diff options
Diffstat (limited to 'indra/newview')
-rwxr-xr-x | indra/newview/llvoavatar.cpp | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 5fed8ce938..7d38cd116d 100755 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -1362,6 +1362,9 @@ void LLVOAvatar::renderCollisionVolumes() void LLVOAvatar::renderBones() { + + LLGLEnable blend(GL_BLEND); + std::ostringstream ostr; std::ostringstream nullstr; @@ -1379,12 +1382,10 @@ void LLVOAvatar::renderBones() ostr << jointp->getName() << ", "; jointp->updateWorldMatrix(); - + gGL.pushMatrix(); gGL.multMatrix( &jointp->getXform()->getWorldMatrix().mMatrix[0][0] ); - gGL.diffuseColor3f( 1.f, 0.f, 1.f ); - gGL.begin(LLRender::LINES); LLVector3 v[] = @@ -1394,6 +1395,19 @@ void LLVOAvatar::renderBones() }; v[1] = jointp->getEnd(); + LLGLDepthTest normal_depth(GL_TRUE); + + // Unoccluded bone portions + gGL.diffuseColor3f( 1.f, 1.f, 1.f ); + + gGL.vertex3fv(v[0].mV); + gGL.vertex3fv(v[1].mV); + + LLGLDepthTest depth_under(GL_TRUE, GL_FALSE, GL_GREATER); + + // Unoccluded bone portions + gGL.diffuseColor3f( 1.0f, 0.f, 0.0f ); + gGL.vertex3fv(v[0].mV); gGL.vertex3fv(v[1].mV); |