From 033705e89efed1648a87f130a59da78c377a56aa Mon Sep 17 00:00:00 2001 From: Ptolemy Date: Thu, 23 Jun 2022 14:04:33 -0700 Subject: SL-17273: Fix off-by-one bug in gPoolNames, fix formatting so it can't happen in the future --- indra/newview/pipeline.cpp | 44 ++++++++++++++++++++++++-------------------- 1 file changed, 24 insertions(+), 20 deletions(-) (limited to 'indra/newview/pipeline.cpp') diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 030c7b450d..21171701e1 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -281,29 +281,33 @@ static LLStaticHashedString sKern("kern"); static LLStaticHashedString sKernScale("kern_scale"); //---------------------------------------- -std::string gPoolNames[] = +#if 0 +std::string gPoolNames[LLDrawPool::NUM_POOL_TYPES] = { // Correspond to LLDrawpool enum render type - "NONE", - "POOL_SIMPLE", - "POOL_GROUND", - "POOL_FULLBRIGHT", - "POOL_BUMP", - "POOL_MATERIALS", - "POOL_TERRAIN," - "POOL_SKY", - "POOL_WL_SKY", - "POOL_TREE", - "POOL_ALPHA_MASK", - "POOL_FULLBRIGHT_ALPHA_MASK", - "POOL_GRASS", - "POOL_INVISIBLE", - "POOL_AVATAR", - "POOL_VOIDWATER", - "POOL_WATER", - "POOL_GLOW", - "POOL_ALPHA" + "NONE" + , "POOL_SIMPLE" + , "POOL_GROUND" + , "POOL_FULLBRIGHT" + , "POOL_BUMP" + , "POOL_MATERIALS" + , "POOL_TERRAIN" + , "POOL_SKY" + , "POOL_WL_SKY" + , "POOL_TREE" + , "POOL_ALPHA_MASK" + , "POOL_FULLBRIGHT_ALPHA_MASK" + , "POOL_GRASS" + , "POOL_INVISIBLE" + , "POOL_AVATAR" + , "POOL_CONTROL_AV" // Animesh + , "POOL_VOIDWATER" + , "POOL_WATER" + , "POOL_GLOW" + , "POOL_ALPHA" + , "POOL_PBR_OPAQUE" }; +#endif void drawBox(const LLVector4a& c, const LLVector4a& r); void drawBoxOutline(const LLVector3& pos, const LLVector3& size); -- cgit v1.2.3