From 54ba657e170614f5f18c84474734a5f97dedcac9 Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Wed, 10 Feb 2010 18:07:54 +0000 Subject: CID-71 Checker: FORWARD_NULL Function: LLFace::getGeometryVolume(const LLVolume &, const int &, const LLMatrix4 &, const LLMatrix3 &, const unsigned short &) File: /indra/newview/llface.cpp --- indra/newview/llface.cpp | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index 965ac1cad0..4a540fbe58 100644 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -1040,17 +1040,20 @@ BOOL LLFace::getGeometryVolume(const LLVolume& volume, if (rebuild_color) { - GLfloat alpha[4] = - { - 0.00f, - 0.25f, - 0.5f, - 0.75f - }; - - if (getPoolType() != LLDrawPool::POOL_ALPHA && (LLPipeline::sRenderDeferred || (LLPipeline::sRenderBump && tep->getShiny()))) + if (tep) { - color.mV[3] = U8 (alpha[tep->getShiny()] * 255); + GLfloat alpha[4] = + { + 0.00f, + 0.25f, + 0.5f, + 0.75f + }; + + if (getPoolType() != LLDrawPool::POOL_ALPHA && (LLPipeline::sRenderDeferred || (LLPipeline::sRenderBump && tep->getShiny()))) + { + color.mV[3] = U8 (alpha[tep->getShiny()] * 255); + } } } -- cgit v1.2.3