diff options
| author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2018-10-02 22:02:42 +0100 |
|---|---|---|
| committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2018-10-02 22:02:42 +0100 |
| commit | 5bb0b393a9ee634db1fbbde2645a6374704e184c (patch) | |
| tree | f4b9a28c23286443f871817dd9e4409dea4aff9b /indra/newview/llspatialpartition.cpp | |
| parent | aacb7eb25fd4caceaafb145ed550e14cebeef665 (diff) | |
SL-966 - behavior improvements and visualization, bonus removal of unrelated duplicate code in llappviewer.cpp
Diffstat (limited to 'indra/newview/llspatialpartition.cpp')
| -rw-r--r-- | indra/newview/llspatialpartition.cpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index ee77556047..f25ab0709b 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -53,6 +53,9 @@ #include "llvolumemgr.h" #include "lltextureatlas.h" #include "llviewershadermgr.h" +#include "llcontrolavatar.h" + +//#pragma optimize("", off) static LLTrace::BlockTimerStatHandle FTM_FRUSTUM_CULL("Frustum Culling"); static LLTrace::BlockTimerStatHandle FTM_CULL_REBOUND("Cull Rebound Partition"); @@ -2170,7 +2173,19 @@ void renderBoundingBox(LLDrawable* drawable, BOOL set_color = TRUE) gGL.diffuseColor4f(0,0.5f,0,1); // dark green break; default: - gGL.diffuseColor4f(1,0,1,1); // magenta + LLControlAvatar *cav = dynamic_cast<LLControlAvatar*>(drawable->getVObj()->asAvatar()); + if (cav) + { + bool has_pos_constraint = (cav->mPositionConstraintFixup != LLVector3()); + bool has_scale_constraint = (cav->mScaleConstraintFixup != 1.0f); + F32 r = 1.0f * has_scale_constraint; + F32 g = 1.0f * has_pos_constraint; + gGL.diffuseColor4f(r,g,0,1); + } + else + { + gGL.diffuseColor4f(1,0,1,1); // magenta + } break; } } |
