diff --git a/indra/llrender/llrendernavprim.cpp b/indra/llrender/llrendernavprim.cpp
index ebc453a32cea345981b3cb406b3576fa5da6b8ae..21ba29741e9da00943dca411b05a720aab7542f1 100644
--- a/indra/llrender/llrendernavprim.cpp
+++ b/indra/llrender/llrendernavprim.cpp
@@ -62,6 +62,19 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
 	gGL.end();		
 }
 //=============================================================================
+void LLRenderNavPrim::renderLLTri( const LLVector3& a, const LLVector3& b, const LLVector3& c, const LLColor4U& color, bool overlayMode ) const
+{
+	LLColor4 cV(color);
+	gGL.color4fv( cV.mV );
+	gGL.begin(LLRender::TRIANGLES);
+	{
+		gGL.vertex3fv( a.mV );
+		gGL.vertex3fv( b.mV );
+		gGL.vertex3fv( c.mV );
+	}
+	gGL.end();		
+}
+//=============================================================================
 void LLRenderNavPrim::renderNavMeshVB( LLVertexBuffer* pVBO, int vertCnt )
 {	
 	pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_COLOR | LLVertexBuffer::MAP_NORMAL );
diff --git a/indra/llrender/llrendernavprim.h b/indra/llrender/llrendernavprim.h
index 158093690ebece395f3d4e87fecadad253abd74c..b5509d9c5ef130ddfa2f51a74b7c1d5f82db876d 100644
--- a/indra/llrender/llrendernavprim.h
+++ b/indra/llrender/llrendernavprim.h
@@ -43,6 +43,8 @@ class LLRenderNavPrim
 	void renderSegment( const LLVector3& start, const LLVector3& end, int color, bool overlayMode  ) const;
 	//Draw simple tri
 	void renderTri( const LLVector3& a, const LLVector3& b, const LLVector3& c, int color, bool overlayMode ) const;
+	//Draw simple tri
+	void renderLLTri( const LLVector3& a, const LLVector3& b, const LLVector3& c, const LLColor4U& color, bool overlayMode ) const;
 	//Draw the contents of vertex buffer
 	void renderNavMeshVB( LLVertexBuffer* pVBO, int vertCnt );
 	//Draw a star
diff --git a/indra/newview/llfloaterpathfindingconsole.cpp b/indra/newview/llfloaterpathfindingconsole.cpp
index ae08a166a10d8be9d89f7b8915d278b79634c2b8..f830dc1fac93aeb0dd3084c7af08538dc0798125 100644
--- a/indra/newview/llfloaterpathfindingconsole.cpp
+++ b/indra/newview/llfloaterpathfindingconsole.cpp
@@ -368,6 +368,35 @@ LLFloaterPathfindingConsole::ERenderHeatmapType LLFloaterPathfindingConsole::get
 	return renderHeatmapType;
 }
 
+int LLFloaterPathfindingConsole::getHeatMapType() const
+{
+	//converts the pathfinding console values to the navmesh filter values
+
+	int renderHeatmapType = 4; //none
+
+	switch ( mShowNavMeshWalkabilityComboBox->getValue().asInteger() )
+	{
+		case XUI_RENDER_HEATMAP_A :
+			renderHeatmapType = 0;
+			break;
+		case XUI_RENDER_HEATMAP_B :
+			renderHeatmapType = 1;
+			break;
+		case XUI_RENDER_HEATMAP_C :
+			renderHeatmapType = 2;
+			break;
+		case XUI_RENDER_HEATMAP_D :
+			renderHeatmapType = 3;
+			break;
+		default :
+			renderHeatmapType = 4;
+			break;
+	}
+
+	return renderHeatmapType;
+}
+
+
 void LLFloaterPathfindingConsole::setRenderHeatmapType(ERenderHeatmapType pRenderHeatmapType)
 {
 	LLSD comboBoxValue;
diff --git a/indra/newview/llfloaterpathfindingconsole.h b/indra/newview/llfloaterpathfindingconsole.h
index 8c22e5ead7ea6aa1018a92292ba050dfb7ad07bf..dff9b0838366606eb1c3499fd7f51499a94b3f10 100644
--- a/indra/newview/llfloaterpathfindingconsole.h
+++ b/indra/newview/llfloaterpathfindingconsole.h
@@ -112,7 +112,7 @@ class LLFloaterPathfindingConsole
 	bool getHeartBeat() const { return mHeartBeat;}
 	void setHeartBeat( bool state ) { mHeartBeat=state; }
 	void regionCrossingOccured();
-
+	int getHeatMapType() const;
 
 protected:
 
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index f0c53424259a7ed52dbf7843801878844c2afa82..f91dfa7c279b4303945d05d64940a45959576aa6 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -4347,7 +4347,8 @@ void LLPipeline::renderDebug()
 					glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT | GL_STENCIL_BUFFER_BIT);					
 					glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );	
 				}
-				llPathingLibInstance->renderNavMesh();
+				int materialIndex = pathfindingConsole->getHeatMapType();
+				llPathingLibInstance->renderNavMesh( materialIndex );
 				glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );	
 				glLineWidth(1.0f);	
 				gGL.flush();