summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2015-11-18 13:21:15 -0500
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2015-11-18 13:21:15 -0500
commit3d66c31156cdde6240f5f27e18275060205f8ce9 (patch)
treebd2af0d811a8d86e830539f7ee61f218c829452f /indra
parent94d7d6a623d755424c2bd8c2526bff0d46101915 (diff)
SL-271 WIP, SL-201 WIP - leaf joint attrib is now end. Show bones option now includes occluded portions.
Diffstat (limited to 'indra')
-rwxr-xr-xindra/llappearance/llavatarappearance.cpp3
-rwxr-xr-xindra/newview/llvoavatar.cpp20
2 files changed, 18 insertions, 5 deletions
diff --git a/indra/llappearance/llavatarappearance.cpp b/indra/llappearance/llavatarappearance.cpp
index 142120cb6c..de541add97 100755
--- a/indra/llappearance/llavatarappearance.cpp
+++ b/indra/llappearance/llavatarappearance.cpp
@@ -1574,8 +1574,7 @@ BOOL LLAvatarBoneInfo::parseXml(LLXmlTreeNode* node)
return FALSE;
}
- // BENTO rename leaf->end
- static LLStdStringHandle end_string = LLXmlTree::addAttributeString("leaf");
+ static LLStdStringHandle end_string = LLXmlTree::addAttributeString("end");
if (!node->getFastAttributeVector3(end_string, mEnd))
{
LL_WARNS() << "Bone without end " << mName << LL_ENDL;
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);