summaryrefslogtreecommitdiff
path: root/indra/newview/llstartup.cpp
diff options
context:
space:
mode:
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 b532d9a9b4..1be1c4ba96 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"));
@@ -2717,81 +2716,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()