From 06bfbf61e16ffec0e54f131a7f3b37c475f10cd9 Mon Sep 17 00:00:00 2001 From: prep Date: Wed, 4 Jan 2012 13:12:46 -0500 Subject: Path-177. Updated to newest version of LLPathingLibrary --- indra/newview/llviewerdisplay.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'indra/newview/llviewerdisplay.cpp') diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index d710076228..2b2dd5ef7c 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -885,6 +885,7 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) LLAppViewer::instance()->pingMainloopTimeout("Display:RenderGeom"); bool exclusiveDraw = false; BOOL allowRenderables = false; + BOOL allowPathToBeDrawn = false; if (!(LLAppViewer::instance()->logoutRequestSent() && LLAppViewer::instance()->hasSavedFinalSnapshot()) && !gRestoreGL) { @@ -906,6 +907,11 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) { allowRenderables = true; } + //Determine if we should also draw a user supplied path on top of the scene + if ( pFloater && pFloater->getShowPathToggle() ) + { + allowPathToBeDrawn = true; + } //Navmesh if ( LLPathingLib::getInstance()->getRenderNavMeshState() ) { @@ -929,7 +935,12 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); LLPathingLib::getInstance()->renderNavMeshShapesVBO(); exclusiveDraw = true; - } + } + //User designated path + if ( allowPathToBeDrawn ) + { + LLPathingLib::getInstance()->renderPath(); + } } } -- cgit v1.2.3