summaryrefslogtreecommitdiff
path: root/indra/newview/lldrawpoolbump.cpp
diff options
context:
space:
mode:
authorCallum Prentice <callum@mbp.localdomain>2022-12-12 11:05:24 -0800
committerCallum Prentice <callum@mbp.localdomain>2022-12-12 11:05:24 -0800
commit6daa0a9ecba98fc805a3e76573c894f1d956da8a (patch)
tree8dd833707caf512e580cbe8f2a265d4367103894 /indra/newview/lldrawpoolbump.cpp
parenta849c51837c9fad2a6929564f4b3a3446a2f4e9a (diff)
parenta0c3d69c620a92d73a1008f218680fb4d0ef9255 (diff)
Merge branch 'main' into DRTVWR-489-emoji
Diffstat (limited to 'indra/newview/lldrawpoolbump.cpp')
-rw-r--r--indra/newview/lldrawpoolbump.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/indra/newview/lldrawpoolbump.cpp b/indra/newview/lldrawpoolbump.cpp
index 8db6a10e26..c4c88d304c 100644
--- a/indra/newview/lldrawpoolbump.cpp
+++ b/indra/newview/lldrawpoolbump.cpp
@@ -41,6 +41,7 @@
#include "lldrawable.h"
#include "llface.h"
#include "llsky.h"
+#include "llstartup.h"
#include "lltextureentry.h"
#include "llviewercamera.h"
#include "llviewertexturelist.h"
@@ -79,11 +80,6 @@ static S32 bump_channel = -1;
#define LL_BUMPLIST_MULTITHREADED 0 // TODO -- figure out why this doesn't work
-// static
-void LLStandardBumpmap::init()
-{
- LLStandardBumpmap::restoreGL();
-}
// static
void LLStandardBumpmap::shutdown()
@@ -94,7 +90,7 @@ void LLStandardBumpmap::shutdown()
// static
void LLStandardBumpmap::restoreGL()
{
- addstandard();
+ addstandard();
}
// static
@@ -107,6 +103,12 @@ void LLStandardBumpmap::addstandard()
return ;
}
+ if (LLStartUp::getStartupState() < STATE_SEED_CAP_GRANTED)
+ {
+ // Not ready, need caps for images
+ return;
+ }
+
// can't assert; we destroyGL and restoreGL a lot during *first* startup, which populates this list already, THEN we explicitly init the list as part of *normal* startup. Sigh. So clear the list every time before we (re-)add the standard bumpmaps.
//llassert( LLStandardBumpmap::sStandardBumpmapCount == 0 );
clear();
@@ -769,8 +771,6 @@ void LLBumpImageList::init()
llassert( mBrightnessEntries.size() == 0 );
llassert( mDarknessEntries.size() == 0 );
- LLStandardBumpmap::init();
-
LLStandardBumpmap::restoreGL();
sMainQueue = LL::WorkQueue::getInstance("mainloop");
sTexUpdateQueue = LL::WorkQueue::getInstance("LLImageGL"); // Share work queue with tex loader.