diff options
author | Dave Parks <davep@lindenlab.com> | 2010-04-15 00:04:17 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2010-04-15 00:04:17 -0500 |
commit | 54dd30cc426e16aa99b4f7eea080bbeae0656843 (patch) | |
tree | 5a30419a11316fd348a678784d660a0b96e1d033 /indra/newview | |
parent | 0660cf0c987385dc2923bff389c7fa1bc0feec81 (diff) |
More rigged attachments work.
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/lldrawpoolavatar.cpp | 3 | ||||
-rw-r--r-- | indra/newview/llvoavatar.cpp | 12 |
2 files changed, 11 insertions, 4 deletions
diff --git a/indra/newview/lldrawpoolavatar.cpp b/indra/newview/lldrawpoolavatar.cpp index de9b71a9b8..1a2558ac5f 100644 --- a/indra/newview/lldrawpoolavatar.cpp +++ b/indra/newview/lldrawpoolavatar.cpp @@ -325,7 +325,7 @@ void LLDrawPoolAvatar::renderShadow(S32 pass) S32 LLDrawPoolAvatar::getNumPasses() { - return LLPipeline::sImpostorRender ? 1 : 3; + return LLPipeline::sImpostorRender ? 1 : 4; } void LLDrawPoolAvatar::render(S32 pass) @@ -588,6 +588,7 @@ void LLDrawPoolAvatar::beginRigged() void LLDrawPoolAvatar::endRigged() { sVertexProgram = NULL; + LLVertexBuffer::unbind(); gSkinnedObjectSimpleProgram.unbind(); LLVertexBuffer::sWeight4Loc = -1; } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 201c4ce1d5..8bf4c0ab96 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -3728,8 +3728,8 @@ U32 LLVOAvatar::renderSkinnedAttachments() LLJoint* joint = getJoint(skin->mJointNames[i]); if (joint) { - mat[i] = skin->mInvBindMatrix[i]; - mat[i] *= joint->getWorldMatrix(); + mat[i*2+0] = skin->mInvBindMatrix[i]; + mat[i*2+1] = joint->getWorldMatrix(); } } @@ -3737,6 +3737,10 @@ U32 LLVOAvatar::renderSkinnedAttachments() skin->mJointNames.size(), FALSE, (GLfloat*) mat[0].mMatrix); + gSkinnedObjectSimpleProgram.uniformMatrix4fv("matrixPalette[0]", + skin->mJointNames.size(), + FALSE, + (GLfloat*) mat[0].mMatrix); buff->setBuffer(data_mask); @@ -3745,7 +3749,9 @@ U32 LLVOAvatar::renderSkinnedAttachments() S32 offset = face->getIndicesStart(); U32 count = face->getIndicesCount(); - buff->drawRange(LLRender::TRIANGLES, start, end, count, offset); + glPointSize(8.f); + buff->drawRange(LLRender::POINTS, start, end, count, offset); + glPointSize(1.f); } } } |