summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/llrender/llrendernavprim.cpp42
-rw-r--r--indra/newview/pipeline.cpp6
2 files changed, 10 insertions, 38 deletions
diff --git a/indra/llrender/llrendernavprim.cpp b/indra/llrender/llrendernavprim.cpp
index 8d55f840f4..c07d93ab0a 100644
--- a/indra/llrender/llrendernavprim.cpp
+++ b/indra/llrender/llrendernavprim.cpp
@@ -35,8 +35,7 @@
LLRenderNavPrim gRenderNav;
//=============================================================================
void LLRenderNavPrim::renderSegment( const LLVector3& start, const LLVector3& end, int color ) const
-{
-
+{
LLColor4 colorA( color );
glLineWidth(1.5f);
gGL.color3fv( colorA.mV );
@@ -47,6 +46,7 @@ void LLRenderNavPrim::renderSegment( const LLVector3& start, const LLVector3& en
gGL.vertex3fv( end.mV );
}
gGL.end();
+
glLineWidth(1.0f);
}
//=============================================================================
@@ -56,7 +56,7 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );
LLGLDisable cull(GL_CULL_FACE);
LLColor4 colorA( color );
- colorA*=2.0f;
+ //colorA*=2.0f;
gGL.color4fv( colorA.mV );
gGL.begin(LLRender::TRIANGLES);
@@ -66,46 +66,16 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
gGL.vertex3fv( c.mV );
}
gGL.end();
+
gGL.flush();
}
//=============================================================================
void LLRenderNavPrim::renderNavMeshVB( LLVertexBuffer* pVBO, int vertCnt )
-{ /*
- LLGLDisable cull(GL_CULL_FACE);
- glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
- glLineWidth(1.f);
-
- gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
- LLColor4 colorA( 255);
- colorA*=2.0f;
- gGL.color4fv( colorA.mV );
-
- pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_COLOR );
- pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt );
- */
-
- //2
- //gGL.setSceneBlendType(LLRender::BT_REPLACE);
- //glEnable(GL_COLOR_MATERIAL);
- //glColorMaterial( GL_FRONT_AND_BACK, GL_AMBIENT );
- //glShadeModel( GL_FLAT );
- //F32 ambient[4] = {1.f,0.f,1.f,1.f };
- //gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
- //LLColor4 colorA( 255.0f );
- //colorA*=2.0f;
- //gGL.color4fv( colorA.mV );
+{
glLineWidth(1.5f);
glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );
LLGLDisable cull(GL_CULL_FACE);
- LLColor4 colorA( 4278190335 );
- colorA*=2.0f;
- gGL.color4fv( colorA.mV );
-
+ gGL.color4fv( LLColor4::white.mV );
pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX );
- pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt );
- //gGL.flush();
-
-
-
}
//=============================================================================
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index 9094984dfe..5f6e3f4675 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -3618,6 +3618,7 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
}
LLAppViewer::instance()->pingMainloopTimeout("Pipeline:ForceVBO");
+ //Render navmesh geometry
{
if ( LLPathingLib::getInstance() )
{
@@ -3628,7 +3629,7 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
glClearColor(0.0f, 0.0f, 0.0f, 0.5f); // Black Background
glClearDepth(1.0f); // Depth Buffer Setup
glEnable(GL_DEPTH_TEST); // Enables Depth Testing
- glDepthFunc(GL_LEQUAL); // The Type Of Depth Testing To Do
+ glDepthFunc(GL_LEQUAL);
GLfloat LightAmbient[]= { 0.5f, 0.5f, 0.5f, 1.0f };
glLightfv(GL_LIGHT1, GL_AMBIENT, LightAmbient);
@@ -3647,6 +3648,7 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
if ( exclusiveDraw ) { return; }
}
}
+
// Initialize lots of GL state to "safe" values
glMatrixMode(GL_TEXTURE);
glLoadIdentity();
@@ -3672,7 +3674,7 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sDefaultImagep);
LLViewerFetchedTexture::sDefaultImagep->setAddressMode(LLTexUnit::TAM_WRAP);
-
+
//////////////////////////////////////////////
//
// Actually render all of the geometry