Unstaged changes cleanup. Further vectorization. Change in binormal/bitangent calculation.
This commit is contained in:
@@ -293,6 +293,9 @@ void LLVolumeImplFlexible::onSetVolume(const LLVolumeParams &volume_params, cons
|
||||
|
||||
void LLVolumeImplFlexible::updateRenderRes()
|
||||
{
|
||||
if (!mAttributes)
|
||||
return;
|
||||
|
||||
LLDrawable* drawablep = mVO->mDrawable;
|
||||
|
||||
S32 new_res = mAttributes->getSimulateLOD();
|
||||
@@ -424,7 +427,7 @@ void LLVolumeImplFlexible::doFlexibleUpdate()
|
||||
}
|
||||
}
|
||||
|
||||
if(!mInitialized)
|
||||
if(!mInitialized || !mAttributes)
|
||||
{
|
||||
//the object is not visible
|
||||
return ;
|
||||
@@ -682,15 +685,17 @@ void LLVolumeImplFlexible::doFlexibleUpdate()
|
||||
new_point = &path->mPath[i];
|
||||
LLVector3 pos = newSection[i].mPosition * rel_xform;
|
||||
LLQuaternion rot = mSection[i].mAxisRotation * newSection[i].mRotation * delta_rot;
|
||||
|
||||
if (!mUpdated || (new_point->mPos-pos).magVec()/mVO->mDrawable->mDistanceWRTCamera > 0.001f)
|
||||
|
||||
LLVector3 np(new_point->mPos.getF32ptr());
|
||||
|
||||
if (!mUpdated || (np-pos).magVec()/mVO->mDrawable->mDistanceWRTCamera > 0.001f)
|
||||
{
|
||||
new_point->mPos = newSection[i].mPosition * rel_xform;
|
||||
new_point->mPos.load3((newSection[i].mPosition * rel_xform).mV);
|
||||
mUpdated = FALSE;
|
||||
}
|
||||
|
||||
new_point->mRot = rot;
|
||||
new_point->mScale = newSection[i].mScale;
|
||||
new_point->mRot.loadu(LLMatrix3(rot));
|
||||
new_point->mScale.set(newSection[i].mScale.mV[0], newSection[i].mScale.mV[1], 0,1);
|
||||
new_point->mTexT = ((F32)i)/(num_render_sections);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user