Slightly smarter flexi update handling, plus extra nullchecks.

This commit is contained in:
Shyotl
2011-05-20 16:07:47 -05:00
parent 9a29428b39
commit 285c19090e
4 changed files with 15 additions and 6 deletions

View File

@@ -366,7 +366,7 @@ void LLVolumeImplFlexible::doFlexibleUpdate()
{
LLVolume* volume = mVO->getVolume();
LLPath *path = &volume->getPath();
if (mSimulateRes == 0)
if ((mSimulateRes == 0 || !mInitialized) && mVO->mDrawable->isVisible()) // if its uninitialized but not visible, what then? - Nyx
{
mVO->markForUpdate(TRUE);
if (!doIdleUpdate(gAgent, *LLWorld::getInstance(), 0.0))
@@ -694,7 +694,11 @@ BOOL LLVolumeImplFlexible::doUpdateGeometry(LLDrawable *drawable)
}
volume->updateRelativeXform();
doFlexibleUpdate();
if (mRenderRes > -1)
{
doFlexibleUpdate();
}
// Object may have been rotated, which means it needs a rebuild. See SL-47220
BOOL rotated = FALSE;