Simplification of LLPrimitive::setVolume ala davep. Have had this for a while, I just never commited until now. Haven't noticed any misbehavior with this alteration, and I'm tired of it going uncommited.
This commit is contained in:
@@ -745,6 +745,10 @@ BOOL LLPrimitive::setVolume(const LLVolumeParams &volume_params, const S32 detai
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
// #if 0'd out by davep
|
||||||
|
// this is a lot of cruft to set texture entry values that just stay the same for LOD switch
|
||||||
|
// or immediately get overridden by an object update message, also crashes occasionally
|
||||||
U32 old_face_mask = mVolumep->mFaceMask;
|
U32 old_face_mask = mVolumep->mFaceMask;
|
||||||
|
|
||||||
S32 face_bit = 0;
|
S32 face_bit = 0;
|
||||||
@@ -942,6 +946,13 @@ BOOL LLPrimitive::setVolume(const LLVolumeParams &volume_params, const S32 detai
|
|||||||
setTE(te_num, *(old_tes.getTexture(face_mapping[face_bit])));
|
setTE(te_num, *(old_tes.getTexture(face_mapping[face_bit])));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
// build the new object
|
||||||
|
sVolumeManager->unrefVolume(mVolumep);
|
||||||
|
mVolumep = volumep;
|
||||||
|
|
||||||
|
setNumTEs(mVolumep->getNumFaces());
|
||||||
|
#endif
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user