Skip to content
Snippets Groups Projects
Commit 1e45d1ae authored by prep's avatar prep
Browse files

vbos for physics shapes are rendering correctly

parent e31a0a7f
No related branches found
No related tags found
No related merge requests found
...@@ -85,20 +85,18 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L ...@@ -85,20 +85,18 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
//============================================================================= //=============================================================================
void LLRenderNavPrim::renderNavMeshVB( LLVertexBuffer* pVBO, int vertCnt ) void LLRenderNavPrim::renderNavMeshVB( LLVertexBuffer* pVBO, int vertCnt )
{ {
LLGLSUIDefault gls_ui;
glLineWidth(1.5f); glLineWidth(1.5f);
LLGLSLShader::sNoFixedFunction = false; LLGLSLShader::sNoFixedFunction = false;
glPolygonMode( GL_FRONT_AND_BACK, GL_FILL ); glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );
LLGLEnable cull( GL_CULL_FACE ); LLGLEnable cull( GL_CULL_FACE );
//pass 1 filled //pass 1 filled
pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_COLOR | LLVertexBuffer::MAP_NORMAL ); pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_COLOR | LLVertexBuffer::MAP_NORMAL );
pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt ); pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt );
//glPolygonMode( GL_FRONT_AND_BACK, GL_LINE ); glPolygonMode( GL_FRONT_AND_BACK, GL_LINE );
//static GLubyte red[]= { 255.0f, 0.0f, 0.0f, 255.0f };
//glColor4ubv( red );
//pass 2 outlined //pass 2 outlined
//pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt ); pVBO->drawArrays( LLRender::TRIANGLES, 0, vertCnt );
LLGLSLShader::sNoFixedFunction = true; LLGLSLShader::sNoFixedFunction = true;
glLineWidth(1.0f); glLineWidth(1.0f);
glPolygonMode( GL_FRONT_AND_BACK, GL_FILL ); glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment