diff options
author | Dave Parks <davep@lindenlab.com> | 2011-10-04 17:25:55 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2011-10-04 17:25:55 -0500 |
commit | ae0cd901f8917f1cacc4c402e5a51a06632a076b (patch) | |
tree | 7c7d49d0d82e0ed4e5fe22d79d6013412bcc3479 /indra/newview/llvograss.cpp | |
parent | c4aa8c50daf7c4eea3509057a7ca74b083682779 (diff) |
SH-2428 Make GCC 4.4 happy by using LLVector4a striders with LLAlphaObject subclasses -- also vectorize particle VBO updates
Diffstat (limited to 'indra/newview/llvograss.cpp')
-rw-r--r-- | indra/newview/llvograss.cpp | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/indra/newview/llvograss.cpp b/indra/newview/llvograss.cpp index 32822e1181..8a79d564d3 100644 --- a/indra/newview/llvograss.cpp +++ b/indra/newview/llvograss.cpp @@ -464,7 +464,7 @@ void LLVOGrass::plantBlades() } void LLVOGrass::getGeometry(S32 idx, - LLStrider<LLVector3>& verticesp, + LLStrider<LLVector4a>& verticesp, LLStrider<LLVector3>& normalsp, LLStrider<LLVector2>& texcoordsp, LLStrider<LLColor4U>& colorsp, @@ -516,21 +516,24 @@ void LLVOGrass::getGeometry(S32 idx, position.mV[0] = mPosition.mV[VX] + x + xf; position.mV[1] = mPosition.mV[VY] + y + yf; position.mV[2] = mRegionp->getLand().resolveHeightRegion(position); - *verticesp++ = v1 = position + mRegionp->getOriginAgent(); - *verticesp++ = v1; + v1 = position + mRegionp->getOriginAgent(); + (*verticesp++).load3(v1.mV); + (*verticesp++).load3(v1.mV); position.mV[0] += dzx; position.mV[1] += dzy; position.mV[2] += blade_height; - *verticesp++ = v2 = position + mRegionp->getOriginAgent(); - *verticesp++ = v2; + v2 = position + mRegionp->getOriginAgent(); + (*verticesp++).load3(v2.mV); + (*verticesp++).load3(v2.mV); position.mV[0] = mPosition.mV[VX] + x - xf; position.mV[1] = mPosition.mV[VY] + y - xf; position.mV[2] = mRegionp->getLand().resolveHeightRegion(position); - *verticesp++ = v3 = position + mRegionp->getOriginAgent(); - *verticesp++ = v3; + v3 = position + mRegionp->getOriginAgent(); + (*verticesp++).load3(v3.mV); + (*verticesp++).load3(v3.mV); LLVector3 normal1 = (v1-v2) % (v2-v3); normal1.mV[VZ] = 0.75f; @@ -541,8 +544,9 @@ void LLVOGrass::getGeometry(S32 idx, position.mV[0] += dzx; position.mV[1] += dzy; position.mV[2] += blade_height; - *verticesp++ = v1 = position + mRegionp->getOriginAgent(); - *verticesp++ = v1; + v1 = position + mRegionp->getOriginAgent(); + (*verticesp++).load3(v1.mV); + (*verticesp++).load3(v1.mV); *(normalsp++) = normal1; *(normalsp++) = normal2; |