summaryrefslogtreecommitdiff
path: root/indra/newview/llstartup.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2020-06-02 23:11:13 +0300
committerAndrey Lihatskiy <alihatskiy@productengine.com>2020-06-02 23:11:13 +0300
commit2571b948298cff82b3e3425c5b6b1c3f56caed45 (patch)
treee83f7feefee1febee685e4aaf662e1a91c6e0815 /indra/newview/llstartup.cpp
parent353afb48f265822f591eb8d02cacd830e32640bf (diff)
parent1702a65665879d0c68df4c6b4fdb60f815ab7abb (diff)
Merge branch 'master' into DRTVWR-507-maint
# Conflicts: # indra/llaudio/llaudioengine_fmodex.cpp
Diffstat (limited to 'indra/newview/llstartup.cpp')
-rw-r--r--indra/newview/llstartup.cpp94
1 files changed, 9 insertions, 85 deletions
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 69b454ef74..c39687a57b 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -39,8 +39,8 @@
#include "llviewermedia_streamingaudio.h"
#include "llaudioengine.h"
-#ifdef LL_FMODEX
-# include "llaudioengine_fmodex.h"
+#ifdef LL_FMODSTUDIO
+# include "llaudioengine_fmodstudio.h"
#endif
#ifdef LL_OPENAL
@@ -623,13 +623,13 @@ bool idle_startup()
delete gAudiop;
gAudiop = NULL;
-#ifdef LL_FMODEX
+#ifdef LL_FMODSTUDIO
#if !LL_WINDOWS
- if (NULL == getenv("LL_BAD_FMODEX_DRIVER"))
+ if (NULL == getenv("LL_BAD_FMODSTUDIO_DRIVER"))
#endif // !LL_WINDOWS
- {
- gAudiop = (LLAudioEngine *) new LLAudioEngine_FMODEX(gSavedSettings.getBOOL("FMODExProfilerEnable"));
- }
+ {
+ gAudiop = (LLAudioEngine *) new LLAudioEngine_FMODSTUDIO(gSavedSettings.getBOOL("FMODExProfilerEnable"));
+ }
#endif
#ifdef LL_OPENAL
@@ -650,7 +650,7 @@ bool idle_startup()
#else
void* window_handle = NULL;
#endif
- bool init = gAudiop->init(kAUDIO_NUM_SOURCES, window_handle);
+ bool init = gAudiop->init(kAUDIO_NUM_SOURCES, window_handle, LLAppViewer::instance()->getSecondLifeTitle());
if(init)
{
gAudiop->setMuted(TRUE);
@@ -994,9 +994,8 @@ bool idle_startup()
gViewerWindow->getWindow()->setCursor(UI_CURSOR_WAIT);
- init_start_screen(agent_location_id);
-
// Display the startup progress bar.
+ gViewerWindow->initTextures(agent_location_id);
gViewerWindow->setShowProgress(TRUE);
gViewerWindow->setProgressCancelButtonVisible(TRUE, LLTrans::getString("Quit"));
@@ -2716,81 +2715,6 @@ std::string LLStartUp::getUserId()
return gUserCredential->userID();
}
-// Loads a bitmap to display during load
-void init_start_screen(S32 location_id)
-{
- if (gStartTexture.notNull())
- {
- gStartTexture = NULL;
- LL_INFOS("AppInit") << "re-initializing start screen" << LL_ENDL;
- }
-
- LL_DEBUGS("AppInit") << "Loading startup bitmap..." << LL_ENDL;
-
- U8 image_codec = IMG_CODEC_PNG;
- std::string temp_str = gDirUtilp->getLindenUserDir() + gDirUtilp->getDirDelimiter();
-
- if ((S32)START_LOCATION_ID_LAST == location_id)
- {
- temp_str += LLStartUp::getScreenLastFilename();
- }
- else
- {
- std::string path = temp_str + LLStartUp::getScreenHomeFilename();
-
- if (!gDirUtilp->fileExists(path) && LLGridManager::getInstance()->isInProductionGrid())
- {
- // Fallback to old file, can be removed later
- // Home image only sets when user changes home, so it will take time for users to switch to pngs
- temp_str += "screen_home.bmp";
- image_codec = IMG_CODEC_BMP;
- }
- else
- {
- temp_str = path;
- }
- }
-
- LLPointer<LLImageFormatted> start_image_frmted = LLImageFormatted::createFromType(image_codec);
-
- // Turn off start screen to get around the occasional readback
- // driver bug
- if(!gSavedSettings.getBOOL("UseStartScreen"))
- {
- LL_INFOS("AppInit") << "Bitmap load disabled" << LL_ENDL;
- return;
- }
- else if(!start_image_frmted->load(temp_str) )
- {
- LL_WARNS("AppInit") << "Bitmap load failed" << LL_ENDL;
- gStartTexture = NULL;
- }
- else
- {
- gStartImageWidth = start_image_frmted->getWidth();
- gStartImageHeight = start_image_frmted->getHeight();
-
- LLPointer<LLImageRaw> raw = new LLImageRaw;
- if (!start_image_frmted->decode(raw, 0.0f))
- {
- LL_WARNS("AppInit") << "Bitmap decode failed" << LL_ENDL;
- gStartTexture = NULL;
- }
- else
- {
- raw->expandToPowerOfTwo();
- gStartTexture = LLViewerTextureManager::getLocalTexture(raw.get(), FALSE) ;
- }
- }
-
- if(gStartTexture.isNull())
- {
- gStartTexture = LLViewerTexture::sBlackImagep ;
- gStartImageWidth = gStartTexture->getWidth() ;
- gStartImageHeight = gStartTexture->getHeight() ;
- }
-}
-
// frees the bitmap
void release_start_screen()