summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2010-04-16 15:53:26 -0500
committerDave Parks <davep@lindenlab.com>2010-04-16 15:53:26 -0500
commita20546a5dd82d16410b2c8d88c3f38d0833b6d3e (patch)
treeda28b31181d38c0fa3be56483d55cd626b075f08 /indra/newview
parent36d942b30c32aeffaf734bd084bd407e5efa4102 (diff)
Fix for busted optimizations.
(transplanted from 6fae1a167f287f23a0cdc5dac8dfa2b74444efcf)
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/lldrawpoolavatar.cpp4
-rw-r--r--indra/newview/llviewerjointmesh.cpp6
2 files changed, 6 insertions, 4 deletions
diff --git a/indra/newview/lldrawpoolavatar.cpp b/indra/newview/lldrawpoolavatar.cpp
index 03e66231d1..c94b0c3fa7 100644
--- a/indra/newview/lldrawpoolavatar.cpp
+++ b/indra/newview/lldrawpoolavatar.cpp
@@ -853,9 +853,7 @@ LLColor3 LLDrawPoolAvatar::getDebugColor() const
LLVertexBufferAvatar::LLVertexBufferAvatar()
: LLVertexBuffer(sDataMask,
- LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_AVATAR) > 0 ?
- GL_DYNAMIC_DRAW_ARB :
- GL_STREAM_DRAW_ARB)
+ GL_STREAM_DRAW_ARB) //avatars are always stream draw due to morph targets
{
}
diff --git a/indra/newview/llviewerjointmesh.cpp b/indra/newview/llviewerjointmesh.cpp
index b125c79f61..c65946a574 100644
--- a/indra/newview/llviewerjointmesh.cpp
+++ b/indra/newview/llviewerjointmesh.cpp
@@ -758,14 +758,18 @@ void LLViewerJointMesh::updateFaceData(LLFace *face, F32 pixel_area, BOOL damp_w
const U32 idx_count = mMesh->getNumFaces()*3;
+ indicesp += mMesh->mFaceIndexOffset;
+
U16* __restrict idx = indicesp.get();
S32* __restrict src_idx = (S32*) mMesh->getFaces();
i = 0;
+ const S32 offset = (S32) mMesh->mFaceVertexOffset;
+
do
{
- *(idx++) = *(src_idx++);
+ *(idx++) = *(src_idx++)+offset;
}
while (++i < idx_count);
}