summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/CMakeLists.txt9
-rw-r--r--indra/newview/app_settings/cmd_line.xml384
-rw-r--r--indra/newview/app_settings/logcontrol.xml8
-rw-r--r--indra/newview/app_settings/settings.xml149
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskF.glsl18
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskV.glsl12
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/alphaF.glsl24
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedF.glsl24
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedNoColorF.glsl24
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl50
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/sunLightSSAOF.glsl52
-rw-r--r--indra/newview/featuretable.txt42
-rw-r--r--indra/newview/featuretable_linux.txt43
-rw-r--r--indra/newview/featuretable_mac.txt42
-rw-r--r--indra/newview/featuretable_xp.txt41
-rw-r--r--indra/newview/gpu_table.txt1
-rwxr-xr-xindra/newview/linux_tools/wrapper.sh42
-rwxr-xr-xindra/newview/llagent.cpp21
-rw-r--r--indra/newview/llagentlistener.cpp11
-rw-r--r--indra/newview/llagentwearables.cpp21
-rw-r--r--indra/newview/llagentwearables.h1
-rw-r--r--indra/newview/llagentwearablesfetch.cpp2
-rw-r--r--indra/newview/llappearancemgr.cpp163
-rw-r--r--indra/newview/llappviewer.cpp210
-rw-r--r--indra/newview/llappviewer.h7
-rwxr-xr-xindra/newview/llavataractions.cpp16
-rw-r--r--indra/newview/llavatarpropertiesprocessor.cpp9
-rw-r--r--indra/newview/llcommandlineparser.cpp9
-rw-r--r--indra/newview/lldebugview.cpp28
-rw-r--r--indra/newview/lldrawpoolbump.cpp7
-rw-r--r--indra/newview/lldynamictexture.cpp4
-rw-r--r--indra/newview/llexternaleditor.cpp73
-rw-r--r--indra/newview/llexternaleditor.h6
-rw-r--r--indra/newview/llfeaturemanager.cpp13
-rw-r--r--indra/newview/llfloaterbvhpreview.cpp24
-rw-r--r--indra/newview/llfloaterhardwaresettings.cpp14
-rwxr-xr-xindra/newview/llfloatermodelpreview.cpp11
-rw-r--r--indra/newview/llfloatermodelpreview.h4
-rw-r--r--indra/newview/llfloatermodelwizard.cpp795
-rw-r--r--indra/newview/llfloatermodelwizard.h140
-rw-r--r--indra/newview/llfloatertexturefetchdebugger.cpp390
-rw-r--r--indra/newview/llfloatertexturefetchdebugger.h71
-rw-r--r--indra/newview/llfolderviewitem.cpp17
-rw-r--r--indra/newview/llgiveinventory.cpp68
-rw-r--r--indra/newview/llgiveinventory.h7
-rw-r--r--indra/newview/llimfloatercontainer.cpp1
-rw-r--r--indra/newview/llimview.cpp10
-rw-r--r--indra/newview/llinspectobject.cpp9
-rw-r--r--indra/newview/llinventoryfilter.cpp2
-rw-r--r--indra/newview/llinventorymodel.cpp49
-rwxr-xr-xindra/newview/llmeshrepository.cpp2
-rw-r--r--indra/newview/llnavigationbar.cpp9
-rw-r--r--indra/newview/llnavigationbar.h1
-rw-r--r--indra/newview/llnearbychatbar.cpp30
-rw-r--r--indra/newview/llnearbychatbar.h7
-rw-r--r--indra/newview/llnotificationscripthandler.cpp2
-rw-r--r--indra/newview/llpanelnearbymedia.cpp2
-rw-r--r--indra/newview/llprogressview.cpp34
-rw-r--r--indra/newview/llprogressview.h7
-rw-r--r--indra/newview/llselectmgr.cpp21
-rw-r--r--indra/newview/llsidepaneltaskinfo.cpp4
-rw-r--r--indra/newview/llspatialpartition.cpp112
-rw-r--r--indra/newview/llspatialpartition.h2
-rw-r--r--indra/newview/llstartup.cpp4
-rw-r--r--indra/newview/llstartup.h4
-rw-r--r--indra/newview/lltexlayer.cpp8
-rw-r--r--indra/newview/lltexturefetch.cpp731
-rw-r--r--indra/newview/lltexturefetch.h196
-rw-r--r--indra/newview/lltextureview.cpp392
-rw-r--r--indra/newview/lltextureview.h35
-rw-r--r--indra/newview/lltoastnotifypanel.cpp4
-rw-r--r--indra/newview/lltoastnotifypanel.h4
-rw-r--r--indra/newview/lltoastpanel.cpp13
-rw-r--r--indra/newview/lltoastscriptquestion.cpp130
-rw-r--r--indra/newview/lltoastscriptquestion.h49
-rw-r--r--indra/newview/llviewerassetstats.cpp43
-rw-r--r--indra/newview/llviewerassetstats.h9
-rw-r--r--indra/newview/llvieweraudio.cpp61
-rw-r--r--indra/newview/llvieweraudio.h7
-rw-r--r--indra/newview/llviewercontrol.cpp8
-rw-r--r--indra/newview/llviewerfloaterreg.cpp8
-rw-r--r--indra/newview/llviewerinventory.cpp4
-rw-r--r--indra/newview/llviewerjointmesh.cpp1
-rw-r--r--indra/newview/llviewerjointmesh.h1
-rw-r--r--indra/newview/llviewermenu.cpp124
-rwxr-xr-xindra/newview/llviewermessage.cpp22
-rw-r--r--indra/newview/llviewermessage.h14
-rw-r--r--indra/newview/llviewerobject.cpp3
-rw-r--r--indra/newview/llviewerobjectlist.cpp5
-rw-r--r--indra/newview/llviewerobjectlist.h2
-rw-r--r--indra/newview/llviewerparcelmgr.cpp9
-rw-r--r--indra/newview/llviewerparcelmgr.h6
-rw-r--r--indra/newview/llviewerprecompiledheaders.h4
-rw-r--r--indra/newview/llviewerstats.cpp107
-rw-r--r--indra/newview/llviewerstats.h25
-rw-r--r--indra/newview/llviewertexture.cpp89
-rw-r--r--indra/newview/llviewertexture.h21
-rw-r--r--indra/newview/llviewertexturelist.cpp29
-rw-r--r--indra/newview/llviewertexturelist.h4
-rwxr-xr-xindra/newview/llviewerwindow.cpp46
-rw-r--r--indra/newview/llvoavatar.cpp647
-rw-r--r--indra/newview/llvoavatar.h46
-rw-r--r--indra/newview/llvoavatarself.cpp260
-rw-r--r--indra/newview/llvoavatarself.h22
-rw-r--r--indra/newview/llvoicevivox.cpp140
-rw-r--r--indra/newview/llvovolume.cpp3
-rw-r--r--indra/newview/llworld.cpp5
-rw-r--r--indra/newview/pipeline.cpp32
-rw-r--r--indra/newview/pipeline.h4
-rw-r--r--indra/newview/skins/default/xui/da/floater_model_wizard.xml241
-rw-r--r--indra/newview/skins/default/xui/de/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/en/floater_hardware_settings.xml22
-rw-r--r--indra/newview/skins/default/xui/en/floater_im_session.xml7
-rw-r--r--indra/newview/skins/default/xui/en/floater_model_preview.xml74
-rw-r--r--indra/newview/skins/default/xui/en/floater_model_wizard.xml841
-rw-r--r--indra/newview/skins/default/xui/en/floater_report_abuse.xml1
-rw-r--r--indra/newview/skins/default/xui/en/floater_stats.xml41
-rw-r--r--indra/newview/skins/default/xui/en/floater_texture_fetch_debugger.xml341
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml101
-rw-r--r--indra/newview/skins/default/xui/en/notifications.xml38
-rw-r--r--indra/newview/skins/default/xui/en/panel_script_question_toast.xml55
-rw-r--r--indra/newview/skins/default/xui/en/sidepanel_task_info.xml8
-rw-r--r--indra/newview/skins/default/xui/en/strings.xml1
-rw-r--r--indra/newview/skins/default/xui/es/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/fr/floater_about_land.xml2
-rw-r--r--indra/newview/skins/default/xui/fr/floater_model_preview.xml2
-rw-r--r--indra/newview/skins/default/xui/fr/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/fr/strings.xml2
-rw-r--r--indra/newview/skins/default/xui/it/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/ja/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/ja/notifications.xml12
-rw-r--r--indra/newview/skins/default/xui/pt/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/pt/menu_viewer.xml4
-rw-r--r--indra/newview/skins/default/xui/ru/floater_model_wizard.xml208
-rw-r--r--indra/newview/skins/default/xui/tr/floater_model_wizard.xml208
-rw-r--r--indra/newview/tests/llviewerassetstats_test.cpp54
-rw-r--r--indra/newview/viewer_manifest.py60
137 files changed, 4846 insertions, 5517 deletions
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index 9aaefa9c6a..a925a39246 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -30,7 +30,6 @@ include(LLUI)
include(LLVFS)
include(LLWindow)
include(LLXML)
-include(LLXUIXML)
include(LScript)
include(Linking)
include(NDOF)
@@ -66,7 +65,6 @@ include_directories(
${LLVFS_INCLUDE_DIRS}
${LLWINDOW_INCLUDE_DIRS}
${LLXML_INCLUDE_DIRS}
- ${LLXUIXML_INCLUDE_DIRS}
${LSCRIPT_INCLUDE_DIRS}
${LSCRIPT_INCLUDE_DIRS}/lscript_compile
${LLLOGIN_INCLUDE_DIRS}
@@ -212,7 +210,6 @@ set(viewer_SOURCE_FILES
llfloatermemleak.cpp
llfloatermodelpreview.cpp
llfloatermodeluploadbase.cpp
- llfloatermodelwizard.cpp
llfloaternamedesc.cpp
llfloaternotificationsconsole.cpp
llfloaterobjectweights.cpp
@@ -237,6 +234,7 @@ set(viewer_SOURCE_FILES
llfloatertelehub.cpp
llfloatertestinspectors.cpp
llfloatertestlistview.cpp
+ llfloatertexturefetchdebugger.cpp
llfloatertools.cpp
llfloatertopobjects.cpp
llfloatertos.cpp
@@ -490,6 +488,7 @@ set(viewer_SOURCE_FILES
lltoastnotifypanel.cpp
lltoastpanel.cpp
lltoastscripttextbox.cpp
+ lltoastscriptquestion.cpp
lltool.cpp
lltoolbarview.cpp
lltoolbrush.cpp
@@ -768,7 +767,6 @@ set(viewer_HEADER_FILES
llfloatermemleak.h
llfloatermodelpreview.h
llfloatermodeluploadbase.h
- llfloatermodelwizard.h
llfloaternamedesc.h
llfloaternotificationsconsole.h
llfloaterobjectweights.h
@@ -793,6 +791,7 @@ set(viewer_HEADER_FILES
llfloatertelehub.h
llfloatertestinspectors.h
llfloatertestlistview.h
+ llfloatertexturefetchdebugger.h
llfloatertools.h
llfloatertopobjects.h
llfloatertos.h
@@ -1037,6 +1036,7 @@ set(viewer_HEADER_FILES
lltoastnotifypanel.h
lltoastpanel.h
lltoastscripttextbox.h
+ lltoastscriptquestion.h
lltool.h
lltoolbarview.h
lltoolbrush.h
@@ -1746,7 +1746,6 @@ target_link_libraries(${VIEWER_BINARY_NAME}
${LLVFS_LIBRARIES}
${LLWINDOW_LIBRARIES}
${LLXML_LIBRARIES}
- ${LLXUIXML_LIBRARIES}
${LSCRIPT_LIBRARIES}
${LLMATH_LIBRARIES}
${LLCOMMON_LIBRARIES}
diff --git a/indra/newview/app_settings/cmd_line.xml b/indra/newview/app_settings/cmd_line.xml
index 15434f2b8f..be79f91919 100644
--- a/indra/newview/app_settings/cmd_line.xml
+++ b/indra/newview/app_settings/cmd_line.xml
@@ -1,45 +1,101 @@
<?xml version="1.0"?>
<llsd>
<map>
- <key>help</key>
+ <!-- Please insert new keys in alphabetical order. -->
+ <key>analyzeperformance</key>
<map>
<key>desc</key>
- <string>display this help message</string>
+ <string>When used in conjunction with logperformance, analyzes result of log against baseline.</string>
+ <key>map-to</key>
+ <string>AnalyzePerformance</string>
+ </map>
- <key>short</key>
- <string>h</string>
+ <key>autologin</key>
+ <map>
+ <key>desc</key>
+ <string>log in as last saved user</string>
+ <key>map-to</key>
+ <string>AutoLogin</string>
</map>
- <key>port</key>
+ <key>channel</key>
<map>
<key>count</key>
<integer>1</integer>
- <key>map-to</key>
- <string>UserConnectionPort</string>
+ <!-- Special case. Not mapped to a setting. -->
</map>
- <key>drop</key>
+ <key>console</key>
<map>
<key>count</key>
<integer>1</integer>
<key>map-to</key>
- <string>PacketDropPercentage</string>
+ <string>ShowConsoleWindow</string>
</map>
- <key>inbw</key>
+ <key>cooperative</key>
<map>
+ <key>desc</key>
+ <string>Yield some idle time to local host.</string>
<key>count</key>
<integer>1</integer>
<key>map-to</key>
- <string>InBandwidth</string>
+ <string>YieldTime</string>
</map>
- <key>outbw</key>
+ <key>crashonstartup</key>
+ <map>
+ <key>desc</key>
+ <string>Crashes on startup. For QA use.</string>
+ <key>map-to</key>
+ <string>CrashOnStartup</string>
+ </map>
+
+ <key>debugsession</key>
+ <map>
+ <key>desc</key>
+ <string>Run as if RenderDebugGL is TRUE, but log errors until end of session.</string>
+ <key>map-to</key>
+ <string>DebugSession</string>
+ </map>
+
+ <key>debugviews</key>
+ <map>
+ <key>map-to</key>
+ <string>DebugViews</string>
+ </map>
+
+ <key>disablecrashlogger</key>
+ <map>
+ <key>desc</key>
+ <string>Disables the crash logger and lets the OS handle crashes</string>
+ <key>map-to</key>
+ <string>DisableCrashLogger</string>
+ </map>
+
+ <key>drop</key>
<map>
<key>count</key>
<integer>1</integer>
<key>map-to</key>
- <string>OutBandwidth</string>
+ <string>PacketDropPercentage</string>
+ </map>
+
+ <key>god</key>
+ <map>
+ <key>desc</key>
+ <string>Log in a god if you have god access.</string>
+ <key>map-to</key>
+ <string>ConnectAsGod</string>
+ </map>
+
+ <key>graphicslevel</key>
+ <map>
+ <key>desc</key>
+ <string>Set the detail level.
+0 - low, 1 - medium, 2 - high, 3 - ultra</string>
+ <key>count</key>
+ <integer>1</integer>
</map>
<key>grid</key>
@@ -52,16 +108,13 @@
<string>CmdLineGridChoice</string>
</map>
- <key>loginuri</key>
+ <key>help</key>
<map>
<key>desc</key>
- <string>login server and CGI script to use</string>
- <key>count</key>
- <integer>1</integer>
- <key>compose</key>
- <boolean>true</boolean>
- <key>map-to</key>
- <string>CmdLineLoginURI</string>
+ <string>display this help message</string>
+
+ <key>short</key>
+ <string>h</string>
</map>
<key>helperuri</key>
@@ -74,44 +127,73 @@
<string>CmdLineHelperURI</string>
</map>
- <key>debugviews</key>
+ <key>ignorepixeldepth</key>
<map>
+ <key>desc</key>
+ <string>Ignore pixel depth settings.</string>
<key>map-to</key>
- <string>DebugViews</string>
+ <string>IgnorePixelDepth</string>
</map>
- <key>skin</key>
+ <key>inbw</key>
+ <map>
+ <key>count</key>
+ <integer>1</integer>
+ <key>map-to</key>
+ <string>InBandwidth</string>
+ </map>
+
+ <key>leap</key>
<map>
<key>desc</key>
- <string>ui/branding skin folder to use</string>
+ <string>command line to run an LLSD Event API Plugin</string>
<key>count</key>
<integer>1</integer>
+ <!-- you can specify multiple such plugins -->
+ <key>compose</key>
+ <boolean>true</boolean>
<key>map-to</key>
- <string>SkinFolder</string>
+ <string>LeapCommand</string>
</map>
- <key>autologin</key>
+ <key>logfile</key>
+ <map>
+ <key>count</key>
+ <integer>1</integer>
+ <key>map-to</key>
+ <string>UserLogFile</string>
+ </map>
+
+ <key>login</key>
<map>
<key>desc</key>
- <string>log in as last saved user</string>
+ <string>3 tokens: first, last and password</string>
+ <key>count</key>
+ <integer>3</integer>
<key>map-to</key>
- <string>AutoLogin</string>
+ <string>UserLoginInfo</string>
</map>
- <key>quitafter</key>
+ <key>loginpage</key>
<map>
+ <key>desc</key>
+ <string>Login authentication page to use.</string>
<key>count</key>
<integer>1</integer>
<key>map-to</key>
- <string>QuitAfterSeconds</string>
+ <string>LoginPage</string>
</map>
- <key>logperformance</key>
+ <key>loginuri</key>
<map>
<key>desc</key>
- <string>Log performance metrics for benchmarking</string>
+ <string>login server and CGI script to use</string>
+ <key>count</key>
+ <integer>1</integer>
+ <key>compose</key>
+ <boolean>true</boolean>
<key>map-to</key>
- <string>LogPerformance</string>
+ <string>CmdLineLoginURI</string>
</map>
<key>logmetrics</key>
@@ -123,29 +205,35 @@
<key>map-to</key>
<string>LogMetrics</string>
</map>
-
- <key>analyzeperformance</key>
+
+ <key>logperformance</key>
<map>
<key>desc</key>
- <string>When used in conjunction with logperformance, analyzes result of log against baseline.</string>
+ <string>Log performance metrics for benchmarking</string>
<key>map-to</key>
- <string>AnalyzePerformance</string>
+ <string>LogPerformance</string>
</map>
- <key>debugsession</key>
+ <key>multiple</key>
<map>
<key>desc</key>
- <string>Run as if RenderDebugGL is TRUE, but log errors until end of session.</string>
+ <string>Allow multiple viewers.</string>
<key>map-to</key>
- <string>DebugSession</string>
+ <string>AllowMultipleViewers</string>
</map>
- <key>replaysession</key>
+ <key>noaudio</key>
+ <map>
+ <key>map-to</key>
+ <string>NoAudio</string>
+ </map>
+
+ <key>noinvlib</key>
<map>
<key>desc</key>
- <string>After login, replay last recorded session and quit.</string>
+ <string>Do not request the inventory library.</string>
<key>map-to</key>
- <string>ReplaySession</string>
+ <string>NoInventoryLibrary</string>
</map>
<key>nonotifications</key>
@@ -156,22 +244,10 @@
<string>IgnoreAllNotifications</string>
</map>
- <key>rotate</key>
- <map>
- <key>map-to</key>
- <string>RotateRight</string>
- </map>
-
- <key>noaudio</key>
- <map>
- <key>map-to</key>
- <string>NoAudio</string>
- </map>
-
- <key>nosound</key>
+ <key>nopreload</key>
<map>
<key>map-to</key>
- <string>NoAudio</string>
+ <string>NoPreload</string>
</map>
<key>noprobe</key>
@@ -186,151 +262,134 @@
<string>NoQuickTime</string>
</map>
- <key>nopreload</key>
+ <key>nosound</key>
<map>
<key>map-to</key>
- <string>NoPreload</string>
+ <string>NoAudio</string>
</map>
- <key>purge</key>
+ <key>no-verify-ssl-cert</key>
<map>
- <key>desc</key>
- <string>Delete files in the cache.</string>
<key>map-to</key>
- <string>PurgeCacheOnNextStartup</string>
+ <string>NoVerifySSLCert</string>
</map>
- <key>noinvlib</key>
+ <key>novoice</key>
<map>
<key>desc</key>
- <string>Do not request the inventory library.</string>
+ <string>Disable voice.</string>
<key>map-to</key>
- <string>NoInventoryLibrary</string>
+ <string>CmdLineDisableVoice</string>
</map>
- <key>logfile</key>
+ <key>outbw</key>
<map>
<key>count</key>
<integer>1</integer>
<key>map-to</key>
- <string>UserLogFile</string>
+ <string>OutBandwidth</string>
</map>
- <key>graphicslevel</key>
+ <key>port</key>
<map>
- <key>desc</key>
- <string>Set the detail level.
-0 - low, 1 - medium, 2 - high, 3 - ultra</string>
<key>count</key>
<integer>1</integer>
+ <key>map-to</key>
+ <string>UserConnectionPort</string>
</map>
- <key>setdefault</key>
+ <key>purge</key>
<map>
<key>desc</key>
- <string>specify the value of a particular configuration variable which can be overridden by settings.xml.</string>
- <key>count</key>
- <integer>2</integer>
- <!-- Special case. Mapped to settings procedurally. -->
+ <string>Delete files in the cache.</string>
+ <key>map-to</key>
+ <string>PurgeCacheOnNextStartup</string>
</map>
- <key>set</key>
+ <key>qa</key>
<map>
<key>desc</key>
- <string>specify the value of a particular configuration variable that overrides all other settings.</string>
- <key>count</key>
- <integer>2</integer>
- <key>compose</key>
- <boolean>true</boolean>
- <!-- Special case. Mapped to settings procedurally. -->
+ <string>Activated debugging menu in Advanced Settings.</string>
+ <key>map-to</key>
+ <string>QAMode</string>
</map>
- <key>settings</key>
+ <key>quitafter</key>
<map>
- <key>desc</key>
- <string>Specify the filename of a configuration file.</string>
<key>count</key>
<integer>1</integer>
- <!-- Special case. Mapped to settings procedurally. -->
+ <key>map-to</key>
+ <string>QuitAfterSeconds</string>
</map>
-
- <key>sessionsettings</key>
+
+ <key>replaysession</key>
<map>
<key>desc</key>
- <string>Specify the filename of a configuration file that contains temporary per-session configuration overrides.</string>
- <key>count</key>
- <integer>1</integer>
- <!-- Special case. Mapped to settings procedurally. -->
+ <string>After login, replay last recorded session and quit.</string>
+ <key>map-to</key>
+ <string>ReplaySession</string>
</map>
- <key>usersessionsettings</key>
- <map>
- <key>desc</key>
- <string>Specify the filename of a configuration file that contains temporary per-session configuration user overrides.</string>
- <key>count</key>
- <integer>1</integer>
- <!-- Special case. Mapped to settings procedurally. -->
- </map>
-
- <key>login</key>
+ <key>rotate</key>
<map>
- <key>desc</key>
- <string>3 tokens: first, last and password</string>
- <key>count</key>
- <integer>3</integer>
<key>map-to</key>
- <string>UserLoginInfo</string>
+ <string>RotateRight</string>
</map>
- <key>god</key>
+ <key>safe</key>
<map>
<key>desc</key>
- <string>Log in a god if you have god access.</string>
+ <string>Reset preferences, run in safe mode.</string>
<key>map-to</key>
- <string>ConnectAsGod</string>
+ <string>SafeMode</string>
</map>
- <key>console</key>
+ <key>sessionsettings</key>
<map>
+ <key>desc</key>
+ <string>Specify the filename of a configuration file that contains temporary per-session configuration overrides.</string>
<key>count</key>
<integer>1</integer>
- <key>map-to</key>
- <string>ShowConsoleWindow</string>
+ <!-- Special case. Mapped to settings procedurally. -->
</map>
- <key>safe</key>
+ <key>set</key>
<map>
<key>desc</key>
- <string>Reset preferences, run in safe mode.</string>
- <key>map-to</key>
- <string>SafeMode</string>
+ <string>specify the value of a particular configuration variable that overrides all other settings.</string>
+ <key>count</key>
+ <integer>2</integer>
+ <key>compose</key>
+ <boolean>true</boolean>
+ <!-- Special case. Mapped to settings procedurally. -->
</map>
- <key>multiple</key>
+ <key>setdefault</key>
<map>
<key>desc</key>
- <string>Allow multiple viewers.</string>
- <key>map-to</key>
- <string>AllowMultipleViewers</string>
+ <string>specify the value of a particular configuration variable which can be overridden by settings.xml.</string>
+ <key>count</key>
+ <integer>2</integer>
+ <!-- Special case. Mapped to settings procedurally. -->
</map>
- <key>novoice</key>
+ <key>settings</key>
<map>
<key>desc</key>
- <string>Disable voice.</string>
- <key>map-to</key>
- <string>CmdLineDisableVoice</string>
+ <string>Specify the filename of a configuration file.</string>
+ <key>count</key>
+ <integer>1</integer>
+ <!-- Special case. Mapped to settings procedurally. -->
</map>
- <key>url</key>
+ <key>skin</key>
<map>
<key>desc</key>
- <string>Startup location</string>
+ <string>ui/branding skin folder to use</string>
<key>count</key>
<integer>1</integer>
- <key>last_option</key>
- <boolean>true</boolean>
- <!-- Special case. Not mapped to a setting. -->
+ <key>map-to</key>
+ <string>SkinFolder</string>
</map>
<key>slurl</key>
@@ -346,69 +405,24 @@
<!-- Special case. Not mapped to a setting. -->
</map>
- <key>ignorepixeldepth</key>
- <map>
- <key>desc</key>
- <string>Ignore pixel depth settings.</string>
- <key>map-to</key>
- <string>IgnorePixelDepth</string>
- </map>
-
- <key>cooperative</key>
+ <key>url</key>
<map>
<key>desc</key>
- <string>Yield some idle time to local host.</string>
- <key>count</key>
- <integer>1</integer>
- <key>map-to</key>
- <string>YieldTime</string>
- </map>
-
- <key>no-verify-ssl-cert</key>
- <map>
- <key>map-to</key>
- <string>NoVerifySSLCert</string>
- </map>
-
- <key>channel</key>
- <map>
+ <string>Startup location</string>
<key>count</key>
<integer>1</integer>
+ <key>last_option</key>
+ <boolean>true</boolean>
<!-- Special case. Not mapped to a setting. -->
</map>
- <key>loginpage</key>
+ <key>usersessionsettings</key>
<map>
<key>desc</key>
- <string>Login authentication page to use.</string>
+ <string>Specify the filename of a configuration file that contains temporary per-session configuration user overrides.</string>
<key>count</key>
<integer>1</integer>
- <key>map-to</key>
- <string>LoginPage</string>
- </map>
-
- <key>qa</key>
- <map>
- <key>desc</key>
- <string>Activated debugging menu in Advanced Settings.</string>
- <key>map-to</key>
- <string>QAMode</string>
- </map>
-
- <key>crashonstartup</key>
- <map>
- <key>desc</key>
- <string>Crashes on startup. For QA use.</string>
- <key>map-to</key>
- <string>CrashOnStartup</string>
- </map>
-
- <key>disablecrashlogger</key>
- <map>
- <key>desc</key>
- <string>Disables the crash logger and lets the OS handle crashes</string>
- <key>map-to</key>
- <string>DisableCrashLogger</string>
+ <!-- Special case. Mapped to settings procedurally. -->
</map>
</map>
</llsd>
diff --git a/indra/newview/app_settings/logcontrol.xml b/indra/newview/app_settings/logcontrol.xml
index a76eb3cd37..64122bbb6c 100644
--- a/indra/newview/app_settings/logcontrol.xml
+++ b/indra/newview/app_settings/logcontrol.xml
@@ -20,7 +20,7 @@
<key>tags</key>
<array>
<string>AppInit</string>
- <string>Capabilities</string>
+ <string>Capabilities</string>
<string>SystemInfo</string>
<string>TextureCache</string>
<string>AppCache</string>
@@ -42,8 +42,10 @@
</array>
<key>tags</key>
<array>
- <!-- sample entry for debugging a specific item -->
-<!-- <string>Voice</string> -->
+ <!-- sample entry for debugging specific items
+ <string>Avatar</string>
+ <string>Voice</string>
+ -->
</array>
</map>
</array>
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 05c05b9393..c9b4de0140 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -335,17 +335,6 @@
<key>Value</key>
<integer>1</integer>
</map>
- <key>AuditTexture</key>
- <map>
- <key>Comment</key>
- <string>Enable texture auditting.</string>
- <key>Persist</key>
- <integer>1</integer>
- <key>Type</key>
- <string>Boolean</string>
- <key>Value</key>
- <integer>0</integer>
- </map>
<key>AutoAcceptNewInventory</key>
<map>
<key>Comment</key>
@@ -1936,7 +1925,7 @@
<key>Type</key>
<string>Boolean</string>
<key>Value</key>
- <integer>0</integer>
+ <integer>1</integer>
</map>
<key>DebugBeaconLineWidth</key>
<map>
@@ -4601,6 +4590,17 @@
<key>Value</key>
<integer>0</integer>
</map>
+ <key>LeapCommand</key>
+ <map>
+ <key>Comment</key>
+ <string>Zero or more command lines to run LLSD Event API Plugin programs.</string>
+ <key>Persist</key>
+ <integer>0</integer>
+ <key>Type</key>
+ <string>LLSD</string>
+ <key>Value</key>
+ <array />
+ </map>
<key>LSLFindCaseInsensitivity</key>
<map>
<key>Comment</key>
@@ -7164,7 +7164,7 @@
<key>QAModeEventHostPort</key>
<map>
<key>Comment</key>
- <string>Port on which lleventhost should listen</string>
+ <string>DEPRECATED: Port on which lleventhost should listen</string>
<key>Persist</key>
<integer>0</integer>
<key>Type</key>
@@ -7183,6 +7183,17 @@
<key>Value</key>
<integer>-1</integer>
</map>
+ <key>QAModeMetrics</key>
+ <map>
+ <key>Comment</key>
+ <string>"Enables QA features (logging, faster cycling) for metrics collector"</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Boolean</string>
+ <key>Value</key>
+ <integer>0</integer>
+ </map>
<key>QuietSnapshotsToDisk</key>
<map>
<key>Comment</key>
@@ -7631,6 +7642,17 @@
<key>Value</key>
<integer>1</integer>
</map>
+ <key>RenderCompressTextures</key>
+ <map>
+ <key>Comment</key>
+ <string>Enable texture compression on OpenGL 3.0 and later implementations (EXPERIMENTAL, requires restart)</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Boolean</string>
+ <key>Value</key>
+ <integer>0</integer>
+ </map>
<key>RenderPerformanceTest</key>
<map>
<key>Comment</key>
@@ -9123,28 +9145,19 @@
<key>Value</key>
<integer>0</integer>
</map>
- <key>RenderUseShaderLOD</key>
- <map>
- <key>Comment</key>
- <string>Whether we want to have different shaders for LOD</string>
- <key>Persist</key>
- <integer>1</integer>
- <key>Type</key>
- <string>Boolean</string>
- <key>Value</key>
- <integer>1</integer>
- </map>
- <key>RenderUseShaderNearParticles</key>
- <map>
- <key>Comment</key>
- <string>Whether we want to use shaders on near particles</string>
- <key>Persist</key>
- <integer>1</integer>
- <key>Type</key>
- <string>Boolean</string>
- <key>Value</key>
- <integer>0</integer>
- </map>
+
+ <key>RenderAutoHideSurfaceAreaLimit</key>
+ <map>
+ <key>Comment</key>
+ <string>Maximum surface area of a set of proximal objects inworld before automatically hiding geometry to prevent system overload.</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>F32</string>
+ <key>Value</key>
+ <integer>0</integer>
+ </map>
+
<key>RenderVBOEnable</key>
<map>
<key>Comment</key>
@@ -10664,6 +10677,39 @@
<key>Value</key>
<real>20.0</real>
</map>
+ <key>TexelPixelRatio</key>
+ <map>
+ <key>Comment</key>
+ <string>texel pixel ratio = texel / pixel</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>F32</string>
+ <key>Value</key>
+ <real>1.0</real>
+ </map>
+ <key>TextureCameraMotionThreshold</key>
+ <map>
+ <key>Comment</key>
+ <string>If the overall motion is lower than this value, textures will be loaded faster</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>F32</string>
+ <key>Value</key>
+ <real>0.2</real>
+ </map>
+ <key>TextureCameraMotionBoost</key>
+ <map>
+ <key>Comment</key>
+ <string>Progressive discard level decrement when the camera is still</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>S32</string>
+ <key>Value</key>
+ <integer>3</integer>
+ </map>
<key>TextureDecodeDisabled</key>
<map>
<key>Comment</key>
@@ -10697,6 +10743,17 @@
<key>Value</key>
<integer>0</integer>
</map>
+ <key>TextureFetchDebuggerEnabled</key>
+ <map>
+ <key>Comment</key>
+ <string>Enable the texture fetching debugger if set</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Boolean</string>
+ <key>Value</key>
+ <integer>0</integer>
+ </map>
<key>TextureLoadFullRes</key>
<map>
<key>Comment</key>
@@ -10719,6 +10776,17 @@
<key>Value</key>
<integer>0</integer>
</map>
+ <key>TextureNewByteRange</key>
+ <map>
+ <key>Comment</key>
+ <string>Use the new more accurate byte range computation for j2c discard levels</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Boolean</string>
+ <key>Value</key>
+ <integer>1</integer>
+ </map>
<key>TexturePickerShowFolders</key>
<map>
<key>Comment</key>
@@ -10741,6 +10809,17 @@
<key>Value</key>
<integer>2</integer>
</map>
+ <key>TextureReverseByteRange</key>
+ <map>
+ <key>Comment</key>
+ <string>Minimal percent of the optimal byte range allowed to render a given discard level</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>S32</string>
+ <key>Value</key>
+ <integer>50</integer>
+ </map>
<key>ThrottleBandwidthKBPS</key>
<map>
<key>Comment</key>
diff --git a/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskF.glsl b/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskF.glsl
index cf8cf8364a..bced4a5577 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskF.glsl
@@ -29,11 +29,11 @@ out vec4 frag_color;
#define frag_color gl_FragColor
#endif
-uniform float minimum_alpha;
-
uniform sampler2D diffuseMap;
-VARYING vec4 post_pos;
+VARYING float pos_zd2;
+VARYING float pos_w;
+VARYING float target_pos_x;
VARYING vec4 vertex_color;
VARYING vec2 vary_texcoord0;
@@ -41,12 +41,20 @@ void main()
{
float alpha = diffuseLookup(vary_texcoord0.xy).a * vertex_color.a;
- if (alpha < minimum_alpha)
+ if (alpha < 0.05) // treat as totally transparent
{
discard;
}
+ if (alpha < 0.88) // treat as semi-transparent
+ {
+ if (fract(0.5*floor(target_pos_x / pos_w )) < 0.25)
+ {
+ discard;
+ }
+ }
+
frag_color = vec4(1,1,1,1);
- gl_FragDepth = max(post_pos.z/post_pos.w*0.5+0.5, 0.0);
+ gl_FragDepth = max(pos_zd2/pos_w+0.5, 0.0);
}
diff --git a/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskV.glsl b/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskV.glsl
index 7d3b06c56e..c1f2d90712 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskV.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/shadowAlphaMaskV.glsl
@@ -25,12 +25,15 @@
uniform mat4 texture_matrix0;
uniform mat4 modelview_projection_matrix;
+uniform float shadow_target_width;
ATTRIBUTE vec3 position;
ATTRIBUTE vec4 diffuse_color;
ATTRIBUTE vec2 texcoord0;
-VARYING vec4 post_pos;
+VARYING float pos_zd2;
+VARYING float pos_w;
+VARYING float target_pos_x;
VARYING vec4 vertex_color;
VARYING vec2 vary_texcoord0;
@@ -39,8 +42,11 @@ void passTextureIndex();
void main()
{
//transform vertex
- vec4 pos = modelview_projection_matrix*vec4(position.xyz, 1.0);
- post_pos = pos;
+ vec4 pre_pos = vec4(position.xyz, 1.0);
+ vec4 pos = modelview_projection_matrix * pre_pos;
+ target_pos_x = 0.5 * (shadow_target_width - 1.0) * pos.x;
+ pos_w = pos.w;
+ pos_zd2 = pos.z * 0.5;
gl_Position = vec4(pos.x, pos.y, pos.w*0.5, pos.w);
diff --git a/indra/newview/app_settings/shaders/class2/deferred/alphaF.glsl b/indra/newview/app_settings/shaders/class2/deferred/alphaF.glsl
index 08f6ec63fe..8db4cb58cf 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/alphaF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/alphaF.glsl
@@ -58,20 +58,22 @@ uniform float shadow_bias;
uniform mat4 inv_proj;
-float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc)
{
stc.xyz /= stc.w;
stc.z += shadow_bias;
+
+ stc.x = floor(stc.x + fract(stc.y*12345)); // add some chaotic jitter to X sample pos according to Y to disguise the snapping going on here
float cs = shadow2DRect(shadowMap, stc.xyz).x;
float shadow = cs;
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, -scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, -scl, 0.0)).x, cs);
-
- return shadow/5.0;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(1.0, -1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-1.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-2.0, -1.5, 0.0)).x;
+
+ return shadow*0.2;
}
@@ -101,7 +103,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap3, lpos, 0.25)*w;
+ shadow += pcfShadow(shadowMap3, lpos)*w;
weight += w;
shadow += max((pos.z+shadow_clip.z)/(shadow_clip.z-shadow_clip.w)*2.0-1.0, 0.0);
}
@@ -114,7 +116,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.y, 0.0)/transition_domain.y;
w -= max(near_split.z-spos.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap2, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap2, lpos)*w;
weight += w;
}
@@ -126,7 +128,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.x, 0.0)/transition_domain.x;
w -= max(near_split.y-spos.z, 0.0)/transition_domain.y;
- shadow += pcfShadow(shadowMap1, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap1, lpos)*w;
weight += w;
}
@@ -138,7 +140,7 @@ void main()
float w = 1.0;
w -= max(near_split.x-spos.z, 0.0)/transition_domain.x;
- shadow += pcfShadow(shadowMap0, lpos, 1.0)*w;
+ shadow += pcfShadow(shadowMap0, lpos)*w;
weight += w;
}
diff --git a/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedF.glsl b/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedF.glsl
index aae6a070e2..33958a5010 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedF.glsl
@@ -71,20 +71,22 @@ vec4 getPosition(vec2 pos_screen)
return pos;
}
-float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc)
{
stc.xyz /= stc.w;
stc.z += shadow_bias;
+
+ stc.x = floor(stc.x + fract(stc.y*12345)); // add some chaotic jitter to X sample pos according to Y to disguise the snapping going on here
float cs = shadow2DRect(shadowMap, stc.xyz).x;
float shadow = cs;
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, -scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, -scl, 0.0)).x, cs);
-
- return shadow/5.0;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(1.0, -1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-1.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-2.0, -1.5, 0.0)).x;
+
+ return shadow*0.2;
}
@@ -114,7 +116,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap3, lpos, 0.25)*w;
+ shadow += pcfShadow(shadowMap3, lpos)*w;
weight += w;
shadow += max((pos.z+shadow_clip.z)/(shadow_clip.z-shadow_clip.w)*2.0-1.0, 0.0);
}
@@ -127,7 +129,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.y, 0.0)/transition_domain.y;
w -= max(near_split.z-spos.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap2, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap2, lpos)*w;
weight += w;
}
@@ -139,7 +141,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.x, 0.0)/transition_domain.x;
w -= max(near_split.y-spos.z, 0.0)/transition_domain.y;
- shadow += pcfShadow(shadowMap1, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap1, lpos)*w;
weight += w;
}
@@ -151,7 +153,7 @@ void main()
float w = 1.0;
w -= max(near_split.x-spos.z, 0.0)/transition_domain.x;
- shadow += pcfShadow(shadowMap0, lpos, 1.0)*w;
+ shadow += pcfShadow(shadowMap0, lpos)*w;
weight += w;
}
diff --git a/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedNoColorF.glsl b/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedNoColorF.glsl
index 931577359e..ba6f3ace53 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedNoColorF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/alphaNonIndexedNoColorF.glsl
@@ -70,20 +70,22 @@ vec4 getPosition(vec2 pos_screen)
return pos;
}
-float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc)
{
stc.xyz /= stc.w;
stc.z += shadow_bias;
+
+ stc.x = floor(stc.x + fract(stc.y*12345)); // add some chaotic jitter to X sample pos according to Y to disguise the snapping going on here
float cs = shadow2DRect(shadowMap, stc.xyz).x;
float shadow = cs;
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(scl, -scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, scl, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-scl, -scl, 0.0)).x, cs);
-
- return shadow/5.0;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(1.0, -1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-1.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-2.0, -1.5, 0.0)).x;
+
+ return shadow*0.2;
}
@@ -113,7 +115,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap3, lpos, 0.25)*w;
+ shadow += pcfShadow(shadowMap3, lpos)*w;
weight += w;
shadow += max((pos.z+shadow_clip.z)/(shadow_clip.z-shadow_clip.w)*2.0-1.0, 0.0);
}
@@ -126,7 +128,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.y, 0.0)/transition_domain.y;
w -= max(near_split.z-spos.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap2, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap2, lpos)*w;
weight += w;
}
@@ -138,7 +140,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.x, 0.0)/transition_domain.x;
w -= max(near_split.y-spos.z, 0.0)/transition_domain.y;
- shadow += pcfShadow(shadowMap1, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap1, lpos)*w;
weight += w;
}
@@ -150,7 +152,7 @@ void main()
float w = 1.0;
w -= max(near_split.x-spos.z, 0.0)/transition_domain.x;
- shadow += pcfShadow(shadowMap0, lpos, 1.0)*w;
+ shadow += pcfShadow(shadowMap0, lpos)*w;
weight += w;
}
diff --git a/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl b/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl
index 8c4ccf9cb3..db3d760359 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl
@@ -78,42 +78,42 @@ vec4 getPosition(vec2 pos_screen)
return pos;
}
-float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl, vec2 pos_screen)
{
stc.xyz /= stc.w;
stc.z += shadow_bias*scl;
-
+
+ stc.x = floor(stc.x + fract(pos_screen.y*0.666666666)); // add some jitter to X sample pos according to Y to disguise the snapping going on here
+
float cs = shadow2DRect(shadowMap, stc.xyz).x;
float shadow = cs;
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(1.5, 1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(1.5, -1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-1.5, 1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-1.5, -1.5, 0.0)).x, cs);
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(1.0, -1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-1.0, -1.5, 0.0)).x;
- return shadow/5.0;
-
- //return shadow;
+ return shadow*0.2;
}
-float pcfShadow(sampler2DShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DShadow shadowMap, vec4 stc, float scl, vec2 pos_screen)
{
stc.xyz /= stc.w;
stc.z += spot_shadow_bias*scl;
+ stc.x = floor(proj_shadow_res.x * stc.x + fract(pos_screen.y*0.666666666)) / proj_shadow_res.x; // snap
float cs = shadow2D(shadowMap, stc.xyz).x;
float shadow = cs;
- vec2 off = 1.5/proj_shadow_res;
+ vec2 off = 1.0/proj_shadow_res;
+ off.y *= 1.5;
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(off.x, off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(off.x, -off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(-off.x, off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(-off.x, -off.y, 0.0)).x, cs);
-
- return shadow/5.0;
-
- //return shadow;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(off.x*2.0, off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(off.x, -off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(-off.x, off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(-off.x*2.0, -off.y, 0.0)).x;
+
+ return shadow*0.2;
}
void main()
@@ -166,7 +166,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap3, lpos, 0.25)*w;
+ shadow += pcfShadow(shadowMap3, lpos, 0.25, pos_screen)*w;
weight += w;
shadow += max((pos.z+shadow_clip.z)/(shadow_clip.z-shadow_clip.w)*2.0-1.0, 0.0);
}
@@ -179,7 +179,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.y, 0.0)/transition_domain.y;
w -= max(near_split.z-spos.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap2, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap2, lpos, 0.5, pos_screen)*w;
weight += w;
}
@@ -191,7 +191,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.x, 0.0)/transition_domain.x;
w -= max(near_split.y-spos.z, 0.0)/transition_domain.y;
- shadow += pcfShadow(shadowMap1, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap1, lpos, 0.75, pos_screen)*w;
weight += w;
}
@@ -203,7 +203,7 @@ void main()
float w = 1.0;
w -= max(near_split.x-spos.z, 0.0)/transition_domain.x;
- shadow += pcfShadow(shadowMap0, lpos, 1.0)*w;
+ shadow += pcfShadow(shadowMap0, lpos, 1.0, pos_screen)*w;
weight += w;
}
@@ -237,11 +237,11 @@ void main()
//spotlight shadow 1
vec4 lpos = shadow_matrix[4]*spos;
- frag_color[2] = pcfShadow(shadowMap4, lpos, 0.8);
+ frag_color[2] = pcfShadow(shadowMap4, lpos, 0.8, pos_screen);
//spotlight shadow 2
lpos = shadow_matrix[5]*spos;
- frag_color[3] = pcfShadow(shadowMap5, lpos, 0.8);
+ frag_color[3] = pcfShadow(shadowMap5, lpos, 0.8, pos_screen);
//frag_color.rgb = pos.xyz;
//frag_color.b = shadow;
diff --git a/indra/newview/app_settings/shaders/class2/deferred/sunLightSSAOF.glsl b/indra/newview/app_settings/shaders/class2/deferred/sunLightSSAOF.glsl
index 02075a7687..dfe108eb01 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/sunLightSSAOF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/sunLightSSAOF.glsl
@@ -90,7 +90,7 @@ vec2 getKern(int i)
kern[5] = vec2(-0.7071, -0.7071) * 0.750*0.750;
kern[6] = vec2(-0.7071, 0.7071) * 0.875*0.875;
kern[7] = vec2(0.7071, -0.7071) * 1.000*1.000;
-
+
return kern[i];
}
@@ -139,42 +139,42 @@ float calcAmbientOcclusion(vec4 pos, vec3 norm)
return min(ret, 1.0);
}
-float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DRectShadow shadowMap, vec4 stc, float scl, vec2 pos_screen)
{
stc.xyz /= stc.w;
stc.z += shadow_bias*scl;
+
+ stc.x = floor(stc.x + fract(pos_screen.y*0.666666666));
float cs = shadow2DRect(shadowMap, stc.xyz).x;
float shadow = cs;
-
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(1.5, 1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(1.5, -1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-1.5, 1.5, 0.0)).x, cs);
- shadow += max(shadow2DRect(shadowMap, stc.xyz+vec3(-1.5, -1.5, 0.0)).x, cs);
-
- return shadow/5.0;
- //return shadow;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(2.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(1.0, -1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-1.0, 1.5, 0.0)).x;
+ shadow += shadow2DRect(shadowMap, stc.xyz+vec3(-2.0, -1.5, 0.0)).x;
+
+ return shadow*0.2;
}
-float pcfShadow(sampler2DShadow shadowMap, vec4 stc, float scl)
+float pcfShadow(sampler2DShadow shadowMap, vec4 stc, float scl, vec2 pos_screen)
{
stc.xyz /= stc.w;
stc.z += spot_shadow_bias*scl;
+ stc.x = floor(proj_shadow_res.x * stc.x + fract(pos_screen.y*0.666666666)) / proj_shadow_res.x; // snap
float cs = shadow2D(shadowMap, stc.xyz).x;
float shadow = cs;
- vec2 off = 1.5/proj_shadow_res;
+ vec2 off = 1.0/proj_shadow_res;
+ off.y *= 1.5;
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(off.x, off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(off.x, -off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(-off.x, off.y, 0.0)).x, cs);
- shadow += max(shadow2D(shadowMap, stc.xyz+vec3(-off.x, -off.y, 0.0)).x, cs);
-
- return shadow/5.0;
-
- //return shadow;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(off.x*2.0, off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(off.x, -off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(-off.x, off.y, 0.0)).x;
+ shadow += shadow2D(shadowMap, stc.xyz+vec3(-off.x*2.0, -off.y, 0.0)).x;
+
+ return shadow*0.2;
}
void main()
@@ -227,7 +227,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap3, lpos, 0.25)*w;
+ shadow += pcfShadow(shadowMap3, lpos, 0.25, pos_screen)*w;
weight += w;
shadow += max((pos.z+shadow_clip.z)/(shadow_clip.z-shadow_clip.w)*2.0-1.0, 0.0);
}
@@ -240,7 +240,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.y, 0.0)/transition_domain.y;
w -= max(near_split.z-spos.z, 0.0)/transition_domain.z;
- shadow += pcfShadow(shadowMap2, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap2, lpos, 0.5, pos_screen)*w;
weight += w;
}
@@ -252,7 +252,7 @@ void main()
float w = 1.0;
w -= max(spos.z-far_split.x, 0.0)/transition_domain.x;
w -= max(near_split.y-spos.z, 0.0)/transition_domain.y;
- shadow += pcfShadow(shadowMap1, lpos, 0.75)*w;
+ shadow += pcfShadow(shadowMap1, lpos, 0.75, pos_screen)*w;
weight += w;
}
@@ -264,7 +264,7 @@ void main()
float w = 1.0;
w -= max(near_split.x-spos.z, 0.0)/transition_domain.x;
- shadow += pcfShadow(shadowMap0, lpos, 1.0)*w;
+ shadow += pcfShadow(shadowMap0, lpos, 1.0, pos_screen)*w;
weight += w;
}
@@ -298,11 +298,11 @@ void main()
//spotlight shadow 1
vec4 lpos = shadow_matrix[4]*spos;
- frag_color[2] = pcfShadow(shadowMap4, lpos, 0.8);
+ frag_color[2] = pcfShadow(shadowMap4, lpos, 0.8, pos_screen);
//spotlight shadow 2
lpos = shadow_matrix[5]*spos;
- frag_color[3] = pcfShadow(shadowMap5, lpos, 0.8);
+ frag_color[3] = pcfShadow(shadowMap5, lpos, 0.8, pos_screen);
//frag_color.rgb = pos.xyz;
//frag_color.b = shadow;
diff --git a/indra/newview/featuretable.txt b/indra/newview/featuretable.txt
index 76bb2b0976..e8a109e661 100644
--- a/indra/newview/featuretable.txt
+++ b/indra/newview/featuretable.txt
@@ -61,6 +61,7 @@ WLSkyDetail 1 128
Disregard128DefaultDrawDistance 1 1
Disregard96DefaultDrawDistance 1 1
RenderTextureMemoryMultiple 1 1.0
+RenderCompressTextures 1 1
RenderShaderLightingMaxLevel 1 3
RenderDeferred 1 1
RenderDeferredSSAO 1 1
@@ -72,6 +73,38 @@ RenderMaxTextureIndex 1 16
//
+// Low Graphics Settings (fixed function)
+//
+list LowFixedFunction
+RenderAnisotropic 1 0
+RenderAvatarCloth 1 0
+RenderAvatarLODFactor 1 0
+RenderAvatarPhysicsLODFactor 1 0
+RenderAvatarMaxVisible 1 3
+RenderAvatarVP 1 0
+RenderFarClip 1 64
+RenderFlexTimeFactor 1 0
+RenderGlowResolutionPow 1 8
+RenderMaxPartCount 1 0
+RenderObjectBump 1 0
+RenderLocalLights 1 0
+RenderReflectionDetail 1 0
+RenderTerrainDetail 1 0
+RenderTerrainLODFactor 1 1
+RenderTransparentWater 1 0
+RenderTreeLODFactor 1 0
+RenderUseImpostors 1 1
+RenderVolumeLODFactor 1 1.125
+VertexShaderEnable 1 0
+WindLightUseAtmosShaders 1 0
+WLSkyDetail 1 48
+RenderDeferred 1 0
+RenderDeferredSSAO 1 0
+RenderShadowDetail 1 0
+RenderFSAASamples 1 0
+
+
+//
// Low Graphics Settings
//
list Low
@@ -94,7 +127,7 @@ RenderTransparentWater 1 0
RenderTreeLODFactor 1 0
RenderUseImpostors 1 1
RenderVolumeLODFactor 1 1.125
-VertexShaderEnable 1 0
+VertexShaderEnable 1 1
WindLightUseAtmosShaders 1 0
WLSkyDetail 1 48
RenderDeferred 1 0
@@ -223,6 +256,12 @@ list Class3
RenderVBOEnable 1 1
//
+// VRAM > 512MB
+//
+list VRAMGT512
+RenderCompressTextures 1 0
+
+//
// No Pixel Shaders available
//
list NoPixelShaders
@@ -302,6 +341,7 @@ RenderMaxTextureIndex 1 1
list Intel
RenderAnisotropic 1 0
RenderVBOEnable 1 0
+RenderFSAASamples 1 0
list GeForce2
RenderAnisotropic 1 0
diff --git a/indra/newview/featuretable_linux.txt b/indra/newview/featuretable_linux.txt
index 5e217e000a..3a0e7e3697 100644
--- a/indra/newview/featuretable_linux.txt
+++ b/indra/newview/featuretable_linux.txt
@@ -61,6 +61,7 @@ WLSkyDetail 1 128
Disregard128DefaultDrawDistance 1 1
Disregard96DefaultDrawDistance 1 1
RenderTextureMemoryMultiple 1 1.0
+RenderCompressTextures 1 1
RenderShaderLightingMaxLevel 1 3
RenderDeferred 1 1
RenderDeferredSSAO 1 1
@@ -69,6 +70,37 @@ RenderFSAASamples 1 16
RenderMaxTextureIndex 1 16
//
+// Low Graphics Settings (fixed function)
+//
+list LowFixedFunction
+RenderAnisotropic 1 0
+RenderAvatarCloth 1 0
+RenderAvatarLODFactor 1 0
+RenderAvatarPhysicsLODFactor 1 0
+RenderAvatarMaxVisible 1 3
+RenderAvatarVP 1 0
+RenderFarClip 1 64
+RenderFlexTimeFactor 1 0
+RenderGlowResolutionPow 1 8
+RenderLocalLights 1 0
+RenderMaxPartCount 1 0
+RenderObjectBump 1 0
+RenderReflectionDetail 1 0
+RenderTerrainDetail 1 0
+RenderTerrainLODFactor 1 1
+RenderTransparentWater 1 0
+RenderTreeLODFactor 1 0
+RenderUseImpostors 1 1
+RenderVolumeLODFactor 1 0.5
+VertexShaderEnable 1 1
+WindLightUseAtmosShaders 1 0
+WLSkyDetail 1 48
+RenderDeferred 1 0
+RenderDeferredSSAO 1 0
+RenderShadowDetail 1 0
+RenderFSAASamples 1 0
+
+//
// Low Graphics Settings
//
list Low
@@ -220,6 +252,12 @@ list Class3
RenderVBOEnable 1 1
//
+// VRAM > 512MB
+//
+list VRAMGT512
+RenderCompressTextures 1 0
+
+//
// No Pixel Shaders available
//
list NoPixelShaders
@@ -291,10 +329,15 @@ RenderObjectBump 0 0
list OpenGLPre15
RenderVBOEnable 1 0
+list OpenGLPre30
+RenderDeferred 0 0
+RenderMaxTextureIndex 1 1
+
list Intel
RenderAnisotropic 1 0
// Avoid some Intel crashes on Linux
RenderCubeMap 0 0
+RenderFSAASamples 1 0
list GeForce2
RenderAnisotropic 1 0
diff --git a/indra/newview/featuretable_mac.txt b/indra/newview/featuretable_mac.txt
index 915a012a39..96362ff4bb 100644
--- a/indra/newview/featuretable_mac.txt
+++ b/indra/newview/featuretable_mac.txt
@@ -61,6 +61,7 @@ WLSkyDetail 1 128
Disregard128DefaultDrawDistance 1 1
Disregard96DefaultDrawDistance 1 1
RenderTextureMemoryMultiple 1 0.5
+RenderCompressTextures 1 1
RenderShaderLightingMaxLevel 1 3
RenderDeferred 1 1
RenderDeferredSSAO 1 1
@@ -71,6 +72,37 @@ RenderFSAASamples 1 16
RenderMaxTextureIndex 1 16
//
+// Low Graphics Settings (fixed function)
+//
+list LowFixedFunction
+RenderAnisotropic 1 0
+RenderAvatarCloth 1 0
+RenderAvatarLODFactor 1 0
+RenderAvatarPhysicsLODFactor 1 0
+RenderAvatarMaxVisible 1 3
+RenderAvatarVP 1 0
+RenderFarClip 1 64
+RenderFlexTimeFactor 1 0
+RenderGlowResolutionPow 1 8
+RenderLocalLights 1 0
+RenderMaxPartCount 1 0
+RenderObjectBump 1 0
+RenderReflectionDetail 1 0
+RenderTerrainDetail 1 0
+RenderTerrainLODFactor 1 1
+RenderTransparentWater 1 0
+RenderTreeLODFactor 1 0
+RenderUseImpostors 1 1
+RenderVolumeLODFactor 1 0.5
+VertexShaderEnable 1 0
+WindLightUseAtmosShaders 1 0
+WLSkyDetail 1 48
+RenderDeferred 1 0
+RenderDeferredSSAO 1 0
+RenderShadowDetail 1 0
+RenderFSAASamples 1 0
+
+//
// Low Graphics Settings
//
list Low
@@ -93,7 +125,7 @@ RenderTransparentWater 1 0
RenderTreeLODFactor 1 0
RenderUseImpostors 1 1
RenderVolumeLODFactor 1 0.5
-VertexShaderEnable 1 0
+VertexShaderEnable 1 1
WindLightUseAtmosShaders 1 0
WLSkyDetail 1 48
RenderDeferred 1 0
@@ -248,6 +280,12 @@ RenderDeferredSSAO 0 0
RenderShadowDetail 0 0
//
+// VRAM > 512MB
+//
+list VRAMGT512
+RenderCompressTextures 1 0
+
+//
// "Default" setups for safe, low, medium, high
//
list safe
@@ -286,6 +324,7 @@ RenderObjectBump 0 0
list OpenGLPre15
RenderVBOEnable 1 0
+
list TexUnit8orLess
RenderDeferredSSAO 0 0
@@ -295,6 +334,7 @@ RenderDeferredSSAO 1 0
list Intel
RenderAnisotropic 1 0
RenderLocalLights 1 0
+RenderFSAASamples 1 0
list GeForce2
RenderAnisotropic 1 0
diff --git a/indra/newview/featuretable_xp.txt b/indra/newview/featuretable_xp.txt
index ae2cf910f2..398a64378e 100644
--- a/indra/newview/featuretable_xp.txt
+++ b/indra/newview/featuretable_xp.txt
@@ -61,6 +61,7 @@ WLSkyDetail 1 128
Disregard128DefaultDrawDistance 1 1
Disregard96DefaultDrawDistance 1 1
RenderTextureMemoryMultiple 1 1.0
+RenderCompressTextures 1 1
RenderShaderLightingMaxLevel 1 3
RenderDeferred 1 0
RenderDeferredSSAO 1 0
@@ -71,6 +72,37 @@ RenderFSAASamples 1 16
RenderMaxTextureIndex 1 16
//
+// Low Graphics Settings (fixed function)
+//
+list LowFixedFunction
+RenderAnisotropic 1 0
+RenderAvatarCloth 1 0
+RenderAvatarLODFactor 1 0
+RenderAvatarPhysicsLODFactor 1 0
+RenderAvatarMaxVisible 1 3
+RenderAvatarVP 1 0
+RenderFarClip 1 64
+RenderFlexTimeFactor 1 0
+RenderGlowResolutionPow 1 8
+RenderLocalLights 1 0
+RenderMaxPartCount 1 0
+RenderObjectBump 1 0
+RenderReflectionDetail 1 0
+RenderTerrainDetail 1 0
+RenderTerrainLODFactor 1 1
+RenderTransparentWater 1 0
+RenderTreeLODFactor 1 0
+RenderUseImpostors 1 1
+RenderVolumeLODFactor 1 0.5
+VertexShaderEnable 1 0
+WindLightUseAtmosShaders 1 0
+WLSkyDetail 1 48
+RenderDeferred 1 0
+RenderDeferredSSAO 1 0
+RenderShadowDetail 1 0
+RenderFSAASamples 1 0
+
+//
// Low Graphics Settings
//
list Low
@@ -93,7 +125,7 @@ RenderTransparentWater 1 0
RenderTreeLODFactor 1 0
RenderUseImpostors 1 1
RenderVolumeLODFactor 1 0.5
-VertexShaderEnable 1 0
+VertexShaderEnable 1 1
WindLightUseAtmosShaders 1 0
WLSkyDetail 1 48
RenderDeferred 1 0
@@ -222,6 +254,12 @@ list Class3
RenderVBOEnable 1 1
//
+// VRAM > 512MB
+//
+list VRAMGT512
+RenderCompressTextures 1 0
+
+//
// No Pixel Shaders available
//
list NoPixelShaders
@@ -299,6 +337,7 @@ RenderMaxTextureIndex 1 1
list Intel
RenderAnisotropic 1 0
RenderVBOEnable 1 0
+RenderFSAASamples 1 0
list GeForce2
RenderAnisotropic 1 0
diff --git a/indra/newview/gpu_table.txt b/indra/newview/gpu_table.txt
index 198e702459..777d54a5c3 100644
--- a/indra/newview/gpu_table.txt
+++ b/indra/newview/gpu_table.txt
@@ -205,6 +205,7 @@ ATI Radeon X800 .*ATI.*Radeon ?X8.* 2 1
ATI Radeon X900 .*ATI.*Radeon ?X9.* 2 1
ATI Radeon Xpress .*ATI.*Radeon Xpress.* 0 1
ATI Rage 128 .*ATI.*Rage 128.* 0 1
+ATI R300 (9700) .*R300.* 1 1
ATI R350 (9800) .*R350.* 1 1
ATI R580 (X1900) .*R580.* 3 1
ATI RC410 (Xpress 200) .*RC410.* 0 0
diff --git a/indra/newview/linux_tools/wrapper.sh b/indra/newview/linux_tools/wrapper.sh
index 283a28a0aa..20936c6460 100755
--- a/indra/newview/linux_tools/wrapper.sh
+++ b/indra/newview/linux_tools/wrapper.sh
@@ -110,22 +110,34 @@ export SAVED_LD_LIBRARY_PATH="${LD_LIBRARY_PATH}"
# fi
#fi
-export SL_ENV='LD_LIBRARY_PATH="`pwd`"/lib:"${LD_LIBRARY_PATH}"'
-export SL_CMD='$LL_WRAPPER bin/do-not-directly-run-secondlife-bin'
-export SL_OPT="`cat etc/gridargs.dat` $@"
-
-# Run the program
-eval ${SL_ENV} ${SL_CMD} ${SL_OPT} || LL_RUN_ERR=runerr
+export LD_LIBRARY_PATH="$PWD/lib:${LD_LIBRARY_PATH}"
+
+# Have to deal specially with gridargs.dat; typical contents look like:
+# --channel "Second Life Developer" --settings settings_developer.xml
+# Simply embedding $(<etc/gridargs.dat) into a command line treats each of
+# Second, Life and Developer as separate args -- no good. We need bash to
+# process quotes using eval.
+# First read it without scanning, then scan that string. Break quoted words
+# into a bash array. Note that if gridargs.dat is empty, or contains only
+# whitespace, the resulting gridargs array will be empty -- zero entries --
+# therefore "${gridargs[@]}" entirely vanishes from the command line below,
+# just as we want.
+eval gridargs=("$(<etc/gridargs.dat)")
+
+# Run the program.
+# Don't quote $LL_WRAPPER because, if empty, it should simply vanish from the
+# command line. But DO quote "$@": preserve separate args as individually
+# quoted. Similar remarks about the contents of gridargs.
+$LL_WRAPPER bin/do-not-directly-run-secondlife-bin "${gridargs[@]}" "$@"
+LL_RUN_ERR=$?
# Handle any resulting errors
-if [ -n "$LL_RUN_ERR" ]; then
- LL_RUN_ERR_MSG=""
- if [ "$LL_RUN_ERR" = "runerr" ]; then
- # generic error running the binary
- echo '*** Bad shutdown. ***'
- if [ "`uname -m`" = "x86_64" ]; then
- echo
- cat << EOFMARKER
+if [ $LL_RUN_ERR -ne 0 ]; then
+ # generic error running the binary
+ echo '*** Bad shutdown ($LL_RUN_ERR). ***'
+ if [ "$(uname -m)" = "x86_64" ]; then
+ echo
+ cat << EOFMARKER
You are running the Second Life Viewer on a x86_64 platform. The
most common problems when launching the Viewer (particularly
'bin/do-not-directly-run-secondlife-bin: not found' and 'error while
@@ -134,10 +146,8 @@ distribution's 32-bit compatibility packages.
For example, on Ubuntu and other Debian-based Linuxes you might run:
$ sudo apt-get install ia32-libs ia32-libs-gtk ia32-libs-kde ia32-libs-sdl
EOFMARKER
- fi
fi
fi
-
echo
echo '*******************************************************'
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 3870a3be2e..3367604753 100755
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -3253,6 +3253,10 @@ void LLAgent::processControlRelease(LLMessageSystem *msg, void **)
void LLAgent::processAgentCachedTextureResponse(LLMessageSystem *mesgsys, void **user_data)
{
gAgentQueryManager.mNumPendingQueries--;
+ if (gAgentQueryManager.mNumPendingQueries == 0)
+ {
+ selfStopPhase("fetch_texture_cache_entries");
+ }
if (!isAgentAvatarValid() || gAgentAvatarp->isDead())
{
@@ -3302,13 +3306,12 @@ void LLAgent::processAgentCachedTextureResponse(LLMessageSystem *mesgsys, void *
else
{
// no cache of this bake. request upload.
- gAgentAvatarp->requestLayerSetUpload(baked_index);
+ gAgentAvatarp->invalidateComposite(gAgentAvatarp->getLayerSet(baked_index),TRUE);
}
}
}
}
}
-
llinfos << "Received cached texture response for " << num_results << " textures." << llendl;
gAgentAvatarp->outputRezTiming("Fetched agent wearables textures from cache. Will now load them");
@@ -3775,7 +3778,15 @@ void LLAgent::sendAgentSetAppearance()
return;
}
- llinfos << "TAT: Sent AgentSetAppearance: " << gAgentAvatarp->getBakedStatusForPrintout() << llendl;
+ if (!gAgentWearables.changeInProgress())
+ {
+ // Change is fully resolved, can close some open phases.
+ gAgentAvatarp->getPhases().stopPhase("process_initial_wearables_update");
+ gAgentAvatarp->getPhases().stopPhase("wear_inventory_category");
+ }
+
+ gAgentAvatarp->sendAppearanceChangeMetrics();
+ LL_INFOS("Avatar") << gAgentAvatarp->avString() << "TAT: Sent AgentSetAppearance: " << gAgentAvatarp->getBakedStatusForPrintout() << LL_ENDL;
//dumpAvatarTEs( "sendAgentSetAppearance()" );
LLMessageSystem* msg = gMessageSystem;
@@ -3822,14 +3833,14 @@ void LLAgent::sendAgentSetAppearance()
// only update cache entries if we have all our baked textures
if (textures_current)
{
- llinfos << "TAT: Sending cached texture data" << llendl;
+ LL_INFOS("Avatar") << gAgentAvatarp->avString() << "TAT: Sending cached texture data" << LL_ENDL;
for (U8 baked_index = 0; baked_index < BAKED_NUM_INDICES; baked_index++)
{
BOOL generate_valid_hash = TRUE;
if (isAgentAvatarValid() && !gAgentAvatarp->isBakedTextureFinal((LLVOAvatarDefines::EBakedTextureIndex)baked_index))
{
generate_valid_hash = FALSE;
- llinfos << "Not caching baked texture upload for " << (U32)baked_index << " due to being uploaded at low resolution." << llendl;
+ LL_DEBUGS("Avatar") << gAgentAvatarp->avString() << "Not caching baked texture upload for " << (U32)baked_index << " due to being uploaded at low resolution." << LL_ENDL;
}
const LLUUID hash = gAgentWearables.computeBakedTextureHash((EBakedTextureIndex) baked_index, generate_valid_hash);
diff --git a/indra/newview/llagentlistener.cpp b/indra/newview/llagentlistener.cpp
index a8d2222c03..a4c0b056ac 100644
--- a/indra/newview/llagentlistener.cpp
+++ b/indra/newview/llagentlistener.cpp
@@ -126,6 +126,17 @@ LLAgentListener::LLAgentListener(LLAgent &agent)
"[\"obj_uuid\"]: id of object to look at, use this or [\"position\"] to indicate the target\n"
"[\"position\"]: region position {x, y, z} where to find closest object or avatar to look at",
&LLAgentListener::lookAt);
+ add("getGroups",
+ "Send information about the agent's groups on [\"reply\"]:\n"
+ "[\"groups\"]: array of group information\n"
+ "[\"id\"]: group id\n"
+ "[\"name\"]: group name\n"
+ "[\"insignia\"]: group insignia texture id\n"
+ "[\"notices\"]: boolean indicating if this user accepts notices from this group\n"
+ "[\"display\"]: boolean indicating if this group is listed in the user's profile\n"
+ "[\"contrib\"]: user's land contribution to this group\n",
+ &LLAgentListener::getGroups,
+ LLSDMap("reply", LLSD()));
}
void LLAgentListener::requestTeleport(LLSD const & event_data) const
diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp
index dd02a74a38..e441f21f90 100644
--- a/indra/newview/llagentwearables.cpp
+++ b/indra/newview/llagentwearables.cpp
@@ -955,6 +955,8 @@ void LLAgentWearables::processAgentInitialWearablesUpdate(LLMessageSystem* mesgs
if (isAgentAvatarValid())
{
+ //gAgentAvatarp->clearPhases(); // reset phase timers for outfit loading.
+ gAgentAvatarp->getPhases().startPhase("process_initial_wearables_update");
gAgentAvatarp->outputRezTiming("Received initial wearables update");
}
@@ -1448,7 +1450,16 @@ void LLAgentWearables::setWearableOutfit(const LLInventoryItem::item_array_t& it
{
gAgentAvatarp->setCompositeUpdatesEnabled(TRUE);
gAgentAvatarp->updateVisualParams();
- gAgentAvatarp->invalidateAll();
+
+ // If we have not yet declouded, we may want to use
+ // baked texture UUIDs sent from the first objectUpdate message
+ // don't overwrite these. If we have already declouded, we've saved
+ // these ids as the last known good textures and can invalidate without
+ // re-clouding.
+ if (!gAgentAvatarp->getIsCloud())
+ {
+ gAgentAvatarp->invalidateAll();
+ }
}
// Start rendering & update the server
@@ -1630,10 +1641,11 @@ void LLAgentWearables::queryWearableCache()
{
if (isAgentAvatarValid())
{
+ selfStartPhase("fetch_texture_cache_entries");
gAgentAvatarp->outputRezTiming("Fetching textures from cache");
}
- llinfos << "Requesting texture cache entry for " << num_queries << " baked textures" << llendl;
+ LL_INFOS("Avatar") << gAgentAvatarp->avString() << "Requesting texture cache entry for " << num_queries << " baked textures" << LL_ENDL;
gMessageSystem->sendReliable(gAgent.getRegion()->getHost());
gAgentQueryManager.mNumPendingQueries++;
gAgentQueryManager.mWearablesCacheQueryID++;
@@ -2081,6 +2093,11 @@ boost::signals2::connection LLAgentWearables::addLoadedCallback(loaded_callback_
return mLoadedSignal.connect(cb);
}
+bool LLAgentWearables::changeInProgress() const
+{
+ return mCOFChangeInProgress;
+}
+
void LLAgentWearables::notifyLoadingStarted()
{
mCOFChangeInProgress = true;
diff --git a/indra/newview/llagentwearables.h b/indra/newview/llagentwearables.h
index 01cae3ffd8..5932be21c6 100644
--- a/indra/newview/llagentwearables.h
+++ b/indra/newview/llagentwearables.h
@@ -233,6 +233,7 @@ public:
typedef boost::signals2::signal<void()> loaded_signal_t;
boost::signals2::connection addLoadedCallback(loaded_callback_t cb);
+ bool changeInProgress() const;
void notifyLoadingStarted();
void notifyLoadingFinished();
diff --git a/indra/newview/llagentwearablesfetch.cpp b/indra/newview/llagentwearablesfetch.cpp
index 8cba54347e..e2417cdddb 100644
--- a/indra/newview/llagentwearablesfetch.cpp
+++ b/indra/newview/llagentwearablesfetch.cpp
@@ -89,6 +89,7 @@ LLInitialWearablesFetch::LLInitialWearablesFetch(const LLUUID& cof_id) :
{
if (isAgentAvatarValid())
{
+ gAgentAvatarp->getPhases().startPhase("initial_wearables_fetch");
gAgentAvatarp->outputRezTiming("Initial wearables fetch started");
}
}
@@ -107,6 +108,7 @@ void LLInitialWearablesFetch::done()
doOnIdleOneTime(boost::bind(&LLInitialWearablesFetch::processContents,this));
if (isAgentAvatarValid())
{
+ gAgentAvatarp->getPhases().stopPhase("initial_wearables_fetch");
gAgentAvatarp->outputRezTiming("Initial wearables fetch done");
}
}
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 33f5373d7e..faadfb4b87 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -50,6 +50,11 @@
#include "llviewerregion.h"
#include "llwearablelist.h"
+std::string self_av_string()
+{
+ return gAgentAvatarp->avString();
+}
+
// RAII thingy to guarantee that a variable gets reset when the Setter
// goes out of scope. More general utility would be handy - TODO:
// check boost.
@@ -156,6 +161,10 @@ public:
{
mCatID = cat_id;
mAppend = append;
+
+ LL_INFOS("Avatar") << self_av_string() << "starting" << LL_ENDL;
+
+ selfStartPhase("wear_inventory_category_callback");
}
void fire(const LLUUID& item_id)
{
@@ -167,13 +176,16 @@ public:
* after the last item has fired the event and dereferenced it -- if all
* the events actually fire!
*/
+ LL_DEBUGS("Avatar") << self_av_string() << " fired on copied item, id " << item_id << LL_ENDL;
}
protected:
~LLWearInventoryCategoryCallback()
{
- llinfos << "done all inventory callbacks" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "done all inventory callbacks" << LL_ENDL;
+ selfStopPhase("wear_inventory_category_callback");
+
// Is the destructor called by ordinary dereference, or because the app's shutting down?
// If the inventory callback manager goes away, we're shutting down, no longer want the callback.
if( LLInventoryCallbackManager::is_instantiated() )
@@ -182,7 +194,7 @@ protected:
}
else
{
- llwarns << "Dropping unhandled LLWearInventoryCategoryCallback" << llendl;
+ llwarns << self_av_string() << "Dropping unhandled LLWearInventoryCategoryCallback" << llendl;
}
}
@@ -212,11 +224,14 @@ LLUpdateAppearanceOnDestroy::LLUpdateAppearanceOnDestroy(bool update_base_outfit
mFireCount(0),
mUpdateBaseOrder(update_base_outfit_ordering)
{
+ selfStartPhase("update_appearance_on_destroy");
}
LLUpdateAppearanceOnDestroy::~LLUpdateAppearanceOnDestroy()
{
- llinfos << "done update appearance on destroy" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "done update appearance on destroy" << LL_ENDL;
+
+ selfStopPhase("update_appearance_on_destroy");
if (!LLApp::isExiting())
{
@@ -229,7 +244,7 @@ void LLUpdateAppearanceOnDestroy::fire(const LLUUID& inv_item)
LLViewerInventoryItem* item = (LLViewerInventoryItem*)gInventory.getItem(inv_item);
const std::string item_name = item ? item->getName() : "ITEM NOT FOUND";
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "callback fired [ name:" << item_name << " UUID:" << inv_item << " count:" << mFireCount << " ] " << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "callback fired [ name:" << item_name << " UUID:" << inv_item << " count:" << mFireCount << " ] " << LL_ENDL;
#endif
mFireCount++;
}
@@ -339,11 +354,16 @@ LLWearableHoldingPattern::LLWearableHoldingPattern():
}
sActiveHoldingPatterns.insert(this);
+ selfStartPhase("holding_pattern");
}
LLWearableHoldingPattern::~LLWearableHoldingPattern()
{
sActiveHoldingPatterns.erase(this);
+ if (isMostRecent())
+ {
+ selfStopPhase("holding_pattern");
+ }
}
bool LLWearableHoldingPattern::isMostRecent()
@@ -390,9 +410,10 @@ void LLWearableHoldingPattern::checkMissingWearables()
{
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway why don't we actually skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
-
+
std::vector<S32> found_by_type(LLWearableType::WT_COUNT,0);
std::vector<S32> requested_by_type(LLWearableType::WT_COUNT,0);
for (found_list_t::iterator it = getFoundList().begin(); it != getFoundList().end(); ++it)
@@ -408,7 +429,7 @@ void LLWearableHoldingPattern::checkMissingWearables()
{
if (requested_by_type[type] > found_by_type[type])
{
- llwarns << "got fewer wearables than requested, type " << type << ": requested " << requested_by_type[type] << ", found " << found_by_type[type] << llendl;
+ llwarns << self_av_string() << "got fewer wearables than requested, type " << type << ": requested " << requested_by_type[type] << ", found " << found_by_type[type] << llendl;
}
if (found_by_type[type] > 0)
continue;
@@ -425,11 +446,13 @@ void LLWearableHoldingPattern::checkMissingWearables()
mTypesToRecover.insert(type);
mTypesToLink.insert(type);
recoverMissingWearable((LLWearableType::EType)type);
- llwarns << "need to replace " << type << llendl;
+ llwarns << self_av_string() << "need to replace " << type << llendl;
}
}
resetTime(60.0F);
+
+ selfStartPhase("get_missing_wearables");
if (!pollMissingWearables())
{
doOnIdleRepeating(boost::bind(&LLWearableHoldingPattern::pollMissingWearables,this));
@@ -445,13 +468,14 @@ void LLWearableHoldingPattern::onAllComplete()
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway need to skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
// Activate all gestures in this folder
if (mGestItems.count() > 0)
{
- llinfos << "Activating " << mGestItems.count() << " gestures" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Activating " << mGestItems.count() << " gestures" << LL_ENDL;
LLGestureMgr::instance().activateGestures(mGestItems);
@@ -468,13 +492,13 @@ void LLWearableHoldingPattern::onAllComplete()
}
// Update wearables.
- llinfos << "Updating agent wearables with " << mResolved << " wearable items " << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "Updating agent wearables with " << mResolved << " wearable items " << LL_ENDL;
LLAppearanceMgr::instance().updateAgentWearables(this, false);
// Update attachments to match those requested.
if (isAgentAvatarValid())
{
- llinfos << "Updating " << mObjItems.count() << " attachments" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Updating " << mObjItems.count() << " attachments" << LL_ENDL;
LLAgentWearables::userUpdateAttachments(mObjItems);
}
@@ -492,9 +516,12 @@ void LLWearableHoldingPattern::onAllComplete()
void LLWearableHoldingPattern::onFetchCompletion()
{
+ selfStopPhase("get_wearables");
+
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
checkMissingWearables();
@@ -505,7 +532,8 @@ bool LLWearableHoldingPattern::pollFetchCompletion()
{
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
bool completed = isFetchCompleted();
@@ -514,14 +542,14 @@ bool LLWearableHoldingPattern::pollFetchCompletion()
if (done)
{
- llinfos << "polling, done status: " << completed << " timed out " << timed_out
- << " elapsed " << mWaitTime.getElapsedTimeF32() << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "polling, done status: " << completed << " timed out " << timed_out
+ << " elapsed " << mWaitTime.getElapsedTimeF32() << LL_ENDL;
mFired = true;
if (timed_out)
{
- llwarns << "Exceeded max wait time for wearables, updating appearance based on what has arrived" << llendl;
+ llwarns << self_av_string() << "Exceeded max wait time for wearables, updating appearance based on what has arrived" << llendl;
}
onFetchCompletion();
@@ -543,6 +571,7 @@ public:
if (!mHolder->isMostRecent())
{
llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
}
llinfos << "Recovered item link for type " << mType << llendl;
@@ -569,12 +598,12 @@ public:
}
else
{
- llwarns << "inventory item not found for recovered wearable" << llendl;
+ llwarns << self_av_string() << "inventory item not found for recovered wearable" << llendl;
}
}
else
{
- llwarns << "inventory link not found for recovered wearable" << llendl;
+ llwarns << self_av_string() << "inventory link not found for recovered wearable" << llendl;
}
}
private:
@@ -596,10 +625,11 @@ public:
{
if (!mHolder->isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
- llinfos << "Recovered item for type " << mType << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Recovered item for type " << mType << LL_ENDL;
LLViewerInventoryItem *itemp = gInventory.getItem(item_id);
mWearable->setItemID(item_id);
LLPointer<LLInventoryCallback> cb = new RecoveredItemLinkCB(mType,mWearable,mHolder);
@@ -626,7 +656,8 @@ void LLWearableHoldingPattern::recoverMissingWearable(LLWearableType::EType type
{
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
// Try to recover by replacing missing wearable with a new one.
@@ -665,7 +696,7 @@ void LLWearableHoldingPattern::clearCOFLinksForMissingWearables()
if ((data.mWearableType < LLWearableType::WT_COUNT) && (!data.mWearable))
{
// Wearable link that was never resolved; remove links to it from COF
- llinfos << "removing link for unresolved item " << data.mItemID.asString() << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "removing link for unresolved item " << data.mItemID.asString() << LL_ENDL;
LLAppearanceMgr::instance().removeCOFItemLinks(data.mItemID,false);
}
}
@@ -675,7 +706,8 @@ bool LLWearableHoldingPattern::pollMissingWearables()
{
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ // runway skip here?
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
bool timed_out = isTimedOut();
@@ -684,15 +716,17 @@ bool LLWearableHoldingPattern::pollMissingWearables()
if (!done)
{
- llinfos << "polling missing wearables, waiting for items " << mTypesToRecover.size()
+ LL_INFOS("Avatar") << self_av_string() << "polling missing wearables, waiting for items " << mTypesToRecover.size()
<< " links " << mTypesToLink.size()
<< " wearables, timed out " << timed_out
<< " elapsed " << mWaitTime.getElapsedTimeF32()
- << " done " << done << llendl;
+ << " done " << done << LL_ENDL;
}
if (done)
{
+ selfStopPhase("get_missing_wearables");
+
gAgentAvatarp->debugWearablesLoaded();
// BAP - if we don't call clearCOFLinksForMissingWearables()
@@ -722,14 +756,14 @@ void LLWearableHoldingPattern::handleLateArrivals()
}
if (!isMostRecent())
{
- llwarns << "Late arrivals not handled - outfit change no longer valid" << llendl;
+ llwarns << self_av_string() << "Late arrivals not handled - outfit change no longer valid" << llendl;
}
if (!mIsAllComplete)
{
- llwarns << "Late arrivals not handled - in middle of missing wearables processing" << llendl;
+ llwarns << self_av_string() << "Late arrivals not handled - in middle of missing wearables processing" << llendl;
}
- llinfos << "Need to handle " << mLateArrivals.size() << " late arriving wearables" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "Need to handle " << mLateArrivals.size() << " late arriving wearables" << LL_ENDL;
// Update mFoundList using late-arriving wearables.
std::set<LLWearableType::EType> replaced_types;
@@ -805,19 +839,19 @@ void LLWearableHoldingPattern::onWearableAssetFetch(LLWearable *wearable)
{
if (!isMostRecent())
{
- llwarns << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
+ llwarns << self_av_string() << "skipping because LLWearableHolding pattern is invalid (superceded by later outfit request)" << llendl;
}
mResolved += 1; // just counting callbacks, not successes.
- llinfos << "resolved " << mResolved << "/" << getFoundList().size() << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "resolved " << mResolved << "/" << getFoundList().size() << LL_ENDL;
if (!wearable)
{
- llwarns << "no wearable found" << llendl;
+ llwarns << self_av_string() << "no wearable found" << llendl;
}
if (mFired)
{
- llwarns << "called after holder fired" << llendl;
+ llwarns << self_av_string() << "called after holder fired" << llendl;
if (wearable)
{
mLateArrivals.insert(wearable);
@@ -843,7 +877,7 @@ void LLWearableHoldingPattern::onWearableAssetFetch(LLWearable *wearable)
// Failing this means inventory or asset server are corrupted in a way we don't handle.
if ((data.mWearableType >= LLWearableType::WT_COUNT) || (wearable->getType() != data.mWearableType))
{
- llwarns << "recovered wearable but type invalid. inventory wearable type: " << data.mWearableType << " asset wearable type: " << wearable->getType() << llendl;
+ llwarns << self_av_string() << "recovered wearable but type invalid. inventory wearable type: " << data.mWearableType << " asset wearable type: " << wearable->getType() << llendl;
break;
}
@@ -1391,8 +1425,8 @@ void LLAppearanceMgr::filterWearableItems(
// Create links to all listed items.
void LLAppearanceMgr::linkAll(const LLUUID& cat_uuid,
- LLInventoryModel::item_array_t& items,
- LLPointer<LLInventoryCallback> cb)
+ LLInventoryModel::item_array_t& items,
+ LLPointer<LLInventoryCallback> cb)
{
for (S32 i=0; i<items.count(); i++)
{
@@ -1408,7 +1442,7 @@ void LLAppearanceMgr::linkAll(const LLUUID& cat_uuid,
const LLViewerInventoryCategory *cat = gInventory.getCategory(cat_uuid);
const std::string cat_name = cat ? cat->getName() : "CAT NOT FOUND";
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "Linking Item [ name:" << item->getName() << " UUID:" << item->getUUID() << " ] to Category [ name:" << cat_name << " UUID:" << cat_uuid << " ] " << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Linking Item [ name:" << item->getName() << " UUID:" << item->getUUID() << " ] to Category [ name:" << cat_name << " UUID:" << cat_uuid << " ] " << LL_ENDL;
#endif
}
}
@@ -1416,7 +1450,7 @@ void LLAppearanceMgr::linkAll(const LLUUID& cat_uuid,
void LLAppearanceMgr::updateCOF(const LLUUID& category, bool append)
{
LLViewerInventoryCategory *pcat = gInventory.getCategory(category);
- llinfos << "starting, cat " << (pcat ? pcat->getName() : "[UNKNOWN]") << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "starting, cat '" << (pcat ? pcat->getName() : "[UNKNOWN]") << "'" << LL_ENDL;
const LLUUID cof = getCOF();
@@ -1478,26 +1512,26 @@ void LLAppearanceMgr::updateCOF(const LLUUID& category, bool append)
gInventory.notifyObservers();
// Create links to new COF contents.
- llinfos << "creating LLUpdateAppearanceOnDestroy" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "creating LLUpdateAppearanceOnDestroy" << LL_ENDL;
LLPointer<LLInventoryCallback> link_waiter = new LLUpdateAppearanceOnDestroy(!append);
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "Linking body items" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Linking body items" << LL_ENDL;
#endif
linkAll(cof, body_items, link_waiter);
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "Linking wear items" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Linking wear items" << LL_ENDL;
#endif
linkAll(cof, wear_items, link_waiter);
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "Linking obj items" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Linking obj items" << LL_ENDL;
#endif
linkAll(cof, obj_items, link_waiter);
#ifndef LL_RELEASE_FOR_DOWNLOAD
- llinfos << "Linking gesture items" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Linking gesture items" << LL_ENDL;
#endif
linkAll(cof, gest_items, link_waiter);
@@ -1506,7 +1540,7 @@ void LLAppearanceMgr::updateCOF(const LLUUID& category, bool append)
{
createBaseOutfitLink(category, link_waiter);
}
- llinfos << "waiting for LLUpdateAppearanceOnDestroy" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "waiting for LLUpdateAppearanceOnDestroy" << LL_ENDL;
}
void LLAppearanceMgr::updatePanelOutfitName(const std::string& name)
@@ -1663,7 +1697,7 @@ void LLAppearanceMgr::enforceItemRestrictions()
++it)
{
LLViewerInventoryItem *item = *it;
- llinfos << "purging duplicate or excess item " << item->getName() << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "purging duplicate or excess item " << item->getName() << LL_ENDL;
gInventory.purgeObject(item->getUUID());
}
gInventory.notifyObservers();
@@ -1678,9 +1712,11 @@ void LLAppearanceMgr::updateAppearanceFromCOF(bool update_base_outfit_ordering)
return;
}
+ LLVOAvatar::ScopedPhaseSetter(gAgentAvatarp,"update_appearance_from_cof");
+
BoolSetter setIsInUpdateAppearanceFromCOF(mIsInUpdateAppearanceFromCOF);
- llinfos << "starting" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "starting" << LL_ENDL;
//checking integrity of the COF in terms of ordering of wearables,
//checking and updating links' descriptions of wearables in the COF (before analyzed for "dirty" state)
@@ -1772,12 +1808,14 @@ void LLAppearanceMgr::updateAppearanceFromCOF(bool update_base_outfit_ordering)
}
}
+ selfStartPhase("get_wearables");
+
for (LLWearableHoldingPattern::found_list_t::iterator it = holder->getFoundList().begin();
it != holder->getFoundList().end(); ++it)
{
LLFoundData& found = *it;
- lldebugs << "waiting for onWearableAssetFetch callback, asset " << found.mAssetID.asString() << llendl;
+ lldebugs << self_av_string() << "waiting for onWearableAssetFetch callback, asset " << found.mAssetID.asString() << llendl;
// Fetch the wearables about to be worn.
LLWearableList::instance().getAsset(found.mAssetID,
@@ -1849,11 +1887,15 @@ void LLAppearanceMgr::wearInventoryCategory(LLInventoryCategory* category, bool
{
if(!category) return;
+ selfClearPhases();
+ selfStartPhase("wear_inventory_category");
+
gAgentWearables.notifyLoadingStarted();
- llinfos << "wearInventoryCategory( " << category->getName()
- << " )" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "wearInventoryCategory( " << category->getName()
+ << " )" << LL_ENDL;
+ selfStartPhase("wear_inventory_category_fetch");
callAfterCategoryFetch(category->getUUID(),boost::bind(&LLAppearanceMgr::wearCategoryFinal,
&LLAppearanceMgr::instance(),
category->getUUID(), copy, append));
@@ -1861,7 +1903,9 @@ void LLAppearanceMgr::wearInventoryCategory(LLInventoryCategory* category, bool
void LLAppearanceMgr::wearCategoryFinal(LLUUID& cat_id, bool copy_items, bool append)
{
- llinfos << "starting" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "starting" << LL_ENDL;
+
+ selfStopPhase("wear_inventory_category_fetch");
// We now have an outfit ready to be copied to agent inventory. Do
// it, and wear that outfit normally.
@@ -1944,8 +1988,8 @@ void LLAppearanceMgr::wearInventoryCategoryOnAvatar( LLInventoryCategory* catego
// wearables being dirty.
if(!category) return;
- llinfos << "wearInventoryCategoryOnAvatar( " << category->getName()
- << " )" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "wearInventoryCategoryOnAvatar '" << category->getName()
+ << "'" << LL_ENDL;
if (gAgentCamera.cameraCustomizeAvatar())
{
@@ -1958,7 +2002,7 @@ void LLAppearanceMgr::wearInventoryCategoryOnAvatar( LLInventoryCategory* catego
void LLAppearanceMgr::wearOutfitByName(const std::string& name)
{
- llinfos << "Wearing category " << name << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "Wearing category " << name << LL_ENDL;
//inc_busy_count();
LLInventoryModel::cat_array_t cat_array;
@@ -2281,7 +2325,7 @@ const std::string OTHER_GESTURES_FOLDER = "Other Gestures";
void LLAppearanceMgr::copyLibraryGestures()
{
- llinfos << "Copying library gestures" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "Copying library gestures" << LL_ENDL;
// Copy gestures
LLUUID lib_gesture_cat_id =
@@ -2337,11 +2381,11 @@ void LLAppearanceMgr::copyLibraryGestures()
LLUUID cat_id = findDescendentCategoryIDByName(lib_gesture_cat_id,folder_name);
if (cat_id.isNull())
{
- llwarns << "failed to find gesture folder for " << folder_name << llendl;
+ llwarns << self_av_string() << "failed to find gesture folder for " << folder_name << llendl;
}
else
{
- llinfos << "initiating fetch and copy for " << folder_name << " cat_id " << cat_id << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "initiating fetch and copy for " << folder_name << " cat_id " << cat_id << LL_ENDL;
callAfterCategoryFetch(cat_id,
boost::bind(&LLAppearanceMgr::shallowCopyCategory,
&LLAppearanceMgr::instance(),
@@ -2355,7 +2399,7 @@ void LLAppearanceMgr::autopopulateOutfits()
// If this is the very first time the user has logged into viewer2+ (from a legacy viewer, or new account)
// then auto-populate outfits from the library into the My Outfits folder.
- llinfos << "avatar fully visible" << llendl;
+ LL_INFOS("Avatar") << self_av_string() << "avatar fully visible" << LL_ENDL;
static bool check_populate_my_outfits = true;
if (check_populate_my_outfits &&
@@ -2731,7 +2775,7 @@ void LLAppearanceMgr::dumpCat(const LLUUID& cat_id, const std::string& msg)
}
void LLAppearanceMgr::dumpItemArray(const LLInventoryModel::item_array_t& items,
- const std::string& msg)
+ const std::string& msg)
{
for (S32 i=0; i<items.count(); i++)
{
@@ -2742,9 +2786,8 @@ void LLAppearanceMgr::dumpItemArray(const LLInventoryModel::item_array_t& items,
{
asset_id = linked_item->getAssetUUID();
}
- llinfos << msg << " " << i <<" " << (item ? item->getName() : "(nullitem)") << " " << asset_id.asString() << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << msg << " " << i <<" " << (item ? item->getName() : "(nullitem)") << " " << asset_id.asString() << LL_ENDL;
}
- llinfos << llendl;
}
LLAppearanceMgr::LLAppearanceMgr():
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index 1174d108d2..d033252029 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -93,6 +93,7 @@
#include "llsecondlifeurls.h"
#include "llupdaterservice.h"
#include "llcallfloater.h"
+#include "llfloatertexturefetchdebugger.h"
// Linden library includes
#include "llavatarnamecache.h"
@@ -111,6 +112,8 @@
#include "llnotifications.h"
#include "llnotificationsutil.h"
+#include "llleap.h"
+
// Third party library includes
#include <boost/bind.hpp>
#include <boost/foreach.hpp>
@@ -124,7 +127,6 @@
#endif
#include "llapr.h"
-#include "apr_dso.h"
#include <boost/lexical_cast.hpp>
#include "llviewerkeyboard.h"
@@ -161,6 +163,7 @@
#include "llcontainerview.h"
#include "lltooltip.h"
+#include "llsdutil.h"
#include "llsdserialize.h"
#include "llworld.h"
@@ -528,6 +531,7 @@ static void settings_to_globals()
LLRender::sGLCoreProfile = gSavedSettings.getBOOL("RenderGLCoreProfile");
LLImageGL::sGlobalUseAnisotropic = gSavedSettings.getBOOL("RenderAnisotropic");
+ LLImageGL::sCompressTextures = gSavedSettings.getBOOL("RenderCompressTextures");
LLVOVolume::sLODFactor = gSavedSettings.getF32("RenderVolumeLODFactor");
LLVOVolume::sDistanceFactor = 1.f-LLVOVolume::sLODFactor * 0.1f;
LLVolumeImplFlexible::sUpdateFactor = gSavedSettings.getF32("RenderFlexTimeFactor");
@@ -545,7 +549,7 @@ static void settings_to_globals()
gAgentPilot.setNumRuns(gSavedSettings.getS32("StatsNumRuns"));
gAgentPilot.setQuitAfterRuns(gSavedSettings.getBOOL("StatsQuitAfterRuns"));
gAgent.setHideGroupTitle(gSavedSettings.getBOOL("RenderHideGroupTitle"));
-
+
gDebugWindowProc = gSavedSettings.getBOOL("DebugWindowProc");
gShowObjectUpdates = gSavedSettings.getBOOL("ShowObjectUpdates");
LLWorldMapView::sMapScale = gSavedSettings.getF32("MapScale");
@@ -560,7 +564,6 @@ static void settings_modify()
LLVOSurfacePatch::sLODFactor *= LLVOSurfacePatch::sLODFactor; //square lod factor to get exponential range of [1,4]
gDebugGL = gSavedSettings.getBOOL("RenderDebugGL") || gDebugSession;
gDebugPipeline = gSavedSettings.getBOOL("RenderDebugPipeline");
- gAuditTexture = gSavedSettings.getBOOL("AuditTexture");
}
class LLFastTimerLogThread : public LLThread
@@ -622,6 +625,7 @@ LLAppViewer::LLAppViewer() :
mPurgeOnExit(false),
mSecondInstance(false),
mSavedFinalSnapshot(false),
+ mSavePerAccountSettings(false), // don't save settings on logout unless login succeeded.
mForceGraphicsDetail(false),
mQuitRequested(false),
mLogoutRequestSent(false),
@@ -731,12 +735,12 @@ bool LLAppViewer::init()
{
// Viewer metrics initialization
- static LLCachedControl<bool> metrics_submode(gSavedSettings,
- "QAModeMetrics",
- false,
- "Enables QA features (logging, faster cycling) for metrics collector");
+ //static LLCachedControl<bool> metrics_submode(gSavedSettings,
+ // "QAModeMetrics",
+ // false,
+ // "Enables QA features (logging, faster cycling) for metrics collector");
- if (metrics_submode)
+ if (gSavedSettings.getBOOL("QAModeMetrics"))
{
app_metrics_qa_mode = true;
app_metrics_interval = METRICS_INTERVAL_QA;
@@ -1014,6 +1018,15 @@ bool LLAppViewer::init()
}
}
+#if LL_WINDOWS
+ if (gGLManager.mIsIntel &&
+ LLFeatureManager::getInstance()->getGPUClass() > 0 &&
+ gGLManager.mGLVersion <= 3.f)
+ {
+ LLNotificationsUtil::add("IntelOldDriver");
+ }
+#endif
+
// save the graphics card
gDebugInfo["GraphicsCard"] = LLFeatureManager::getInstance()->getGPUString();
@@ -1038,11 +1051,38 @@ bool LLAppViewer::init()
gGLActive = FALSE;
+
+ // Iterate over --leap command-line options. But this is a bit tricky: if
+ // there's only one, it won't be an array at all.
+ LLSD LeapCommand(gSavedSettings.getLLSD("LeapCommand"));
+ LL_DEBUGS("InitInfo") << "LeapCommand: " << LeapCommand << LL_ENDL;
+ if (LeapCommand.isDefined() && ! LeapCommand.isArray())
+ {
+ // If LeapCommand is actually a scalar value, make an array of it.
+ // Have to do it in two steps because LeapCommand.append(LeapCommand)
+ // trashes content! :-P
+ LLSD item(LeapCommand);
+ LeapCommand.append(item);
+ }
+ BOOST_FOREACH(const std::string& leap, llsd::inArray(LeapCommand))
+ {
+ LL_INFOS("InitInfo") << "processing --leap \"" << leap << '"' << LL_ENDL;
+ // We don't have any better description of this plugin than the
+ // user-specified command line. Passing "" causes LLLeap to derive a
+ // description from the command line itself.
+ // Suppress LLLeap::Error exception: trust LLLeap's own logging. We
+ // don't consider any one --leap command mission-critical, so if one
+ // fails, log it, shrug and carry on.
+ LLLeap::create("", leap, false); // exception=false
+ }
+
if (gSavedSettings.getBOOL("QAMode") && gSavedSettings.getS32("QAModeEventHostPort") > 0)
{
- loadEventHostModule(gSavedSettings.getS32("QAModeEventHostPort"));
+ LL_WARNS("InitInfo") << "QAModeEventHostPort DEPRECATED: "
+ << "lleventhost no longer supported as a dynamic library"
+ << LL_ENDL;
}
-
+
LLViewerMedia::initClass();
LL_INFOS("InitInfo") << "Viewer media initialized." << LL_ENDL ;
@@ -1219,7 +1259,7 @@ bool LLAppViewer::mainLoop()
if(mem_leak_instance)
{
mem_leak_instance->idle() ;
- }
+ }
// canonical per-frame event
mainloop.post(newFrame);
@@ -1340,13 +1380,11 @@ bool LLAppViewer::mainLoop()
ms_sleep(500);
}
- static const F64 FRAME_SLOW_THRESHOLD = 0.5; //2 frames per seconds
const F64 max_idle_time = llmin(.005*10.0*gFrameTimeSeconds, 0.005); // 5 ms a second
idleTimer.reset();
- bool is_slow = (frameTimer.getElapsedTimeF64() > FRAME_SLOW_THRESHOLD) ;
S32 total_work_pending = 0;
S32 total_io_pending = 0;
- while(!is_slow)//do not unpause threads if the frame rates are very low.
+ while(1)
{
S32 work_pending = 0;
S32 io_pending = 0;
@@ -1406,6 +1444,17 @@ bool LLAppViewer::mainLoop()
LLLFSThread::sLocal->pause();
}
+ //texture fetching debugger
+ if(LLTextureFetchDebugger::isEnabled())
+ {
+ LLFloaterTextureFetchDebugger* tex_fetch_debugger_instance =
+ LLFloaterReg::findTypedInstance<LLFloaterTextureFetchDebugger>("tex_fetch_debugger");
+ if(tex_fetch_debugger_instance)
+ {
+ tex_fetch_debugger_instance->idle() ;
+ }
+ }
+
if ((LLStartUp::getStartupState() >= STATE_CLEANUP) &&
(frameTimer.getElapsedTimeF64() > FRAME_STALL_THRESHOLD))
{
@@ -1511,21 +1560,27 @@ bool LLAppViewer::cleanup()
if (! isError())
{
std::string logdir = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "");
- logdir += gDirUtilp->getDirDelimiter();
gDirUtilp->deleteFilesInDir(logdir, "*-*-*-*-*.dmp");
}
- // *TODO - generalize this and move DSO wrangling to a helper class -brad
- std::set<struct apr_dso_handle_t *>::const_iterator i;
- for(i = mPlugins.begin(); i != mPlugins.end(); ++i)
{
- int (*ll_plugin_stop_func)(void) = NULL;
- apr_status_t rv = apr_dso_sym((apr_dso_handle_sym_t*)&ll_plugin_stop_func, *i, "ll_plugin_stop");
- ll_plugin_stop_func();
-
- rv = apr_dso_unload(*i);
- }
- mPlugins.clear();
+ // Kill off LLLeap objects. We can find them all because LLLeap is derived
+ // from LLInstanceTracker. But collect instances first: LLInstanceTracker
+ // specifically forbids adding/deleting instances while iterating.
+ std::vector<LLLeap*> leaps;
+ leaps.reserve(LLLeap::instanceCount());
+ for (LLLeap::instance_iter li(LLLeap::beginInstances()), lend(LLLeap::endInstances());
+ li != lend; ++li)
+ {
+ leaps.push_back(&*li);
+ }
+ // Okay, now trash them all. We don't have to NULL or erase the entry
+ // in 'leaps' because the whole vector is going away momentarily.
+ BOOST_FOREACH(LLLeap* leap, leaps)
+ {
+ delete leap;
+ }
+ } // destroy 'leaps'
//flag all elements as needing to be destroyed immediately
// to ensure shutdown order
@@ -1742,6 +1797,13 @@ bool LLAppViewer::cleanup()
{
llinfos << "Not saving per-account settings; don't know the account name yet." << llendl;
}
+ // Only save per account settings if the previous login succeeded, otherwise
+ // we might end up with a cleared out settings file in case a previous login
+ // failed after loading per account settings.
+ else if (!mSavePerAccountSettings)
+ {
+ llinfos << "Not saving per-account settings; last login was not successful." << llendl;
+ }
else
{
gSavedPerAccountSettings.saveToFile(gSavedSettings.getString("PerAccountSettingsFile"), TRUE);
@@ -1760,8 +1822,7 @@ bool LLAppViewer::cleanup()
if (mPurgeOnExit)
{
llinfos << "Purging all cache files on exit" << llendflush;
- std::string mask = gDirUtilp->getDirDelimiter() + "*.*";
- gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE,""),mask);
+ gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE,""), "*.*");
}
removeMarkerFile(); // Any crashes from here on we'll just have to ignore
@@ -1951,7 +2012,7 @@ bool LLAppViewer::initThreads()
static const bool enable_threads = true;
#endif
- LLImage::initClass();
+ LLImage::initClass(gSavedSettings.getBOOL("TextureNewByteRange"),gSavedSettings.getS32("TextureReverseByteRange"));
LLVFSThread::initClass(enable_threads && false);
LLLFSThread::initClass(enable_threads && false);
@@ -2995,8 +3056,7 @@ void LLAppViewer::cleanupSavedSettings()
void LLAppViewer::removeCacheFiles(const std::string& file_mask)
{
- std::string mask = gDirUtilp->getDirDelimiter() + file_mask;
- gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""), mask);
+ gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""), file_mask);
}
void LLAppViewer::writeSystemInfo()
@@ -3855,8 +3915,7 @@ void LLAppViewer::purgeCache()
LL_INFOS("AppCache") << "Purging Cache and Texture Cache..." << LL_ENDL;
LLAppViewer::getTextureCache()->purgeCache(LL_PATH_CACHE);
LLVOCache::getInstance()->removeCache(LL_PATH_CACHE);
- std::string mask = "*.*";
- gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""), mask);
+ gDirUtilp->deleteFilesInDir(gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""), "*.*");
}
std::string LLAppViewer::getSecondLifeTitle() const
@@ -4201,6 +4260,7 @@ void LLAppViewer::idle()
// The 5-second interval is nice for this purpose. If the object debug
// bit moves or is disabled, please give this a suitable home.
LLViewerAssetStatsFF::record_fps_main(gFPSClamped);
+ LLViewerAssetStatsFF::record_avatar_stats();
}
}
@@ -4248,7 +4308,8 @@ void LLAppViewer::idle()
static LLTimer report_interval;
// *TODO: Add configuration controls for this
- if (report_interval.getElapsedTimeF32() >= app_metrics_interval)
+ F32 seconds = report_interval.getElapsedTimeF32();
+ if (seconds >= app_metrics_interval)
{
metricsSend(! gDisconnected);
report_interval.reset();
@@ -4956,87 +5017,10 @@ void LLAppViewer::handleLoginComplete()
mOnLoginCompleted();
writeDebugInfo();
-}
-
-// *TODO - generalize this and move DSO wrangling to a helper class -brad
-void LLAppViewer::loadEventHostModule(S32 listen_port)
-{
- std::string dso_name =
-#if LL_WINDOWS
- "lleventhost.dll";
-#elif LL_DARWIN
- "liblleventhost.dylib";
-#else
- "liblleventhost.so";
-#endif
-
- std::string dso_path = gDirUtilp->findFile(dso_name,
- gDirUtilp->getAppRODataDir(),
- gDirUtilp->getExecutableDir());
-
- if(dso_path == "")
- {
- llerrs << "QAModeEventHost requested but module \"" << dso_name << "\" not found!" << llendl;
- return;
- }
-
- LL_INFOS("eventhost") << "Found lleventhost at '" << dso_path << "'" << LL_ENDL;
-#if ! defined(LL_WINDOWS)
- {
- std::string outfile("/tmp/lleventhost.file.out");
- std::string command("file '" + dso_path + "' > '" + outfile + "' 2>&1");
- int rc = system(command.c_str());
- if (rc != 0)
- {
- LL_WARNS("eventhost") << command << " ==> " << rc << ':' << LL_ENDL;
- }
- else
- {
- LL_INFOS("eventhost") << command << ':' << LL_ENDL;
- }
- {
- std::ifstream reader(outfile.c_str());
- std::string line;
- while (std::getline(reader, line))
- {
- size_t len = line.length();
- if (len && line[len-1] == '\n')
- line.erase(len-1);
- LL_INFOS("eventhost") << line << LL_ENDL;
- }
- }
- remove(outfile.c_str());
- }
-#endif // LL_WINDOWS
-
- apr_dso_handle_t * eventhost_dso_handle = NULL;
- apr_pool_t * eventhost_dso_memory_pool = NULL;
-
- //attempt to load the shared library
- apr_pool_create(&eventhost_dso_memory_pool, NULL);
- apr_status_t rv = apr_dso_load(&eventhost_dso_handle,
- dso_path.c_str(),
- eventhost_dso_memory_pool);
- llassert_always(! ll_apr_warn_status(rv, eventhost_dso_handle));
- llassert_always(eventhost_dso_handle != NULL);
-
- int (*ll_plugin_start_func)(LLSD const &) = NULL;
- rv = apr_dso_sym((apr_dso_handle_sym_t*)&ll_plugin_start_func, eventhost_dso_handle, "ll_plugin_start");
-
- llassert_always(! ll_apr_warn_status(rv, eventhost_dso_handle));
- llassert_always(ll_plugin_start_func != NULL);
-
- LLSD args;
- args["listen_port"] = listen_port;
-
- int status = ll_plugin_start_func(args);
-
- if(status != 0)
- {
- llerrs << "problem loading eventhost plugin, status: " << status << llendl;
- }
- mPlugins.insert(eventhost_dso_handle);
+ // we logged in successfully, so save settings on logout
+ llinfos << "Login successful, per account settings will be saved on log out." << llendl;
+ mSavePerAccountSettings=true;
}
void LLAppViewer::launchUpdater()
diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h
index 71a7868191..ae3c795d1e 100644
--- a/indra/newview/llappviewer.h
+++ b/indra/newview/llappviewer.h
@@ -41,8 +41,6 @@ class LLTextureFetch;
class LLWatchdogTimeout;
class LLUpdaterService;
-struct apr_dso_handle_t;
-
class LLAppViewer : public LLApp
{
public:
@@ -220,8 +218,6 @@ private:
void sendLogoutRequest();
void disconnectViewer();
-
- void loadEventHostModule(S32 listen_port);
// *FIX: the app viewer class should be some sort of singleton, no?
// Perhaps its child class is the singleton and this should be an abstract base.
@@ -251,6 +247,7 @@ private:
bool mPurgeOnExit;
bool mSavedFinalSnapshot;
+ bool mSavePerAccountSettings; // only save per account settings if login succeeded
bool mForceGraphicsDetail;
@@ -270,8 +267,6 @@ private:
LLAllocator mAlloc;
- std::set<struct apr_dso_handle_t*> mPlugins;
-
LLFrameTimer mMemCheckTimer;
boost::scoped_ptr<LLUpdaterService> mUpdater;
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp
index f618af9536..fdd4565e50 100755
--- a/indra/newview/llavataractions.cpp
+++ b/indra/newview/llavataractions.cpp
@@ -594,7 +594,7 @@ namespace action_give_inventory
}
S32 count = LLShareInfo::instance().mAvatarNames.size();
- bool shared = false;
+ bool shared = count && !inventory_selected_uuids.empty();
// iterate through avatars
for(S32 i = 0; i < count; ++i)
@@ -616,8 +616,10 @@ namespace action_give_inventory
LLViewerInventoryCategory* inv_cat = gInventory.getCategory(*it);
if (inv_cat)
{
- LLGiveInventory::doGiveInventoryCategory(avatar_uuid, inv_cat, session_id);
- shared = true;
+ if (!LLGiveInventory::doGiveInventoryCategory(avatar_uuid, inv_cat, session_id, "ItemsShared"))
+ {
+ shared = false;
+ }
break;
}
LLViewerInventoryItem* inv_item = gInventory.getItem(*it);
@@ -632,8 +634,10 @@ namespace action_give_inventory
}
else
{
- LLGiveInventory::doGiveInventoryItem(avatar_uuid, inv_item, session_id);
- shared = true;
+ if (!LLGiveInventory::doGiveInventoryItem(avatar_uuid, inv_item, session_id))
+ {
+ shared = false;
+ }
}
}
if (noncopy_items.beginArray() != noncopy_items.endArray())
@@ -643,8 +647,10 @@ namespace action_give_inventory
LLSD payload;
payload["agent_id"] = avatar_uuid;
payload["items"] = noncopy_items;
+ payload["success_notification"] = "ItemsShared";
LLNotificationsUtil::add("CannotCopyWarning", substitutions, payload,
&LLGiveInventory::handleCopyProtectedItem);
+ shared = false;
break;
}
}
diff --git a/indra/newview/llavatarpropertiesprocessor.cpp b/indra/newview/llavatarpropertiesprocessor.cpp
index b1cd83a1fb..706bc42ea0 100644
--- a/indra/newview/llavatarpropertiesprocessor.cpp
+++ b/indra/newview/llavatarpropertiesprocessor.cpp
@@ -33,6 +33,7 @@
#include "llagentpicksinfo.h"
#include "lldateutil.h"
#include "llviewergenericmessage.h"
+#include "llstartup.h"
// Linden library includes
#include "llavatarconstants.h" // AVATAR_TRANSACTED, etc.
@@ -113,6 +114,14 @@ void LLAvatarPropertiesProcessor::sendGenericRequest(const LLUUID& avatar_id, EA
void LLAvatarPropertiesProcessor::sendAvatarPropertiesRequest(const LLUUID& avatar_id)
{
+ // this is the startup state when send_complete_agent_movement() message is sent.
+ // Before this, the AvatarPropertiesRequest message
+ // won't work so don't bother trying
+ if (LLStartUp::getStartupState() <= STATE_AGENT_SEND)
+ {
+ return;
+ }
+
if (isPendingRequest(avatar_id, APT_PROPERTIES))
{
// waiting for a response, don't re-request
diff --git a/indra/newview/llcommandlineparser.cpp b/indra/newview/llcommandlineparser.cpp
index 65c61c4a8b..17d403bbe1 100644
--- a/indra/newview/llcommandlineparser.cpp
+++ b/indra/newview/llcommandlineparser.cpp
@@ -342,6 +342,15 @@ bool LLCommandLineParser::parseCommandLine(int argc, char **argv)
return parseAndStoreResults(clp);
}
+// TODO:
+// - Break out this funky parsing logic into separate method
+// - Unit-test it with tests like LLStringUtil::getTokens() (the command-line
+// overload that supports quoted tokens)
+// - Unless this logic offers significant semantic benefits, replace it with
+// LLStringUtil::getTokens(). This would fix a known bug: you cannot --set a
+// string-valued variable to the empty string, because empty strings are
+// eliminated below.
+
bool LLCommandLineParser::parseCommandLineString(const std::string& str)
{
// Split the string content into tokens
diff --git a/indra/newview/lldebugview.cpp b/indra/newview/lldebugview.cpp
index 7d3170cb76..29b1d23d7d 100644
--- a/indra/newview/lldebugview.cpp
+++ b/indra/newview/lldebugview.cpp
@@ -68,8 +68,6 @@ LLDebugView::~LLDebugView()
gDebugView = NULL;
gTextureView = NULL;
gSceneView = NULL;
- gTextureSizeView = NULL;
- gTextureCategoryView = NULL;
}
void LLDebugView::init()
@@ -117,35 +115,11 @@ void LLDebugView::init()
LLTextureView::Params tvp;
tvp.name("gTextureView");
tvp.rect(r);
- tvp.follows.flags(FOLLOWS_BOTTOM|FOLLOWS_LEFT);
+ tvp.follows.flags(FOLLOWS_TOP|FOLLOWS_LEFT);
tvp.visible(false);
gTextureView = LLUICtrlFactory::create<LLTextureView>(tvp);
addChild(gTextureView);
//gTextureView->reshape(r.getWidth(), r.getHeight(), TRUE);
-
-
- if(gAuditTexture)
- {
- r.set(150, rect.getHeight() - 50, 900 + LLImageGL::sTextureLoadedCounter.size() * 30, 100);
- LLTextureSizeView::Params tsv ;
- tsv.name("gTextureSizeView");
- tsv.rect(r);
- tsv.follows.flags(FOLLOWS_BOTTOM|FOLLOWS_LEFT);
- tsv.visible(false);
- gTextureSizeView = LLUICtrlFactory::create<LLTextureSizeView>(tsv);
- addChild(gTextureSizeView);
- gTextureSizeView->setType(LLTextureSizeView::TEXTURE_MEM_OVER_SIZE) ;
-
- r.set(150, rect.getHeight() - 50, 900 + LLViewerTexture::getTotalNumOfCategories() * 30, 100);
- LLTextureSizeView::Params tcv ;
- tcv.name("gTextureCategoryView");
- tcv.rect(r);
- tcv.follows.flags(FOLLOWS_BOTTOM|FOLLOWS_LEFT);
- tcv.visible(false);
- gTextureCategoryView = LLUICtrlFactory::create<LLTextureSizeView>(tcv);
- gTextureCategoryView->setType(LLTextureSizeView::TEXTURE_MEM_OVER_CATEGORY);
- addChild(gTextureCategoryView);
- }
}
void LLDebugView::draw()
diff --git a/indra/newview/lldrawpoolbump.cpp b/indra/newview/lldrawpoolbump.cpp
index b58efe62ab..6f71e6ebc8 100644
--- a/indra/newview/lldrawpoolbump.cpp
+++ b/indra/newview/lldrawpoolbump.cpp
@@ -1341,8 +1341,7 @@ void LLBumpImageList::onSourceLoaded( BOOL success, LLViewerTexture *src_vi, LLI
// immediately assign bump to a global smart pointer in case some local smart pointer
// accidentally releases it.
LLPointer<LLViewerTexture> bump = LLViewerTextureManager::getLocalTexture( TRUE );
-
-
+
if (!LLPipeline::sRenderDeferred)
{
LLFastTimer t(FTM_BUMP_SOURCE_CREATE);
@@ -1351,6 +1350,10 @@ void LLBumpImageList::onSourceLoaded( BOOL success, LLViewerTexture *src_vi, LLI
}
else
{ //convert to normal map
+
+ //disable compression on normal maps to prevent errors below
+ bump->getGLTexture()->setAllowCompression(false);
+
{
LLFastTimer t(FTM_BUMP_SOURCE_CREATE);
bump->setExplicitFormat(GL_RGBA8, GL_ALPHA);
diff --git a/indra/newview/lldynamictexture.cpp b/indra/newview/lldynamictexture.cpp
index a93b2b71de..bf8338e5f2 100644
--- a/indra/newview/lldynamictexture.cpp
+++ b/indra/newview/lldynamictexture.cpp
@@ -216,12 +216,14 @@ BOOL LLViewerDynamicTexture::updateAllInstances()
return TRUE;
}
+#if 0 //THIS CAUSES MAINT-1092
bool use_fbo = gGLManager.mHasFramebufferObject && gPipeline.mWaterDis.isComplete();
if (use_fbo)
{
gPipeline.mWaterDis.bindTarget();
}
+#endif
LLGLSLShader::bindNoShader();
LLVertexBuffer::unbind();
@@ -256,10 +258,12 @@ BOOL LLViewerDynamicTexture::updateAllInstances()
}
}
+#if 0
if (use_fbo)
{
gPipeline.mWaterDis.flush();
}
+#endif
return ret;
}
diff --git a/indra/newview/llexternaleditor.cpp b/indra/newview/llexternaleditor.cpp
index ed1d7e860a..9480e54809 100644
--- a/indra/newview/llexternaleditor.cpp
+++ b/indra/newview/llexternaleditor.cpp
@@ -29,6 +29,9 @@
#include "lltrans.h"
#include "llui.h"
+#include "llprocess.h"
+#include "llsdutil.h"
+#include <boost/foreach.hpp>
// static
const std::string LLExternalEditor::sFilenameMarker = "%s";
@@ -45,19 +48,8 @@ LLExternalEditor::EErrorCode LLExternalEditor::setCommand(const std::string& env
return EC_NOT_SPECIFIED;
}
- // Add the filename marker if missing.
- if (cmd.find(sFilenameMarker) == std::string::npos)
- {
- cmd += " \"" + sFilenameMarker + "\"";
- llinfos << "Adding the filename marker (" << sFilenameMarker << ")" << llendl;
- }
-
string_vec_t tokens;
- if (tokenize(tokens, cmd) < 2) // 2 = bin + at least one arg (%s)
- {
- llwarns << "Error parsing editor command" << llendl;
- return EC_PARSE_ERROR;
- }
+ tokenize(tokens, cmd);
// Check executable for existence.
std::string bin_path = tokens[0];
@@ -68,51 +60,48 @@ LLExternalEditor::EErrorCode LLExternalEditor::setCommand(const std::string& env
}
// Save command.
- mProcess.setExecutable(bin_path);
- mArgs.clear();
+ mProcessParams = LLProcess::Params();
+ mProcessParams.executable = bin_path;
for (size_t i = 1; i < tokens.size(); ++i)
{
- if (i > 1) mArgs += " ";
- mArgs += "\"" + tokens[i] + "\"";
+ mProcessParams.args.add(tokens[i]);
}
- llinfos << "Setting command [" << bin_path << " " << mArgs << "]" << llendl;
+
+ // Add the filename marker if missing.
+ if (cmd.find(sFilenameMarker) == std::string::npos)
+ {
+ mProcessParams.args.add(sFilenameMarker);
+ llinfos << "Adding the filename marker (" << sFilenameMarker << ")" << llendl;
+ }
+
+ llinfos << "Setting command [" << mProcessParams << "]" << llendl;
return EC_SUCCESS;
}
LLExternalEditor::EErrorCode LLExternalEditor::run(const std::string& file_path)
{
- std::string args = mArgs;
- if (mProcess.getExecutable().empty() || args.empty())
+ if (std::string(mProcessParams.executable).empty() || mProcessParams.args.empty())
{
llwarns << "Editor command not set" << llendl;
return EC_NOT_SPECIFIED;
}
- // Substitute the filename marker in the command with the actual passed file name.
- LLStringUtil::replaceString(args, sFilenameMarker, file_path);
-
- // Split command into separate tokens.
- string_vec_t tokens;
- tokenize(tokens, args);
+ // Copy params block so we can replace sFilenameMarker
+ LLProcess::Params params;
+ params.executable = mProcessParams.executable;
- // Set process arguments taken from the command.
- mProcess.clearArguments();
- for (string_vec_t::const_iterator arg_it = tokens.begin(); arg_it != tokens.end(); ++arg_it)
- {
- mProcess.addArgument(*arg_it);
- }
-
- // Run the editor.
- llinfos << "Running editor command [" << mProcess.getExecutable() + " " + args << "]" << llendl;
- int result = mProcess.launch();
- if (result == 0)
+ // Substitute the filename marker in the command with the actual passed file name.
+ BOOST_FOREACH(const std::string& arg, mProcessParams.args)
{
- // Prevent killing the process in destructor (will add it to the zombies list).
- mProcess.orphan();
+ std::string fixed(arg);
+ LLStringUtil::replaceString(fixed, sFilenameMarker, file_path);
+ params.args.add(fixed);
}
- return result == 0 ? EC_SUCCESS : EC_FAILED_TO_RUN;
+ // Run the editor. Prevent killing the process in destructor.
+ params.autokill = false;
+ return LLProcess::create(params) ? EC_SUCCESS : EC_FAILED_TO_RUN;
}
// static
@@ -130,6 +119,12 @@ std::string LLExternalEditor::getErrorMessage(EErrorCode code)
return LLTrans::getString("Unknown");
}
+// TODO:
+// - Unit-test this with tests like LLStringUtil::getTokens() (the
+// command-line overload that supports quoted tokens)
+// - Unless there are significant semantic differences, eliminate this method
+// and use LLStringUtil::getTokens() instead.
+
// static
size_t LLExternalEditor::tokenize(string_vec_t& tokens, const std::string& str)
{
diff --git a/indra/newview/llexternaleditor.h b/indra/newview/llexternaleditor.h
index ef5db56c6e..fd2c25020c 100644
--- a/indra/newview/llexternaleditor.h
+++ b/indra/newview/llexternaleditor.h
@@ -27,7 +27,7 @@
#ifndef LL_LLEXTERNALEDITOR_H
#define LL_LLEXTERNALEDITOR_H
-#include <llprocesslauncher.h>
+#include "llprocess.h"
/**
* Usage:
@@ -97,9 +97,7 @@ private:
*/
static const std::string sSetting;
-
- std::string mArgs;
- LLProcessLauncher mProcess;
+ LLProcess::Params mProcessParams;
};
#endif // LL_LLEXTERNALEDITOR_H
diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp
index 08f9d26705..ec2493dd2e 100644
--- a/indra/newview/llfeaturemanager.cpp
+++ b/indra/newview/llfeaturemanager.cpp
@@ -670,7 +670,14 @@ void LLFeatureManager::setGraphicsLevel(S32 level, bool skipFeatures)
switch (level)
{
case 0:
- maskFeatures("Low");
+ if (gGLManager.mGLVersion < 3.f || gGLManager.mIsIntel)
+ { //only use fixed function by default if GL version < 3.0 or this is an intel graphics chip
+ maskFeatures("LowFixedFunction");
+ }
+ else
+ { //same as low, but with "Basic Shaders" enabled
+ maskFeatures("Low");
+ }
break;
case 1:
maskFeatures("Mid");
@@ -779,6 +786,10 @@ void LLFeatureManager::applyBaseMasks()
{
maskFeatures("MapBufferRange");
}
+ if (gGLManager.mVRAM > 512)
+ {
+ maskFeatures("VRAMGT512");
+ }
// now mask by gpu string
// Replaces ' ' with '_' in mGPUString to deal with inability for parser to handle spaces
diff --git a/indra/newview/llfloaterbvhpreview.cpp b/indra/newview/llfloaterbvhpreview.cpp
index b050a638dc..ac33a05f42 100644
--- a/indra/newview/llfloaterbvhpreview.cpp
+++ b/indra/newview/llfloaterbvhpreview.cpp
@@ -416,6 +416,9 @@ void LLFloaterBvhPreview::draw()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::resetMotion()
{
+ if (!mAnimPreview)
+ return;
+
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
BOOL paused = avatarp->areAnimationsPaused();
@@ -535,6 +538,9 @@ BOOL LLFloaterBvhPreview::handleHover(S32 x, S32 y, MASK mask)
//-----------------------------------------------------------------------------
BOOL LLFloaterBvhPreview::handleScrollWheel(S32 x, S32 y, S32 clicks)
{
+ if (!mAnimPreview)
+ return false;
+
mAnimPreview->zoom((F32)clicks * -0.2f);
mAnimPreview->requestUpdate();
@@ -670,7 +676,7 @@ void LLFloaterBvhPreview::onCommitBaseAnim()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitLoop()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -689,7 +695,7 @@ void LLFloaterBvhPreview::onCommitLoop()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitLoopIn()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -709,7 +715,7 @@ void LLFloaterBvhPreview::onCommitLoopIn()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitLoopOut()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -729,7 +735,7 @@ void LLFloaterBvhPreview::onCommitLoopOut()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitName()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -770,7 +776,7 @@ void LLFloaterBvhPreview::onCommitEmote()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitPriority()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -784,7 +790,7 @@ void LLFloaterBvhPreview::onCommitPriority()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitEaseIn()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -799,7 +805,7 @@ void LLFloaterBvhPreview::onCommitEaseIn()
//-----------------------------------------------------------------------------
void LLFloaterBvhPreview::onCommitEaseOut()
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -814,7 +820,7 @@ void LLFloaterBvhPreview::onCommitEaseOut()
//-----------------------------------------------------------------------------
bool LLFloaterBvhPreview::validateEaseIn(const LLSD& data)
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return false;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
@@ -834,7 +840,7 @@ bool LLFloaterBvhPreview::validateEaseIn(const LLSD& data)
//-----------------------------------------------------------------------------
bool LLFloaterBvhPreview::validateEaseOut(const LLSD& data)
{
- if (!getEnabled())
+ if (!getEnabled() || !mAnimPreview)
return false;
LLVOAvatar* avatarp = mAnimPreview->getDummyAvatar();
diff --git a/indra/newview/llfloaterhardwaresettings.cpp b/indra/newview/llfloaterhardwaresettings.cpp
index f9a403cf9f..116bd241c4 100644
--- a/indra/newview/llfloaterhardwaresettings.cpp
+++ b/indra/newview/llfloaterhardwaresettings.cpp
@@ -37,6 +37,7 @@
#include "llspinctrl.h"
#include "llstartup.h"
#include "lltextbox.h"
+#include "llcombobox.h"
#include "pipeline.h"
// Linden library includes
@@ -99,6 +100,12 @@ void LLFloaterHardwareSettings::refreshEnabledState()
getChildView("vbo")->setEnabled(FALSE);
}
+ if (!LLFeatureManager::getInstance()->isFeatureAvailable("RenderCompressTextures") ||
+ !gGLManager.mHasVertexBufferObject)
+ {
+ getChildView("texture compression")->setEnabled(FALSE);
+ }
+
// if no windlight shaders, turn off nighttime brightness, gamma, and fog distance
LLSpinCtrl* gamma_ctrl = getChild<LLSpinCtrl>("gamma");
gamma_ctrl->setEnabled(!gPipeline.canUseWindLightShaders());
@@ -142,6 +149,13 @@ BOOL LLFloaterHardwareSettings::postBuild()
{
childSetAction("OK", onBtnOK, this);
+ if (gGLManager.mIsIntel || gGLManager.mGLVersion < 3.f)
+ { //remove FSAA settings above "4x"
+ LLComboBox* combo = getChild<LLComboBox>("fsaa");
+ combo->remove("8x");
+ combo->remove("16x");
+ }
+
refresh();
center();
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp
index 7448f2bb2a..4b8beba546 100755
--- a/indra/newview/llfloatermodelpreview.cpp
+++ b/indra/newview/llfloatermodelpreview.cpp
@@ -5053,15 +5053,7 @@ BOOL LLModelPreview::render()
LLRect preview_rect;
- LLFloaterModelWizard* floater_wizard = dynamic_cast<LLFloaterModelWizard*>(mFMP);
- if (floater_wizard)
- {
- preview_rect = floater_wizard->getPreviewRect();
- }
- else
- {
- preview_rect = mFMP->getChildView("preview_panel")->getRect();
- }
+ preview_rect = mFMP->getChildView("preview_panel")->getRect();
F32 aspect = (F32) preview_rect.getWidth()/preview_rect.getHeight();
@@ -5605,7 +5597,6 @@ void LLModelPreview::setPreviewLOD(S32 lod)
combo_box->setCurrentByIndex((NUM_LOD-1)-mPreviewLOD); // combo box list of lods is in reverse order
mFMP->childSetText("lod_file_" + lod_name[mPreviewLOD], mLODFile[mPreviewLOD]);
- // the wizard has three lod drop downs
LLComboBox* combo_box2 = mFMP->getChild<LLComboBox>("preview_lod_combo2");
combo_box2->setCurrentByIndex((NUM_LOD-1)-mPreviewLOD); // combo box list of lods is in reverse order
diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h
index 64324854a5..c522e6f734 100644
--- a/indra/newview/llfloatermodelpreview.h
+++ b/indra/newview/llfloatermodelpreview.h
@@ -30,12 +30,12 @@
#include "llfloaternamedesc.h"
#include "lldynamictexture.h"
-#include "llfloatermodelwizard.h"
#include "llquaternion.h"
#include "llmeshrepository.h"
#include "llmodel.h"
#include "llthread.h"
#include "llviewermenufile.h"
+#include "llfloatermodeluploadbase.h"
class LLComboBox;
class LLJoint;
@@ -390,9 +390,7 @@ private:
protected:
friend class LLModelLoader;
friend class LLFloaterModelPreview;
- friend class LLFloaterModelWizard;
friend class LLFloaterModelPreview::DecompRequest;
- friend class LLFloaterModelWizard::DecompRequest;
friend class LLPhysicsDecomp;
LLFloater* mFMP;
diff --git a/indra/newview/llfloatermodelwizard.cpp b/indra/newview/llfloatermodelwizard.cpp
deleted file mode 100644
index b517b78e5a..0000000000
--- a/indra/newview/llfloatermodelwizard.cpp
+++ /dev/null
@@ -1,795 +0,0 @@
-/**
- * @file llfloatermodelwizard.cpp
- * @author Leyla Farazha
- * @brief Implementation of the LLFloaterModelWizard class.
- *
- * $LicenseInfo:firstyear=2002&license=viewerlgpl$
- * Second Life Viewer Source Code
- * Copyright (C) 2010, Linden Research, Inc.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation;
- * version 2.1 of the License only.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
- * $/LicenseInfo$
- */
-
-
-#include "llviewerprecompiledheaders.h"
-
-#include "llbutton.h"
-#include "lldrawable.h"
-#include "llcheckboxctrl.h"
-#include "llcombobox.h"
-#include "llfloater.h"
-#include "llfloatermodelwizard.h"
-#include "llfloatermodelpreview.h"
-#include "llfloaterreg.h"
-#include "llsliderctrl.h"
-#include "lltoolmgr.h"
-#include "llviewerwindow.h"
-
-LLFloaterModelWizard* LLFloaterModelWizard::sInstance = NULL;
-
-static const std::string stateNames[]={
- "choose_file",
- "optimize",
- "physics",
- "review",
- "upload"};
-
-static void swap_controls(LLUICtrl* first_ctrl, LLUICtrl* second_ctrl, bool first_ctr_visible);
-
-LLFloaterModelWizard::LLFloaterModelWizard(const LLSD& key)
- : LLFloaterModelUploadBase(key)
- ,mRecalculateGeometryBtn(NULL)
- ,mRecalculatePhysicsBtn(NULL)
- ,mRecalculatingPhysicsBtn(NULL)
- ,mCalculateWeightsBtn(NULL)
- ,mCalculatingWeightsBtn(NULL)
- ,mChooseFilePreviewPanel(NULL)
- ,mOptimizePreviewPanel(NULL)
- ,mPhysicsPreviewPanel(NULL)
-{
- mLastEnabledState = CHOOSE_FILE;
- sInstance = this;
-
- mCommitCallbackRegistrar.add("Wizard.Choose", boost::bind(&LLFloaterModelWizard::setState, this, CHOOSE_FILE));
- mCommitCallbackRegistrar.add("Wizard.Optimize", boost::bind(&LLFloaterModelWizard::setState, this, OPTIMIZE));
- mCommitCallbackRegistrar.add("Wizard.Physics", boost::bind(&LLFloaterModelWizard::setState, this, PHYSICS));
- mCommitCallbackRegistrar.add("Wizard.Review", boost::bind(&LLFloaterModelWizard::setState, this, REVIEW));
- mCommitCallbackRegistrar.add("Wizard.Upload", boost::bind(&LLFloaterModelWizard::setState, this, UPLOAD));
-}
-LLFloaterModelWizard::~LLFloaterModelWizard()
-{
- sInstance = NULL;
-}
-void LLFloaterModelWizard::setState(int state)
-{
-
- mState = state;
-
- for(size_t t=0; t<LL_ARRAY_SIZE(stateNames); ++t)
- {
- LLView *view = getChildView(stateNames[t]+"_panel");
- if (view)
- {
- view->setVisible(state == (int) t ? TRUE : FALSE);
- }
- }
-
- LLView* current_preview_panel = NULL;
-
- if (state == CHOOSE_FILE)
- {
- mModelPreview->mViewOption["show_physics"] = false;
-
- current_preview_panel = mChooseFilePreviewPanel;
-
- getChildView("close")->setVisible(false);
- getChildView("back")->setVisible(true);
- getChildView("back")->setEnabled(false);
- getChildView("next")->setVisible(true);
- getChildView("upload")->setVisible(false);
- getChildView("cancel")->setVisible(true);
- mCalculateWeightsBtn->setVisible(false);
- mCalculatingWeightsBtn->setVisible(false);
- }
-
- if (state == OPTIMIZE)
- {
- if (mLastEnabledState < state)
- {
- mModelPreview->genLODs(-1);
- }
-
- mModelPreview->mViewOption["show_physics"] = false;
-
- current_preview_panel = mOptimizePreviewPanel;
-
- getChildView("back")->setVisible(true);
- getChildView("back")->setEnabled(true);
- getChildView("close")->setVisible(false);
- getChildView("next")->setVisible(true);
- getChildView("upload")->setVisible(false);
- getChildView("cancel")->setVisible(true);
- mCalculateWeightsBtn->setVisible(false);
- mCalculatingWeightsBtn->setVisible(false);
- }
-
- if (state == PHYSICS)
- {
- if (mLastEnabledState < state)
- {
- mModelPreview->setPhysicsFromLOD(1);
-
- // Trigger the recalculate physics when first entering
- // the Physics step.
- onClickRecalculatePhysics();
- }
-
- mModelPreview->mViewOption["show_physics"] = true;
-
- current_preview_panel = mPhysicsPreviewPanel;
-
- getChildView("next")->setVisible(false);
- getChildView("upload")->setVisible(false);
- getChildView("close")->setVisible(false);
- getChildView("back")->setVisible(true);
- getChildView("back")->setEnabled(true);
- getChildView("cancel")->setVisible(true);
- mCalculateWeightsBtn->setVisible(true);
- mCalculatingWeightsBtn->setVisible(false);
- }
-
- if (state == REVIEW)
- {
-
- mModelPreview->mViewOption["show_physics"] = false;
-
- getChildView("close")->setVisible(false);
- getChildView("next")->setVisible(false);
- getChildView("back")->setVisible(true);
- getChildView("back")->setEnabled(true);
- getChildView("upload")->setVisible(true);
- getChildView("cancel")->setVisible(true);
- mCalculateWeightsBtn->setVisible(false);
- mCalculatingWeightsBtn->setVisible(false);
- }
-
- if (state == UPLOAD)
- {
- getChildView("close")->setVisible(true);
- getChildView("next")->setVisible(false);
- getChildView("back")->setVisible(false);
- getChildView("upload")->setVisible(false);
- getChildView("cancel")->setVisible(false);
- mCalculateWeightsBtn->setVisible(false);
- mCalculatingWeightsBtn->setVisible(false);
- }
-
- if (current_preview_panel)
- {
- LLRect rect;
- current_preview_panel->localRectToOtherView(current_preview_panel->getLocalRect(), &rect, this);
-
- // Reduce the preview rect by 1 px to fit the borders
- rect.stretch(-1);
-
- if (rect != mPreviewRect)
- {
- mPreviewRect = rect;
- mModelPreview->refresh();
- }
- }
- updateButtons();
-}
-
-
-
-void LLFloaterModelWizard::updateButtons()
-{
- if (mLastEnabledState < mState)
- {
- mLastEnabledState = mState;
- }
-
- for(size_t i=0; i<LL_ARRAY_SIZE(stateNames); ++i)
- {
- LLButton *button = getChild<LLButton>(stateNames[i]+"_btn");
-
- if (i == mState)
- {
- button->setEnabled(TRUE);
- button->setToggleState(TRUE);
- }
- else if (i <= mLastEnabledState)
- {
- button->setEnabled(TRUE);
- button->setToggleState(FALSE);
- }
- else
- {
- button->setEnabled(FALSE);
- }
- }
-}
-
-void LLFloaterModelWizard::onClickSwitchToAdvanced()
-{
- LLFloaterModelPreview* floater_preview = LLFloaterReg::getTypedInstance<LLFloaterModelPreview>("upload_model");
- if (!floater_preview)
- {
- llwarns << "FLoater model preview not found." << llendl;
- return;
- }
-
- // Open floater model preview
- floater_preview->openFloater();
-
- // Close the wizard
- closeFloater();
-
- std::string filename = getChild<LLUICtrl>("lod_file")->getValue().asString();
- if (!filename.empty())
- {
- // Re-load the model to the floater model preview if it has been loaded
- // into the wizard.
- floater_preview->loadModel(3, filename);
- }
-}
-
-void LLFloaterModelWizard::onClickRecalculateGeometry()
-{
- S32 val = getChild<LLUICtrl>("accuracy_slider")->getValue().asInteger();
-
- mModelPreview->genLODs(-1, NUM_LOD - val);
-
- mModelPreview->refresh();
-}
-
-void LLFloaterModelWizard::onClickRecalculatePhysics()
-{
- // Hide the "Recalculate physics" button and show the "Recalculating..."
- // button instead.
- swap_controls(mRecalculatePhysicsBtn, mRecalculatingPhysicsBtn, false);
-
- executePhysicsStage("Decompose");
-}
-
-void LLFloaterModelWizard::onClickCalculateUploadFee()
-{
- swap_controls(mCalculateWeightsBtn, mCalculatingWeightsBtn, false);
-
- mModelPreview->rebuildUploadData();
-
- mUploadModelUrl.clear();
-
- gMeshRepo.uploadModel(mModelPreview->mUploadData, mModelPreview->mPreviewScale,
- true, false, false, mUploadModelUrl, false, getWholeModelFeeObserverHandle());
-}
-
-void LLFloaterModelWizard::loadModel()
-{
- mModelPreview->mLoading = TRUE;
-
- (new LLMeshFilePicker(mModelPreview, 3))->getFile();
-}
-
-void LLFloaterModelWizard::onClickCancel()
-{
- closeFloater();
-}
-
-void LLFloaterModelWizard::onClickBack()
-{
- setState(llmax((int) CHOOSE_FILE, mState-1));
-}
-
-void LLFloaterModelWizard::onClickNext()
-{
- setState(llmin((int) UPLOAD, mState+1));
-}
-
-bool LLFloaterModelWizard::onEnableNext()
-{
- return true;
-}
-
-bool LLFloaterModelWizard::onEnableBack()
-{
- return true;
-}
-
-
-//-----------------------------------------------------------------------------
-// handleMouseDown()
-//-----------------------------------------------------------------------------
-BOOL LLFloaterModelWizard::handleMouseDown(S32 x, S32 y, MASK mask)
-{
- if (mPreviewRect.pointInRect(x, y))
- {
- bringToFront( x, y );
- gFocusMgr.setMouseCapture(this);
- gViewerWindow->hideCursor();
- mLastMouseX = x;
- mLastMouseY = y;
- return TRUE;
- }
-
- return LLFloater::handleMouseDown(x, y, mask);
-}
-
-//-----------------------------------------------------------------------------
-// handleMouseUp()
-//-----------------------------------------------------------------------------
-BOOL LLFloaterModelWizard::handleMouseUp(S32 x, S32 y, MASK mask)
-{
- gFocusMgr.setMouseCapture(FALSE);
- gViewerWindow->showCursor();
- return LLFloater::handleMouseUp(x, y, mask);
-}
-
-//-----------------------------------------------------------------------------
-// handleHover()
-//-----------------------------------------------------------------------------
-BOOL LLFloaterModelWizard::handleHover (S32 x, S32 y, MASK mask)
-{
- MASK local_mask = mask & ~MASK_ALT;
-
- if (mModelPreview && hasMouseCapture())
- {
- if (local_mask == MASK_PAN)
- {
- // pan here
- mModelPreview->pan((F32)(x - mLastMouseX) * -0.005f, (F32)(y - mLastMouseY) * -0.005f);
- }
- else if (local_mask == MASK_ORBIT)
- {
- F32 yaw_radians = (F32)(x - mLastMouseX) * -0.01f;
- F32 pitch_radians = (F32)(y - mLastMouseY) * 0.02f;
-
- mModelPreview->rotate(yaw_radians, pitch_radians);
- }
- else
- {
-
- F32 yaw_radians = (F32)(x - mLastMouseX) * -0.01f;
- F32 zoom_amt = (F32)(y - mLastMouseY) * 0.02f;
-
- mModelPreview->rotate(yaw_radians, 0.f);
- mModelPreview->zoom(zoom_amt);
- }
-
-
- mModelPreview->refresh();
-
- LLUI::setMousePositionLocal(this, mLastMouseX, mLastMouseY);
- }
-
- if (!mPreviewRect.pointInRect(x, y) || !mModelPreview)
- {
- return LLFloater::handleHover(x, y, mask);
- }
- else if (local_mask == MASK_ORBIT)
- {
- gViewerWindow->setCursor(UI_CURSOR_TOOLCAMERA);
- }
- else if (local_mask == MASK_PAN)
- {
- gViewerWindow->setCursor(UI_CURSOR_TOOLPAN);
- }
- else
- {
- gViewerWindow->setCursor(UI_CURSOR_TOOLZOOMIN);
- }
-
- return TRUE;
-}
-
-//-----------------------------------------------------------------------------
-// handleScrollWheel()
-//-----------------------------------------------------------------------------
-BOOL LLFloaterModelWizard::handleScrollWheel(S32 x, S32 y, S32 clicks)
-{
- if (mPreviewRect.pointInRect(x, y) && mModelPreview)
- {
- mModelPreview->zoom((F32)clicks * -0.2f);
- mModelPreview->refresh();
- }
-
- return TRUE;
-}
-
-
-void LLFloaterModelWizard::initDecompControls()
-{
- LLSD key;
-
- static const LLCDStageData* stage = NULL;
- static S32 stage_count = 0;
-
- if (!stage && LLConvexDecomposition::getInstance() != NULL)
- {
- stage_count = LLConvexDecomposition::getInstance()->getStages(&stage);
- }
-
- static const LLCDParam* param = NULL;
- static S32 param_count = 0;
- if (!param && LLConvexDecomposition::getInstance() != NULL)
- {
- param_count = LLConvexDecomposition::getInstance()->getParameters(&param);
- }
-
- for (S32 j = stage_count-1; j >= 0; --j)
- {
- gMeshRepo.mDecompThread->mStageID[stage[j].mName] = j;
- // protected against stub by stage_count being 0 for stub above
- LLConvexDecomposition::getInstance()->registerCallback(j, LLPhysicsDecomp::llcdCallback);
-
- for (S32 i = 0; i < param_count; ++i)
- {
- if (param[i].mStage != j)
- {
- continue;
- }
-
- std::string name(param[i].mName ? param[i].mName : "");
- std::string description(param[i].mDescription ? param[i].mDescription : "");
-
- if (param[i].mType == LLCDParam::LLCD_FLOAT)
- {
- mDecompParams[param[i].mName] = LLSD(param[i].mDefault.mFloat);
- }
- else if (param[i].mType == LLCDParam::LLCD_INTEGER)
- {
- mDecompParams[param[i].mName] = LLSD(param[i].mDefault.mIntOrEnumValue);
- }
- else if (param[i].mType == LLCDParam::LLCD_BOOLEAN)
- {
- mDecompParams[param[i].mName] = LLSD(param[i].mDefault.mBool);
- }
- else if (param[i].mType == LLCDParam::LLCD_ENUM)
- {
- mDecompParams[param[i].mName] = LLSD(param[i].mDefault.mIntOrEnumValue);
- }
- }
- }
-
- mDecompParams["Simplify Method"] = 0; // set it to retain %
-}
-
-/*virtual*/
-void LLFloaterModelWizard::onPermissionsReceived(const LLSD& result)
-{
- std::string upload_status = result["mesh_upload_status"].asString();
- // BAP HACK: handle "" for case that MeshUploadFlag cap is broken.
- mHasUploadPerm = (("" == upload_status) || ("valid" == upload_status));
-
- getChildView("warning_label")->setVisible(!mHasUploadPerm);
- getChildView("warning_text")->setVisible(!mHasUploadPerm);
-}
-
-/*virtual*/
-void LLFloaterModelWizard::setPermissonsErrorStatus(U32 status, const std::string& reason)
-{
- llwarns << "LLFloaterModelWizard::setPermissonsErrorStatus(" << status << " : " << reason << ")" << llendl;
-}
-
-/*virtual*/
-void LLFloaterModelWizard::onModelPhysicsFeeReceived(const LLSD& result, std::string upload_url)
-{
- swap_controls(mCalculateWeightsBtn, mCalculatingWeightsBtn, true);
-
- // Enable the "Upload" buton if we have calculated the upload fee
- // and have the permission to upload.
- getChildView("upload")->setEnabled(mHasUploadPerm);
-
- mUploadModelUrl = upload_url;
-
- S32 fee = result["upload_price"].asInteger();
- childSetTextArg("review_fee", "[FEE]", llformat("%d", fee));
- childSetTextArg("charged_fee", "[FEE]", llformat("%d", fee));
-
- setState(REVIEW);
-}
-
-/*virtual*/
-void LLFloaterModelWizard::setModelPhysicsFeeErrorStatus(U32 status, const std::string& reason)
-{
- swap_controls(mCalculateWeightsBtn, mCalculatingWeightsBtn, true);
-
- // Disable the "Review" step if it has been previously enabled.
- modelChangedCallback();
-
- llwarns << "LLFloaterModelWizard::setModelPhysicsFeeErrorStatus(" << status << " : " << reason << ")" << llendl;
-
- setState(PHYSICS);
-}
-
-/*virtual*/
-void LLFloaterModelWizard::onModelUploadSuccess()
-{
- // success!
- setState(UPLOAD);
-}
-
-/*virtual*/
-void LLFloaterModelWizard::onModelUploadFailure()
-{
- // Failure. Make the user recalculate fees
- setState(PHYSICS);
- // Disable the "Review" step if it has been previously enabled.
- if (mLastEnabledState > PHYSICS)
- {
- mLastEnabledState = PHYSICS;
- }
-
- updateButtons();
-}
-
-//static
-void LLFloaterModelWizard::executePhysicsStage(std::string stage_name)
-{
- if (sInstance)
- {
- // Invert the slider value so that "performance" end is giving the least detailed physics,
- // and the "accuracy" end is giving the most detailed physics
- F64 physics_accuracy = 1 - sInstance->getChild<LLSliderCtrl>("physics_slider")->getValue().asReal();
-
- sInstance->mDecompParams["Retain%"] = physics_accuracy;
-
- if (!sInstance->mCurRequest.empty())
- {
- llinfos << "Decomposition request still pending." << llendl;
- return;
- }
-
- if (sInstance->mModelPreview)
- {
- for (S32 i = 0; i < sInstance->mModelPreview->mModel[LLModel::LOD_PHYSICS].size(); ++i)
- {
- LLModel* mdl = sInstance->mModelPreview->mModel[LLModel::LOD_PHYSICS][i];
- DecompRequest* request = new DecompRequest(stage_name, mdl);
- if(request->isValid())
- {
- sInstance->mCurRequest.insert(request);
- gMeshRepo.mDecompThread->submitRequest(request);
- }
- }
- }
- }
-}
-
-LLFloaterModelWizard::DecompRequest::DecompRequest(const std::string& stage, LLModel* mdl)
-{
- mStage = stage;
- mContinue = 1;
- mModel = mdl;
- mDecompID = &mdl->mDecompID;
- mParams = sInstance->mDecompParams;
-
- //copy out positions and indices
- assignData(mdl) ;
-}
-
-
-S32 LLFloaterModelWizard::DecompRequest::statusCallback(const char* status, S32 p1, S32 p2)
-{
- setStatusMessage(llformat("%s: %d/%d", status, p1, p2));
-
- return mContinue;
-}
-
-void LLFloaterModelWizard::DecompRequest::completed()
-{ //called from the main thread
- mModel->setConvexHullDecomposition(mHull);
-
- if (sInstance)
- {
- if (sInstance->mModelPreview)
- {
- sInstance->mModelPreview->mDirty = true;
- LLFloaterModelWizard::sInstance->mModelPreview->refresh();
- }
-
- sInstance->mCurRequest.erase(this);
- }
-
- if (mStage == "Decompose")
- {
- executePhysicsStage("Simplify");
- }
- else
- {
- // Decomp request is complete so we can enable the "Recalculate physics" button again.
- swap_controls(sInstance->mRecalculatePhysicsBtn, sInstance->mRecalculatingPhysicsBtn, true);
- }
-}
-
-
-BOOL LLFloaterModelWizard::postBuild()
-{
- childSetValue("import_scale", (F32) 0.67335826);
-
- getChild<LLUICtrl>("browse")->setCommitCallback(boost::bind(&LLFloaterModelWizard::loadModel, this));
- //getChild<LLUICtrl>("lod_file")->setCommitCallback(boost::bind(&LLFloaterModelWizard::loadModel, this));
- getChild<LLUICtrl>("cancel")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickCancel, this));
- getChild<LLUICtrl>("close")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickCancel, this));
- getChild<LLUICtrl>("back")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickBack, this));
- getChild<LLUICtrl>("next")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickNext, this));
- getChild<LLUICtrl>("preview_lod_combo")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onPreviewLODCommit, this, _1));
- getChild<LLUICtrl>("preview_lod_combo2")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onPreviewLODCommit, this, _1));
- getChild<LLUICtrl>("upload")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onUpload, this));
- getChild<LLUICtrl>("switch_to_advanced")->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickSwitchToAdvanced, this));
-
- mRecalculateGeometryBtn = getChild<LLButton>("recalculate_geometry_btn");
- mRecalculateGeometryBtn->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickRecalculateGeometry, this));
-
- mRecalculatePhysicsBtn = getChild<LLButton>("recalculate_physics_btn");
- mRecalculatePhysicsBtn->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickRecalculatePhysics, this));
-
- mRecalculatingPhysicsBtn = getChild<LLButton>("recalculating_physics_btn");
-
- mCalculateWeightsBtn = getChild<LLButton>("calculate");
- mCalculateWeightsBtn->setCommitCallback(boost::bind(&LLFloaterModelWizard::onClickCalculateUploadFee, this));
-
- mCalculatingWeightsBtn = getChild<LLButton>("calculating");
-
- mChooseFilePreviewPanel = getChild<LLView>("choose_file_preview_panel");
- mOptimizePreviewPanel = getChild<LLView>("optimize_preview_panel");
- mPhysicsPreviewPanel = getChild<LLView>("physics_preview_panel");
-
- LLUICtrl::EnableCallbackRegistry::ScopedRegistrar enable_registrar;
-
- enable_registrar.add("Next.OnEnable", boost::bind(&LLFloaterModelWizard::onEnableNext, this));
- enable_registrar.add("Back.OnEnable", boost::bind(&LLFloaterModelWizard::onEnableBack, this));
-
- mModelPreview = new LLModelPreview(512, 512, this);
- mModelPreview->setPreviewTarget(16.f);
- mModelPreview->setDetailsCallback(boost::bind(&LLFloaterModelWizard::setDetails, this, _1, _2, _3, _4, _5));
- mModelPreview->setModelLoadedCallback(boost::bind(&LLFloaterModelWizard::modelLoadedCallback, this));
- mModelPreview->setModelUpdatedCallback(boost::bind(&LLFloaterModelWizard::modelChangedCallback, this));
- mModelPreview->mViewOption["show_textures"] = true;
-
- center();
-
- setState(CHOOSE_FILE);
-
- childSetTextArg("import_dimensions", "[X]", LLStringUtil::null);
- childSetTextArg("import_dimensions", "[Y]", LLStringUtil::null);
- childSetTextArg("import_dimensions", "[Z]", LLStringUtil::null);
-
- initDecompControls();
-
- requestAgentUploadPermissions();
-
- return TRUE;
-}
-
-
-void LLFloaterModelWizard::setDetails(F32 x, F32 y, F32 z, F32 streaming_cost, F32 physics_cost)
-{
- // iterate through all the panels, setting the dimensions
- for(size_t t=0; t<LL_ARRAY_SIZE(stateNames); ++t)
- {
- LLPanel *panel = getChild<LLPanel>(stateNames[t]+"_panel");
- if (panel)
- {
- panel->childSetText("dimension_x", llformat("%.1f", x));
- panel->childSetText("dimension_y", llformat("%.1f", y));
- panel->childSetText("dimension_z", llformat("%.1f", z));
- }
- }
-
- childSetTextArg("review_prim_equiv", "[EQUIV]", llformat("%d", mModelPreview->mResourceCost));
-}
-
-void LLFloaterModelWizard::modelLoadedCallback()
-{
- mLastEnabledState = CHOOSE_FILE;
- updateButtons();
-}
-
-void LLFloaterModelWizard::modelChangedCallback()
-{
- // Don't allow to proceed to the "Review" step if the model has changed
- // but the new upload fee hasn't been calculated yet.
- if (mLastEnabledState > PHYSICS)
- {
- mLastEnabledState = PHYSICS;
- }
-
- getChildView("upload")->setEnabled(false);
-
- updateButtons();
-}
-
-void LLFloaterModelWizard::onUpload()
-{
- mModelPreview->rebuildUploadData();
-
- gMeshRepo.uploadModel(mModelPreview->mUploadData, mModelPreview->mPreviewScale,
- true, false, false, mUploadModelUrl, true,
- LLHandle<LLWholeModelFeeObserver>(), getWholeModelUploadObserverHandle());
-}
-
-void LLFloaterModelWizard::onPreviewLODCommit(LLUICtrl* ctrl)
-{
- if (!mModelPreview)
- {
- return;
- }
-
- S32 which_mode = 0;
-
- LLComboBox* combo = (LLComboBox*) ctrl;
-
- which_mode = (NUM_LOD-1)-combo->getFirstSelectedIndex(); // combo box list of lods is in reverse order
-
- mModelPreview->setPreviewLOD(which_mode);
-}
-
-void LLFloaterModelWizard::refresh()
-{
- if (mState == CHOOSE_FILE)
- {
- bool model_loaded = false;
-
- if (mModelPreview && mModelPreview->getLoadState() == LLModelLoader::DONE)
- {
- model_loaded = true;
- }
-
- getChildView("next")->setEnabled(model_loaded);
- }
-}
-
-void LLFloaterModelWizard::draw()
-{
- refresh();
-
- LLFloater::draw();
-
- if (mModelPreview && mState < REVIEW)
- {
- mModelPreview->update();
-
- gGL.color3f(1.f, 1.f, 1.f);
-
- gGL.getTexUnit(0)->bind(mModelPreview);
-
- gGL.begin( LLRender::QUADS );
- {
- gGL.texCoord2f(0.f, 1.f);
- gGL.vertex2i(mPreviewRect.mLeft, mPreviewRect.mTop);
- gGL.texCoord2f(0.f, 0.f);
- gGL.vertex2i(mPreviewRect.mLeft, mPreviewRect.mBottom);
- gGL.texCoord2f(1.f, 0.f);
- gGL.vertex2i(mPreviewRect.mRight, mPreviewRect.mBottom);
- gGL.texCoord2f(1.f, 1.f);
- gGL.vertex2i(mPreviewRect.mRight, mPreviewRect.mTop);
- }
- gGL.end();
-
- gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
- }
-}
-
-// static
-void swap_controls(LLUICtrl* first_ctrl, LLUICtrl* second_ctrl, bool first_ctr_visible)
-{
- first_ctrl->setVisible(first_ctr_visible);
- second_ctrl->setVisible(!first_ctr_visible);
-}
diff --git a/indra/newview/llfloatermodelwizard.h b/indra/newview/llfloatermodelwizard.h
deleted file mode 100644
index db9b605777..0000000000
--- a/indra/newview/llfloatermodelwizard.h
+++ /dev/null
@@ -1,140 +0,0 @@
-/**
- * @file llfloatermodelwizard.h
- *
- * $LicenseInfo:firstyear=2009&license=viewerlgpl$
- * Second Life Viewer Source Code
- * Copyright (C) 2010, Linden Research, Inc.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation;
- * version 2.1 of the License only.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
- * $/LicenseInfo$
- */
-
-#ifndef LLFLOATERMODELWIZARD_H
-#define LLFLOATERMODELWIZARD_H
-
-
-#include "llmeshrepository.h"
-#include "llmodel.h"
-#include "llthread.h"
-#include "llfloatermodeluploadbase.h"
-
-
-class LLModelPreview;
-
-
-class LLFloaterModelWizard : public LLFloaterModelUploadBase
-{
-public:
-
- class DecompRequest : public LLPhysicsDecomp::Request
- {
- public:
- S32 mContinue;
- LLPointer<LLModel> mModel;
-
- DecompRequest(const std::string& stage, LLModel* mdl);
- virtual S32 statusCallback(const char* status, S32 p1, S32 p2);
- virtual void completed();
-
- };
-
- static LLFloaterModelWizard* sInstance;
-
- LLFloaterModelWizard(const LLSD& key);
- virtual ~LLFloaterModelWizard();
- /*virtual*/ BOOL postBuild();
- void draw();
- void refresh();
-
- BOOL handleMouseDown(S32 x, S32 y, MASK mask);
- BOOL handleMouseUp(S32 x, S32 y, MASK mask);
- BOOL handleHover(S32 x, S32 y, MASK mask);
- BOOL handleScrollWheel(S32 x, S32 y, S32 clicks);
-
- void setDetails(F32 x, F32 y, F32 z, F32 streaming_cost, F32 physics_cost);
- void modelLoadedCallback();
- void modelChangedCallback();
- void initDecompControls();
-
- // shows warning message if agent has no permissions to upload model
- /*virtual*/ void onPermissionsReceived(const LLSD& result);
-
- // called when error occurs during permissions request
- /*virtual*/ void setPermissonsErrorStatus(U32 status, const std::string& reason);
-
- /*virtual*/ void onModelPhysicsFeeReceived(const LLSD& result, std::string upload_url);
-
- /*virtual*/ void setModelPhysicsFeeErrorStatus(U32 status, const std::string& reason);
-
- /*virtual*/ void onModelUploadSuccess();
-
- /*virtual*/ void onModelUploadFailure();
-
- const LLRect& getPreviewRect() const { return mPreviewRect; }
-
- LLPhysicsDecomp::decomp_params mDecompParams;
- std::set<LLPointer<DecompRequest> > mCurRequest;
- std::string mStatusMessage;
- static void executePhysicsStage(std::string stage_name);
-
-private:
- enum EWizardState
- {
- CHOOSE_FILE = 0,
- OPTIMIZE,
- PHYSICS,
- REVIEW,
- UPLOAD
- };
-
- void setState(int state);
- void updateButtons();
- void onClickSwitchToAdvanced();
- void onClickRecalculateGeometry();
- void onClickRecalculatePhysics();
- void onClickCalculateUploadFee();
- void onClickCancel();
- void onClickBack();
- void onClickNext();
- bool onEnableNext();
- bool onEnableBack();
- void loadModel();
- void onPreviewLODCommit(LLUICtrl*);
- void onUpload();
-
- LLModelPreview* mModelPreview;
- LLRect mPreviewRect;
- int mState;
-
- S32 mLastMouseX;
- S32 mLastMouseY;
-
- U32 mLastEnabledState;
-
- LLButton* mRecalculateGeometryBtn;
- LLButton* mRecalculatePhysicsBtn;
- LLButton* mRecalculatingPhysicsBtn;
- LLButton* mCalculateWeightsBtn;
- LLButton* mCalculatingWeightsBtn;
-
- LLView* mChooseFilePreviewPanel;
- LLView* mOptimizePreviewPanel;
- LLView* mPhysicsPreviewPanel;
-};
-
-
-#endif
diff --git a/indra/newview/llfloatertexturefetchdebugger.cpp b/indra/newview/llfloatertexturefetchdebugger.cpp
new file mode 100644
index 0000000000..2b34b72055
--- /dev/null
+++ b/indra/newview/llfloatertexturefetchdebugger.cpp
@@ -0,0 +1,390 @@
+/**
+ * @file llfloatertexturefetchdebugger.cpp
+ * @brief LLFloaterTextureFetchDebugger class definition
+ *
+ * $LicenseInfo:firstyear=2007&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2010, Linden Research, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation;
+ * version 2.1 of the License only.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llfloatertexturefetchdebugger.h"
+
+#include "lluictrlfactory.h"
+#include "llbutton.h"
+#include "llspinctrl.h"
+#include "llresmgr.h"
+
+#include "llmath.h"
+#include "llviewerwindow.h"
+#include "llappviewer.h"
+#include "lltexturefetch.h"
+#include "llviewercontrol.h"
+
+LLFloaterTextureFetchDebugger::LLFloaterTextureFetchDebugger(const LLSD& key)
+ : LLFloater(key),
+ mDebugger(NULL)
+{
+ setTitle("Texture Fetching Debugger Floater");
+
+ mCommitCallbackRegistrar.add("TexFetchDebugger.ChangeTexelPixelRatio", boost::bind(&LLFloaterTextureFetchDebugger::onChangeTexelPixelRatio, this));
+
+ mCommitCallbackRegistrar.add("TexFetchDebugger.Start", boost::bind(&LLFloaterTextureFetchDebugger::onClickStart, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.Clear", boost::bind(&LLFloaterTextureFetchDebugger::onClickClear, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.Close", boost::bind(&LLFloaterTextureFetchDebugger::onClickClose, this));
+
+ mCommitCallbackRegistrar.add("TexFetchDebugger.CacheRead", boost::bind(&LLFloaterTextureFetchDebugger::onClickCacheRead, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.CacheWrite", boost::bind(&LLFloaterTextureFetchDebugger::onClickCacheWrite, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.HTTPLoad", boost::bind(&LLFloaterTextureFetchDebugger::onClickHTTPLoad, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.Decode", boost::bind(&LLFloaterTextureFetchDebugger::onClickDecode, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.GLTexture", boost::bind(&LLFloaterTextureFetchDebugger::onClickGLTexture, this));
+
+ mCommitCallbackRegistrar.add("TexFetchDebugger.RefetchVisCache", boost::bind(&LLFloaterTextureFetchDebugger::onClickRefetchVisCache, this));
+ mCommitCallbackRegistrar.add("TexFetchDebugger.RefetchVisHTTP", boost::bind(&LLFloaterTextureFetchDebugger::onClickRefetchVisHTTP, this));
+}
+//----------------------------------------------
+
+BOOL LLFloaterTextureFetchDebugger::postBuild(void)
+{
+ mDebugger = LLAppViewer::getTextureFetch()->getFetchDebugger();
+
+ //set states for buttons
+ mButtonStateMap["start_btn"] = true;
+ mButtonStateMap["close_btn"] = true;
+ mButtonStateMap["clear_btn"] = true;
+ mButtonStateMap["cacheread_btn"] = false;
+ mButtonStateMap["cachewrite_btn"] = false;
+ mButtonStateMap["http_btn"] = false;
+ mButtonStateMap["decode_btn"] = false;
+ mButtonStateMap["gl_btn"] = false;
+
+ mButtonStateMap["refetchviscache_btn"] = true;
+ mButtonStateMap["refetchvishttp_btn"] = true;
+
+ updateButtons();
+
+ getChild<LLUICtrl>("texel_pixel_ratio")->setValue(gSavedSettings.getF32("TexelPixelRatio"));
+
+ return TRUE ;
+}
+
+LLFloaterTextureFetchDebugger::~LLFloaterTextureFetchDebugger()
+{
+ //stop everything
+ mDebugger->stopDebug();
+}
+
+void LLFloaterTextureFetchDebugger::updateButtons()
+{
+ for(std::map<std::string, bool>::iterator iter = mButtonStateMap.begin(); iter != mButtonStateMap.end(); ++iter)
+ {
+ if(iter->second)
+ {
+ childEnable(iter->first.c_str());
+ }
+ else
+ {
+ childDisable(iter->first.c_str());
+ }
+ }
+}
+
+void LLFloaterTextureFetchDebugger::disableButtons()
+{
+ childDisable("start_btn");
+ childDisable("clear_btn");
+ childDisable("cacheread_btn");
+ childDisable("cachewrite_btn");
+ childDisable("http_btn");
+ childDisable("decode_btn");
+ childDisable("gl_btn");
+ childDisable("refetchviscache_btn");
+ childDisable("refetchvishttp_btn");
+}
+
+void LLFloaterTextureFetchDebugger::idle()
+{
+ LLTextureFetchDebugger::e_debug_state state = mDebugger->getState();
+
+ if(mDebugger->update())
+ {
+ switch(state)
+ {
+ case LLTextureFetchDebugger::IDLE:
+ break;
+ case LLTextureFetchDebugger::READ_CACHE:
+ mButtonStateMap["cachewrite_btn"] = true;
+ mButtonStateMap["decode_btn"] = true;
+ updateButtons();
+ break;
+ case LLTextureFetchDebugger::WRITE_CACHE:
+ updateButtons();
+ break;
+ case LLTextureFetchDebugger::DECODING:
+ mButtonStateMap["gl_btn"] = true;
+ updateButtons();
+ break;
+ case LLTextureFetchDebugger::HTTP_FETCHING:
+ mButtonStateMap["cacheread_btn"] = true;
+ mButtonStateMap["cachewrite_btn"] = true;
+ mButtonStateMap["decode_btn"] = true;
+ updateButtons();
+ break;
+ case LLTextureFetchDebugger::GL_TEX:
+ updateButtons();
+ break;
+ case LLTextureFetchDebugger::REFETCH_VIS_CACHE:
+ updateButtons();
+ case LLTextureFetchDebugger::REFETCH_VIS_HTTP:
+ updateButtons();
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+//----------------------
+void LLFloaterTextureFetchDebugger::onChangeTexelPixelRatio()
+{
+ gSavedSettings.setF32("TexelPixelRatio", getChild<LLUICtrl>("texel_pixel_ratio")->getValue().asReal());
+}
+
+void LLFloaterTextureFetchDebugger::onClickStart()
+{
+ disableButtons();
+
+ mDebugger->startDebug();
+
+ mButtonStateMap["start_btn"] = false;
+ mButtonStateMap["cacheread_btn"] = true;
+ mButtonStateMap["http_btn"] = true;
+ updateButtons();
+}
+
+void LLFloaterTextureFetchDebugger::onClickClose()
+{
+ setVisible(FALSE);
+
+ //stop everything
+ mDebugger->stopDebug();
+}
+
+void LLFloaterTextureFetchDebugger::onClickClear()
+{
+ mButtonStateMap["start_btn"] = true;
+ mButtonStateMap["close_btn"] = true;
+ mButtonStateMap["clear_btn"] = true;
+ mButtonStateMap["cacheread_btn"] = false;
+ mButtonStateMap["cachewrite_btn"] = false;
+ mButtonStateMap["http_btn"] = false;
+ mButtonStateMap["decode_btn"] = false;
+ mButtonStateMap["gl_btn"] = false;
+ mButtonStateMap["refetchviscache_btn"] = true;
+ mButtonStateMap["refetchvishttp_btn"] = true;
+ updateButtons();
+
+ //stop everything
+ mDebugger->stopDebug();
+ mDebugger->clearHistory();
+}
+
+void LLFloaterTextureFetchDebugger::onClickCacheRead()
+{
+ disableButtons();
+
+ mDebugger->debugCacheRead();
+}
+
+void LLFloaterTextureFetchDebugger::onClickCacheWrite()
+{
+ disableButtons();
+
+ mDebugger->debugCacheWrite();
+}
+
+void LLFloaterTextureFetchDebugger::onClickHTTPLoad()
+{
+ disableButtons();
+
+ mDebugger->debugHTTP();
+}
+
+void LLFloaterTextureFetchDebugger::onClickDecode()
+{
+ disableButtons();
+
+ mDebugger->debugDecoder();
+}
+
+void LLFloaterTextureFetchDebugger::onClickGLTexture()
+{
+ disableButtons();
+
+ mDebugger->debugGLTextureCreation();
+}
+
+void LLFloaterTextureFetchDebugger::onClickRefetchVisCache()
+{
+ disableButtons();
+
+ mDebugger->debugRefetchVisibleFromCache();
+}
+
+void LLFloaterTextureFetchDebugger::onClickRefetchVisHTTP()
+{
+ disableButtons();
+
+ mDebugger->debugRefetchVisibleFromHTTP();
+}
+
+void LLFloaterTextureFetchDebugger::draw()
+{
+ //total number of fetched textures
+ {
+ getChild<LLUICtrl>("total_num_fetched_label")->setTextArg("[NUM]", llformat("%d", mDebugger->getNumFetchedTextures()));
+ }
+
+ //total number of fetching requests
+ {
+ getChild<LLUICtrl>("total_num_fetching_requests_label")->setTextArg("[NUM]", llformat("%d", mDebugger->getNumFetchingRequests()));
+ }
+
+ //total number of cache hits
+ {
+ getChild<LLUICtrl>("total_num_cache_hits_label")->setTextArg("[NUM]", llformat("%d", mDebugger->getNumCacheHits()));
+ }
+
+ //total number of visible textures
+ {
+ getChild<LLUICtrl>("total_num_visible_tex_label")->setTextArg("[NUM]", llformat("%d", mDebugger->getNumVisibleFetchedTextures()));
+ }
+
+ //total number of visible texture fetching requests
+ {
+ getChild<LLUICtrl>("total_num_visible_tex_fetch_req_label")->setTextArg("[NUM]", llformat("%d", mDebugger->getNumVisibleFetchingRequests()));
+ }
+
+ //total number of fetched data
+ {
+ getChild<LLUICtrl>("total_fetched_data_label")->setTextArg("[SIZE1]", llformat("%d", mDebugger->getFetchedData() >> 10));
+ getChild<LLUICtrl>("total_fetched_data_label")->setTextArg("[SIZE2]", llformat("%d", mDebugger->getDecodedData() >> 10));
+ getChild<LLUICtrl>("total_fetched_data_label")->setTextArg("[PIXEL]", llformat("%.3f", mDebugger->getFetchedPixels() / 1000000.f));
+ }
+
+ //total number of visible fetched data
+ {
+ getChild<LLUICtrl>("total_fetched_vis_data_label")->setTextArg("[SIZE1]", llformat("%d", mDebugger->getVisibleFetchedData() >> 10));
+ getChild<LLUICtrl>("total_fetched_vis_data_label")->setTextArg("[SIZE2]", llformat("%d", mDebugger->getVisibleDecodedData() >> 10));
+ }
+
+ //total number of rendered fetched data
+ {
+ getChild<LLUICtrl>("total_fetched_rendered_data_label")->setTextArg("[SIZE1]", llformat("%d", mDebugger->getRenderedData() >> 10));
+ getChild<LLUICtrl>("total_fetched_rendered_data_label")->setTextArg("[SIZE2]", llformat("%d", mDebugger->getRenderedDecodedData() >> 10));
+ getChild<LLUICtrl>("total_fetched_rendered_data_label")->setTextArg("[PIXEL]", llformat("%.3f", mDebugger->getRenderedPixels() / 1000000.f));
+ }
+
+ //total time on cache readings
+ if(mDebugger->getCacheReadTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_cache_read_label")->setTextArg("[TIME]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_cache_read_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getCacheReadTime()));
+ }
+
+ //total time on cache writings
+ if(mDebugger->getCacheWriteTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_cache_write_label")->setTextArg("[TIME]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_cache_write_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getCacheWriteTime()));
+ }
+
+ //total time on decoding
+ if(mDebugger->getDecodeTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_decode_label")->setTextArg("[TIME]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_decode_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getDecodeTime()));
+ }
+
+ //total time on gl texture creation
+ if(mDebugger->getGLCreationTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_gl_label")->setTextArg("[TIME]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_gl_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getGLCreationTime()));
+ }
+
+ //total time on HTTP fetching
+ if(mDebugger->getHTTPTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_http_label")->setTextArg("[TIME]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_http_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getHTTPTime()));
+ }
+
+ //total time on entire fetching
+ {
+ getChild<LLUICtrl>("total_time_fetch_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getTotalFetchingTime()));
+ }
+
+ //total time on refetching visible textures from cache
+ if(mDebugger->getRefetchVisCacheTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[TIME]", std::string("----"));
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[SIZE]", std::string("----"));
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[PIXEL]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getRefetchVisCacheTime()));
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[SIZE]", llformat("%d", mDebugger->getRefetchedData() >> 10));
+ getChild<LLUICtrl>("total_time_refetch_vis_cache_label")->setTextArg("[PIXEL]", llformat("%.3f", mDebugger->getRefetchedPixels() / 1000000.f));
+ }
+
+ //total time on refetching visible textures from http
+ if(mDebugger->getRefetchVisHTTPTime() < 0.f)
+ {
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[TIME]", std::string("----"));
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[SIZE]", std::string("----"));
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[PIXEL]", std::string("----"));
+ }
+ else
+ {
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[TIME]", llformat("%.3f", mDebugger->getRefetchVisHTTPTime()));
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[SIZE]", llformat("%d", mDebugger->getRefetchedData() >> 10));
+ getChild<LLUICtrl>("total_time_refetch_vis_http_label")->setTextArg("[PIXEL]", llformat("%.3f", mDebugger->getRefetchedPixels() / 1000000.f));
+ }
+
+ LLFloater::draw();
+}
diff --git a/indra/newview/llfloatertexturefetchdebugger.h b/indra/newview/llfloatertexturefetchdebugger.h
new file mode 100644
index 0000000000..33012c6a3d
--- /dev/null
+++ b/indra/newview/llfloatertexturefetchdebugger.h
@@ -0,0 +1,71 @@
+/**
+ * @file llfloatertexturefetchdebugger.h
+ * @brief texture fetching debugger window, debug use only
+ *
+ * $LicenseInfo:firstyear=2004&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2010, Linden Research, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation;
+ * version 2.1 of the License only.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
+ * $/LicenseInfo$
+ */
+
+#ifndef LL_FLOATER_TEXTURE_FETCH_DEBUGGER__H
+#define LL_FLOATER_TEXTURE_FETCH_DEBUGGER__H
+
+#include "llfloater.h"
+class LLTextureFetchDebugger;
+
+class LLFloaterTextureFetchDebugger : public LLFloater
+{
+ friend class LLFloaterReg;
+public:
+ /// initialize all the callbacks for the menu
+
+ virtual BOOL postBuild() ;
+ virtual void draw() ;
+
+ void onChangeTexelPixelRatio();
+
+ void onClickStart();
+ void onClickClear();
+ void onClickClose();
+
+ void onClickCacheRead();
+ void onClickCacheWrite();
+ void onClickHTTPLoad();
+ void onClickDecode();
+ void onClickGLTexture();
+
+ void onClickRefetchVisCache();
+ void onClickRefetchVisHTTP();
+public:
+ void idle() ;
+
+private:
+ LLFloaterTextureFetchDebugger(const LLSD& key);
+ virtual ~LLFloaterTextureFetchDebugger();
+
+ void updateButtons();
+ void disableButtons();
+
+private:
+ LLTextureFetchDebugger* mDebugger;
+ std::map<std::string, bool> mButtonStateMap;
+};
+
+#endif // LL_FLOATER_TEXTURE_FETCH_DEBUGGER__H
diff --git a/indra/newview/llfolderviewitem.cpp b/indra/newview/llfolderviewitem.cpp
index d2b4866987..515e544452 100644
--- a/indra/newview/llfolderviewitem.cpp
+++ b/indra/newview/llfolderviewitem.cpp
@@ -2183,14 +2183,8 @@ BOOL LLFolderViewFolder::addItem(LLFolderViewItem* item)
item->dirtyFilter();
- // Update the folder creation date if the folder has no creation date
- bool setting_date = false;
- const time_t item_creation_date = item->getCreationDate();
- if ((item_creation_date > 0) && (mCreationDate == 0))
- {
- setCreationDate(item_creation_date);
- setting_date = true;
- }
+ // Update the folder creation date if the child is newer than our current date
+ setCreationDate(llmax<time_t>(mCreationDate, item->getCreationDate()));
// Handle sorting
requestArrange();
@@ -2200,11 +2194,8 @@ BOOL LLFolderViewFolder::addItem(LLFolderViewItem* item)
LLFolderViewFolder* parentp = getParentFolder();
while (parentp)
{
- // Update the parent folder creation date
- if (setting_date && (parentp->mCreationDate == 0))
- {
- parentp->setCreationDate(item_creation_date);
- }
+ // Update the folder creation date if the child is newer than our current date
+ parentp->setCreationDate(llmax<time_t>(parentp->mCreationDate, item->getCreationDate()));
if (parentp->mSortFunction.isByDate())
{
diff --git a/indra/newview/llgiveinventory.cpp b/indra/newview/llgiveinventory.cpp
index 30858871ec..72bea8db10 100644
--- a/indra/newview/llgiveinventory.cpp
+++ b/indra/newview/llgiveinventory.cpp
@@ -220,17 +220,25 @@ bool LLGiveInventory::doGiveInventoryItem(const LLUUID& to_agent,
return res;
}
-void LLGiveInventory::doGiveInventoryCategory(const LLUUID& to_agent,
+bool LLGiveInventory::doGiveInventoryCategory(const LLUUID& to_agent,
const LLInventoryCategory* cat,
- const LLUUID& im_session_id)
+ const LLUUID& im_session_id,
+ const std::string& notification_name)
{
- if (!cat) return;
+ if (!cat)
+ {
+ return false;
+ }
llinfos << "LLGiveInventory::giveInventoryCategory() - "
<< cat->getUUID() << llendl;
- if (!isAgentAvatarValid()) return;
+ if (!isAgentAvatarValid())
+ {
+ return false;
+ }
+ bool give_successful = true;
// Test out how many items are being given.
LLViewerInventoryCategory::cat_array_t cats;
LLViewerInventoryItem::item_array_t items;
@@ -253,24 +261,24 @@ void LLGiveInventory::doGiveInventoryCategory(const LLUUID& to_agent,
if (!complete)
{
LLNotificationsUtil::add("IncompleteInventory");
- return;
+ give_successful = false;
}
count = items.count() + cats.count();
if (count > MAX_ITEMS)
{
LLNotificationsUtil::add("TooManyItems");
- return;
+ give_successful = false;
}
else if (count == 0)
{
LLNotificationsUtil::add("NoItems");
- return;
+ give_successful = false;
}
- else
+ else if (give_successful)
{
if (0 == giveable.countNoCopy())
{
- LLGiveInventory::commitGiveInventoryCategory(to_agent, cat, im_session_id);
+ give_successful = LLGiveInventory::commitGiveInventoryCategory(to_agent, cat, im_session_id);
}
else
{
@@ -279,9 +287,16 @@ void LLGiveInventory::doGiveInventoryCategory(const LLUUID& to_agent,
LLSD payload;
payload["agent_id"] = to_agent;
payload["folder_id"] = cat->getUUID();
+ if (!notification_name.empty())
+ {
+ payload["success_notification"] = notification_name;
+ }
LLNotificationsUtil::add("CannotCopyCountItems", args, payload, &LLGiveInventory::handleCopyProtectedCategory);
+ give_successful = false;
}
}
+
+ return give_successful;
}
//////////////////////////////////////////////////////////////////////////
@@ -325,6 +340,7 @@ bool LLGiveInventory::handleCopyProtectedItem(const LLSD& notification, const LL
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
LLSD itmes = notification["payload"]["items"];
LLInventoryItem* item = NULL;
+ bool give_successful = true;
switch(option)
{
case 0: // "Yes"
@@ -343,15 +359,21 @@ bool LLGiveInventory::handleCopyProtectedItem(const LLSD& notification, const LL
else
{
LLNotificationsUtil::add("CannotGiveItem");
+ give_successful = false;
}
}
+ if (give_successful && notification["payload"]["success_notification"].isDefined())
+ {
+ LLNotificationsUtil::add(notification["payload"]["success_notification"].asString());
+ }
break;
default: // no, cancel, whatever, who cares, not yes.
LLNotificationsUtil::add("TransactionCancelled");
+ give_successful = false;
break;
}
- return false;
+ return give_successful;
}
// static
@@ -408,13 +430,14 @@ bool LLGiveInventory::handleCopyProtectedCategory(const LLSD& notification, cons
{
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
LLInventoryCategory* cat = NULL;
+ bool give_successful = true;
switch(option)
{
case 0: // "Yes"
cat = gInventory.getCategory(notification["payload"]["folder_id"].asUUID());
if (cat)
{
- LLGiveInventory::commitGiveInventoryCategory(notification["payload"]["agent_id"].asUUID(),
+ give_successful = LLGiveInventory::commitGiveInventoryCategory(notification["payload"]["agent_id"].asUUID(),
cat);
LLViewerInventoryCategory::cat_array_t cats;
LLViewerInventoryItem::item_array_t items;
@@ -430,27 +453,37 @@ bool LLGiveInventory::handleCopyProtectedCategory(const LLSD& notification, cons
gInventory.deleteObject(items.get(i)->getUUID());
}
gInventory.notifyObservers();
+
+ if (give_successful && notification["payload"]["success_notification"].isDefined())
+ {
+ LLNotificationsUtil::add(notification["payload"]["success_notification"].asString());
+ }
}
else
{
LLNotificationsUtil::add("CannotGiveCategory");
+ give_successful = false;
}
break;
default: // no, cancel, whatever, who cares, not yes.
LLNotificationsUtil::add("TransactionCancelled");
+ give_successful = false;
break;
}
- return false;
+ return give_successful;
}
// static
-void LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent,
+bool LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent,
const LLInventoryCategory* cat,
const LLUUID& im_session_id)
{
- if (!cat) return;
+ if (!cat)
+ {
+ return false;
+ }
llinfos << "LLGiveInventory::commitGiveInventoryCategory() - "
<< cat->getUUID() << llendl;
@@ -467,6 +500,7 @@ void LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent,
LLInventoryModel::EXCLUDE_TRASH,
giveable);
+ bool give_successful = true;
// MAX ITEMS is based on (sizeof(uuid)+2) * count must be <
// MTUBYTES or 18 * count < 1200 => count < 1200/18 =>
// 66. I've cut it down a bit from there to give some pad.
@@ -474,12 +508,12 @@ void LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent,
if (count > MAX_ITEMS)
{
LLNotificationsUtil::add("TooManyItems");
- return;
+ give_successful = false;
}
else if (count == 0)
{
LLNotificationsUtil::add("NoItems");
- return;
+ give_successful = false;
}
else
{
@@ -545,6 +579,8 @@ void LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent,
logInventoryOffer(to_agent, im_session_id);
}
+
+ return give_successful;
}
// EOF
diff --git a/indra/newview/llgiveinventory.h b/indra/newview/llgiveinventory.h
index e1e221c75b..85bc1ed49c 100644
--- a/indra/newview/llgiveinventory.h
+++ b/indra/newview/llgiveinventory.h
@@ -62,9 +62,10 @@ public:
/**
* Gives passed inventory category to specified avatar in specified session.
*/
- static void doGiveInventoryCategory(const LLUUID& to_agent,
+ static bool doGiveInventoryCategory(const LLUUID& to_agent,
const LLInventoryCategory* item,
- const LLUUID &session_id = LLUUID::null);
+ const LLUUID &session_id = LLUUID::null,
+ const std::string& notification = std::string());
// give inventory item functionality
static bool handleCopyProtectedItem(const LLSD& notification, const LLSD& response);
@@ -85,7 +86,7 @@ private:
// give inventory category functionality
static bool handleCopyProtectedCategory(const LLSD& notification, const LLSD& response);
- static void commitGiveInventoryCategory(const LLUUID& to_agent,
+ static bool commitGiveInventoryCategory(const LLUUID& to_agent,
const LLInventoryCategory* cat,
const LLUUID &im_session_id = LLUUID::null);
diff --git a/indra/newview/llimfloatercontainer.cpp b/indra/newview/llimfloatercontainer.cpp
index c8e48b0d42..0f0ae896a2 100644
--- a/indra/newview/llimfloatercontainer.cpp
+++ b/indra/newview/llimfloatercontainer.cpp
@@ -119,6 +119,7 @@ void LLIMFloaterContainer::addFloater(LLFloater* floaterp,
void LLIMFloaterContainer::onCloseFloater(LLUUID& id)
{
mSessions.erase(id);
+ setFocus(TRUE);
}
void LLIMFloaterContainer::onNewMessageReceived(const LLSD& data)
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index a7c4618fa4..4000570872 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -3237,7 +3237,6 @@ public:
//just like a normal IM
//this is just replicated code from process_improved_im
//and should really go in it's own function -jwolk
- LLChat chat;
std::string message = message_params["message"].asString();
std::string name = message_params["from_name"].asString();
@@ -3255,14 +3254,7 @@ public:
name,
LLMute::flagTextChat);
- BOOL is_linden = LLMuteList::getInstance()->isLinden(name);
- std::string separator_string(": ");
-
- chat.mMuted = is_muted && !is_linden;
- chat.mFromID = from_id;
- chat.mFromName = name;
-
- if (!is_linden && is_busy)
+ if (is_busy || is_muted)
{
return;
}
diff --git a/indra/newview/llinspectobject.cpp b/indra/newview/llinspectobject.cpp
index acc139c569..a7b93b8030 100644
--- a/indra/newview/llinspectobject.cpp
+++ b/indra/newview/llinspectobject.cpp
@@ -111,6 +111,7 @@ private:
private:
LLUUID mObjectID;
+ LLUUID mPreviousObjectID;
S32 mObjectFace;
viewer_media_t mMediaImpl;
LLMediaEntry* mMediaEntry;
@@ -249,6 +250,7 @@ void LLInspectObject::onClose(bool app_quitting)
{
// Release selection to deselect
mObjectSelection = NULL;
+ mPreviousObjectID = mObjectID;
getChild<LLMenuButton>("gear_btn")->hideMenu();
}
@@ -266,6 +268,13 @@ void LLInspectObject::update()
LLSelectNode* nodep = selection->getFirstRootNode();
if (!nodep) return;
+ // If we don't have fresh object info yet and it's the object we inspected last time,
+ // keep showing the previously retrieved data until we get the update.
+ if (!nodep->mValid && nodep->getObject()->getID() == mPreviousObjectID)
+ {
+ return;
+ }
+
updateButtons(nodep);
updateName(nodep);
updateDescription(nodep);
diff --git a/indra/newview/llinventoryfilter.cpp b/indra/newview/llinventoryfilter.cpp
index 4d0af94f9f..4573074c73 100644
--- a/indra/newview/llinventoryfilter.cpp
+++ b/indra/newview/llinventoryfilter.cpp
@@ -654,7 +654,7 @@ void LLInventoryFilter::setHoursAgo(U32 hours)
bool are_date_limits_valid = mFilterOps.mMinDate == time_min() && mFilterOps.mMaxDate == time_max();
bool is_increasing = hours > mFilterOps.mHoursAgo;
- bool is_increasing_from_zero = is_increasing && !mFilterOps.mHoursAgo;
+ bool is_increasing_from_zero = is_increasing && !mFilterOps.mHoursAgo && !isSinceLogoff();
// *NOTE: need to cache last filter time, in case filter goes stale
BOOL less_restrictive = (are_date_limits_valid && ((is_increasing && mFilterOps.mHoursAgo)) || !hours);
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 85ecb133d0..8092f3bf36 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -1759,6 +1759,7 @@ bool LLInventoryModel::loadSkeleton(
update_map_t child_counts;
cat_array_t categories;
item_array_t items;
+ item_array_t possible_broken_links;
cat_set_t invalid_categories; // Used to mark categories that weren't successfully loaded.
std::string owner_id_str;
owner_id.toString(owner_id_str);
@@ -1807,7 +1808,7 @@ bool LLInventoryModel::loadSkeleton(
LLViewerInventoryCategory* tcat = *cit;
// we can safely ignore anything loaded from file, but
- // not sent down in the skeleton.
+ // not sent down in the skeleton. Must have been removed from inventory.
if(cit == not_cached)
{
continue;
@@ -1845,6 +1846,8 @@ bool LLInventoryModel::loadSkeleton(
// Add all the items loaded which are parented to a
// category with a correctly cached parent
S32 bad_link_count = 0;
+ S32 good_link_count = 0;
+ S32 recovered_link_count = 0;
cat_map_t::iterator unparented = mCategoryMap.end();
for(item_array_t::const_iterator item_iter = items.begin();
item_iter != items.end();
@@ -1861,26 +1864,56 @@ bool LLInventoryModel::loadSkeleton(
// This can happen if the linked object's baseobj is removed from the cache but the linked object is still in the cache.
if (item->getIsBrokenLink())
{
- bad_link_count++;
+ //bad_link_count++;
lldebugs << "Attempted to add cached link item without baseobj present ( name: "
<< item->getName() << " itemID: " << item->getUUID()
<< " assetID: " << item->getAssetUUID()
<< " ). Ignoring and invalidating " << cat->getName() << " . " << llendl;
- invalid_categories.insert(cit->second);
+ possible_broken_links.push_back(item);
continue;
}
+ else if (item->getIsLinkType())
+ {
+ good_link_count++;
+ }
addItem(item);
cached_item_count += 1;
++child_counts[cat->getUUID()];
}
}
}
- if (bad_link_count > 0)
+ if (possible_broken_links.size() > 0)
{
- llinfos << "Attempted to add " << bad_link_count
- << " cached link items without baseobj present. "
- << "The corresponding categories were invalidated." << llendl;
+ for(item_array_t::const_iterator item_iter = possible_broken_links.begin();
+ item_iter != possible_broken_links.end();
+ ++item_iter)
+ {
+ LLViewerInventoryItem *item = (*item_iter).get();
+ const cat_map_t::iterator cit = mCategoryMap.find(item->getParentUUID());
+ const LLViewerInventoryCategory* cat = cit->second.get();
+ if (item->getIsBrokenLink())
+ {
+ bad_link_count++;
+ invalid_categories.insert(cit->second);
+ //llinfos << "link still broken: " << item->getName() << " in folder " << cat->getName() << llendl;
+ }
+ else
+ {
+ // was marked as broken because of loading order, its actually fine to load
+ addItem(item);
+ cached_item_count += 1;
+ ++child_counts[cat->getUUID()];
+ recovered_link_count++;
+ }
+ }
+
+ llinfos << "Attempted to add " << bad_link_count
+ << " cached link items without baseobj present. "
+ << good_link_count << " link items were successfully added. "
+ << recovered_link_count << " links added in recovery. "
+ << "The corresponding categories were invalidated." << llendl;
}
+
}
else
{
@@ -2778,7 +2811,7 @@ void LLInventoryModel::processBulkUpdateInventory(LLMessageSystem* msg, void**)
{
LLPointer<LLViewerInventoryItem> titem = new LLViewerInventoryItem;
titem->unpackMessage(msg, _PREHASH_ItemData, i);
- llinfos << "unpaked item '" << titem->getName() << "' in "
+ llinfos << "unpacked item '" << titem->getName() << "' in "
<< titem->getParentUUID() << llendl;
U32 callback_id;
msg->getU32Fast(_PREHASH_ItemData, _PREHASH_CallbackID, callback_id);
diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp
index f461c7e46f..c899e8991e 100755
--- a/indra/newview/llmeshrepository.cpp
+++ b/indra/newview/llmeshrepository.cpp
@@ -1620,7 +1620,7 @@ void LLMeshUploadThread::doWholeModelUpload()
mCurlRequest->process();
//sleep for 10ms to prevent eating a whole core
apr_sleep(10000);
- } while (mCurlRequest->getQueued() > 0);
+ } while (!LLAppViewer::isQuitting() && mCurlRequest->getQueued() > 0);
}
delete mCurlRequest;
diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp
index 2a08cb1845..95caa2731a 100644
--- a/indra/newview/llnavigationbar.cpp
+++ b/indra/newview/llnavigationbar.cpp
@@ -267,7 +267,6 @@ LLNavigationBar::LLNavigationBar()
mBtnForward(NULL),
mBtnHome(NULL),
mCmbLocation(NULL),
- mPurgeTPHistoryItems(false),
mSaveToLocationHistory(false)
{
buildFromFile( "panel_navigation_bar.xml");
@@ -338,12 +337,6 @@ void LLNavigationBar::setVisible(BOOL visible)
void LLNavigationBar::draw()
{
- if(mPurgeTPHistoryItems)
- {
- LLTeleportHistory::getInstance()->purgeItems();
- mPurgeTPHistoryItems = false;
- }
-
if (isBackgroundVisible())
{
static LLUICachedControl<S32> drop_shadow_floater ("DropShadowFloater", 0);
@@ -687,7 +680,7 @@ void LLNavigationBar::clearHistoryCache()
LLLocationHistory* lh = LLLocationHistory::getInstance();
lh->removeItems();
lh->save();
- mPurgeTPHistoryItems= true;
+ LLTeleportHistory::getInstance()->purgeItems();
}
int LLNavigationBar::getDefNavBarHeight()
diff --git a/indra/newview/llnavigationbar.h b/indra/newview/llnavigationbar.h
index e4ce9e3998..7878bab24e 100644
--- a/indra/newview/llnavigationbar.h
+++ b/indra/newview/llnavigationbar.h
@@ -145,7 +145,6 @@ private:
boost::signals2::connection mTeleportFailedConnection;
boost::signals2::connection mTeleportFinishConnection;
boost::signals2::connection mHistoryMenuConnection;
- bool mPurgeTPHistoryItems;
// if true, save location to location history when teleport finishes
bool mSaveToLocationHistory;
};
diff --git a/indra/newview/llnearbychatbar.cpp b/indra/newview/llnearbychatbar.cpp
index b4224e30e6..00ff81724c 100644
--- a/indra/newview/llnearbychatbar.cpp
+++ b/indra/newview/llnearbychatbar.cpp
@@ -34,6 +34,7 @@
#include "llfirstuse.h"
#include "llnearbychatbar.h"
+#include "llnearbychatbarlistener.h"
#include "llagent.h"
#include "llgesturemgr.h"
#include "llmultigesture.h"
@@ -80,6 +81,7 @@ LLNearbyChatBar::LLNearbyChatBar(const LLSD& key)
mExpandedHeight(COLLAPSED_HEIGHT + EXPANDED_HEIGHT)
{
mSpeakerMgr = LLLocalSpeakerMgr::getInstance();
+ mListener.reset(new LLNearbyChatBarListener(*this));
}
//virtual
@@ -103,15 +105,17 @@ BOOL LLNearbyChatBar::postBuild()
mNearbyChat = getChildView("nearby_chat");
- LLUICtrl* show_btn = getChild<LLUICtrl>("show_nearby_chat");
+ gSavedSettings.declareBOOL("nearbychat_history_visibility", mNearbyChat->getVisible(), "Visibility state of nearby chat history", TRUE);
+ BOOL show_nearby_chat = gSavedSettings.getBOOL("nearbychat_history_visibility");
+
+ LLButton* show_btn = getChild<LLButton>("show_nearby_chat");
show_btn->setCommitCallback(boost::bind(&LLNearbyChatBar::onToggleNearbyChatPanel, this));
+ show_btn->setToggleState(show_nearby_chat);
mOutputMonitor = getChild<LLOutputMonitorCtrl>("chat_zone_indicator");
mOutputMonitor->setVisible(FALSE);
- gSavedSettings.declareBOOL("nearbychat_history_visibility", mNearbyChat->getVisible(), "Visibility state of nearby chat history", TRUE);
-
- mNearbyChat->setVisible(gSavedSettings.getBOOL("nearbychat_history_visibility"));
+ showNearbyChatPanel(show_nearby_chat);
// Register for font change notifications
LLViewerChat::setFontChangedCallback(boost::bind(&LLNearbyChatBar::onChatFontChange, this, _1));
@@ -392,26 +396,23 @@ void LLNearbyChatBar::sendChat( EChatType type )
}
}
-
-void LLNearbyChatBar::onToggleNearbyChatPanel()
+void LLNearbyChatBar::showNearbyChatPanel(bool show)
{
- LLView* nearby_chat = getChildView("nearby_chat");
-
- if (nearby_chat->getVisible())
+ if (!show)
{
- if (!isMinimized())
+ if (mNearbyChat->getVisible() && !isMinimized())
{
mExpandedHeight = getRect().getHeight();
}
setResizeLimits(getMinWidth(), COLLAPSED_HEIGHT);
- nearby_chat->setVisible(FALSE);
+ mNearbyChat->setVisible(FALSE);
reshape(getRect().getWidth(), COLLAPSED_HEIGHT);
enableResizeCtrls(true, true, false);
storeRectControl();
}
else
{
- nearby_chat->setVisible(TRUE);
+ mNearbyChat->setVisible(TRUE);
setResizeLimits(getMinWidth(), EXPANDED_MIN_HEIGHT);
reshape(getRect().getWidth(), mExpandedHeight);
enableResizeCtrls(true);
@@ -421,6 +422,11 @@ void LLNearbyChatBar::onToggleNearbyChatPanel()
gSavedSettings.setBOOL("nearbychat_history_visibility", mNearbyChat->getVisible());
}
+void LLNearbyChatBar::onToggleNearbyChatPanel()
+{
+ showNearbyChatPanel(!mNearbyChat->getVisible());
+}
+
void LLNearbyChatBar::setMinimized(BOOL b)
{
LLNearbyChat* nearby_chat = getChild<LLNearbyChat>("nearby_chat");
diff --git a/indra/newview/llnearbychatbar.h b/indra/newview/llnearbychatbar.h
index 8547cf0bce..662496d338 100644
--- a/indra/newview/llnearbychatbar.h
+++ b/indra/newview/llnearbychatbar.h
@@ -35,8 +35,12 @@
#include "lloutputmonitorctrl.h"
#include "llspeakers.h"
+class LLNearbyChatBarListener;
+
class LLNearbyChatBar : public LLFloater
{
+ LOG_CLASS(LLNearbyChatBar);
+
public:
// constructor for inline chat-bars (e.g. hosted in chat history window)
LLNearbyChatBar(const LLSD& key);
@@ -76,6 +80,7 @@ protected:
/* virtual */ bool applyRectControl();
+ void showNearbyChatPanel(bool show);
void onToggleNearbyChatPanel();
static LLWString stripChannelNumber(const LLWString &mesg, S32* channel);
@@ -92,6 +97,8 @@ protected:
LLLocalSpeakerMgr* mSpeakerMgr;
S32 mExpandedHeight;
+
+ boost::shared_ptr<LLNearbyChatBarListener> mListener;
};
#endif
diff --git a/indra/newview/llnotificationscripthandler.cpp b/indra/newview/llnotificationscripthandler.cpp
index 995915206b..398f54c6f7 100644
--- a/indra/newview/llnotificationscripthandler.cpp
+++ b/indra/newview/llnotificationscripthandler.cpp
@@ -101,7 +101,7 @@ bool LLScriptHandler::processNotification(const LLSD& notify)
}
else
{
- LLToastNotifyPanel* notify_box = new LLToastNotifyPanel(notification);
+ LLToastPanel* notify_box = LLToastPanel::buidPanelFromNotification(notification);
LLToast::Params p;
p.notif_id = notification->getID();
diff --git a/indra/newview/llpanelnearbymedia.cpp b/indra/newview/llpanelnearbymedia.cpp
index c01adc3c35..a50d9074f7 100644
--- a/indra/newview/llpanelnearbymedia.cpp
+++ b/indra/newview/llpanelnearbymedia.cpp
@@ -176,7 +176,7 @@ void LLPanelNearByMedia::handleMediaAutoPlayChanged(const LLSD& newvalue)
{
// update mParcelAudioAutoStart if AUTO_PLAY_MEDIA_SETTING changes
mParcelAudioAutoStart = gSavedSettings.getBOOL(LLViewerMedia::AUTO_PLAY_MEDIA_SETTING) &&
- gSavedSettings.getBOOL("MediaTentativeAutoPlay");
+ gSavedSettings.getBOOL("MediaTentativeAutoPlay");
}
/*virtual*/
diff --git a/indra/newview/llprogressview.cpp b/indra/newview/llprogressview.cpp
index 5d7a5b1c59..f86e583b9e 100644
--- a/indra/newview/llprogressview.cpp
+++ b/indra/newview/llprogressview.cpp
@@ -40,6 +40,7 @@
#include "llagent.h"
#include "llbutton.h"
+#include "llcallbacklist.h"
#include "llfocusmgr.h"
#include "llnotifications.h"
#include "llprogressbar.h"
@@ -72,6 +73,8 @@ LLProgressView::LLProgressView()
mStartupComplete(false)
{
mUpdateEvents.listen("self", boost::bind(&LLProgressView::handleUpdate, this, _1));
+ mFadeToWorldTimer.stop();
+ mFadeFromLoginTimer.stop();
}
BOOL LLProgressView::postBuild()
@@ -87,8 +90,6 @@ BOOL LLProgressView::postBuild()
mCancelBtn = getChild<LLButton>("cancel_btn");
mCancelBtn->setClickedCallback( LLProgressView::onCancelButtonClicked, NULL );
- mFadeToWorldTimer.stop();
- mFadeFromLoginTimer.stop();
getChild<LLTextBox>("title_text")->setText(LLStringExplicit(LLAppViewer::instance()->getSecondLifeTitle()));
@@ -106,6 +107,9 @@ BOOL LLProgressView::postBuild()
LLProgressView::~LLProgressView()
{
+ // Just in case something went wrong, make sure we deregister our idle callback.
+ gIdleCallbacks.deleteFunction(onIdle, this);
+
gFocusMgr.releaseFocusIfNeeded( this );
sInstance = NULL;
@@ -154,6 +158,7 @@ void LLProgressView::revealIntroPanel()
}
mFadeFromLoginTimer.start();
+ gIdleCallbacks.addFunction(onIdle, this);
}
void LLProgressView::setStartupComplete()
@@ -236,13 +241,6 @@ void LLProgressView::draw()
}
LLPanel::draw();
-
- if (mFadeFromLoginTimer.getElapsedTimeF32() > FADE_TO_WORLD_TIME )
- {
- mFadeFromLoginTimer.stop();
- LLPanelLogin::closePanel();
- }
-
return;
}
@@ -424,3 +422,21 @@ void LLProgressView::handleMediaEvent(LLPluginClassMedia* self, EMediaEvent even
}
}
}
+
+
+// static
+void LLProgressView::onIdle(void* user_data)
+{
+ LLProgressView* self = (LLProgressView*) user_data;
+
+ // Close login panel on mFadeToWorldTimer expiration.
+ if (self->mFadeFromLoginTimer.getStarted() &&
+ self->mFadeFromLoginTimer.getElapsedTimeF32() > FADE_TO_WORLD_TIME)
+ {
+ self->mFadeFromLoginTimer.stop();
+ LLPanelLogin::closePanel();
+
+ // Nothing to do anymore.
+ gIdleCallbacks.deleteFunction(onIdle, user_data);
+ }
+}
diff --git a/indra/newview/llprogressview.h b/indra/newview/llprogressview.h
index fac00ad04d..813576b21d 100644
--- a/indra/newview/llprogressview.h
+++ b/indra/newview/llprogressview.h
@@ -41,6 +41,8 @@ class LLProgressView :
public LLViewerMediaObserver
{
+ LOG_CLASS(LLProgressView);
+
public:
LLProgressView();
virtual ~LLProgressView();
@@ -74,10 +76,6 @@ public:
static void onClickMessage(void*);
bool onAlertModal(const LLSD& sd);
- // note - this is not just hiding the intro panel - it also hides the parent panel
- // and is used when the intro is finished and we want to show the world
- void removeIntroPanel();
-
protected:
LLProgressBar* mProgressBar;
LLMediaCtrl* mMediaCtrl;
@@ -96,6 +94,7 @@ protected:
LLEventStream mUpdateEvents;
bool handleUpdate(const LLSD& event_data);
+ static void onIdle(void* user_data);
};
#endif // LL_LLPROGRESSVIEW_H
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index 6111255a66..eec2c0a521 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -3051,11 +3051,11 @@ bool LLSelectMgr::confirmDelete(const LLSD& notification, const LLSD& response,
// TODO: Make sure you have delete permissions on all of them.
const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH);
// attempt to derez into the trash.
- LLDeRezInfo* info = new LLDeRezInfo(DRD_TRASH, trash_id);
+ LLDeRezInfo info(DRD_TRASH, trash_id);
LLSelectMgr::getInstance()->sendListToRegions("DeRezObject",
packDeRezHeader,
packObjectLocalID,
- (void*)info,
+ (void*) &info,
SEND_ONLY_ROOTS);
// VEFFECT: Delete Object - one effect for all deletes
if (LLSelectMgr::getInstance()->mSelectedObjects->mSelectType != SELECT_TYPE_HUD)
@@ -3745,13 +3745,15 @@ void LLSelectMgr::deselectAllIfTooFar()
void LLSelectMgr::selectionSetObjectName(const std::string& name)
{
+ std::string name_copy(name);
+
// we only work correctly if 1 object is selected.
if(mSelectedObjects->getRootObjectCount() == 1)
{
sendListToRegions("ObjectName",
packAgentAndSessionID,
packObjectName,
- (void*)(new std::string(name)),
+ (void*)(&name_copy),
SEND_ONLY_ROOTS);
}
else if(mSelectedObjects->getObjectCount() == 1)
@@ -3759,20 +3761,22 @@ void LLSelectMgr::selectionSetObjectName(const std::string& name)
sendListToRegions("ObjectName",
packAgentAndSessionID,
packObjectName,
- (void*)(new std::string(name)),
+ (void*)(&name_copy),
SEND_INDIVIDUALS);
}
}
void LLSelectMgr::selectionSetObjectDescription(const std::string& desc)
{
+ std::string desc_copy(desc);
+
// we only work correctly if 1 object is selected.
if(mSelectedObjects->getRootObjectCount() == 1)
{
sendListToRegions("ObjectDescription",
packAgentAndSessionID,
packObjectDescription,
- (void*)(new std::string(desc)),
+ (void*)(&desc_copy),
SEND_ONLY_ROOTS);
}
else if(mSelectedObjects->getObjectCount() == 1)
@@ -3780,7 +3784,7 @@ void LLSelectMgr::selectionSetObjectDescription(const std::string& desc)
sendListToRegions("ObjectDescription",
packAgentAndSessionID,
packObjectDescription,
- (void*)(new std::string(desc)),
+ (void*)(&desc_copy),
SEND_INDIVIDUALS);
}
}
@@ -4298,15 +4302,14 @@ void LLSelectMgr::packObjectName(LLSelectNode* node, void* user_data)
gMessageSystem->addU32Fast(_PREHASH_LocalID, node->getObject()->getLocalID());
gMessageSystem->addStringFast(_PREHASH_Name, *name);
}
- delete name;
}
// static
void LLSelectMgr::packObjectDescription(LLSelectNode* node, void* user_data)
{
const std::string* desc = (const std::string*)user_data;
- if(!desc->empty())
- {
+ if(desc)
+ { // Empty (non-null, but zero length) descriptions are OK
gMessageSystem->nextBlockFast(_PREHASH_ObjectData);
gMessageSystem->addU32Fast(_PREHASH_LocalID, node->getObject()->getLocalID());
gMessageSystem->addStringFast(_PREHASH_Description, *desc);
diff --git a/indra/newview/llsidepaneltaskinfo.cpp b/indra/newview/llsidepaneltaskinfo.cpp
index 24cb559fd0..64b82aa0bb 100644
--- a/indra/newview/llsidepaneltaskinfo.cpp
+++ b/indra/newview/llsidepaneltaskinfo.cpp
@@ -94,7 +94,7 @@ BOOL LLSidepanelTaskInfo::postBuild()
mPayBtn = getChild<LLButton>("pay_btn");
mPayBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onPayButtonClicked, this));
mBuyBtn = getChild<LLButton>("buy_btn");
- mBuyBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onBuyButtonClicked, this));
+ mBuyBtn->setClickedCallback(boost::bind(&handle_buy));
mDetailsBtn = getChild<LLButton>("details_btn");
mDetailsBtn->setClickedCallback(boost::bind(&LLSidepanelTaskInfo::onDetailsButtonClicked, this));
@@ -1114,8 +1114,6 @@ void LLSidepanelTaskInfo::doClickAction(U8 click_action)
// Set click action back to its old value
U8 click_action = 0;
LLSelectMgr::getInstance()->selectionGetClickAction(&click_action);
-// box->setCurrentByIndex((S32)click_action);
-
return;
}
}
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp
index 5d196a465f..8e62b79d7f 100644
--- a/indra/newview/llspatialpartition.cpp
+++ b/indra/newview/llspatialpartition.cpp
@@ -1186,6 +1186,7 @@ void LLSpatialGroup::clearOcclusionState(U32 state, S32 mode)
//======================================
LLSpatialGroup::LLSpatialGroup(OctreeNode* node, LLSpatialPartition* part) :
+ mObjectBoxSize(1.f),
mState(0),
mGeometryBytes(0),
mSurfaceArea(0.f),
@@ -3647,6 +3648,110 @@ void renderShadowFrusta(LLDrawInfo* params)
gGL.setSceneBlendType(LLRender::BT_ALPHA);
}
+void renderTexelDensity(LLDrawable* drawable)
+{
+ if (LLViewerTexture::sDebugTexelsMode == LLViewerTexture::DEBUG_TEXELS_OFF
+ || LLViewerTexture::sCheckerBoardImagep.isNull())
+ {
+ return;
+ }
+
+ LLGLEnable _(GL_BLEND);
+ //gObjectFullbrightProgram.bind();
+
+ LLMatrix4 checkerboard_matrix;
+ S32 discard_level = -1;
+
+ for (S32 f = 0; f < drawable->getNumFaces(); f++)
+ {
+ LLFace* facep = drawable->getFace(f);
+ LLVertexBuffer* buffer = facep->getVertexBuffer();
+ LLViewerTexture* texturep = facep->getTexture();
+
+ if (texturep == NULL) continue;
+
+ switch(LLViewerTexture::sDebugTexelsMode)
+ {
+ case LLViewerTexture::DEBUG_TEXELS_CURRENT:
+ discard_level = -1;
+ break;
+ case LLViewerTexture::DEBUG_TEXELS_DESIRED:
+ {
+ LLViewerFetchedTexture* fetched_texturep = dynamic_cast<LLViewerFetchedTexture*>(texturep);
+ discard_level = fetched_texturep ? fetched_texturep->getDesiredDiscardLevel() : -1;
+ break;
+ }
+ default:
+ case LLViewerTexture::DEBUG_TEXELS_FULL:
+ discard_level = 0;
+ break;
+ }
+
+ checkerboard_matrix.initScale(LLVector3(texturep->getWidth(discard_level) / 8, texturep->getHeight(discard_level) / 8, 1.f));
+
+ gGL.getTexUnit(0)->bind(LLViewerTexture::sCheckerBoardImagep, TRUE);
+ gGL.matrixMode(LLRender::MM_TEXTURE);
+ gGL.loadMatrix((GLfloat*)&checkerboard_matrix.mMatrix);
+
+ if (buffer && (facep->getGeomCount() >= 3))
+ {
+ buffer->setBuffer(LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0);
+ U16 start = facep->getGeomStart();
+ U16 end = start + facep->getGeomCount()-1;
+ U32 count = facep->getIndicesCount();
+ U16 offset = facep->getIndicesStart();
+ buffer->drawRange(LLRender::TRIANGLES, start, end, count, offset);
+ }
+
+ gGL.loadIdentity();
+ gGL.matrixMode(LLRender::MM_MODELVIEW);
+ }
+
+ //S32 num_textures = llmax(1, (S32)params->mTextureList.size());
+
+ //for (S32 i = 0; i < num_textures; i++)
+ //{
+ // LLViewerTexture* texturep = params->mTextureList.empty() ? params->mTexture.get() : params->mTextureList[i].get();
+ // if (texturep == NULL) continue;
+
+ // LLMatrix4 checkboard_matrix;
+ // S32 discard_level = -1;
+ // switch(LLViewerTexture::sDebugTexelsMode)
+ // {
+ // case LLViewerTexture::DEBUG_TEXELS_CURRENT:
+ // discard_level = -1;
+ // break;
+ // case LLViewerTexture::DEBUG_TEXELS_DESIRED:
+ // {
+ // LLViewerFetchedTexture* fetched_texturep = dynamic_cast<LLViewerFetchedTexture*>(texturep);
+ // discard_level = fetched_texturep ? fetched_texturep->getDesiredDiscardLevel() : -1;
+ // break;
+ // }
+ // default:
+ // case LLViewerTexture::DEBUG_TEXELS_FULL:
+ // discard_level = 0;
+ // break;
+ // }
+
+ // checkboard_matrix.initScale(LLVector3(texturep->getWidth(discard_level) / 8, texturep->getHeight(discard_level) / 8, 1.f));
+ // gGL.getTexUnit(i)->activate();
+
+ // glMatrixMode(GL_TEXTURE);
+ // glPushMatrix();
+ // glLoadIdentity();
+ // //gGL.matrixMode(LLRender::MM_TEXTURE);
+ // glLoadMatrixf((GLfloat*) checkboard_matrix.mMatrix);
+
+ // gGL.getTexUnit(i)->bind(LLViewerTexture::sCheckerBoardImagep, TRUE);
+
+ // pushVerts(params, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0 | LLVertexBuffer::MAP_COLOR | LLVertexBuffer::MAP_NORMAL );
+
+ // glPopMatrix();
+ // glMatrixMode(GL_MODELVIEW);
+ // //gGL.matrixMode(LLRender::MM_MODELVIEW);
+ //}
+}
+
void renderLights(LLDrawable* drawablep)
{
@@ -4042,6 +4147,10 @@ public:
{
renderComplexityDisplay(drawable);
}
+ if(gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY))
+ {
+ renderTexelDensity(drawable);
+ }
LLVOAvatar* avatar = dynamic_cast<LLVOAvatar*>(drawable->getVObj().get());
@@ -4291,7 +4400,8 @@ void LLSpatialPartition::renderDebug()
LLPipeline::RENDER_DEBUG_AGENT_TARGET |
//LLPipeline::RENDER_DEBUG_BUILD_QUEUE |
LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA |
- LLPipeline::RENDER_DEBUG_RENDER_COMPLEXITY))
+ LLPipeline::RENDER_DEBUG_RENDER_COMPLEXITY |
+ LLPipeline::RENDER_DEBUG_TEXEL_DENSITY))
{
return;
}
diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h
index 6c14ecf452..1a93145cc5 100644
--- a/indra/newview/llspatialpartition.h
+++ b/indra/newview/llspatialpartition.h
@@ -378,6 +378,8 @@ public:
LLVector4a mObjectBounds[2]; // bounding box (center, size) of objects in this node
LLVector4a mViewAngle;
LLVector4a mLastUpdateViewAngle;
+
+ F32 mObjectBoxSize; //cached mObjectBounds[1].getLength3()
private:
U32 mCurUpdatingTime ;
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 0ac8c1fe39..6b0fc26db7 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -240,6 +240,7 @@ static bool mLoginStatePastUI = false;
boost::scoped_ptr<LLEventPump> LLStartUp::sStateWatcher(new LLEventStream("StartupState"));
boost::scoped_ptr<LLStartupListener> LLStartUp::sListener(new LLStartupListener());
+boost::scoped_ptr<LLViewerStats::PhaseMap> LLStartUp::sPhases(new LLViewerStats::PhaseMap);
//
// local function declaration
@@ -2705,7 +2706,10 @@ void LLStartUp::setStartupState( EStartupState state )
LL_INFOS("AppInit") << "Startup state changing from " <<
getStartupStateString() << " to " <<
startupStateToString(state) << LL_ENDL;
+
+ sPhases->stopPhase(getStartupStateString());
gStartupState = state;
+ sPhases->startPhase(getStartupStateString());
postStartupState();
}
diff --git a/indra/newview/llstartup.h b/indra/newview/llstartup.h
index 0a18ef1b2d..3754aaf966 100644
--- a/indra/newview/llstartup.h
+++ b/indra/newview/llstartup.h
@@ -34,6 +34,8 @@ class LLEventPump;
class LLStartupListener;
class LLSLURL;
+#include "llviewerstats.h"
+
// functions
bool idle_startup();
void release_start_screen();
@@ -113,6 +115,7 @@ public:
static bool startLLProxy(); // Initialize the SOCKS 5 proxy
+ static LLViewerStats::PhaseMap& getPhases() { return *sPhases; }
private:
static LLSLURL sStartSLURL;
@@ -120,6 +123,7 @@ private:
static EStartupState gStartupState; // Do not set directly, use LLStartup::setStartupState
static boost::scoped_ptr<LLEventPump> sStateWatcher;
static boost::scoped_ptr<LLStartupListener> sListener;
+ static boost::scoped_ptr<LLViewerStats::PhaseMap> sPhases;
};
diff --git a/indra/newview/lltexlayer.cpp b/indra/newview/lltexlayer.cpp
index 6f6d5dbf12..467115c928 100644
--- a/indra/newview/lltexlayer.cpp
+++ b/indra/newview/lltexlayer.cpp
@@ -55,6 +55,9 @@ using namespace LLVOAvatarDefines;
static const S32 BAKE_UPLOAD_ATTEMPTS = 7;
static const F32 BAKE_UPLOAD_RETRY_DELAY = 2.f; // actual delay grows by power of 2 each attempt
+// runway consolidate
+extern std::string self_av_string();
+
class LLTexLayerInfo
{
friend class LLTexLayer;
@@ -494,7 +497,6 @@ void LLTexLayerSetBuffer::doUpload()
}
LLPointer<LLImageJ2C> compressedImage = new LLImageJ2C;
- compressedImage->setRate(0.f);
const char* comment_text = LINDEN_J2C_COMMENT_PREFIX "RGBHM"; // writes into baked_color_data. 5 channels (rgb, heightfield/alpha, mask)
if (compressedImage->encode(baked_image, comment_text))
{
@@ -577,7 +579,7 @@ void LLTexLayerSetBuffer::doUpload()
args["BODYREGION"] = mTexLayerSet->getBodyRegionName();
args["RESOLUTION"] = lod_str;
LLNotificationsUtil::add("AvatarRezSelfBakedTextureUploadNotification",args);
- llinfos << "Uploading [ name: " << mTexLayerSet->getBodyRegionName() << " res:" << lod_str << " time:" << (U32)mNeedsUploadTimer.getElapsedTimeF32() << " ]" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Uploading [ name: " << mTexLayerSet->getBodyRegionName() << " res:" << lod_str << " time:" << (U32)mNeedsUploadTimer.getElapsedTimeF32() << " ]" << LL_ENDL;
}
}
else
@@ -631,7 +633,7 @@ void LLTexLayerSetBuffer::doUpdate()
args["BODYREGION"] = mTexLayerSet->getBodyRegionName();
args["RESOLUTION"] = lod_str;
LLNotificationsUtil::add("AvatarRezSelfBakedTextureUpdateNotification",args);
- llinfos << "Locally updating [ name: " << mTexLayerSet->getBodyRegionName() << " res:" << lod_str << " time:" << (U32)mNeedsUpdateTimer.getElapsedTimeF32() << " ]" << llendl;
+ LL_DEBUGS("Avatar") << self_av_string() << "Locally updating [ name: " << mTexLayerSet->getBodyRegionName() << " res:" << lod_str << " time:" << (U32)mNeedsUpdateTimer.getElapsedTimeF32() << " ]" << LL_ENDL;
}
}
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp
index f18aa8b4e6..e2af497a7d 100644
--- a/indra/newview/lltexturefetch.cpp
+++ b/indra/newview/lltexturefetch.cpp
@@ -52,12 +52,20 @@
#include "llviewerstats.h"
#include "llviewerassetstats.h"
#include "llworld.h"
+#include "llsdutil.h"
+#include "llstartup.h"
+#include "llviewerstats.h"
+
+bool LLTextureFetchDebugger::sDebuggerEnabled = false ;
+LLStat LLTextureFetch::sCacheHitRate("texture_cache_hits", 128);
+LLStat LLTextureFetch::sCacheReadLatency("texture_cache_read_latency", 128);
//////////////////////////////////////////////////////////////////////////////
class LLTextureFetchWorker : public LLWorkerClass
{
friend class LLTextureFetch;
friend class HTTPGetResponder;
+ friend class LLTextureFetchDebugger;
private:
class CacheReadResponder : public LLTextureCache::ReadResponder
@@ -242,6 +250,8 @@ private:
S32 mDecodedDiscard;
LLFrameTimer mRequestedTimer;
LLFrameTimer mFetchTimer;
+ LLTimer mCacheReadTimer;
+ F32 mCacheReadTime;
LLTextureCache::handle_t mCacheReadHandle;
LLTextureCache::handle_t mCacheWriteHandle;
U8* mBuffer;
@@ -258,6 +268,7 @@ private:
BOOL mNeedsAux;
BOOL mHaveAllData;
BOOL mInLocalCache;
+ BOOL mInCache;
bool mCanUseHTTP ;
bool mCanUseNET ; //can get from asset server.
S32 mHTTPFailCount;
@@ -653,6 +664,7 @@ LLTextureFetchWorker::LLTextureFetchWorker(LLTextureFetch* fetcher,
mRequestedDiscard(-1),
mLoadedDiscard(-1),
mDecodedDiscard(-1),
+ mCacheReadTime(0.f),
mCacheReadHandle(LLTextureCache::nullHandle()),
mCacheWriteHandle(LLTextureCache::nullHandle()),
mBuffer(NULL),
@@ -669,6 +681,7 @@ LLTextureFetchWorker::LLTextureFetchWorker(LLTextureFetch* fetcher,
mNeedsAux(FALSE),
mHaveAllData(FALSE),
mInLocalCache(FALSE),
+ mInCache(FALSE),
mCanUseHTTP(true),
mHTTPFailCount(0),
mRetryAttempt(0),
@@ -838,6 +851,8 @@ void LLTextureFetchWorker::startWork(S32 param)
// Called from LLWorkerThread::processRequest()
bool LLTextureFetchWorker::doWork(S32 param)
{
+ static const F32 FETCHING_TIMEOUT = 120.f;//seconds
+
LLMutexLock lock(&mWorkMutex);
if ((mFetcher->isQuitting() || getFlags(LLWorkerClass::WCF_DELETE_REQUESTED)))
@@ -896,6 +911,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
mCacheReadHandle = LLTextureCache::nullHandle();
mCacheWriteHandle = LLTextureCache::nullHandle();
mState = LOAD_FROM_TEXTURE_CACHE;
+ mInCache = FALSE;
mDesiredSize = llmax(mDesiredSize, TEXTURE_CACHE_ENTRY_SIZE); // min desired size is TEXTURE_CACHE_ENTRY_SIZE
LL_DEBUGS("Texture") << mID << ": Priority: " << llformat("%8.0f",mImagePriority)
<< " Desired Discard: " << mDesiredDiscard << " Desired Size: " << mDesiredSize << LL_ENDL;
@@ -926,6 +942,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
CacheReadResponder* responder = new CacheReadResponder(mFetcher, mID, mFormattedImage);
mCacheReadHandle = mFetcher->mTextureCache->readFromCache(filename, mID, cache_priority,
offset, size, responder);
+ mCacheReadTimer.reset();
}
else if (mUrl.empty())
{
@@ -934,6 +951,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
CacheReadResponder* responder = new CacheReadResponder(mFetcher, mID, mFormattedImage);
mCacheReadHandle = mFetcher->mTextureCache->readFromCache(mID, cache_priority,
offset, size, responder);
+ mCacheReadTimer.reset();
}
else if(mCanUseHTTP)
{
@@ -982,11 +1000,12 @@ bool LLTextureFetchWorker::doWork(S32 param)
llassert_always(mFormattedImage->getDataSize() > 0);
mLoadedDiscard = mDesiredDiscard;
mState = DECODE_IMAGE;
+ mInCache = TRUE;
mWriteToCacheState = NOT_WRITE ;
LL_DEBUGS("Texture") << mID << ": Cached. Bytes: " << mFormattedImage->getDataSize()
<< " Size: " << llformat("%dx%d",mFormattedImage->getWidth(),mFormattedImage->getHeight())
<< " Desired Discard: " << mDesiredDiscard << " Desired Size: " << mDesiredSize << LL_ENDL;
- // fall through
+ LLTextureFetch::sCacheHitRate.addValue(100.f);
}
else
{
@@ -1002,6 +1021,7 @@ bool LLTextureFetchWorker::doWork(S32 param)
mState = LOAD_FROM_NETWORK;
}
// fall through
+ LLTextureFetch::sCacheHitRate.addValue(0.f);
}
}
@@ -1177,6 +1197,8 @@ bool LLTextureFetchWorker::doWork(S32 param)
bool res = false;
if (!mUrl.empty())
{
+ mRequestedTimer.reset();
+
mLoaded = FALSE;
mGetStatus = 0;
mGetReason.clear();
@@ -1335,6 +1357,13 @@ bool LLTextureFetchWorker::doWork(S32 param)
}
else
{
+ if(FETCHING_TIMEOUT < mRequestedTimer.getElapsedTimeF32())
+ {
+ //timeout, abort.
+ mState = DONE;
+ return true;
+ }
+
setPriority(LLWorkerThread::PRIORITY_LOW | mWorkPriority);
return false;
}
@@ -1396,6 +1425,11 @@ bool LLTextureFetchWorker::doWork(S32 param)
{
if (mDecoded)
{
+ if(mFetcher->getFetchDebugger() && !mInLocalCache)
+ {
+ mFetcher->getFetchDebugger()->addHistoryEntry(this);
+ }
+
if (mDecodedDiscard < 0)
{
LL_DEBUGS("Texture") << mID << ": Failed to Decode." << LL_ENDL;
@@ -1780,6 +1814,7 @@ void LLTextureFetchWorker::callbackDecoded(bool success, LLImageRaw* raw, LLImag
mDecoded = TRUE;
// llinfos << mID << " : DECODE COMPLETE " << llendl;
setPriority(LLWorkerThread::PRIORITY_HIGH | mWorkPriority);
+ mCacheReadTime = mCacheReadTimer.getElapsedTimeF32();
}
//////////////////////////////////////////////////////////////////////////////
@@ -1824,11 +1859,18 @@ LLTextureFetch::LLTextureFetch(LLTextureCache* cache, LLImageDecodeThread* image
mHTTPTextureBits(0),
mTotalHTTPRequests(0),
mCurlGetRequest(NULL),
- mQAMode(qa_mode)
+ mQAMode(qa_mode),
+ mFetchDebugger(NULL)
{
mCurlPOSTRequestCount = 0;
mMaxBandwidth = gSavedSettings.getF32("ThrottleBandwidthKBPS");
mTextureInfo.setUpLogging(gSavedSettings.getBOOL("LogTextureDownloadsToViewerLog"), gSavedSettings.getBOOL("LogTextureDownloadsToSimulator"), gSavedSettings.getU32("TextureLoggingThreshold"));
+
+ LLTextureFetchDebugger::sDebuggerEnabled = gSavedSettings.getBOOL("TextureFetchDebuggerEnabled");
+ if(LLTextureFetchDebugger::isEnabled())
+ {
+ mFetchDebugger = new LLTextureFetchDebugger(this, cache, imagedecodethread) ;
+ }
}
LLTextureFetch::~LLTextureFetch()
@@ -1843,11 +1885,17 @@ LLTextureFetch::~LLTextureFetch()
}
// ~LLQueuedThread() called here
+
+ delete mFetchDebugger;
}
bool LLTextureFetch::createRequest(const std::string& url, const LLUUID& id, const LLHost& host, F32 priority,
S32 w, S32 h, S32 c, S32 desired_discard, bool needs_aux, bool can_use_http)
{
+ if(mFetcherLocked)
+ {
+ return false;
+ }
if (mDebugPause)
{
return false;
@@ -2092,6 +2140,11 @@ bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level,
discard_level = worker->mDecodedDiscard;
raw = worker->mRawImage;
aux = worker->mAuxImage;
+ F32 cache_read_time = worker->mCacheReadTime;
+ if (cache_read_time != 0.f)
+ {
+ sCacheReadLatency.addValue(cache_read_time * 1000.f);
+ }
res = true;
LL_DEBUGS("Texture") << id << ": Request Finished. State: " << worker->mState << " Discard: " << discard_level << LL_ENDL;
worker->unlockWorkMutex();
@@ -2222,7 +2275,13 @@ S32 LLTextureFetch::update(F32 max_time_ms)
if (!mDebugPause)
{
- sendRequestListToSimulators();
+ // this is the startup state when send_complete_agent_movement() message is sent.
+ // Before this, the RequestImages message sent by sendRequestListToSimulators
+ // won't work so don't bother trying
+ if (LLStartUp::getStartupState() > STATE_AGENT_SEND)
+ {
+ sendRequestListToSimulators();
+ }
}
if (!mThreaded)
@@ -2258,6 +2317,11 @@ void LLTextureFetch::startThread()
{
// Construct mCurlGetRequest from Worker Thread
mCurlGetRequest = new LLCurlRequest();
+
+ if(mFetchDebugger)
+ {
+ mFetchDebugger->setCurlGetRequest(mCurlGetRequest);
+ }
}
// WORKER THREAD
@@ -2266,6 +2330,10 @@ void LLTextureFetch::endThread()
// Destroy mCurlGetRequest from Worker Thread
delete mCurlGetRequest;
mCurlGetRequest = NULL;
+ if(mFetchDebugger)
+ {
+ mFetchDebugger->setCurlGetRequest(NULL);
+ }
}
// WORKER THREAD
@@ -2803,7 +2871,6 @@ void LLTextureFetch::cmdDoWork()
}
}
-
//////////////////////////////////////////////////////////////////////////////
// Private (anonymous) class methods implementing the command scheme.
@@ -2959,7 +3026,7 @@ TFReqSendMetrics::doWork(LLTextureFetch * fetcher)
// In QA mode, Metrics submode, log the result for ease of testing
if (fetcher->isQAMode())
{
- LL_INFOS("Textures") << merged_llsd << LL_ENDL;
+ LL_INFOS("Textures") << ll_pretty_print_sd(merged_llsd) << LL_ENDL;
}
gViewerAssetStatsThread1->reset();
@@ -3007,5 +3074,659 @@ truncate_viewer_metrics(int max_regions, LLSD & metrics)
} // end of anonymous namespace
+///////////////////////////////////////////////////////////////////////////////////////////
+//Start LLTextureFetchDebugger
+///////////////////////////////////////////////////////////////////////////////////////////
+//---------------------
+class LLDebuggerCacheReadResponder : public LLTextureCache::ReadResponder
+{
+public:
+ LLDebuggerCacheReadResponder(LLTextureFetchDebugger* debugger, S32 id, LLImageFormatted* image)
+ : mDebugger(debugger), mID(id)
+ {
+ setImage(image);
+ }
+ virtual void completed(bool success)
+ {
+ mDebugger->callbackCacheRead(mID, success, mFormattedImage, mImageSize, mImageLocal);
+ }
+private:
+ LLTextureFetchDebugger* mDebugger;
+ S32 mID;
+};
+
+class LLDebuggerCacheWriteResponder : public LLTextureCache::WriteResponder
+{
+public:
+ LLDebuggerCacheWriteResponder(LLTextureFetchDebugger* debugger, S32 id)
+ : mDebugger(debugger), mID(id)
+ {
+ }
+ virtual void completed(bool success)
+ {
+ mDebugger->callbackCacheWrite(mID, success);
+ }
+private:
+ LLTextureFetchDebugger* mDebugger;
+ S32 mID;
+};
+
+class LLDebuggerDecodeResponder : public LLImageDecodeThread::Responder
+{
+public:
+ LLDebuggerDecodeResponder(LLTextureFetchDebugger* debugger, S32 id)
+ : mDebugger(debugger), mID(id)
+ {
+ }
+ virtual void completed(bool success, LLImageRaw* raw, LLImageRaw* aux)
+ {
+ mDebugger->callbackDecoded(mID, success, raw, aux);
+ }
+private:
+ LLTextureFetchDebugger* mDebugger;
+ S32 mID;
+};
+
+class LLDebuggerHTTPResponder : public LLCurl::Responder
+{
+public:
+ LLDebuggerHTTPResponder(LLTextureFetchDebugger* debugger, S32 index)
+ : mDebugger(debugger), mIndex(index)
+ {
+ }
+ virtual void completedRaw(U32 status, const std::string& reason,
+ const LLChannelDescriptors& channels,
+ const LLIOPipe::buffer_ptr_t& buffer)
+ {
+ bool success = false;
+ bool partial = false;
+ if (HTTP_OK <= status && status < HTTP_MULTIPLE_CHOICES)
+ {
+ success = true;
+ if (HTTP_PARTIAL_CONTENT == status) // partial information
+ {
+ partial = true;
+ }
+ }
+ if (!success)
+ {
+ llinfos << "Fetch Debugger : CURL GET FAILED, index = " << mIndex << ", status:" << status << " reason:" << reason << llendl;
+ }
+ mDebugger->callbackHTTP(mIndex, channels, buffer, partial, success);
+ }
+ virtual bool followRedir()
+ {
+ return true;
+ }
+private:
+ LLTextureFetchDebugger* mDebugger;
+ S32 mIndex;
+};
+
+LLTextureFetchDebugger::LLTextureFetchDebugger(LLTextureFetch* fetcher, LLTextureCache* cache, LLImageDecodeThread* imagedecodethread) :
+ mFetcher(fetcher),
+ mTextureCache(cache),
+ mImageDecodeThread(imagedecodethread),
+ mCurlGetRequest(NULL)
+{
+ init();
+}
+
+LLTextureFetchDebugger::~LLTextureFetchDebugger()
+{
+ mFetchingHistory.clear();
+ stopDebug();
+}
+
+void LLTextureFetchDebugger::init()
+{
+ mState = IDLE;
+
+ mCacheReadTime = -1.f;
+ mCacheWriteTime = -1.f;
+ mDecodingTime = -1.f;
+ mHTTPTime = -1.f;
+ mGLCreationTime = -1.f;
+ mTotalFetchingTime = 0.f;
+ mRefetchVisCacheTime = -1.f;
+ mRefetchVisHTTPTime = -1.f;
+
+ mNumFetchedTextures = 0;
+ mNumCacheHits = 0;
+ mNumVisibleFetchedTextures = 0;
+ mNumVisibleFetchingRequests = 0;
+ mFetchedData = 0;
+ mDecodedData = 0;
+ mVisibleFetchedData = 0;
+ mVisibleDecodedData = 0;
+ mRenderedData = 0;
+ mRenderedDecodedData = 0;
+ mFetchedPixels = 0;
+ mRenderedPixels = 0;
+ mRefetchedData = 0;
+ mRefetchedPixels = 0;
+
+ mFreezeHistory = FALSE;
+}
+
+void LLTextureFetchDebugger::startDebug()
+{
+ //lock the fetcher
+ mFetcher->lockFetcher(true);
+ mFreezeHistory = TRUE;
+
+ //clear the current fetching queue
+ gTextureList.clearFetchingRequests();
+
+ //wait for all works to be done
+ while(1)
+ {
+ S32 pending = 0;
+ pending += LLAppViewer::getTextureCache()->update(1);
+ pending += LLAppViewer::getImageDecodeThread()->update(1);
+ pending += LLAppViewer::getTextureFetch()->update(1);
+ if(!pending)
+ {
+ break;
+ }
+ }
+
+ //collect statistics
+ mTotalFetchingTime = gDebugTimers[0].getElapsedTimeF32() - mTotalFetchingTime;
+
+ std::set<LLUUID> fetched_textures;
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size; i++)
+ {
+ bool in_list = true;
+ if(fetched_textures.find(mFetchingHistory[i].mID) == fetched_textures.end())
+ {
+ fetched_textures.insert(mFetchingHistory[i].mID);
+ in_list = false;
+ }
+
+ LLViewerFetchedTexture* tex = LLViewerTextureManager::findFetchedTexture(mFetchingHistory[i].mID);
+ if(tex && tex->isJustBound()) //visible
+ {
+ if(!in_list)
+ {
+ mNumVisibleFetchedTextures++;
+ }
+ mNumVisibleFetchingRequests++;
+
+ mVisibleFetchedData += mFetchingHistory[i].mFetchedSize;
+ mVisibleDecodedData += mFetchingHistory[i].mDecodedSize;
+
+ if(tex->getDiscardLevel() >= mFetchingHistory[i].mDecodedLevel)
+ {
+ mRenderedData += mFetchingHistory[i].mFetchedSize;
+ mRenderedDecodedData += mFetchingHistory[i].mDecodedSize;
+ mRenderedPixels += tex->getWidth() * tex->getHeight();
+ }
+ }
+ }
+
+ mNumFetchedTextures = fetched_textures.size();
+}
+
+void LLTextureFetchDebugger::stopDebug()
+{
+ //clear the current debug work
+ S32 size = mFetchingHistory.size();
+ switch(mState)
+ {
+ case READ_CACHE:
+ for(S32 i = 0 ; i < size; i++)
+ {
+ if (mFetchingHistory[i]. mCacheHandle != LLTextureCache::nullHandle())
+ {
+ mTextureCache->readComplete(mFetchingHistory[i].mCacheHandle, true);
+ }
+ }
+ break;
+ case WRITE_CACHE:
+ for(S32 i = 0 ; i < size; i++)
+ {
+ if (mFetchingHistory[i].mCacheHandle != LLTextureCache::nullHandle())
+ {
+ mTextureCache->writeComplete(mFetchingHistory[i].mCacheHandle, true);
+ }
+ }
+ break;
+ case DECODING:
+ break;
+ case HTTP_FETCHING:
+ break;
+ case GL_TEX:
+ break;
+ default:
+ break;
+ }
+
+ while(1)
+ {
+ if(update())
+ {
+ break;
+ }
+ }
+
+ //unlock the fetcher
+ mFetcher->lockFetcher(false);
+ mFreezeHistory = FALSE;
+ mTotalFetchingTime = gDebugTimers[0].getElapsedTimeF32(); //reset
+}
+
+//called in the main thread and when the fetching queue is empty
+void LLTextureFetchDebugger::clearHistory()
+{
+ mFetchingHistory.clear();
+ init();
+}
+
+void LLTextureFetchDebugger::addHistoryEntry(LLTextureFetchWorker* worker)
+{
+ if(mFreezeHistory)
+ {
+ mRefetchedPixels += worker->mRawImage->getWidth() * worker->mRawImage->getHeight();
+ mRefetchedData += worker->mFormattedImage->getDataSize();
+ return;
+ }
+
+ if(worker->mInCache)
+ {
+ mNumCacheHits++;
+ }
+ mFetchedData += worker->mFormattedImage->getDataSize();
+ mDecodedData += worker->mRawImage->getDataSize();
+ mFetchedPixels += worker->mRawImage->getWidth() * worker->mRawImage->getHeight();
+
+ mFetchingHistory.push_back(FetchEntry(worker->mID, worker->mDesiredSize, worker->mDecodedDiscard, worker->mFormattedImage->getDataSize(), worker->mRawImage->getDataSize()));
+ //mFetchingHistory.push_back(FetchEntry(worker->mID, worker->mDesiredSize, worker->mHaveAllData ? 0 : worker->mLoadedDiscard, worker->mFormattedImage->getComponents(),
+ //worker->mDecodedDiscard, worker->mFormattedImage->getDataSize(), worker->mRawImage->getDataSize()));
+}
+
+void LLTextureFetchDebugger::lockCache()
+{
+}
+
+void LLTextureFetchDebugger::unlockCache()
+{
+}
+
+void LLTextureFetchDebugger::debugCacheRead()
+{
+ lockCache();
+ llassert_always(mState == IDLE);
+ mTimer.reset();
+ mState = READ_CACHE;
+
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ mFetchingHistory[i].mFormattedImage = NULL;
+ mFetchingHistory[i].mCacheHandle = mTextureCache->readFromCache(mFetchingHistory[i].mID, LLWorkerThread::PRIORITY_NORMAL, 0, mFetchingHistory[i].mFetchedSize,
+ new LLDebuggerCacheReadResponder(this, i, mFetchingHistory[i].mFormattedImage));
+ }
+}
+
+void LLTextureFetchDebugger::clearCache()
+{
+ S32 size = mFetchingHistory.size();
+ {
+ std::set<LLUUID> deleted_list;
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ if(deleted_list.find(mFetchingHistory[i].mID) == deleted_list.end())
+ {
+ deleted_list.insert(mFetchingHistory[i].mID);
+ mTextureCache->removeFromCache(mFetchingHistory[i].mID);
+ }
+ }
+ }
+}
+
+void LLTextureFetchDebugger::debugCacheWrite()
+{
+ //remove from cache
+ clearCache();
+
+ lockCache();
+ llassert_always(mState == IDLE);
+ mTimer.reset();
+ mState = WRITE_CACHE;
+
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ if(mFetchingHistory[i].mFormattedImage.notNull())
+ {
+ mFetchingHistory[i].mCacheHandle = mTextureCache->writeToCache(mFetchingHistory[i].mID, LLWorkerThread::PRIORITY_NORMAL,
+ mFetchingHistory[i].mFormattedImage->getData(), mFetchingHistory[i].mFetchedSize,
+ mFetchingHistory[i].mDecodedLevel == 0 ? mFetchingHistory[i].mFetchedSize : mFetchingHistory[i].mFetchedSize + 1,
+ new LLDebuggerCacheWriteResponder(this, i));
+ }
+ }
+}
+
+void LLTextureFetchDebugger::lockDecoder()
+{
+}
+
+void LLTextureFetchDebugger::unlockDecoder()
+{
+}
+
+void LLTextureFetchDebugger::debugDecoder()
+{
+ lockDecoder();
+ llassert_always(mState == IDLE);
+ mTimer.reset();
+ mState = DECODING;
+
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ if(mFetchingHistory[i].mFormattedImage.isNull())
+ {
+ continue;
+ }
+
+ mImageDecodeThread->decodeImage(mFetchingHistory[i].mFormattedImage, LLWorkerThread::PRIORITY_NORMAL,
+ mFetchingHistory[i].mDecodedLevel, mFetchingHistory[i].mNeedsAux,
+ new LLDebuggerDecodeResponder(this, i));
+ }
+}
+
+void LLTextureFetchDebugger::debugHTTP()
+{
+ llassert_always(mState == IDLE);
+
+ LLViewerRegion* region = gAgent.getRegion();
+ if (!region)
+ {
+ llinfos << "Fetch Debugger : Current region undefined. Cannot fetch textures through HTTP." << llendl;
+ return;
+ }
+
+ mHTTPUrl = region->getHttpUrl();
+ if (mHTTPUrl.empty())
+ {
+ llinfos << "Fetch Debugger : Current region URL undefined. Cannot fetch textures through HTTP." << llendl;
+ return;
+ }
+
+ mTimer.reset();
+ mState = HTTP_FETCHING;
+
+ S32 size = mFetchingHistory.size();
+ for (S32 i = 0 ; i < size ; i++)
+ {
+ mFetchingHistory[i].mCurlState = FetchEntry::CURL_NOT_DONE;
+ mFetchingHistory[i].mCurlReceivedSize = 0;
+ mFetchingHistory[i].mHTTPFailCount = 0;
+ }
+ mNbCurlRequests = 0;
+ mNbCurlCompleted = 0;
+
+ fillCurlQueue();
+}
+
+S32 LLTextureFetchDebugger::fillCurlQueue()
+{
+ if (mNbCurlRequests == 24)
+ return mNbCurlRequests;
+
+ S32 size = mFetchingHistory.size();
+ for (S32 i = 0 ; i < size ; i++)
+ {
+ if (mFetchingHistory[i].mCurlState != FetchEntry::CURL_NOT_DONE)
+ continue;
+ std::string texture_url = mHTTPUrl + "/?texture_id=" + mFetchingHistory[i].mID.asString().c_str();
+ S32 requestedSize = mFetchingHistory[i].mRequestedSize;
+ // We request the whole file if the size was not set.
+ requestedSize = llmax(0,requestedSize);
+ // We request the whole file if the size was set to an absurdly high value (meaning all file)
+ requestedSize = (requestedSize == 33554432 ? 0 : requestedSize);
+ std::vector<std::string> headers;
+ headers.push_back("Accept: image/x-j2c");
+ bool res = mCurlGetRequest->getByteRange(texture_url, headers, 0, requestedSize, new LLDebuggerHTTPResponder(this, i));
+ if (res)
+ {
+ mFetchingHistory[i].mCurlState = FetchEntry::CURL_IN_PROGRESS;
+ mNbCurlRequests++;
+ // Hack
+ if (mNbCurlRequests == 24)
+ break;
+ }
+ else
+ {
+ break;
+ }
+ }
+ //llinfos << "Fetch Debugger : Having " << mNbCurlRequests << " requests through the curl thread." << llendl;
+ return mNbCurlRequests;
+}
+
+void LLTextureFetchDebugger::debugGLTextureCreation()
+{
+ llassert_always(mState == IDLE);
+ mState = GL_TEX;
+ std::vector<LLViewerFetchedTexture*> tex_list;
+
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ if(mFetchingHistory[i].mRawImage.notNull())
+ {
+ LLViewerFetchedTexture* tex = gTextureList.findImage(mFetchingHistory[i].mID) ;
+ if(tex && !tex->isForSculptOnly())
+ {
+ tex->destroyGLTexture() ;
+ tex_list.push_back(tex);
+ }
+ }
+ }
+
+ mTimer.reset();
+ S32 j = 0 ;
+ S32 size1 = tex_list.size();
+ for(S32 i = 0 ; i < size && j < size1; i++)
+ {
+ if(mFetchingHistory[i].mRawImage.notNull())
+ {
+ if(mFetchingHistory[i].mID == tex_list[j]->getID())
+ {
+ tex_list[j]->createGLTexture(mFetchingHistory[i].mDecodedLevel, mFetchingHistory[i].mRawImage, 0, TRUE, tex_list[j]->getBoostLevel());
+ j++;
+ }
+ }
+ }
+
+ mGLCreationTime = mTimer.getElapsedTimeF32() ;
+ return;
+}
+
+//clear fetching results of all textures.
+void LLTextureFetchDebugger::clearTextures()
+{
+ S32 size = mFetchingHistory.size();
+ for(S32 i = 0 ; i < size ; i++)
+ {
+ LLViewerFetchedTexture* tex = gTextureList.findImage(mFetchingHistory[i].mID) ;
+ if(tex)
+ {
+ tex->clearFetchedResults() ;
+ }
+ }
+}
+
+void LLTextureFetchDebugger::debugRefetchVisibleFromCache()
+{
+ llassert_always(mState == IDLE);
+ mState = REFETCH_VIS_CACHE;
+
+ clearTextures();
+
+ mTimer.reset();
+ mFetcher->lockFetcher(false);
+}
+
+void LLTextureFetchDebugger::debugRefetchVisibleFromHTTP()
+{
+ llassert_always(mState == IDLE);
+ mState = REFETCH_VIS_HTTP;
+
+ clearCache();
+ clearTextures();
+
+ mTimer.reset();
+ mFetcher->lockFetcher(false);
+}
+
+bool LLTextureFetchDebugger::update()
+{
+ switch(mState)
+ {
+ case READ_CACHE:
+ if(!mTextureCache->update(1))
+ {
+ mCacheReadTime = mTimer.getElapsedTimeF32() ;
+ mState = IDLE;
+ unlockCache();
+ }
+ break;
+ case WRITE_CACHE:
+ if(!mTextureCache->update(1))
+ {
+ mCacheWriteTime = mTimer.getElapsedTimeF32() ;
+ mState = IDLE;
+ unlockCache();
+ }
+ break;
+ case DECODING:
+ if(!mImageDecodeThread->update(1))
+ {
+ mDecodingTime = mTimer.getElapsedTimeF32() ;
+ mState = IDLE;
+ unlockDecoder();
+ }
+ break;
+ case HTTP_FETCHING:
+ mCurlGetRequest->process();
+ LLCurl::getCurlThread()->update(1);
+ if (!fillCurlQueue() && mNbCurlCompleted == mFetchingHistory.size())
+ {
+ mHTTPTime = mTimer.getElapsedTimeF32() ;
+ mState = IDLE;
+ }
+ break;
+ case GL_TEX:
+ mState = IDLE;
+ break;
+ case REFETCH_VIS_CACHE:
+ if (LLAppViewer::getTextureFetch()->getNumRequests() == 0)
+ {
+ mRefetchVisCacheTime = gDebugTimers[0].getElapsedTimeF32() - mTotalFetchingTime;
+ mState = IDLE;
+ mFetcher->lockFetcher(true);
+ }
+ break;
+ case REFETCH_VIS_HTTP:
+ if (LLAppViewer::getTextureFetch()->getNumRequests() == 0)
+ {
+ mRefetchVisHTTPTime = gDebugTimers[0].getElapsedTimeF32() - mTotalFetchingTime;
+ mState = IDLE;
+ mFetcher->lockFetcher(true);
+ }
+ break;
+ default:
+ mState = IDLE;
+ break;
+ }
+
+ return mState == IDLE;
+}
+
+void LLTextureFetchDebugger::callbackCacheRead(S32 id, bool success, LLImageFormatted* image,
+ S32 imagesize, BOOL islocal)
+{
+ if (success)
+ {
+ mFetchingHistory[id].mFormattedImage = image;
+ }
+ mTextureCache->readComplete(mFetchingHistory[id].mCacheHandle, false);
+ mFetchingHistory[id].mCacheHandle = LLTextureCache::nullHandle();
+}
+
+void LLTextureFetchDebugger::callbackCacheWrite(S32 id, bool success)
+{
+ mTextureCache->writeComplete(mFetchingHistory[id].mCacheHandle);
+ mFetchingHistory[id].mCacheHandle = LLTextureCache::nullHandle();
+}
+
+void LLTextureFetchDebugger::callbackDecoded(S32 id, bool success, LLImageRaw* raw, LLImageRaw* aux)
+{
+ if (success)
+ {
+ llassert_always(raw);
+ mFetchingHistory[id].mRawImage = raw;
+ }
+}
+
+void LLTextureFetchDebugger::callbackHTTP(S32 id, const LLChannelDescriptors& channels,
+ const LLIOPipe::buffer_ptr_t& buffer,
+ bool partial, bool success)
+{
+ mNbCurlRequests--;
+ if (success)
+ {
+ mFetchingHistory[id].mCurlState = FetchEntry::CURL_DONE;
+ mNbCurlCompleted++;
+
+ S32 data_size = buffer->countAfter(channels.in(), NULL);
+ mFetchingHistory[id].mCurlReceivedSize += data_size;
+ //llinfos << "Fetch Debugger : got results for " << id << ", data_size = " << data_size << ", received = " << mFetchingHistory[id].mCurlReceivedSize << ", requested = " << mFetchingHistory[id].mRequestedSize << ", partial = " << partial << llendl;
+ if ((mFetchingHistory[id].mCurlReceivedSize >= mFetchingHistory[id].mRequestedSize) || !partial || (mFetchingHistory[id].mRequestedSize == 600))
+ {
+ U8* d_buffer = (U8*)ALLOCATE_MEM(LLImageBase::getPrivatePool(), data_size);
+ buffer->readAfter(channels.in(), NULL, d_buffer, data_size);
+
+ llassert_always(mFetchingHistory[id].mFormattedImage.isNull());
+ {
+ // For now, create formatted image based on extension
+ std::string texture_url = mHTTPUrl + "/?texture_id=" + mFetchingHistory[id].mID.asString().c_str();
+ std::string extension = gDirUtilp->getExtension(texture_url);
+ mFetchingHistory[id].mFormattedImage = LLImageFormatted::createFromType(LLImageBase::getCodecFromExtension(extension));
+ if (mFetchingHistory[id].mFormattedImage.isNull())
+ {
+ mFetchingHistory[id].mFormattedImage = new LLImageJ2C; // default
+ }
+ }
+
+ mFetchingHistory[id].mFormattedImage->setData(d_buffer, data_size);
+ }
+ }
+ else //failed
+ {
+ mFetchingHistory[id].mHTTPFailCount++;
+ if(mFetchingHistory[id].mHTTPFailCount < 5)
+ {
+ // Fetch will have to be redone
+ mFetchingHistory[id].mCurlState = FetchEntry::CURL_NOT_DONE;
+ }
+ else //skip
+ {
+ mFetchingHistory[id].mCurlState = FetchEntry::CURL_DONE;
+ mNbCurlCompleted++;
+ }
+ }
+}
+
+
+//---------------------
+///////////////////////////////////////////////////////////////////////////////////////////
+//End LLTextureFetchDebugger
+///////////////////////////////////////////////////////////////////////////////////////////
diff --git a/indra/newview/lltexturefetch.h b/indra/newview/lltexturefetch.h
index 35df7d816f..107e1623b0 100644
--- a/indra/newview/lltexturefetch.h
+++ b/indra/newview/lltexturefetch.h
@@ -34,14 +34,17 @@
#include "llcurl.h"
#include "lltextureinfo.h"
#include "llapr.h"
+#include "llimageworker.h"
+//#include "lltexturecache.h"
class LLViewerTexture;
class LLTextureFetchWorker;
class HTTPGetResponder;
-class LLTextureCache;
class LLImageDecodeThread;
class LLHost;
class LLViewerAssetStats;
+class LLTextureFetchDebugger;
+class LLTextureCache;
// Interface class
class LLTextureFetch : public LLWorkerThread
@@ -164,6 +167,9 @@ private:
LLMutex mQueueMutex; //to protect mRequestMap and mCommands only
LLMutex mNetworkQueueMutex; //to protect mNetworkQueue, mHTTPTextureQueue and mCancelQueue.
+ static LLStat sCacheHitRate;
+ static LLStat sCacheReadLatency;
+
LLTextureCache* mTextureCache;
LLImageDecodeThread* mImageDecodeThread;
LLCurlRequest* mCurlGetRequest;
@@ -209,7 +215,195 @@ public:
// attempt to log metrics follows a break in the metrics stream
// reporting due to either startup or a problem POSTing data.
static volatile bool svMetricsDataBreak;
+
+private:
+ //debug use
+ LLTextureFetchDebugger* mFetchDebugger;
+ bool mFetcherLocked;
+
+public:
+ //debug use
+ LLTextureFetchDebugger* getFetchDebugger() { return mFetchDebugger;}
+ void lockFetcher(bool lock) { mFetcherLocked = lock;}
};
+//debug use
+class LLTextureFetchDebugger
+{
+ friend class LLTextureFetch;
+public:
+ LLTextureFetchDebugger(LLTextureFetch* fetcher, LLTextureCache* cache, LLImageDecodeThread* imagedecodethread) ;
+ ~LLTextureFetchDebugger();
+
+public:
+ enum e_debug_state
+ {
+ IDLE = 0,
+ READ_CACHE,
+ WRITE_CACHE,
+ DECODING,
+ HTTP_FETCHING,
+ GL_TEX,
+ REFETCH_VIS_CACHE,
+ REFETCH_VIS_HTTP,
+ REFETCH_ALL_CACHE,
+ REFETCH_ALL_HTTP,
+ INVALID
+ };
+
+private:
+ struct FetchEntry
+ {
+ enum e_curl_state
+ {
+ CURL_NOT_DONE = 0,
+ CURL_IN_PROGRESS,
+ CURL_DONE
+ };
+ LLUUID mID;
+ S32 mRequestedSize;
+ S32 mDecodedLevel;
+ S32 mFetchedSize;
+ S32 mDecodedSize;
+ BOOL mNeedsAux;
+ U32 mCacheHandle;
+ LLPointer<LLImageFormatted> mFormattedImage;
+ LLPointer<LLImageRaw> mRawImage;
+ e_curl_state mCurlState;
+ S32 mCurlReceivedSize;
+ S32 mHTTPFailCount;
+
+ FetchEntry() :
+ mDecodedLevel(-1),
+ mFetchedSize(0),
+ mDecodedSize(0)
+ {}
+ FetchEntry(LLUUID& id, S32 r_size, /*S32 f_discard, S32 c,*/ S32 level, S32 f_size, S32 d_size) :
+ mID(id),
+ mRequestedSize(r_size),
+ mDecodedLevel(level),
+ mFetchedSize(f_size),
+ mDecodedSize(d_size),
+ mNeedsAux(false),
+ mHTTPFailCount(0)
+ {}
+ };
+ std::vector<FetchEntry> mFetchingHistory;
+
+ e_debug_state mState;
+
+ F32 mCacheReadTime;
+ F32 mCacheWriteTime;
+ F32 mDecodingTime;
+ F32 mHTTPTime;
+ F32 mGLCreationTime;
+
+ F32 mTotalFetchingTime;
+ F32 mRefetchVisCacheTime;
+ F32 mRefetchVisHTTPTime;
+
+ LLTimer mTimer;
+
+ LLTextureFetch* mFetcher;
+ LLTextureCache* mTextureCache;
+ LLImageDecodeThread* mImageDecodeThread;
+ LLCurlRequest* mCurlGetRequest;
+
+ S32 mNumFetchedTextures;
+ S32 mNumCacheHits;
+ S32 mNumVisibleFetchedTextures;
+ S32 mNumVisibleFetchingRequests;
+ U32 mFetchedData;
+ U32 mDecodedData;
+ U32 mVisibleFetchedData;
+ U32 mVisibleDecodedData;
+ U32 mRenderedData;
+ U32 mRenderedDecodedData;
+ U32 mFetchedPixels;
+ U32 mRenderedPixels;
+ U32 mRefetchedData;
+ U32 mRefetchedPixels;
+
+ BOOL mFreezeHistory;
+
+ std::string mHTTPUrl;
+ S32 mNbCurlRequests;
+ S32 mNbCurlCompleted;
+
+public:
+ bool update(); //called in the main thread once per frame
+
+ //fetching history
+ void clearHistory();
+ void addHistoryEntry(LLTextureFetchWorker* worker);
+
+ void setCurlGetRequest(LLCurlRequest* request) { mCurlGetRequest = request;}
+
+ void startDebug();
+ void stopDebug(); //stop everything
+ void debugCacheRead();
+ void debugCacheWrite();
+ void debugHTTP();
+ void debugDecoder();
+ void debugGLTextureCreation();
+ void debugRefetchVisibleFromCache();
+ void debugRefetchVisibleFromHTTP();
+
+ void callbackCacheRead(S32 id, bool success, LLImageFormatted* image,
+ S32 imagesize, BOOL islocal);
+ void callbackCacheWrite(S32 id, bool success);
+ void callbackDecoded(S32 id, bool success, LLImageRaw* raw, LLImageRaw* aux);
+ void callbackHTTP(S32 id, const LLChannelDescriptors& channels,
+ const LLIOPipe::buffer_ptr_t& buffer,
+ bool partial, bool success);
+
+
+ e_debug_state getState() {return mState;}
+ S32 getNumFetchedTextures() {return mNumFetchedTextures;}
+ S32 getNumFetchingRequests() {return mFetchingHistory.size();}
+ S32 getNumCacheHits() {return mNumCacheHits;}
+ S32 getNumVisibleFetchedTextures() {return mNumVisibleFetchedTextures;}
+ S32 getNumVisibleFetchingRequests() {return mNumVisibleFetchingRequests;}
+ U32 getFetchedData() {return mFetchedData;}
+ U32 getDecodedData() {return mDecodedData;}
+ U32 getVisibleFetchedData() {return mVisibleFetchedData;}
+ U32 getVisibleDecodedData() {return mVisibleDecodedData;}
+ U32 getRenderedData() {return mRenderedData;}
+ U32 getRenderedDecodedData() {return mRenderedDecodedData;}
+ U32 getFetchedPixels() {return mFetchedPixels;}
+ U32 getRenderedPixels() {return mRenderedPixels;}
+ U32 getRefetchedData() {return mRefetchedData;}
+ U32 getRefetchedPixels() {return mRefetchedPixels;}
+
+ F32 getCacheReadTime() {return mCacheReadTime;}
+ F32 getCacheWriteTime() {return mCacheWriteTime;}
+ F32 getDecodeTime() {return mDecodingTime;}
+ F32 getGLCreationTime() {return mGLCreationTime;}
+ F32 getHTTPTime() {return mHTTPTime;}
+ F32 getTotalFetchingTime() {return mTotalFetchingTime;}
+ F32 getRefetchVisCacheTime() {return mRefetchVisCacheTime;}
+ F32 getRefetchVisHTTPTime() {return mRefetchVisHTTPTime;}
+
+private:
+ void init();
+ void clearTextures();//clear fetching results of all textures.
+ void clearCache();
+
+ void lockFetcher();
+ void unlockFetcher();
+
+ void lockCache();
+ void unlockCache();
+
+ void lockDecoder();
+ void unlockDecoder();
+
+ S32 fillCurlQueue();
+
+private:
+ static bool sDebuggerEnabled;
+public:
+ static bool isEnabled() {return sDebuggerEnabled;}
+};
#endif // LL_LLTEXTUREFETCH_H
diff --git a/indra/newview/lltextureview.cpp b/indra/newview/lltextureview.cpp
index 5b41a05f2a..425bf7ee87 100644
--- a/indra/newview/lltextureview.cpp
+++ b/indra/newview/lltextureview.cpp
@@ -57,8 +57,6 @@
extern F32 texmem_lower_bound_scale;
LLTextureView *gTextureView = NULL;
-LLTextureSizeView *gTextureSizeView = NULL;
-LLTextureSizeView *gTextureCategoryView = NULL;
#define HIGH_PRIORITY 100000000.f
@@ -512,8 +510,8 @@ void LLGLTexMemBar::draw()
F32 discard_bias = LLViewerTexture::sDesiredDiscardBias;
F32 cache_usage = (F32)BYTES_TO_MEGA_BYTES(LLAppViewer::getTextureCache()->getUsage()) ;
F32 cache_max_usage = (F32)BYTES_TO_MEGA_BYTES(LLAppViewer::getTextureCache()->getMaxUsage()) ;
- S32 line_height = LLFontGL::getFontMonospace()->getLineHeight();
- S32 v_offset = (S32)((texture_bar_height + 2.2f) * mTextureView->mNumTextureBars + 2.0f);
+ S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f);
+ S32 v_offset = 0;//(S32)((texture_bar_height + 2.2f) * mTextureView->mNumTextureBars + 2.0f);
F32 total_texture_downloaded = (F32)gTotalTextureBytes / (1024 * 1024);
F32 total_object_downloaded = (F32)gTotalObjectBytes / (1024 * 1024);
U32 total_http_requests = LLAppViewer::getTextureFetch()->getTotalNumHTTPRequests() ;
@@ -527,80 +525,24 @@ void LLGLTexMemBar::draw()
LLFontGL::getFontMonospace()->renderUTF8(text, 0, 0, v_offset + line_height*6,
text_color, LLFontGL::LEFT, LLFontGL::TOP);
- text = llformat("GL Tot: %d/%d MB Bound: %d/%d MB FBO: %d MB Raw Tot: %d MB Bias: %.2f Cache: %.1f/%.1f MB Net Tot Tex: %.1f MB Tot Obj: %.1f MB Tot Htp: %d",
+ text = llformat("GL Tot: %d/%d MB Bound: %d/%d MB FBO: %d MB Raw Tot: %d MB Bias: %.2f Cache: %.1f/%.1f MB",
total_mem,
max_total_mem,
bound_mem,
max_bound_mem,
LLRenderTarget::sBytesAllocated/(1024*1024),
LLImageRaw::sGlobalRawMemory >> 20, discard_bias,
- cache_usage, cache_max_usage, total_texture_downloaded, total_object_downloaded, total_http_requests);
- //, cache_entries, cache_max_entries
-
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, 0, v_offset + line_height*3,
+ cache_usage, cache_max_usage);
+ LLFontGL::getFontMonospace()->renderUTF8(text, 0, 0, v_offset + line_height*4,
text_color, LLFontGL::LEFT, LLFontGL::TOP);
- //----------------------------------------------------------------------------
-#if 0
- S32 bar_left = 400;
- S32 bar_width = 200;
- S32 top = line_height*3 - 2 + v_offset;
- S32 bottom = top - 6;
- S32 left = bar_left;
- S32 right = left + bar_width;
- F32 bar_scale;
-
- gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
-
- // GL Mem Bar
-
- left = bar_left;
- text = "GL";
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left, line_height*3,
+ text = llformat("Net Tot Tex: %.1f MB Tot Obj: %.1f MB Tot Htp: %d",
+ total_texture_downloaded, total_object_downloaded, total_http_requests);
+ //, cache_entries, cache_max_entries
+ LLFontGL::getFontMonospace()->renderUTF8(text, 0, 0, v_offset + line_height*3,
text_color, LLFontGL::LEFT, LLFontGL::TOP);
-
- left = bar_left+20;
- right = left + bar_width;
-
- gGL.color4f(0.5f, 0.5f, 0.5f, 0.75f); // grey
- gl_rect_2d(left, top, right, bottom);
-
- bar_scale = (F32)bar_width / (max_total_mem * 1.5f);
- right = left + llfloor(total_mem * bar_scale);
- right = llclamp(right, bar_left, bar_left + bar_width);
-
- color = (total_mem < llfloor(max_total_mem * texmem_lower_bound_scale)) ? LLColor4::green :
- (total_mem < max_total_mem) ? LLColor4::yellow : LLColor4::red;
- color[VALPHA] = .75f;
- gGL.diffuseColor4fv(color.mV);
-
- gl_rect_2d(left, top, right, bottom); // red/yellow/green
-
- //
- bar_left += bar_width + bar_space;
- //top = bottom - 2; bottom = top - 6;
-
- // Bound Mem Bar
-
- left = bar_left;
- text = "GL";
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left, line_height*3,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- left = bar_left + 20;
- right = left + bar_width;
-
- gGL.color4f(0.5f, 0.5f, 0.5f, 0.75f);
- gl_rect_2d(left, top, right, bottom);
-
- color = (bound_mem < llfloor(max_bound_mem * texmem_lower_bound_scale)) ? LLColor4::green :
- (bound_mem < max_bound_mem) ? LLColor4::yellow : LLColor4::red;
- color[VALPHA] = .75f;
- gGL.diffuseColor4fv(color.mV);
- gl_rect_2d(left, top, right, bottom);
-#else
S32 left = 0 ;
-#endif
//----------------------------------------------------------------------------
text = llformat("Textures: %d Fetch: %d(%d) Pkts:%d(%d) Cache R/W: %d/%d LFS:%d RAW:%d HTP:%d DEC:%d CRE:%d",
@@ -669,8 +611,7 @@ BOOL LLGLTexMemBar::handleMouseDown(S32 x, S32 y, MASK mask)
LLRect LLGLTexMemBar::getRequiredRect()
{
LLRect rect;
- //rect.mTop = 50;
- rect.mTop = 0;
+ rect.mTop = 50; //LLFontGL::getFontMonospace()->getLineHeight() * 6;
return rect;
}
@@ -954,9 +895,11 @@ void LLTextureView::draw()
LLRect tmbr;
tmbp.name("gl texmem bar");
tmbp.rect(tmbr);
+ tmbp.follows.flags = FOLLOWS_LEFT|FOLLOWS_TOP;
tmbp.texture_view(this);
mGLTexMemBar = LLUICtrlFactory::create<LLGLTexMemBar>(tmbp);
- addChildInBack(mGLTexMemBar);
+ addChild(mGLTexMemBar);
+ sendChildToFront(mGLTexMemBar);
LLAvatarTexBar::Params atbp;
LLRect atbr;
@@ -965,16 +908,13 @@ void LLTextureView::draw()
atbp.rect(atbr);
mAvatarTexBar = LLUICtrlFactory::create<LLAvatarTexBar>(atbp);
addChild(mAvatarTexBar);
+ sendChildToFront(mAvatarTexBar);
reshape(getRect().getWidth(), getRect().getHeight(), TRUE);
- /*
- count = gTextureList.getNumImages();
- std::string info_string;
- info_string = llformat("Global Info:\nTexture Count: %d", count);
- mInfoTextp->setText(info_string);
- */
-
+ LLUI::popMatrix();
+ LLUI::pushMatrix();
+ LLUI::translate((F32)getRect().mLeft, (F32)getRect().mBottom);
for (child_list_const_iter_t child_iter = getChildList()->begin();
child_iter != getChildList()->end(); ++child_iter)
@@ -1049,302 +989,4 @@ BOOL LLTextureView::handleKey(KEY key, MASK mask, BOOL called_from_parent)
return FALSE;
}
-//-----------------------------------------------------------------
-LLTextureSizeView::LLTextureSizeView(const LLTextureSizeView::Params& p) : LLContainerView(p)
-{
- setVisible(FALSE) ;
-
- mTextureSizeBarWidth = 30 ;
-}
-
-LLTextureSizeView::~LLTextureSizeView()
-{
- if(mTextureSizeBar.size())
- {
- for(U32 i = 0 ; i < mTextureSizeBar.size() ; i++)
- {
- delete mTextureSizeBar[i] ;
- }
- mTextureSizeBar.clear() ;
- }
-}
-void LLTextureSizeView::draw()
-{
- if(mType == TEXTURE_MEM_OVER_SIZE)
- {
- drawTextureSizeGraph();
- }
- else
- {
- drawTextureCategoryGraph() ;
- }
-
- LLView::draw();
-}
-
-BOOL LLTextureSizeView::handleHover(S32 x, S32 y, MASK mask)
-{
- if(x > mTextureSizeBarRect.mLeft && x < mTextureSizeBarRect.mRight)
- {
- mTextureSizeBar[(x - mTextureSizeBarRect.mLeft) / mTextureSizeBarWidth]->handleHover(x, y, mask, (mType == TEXTURE_MEM_OVER_SIZE)) ;
- }
-
- return TRUE ;
-}
-
-//draw real-time texture mem bar over size
-void LLTextureSizeView::drawTextureSizeGraph()
-{
- if(mTextureSizeBar.size() == 0)
- {
- S32 line_height = LLFontGL::getFontMonospace()->getLineHeight();
- mTextureSizeBar.resize(LLImageGL::sTextureLoadedCounter.size()) ;
- mTextureSizeBarRect.set(700, line_height * 2 + 400, 700 + mTextureSizeBar.size() * mTextureSizeBarWidth, line_height * 2) ;
-
- for(U32 i = 0 ; i < mTextureSizeBar.size() ; i++)
- {
- mTextureSizeBar[i] = new LLGLTexSizeBar(i, mTextureSizeBarRect.mLeft + i * mTextureSizeBarWidth ,
- line_height * 2, mTextureSizeBarRect.mLeft + (i + 1) * mTextureSizeBarWidth, line_height) ;
- }
- }
-
- F32 size_bar_scale = drawTextureSizeDistributionGraph() ;
- for(U32 i = 0 ; i < mTextureSizeBar.size() ; i++)
- {
- mTextureSizeBar[i]->setTop(LLImageGL::sTextureLoadedCounter[i], LLImageGL::sTextureBoundCounter[i], size_bar_scale) ;
- mTextureSizeBar[i]->draw() ;
- }
- LLImageGL::resetCurTexSizebar();
-}
-
-//draw background of texture size bar graph
-F32 LLTextureSizeView::drawTextureSizeDistributionGraph()
-{
- //scale
- F32 scale = 1.0f ;
-
- LLGLSUIDefault gls_ui;
-
- {
- S32 count = 0 ;
- for(U32 i = 0 ; i < LLImageGL::sTextureLoadedCounter.size() ; i++)
- {
- if(LLImageGL::sTextureLoadedCounter[i] > count)
- {
- count = LLImageGL::sTextureLoadedCounter[i] ;
- }
- }
- if(count > mTextureSizeBarRect.getHeight())
- {
- scale = (F32)mTextureSizeBarRect.getHeight() / count ;
- }
- }
-
- S32 line_height = LLFontGL::getFontMonospace()->getLineHeight();
- S32 left = mTextureSizeBarRect.mLeft ;
- S32 bottom = mTextureSizeBarRect.mBottom ;
- S32 right = mTextureSizeBarRect.mRight ;
- S32 top = mTextureSizeBarRect.mTop ;
-
- gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
-
- //background rect
- gl_rect_2d(left - 25, top + 30, right + 100, bottom - 25, LLColor4(0.0f, 0.0f, 0.0f, 0.25f)) ;
-
- //--------------------------------------------------
- gGL.color4f(1.0f, 0.5f, 0.5f, 0.75f);
- gl_line_2d(left, bottom, right, bottom) ; //x axis
- gl_line_2d(left, bottom, left, top) ; //y axis
-
- //ruler
- //--------------------------------------------------
- gGL.color4f(1.0f, 0.5f, 0.5f, 0.5f);
- for(S32 i = bottom + 50 ; i <= top ; i += 50)
- {
- gl_line_2d(left, i, right, i) ;
- }
-
- //texts
- //--------------------------------------------------
- F32 text_color[] = {1.f, 1.f, 1.f, 0.75f};
- std::string text;
-
- //-------
- //x axis: size label
- text = llformat("%d", 0) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 12, bottom - line_height / 2,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- for(U32 i = 1 ; i < mTextureSizeBar.size() ; i++)
- {
- text = llformat("%d", (1 << (i / 2)) + ((i & 1) ? ((1 << (i / 2)) >> 1) : 0)) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + i * mTextureSizeBarWidth + 12, bottom - line_height / 2,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- }
- text = llformat("(w + h)/2") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, right + 10, bottom - line_height / 2,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- //-------
-
- //y axis: number label
- for(S32 i = bottom + 50 ; i <= top ; i += 50)
- {
- text = llformat("%d", (S32)((i - bottom) / scale)) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left - 20, i + line_height / 2 ,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, right + 5, i + line_height / 2 ,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- }
-
- //--------------------------------------------------
- F32 loaded_color[] = {1.0f, 0.0f, 0.0f, 0.75f};
- gl_rect_2d(left + 70, top + line_height * 2, left + 90, top + line_height, loaded_color) ;
- text = llformat("Loaded") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 100, top + line_height * 2,
- loaded_color, LLFontGL::LEFT, LLFontGL::TOP);
-
- F32 bound_color[] = {1.0f, 1.0f, 0.0f, 0.75f};
- gl_rect_2d(left + 170, top + line_height * 2, left + 190, top + line_height, bound_color) ;
- text = llformat("Bound") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 200, top + line_height * 2,
- bound_color, LLFontGL::LEFT, LLFontGL::TOP);
-
- //--------------------------------------------------
-
- //title
- text = llformat("Texture Size Distribution") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 250, top + line_height * 3,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- return scale ;
-}
-
-//draw real-time texture mem bar over category
-void LLTextureSizeView::drawTextureCategoryGraph()
-{
- if(mTextureSizeBar.size() == 0)
- {
- S32 line_height = LLFontGL::getFontMonospace()->getLineHeight();
- mTextureSizeBar.resize(LLViewerTexture::getTotalNumOfCategories()) ;
- mTextureSizeBarRect.set(700, line_height * 2 + 400, 700 + mTextureSizeBar.size() * mTextureSizeBarWidth, line_height * 2) ;
-
- for(U32 i = 0 ; i < mTextureSizeBar.size() ; i++)
- {
- mTextureSizeBar[i] = new LLGLTexSizeBar(i, mTextureSizeBarRect.mLeft + i * mTextureSizeBarWidth ,
- line_height * 2, mTextureSizeBarRect.mLeft + (i + 1) * mTextureSizeBarWidth, line_height) ;
- }
- }
-
- F32 size_bar_scale = drawTextureCategoryDistributionGraph() ;
- for(U32 i = 0 ; i < mTextureSizeBar.size() ; i++)
- {
- U32 k = LLViewerTexture::getIndexFromCategory(i) ;
- mTextureSizeBar[i]->setTop(LLImageGL::sTextureMemByCategory[k] >> 20, LLImageGL::sTextureMemByCategoryBound[k] >> 20, size_bar_scale) ;
- mTextureSizeBar[i]->draw() ;
- }
- LLImageGL::resetCurTexSizebar();
-}
-
-//draw background for TEXTURE_MEM_OVER_CATEGORY
-F32 LLTextureSizeView::drawTextureCategoryDistributionGraph()
-{
- //scale
- F32 scale = 4.0f ;
-
- LLGLSUIDefault gls_ui;
- {
- S32 count = 0 ;
- for(U32 i = 0 ; i < LLImageGL::sTextureMemByCategory.size() ; i++)
- {
- S32 tmp = LLImageGL::sTextureMemByCategory[i] >> 20 ;
- if(tmp > count)
- {
- count = tmp ;
- }
- }
- if(count > mTextureSizeBarRect.getHeight() * 0.25f)
- {
- scale = (F32)mTextureSizeBarRect.getHeight() * 0.25f / count ;
- }
- }
-
- S32 line_height = LLFontGL::getFontMonospace()->getLineHeight();
- S32 left = mTextureSizeBarRect.mLeft ;
- S32 bottom = mTextureSizeBarRect.mBottom ;
- S32 right = mTextureSizeBarRect.mRight ;
- S32 top = mTextureSizeBarRect.mTop ;
-
- gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
-
- //background rect
- gl_rect_2d(left - 25, top + 30, right + 100, bottom - 25, LLColor4(0.0f, 0.0f, 0.0f, 0.25f)) ;
-
- //--------------------------------------------------
- gGL.color4f(1.0f, 0.5f, 0.5f, 0.75f);
- gl_line_2d(left, bottom, right, bottom) ; //x axis
- gl_line_2d(left, bottom, left, top) ; //y axis
-
- //ruler
- //--------------------------------------------------
- gGL.color4f(1.0f, 0.5f, 0.5f, 0.5f);
- for(S32 i = bottom + 50 ; i <= top ; i += 50)
- {
- gl_line_2d(left, i, right, i) ;
- }
-
- //texts
- //--------------------------------------------------
- F32 text_color[] = {1.f, 1.f, 1.f, 0.75f};
- std::string text;
-
- //-------
- //x axis: size label
- static char category[LLViewerTexture::MAX_GL_IMAGE_CATEGORY][4] =
- {"Non", "Bak", "Av", "Cld", "Scp", "Hi", "Trn", "Slt", "Hud", "Bsf", "UI", "Pvw", "Map", "Mvs", "Slf", "Loc", "Scr", "Dyn", "Mdi", "ALT", "Oth" } ;
-
- text = llformat("%s", category[0]) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 12, bottom - line_height / 2,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- for(U32 i = 1 ; i < mTextureSizeBar.size() ; i++)
- {
- text = llformat("%s", category[i]) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + i * mTextureSizeBarWidth + 12, bottom - line_height / 2,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- }
- //-------
-
- //y axis: number label
- for(S32 i = bottom + 50 ; i <= top ; i += 50)
- {
- text = llformat("%d", (S32)((i - bottom) / scale)) ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left - 20, i + line_height / 2 ,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, right + 5, i + line_height / 2 ,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- }
-
- text = llformat("MB") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left - 20, top + line_height * 2 ,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
- //--------------------------------------------------
- F32 loaded_color[] = {1.0f, 0.0f, 0.0f, 0.75f};
- gl_rect_2d(left + 70, top + line_height * 2, left + 90, top + line_height, loaded_color) ;
- text = llformat("Loaded") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 100, top + line_height * 2,
- loaded_color,
- LLFontGL::LEFT, LLFontGL::TOP);
-
- F32 bound_color[] = {1.0f, 1.0f, 0.0f, 0.75f};
- gl_rect_2d(left + 170, top + line_height * 2, left + 190, top + line_height, bound_color) ;
- text = llformat("Bound") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 200, top + line_height * 2,
- bound_color, LLFontGL::LEFT, LLFontGL::TOP);
-
- //--------------------------------------------------
-
- //title
- text = llformat("Texture Category Distribution") ;
- LLFontGL::getFontMonospace()->renderUTF8(text, 0, left + 250, top + line_height * 3,
- text_color, LLFontGL::LEFT, LLFontGL::TOP);
-
- return scale ;
-}
diff --git a/indra/newview/lltextureview.h b/indra/newview/lltextureview.h
index 3723eb737b..900b4e17d8 100644
--- a/indra/newview/lltextureview.h
+++ b/indra/newview/lltextureview.h
@@ -75,41 +75,6 @@ public:
};
class LLGLTexSizeBar;
-class LLTextureSizeView : public LLContainerView
-{
-protected:
- LLTextureSizeView(const Params&);
- friend class LLUICtrlFactory;
-public:
- ~LLTextureSizeView();
-
- /*virtual*/ void draw();
- /*virtual*/ BOOL handleHover(S32 x, S32 y, MASK mask) ;
-
- void setType(S32 type) {mType = type ;}
- enum
- {
- TEXTURE_MEM_OVER_SIZE,
- TEXTURE_MEM_OVER_CATEGORY
- };
-private:
- //draw background for TEXTURE_MEM_OVER_SIZE
- F32 drawTextureSizeDistributionGraph() ;
- //draw real-time texture mem bar over size
- void drawTextureSizeGraph();
-
- //draw background for TEXTURE_MEM_OVER_CATEGORY
- F32 drawTextureCategoryDistributionGraph() ;
- //draw real-time texture mem bar over category
- void drawTextureCategoryGraph();
-private:
- std::vector<LLGLTexSizeBar*> mTextureSizeBar ;
- LLRect mTextureSizeBarRect ;
- S32 mTextureSizeBarWidth ;
- S32 mType ;
-};
extern LLTextureView *gTextureView;
-extern LLTextureSizeView *gTextureSizeView;
-extern LLTextureSizeView *gTextureCategoryView;
#endif // LL_TEXTURE_VIEW_H
diff --git a/indra/newview/lltoastnotifypanel.cpp b/indra/newview/lltoastnotifypanel.cpp
index a8060649ba..a473ee7ce0 100644
--- a/indra/newview/lltoastnotifypanel.cpp
+++ b/indra/newview/lltoastnotifypanel.cpp
@@ -52,7 +52,7 @@ const LLFontGL* LLToastNotifyPanel::sFontSmall = NULL;
LLToastNotifyPanel::button_click_signal_t LLToastNotifyPanel::sButtonClickSignal;
-LLToastNotifyPanel::LLToastNotifyPanel(LLNotificationPtr& notification, const LLRect& rect, bool show_images) :
+LLToastNotifyPanel::LLToastNotifyPanel(const LLNotificationPtr& notification, const LLRect& rect, bool show_images) :
LLToastPanel(notification),
mTextBox(NULL),
mInfoPanel(NULL),
@@ -536,7 +536,7 @@ void LLToastNotifyPanel::onToastPanelButtonClicked(const LLUUID& notification_id
}
}
-void LLToastNotifyPanel::disableRespondedOptions(LLNotificationPtr& notification)
+void LLToastNotifyPanel::disableRespondedOptions(const LLNotificationPtr& notification)
{
LLSD response = notification->getResponse();
for (LLSD::map_const_iterator response_it = response.beginMap();
diff --git a/indra/newview/lltoastnotifypanel.h b/indra/newview/lltoastnotifypanel.h
index 57711b3d80..db517ec858 100644
--- a/indra/newview/lltoastnotifypanel.h
+++ b/indra/newview/lltoastnotifypanel.h
@@ -60,7 +60,7 @@ public:
* @deprecated if you intend to instantiate LLToastNotifyPanel - it's point to
* implement right class for desired toast panel. @see LLGenericTipPanel as example.
*/
- LLToastNotifyPanel(LLNotificationPtr& pNotification, const LLRect& rect = LLRect::null, bool show_images = true);
+ LLToastNotifyPanel(const LLNotificationPtr& pNotification, const LLRect& rect = LLRect::null, bool show_images = true);
virtual ~LLToastNotifyPanel();
LLPanel * getControlPanel() { return mControlPanel; }
@@ -118,7 +118,7 @@ protected:
/**
* Process response data. Will disable selected options
*/
- void disableRespondedOptions(LLNotificationPtr& notification);
+ void disableRespondedOptions(const LLNotificationPtr& notification);
bool mIsTip;
bool mAddedDefaultBtn;
diff --git a/indra/newview/lltoastpanel.cpp b/indra/newview/lltoastpanel.cpp
index d2a4ce8745..c33fde99c5 100644
--- a/indra/newview/lltoastpanel.cpp
+++ b/indra/newview/lltoastpanel.cpp
@@ -29,7 +29,9 @@
#include "llpanelgenerictip.h"
#include "llpanelonlinestatus.h"
#include "llnotifications.h"
+#include "lltoastnotifypanel.h"
#include "lltoastpanel.h"
+#include "lltoastscriptquestion.h"
//static
const S32 LLToastPanel::MIN_PANEL_HEIGHT = 40; // VPAD(4)*2 + ICON_HEIGHT(32)
@@ -106,6 +108,17 @@ LLToastPanel* LLToastPanel::buidPanelFromNotification(
res = new LLPanelGenericTip(notification);
}
}
+ else if("notify" == notification->getType())
+ {
+ if (notification->getPriority() == NOTIFICATION_PRIORITY_CRITICAL)
+ {
+ res = new LLToastScriptQuestion(notification);
+ }
+ else
+ {
+ res = new LLToastNotifyPanel(notification);
+ }
+ }
/*
else if(...)
create all other specific non-public toast panel
diff --git a/indra/newview/lltoastscriptquestion.cpp b/indra/newview/lltoastscriptquestion.cpp
new file mode 100644
index 0000000000..feeb8ca77b
--- /dev/null
+++ b/indra/newview/lltoastscriptquestion.cpp
@@ -0,0 +1,130 @@
+/**
+ * @file lltoastscriptquestion.cpp
+ *
+ * $LicenseInfo:firstyear=2010&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2012, Linden Research, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation;
+ * version 2.1 of the License only.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llbutton.h"
+#include "llnotifications.h"
+#include "lltoastscriptquestion.h"
+
+const int LEFT_PAD = 10;
+const int BUTTON_HEIGHT = 27;
+const int MAX_LINES_COUNT = 50;
+
+LLToastScriptQuestion::LLToastScriptQuestion(const LLNotificationPtr& notification)
+:
+LLToastPanel(notification)
+{
+ buildFromFile("panel_script_question_toast.xml");
+}
+
+BOOL LLToastScriptQuestion::postBuild()
+{
+ createButtons();
+
+ LLTextBox* mMessage = getChild<LLTextBox>("top_info_message");
+ LLTextBox* mFooter = getChild<LLTextBox>("bottom_info_message");
+
+ mMessage->setValue(mNotification->getMessage());
+ mFooter->setValue(mNotification->getFooter());
+
+ snapToMessageHeight();
+
+ return TRUE;
+}
+void LLToastScriptQuestion::snapToMessageHeight()
+{
+ LLTextBox* mMessage = getChild<LLTextBox>("top_info_message");
+ LLTextBox* mFooter = getChild<LLTextBox>("bottom_info_message");
+ if (!mMessage || !mFooter)
+ {
+ return;
+ }
+
+ if (mMessage->getVisible() && mFooter->getVisible())
+ {
+ S32 heightDelta = 0;
+ S32 maxTextHeight = (mMessage->getDefaultFont()->getLineHeight() * MAX_LINES_COUNT)
+ + (mFooter->getDefaultFont()->getLineHeight() * MAX_LINES_COUNT);
+
+ LLRect messageRect = mMessage->getRect();
+ LLRect footerRect = mFooter->getRect();
+
+ S32 oldTextHeight = messageRect.getHeight() + footerRect.getHeight();
+
+ S32 requiredTextHeight = mMessage->getTextBoundingRect().getHeight() + mFooter->getTextBoundingRect().getHeight();
+ S32 newTextHeight = llmin(requiredTextHeight, maxTextHeight);
+
+ heightDelta = newTextHeight - oldTextHeight - heightDelta;
+
+ reshape( getRect().getWidth(), llmax(getRect().getHeight() + heightDelta, MIN_PANEL_HEIGHT));
+ }
+}
+
+void LLToastScriptQuestion::createButtons()
+{
+ LLNotificationFormPtr form = mNotification->getForm();
+ int num_elements = form->getNumElements();
+ int buttons_width = 0;
+
+ for (int i = 0; i < num_elements; ++i)
+ {
+ LLSD form_element = form->getElement(i);
+ if ("button" == form_element["type"].asString())
+ {
+ LLButton::Params p;
+ const LLFontGL* font = LLFontGL::getFontSansSerif();
+ p.name(form_element["name"].asString());
+ p.label(form_element["text"].asString());
+ p.layout("topleft");
+ p.font(font);
+ p.rect.height(BUTTON_HEIGHT);
+ p.click_callback.function(boost::bind(&LLToastScriptQuestion::onButtonClicked, this, form_element["name"].asString()));
+ p.rect.left = LEFT_PAD;
+ p.rect.width = font->getWidth(form_element["text"].asString());
+ p.auto_resize = true;
+ p.follows.flags(FOLLOWS_LEFT | FOLLOWS_BOTTOM);
+ p.image_color(LLUIColorTable::instance().getColor("ButtonCautionImageColor"));
+ p.image_color_disabled(LLUIColorTable::instance().getColor("ButtonCautionImageColor"));
+
+ LLButton* button = LLUICtrlFactory::create<LLButton>(p);
+ button->autoResize();
+ getChild<LLPanel>("buttons_panel")->addChild(button);
+
+ LLRect rect = button->getRect();
+ rect.setLeftTopAndSize(buttons_width, rect.mTop, rect.getWidth(), rect.getHeight());
+ button->setRect(rect);
+
+ buttons_width += rect.getWidth() + LEFT_PAD;
+ }
+ }
+}
+
+void LLToastScriptQuestion::onButtonClicked(std::string btn_name)
+{
+ LLSD response = mNotification->getResponseTemplate();
+ response[btn_name] = true;
+ mNotification->respond(response);
+}
diff --git a/indra/newview/lltoastscriptquestion.h b/indra/newview/lltoastscriptquestion.h
new file mode 100644
index 0000000000..3a557f60f6
--- /dev/null
+++ b/indra/newview/lltoastscriptquestion.h
@@ -0,0 +1,49 @@
+/**
+ * @file lltoastscriptquestion.h
+ *
+ * $LicenseInfo:firstyear=2010&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2012, Linden Research, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation;
+ * version 2.1 of the License only.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
+ * $/LicenseInfo$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "lltoastpanel.h"
+
+#ifndef LLTOASTSCRIPTQUESTION_H_
+#define LLTOASTSCRIPTQUESTION_H_
+
+class LLToastScriptQuestion : public LLToastPanel
+{
+ LOG_CLASS(LLToastScriptQuestion);
+
+public:
+ LLToastScriptQuestion(const LLNotificationPtr& notification);
+ virtual BOOL postBuild();
+ virtual ~LLToastScriptQuestion(){};
+
+private:
+ void snapToMessageHeight();
+
+ void createButtons();
+ void onButtonClicked(std::string btn_name);
+};
+
+#endif /* LLTOASTSCRIPTQUESTION_H_ */
diff --git a/indra/newview/llviewerassetstats.cpp b/indra/newview/llviewerassetstats.cpp
index e621cf647e..4c59fd0371 100644
--- a/indra/newview/llviewerassetstats.cpp
+++ b/indra/newview/llviewerassetstats.cpp
@@ -30,6 +30,7 @@
#include "llregionhandle.h"
#include "stdtypes.h"
+#include "llvoavatar.h"
/*
* Classes and utility functions for per-thread and per-region
@@ -126,6 +127,8 @@ LLViewerAssetStats::PerRegionStats::merge(const LLViewerAssetStats::PerRegionSta
mFPS.merge(src.mFPS);
}
+ // Avatar stats - data all comes from main thread, so leave alone.
+
// Requests
for (int i = 0; i < LL_ARRAY_SIZE(mRequests); ++i)
{
@@ -133,6 +136,7 @@ LLViewerAssetStats::PerRegionStats::merge(const LLViewerAssetStats::PerRegionSta
mRequests[i].mDequeued.merge(src.mRequests[i].mDequeued);
mRequests[i].mResponse.merge(src.mRequests[i].mResponse);
}
+
}
@@ -156,7 +160,9 @@ LLViewerAssetStats::LLViewerAssetStats()
LLViewerAssetStats::LLViewerAssetStats(const LLViewerAssetStats & src)
: mRegionHandle(src.mRegionHandle),
- mResetTimestamp(src.mResetTimestamp)
+ mResetTimestamp(src.mResetTimestamp),
+ mPhaseStats(src.mPhaseStats),
+ mAvatarRezStates(src.mAvatarRezStates)
{
const PerRegionContainer::const_iterator it_end(src.mRegionStats.end());
for (PerRegionContainer::const_iterator it(src.mRegionStats.begin()); it_end != it; ++it)
@@ -252,6 +258,17 @@ LLViewerAssetStats::recordFPS(F32 fps)
mCurRegionStats->mFPS.record(fps);
}
+void
+LLViewerAssetStats::recordAvatarStats()
+{
+ std::vector<S32> rez_counts;
+ LLVOAvatar::getNearbyRezzedStats(rez_counts);
+ mAvatarRezStates = rez_counts;
+ mPhaseStats.clear();
+ mPhaseStats["cloud"] = LLViewerStats::PhaseMap::getPhaseStats("cloud");
+ mPhaseStats["cloud-or-gray"] = LLViewerStats::PhaseMap::getPhaseStats("cloud-or-gray");
+}
+
LLSD
LLViewerAssetStats::asLLSD(bool compact_output)
{
@@ -282,6 +299,11 @@ LLViewerAssetStats::asLLSD(bool compact_output)
static const LLSD::String max_tag("max");
static const LLSD::String mean_tag("mean");
+ // Avatar sub-tags
+ static const LLSD::String avatar_tag("avatar");
+ static const LLSD::String avatar_nearby_tag("nearby");
+ static const LLSD::String avatar_phase_stats_tag("phase_stats");
+
const duration_t now = LLViewerAssetStatsFF::get_timestamp();
mCurRegionStats->accumulateTime(now);
@@ -329,7 +351,6 @@ LLViewerAssetStats::asLLSD(bool compact_output)
slot[max_tag] = LLSD(F64(stats.mFPS.getMax()));
slot[mean_tag] = LLSD(F64(stats.mFPS.getMean()));
}
-
U32 grid_x(0), grid_y(0);
grid_from_region_handle(it->first, &grid_x, &grid_y);
reg_stat["grid_x"] = LLSD::Integer(grid_x);
@@ -341,6 +362,16 @@ LLViewerAssetStats::asLLSD(bool compact_output)
LLSD ret = LLSD::emptyMap();
ret["regions"] = regions;
ret["duration"] = LLSD::Real((now - mResetTimestamp) * 1.0e-6);
+ LLSD avatar_info;
+ avatar_info[avatar_nearby_tag] = LLSD::emptyArray();
+ for (S32 rez_stat=0; rez_stat < mAvatarRezStates.size(); ++rez_stat)
+ {
+ std::string rez_status_name = LLVOAvatar::rezStatusToString(rez_stat);
+ avatar_info[avatar_nearby_tag][rez_status_name] = mAvatarRezStates[rez_stat];
+ }
+ avatar_info[avatar_phase_stats_tag]["cloud"] = mPhaseStats["cloud"].getData();
+ avatar_info[avatar_phase_stats_tag]["cloud-or-gray"] = mPhaseStats["cloud-or-gray"].getData();
+ ret[avatar_tag] = avatar_info;
return ret;
}
@@ -439,6 +470,14 @@ record_fps_main(F32 fps)
gViewerAssetStatsMain->recordFPS(fps);
}
+void
+record_avatar_stats()
+{
+ if (! gViewerAssetStatsMain)
+ return;
+
+ gViewerAssetStatsMain->recordAvatarStats();
+}
// 'thread1' - should be for TextureFetch thread
diff --git a/indra/newview/llviewerassetstats.h b/indra/newview/llviewerassetstats.h
index 73ec5974b2..8319752230 100644
--- a/indra/newview/llviewerassetstats.h
+++ b/indra/newview/llviewerassetstats.h
@@ -36,6 +36,7 @@
#include "llviewerassetstorage.h"
#include "llsimplestat.h"
#include "llsd.h"
+#include "llvoavatar.h"
/**
* @class LLViewerAssetStats
@@ -181,6 +182,9 @@ public:
// Frames-Per-Second Samples
void recordFPS(F32 fps);
+ // Avatar-related statistics
+ void recordAvatarStats();
+
// Merge a source instance into a destination instance. This is
// conceptually an 'operator+=()' method:
// - counts are added
@@ -252,6 +256,10 @@ protected:
// Time of last reset
duration_t mResetTimestamp;
+
+ // Nearby avatar stats
+ std::vector<S32> mAvatarRezStates;
+ LLViewerStats::phase_stats_t mPhaseStats;
};
@@ -310,6 +318,7 @@ void record_response_main(LLViewerAssetType::EType at, bool with_http, bool is_t
void record_fps_main(F32 fps);
+void record_avatar_stats();
/**
* Region context, event and duration loggers for Thread 1.
diff --git a/indra/newview/llvieweraudio.cpp b/indra/newview/llvieweraudio.cpp
index 2447f5dea8..8d8c401dac 100644
--- a/indra/newview/llvieweraudio.cpp
+++ b/indra/newview/llvieweraudio.cpp
@@ -41,6 +41,7 @@
#include "llstartup.h"
#include "llviewerparcelmgr.h"
#include "llparcel.h"
+#include "llviewermessage.h"
/////////////////////////////////////////////////////////
@@ -49,15 +50,22 @@ LLViewerAudio::LLViewerAudio() :
mFadeState(FADE_IDLE),
mFadeTime(),
mIdleListnerActive(false),
- mForcedTeleportFade(false)
+ mForcedTeleportFade(false),
+ mWasPlaying(false)
{
mTeleportFailedConnection = LLViewerParcelMgr::getInstance()->
setTeleportFailedCallback(boost::bind(&LLViewerAudio::onTeleportFailed, this));
+ mTeleportFinishedConnection = LLViewerParcelMgr::getInstance()->
+ setTeleportFinishedCallback(boost::bind(&LLViewerAudio::onTeleportFinished, this, _1, _2));
+ mTeleportStartedConnection = LLViewerMessage::getInstance()->
+ setTeleportStartedCallback(boost::bind(&LLViewerAudio::onTeleportStarted, this));
}
LLViewerAudio::~LLViewerAudio()
{
mTeleportFailedConnection.disconnect();
+ mTeleportFinishedConnection.disconnect();
+ mTeleportStartedConnection.disconnect();
}
void LLViewerAudio::registerIdleListener()
@@ -67,7 +75,6 @@ void LLViewerAudio::registerIdleListener()
mIdleListnerActive = true;
doOnIdleRepeating(boost::bind(boost::bind(&LLViewerAudio::onIdleUpdate, this)));
}
-
}
void LLViewerAudio::startInternetStreamWithAutoFade(std::string streamURI)
@@ -245,16 +252,54 @@ F32 LLViewerAudio::getFadeVolume()
return fade_volume;
}
+void LLViewerAudio::onTeleportStarted()
+{
+ if (!LLViewerAudio::getInstance()->getForcedTeleportFade())
+ {
+ // Even though the music was turned off it was starting up (with autoplay disabled) occasionally
+ // after a failed teleport or after an intra-parcel teleport. Also, the music sometimes was not
+ // restarting after a successful intra-parcel teleport. Setting mWasPlaying fixes these issues.
+ LLViewerAudio::getInstance()->setWasPlaying(!gAudiop->getInternetStreamURL().empty());
+ LLViewerAudio::getInstance()->setForcedTeleportFade(true);
+ LLViewerAudio::getInstance()->startInternetStreamWithAutoFade(LLStringUtil::null);
+ LLViewerAudio::getInstance()->setNextStreamURI(LLStringUtil::null);
+ }
+}
+
void LLViewerAudio::onTeleportFailed()
{
- if (gAudiop)
+ // Calling audio_update_volume makes sure that the music stream is properly set to be restored to
+ // its previous value
+ audio_update_volume(false);
+
+ if (gAudiop && mWasPlaying)
+ {
+ LLParcel* parcel = LLViewerParcelMgr::getInstance()->getAgentParcel();
+ if (parcel)
+ {
+ mNextStreamURI = parcel->getMusicURL();
+ llinfos << "Teleport failed -- setting music stream to " << mNextStreamURI << llendl;
+ }
+ }
+ mWasPlaying = false;
+}
+
+void LLViewerAudio::onTeleportFinished(const LLVector3d& pos, const bool& local)
+{
+ // Calling audio_update_volume makes sure that the music stream is properly set to be restored to
+ // its previous value
+ audio_update_volume(false);
+
+ if (gAudiop && local && mWasPlaying)
{
LLParcel* parcel = LLViewerParcelMgr::getInstance()->getAgentParcel();
if (parcel)
{
mNextStreamURI = parcel->getMusicURL();
+ llinfos << "Intraparcel teleport -- setting music stream to " << mNextStreamURI << llendl;
}
}
+ mWasPlaying = false;
}
void init_audio()
@@ -360,15 +405,9 @@ void audio_update_volume(bool force_update)
// Streaming Music
if (gAudiop)
{
- if (progress_view_visible && !LLViewerAudio::getInstance()->getForcedTeleportFade())
- {
- LLViewerAudio::getInstance()->setForcedTeleportFade(true);
- LLViewerAudio::getInstance()->startInternetStreamWithAutoFade(LLStringUtil::null);
- LLViewerAudio::getInstance()->setNextStreamURI(LLStringUtil::null);
- }
-
- if (!progress_view_visible && LLViewerAudio::getInstance()->getForcedTeleportFade() == true)
+ if (!progress_view_visible && LLViewerAudio::getInstance()->getForcedTeleportFade())
{
+ LLViewerAudio::getInstance()->setWasPlaying(!gAudiop->getInternetStreamURL().empty());
LLViewerAudio::getInstance()->setForcedTeleportFade(false);
}
diff --git a/indra/newview/llvieweraudio.h b/indra/newview/llvieweraudio.h
index a3da9fc6b8..8c302c6549 100644
--- a/indra/newview/llvieweraudio.h
+++ b/indra/newview/llvieweraudio.h
@@ -66,6 +66,7 @@ public:
bool getForcedTeleportFade() { return mForcedTeleportFade; };
void setForcedTeleportFade(bool fade) { mForcedTeleportFade = fade;} ;
void setNextStreamURI(std::string stream) { mNextStreamURI = stream; } ;
+ void setWasPlaying(bool playing) { mWasPlaying = playing;} ;
private:
@@ -76,13 +77,17 @@ private:
LLFrameTimer stream_fade_timer;
bool mIdleListnerActive;
bool mForcedTeleportFade;
+ bool mWasPlaying;
boost::signals2::connection mTeleportFailedConnection;
+ boost::signals2::connection mTeleportFinishedConnection;
+ boost::signals2::connection mTeleportStartedConnection;
void registerIdleListener();
void deregisterIdleListener() { mIdleListnerActive = false; };
void startFading();
void onTeleportFailed();
-
+ void onTeleportFinished(const LLVector3d& pos, const bool& local);
+ void onTeleportStarted();
};
#endif //LL_VIEWER_H
diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp
index ab45aae5cc..f2712e7590 100644
--- a/indra/newview/llviewercontrol.cpp
+++ b/indra/newview/llviewercontrol.cpp
@@ -87,7 +87,6 @@ std::string gLastRunVersion;
extern BOOL gResizeScreenTexture;
extern BOOL gDebugGL;
-extern BOOL gAuditTexture;
////////////////////////////////////////////////////////////////////////////
// Listeners
@@ -411,12 +410,6 @@ static bool handleRenderUseImpostorsChanged(const LLSD& newvalue)
return true;
}
-static bool handleAuditTextureChanged(const LLSD& newvalue)
-{
- gAuditTexture = newvalue.asBoolean();
- return true;
-}
-
static bool handleRenderDebugGLChanged(const LLSD& newvalue)
{
gDebugGL = newvalue.asBoolean() || gDebugSession;
@@ -618,7 +611,6 @@ void settings_setup_listeners()
gSavedSettings.getControl("RenderDeferredSSAO")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _2));
gSavedSettings.getControl("RenderPerformanceTest")->getSignal()->connect(boost::bind(&handleRenderPerfTestChanged, _2));
gSavedSettings.getControl("TextureMemory")->getSignal()->connect(boost::bind(&handleVideoMemoryChanged, _2));
- gSavedSettings.getControl("AuditTexture")->getSignal()->connect(boost::bind(&handleAuditTextureChanged, _2));
gSavedSettings.getControl("ChatFontSize")->getSignal()->connect(boost::bind(&handleChatFontSizeChanged, _2));
gSavedSettings.getControl("ChatPersistTime")->getSignal()->connect(boost::bind(&handleChatPersistTimeChanged, _2));
gSavedSettings.getControl("ConsoleMaxLines")->getSignal()->connect(boost::bind(&handleConsoleMaxLinesChanged, _2));
diff --git a/indra/newview/llviewerfloaterreg.cpp b/indra/newview/llviewerfloaterreg.cpp
index 7fdaac68c8..affea90a15 100644
--- a/indra/newview/llviewerfloaterreg.cpp
+++ b/indra/newview/llviewerfloaterreg.cpp
@@ -78,7 +78,6 @@
#include "llfloaterlandholdings.h"
#include "llfloatermap.h"
#include "llfloatermemleak.h"
-#include "llfloatermodelwizard.h"
#include "llfloaternamedesc.h"
#include "llfloaternotificationsconsole.h"
#include "llfloaterobjectweights.h"
@@ -103,6 +102,7 @@
#include "llfloatertelehub.h"
#include "llfloatertestinspectors.h"
#include "llfloatertestlistview.h"
+#include "llfloatertexturefetchdebugger.h"
#include "llfloatertools.h"
#include "llfloatertos.h"
#include "llfloatertopobjects.h"
@@ -227,6 +227,11 @@ void LLViewerFloaterReg::registerFloaters()
LLFloaterReg::add("land_holdings", "floater_land_holdings.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterLandHoldings>);
LLFloaterReg::add("mem_leaking", "floater_mem_leaking.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterMemLeak>);
+
+ if(gSavedSettings.getBOOL("TextureFetchDebuggerEnabled"))
+ {
+ LLFloaterReg::add("tex_fetch_debugger", "floater_texture_fetch_debugger.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterTextureFetchDebugger>);
+ }
LLFloaterReg::add("media_settings", "floater_media_settings.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterMediaSettings>);
LLFloaterReg::add("message_critical", "floater_critical.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterTOS>);
LLFloaterReg::add("message_tos", "floater_tos.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterTOS>);
@@ -298,7 +303,6 @@ void LLViewerFloaterReg::registerFloaters()
LLFloaterReg::add("upload_anim_anim", "floater_animation_anim_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAnimPreview>, "upload");
LLFloaterReg::add("upload_image", "floater_image_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterImagePreview>, "upload");
LLFloaterReg::add("upload_model", "floater_model_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterModelPreview>, "upload");
- LLFloaterReg::add("upload_model_wizard", "floater_model_wizard.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterModelWizard>);
LLFloaterReg::add("upload_script", "floater_script_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterScriptPreview>, "upload");
LLFloaterReg::add("upload_sound", "floater_sound_preview.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterSoundPreview>, "upload");
diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp
index 45ca23cdfe..b47a41c44c 100644
--- a/indra/newview/llviewerinventory.cpp
+++ b/indra/newview/llviewerinventory.cpp
@@ -342,8 +342,8 @@ void LLViewerInventoryItem::cloneViewerItem(LLPointer<LLViewerInventoryItem>& ne
void LLViewerInventoryItem::removeFromServer()
{
- llinfos << "Removing inventory item " << mUUID << " from server."
- << llendl;
+ lldebugs << "Removing inventory item " << mUUID << " from server."
+ << llendl;
LLInventoryModel::LLCategoryUpdate up(mParentUUID, -1);
gInventory.accountForUpdate(up);
diff --git a/indra/newview/llviewerjointmesh.cpp b/indra/newview/llviewerjointmesh.cpp
index e052e37393..f029ae5302 100644
--- a/indra/newview/llviewerjointmesh.cpp
+++ b/indra/newview/llviewerjointmesh.cpp
@@ -576,7 +576,6 @@ U32 LLViewerJointMesh::drawShape( F32 pixelArea, BOOL first_pass, BOOL is_dummy)
{
old_mode = mTexture->getAddressMode();
}
- gGL.getTexUnit(diffuse_channel)->bind(mTexture.get());
gGL.getTexUnit(diffuse_channel)->bind(mTexture);
gGL.getTexUnit(diffuse_channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP);
}
diff --git a/indra/newview/llviewerjointmesh.h b/indra/newview/llviewerjointmesh.h
index 0191f0cae8..dd5dae1dc1 100644
--- a/indra/newview/llviewerjointmesh.h
+++ b/indra/newview/llviewerjointmesh.h
@@ -61,6 +61,7 @@ public:
//-----------------------------------------------------------------------------
class LLViewerJointMesh : public LLViewerJoint
{
+ friend class LLVOAvatar;
protected:
LLColor4 mColor; // color value
// LLColor4 mSpecular; // specular color (always white for now)
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 7481414b5c..c9af6a2820 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -93,6 +93,7 @@
#include "lltoolpie.h"
#include "lltoolselectland.h"
#include "lltrans.h"
+#include "llviewerdisplay.h" //for gWindowResized
#include "llviewergenericmessage.h"
#include "llviewerhelp.h"
#include "llviewermenufile.h" // init_menu_file()
@@ -205,7 +206,7 @@ BOOL enable_take();
void handle_take();
void handle_object_show_inspector();
void handle_avatar_show_inspector();
-bool confirm_take(const LLSD& notification, const LLSD& response);
+bool confirm_take(const LLSD& notification, const LLSD& response, LLObjectSelectionHandle selection_handle);
void handle_buy_object(LLSaleInfo sale_info);
void handle_buy_contents(LLSaleInfo sale_info);
@@ -516,14 +517,6 @@ class LLAdvancedToggleConsole : public view_listener_t
{
toggle_visibility( (void*)static_cast<LLUICtrl*>(gDebugView->mDebugConsolep));
}
- else if (gTextureSizeView && "texture size" == console_type)
- {
- toggle_visibility( (void*)gTextureSizeView );
- }
- else if (gTextureCategoryView && "texture category" == console_type)
- {
- toggle_visibility( (void*)gTextureCategoryView );
- }
else if ("fast timers" == console_type)
{
LLFloaterReg::toggleInstance("fast_timers");
@@ -556,14 +549,6 @@ class LLAdvancedCheckConsole : public view_listener_t
{
new_value = get_visibility( (void*)((LLView*)gDebugView->mDebugConsolep) );
}
- else if (gTextureSizeView && "texture size" == console_type)
- {
- new_value = get_visibility( (void*)gTextureSizeView );
- }
- else if (gTextureCategoryView && "texture category" == console_type)
- {
- new_value = get_visibility( (void*)gTextureCategoryView );
- }
else if ("fast timers" == console_type)
{
new_value = LLFloaterReg::instanceVisible("fast_timers");
@@ -866,6 +851,73 @@ class LLAdvancedCheckFeature : public view_listener_t
}
};
+class LLAdvancedCheckDisplayTextureDensity : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ std::string mode = userdata.asString();
+ if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY))
+ {
+ return mode == "none";
+ }
+ if (mode == "current")
+ {
+ return LLViewerTexture::sDebugTexelsMode == LLViewerTexture::DEBUG_TEXELS_CURRENT;
+ }
+ else if (mode == "desired")
+ {
+ return LLViewerTexture::sDebugTexelsMode == LLViewerTexture::DEBUG_TEXELS_DESIRED;
+ }
+ else if (mode == "full")
+ {
+ return LLViewerTexture::sDebugTexelsMode == LLViewerTexture::DEBUG_TEXELS_FULL;
+ }
+ return false;
+ }
+};
+
+class LLAdvancedSetDisplayTextureDensity : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ std::string mode = userdata.asString();
+ if (mode == "none")
+ {
+ if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY) == TRUE)
+ {
+ gPipeline.toggleRenderDebug((void*)LLPipeline::RENDER_DEBUG_TEXEL_DENSITY);
+ }
+ LLViewerTexture::sDebugTexelsMode = LLViewerTexture::DEBUG_TEXELS_OFF;
+ }
+ else if (mode == "current")
+ {
+ if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY) == FALSE)
+ {
+ gPipeline.toggleRenderDebug((void*)LLPipeline::RENDER_DEBUG_TEXEL_DENSITY);
+ }
+ LLViewerTexture::sDebugTexelsMode = LLViewerTexture::DEBUG_TEXELS_CURRENT;
+ }
+ else if (mode == "desired")
+ {
+ if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY) == FALSE)
+ {
+ gPipeline.toggleRenderDebug((void*)LLPipeline::RENDER_DEBUG_TEXEL_DENSITY);
+ }
+ gPipeline.setRenderDebugFeatureControl(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY, true);
+ LLViewerTexture::sDebugTexelsMode = LLViewerTexture::DEBUG_TEXELS_DESIRED;
+ }
+ else if (mode == "full")
+ {
+ if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_TEXEL_DENSITY) == FALSE)
+ {
+ gPipeline.toggleRenderDebug((void*)LLPipeline::RENDER_DEBUG_TEXEL_DENSITY);
+ }
+ LLViewerTexture::sDebugTexelsMode = LLViewerTexture::DEBUG_TEXELS_FULL;
+ }
+ return true;
+ }
+};
+
//////////////////
// INFO DISPLAY //
@@ -980,6 +1032,10 @@ U32 info_display_from_string(std::string info_display)
{
return LLPipeline::RENDER_DEBUG_WIND_VECTORS;
}
+ else if ("texel density" == info_display)
+ {
+ return LLPipeline::RENDER_DEBUG_TEXEL_DENSITY;
+ }
else
{
return 0;
@@ -1118,6 +1174,7 @@ class LLAdvancedToggleWireframe : public view_listener_t
bool handleEvent(const LLSD& userdata)
{
gUseWireframe = !(gUseWireframe);
+ gWindowResized = TRUE;
LLPipeline::updateRenderDeferred();
gPipeline.resetVertexBuffers();
return true;
@@ -2245,6 +2302,14 @@ class LLDevelopSetLoggingLevel : public view_listener_t
}
};
+class LLDevelopTextureFetchDebugger : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ return gSavedSettings.getBOOL("TextureFetchDebuggerEnabled");
+ }
+};
+
//////////////////
// ADMIN MENU //
//////////////////
@@ -4448,7 +4513,10 @@ void handle_take()
LLNotification::Params params("ConfirmObjectTakeLock");
params.payload(payload);
- params.functor.function(confirm_take);
+ // MAINT-290
+ // Reason: Showing the confirmation dialog resets object selection, thus there is nothing to derez.
+ // Fix: pass selection to the confirm_take, so that selection doesn't "die" after confirmation dialog is opened
+ params.functor.function(boost::bind(confirm_take, _1, _2, LLSelectMgr::instance().getSelection()));
if(locked_but_takeable_object ||
!you_own_everything)
@@ -4501,7 +4569,7 @@ void handle_avatar_show_inspector()
-bool confirm_take(const LLSD& notification, const LLSD& response)
+bool confirm_take(const LLSD& notification, const LLSD& response, LLObjectSelectionHandle selection_handle)
{
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
if(enable_take() && (option == 0))
@@ -5299,6 +5367,14 @@ void toggle_debug_menus(void*)
// }
//
+class LLCommunicateBlockList : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ LLFloaterSidePanelContainer::showPanel("people", "panel_block_list_sidetray", LLSD());
+ return true;
+ }
+};
class LLWorldSetHomeLocation : public view_listener_t
{
@@ -8084,6 +8160,9 @@ void initialize_menus()
// Me > Movement
view_listener_t::addMenu(new LLAdvancedAgentFlyingInfo(), "Agent.getFlying");
+
+ // Communicate
+ view_listener_t::addMenu(new LLCommunicateBlockList(), "Communicate.BlockList");
// World menu
view_listener_t::addMenu(new LLWorldAlwaysRun(), "World.AlwaysRun");
@@ -8164,6 +8243,10 @@ void initialize_menus()
//// Advanced > Render > Features
view_listener_t::addMenu(new LLAdvancedToggleFeature(), "Advanced.ToggleFeature");
view_listener_t::addMenu(new LLAdvancedCheckFeature(), "Advanced.CheckFeature");
+
+ view_listener_t::addMenu(new LLAdvancedCheckDisplayTextureDensity(), "Advanced.CheckDisplayTextureDensity");
+ view_listener_t::addMenu(new LLAdvancedSetDisplayTextureDensity(), "Advanced.SetDisplayTextureDensity");
+
// Advanced > Render > Info Displays
view_listener_t::addMenu(new LLAdvancedToggleInfoDisplay(), "Advanced.ToggleInfoDisplay");
view_listener_t::addMenu(new LLAdvancedCheckInfoDisplay(), "Advanced.CheckInfoDisplay");
@@ -8295,6 +8378,9 @@ void initialize_menus()
// Develop >Set logging level
view_listener_t::addMenu(new LLDevelopCheckLoggingLevel(), "Develop.CheckLoggingLevel");
view_listener_t::addMenu(new LLDevelopSetLoggingLevel(), "Develop.SetLoggingLevel");
+
+ //Develop (Texture Fetch Debug Console)
+ view_listener_t::addMenu(new LLDevelopTextureFetchDebugger(), "Develop.SetTexFetchDebugger");
// Admin >Object
view_listener_t::addMenu(new LLAdminForceTakeCopy(), "Admin.ForceTakeCopy");
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 854e2bea52..1813611c35 100755
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -2706,7 +2706,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
case IM_SESSION_SEND:
{
- if (!is_linden && is_busy)
+ if (is_busy)
{
return;
}
@@ -3441,6 +3441,9 @@ void process_teleport_start(LLMessageSystem *msg, void**)
LL_DEBUGS("Messaging") << "Got TeleportStart with TeleportFlags=" << teleport_flags << ". gTeleportDisplay: " << gTeleportDisplay << ", gAgent.mTeleportState: " << gAgent.getTeleportState() << LL_ENDL;
+ // *NOTE: The server sends two StartTeleport packets when you are teleporting to a LM
+ LLViewerMessage::getInstance()->mTeleportStartedSignal();
+
if (teleport_flags & TELEPORT_FLAGS_DISABLE_CANCEL)
{
gViewerWindow->setProgressCancelButtonVisible(FALSE);
@@ -3460,11 +3463,17 @@ void process_teleport_start(LLMessageSystem *msg, void**)
make_ui_sound("UISndTeleportOut");
LL_INFOS("Messaging") << "Teleport initiated by remote TeleportStart message with TeleportFlags: " << teleport_flags << LL_ENDL;
+
// Don't call LLFirstUse::useTeleport here because this could be
// due to being killed, which would send you home, not to a Telehub
}
}
+boost::signals2::connection LLViewerMessage::setTeleportStartedCallback(teleport_started_callback_t cb)
+{
+ return mTeleportStartedSignal.connect(cb);
+}
+
void process_teleport_progress(LLMessageSystem* msg, void**)
{
LLUUID agent_id;
@@ -5976,16 +5985,21 @@ void process_script_question(LLMessageSystem *msg, void **user_data)
args["OBJECTNAME"] = object_name;
args["NAME"] = LLCacheName::cleanFullName(owner_name);
+ BOOL has_not_only_debit = questions ^ LSCRIPTRunTimePermissionBits[SCRIPT_PERMISSION_DEBIT];
// check the received permission flags against each permission
for (S32 i = 0; i < SCRIPT_PERMISSION_EOF; i++)
{
if (questions & LSCRIPTRunTimePermissionBits[i])
{
count++;
- script_question += " " + LLTrans::getString(SCRIPT_QUESTIONS[i]) + "\n";
// check whether permission question should cause special caution dialog
caution |= (SCRIPT_QUESTION_IS_CAUTION[i]);
+
+ if (("ScriptTakeMoney" == SCRIPT_QUESTIONS[i]) && has_not_only_debit)
+ continue;
+
+ script_question += " " + LLTrans::getString(SCRIPT_QUESTIONS[i]) + "\n";
}
}
args["QUESTIONS"] = script_question;
@@ -6001,6 +6015,10 @@ void process_script_question(LLMessageSystem *msg, void **user_data)
// check whether cautions are even enabled or not
if (gSavedSettings.getBOOL("PermissionsCautionEnabled"))
{
+ if (caution)
+ {
+ args["FOOTERTEXT"] = (count > 1) ? LLTrans::getString("AdditionalPermissionsRequestHeader") + "\n\n" + script_question : "";
+ }
// display the caution permissions prompt
LLNotificationsUtil::add(caution ? "ScriptQuestionCaution" : "ScriptQuestion", args, payload);
}
diff --git a/indra/newview/llviewermessage.h b/indra/newview/llviewermessage.h
index 46bfb2dad0..594c22ed9c 100644
--- a/indra/newview/llviewermessage.h
+++ b/indra/newview/llviewermessage.h
@@ -37,6 +37,9 @@
#include "llnotifications.h"
#include "llextendedstatus.h"
+#include <boost/function.hpp>
+#include <boost/signals2.hpp>
+
//
// Forward declarations
//
@@ -205,6 +208,15 @@ bool highlight_offered_object(const LLUUID& obj_id);
void set_dad_inventory_item(LLInventoryItem* inv_item, const LLUUID& into_folder_uuid);
void set_dad_inbox_object(const LLUUID& object_id);
+class LLViewerMessage : public LLSingleton<LLViewerMessage>
+{
+public:
+ typedef boost::function<void()> teleport_started_callback_t;
+ typedef boost::signals2::signal<void()> teleport_started_signal_t;
+ boost::signals2::connection setTeleportStartedCallback(teleport_started_callback_t cb);
+
+ teleport_started_signal_t mTeleportStartedSignal;
+};
class LLOfferInfo : public LLNotificationResponderInterface
{
@@ -253,5 +265,3 @@ private:
void process_feature_disabled_message(LLMessageSystem* msg, void**);
#endif
-
-
diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp
index cd300accb7..da72f2fdac 100644
--- a/indra/newview/llviewerobject.cpp
+++ b/indra/newview/llviewerobject.cpp
@@ -2389,10 +2389,11 @@ void LLViewerObject::interpolateLinearMotion(const F64 & time, const F32 & dt)
{ // This will put the object underground, but we can't tell if it will stop
// at ground level or not
min_height = LLWorld::getInstance()->getMinAllowedZ(this, new_pos_global);
+ // Cap maximum height
+ new_pos.mV[VZ] = llmin(LLWorld::getInstance()->getRegionMaxHeight(), new_pos.mV[VZ]);
}
new_pos.mV[VZ] = llmax(min_height, new_pos.mV[VZ]);
- new_pos.mV[VZ] = llmin(LLWorld::getInstance()->getRegionMaxHeight(), new_pos.mV[VZ]);
// Check to see if it's going off the region
LLVector3 temp(new_pos);
diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp
index 6912faa9ec..54ccfb9aae 100644
--- a/indra/newview/llviewerobjectlist.cpp
+++ b/indra/newview/llviewerobjectlist.cpp
@@ -91,8 +91,9 @@ extern LLPipeline gPipeline;
// Statics for object lookup tables.
U32 LLViewerObjectList::sSimulatorMachineIndex = 1; // Not zero deliberately, to speed up index check.
-std::map<U64, U32> LLViewerObjectList::sIPAndPortToIndex;
+std::map<U64, U32> LLViewerObjectList::sIPAndPortToIndex;
std::map<U64, LLUUID> LLViewerObjectList::sIndexAndLocalIDToUUID;
+LLStat LLViewerObjectList::sCacheHitRate("object_cache_hits", 128);
LLViewerObjectList::LLViewerObjectList()
{
@@ -542,6 +543,8 @@ void LLViewerObjectList::processObjectUpdate(LLMessageSystem *mesgsys,
}
justCreated = TRUE;
mNumNewObjects++;
+ sCacheHitRate.addValue(cached ? 100.f : 0.f);
+
}
diff --git a/indra/newview/llviewerobjectlist.h b/indra/newview/llviewerobjectlist.h
index c5f2a2c1ee..64925f46ae 100644
--- a/indra/newview/llviewerobjectlist.h
+++ b/indra/newview/llviewerobjectlist.h
@@ -192,6 +192,8 @@ protected:
std::vector<OrphanInfo> mOrphanChildren; // UUID's of orphaned objects
S32 mNumOrphans;
+ static LLStat sCacheHitRate;
+
typedef std::vector<LLPointer<LLViewerObject> > vobj_list_t;
vobj_list_t mObjects;
diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp
index 9db784101d..ae9c31bfe7 100644
--- a/indra/newview/llviewerparcelmgr.cpp
+++ b/indra/newview/llviewerparcelmgr.cpp
@@ -82,7 +82,6 @@ LLPointer<LLViewerTexture> sBlockedImage;
LLPointer<LLViewerTexture> sPassImage;
// Local functions
-void optionally_start_music(const std::string& music_url);
void callback_start_music(S32 option, void* data);
void optionally_prepare_video(const LLParcel *parcelp);
void callback_prepare_video(S32 option, void* data);
@@ -1589,7 +1588,7 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use
if (instance->mTeleportInProgress)
{
instance->mTeleportInProgress = FALSE;
- instance->mTeleportFinishedSignal(gAgent.getPositionGlobal());
+ instance->mTeleportFinishedSignal(gAgent.getPositionGlobal(), false);
}
}
}
@@ -1773,13 +1772,13 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use
};
}
-void optionally_start_music(const std::string& music_url)
+void LLViewerParcelMgr::optionally_start_music(const std::string& music_url)
{
if (gSavedSettings.getBOOL("AudioStreamingMusic"))
{
// only play music when you enter a new parcel if the UI control for this
// was not *explicitly* stopped by the user. (part of SL-4878)
- LLPanelNearByMedia* nearby_media_panel = gStatusBar->getNearbyMediaPanel();;
+ LLPanelNearByMedia* nearby_media_panel = gStatusBar->getNearbyMediaPanel();
if ((nearby_media_panel &&
nearby_media_panel->getParcelAudioAutoStart()) ||
// or they have expressed no opinion in the UI, but have autoplay on...
@@ -2559,7 +2558,7 @@ void LLViewerParcelMgr::onTeleportFinished(bool local, const LLVector3d& new_pos
{
// Local teleport. We already have the agent parcel data.
// Emit the signal immediately.
- getInstance()->mTeleportFinishedSignal(new_pos);
+ getInstance()->mTeleportFinishedSignal(new_pos, local);
}
else
{
diff --git a/indra/newview/llviewerparcelmgr.h b/indra/newview/llviewerparcelmgr.h
index cac8d8391c..2a11549426 100644
--- a/indra/newview/llviewerparcelmgr.h
+++ b/indra/newview/llviewerparcelmgr.h
@@ -78,8 +78,8 @@ class LLViewerParcelMgr : public LLSingleton<LLViewerParcelMgr>
{
public:
- typedef boost::function<void (const LLVector3d&)> teleport_finished_callback_t;
- typedef boost::signals2::signal<void (const LLVector3d&)> teleport_finished_signal_t;
+ typedef boost::function<void (const LLVector3d&, const bool& local)> teleport_finished_callback_t;
+ typedef boost::signals2::signal<void (const LLVector3d&, const bool&)> teleport_finished_signal_t;
typedef boost::function<void()> parcel_changed_callback_t;
typedef boost::signals2::signal<void()> parcel_changed_signal_t;
@@ -275,6 +275,8 @@ public:
// *NOTE: Taken out 2005-03-21. Phoenix.
//void makeLandmarkAtSelection();
+ static void optionally_start_music(const std::string& music_url);
+
static void processParcelOverlay(LLMessageSystem *msg, void **user_data);
static void processParcelProperties(LLMessageSystem *msg, void **user_data);
static void processParcelAccessListReply(LLMessageSystem *msg, void **user);
diff --git a/indra/newview/llviewerprecompiledheaders.h b/indra/newview/llviewerprecompiledheaders.h
index f738b84bb9..6c8a827ba3 100644
--- a/indra/newview/llviewerprecompiledheaders.h
+++ b/indra/newview/llviewerprecompiledheaders.h
@@ -57,6 +57,8 @@
#include "lldeleteutils.h"
#include "imageids.h"
#include "indra_constants.h"
+#include "llinitparam.h"
+
//#include "linden_common.h"
//#include "llpreprocessor.h"
#include "llallocator.h"
@@ -124,7 +126,5 @@
// Library includes from llmessage project
#include "llcachename.h"
-// Library includes from llxuixml
-#include "llinitparam.h"
#endif
diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp
index c88122f22c..497e95c5e3 100644
--- a/indra/newview/llviewerstats.cpp
+++ b/indra/newview/llviewerstats.cpp
@@ -860,3 +860,110 @@ void send_stats()
LLHTTPClient::post(url, body, new ViewerStatsResponder());
}
+LLFrameTimer& LLViewerStats::PhaseMap::getPhaseTimer(const std::string& phase_name)
+{
+ phase_map_t::iterator iter = mPhaseMap.find(phase_name);
+ if (iter == mPhaseMap.end())
+ {
+ LLFrameTimer timer;
+ mPhaseMap[phase_name] = timer;
+ }
+ LLFrameTimer& timer = mPhaseMap[phase_name];
+ return timer;
+}
+
+void LLViewerStats::PhaseMap::startPhase(const std::string& phase_name)
+{
+ LLFrameTimer& timer = getPhaseTimer(phase_name);
+ lldebugs << "startPhase " << phase_name << llendl;
+ timer.unpause();
+}
+
+void LLViewerStats::PhaseMap::stopPhase(const std::string& phase_name)
+{
+ phase_map_t::iterator iter = mPhaseMap.find(phase_name);
+ if (iter != mPhaseMap.end())
+ {
+ if (iter->second.getStarted())
+ {
+ // Going from started to paused state - record stats.
+ recordPhaseStat(phase_name,iter->second.getElapsedTimeF32());
+ }
+ lldebugs << "stopPhase " << phase_name << llendl;
+ iter->second.pause();
+ }
+ else
+ {
+ lldebugs << "stopPhase " << phase_name << " is not started, no-op" << llendl;
+ }
+}
+
+void LLViewerStats::PhaseMap::stopAllPhases()
+{
+ for (phase_map_t::iterator iter = mPhaseMap.begin();
+ iter != mPhaseMap.end(); ++iter)
+ {
+ const std::string& phase_name = iter->first;
+ if (iter->second.getStarted())
+ {
+ // Going from started to paused state - record stats.
+ recordPhaseStat(phase_name,iter->second.getElapsedTimeF32());
+ }
+ lldebugs << "stopPhase (all) " << phase_name << llendl;
+ iter->second.pause();
+ }
+}
+
+void LLViewerStats::PhaseMap::clearPhases()
+{
+ lldebugs << "clearPhases" << llendl;
+
+ mPhaseMap.clear();
+}
+
+LLSD LLViewerStats::PhaseMap::dumpPhases()
+{
+ LLSD result;
+ for (phase_map_t::iterator iter = mPhaseMap.begin(); iter != mPhaseMap.end(); ++iter)
+ {
+ const std::string& phase_name = iter->first;
+ result[phase_name]["completed"] = !(iter->second.getStarted());
+ result[phase_name]["elapsed"] = iter->second.getElapsedTimeF32();
+#if 0 // global stats for each phase seem like overkill here
+ phase_stats_t::iterator stats_iter = sPhaseStats.find(phase_name);
+ if (stats_iter != sPhaseStats.end())
+ {
+ result[phase_name]["stats"] = stats_iter->second.getData();
+ }
+#endif
+ }
+ return result;
+}
+
+// static initializer
+//static
+LLViewerStats::phase_stats_t LLViewerStats::PhaseMap::sStats;
+
+LLViewerStats::PhaseMap::PhaseMap()
+{
+}
+
+// static
+LLViewerStats::StatsAccumulator& LLViewerStats::PhaseMap::getPhaseStats(const std::string& phase_name)
+{
+ phase_stats_t::iterator it = sStats.find(phase_name);
+ if (it == sStats.end())
+ {
+ LLViewerStats::StatsAccumulator new_stats;
+ sStats[phase_name] = new_stats;
+ }
+ return sStats[phase_name];
+}
+
+// static
+void LLViewerStats::PhaseMap::recordPhaseStat(const std::string& phase_name, F32 value)
+{
+ LLViewerStats::StatsAccumulator& stats = getPhaseStats(phase_name);
+ stats.push(value);
+}
+
diff --git a/indra/newview/llviewerstats.h b/indra/newview/llviewerstats.h
index f91a1241fe..750d963f69 100644
--- a/indra/newview/llviewerstats.h
+++ b/indra/newview/llviewerstats.h
@@ -244,7 +244,7 @@ public:
inline F32 getStdDev() const
{
const F32 mean = getMean();
- return (mCount == 0) ? 0.f : sqrt( mSumOfSquares/mCount - (mean * mean) );
+ return (mCount < 2) ? 0.f : sqrt(llmax(0.f,mSumOfSquares/mCount - (mean * mean)));
}
inline U32 getCount() const
@@ -274,7 +274,28 @@ public:
};
StatsAccumulator mAgentPositionSnaps;
-
+
+ // Phase tracking (originally put in for avatar rezzing), tracking
+ // progress of active/completed phases for activities like outfit changing.
+ typedef std::map<std::string,LLFrameTimer> phase_map_t;
+ typedef std::map<std::string,StatsAccumulator> phase_stats_t;
+ class PhaseMap
+ {
+ private:
+ phase_map_t mPhaseMap;
+ static phase_stats_t sStats;
+ public:
+ PhaseMap();
+ LLFrameTimer& getPhaseTimer(const std::string& phase_name);
+ void startPhase(const std::string& phase_name);
+ void stopPhase(const std::string& phase_name);
+ void stopAllPhases();
+ void clearPhases();
+ LLSD dumpPhases();
+ static StatsAccumulator& getPhaseStats(const std::string& phase_name);
+ static void recordPhaseStat(const std::string& phase_name, F32 value);
+ };
+
private:
F64 mStats[ST_COUNT];
diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp
index 61236edc86..d844aeb12a 100644
--- a/indra/newview/llviewertexture.cpp
+++ b/indra/newview/llviewertexture.cpp
@@ -67,6 +67,7 @@
// statics
LLPointer<LLViewerTexture> LLViewerTexture::sNullImagep = NULL;
LLPointer<LLViewerTexture> LLViewerTexture::sBlackImagep = NULL;
+LLPointer<LLViewerTexture> LLViewerTexture::sCheckerBoardImagep = NULL;
LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sMissingAssetImagep = NULL;
LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sWhiteImagep = NULL;
LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sDefaultImagep = NULL;
@@ -87,6 +88,7 @@ S32 LLViewerTexture::sMaxBoundTextureMemInMegaBytes = 0;
S32 LLViewerTexture::sMaxTotalTextureMemInMegaBytes = 0;
S32 LLViewerTexture::sMaxDesiredTextureMemInBytes = 0 ;
S8 LLViewerTexture::sCameraMovingDiscardBias = 0 ;
+F32 LLViewerTexture::sCameraMovingBias = 0.0f ;
S32 LLViewerTexture::sMaxSculptRez = 128 ; //max sculpt image size
const S32 MAX_CACHED_RAW_IMAGE_AREA = 64 * 64 ;
const S32 MAX_CACHED_RAW_SCULPT_IMAGE_AREA = LLViewerTexture::sMaxSculptRez * LLViewerTexture::sMaxSculptRez ;
@@ -96,6 +98,9 @@ S32 LLViewerTexture::sMaxSmallImageSize = MAX_CACHED_RAW_IMAGE_AREA ;
BOOL LLViewerTexture::sFreezeImageScalingDown = FALSE ;
F32 LLViewerTexture::sCurrentTime = 0.0f ;
BOOL LLViewerTexture::sUseTextureAtlas = FALSE ;
+F32 LLViewerTexture::sTexelPixelRatio = 1.0f;
+
+LLViewerTexture::EDebugTexels LLViewerTexture::sDebugTexelsMode = LLViewerTexture::DEBUG_TEXELS_OFF;
const F32 desired_discard_bias_min = -2.0f; // -max number of levels to improve image quality by
const F32 desired_discard_bias_max = (F32)MAX_DISCARD_LEVEL; // max number of levels to reduce image quality by
@@ -175,7 +180,12 @@ LLViewerTexture* LLViewerTextureManager::findTexture(const LLUUID& id)
}
return tex ;
}
-
+
+LLViewerFetchedTexture* LLViewerTextureManager::findFetchedTexture(const LLUUID& id)
+{
+ return gTextureList.findImage(id);
+}
+
LLViewerMediaTexture* LLViewerTextureManager::findMediaTexture(const LLUUID &media_id)
{
return LLViewerMediaTexture::findMediaTexture(media_id) ;
@@ -347,6 +357,21 @@ void LLViewerTextureManager::init()
LLViewerFetchedTexture::sSmokeImagep = LLViewerTextureManager::getFetchedTexture(IMG_SMOKE, TRUE, LLViewerTexture::BOOST_UI);
LLViewerFetchedTexture::sSmokeImagep->setNoDelete() ;
+ image_raw = new LLImageRaw(32,32,3);
+ data = image_raw->getData();
+
+ for (S32 i = 0; i < (32*32*3); i+=3)
+ {
+ S32 x = (i % (32*3)) / (3*16);
+ S32 y = i / (32*3*16);
+ U8 color = ((x + y) % 2) * 255;
+ data[i] = color;
+ data[i+1] = color;
+ data[i+2] = color;
+ }
+
+ LLViewerTexture::sCheckerBoardImagep = LLViewerTextureManager::getLocalTexture(image_raw.get(), TRUE);
+
LLViewerTexture::initClass() ;
if (LLMetricPerformanceTesterBasic::isMetricLogRequested(sTesterName) && !LLMetricPerformanceTesterBasic::getTester(sTesterName))
@@ -367,6 +392,7 @@ void LLViewerTextureManager::cleanup()
LLImageGL::sDefaultGLTexture = NULL ;
LLViewerTexture::sNullImagep = NULL;
LLViewerTexture::sBlackImagep = NULL;
+ LLViewerTexture::sCheckerBoardImagep = NULL;
LLViewerFetchedTexture::sDefaultImagep = NULL;
LLViewerFetchedTexture::sSmokeImagep = NULL;
LLViewerFetchedTexture::sMissingAssetImagep = NULL;
@@ -383,11 +409,7 @@ void LLViewerTextureManager::cleanup()
void LLViewerTexture::initClass()
{
LLImageGL::sDefaultGLTexture = LLViewerFetchedTexture::sDefaultImagep->getGLTexture() ;
-
- if(gAuditTexture)
- {
- LLImageGL::setHighlightTexture(LLViewerTexture::OTHER) ;
- }
+ sTexelPixelRatio = gSavedSettings.getF32("TexelPixelRatio");
}
// static
@@ -534,7 +556,8 @@ void LLViewerTexture::updateClass(const F32 velocity, const F32 angular_velocity
F32 camera_moving_speed = LLViewerCamera::getInstance()->getAverageSpeed() ;
F32 camera_angular_speed = LLViewerCamera::getInstance()->getAverageAngularSpeed();
- sCameraMovingDiscardBias = (S8)llmax(0.2f * camera_moving_speed, 2.0f * camera_angular_speed - 1) ;
+ sCameraMovingBias = llmax(0.2f * camera_moving_speed, 2.0f * camera_angular_speed - 1);
+ sCameraMovingDiscardBias = (S8)(sCameraMovingBias);
LLViewerTexture::sFreezeImageScalingDown = (BYTES_TO_MEGA_BYTES(sBoundTextureMemoryInBytes) < 0.75f * sMaxBoundTextureMemInMegaBytes * texmem_middle_bound_scale) &&
(BYTES_TO_MEGA_BYTES(sTotalTextureMemoryInBytes) < 0.75f * sMaxTotalTextureMemInMegaBytes * texmem_middle_bound_scale) ;
@@ -655,10 +678,6 @@ void LLViewerTexture::setBoostLevel(S32 level)
{
setNoDelete() ;
}
- if(gAuditTexture)
- {
- setCategory(mBoostLevel);
- }
}
}
@@ -712,6 +731,7 @@ void LLViewerTexture::addTextureStats(F32 virtual_size, BOOL needs_gltexture) co
mNeedsGLTexture = TRUE ;
}
+ virtual_size *= sTexelPixelRatio;
if(!mMaxVirtualSizeResetCounter)
{
//flag to reset the values because the old values are used.
@@ -1287,6 +1307,7 @@ void LLViewerFetchedTexture::cleanup()
mCachedRawDiscardLevel = -1 ;
mCachedRawImageReady = FALSE ;
mSavedRawImage = NULL ;
+ mSavedRawDiscardLevel = -1;
}
void LLViewerFetchedTexture::setForSculpt()
@@ -1880,6 +1901,8 @@ S32 LLViewerFetchedTexture::getCurrentDiscardLevelForFetching()
bool LLViewerFetchedTexture::updateFetch()
{
static LLCachedControl<bool> textures_decode_disabled(gSavedSettings,"TextureDecodeDisabled");
+ static LLCachedControl<F32> sCameraMotionThreshold(gSavedSettings,"TextureCameraMotionThreshold");
+ static LLCachedControl<S32> sCameraMotionBoost(gSavedSettings,"TextureCameraMotionBoost");
if(textures_decode_disabled)
{
return false ;
@@ -2042,18 +2065,24 @@ bool LLViewerFetchedTexture::updateFetch()
// make_request = false;
//}
- if(make_request)
+ if (make_request)
{
- //load the texture progressively.
+ // Load the texture progressively: we try not to rush to the desired discard too fast.
+ // If the camera is not moving, we do not tweak the discard level notch by notch but go to the desired discard with larger boosted steps
+ // This mitigates the "textures stay blurry" problem when loading while not killing the texture memory while moving around
S32 delta_level = (mBoostLevel > LLViewerTexture::BOOST_NONE) ? 2 : 1 ;
- if(current_discard < 0)
+ if (current_discard < 0)
{
desired_discard = llmax(desired_discard, getMaxDiscardLevel() - delta_level);
}
- else
+ else if (LLViewerTexture::sCameraMovingBias < sCameraMotionThreshold)
{
- desired_discard = llmax(desired_discard, current_discard - delta_level);
+ desired_discard = llmax(desired_discard, current_discard - sCameraMotionBoost);
}
+ else
+ {
+ desired_discard = llmax(desired_discard, current_discard - delta_level);
+ }
if (mIsFetching)
{
@@ -2121,6 +2150,30 @@ bool LLViewerFetchedTexture::updateFetch()
return mIsFetching ? true : false;
}
+void LLViewerFetchedTexture::clearFetchedResults()
+{
+ llassert_always(!mNeedsCreateTexture && !mIsFetching);
+
+ cleanup();
+ destroyGLTexture();
+
+ if(getDiscardLevel() >= 0) //sculpty texture, force to invalidate
+ {
+ mGLTexturep->forceToInvalidateGLTexture();
+ }
+}
+
+void LLViewerFetchedTexture::forceToDeleteRequest()
+{
+ if (mHasFetcher)
+ {
+ LLAppViewer::getTextureFetch()->deleteRequest(getID(), true);
+ mHasFetcher = FALSE;
+ mIsFetching = FALSE ;
+ resetTextureStats();
+ }
+}
+
void LLViewerFetchedTexture::setIsMissingAsset()
{
if (mUrl.empty())
@@ -3290,10 +3343,14 @@ LLViewerMediaTexture::LLViewerMediaTexture(const LLUUID& id, BOOL usemipmaps, LL
sMediaMap.insert(std::make_pair(id, this));
mGLTexturep = gl_image ;
+
if(mGLTexturep.isNull())
{
generateGLTexture() ;
}
+
+ mGLTexturep->setAllowCompression(false);
+
mGLTexturep->setNeedsAlphaAndPickMask(FALSE) ;
mIsPlaying = FALSE ;
diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h
index b96441127d..f1105c3705 100644
--- a/indra/newview/llviewertexture.h
+++ b/indra/newview/llviewertexture.h
@@ -139,6 +139,7 @@ public:
OTHER,
MAX_GL_IMAGE_CATEGORY
};
+
static S32 getTotalNumOfCategories() ;
static S32 getIndexFromCategory(S32 category) ;
static S32 getCategoryFromIndex(S32 index) ;
@@ -263,6 +264,9 @@ protected:
void reorganizeVolumeList() ;
void setTexelsPerImage();
private:
+ friend class LLBumpImageList;
+ friend class LLUIImageList;
+
//note: do not make this function public.
/*virtual*/ LLImageGL* getGLTexture() const ;
virtual void switchToCachedImage();
@@ -309,6 +313,7 @@ protected:
} LLGLTextureState;
LLGLTextureState mTextureState ;
+ static F32 sTexelPixelRatio;
public:
static const U32 sCurrentFileVersion;
static S32 sImageCount;
@@ -323,6 +328,7 @@ public:
static S32 sMaxTotalTextureMemInMegaBytes;
static S32 sMaxDesiredTextureMemInBytes ;
static S8 sCameraMovingDiscardBias;
+ static F32 sCameraMovingBias;
static S32 sMaxSculptRez ;
static S32 sMinLargeImageSize ;
static S32 sMaxSmallImageSize ;
@@ -330,8 +336,19 @@ public:
static F32 sCurrentTime ;
static BOOL sUseTextureAtlas ;
+ enum EDebugTexels
+ {
+ DEBUG_TEXELS_OFF,
+ DEBUG_TEXELS_CURRENT,
+ DEBUG_TEXELS_DESIRED,
+ DEBUG_TEXELS_FULL
+ };
+
+ static EDebugTexels sDebugTexelsMode;
+
static LLPointer<LLViewerTexture> sNullImagep; // Null texture for non-textured objects.
static LLPointer<LLViewerTexture> sBlackImagep; // Texture to show NOTHING (pure black)
+ static LLPointer<LLViewerTexture> sCheckerBoardImagep; // Texture to show NOTHING (pure black)
};
@@ -420,6 +437,8 @@ public:
bool updateFetch();
+ void clearFetchedResults(); //clear all fetched results, for debug use.
+
// Override the computation of discard levels if we know the exact output
// size of the image. Used for UI textures to not decode, even if we have
// more data.
@@ -478,6 +497,7 @@ public:
BOOL hasFetcher() const { return mHasFetcher;}
void setCanUseHTTP(bool can_use_http) {mCanUseHTTP = can_use_http;}
+ void forceToDeleteRequest();
protected:
/*virtual*/ void switchToCachedImage();
S32 getCurrentDiscardLevelForFetching() ;
@@ -687,6 +707,7 @@ public:
//"find-texture" just check if the texture exists, if yes, return it, otherwise return null.
//
static LLViewerTexture* findTexture(const LLUUID& id) ;
+ static LLViewerFetchedTexture* findFetchedTexture(const LLUUID& id) ;
static LLViewerMediaTexture* findMediaTexture(const LLUUID& id) ;
static LLViewerMediaTexture* createMediaTexture(const LLUUID& id, BOOL usemipmaps = TRUE, LLImageGL* gl_image = NULL) ;
diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp
index 089f45ca89..528e0080b7 100644
--- a/indra/newview/llviewertexturelist.cpp
+++ b/indra/newview/llviewertexturelist.cpp
@@ -58,6 +58,7 @@
#include "pipeline.h"
#include "llappviewer.h"
#include "llxuiparser.h"
+#include "llagent.h"
////////////////////////////////////////////////////////////////////////////
@@ -597,6 +598,12 @@ static LLFastTimer::DeclareTimer FTM_IMAGE_STATS("Stats");
void LLViewerTextureList::updateImages(F32 max_time)
{
+ if(gAgent.getTeleportState() != LLAgent::TELEPORT_NONE)
+ {
+ clearFetchingRequests();
+ return;
+ }
+
LLAppViewer::getTextureFetch()->setTextureBandwidth(LLViewerStats::getInstance()->mTextureKBitStat.getMeanPerSec());
LLViewerStats::getInstance()->mNumImagesStat.addValue(sNumImages);
@@ -659,6 +666,24 @@ void LLViewerTextureList::updateImages(F32 max_time)
}
}
+void LLViewerTextureList::clearFetchingRequests()
+{
+ if (LLAppViewer::getTextureFetch()->getNumRequests() == 0)
+ {
+ return;
+ }
+
+ for (image_priority_list_t::iterator iter = mImageList.begin();
+ iter != mImageList.end(); ++iter)
+ {
+ LLViewerFetchedTexture* image = *iter;
+ if(image->hasFetcher())
+ {
+ image->forceToDeleteRequest() ;
+ }
+ }
+}
+
void LLViewerTextureList::updateImagesDecodePriorities()
{
// Update the decode priority for N images each frame
@@ -1030,7 +1055,6 @@ LLPointer<LLImageJ2C> LLViewerTextureList::convertToUploadFile(LLPointer<LLImage
{
raw_image->biasedScaleToPowerOfTwo(LLViewerFetchedTexture::MAX_IMAGE_SIZE_DEFAULT);
LLPointer<LLImageJ2C> compressedImage = new LLImageJ2C();
- compressedImage->setRate(0.f);
if (gSavedSettings.getBOOL("LosslessJ2CUpload") &&
(raw_image->getWidth() * raw_image->getHeight() <= LL_IMAGE_REZ_LOSSLESS_CUTOFF * LL_IMAGE_REZ_LOSSLESS_CUTOFF))
@@ -1432,6 +1456,9 @@ LLUIImagePtr LLUIImageList::loadUIImage(LLViewerFetchedTexture* imagep, const st
imagep->setAddressMode(LLTexUnit::TAM_CLAMP);
+ //don't compress UI images
+ imagep->getGLTexture()->setAllowCompression(false);
+
//all UI images are non-deletable
imagep->setNoDelete();
diff --git a/indra/newview/llviewertexturelist.h b/indra/newview/llviewertexturelist.h
index b386c73d2a..e89997fe28 100644
--- a/indra/newview/llviewertexturelist.h
+++ b/indra/newview/llviewertexturelist.h
@@ -110,6 +110,8 @@ public:
void doPreloadImages();
void doPrefetchImages();
+ void clearFetchingRequests();
+
static S32 getMinVideoRamSetting();
static S32 getMaxVideoRamSetting(bool get_recommended = false);
@@ -164,7 +166,7 @@ private:
// Request image from a specific host, used for baked avatar textures.
// Implemented in header in case someone changes default params above. JC
LLViewerFetchedTexture* getImageFromHost(const LLUUID& image_id, LLHost host)
- { return getImage(image_id, TRUE, LLViewerTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE, 0, 0, host); }
+ { return getImage(image_id, TRUE, LLViewerTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE, 0, 0, host); }
public:
typedef std::set<LLPointer<LLViewerFetchedTexture> > image_list_t;
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index ecd76f5495..39e330ad66 100755
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -534,7 +534,10 @@ public:
}
- addText(xpos, ypos, llformat("%d MB Vertex Data (%d MB Pooled)", LLVertexBuffer::sAllocatedBytes/(1024*1024), LLVBOPool::sBytesPooled/(1024*1024)));
+ addText(xpos, ypos, llformat("%d MB Index Data (%d MB Pooled, %d KIndices)", LLVertexBuffer::sAllocatedIndexBytes/(1024*1024), LLVBOPool::sIndexBytesPooled/(1024*1024), LLVertexBuffer::sIndexCount/1024));
+ ypos += y_inc;
+
+ addText(xpos, ypos, llformat("%d MB Vertex Data (%d MB Pooled, %d KVerts)", LLVertexBuffer::sAllocatedBytes/(1024*1024), LLVBOPool::sBytesPooled/(1024*1024), LLVertexBuffer::sVertexCount/1024));
ypos += y_inc;
addText(xpos, ypos, llformat("%d Vertex Buffers", LLVertexBuffer::sGLCount));
@@ -742,40 +745,41 @@ public:
if (gSavedSettings.getBOOL("DebugShowTextureInfo"))
{
LLViewerObject* objectp = NULL ;
- //objectp = = gAgentCamera.getFocusObject();
LLSelectNode* nodep = LLSelectMgr::instance().getHoverNode();
if (nodep)
{
- objectp = nodep->getObject();
+ objectp = nodep->getObject();
}
+
if (objectp && !objectp->isDead())
{
S32 num_faces = objectp->mDrawable->getNumFaces() ;
-
+ std::set<LLViewerFetchedTexture*> tex_list;
+
for(S32 i = 0 ; i < num_faces; i++)
{
LLFace* facep = objectp->mDrawable->getFace(i) ;
if(facep)
- {
- //addText(xpos, ypos, llformat("ts_min: %.3f ts_max: %.3f tt_min: %.3f tt_max: %.3f", facep->mTexExtents[0].mV[0], facep->mTexExtents[1].mV[0],
- // facep->mTexExtents[0].mV[1], facep->mTexExtents[1].mV[1]));
- //ypos += y_inc;
-
- addText(xpos, ypos, llformat("v_size: %.3f: p_size: %.3f", facep->getVirtualSize(), facep->getPixelArea()));
- ypos += y_inc;
-
- //const LLTextureEntry *tep = facep->getTextureEntry();
- //if(tep)
- //{
- // addText(xpos, ypos, llformat("scale_s: %.3f: scale_t: %.3f", tep->mScaleS, tep->mScaleT)) ;
- // ypos += y_inc;
- //}
-
- LLViewerTexture* tex = facep->getTexture() ;
+ {
+ LLViewerFetchedTexture* tex = dynamic_cast<LLViewerFetchedTexture*>(facep->getTexture()) ;
if(tex)
{
- addText(xpos, ypos, llformat("ID: %s v_size: %.3f", tex->getID().asString().c_str(), tex->getMaxVirtualSize()));
+ if(tex_list.find(tex) != tex_list.end())
+ {
+ continue ; //already displayed.
+ }
+ tex_list.insert(tex);
+
+ std::string uuid_str;
+ tex->getID().toString(uuid_str);
+ uuid_str = uuid_str.substr(0,7);
+
+ addText(xpos, ypos, llformat("ID: %s v_size: %.3f", uuid_str.c_str(), tex->getMaxVirtualSize()));
+ ypos += y_inc;
+
+ addText(xpos, ypos, llformat("discard level: %d desired level: %d Missing: %s", tex->getDiscardLevel(),
+ tex->getDesiredDiscardLevel(), tex->isMissingAsset() ? "Y" : "N"));
ypos += y_inc;
}
}
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index a7a4281860..eada77156e 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -101,6 +101,8 @@
#include "llvoicevisualizer.h" // Ventrella
#include "lldebugmessagebox.h"
+#include "llsdutil.h"
+
extern F32 SPEED_ADJUST_MAX;
extern F32 SPEED_ADJUST_MAX_SEC;
extern F32 ANIM_SPEED_MAX;
@@ -627,7 +629,6 @@ F32 LLVOAvatar::sLODFactor = 1.f;
F32 LLVOAvatar::sPhysicsLODFactor = 1.f;
BOOL LLVOAvatar::sUseImpostors = FALSE;
BOOL LLVOAvatar::sJointDebug = FALSE;
-
F32 LLVOAvatar::sUnbakedTime = 0.f;
F32 LLVOAvatar::sUnbakedUpdateTime = 0.f;
F32 LLVOAvatar::sGreyTime = 0.f;
@@ -683,13 +684,16 @@ LLVOAvatar::LLVOAvatar(const LLUUID& id,
mNeedsSkin(FALSE),
mLastSkinTime(0.f),
mUpdatePeriod(1),
+ mFirstFullyVisible(TRUE),
mFullyLoaded(FALSE),
mPreviousFullyLoaded(FALSE),
mFullyLoadedInitialized(FALSE),
mSupportsAlphaLayers(FALSE),
mLoadedCallbacksPaused(FALSE),
mHasPelvisOffset( FALSE ),
- mRenderUnloadedAvatar(LLCachedControl<bool>(gSavedSettings, "RenderUnloadedAvatar"))
+ mRenderUnloadedAvatar(LLCachedControl<bool>(gSavedSettings, "RenderUnloadedAvatar")),
+ mLastRezzedStatus(-1)
+
{
LLMemType mt(LLMemType::MTYPE_AVATAR);
//VTResume(); // VTune
@@ -770,32 +774,46 @@ LLVOAvatar::LLVOAvatar(const LLUUID& id,
mLastPelvisFixup = 0.0f;
}
+std::string LLVOAvatar::avString() const
+{
+ std::string viz_string = LLVOAvatar::rezStatusToString(getRezzedStatus());
+ return " Avatar '" + getFullname() + "' " + viz_string + " ";
+}
+
+void LLVOAvatar::debugAvatarRezTime(std::string notification_name, std::string comment)
+{
+ LL_INFOS("Avatar") << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32()
+ << "sec ]"
+ << avString()
+ << "RuthTimer " << (U32)mRuthDebugTimer.getElapsedTimeF32()
+ << " Notification " << notification_name
+ << " : " << comment
+ << llendl;
+
+ if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
+ {
+ LLSD args;
+ args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
+ args["TIME"] = llformat("%d",(U32)mRuthDebugTimer.getElapsedTimeF32());
+ args["NAME"] = getFullname();
+ LLNotificationsUtil::add(notification_name,args);
+ }
+}
+
//------------------------------------------------------------------------
// LLVOAvatar::~LLVOAvatar()
//------------------------------------------------------------------------
LLVOAvatar::~LLVOAvatar()
{
- if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
+ if (!mFullyLoaded)
{
- if (!mFullyLoaded)
- {
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' left after " << (U32)mRuthDebugTimer.getElapsedTimeF32() << " seconds as cloud." << llendl;
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["TIME"] = llformat("%d",(U32)mRuthDebugTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezLeftCloudNotification",args);
- }
- else
- {
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' left." << llendl;
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezLeftNotification",args);
- }
-
+ debugAvatarRezTime("AvatarRezLeftCloudNotification","left after ruth seconds as cloud");
}
+ else
+ {
+ debugAvatarRezTime("AvatarRezLeftNotification","left sometime after declouding");
+ }
+
lldebugs << "LLVOAvatar Destructor (0x" << this << ") id:" << mID << llendl;
mRoot.removeAllChildren();
@@ -844,6 +862,8 @@ LLVOAvatar::~LLVOAvatar()
mAnimationSources.clear();
LLLoadedCallbackEntry::cleanUpCallbackList(&mCallbackTextureList) ;
+ getPhases().clearPhases();
+
lldebugs << "LLVOAvatar Destructor end" << llendl;
}
@@ -877,6 +897,55 @@ BOOL LLVOAvatar::isFullyBaked()
return TRUE;
}
+BOOL LLVOAvatar::isFullyTextured() const
+{
+ for (S32 i = 0; i < mMeshLOD.size(); i++)
+ {
+ LLViewerJoint* joint = (LLViewerJoint*) mMeshLOD[i];
+ if (i==MESH_ID_SKIRT && !isWearingWearableType(LLWearableType::WT_SKIRT))
+ {
+ continue; // don't care about skirt textures if we're not wearing one.
+ }
+ if (!joint)
+ {
+ continue; // nonexistent LOD OK.
+ }
+ std::vector<LLViewerJointMesh*>::iterator meshIter = joint->mMeshParts.begin();
+ if (meshIter != joint->mMeshParts.end())
+ {
+ LLViewerJointMesh *mesh = (LLViewerJointMesh *) *meshIter;
+ if (!mesh)
+ {
+ continue; // nonexistent mesh OK
+ }
+ if (mesh->mTexture.notNull() && mesh->mTexture->hasGLTexture())
+ {
+ continue; // Mesh exists and has a baked texture.
+ }
+ if (mesh->mLayerSet && mesh->mLayerSet->hasComposite())
+ {
+ continue; // Mesh exists and has a composite texture.
+ }
+ // Fail
+ return FALSE;
+ }
+ }
+ return TRUE;
+}
+
+BOOL LLVOAvatar::hasGray() const
+{
+ return !getIsCloud() && !isFullyTextured();
+}
+
+S32 LLVOAvatar::getRezzedStatus() const
+{
+ if (getIsCloud()) return 0;
+ if (isFullyTextured()) return 2;
+ llassert(hasGray());
+ return 1; // gray
+}
+
void LLVOAvatar::deleteLayerSetCaches(bool clearAll)
{
for (U32 i = 0; i < mBakedTextureDatas.size(); i++)
@@ -924,6 +993,31 @@ BOOL LLVOAvatar::areAllNearbyInstancesBaked(S32& grey_avatars)
}
// static
+void LLVOAvatar::getNearbyRezzedStats(std::vector<S32>& counts)
+{
+ counts.clear();
+ counts.resize(3);
+ for (std::vector<LLCharacter*>::iterator iter = LLCharacter::sInstances.begin();
+ iter != LLCharacter::sInstances.end(); ++iter)
+ {
+ LLVOAvatar* inst = (LLVOAvatar*) *iter;
+ if (!inst)
+ continue;
+ S32 rez_status = inst->getRezzedStatus();
+ counts[rez_status]++;
+ }
+}
+
+// static
+std::string LLVOAvatar::rezStatusToString(S32 rez_status)
+{
+ if (rez_status==0) return "cloud";
+ if (rez_status==1) return "gray";
+ if (rez_status==2) return "textured";
+ return "unknown";
+}
+
+// static
void LLVOAvatar::dumpBakedStatus()
{
LLVector3d camera_pos_global = gAgentCamera.getCameraPositionGlobal();
@@ -2248,18 +2342,12 @@ U32 LLVOAvatar::processUpdateMessage(LLMessageSystem *mesgsys,
U32 retval = LLViewerObject::processUpdateMessage(mesgsys, user_data, block_num, update_type, dp);
// Print out arrival information once we have name of avatar.
- if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
+ if (has_name && getNVPair("FirstName"))
{
- if (has_name && getNVPair("FirstName"))
- {
- mDebugExistenceTimer.reset();
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezArrivedNotification",args);
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' arrived." << llendl;
- }
+ mDebugExistenceTimer.reset();
+ debugAvatarRezTime("AvatarRezArrivedNotification","avatar arrived");
}
+
if(retval & LLViewerObject::INVALID_UPDATE)
{
if (isSelf())
@@ -2765,16 +2853,16 @@ void LLVOAvatar::idleUpdateLoadingEffect()
// update visibility when avatar is partially loaded
if (updateIsFullyLoaded()) // changed?
{
- if (isFullyLoaded() && isSelf())
+ if (isFullyLoaded() && mFirstFullyVisible && isSelf())
{
- static bool first_fully_visible = true;
- if (first_fully_visible)
- {
- llinfos << "self isFullyLoaded, first_fully_visible" << llendl;
-
- first_fully_visible = false;
- LLAppearanceMgr::instance().onFirstFullyVisible();
- }
+ LL_INFOS("Avatar") << avString() << "self isFullyLoaded, mFirstFullyVisible" << LL_ENDL;
+ mFirstFullyVisible = FALSE;
+ LLAppearanceMgr::instance().onFirstFullyVisible();
+ }
+ if (isFullyLoaded() && mFirstFullyVisible && !isSelf())
+ {
+ LL_INFOS("Avatar") << avString() << "other isFullyLoaded, mFirstFullyVisible" << LL_ENDL;
+ mFirstFullyVisible = FALSE;
}
if (isFullyLoaded())
{
@@ -2918,43 +3006,43 @@ void LLVOAvatar::idleUpdateNameTag(const LLVector3& root_pos_last)
return;
}
- BOOL new_name = FALSE;
- if (visible_chat != mVisibleChat)
+ BOOL new_name = FALSE;
+ if (visible_chat != mVisibleChat)
+ {
+ mVisibleChat = visible_chat;
+ new_name = TRUE;
+ }
+
+ if (sRenderGroupTitles != mRenderGroupTitles)
+ {
+ mRenderGroupTitles = sRenderGroupTitles;
+ new_name = TRUE;
+ }
+
+ // First Calculate Alpha
+ // If alpha > 0, create mNameText if necessary, otherwise delete it
+ F32 alpha = 0.f;
+ if (mAppAngle > 5.f)
+ {
+ const F32 START_FADE_TIME = NAME_SHOW_TIME - FADE_DURATION;
+ if (!visible_chat && sRenderName == RENDER_NAME_FADE && time_visible > START_FADE_TIME)
{
- mVisibleChat = visible_chat;
- new_name = TRUE;
+ alpha = 1.f - (time_visible - START_FADE_TIME) / FADE_DURATION;
}
-
- if (sRenderGroupTitles != mRenderGroupTitles)
+ else
{
- mRenderGroupTitles = sRenderGroupTitles;
- new_name = TRUE;
+ // ...not fading, full alpha
+ alpha = 1.f;
}
-
- // First Calculate Alpha
- // If alpha > 0, create mNameText if necessary, otherwise delete it
- F32 alpha = 0.f;
- if (mAppAngle > 5.f)
- {
- const F32 START_FADE_TIME = NAME_SHOW_TIME - FADE_DURATION;
- if (!visible_chat && sRenderName == RENDER_NAME_FADE && time_visible > START_FADE_TIME)
- {
- alpha = 1.f - (time_visible - START_FADE_TIME) / FADE_DURATION;
- }
- else
- {
- // ...not fading, full alpha
- alpha = 1.f;
- }
- }
- else if (mAppAngle > 2.f)
- {
- // far away is faded out also
- alpha = (mAppAngle-2.f)/3.f;
- }
+ }
+ else if (mAppAngle > 2.f)
+ {
+ // far away is faded out also
+ alpha = (mAppAngle-2.f)/3.f;
+ }
if (alpha <= 0.f)
- {
+ {
if (mNameText)
{
mNameText->markDead();
@@ -2964,19 +3052,19 @@ void LLVOAvatar::idleUpdateNameTag(const LLVector3& root_pos_last)
return;
}
- if (!mNameText)
- {
+ if (!mNameText)
+ {
mNameText = static_cast<LLHUDNameTag*>( LLHUDObject::addHUDObject(
- LLHUDObject::LL_HUD_NAME_TAG) );
+ LLHUDObject::LL_HUD_NAME_TAG) );
//mNameText->setMass(10.f);
- mNameText->setSourceObject(this);
+ mNameText->setSourceObject(this);
mNameText->setVertAlignment(LLHUDNameTag::ALIGN_VERT_TOP);
- mNameText->setVisibleOffScreen(TRUE);
- mNameText->setMaxLines(11);
- mNameText->setFadeDistance(CHAT_NORMAL_RADIUS, 5.f);
- sNumVisibleChatBubbles++;
- new_name = TRUE;
- }
+ mNameText->setVisibleOffScreen(TRUE);
+ mNameText->setMaxLines(11);
+ mNameText->setFadeDistance(CHAT_NORMAL_RADIUS, 5.f);
+ sNumVisibleChatBubbles++;
+ new_name = TRUE;
+ }
LLVector3 name_position = idleUpdateNameTagPosition(root_pos_last);
mNameText->setPositionAgent(name_position);
@@ -2985,10 +3073,10 @@ void LLVOAvatar::idleUpdateNameTag(const LLVector3& root_pos_last)
}
void LLVOAvatar::idleUpdateNameTagText(BOOL new_name)
- {
- LLNameValue *title = getNVPair("Title");
- LLNameValue* firstname = getNVPair("FirstName");
- LLNameValue* lastname = getNVPair("LastName");
+{
+ LLNameValue *title = getNVPair("Title");
+ LLNameValue* firstname = getNVPair("FirstName");
+ LLNameValue* lastname = getNVPair("LastName");
// Avatars must have a first and last name
if (!firstname || !lastname) return;
@@ -3002,34 +3090,23 @@ void LLVOAvatar::idleUpdateNameTagText(BOOL new_name)
is_muted = false;
}
else
- {
+ {
is_muted = LLMuteList::getInstance()->isMuted(getID());
}
bool is_friend = LLAvatarTracker::instance().isBuddy(getID());
bool is_cloud = getIsCloud();
- if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
- {
- if (is_appearance != mNameAppearance)
- {
- if (is_appearance)
- {
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezEnteredAppearanceNotification",args);
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' entered appearance mode." << llendl;
- }
- else
- {
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezLeftAppearanceNotification",args);
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' left appearance mode." << llendl;
- }
- }
- }
+ if (is_appearance != mNameAppearance)
+ {
+ if (is_appearance)
+ {
+ debugAvatarRezTime("AvatarRezEnteredAppearanceNotification","entered appearance mode");
+ }
+ else
+ {
+ debugAvatarRezTime("AvatarRezLeftAppearanceNotification","left appearance mode");
+ }
+ }
// Rebuild name tag if state change detected
if (mNameString.empty()
@@ -3039,56 +3116,56 @@ void LLVOAvatar::idleUpdateNameTagText(BOOL new_name)
|| is_away != mNameAway
|| is_busy != mNameBusy
|| is_muted != mNameMute
- || is_appearance != mNameAppearance
+ || is_appearance != mNameAppearance
|| is_friend != mNameFriend
|| is_cloud != mNameCloud)
- {
+ {
LLColor4 name_tag_color = getNameTagColor(is_friend);
clearNameTag();
if (is_away || is_muted || is_busy || is_appearance)
- {
+ {
std::string line;
- if (is_away)
- {
- line += LLTrans::getString("AvatarAway");
+ if (is_away)
+ {
+ line += LLTrans::getString("AvatarAway");
line += ", ";
- }
- if (is_busy)
- {
+ }
+ if (is_busy)
+ {
line += LLTrans::getString("AvatarBusy");
line += ", ";
}
if (is_muted)
- {
+ {
line += LLTrans::getString("AvatarMuted");
- line += ", ";
- }
+ line += ", ";
+ }
if (is_appearance)
{
line += LLTrans::getString("AvatarEditingAppearance");
line += ", ";
- }
+ }
if (is_cloud)
- {
+ {
line += LLTrans::getString("LoadingData");
line += ", ";
}
// trim last ", "
line.resize( line.length() - 2 );
addNameTagLine(line, name_tag_color, LLFontGL::NORMAL,
- LLFontGL::getFontSansSerifSmall());
+ LLFontGL::getFontSansSerifSmall());
}
if (sRenderGroupTitles
&& title && title->getString() && title->getString()[0] != '\0')
- {
+ {
std::string title_str = title->getString();
LLStringFn::replace_ascii_controlchars(title_str,LL_UNKNOWN_CHAR);
addNameTagLine(title_str, name_tag_color, LLFontGL::NORMAL,
- LLFontGL::getFontSansSerifSmall());
- }
+ LLFontGL::getFontSansSerifSmall());
+ }
static LLUICachedControl<bool> show_display_names("NameTagShowDisplayNames");
static LLUICachedControl<bool> show_usernames("NameTagShowUsernames");
@@ -3101,120 +3178,120 @@ void LLVOAvatar::idleUpdateNameTagText(BOOL new_name)
// ...call this function back when the name arrives
// and force a rebuild
LLAvatarNameCache::get(getID(),
- boost::bind(&LLVOAvatar::clearNameTag, this));
- }
+ boost::bind(&LLVOAvatar::clearNameTag, this));
+ }
// Might be blank if name not available yet, that's OK
if (show_display_names)
{
addNameTagLine(av_name.mDisplayName, name_tag_color, LLFontGL::NORMAL,
- LLFontGL::getFontSansSerif());
- }
+ LLFontGL::getFontSansSerif());
+ }
// Suppress SLID display if display name matches exactly (ugh)
if (show_usernames && !av_name.mIsDisplayNameDefault)
- {
+ {
// *HACK: Desaturate the color
LLColor4 username_color = name_tag_color * 0.83f;
addNameTagLine(av_name.mUsername, username_color, LLFontGL::NORMAL,
- LLFontGL::getFontSansSerifSmall());
+ LLFontGL::getFontSansSerifSmall());
}
- }
+ }
else
- {
+ {
const LLFontGL* font = LLFontGL::getFontSansSerif();
std::string full_name =
LLCacheName::buildFullName( firstname->getString(), lastname->getString() );
addNameTagLine(full_name, name_tag_color, LLFontGL::NORMAL, font);
- }
+ }
- mNameAway = is_away;
- mNameBusy = is_busy;
- mNameMute = is_muted;
- mNameAppearance = is_appearance;
+ mNameAway = is_away;
+ mNameBusy = is_busy;
+ mNameMute = is_muted;
+ mNameAppearance = is_appearance;
mNameFriend = is_friend;
- mNameCloud = is_cloud;
- mTitle = title ? title->getString() : "";
- LLStringFn::replace_ascii_controlchars(mTitle,LL_UNKNOWN_CHAR);
- new_name = TRUE;
- }
+ mNameCloud = is_cloud;
+ mTitle = title ? title->getString() : "";
+ LLStringFn::replace_ascii_controlchars(mTitle,LL_UNKNOWN_CHAR);
+ new_name = TRUE;
+ }
if (mVisibleChat)
- {
- mNameText->setFont(LLFontGL::getFontSansSerif());
+ {
+ mNameText->setFont(LLFontGL::getFontSansSerif());
mNameText->setTextAlignment(LLHUDNameTag::ALIGN_TEXT_LEFT);
- mNameText->setFadeDistance(CHAT_NORMAL_RADIUS * 2.f, 5.f);
+ mNameText->setFadeDistance(CHAT_NORMAL_RADIUS * 2.f, 5.f);
- char line[MAX_STRING]; /* Flawfinder: ignore */
- line[0] = '\0';
- std::deque<LLChat>::iterator chat_iter = mChats.begin();
- mNameText->clearString();
-
- LLColor4 new_chat = LLUIColorTable::instance().getColor( isSelf() ? "UserChatColor" : "AgentChatColor" );
- LLColor4 normal_chat = lerp(new_chat, LLColor4(0.8f, 0.8f, 0.8f, 1.f), 0.7f);
- LLColor4 old_chat = lerp(normal_chat, LLColor4(0.6f, 0.6f, 0.6f, 1.f), 0.7f);
- if (mTyping && mChats.size() >= MAX_BUBBLE_CHAT_UTTERANCES)
- {
- ++chat_iter;
- }
+ char line[MAX_STRING]; /* Flawfinder: ignore */
+ line[0] = '\0';
+ std::deque<LLChat>::iterator chat_iter = mChats.begin();
+ mNameText->clearString();
- for(; chat_iter != mChats.end(); ++chat_iter)
- {
- F32 chat_fade_amt = llclamp((F32)((LLFrameTimer::getElapsedSeconds() - chat_iter->mTime) / CHAT_FADE_TIME), 0.f, 4.f);
- LLFontGL::StyleFlags style;
- switch(chat_iter->mChatType)
- {
- case CHAT_TYPE_WHISPER:
- style = LLFontGL::ITALIC;
- break;
- case CHAT_TYPE_SHOUT:
- style = LLFontGL::BOLD;
- break;
- default:
- style = LLFontGL::NORMAL;
- break;
- }
- if (chat_fade_amt < 1.f)
- {
- F32 u = clamp_rescale(chat_fade_amt, 0.9f, 1.f, 0.f, 1.f);
- mNameText->addLine(chat_iter->mText, lerp(new_chat, normal_chat, u), style);
- }
- else if (chat_fade_amt < 2.f)
- {
- F32 u = clamp_rescale(chat_fade_amt, 1.9f, 2.f, 0.f, 1.f);
- mNameText->addLine(chat_iter->mText, lerp(normal_chat, old_chat, u), style);
- }
- else if (chat_fade_amt < 3.f)
- {
- // *NOTE: only remove lines down to minimum number
- mNameText->addLine(chat_iter->mText, old_chat, style);
- }
- }
- mNameText->setVisibleOffScreen(TRUE);
-
- if (mTyping)
- {
- S32 dot_count = (llfloor(mTypingTimer.getElapsedTimeF32() * 3.f) + 2) % 3 + 1;
- switch(dot_count)
- {
- case 1:
- mNameText->addLine(".", new_chat);
- break;
- case 2:
- mNameText->addLine("..", new_chat);
- break;
- case 3:
- mNameText->addLine("...", new_chat);
- break;
- }
+ LLColor4 new_chat = LLUIColorTable::instance().getColor( isSelf() ? "UserChatColor" : "AgentChatColor" );
+ LLColor4 normal_chat = lerp(new_chat, LLColor4(0.8f, 0.8f, 0.8f, 1.f), 0.7f);
+ LLColor4 old_chat = lerp(normal_chat, LLColor4(0.6f, 0.6f, 0.6f, 1.f), 0.7f);
+ if (mTyping && mChats.size() >= MAX_BUBBLE_CHAT_UTTERANCES)
+ {
+ ++chat_iter;
+ }
- }
+ for(; chat_iter != mChats.end(); ++chat_iter)
+ {
+ F32 chat_fade_amt = llclamp((F32)((LLFrameTimer::getElapsedSeconds() - chat_iter->mTime) / CHAT_FADE_TIME), 0.f, 4.f);
+ LLFontGL::StyleFlags style;
+ switch(chat_iter->mChatType)
+ {
+ case CHAT_TYPE_WHISPER:
+ style = LLFontGL::ITALIC;
+ break;
+ case CHAT_TYPE_SHOUT:
+ style = LLFontGL::BOLD;
+ break;
+ default:
+ style = LLFontGL::NORMAL;
+ break;
}
- else
+ if (chat_fade_amt < 1.f)
+ {
+ F32 u = clamp_rescale(chat_fade_amt, 0.9f, 1.f, 0.f, 1.f);
+ mNameText->addLine(chat_iter->mText, lerp(new_chat, normal_chat, u), style);
+ }
+ else if (chat_fade_amt < 2.f)
+ {
+ F32 u = clamp_rescale(chat_fade_amt, 1.9f, 2.f, 0.f, 1.f);
+ mNameText->addLine(chat_iter->mText, lerp(normal_chat, old_chat, u), style);
+ }
+ else if (chat_fade_amt < 3.f)
+ {
+ // *NOTE: only remove lines down to minimum number
+ mNameText->addLine(chat_iter->mText, old_chat, style);
+ }
+ }
+ mNameText->setVisibleOffScreen(TRUE);
+
+ if (mTyping)
+ {
+ S32 dot_count = (llfloor(mTypingTimer.getElapsedTimeF32() * 3.f) + 2) % 3 + 1;
+ switch(dot_count)
{
+ case 1:
+ mNameText->addLine(".", new_chat);
+ break;
+ case 2:
+ mNameText->addLine("..", new_chat);
+ break;
+ case 3:
+ mNameText->addLine("...", new_chat);
+ break;
+ }
+
+ }
+ }
+ else
+ {
// ...not using chat bubbles, just names
mNameText->setTextAlignment(LLHUDNameTag::ALIGN_TEXT_CENTER);
- mNameText->setFadeDistance(CHAT_NORMAL_RADIUS, 5.f);
- mNameText->setVisibleOffScreen(FALSE);
+ mNameText->setFadeDistance(CHAT_NORMAL_RADIUS, 5.f);
+ mNameText->setVisibleOffScreen(FALSE);
}
}
@@ -3237,8 +3314,8 @@ void LLVOAvatar::clearNameTag()
{
mNameString.clear();
if (mNameText)
- {
- mNameText->setLabel("");
+ {
+ mNameText->setLabel("");
mNameText->setString( "" );
}
}
@@ -3964,7 +4041,7 @@ void LLVOAvatar::updateVisibility()
LLNameValue* firstname = getNVPair("FirstName");
if (firstname)
{
- llinfos << "Avatar " << firstname->getString() << " updating visiblity" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " updating visibility" << LL_ENDL;
}
else
{
@@ -4130,11 +4207,11 @@ U32 LLVOAvatar::renderSkinned(EAvatarRenderPass pass)
{ //LOD changed or new mesh created, allocate new vertex buffer if needed
if (needs_rebuild || mDirtyMesh >= 2 || mVisibilityRank <= 4)
{
- updateMeshData();
+ updateMeshData();
mDirtyMesh = 0;
- mNeedsSkin = TRUE;
- mDrawable->clearState(LLDrawable::REBUILD_GEOMETRY);
- }
+ mNeedsSkin = TRUE;
+ mDrawable->clearState(LLDrawable::REBUILD_GEOMETRY);
+ }
}
if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_AVATAR) <= 0)
@@ -4176,7 +4253,7 @@ U32 LLVOAvatar::renderSkinned(EAvatarRenderPass pass)
LLNameValue* firstname = getNVPair("FirstName");
if (firstname)
{
- llinfos << "Avatar " << firstname->getString() << " in render" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " in render" << LL_ENDL;
}
else
{
@@ -6393,10 +6470,10 @@ BOOL LLVOAvatar::isVisible() const
}
// Determine if we have enough avatar data to render
-BOOL LLVOAvatar::getIsCloud()
+BOOL LLVOAvatar::getIsCloud() const
{
// Do we have a shape?
- if (visualParamWeightsAreDefault())
+ if ((const_cast<LLVOAvatar*>(this))->visualParamWeightsAreDefault())
{
return TRUE;
}
@@ -6415,11 +6492,53 @@ BOOL LLVOAvatar::getIsCloud()
return FALSE;
}
+void LLVOAvatar::updateRezzedStatusTimers()
+{
+ // State machine for rezzed status. Statuses are 0 = cloud, 1 = gray, 2 = textured.
+ // Purpose is to collect time data for each period of cloud or cloud+gray.
+ S32 rez_status = getRezzedStatus();
+ if (rez_status != mLastRezzedStatus)
+ {
+ LL_DEBUGS("Avatar") << avString() << "rez state change: " << mLastRezzedStatus << " -> " << rez_status << LL_ENDL;
+ bool is_cloud_or_gray = (rez_status==0 || rez_status==1);
+ bool was_cloud_or_gray = (mLastRezzedStatus==0 || mLastRezzedStatus==1);
+ bool is_cloud = (rez_status==0);
+ bool was_cloud = (mLastRezzedStatus==0);
+
+ // Non-cloud to cloud
+ if (is_cloud && !was_cloud)
+ {
+ // start cloud timer.
+ getPhases().startPhase("cloud");
+ }
+ else if (was_cloud && !is_cloud)
+ {
+ // stop cloud timer, which will capture stats.
+ getPhases().stopPhase("cloud");
+ }
+
+ // Non-cloud-or-gray to cloud-or-gray
+ if (is_cloud_or_gray && !was_cloud_or_gray)
+ {
+ // start cloud-or-gray timer.
+ getPhases().startPhase("cloud-or-gray");
+ }
+ else if (was_cloud_or_gray && !is_cloud_or_gray)
+ {
+ // stop cloud-or-gray timer, which will capture stats.
+ getPhases().stopPhase("cloud-or-gray");
+ }
+
+ mLastRezzedStatus = rez_status;
+ }
+}
+
// call periodically to keep isFullyLoaded up to date.
// returns true if the value has changed.
BOOL LLVOAvatar::updateIsFullyLoaded()
{
const BOOL loading = getIsCloud();
+ updateRezzedStatusTimers();
updateRuthTimer(loading);
return processFullyLoadedChange(loading);
}
@@ -6434,27 +6553,19 @@ void LLVOAvatar::updateRuthTimer(bool loading)
if (mPreviousFullyLoaded)
{
mRuthTimer.reset();
- if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
- {
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' became cloud." << llendl;
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["TIME"] = llformat("%d",(U32)mRuthDebugTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezCloudNotification",args);
- }
- mRuthDebugTimer.reset();
+ debugAvatarRezTime("AvatarRezCloudNotification","became cloud");
}
const F32 LOADING_TIMEOUT__SECONDS = 120.f;
if (mRuthTimer.getElapsedTimeF32() > LOADING_TIMEOUT__SECONDS)
{
- llinfos << "Ruth Timer timeout: Missing texture data for '" << getFullname() << "' "
+ LL_DEBUGS("Avatar") << avString()
+ << "Ruth Timer timeout: Missing texture data for '" << getFullname() << "' "
<< "( Params loaded : " << !visualParamWeightsAreDefault() << " ) "
<< "( Lower : " << isTextureDefined(TEX_LOWER_BAKED) << " ) "
<< "( Upper : " << isTextureDefined(TEX_UPPER_BAKED) << " ) "
<< "( Head : " << isTextureDefined(TEX_HEAD_BAKED) << " )."
- << llendl;
+ << LL_ENDL;
LLAvatarPropertiesProcessor::getInstance()->sendAvatarTexturesRequest(getID());
mRuthTimer.reset();
@@ -6471,20 +6582,13 @@ BOOL LLVOAvatar::processFullyLoadedChange(bool loading)
mFullyLoaded = (mFullyLoadedTimer.getElapsedTimeF32() > PAUSE);
- if (gSavedSettings.getBOOL("DebugAvatarRezTime"))
+ if (!mPreviousFullyLoaded && !loading && mFullyLoaded)
{
- if (!mPreviousFullyLoaded && !loading && mFullyLoaded)
- {
- llinfos << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32() << "sec ] Avatar '" << getFullname() << "' resolved in " << (U32)mRuthDebugTimer.getElapsedTimeF32() << " seconds." << llendl;
- LLSD args;
- args["EXISTENCE"] = llformat("%d",(U32)mDebugExistenceTimer.getElapsedTimeF32());
- args["TIME"] = llformat("%d",(U32)mRuthDebugTimer.getElapsedTimeF32());
- args["NAME"] = getFullname();
- LLNotificationsUtil::add("AvatarRezNotification",args);
- }
+ debugAvatarRezTime("AvatarRezNotification","fully loaded");
}
// did our loading state "change" from last call?
+ // runway - why are we updating every 30 calls even if nothing has changed?
const S32 UPDATE_RATE = 30;
BOOL changed =
((mFullyLoaded != mPreviousFullyLoaded) || // if the value is different from the previous call
@@ -6924,7 +7028,7 @@ LLColor4 LLVOAvatar::getDummyColor()
void LLVOAvatar::dumpAvatarTEs( const std::string& context ) const
{
- llinfos << (isSelf() ? "Self: " : "Other: ") << context << llendl;
+ LL_DEBUGS("Avatar") << avString() << (isSelf() ? "Self: " : "Other: ") << context << LL_ENDL;
for (LLVOAvatarDictionary::Textures::const_iterator iter = LLVOAvatarDictionary::getInstance()->getTextures().begin();
iter != LLVOAvatarDictionary::getInstance()->getTextures().end();
++iter)
@@ -6934,23 +7038,23 @@ void LLVOAvatar::dumpAvatarTEs( const std::string& context ) const
const LLViewerTexture* te_image = getImage(iter->first,0);
if( !te_image )
{
- llinfos << " " << texture_dict->mName << ": null ptr" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " " << texture_dict->mName << ": null ptr" << LL_ENDL;
}
else if( te_image->getID().isNull() )
{
- llinfos << " " << texture_dict->mName << ": null UUID" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " " << texture_dict->mName << ": null UUID" << LL_ENDL;
}
else if( te_image->getID() == IMG_DEFAULT )
{
- llinfos << " " << texture_dict->mName << ": IMG_DEFAULT" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " " << texture_dict->mName << ": IMG_DEFAULT" << LL_ENDL;
}
else if( te_image->getID() == IMG_DEFAULT_AVATAR )
{
- llinfos << " " << texture_dict->mName << ": IMG_DEFAULT_AVATAR" << llendl;
+ LL_DEBUGS("Avatar") << avString() << " " << texture_dict->mName << ": IMG_DEFAULT_AVATAR" << LL_ENDL;
}
else
{
- llinfos << " " << texture_dict->mName << ": " << te_image->getID() << llendl;
+ LL_DEBUGS("Avatar") << avString() << " " << texture_dict->mName << ": " << te_image->getID() << LL_ENDL;
}
}
}
@@ -7081,6 +7185,7 @@ void LLVOAvatar::rebuildHUD()
//-----------------------------------------------------------------------------
void LLVOAvatar::onFirstTEMessageReceived()
{
+ LL_INFOS("Avatar") << avString() << LL_ENDL;
if( !mFirstTEMessageReceived )
{
mFirstTEMessageReceived = TRUE;
@@ -7109,6 +7214,7 @@ void LLVOAvatar::onFirstTEMessageReceived()
image->setLoadedCallback( onBakedTextureMasksLoaded, MORPH_MASK_REQUESTED_DISCARD, TRUE, TRUE, new LLTextureMaskData( mID ),
src_callback_list, paused);
}
+ LL_DEBUGS("Avatar") << avString() << "layer_baked, setting onInitialBakedTextureLoaded as callback" << LL_ENDL;
image->setLoadedCallback( onInitialBakedTextureLoaded, MAX_DISCARD_LEVEL, FALSE, FALSE, new LLUUID( mID ),
src_callback_list, paused );
}
@@ -7167,14 +7273,16 @@ void LLVOAvatar::processAvatarAppearance( LLMessageSystem* mesgsys )
LLMemType mt(LLMemType::MTYPE_AVATAR);
-// llinfos << "processAvatarAppearance start " << mID << llendl;
BOOL is_first_appearance_message = !mFirstAppearanceMessageReceived;
-
mFirstAppearanceMessageReceived = TRUE;
+ LL_INFOS("Avatar") << avString() << "processAvatarAppearance start " << mID
+ << " first? " << is_first_appearance_message << " self? " << isSelf() << LL_ENDL;
+
+
if( isSelf() )
{
- llwarns << "Received AvatarAppearance for self" << llendl;
+ llwarns << avString() << "Received AvatarAppearance for self" << llendl;
if( mFirstTEMessageReceived )
{
// llinfos << "processAvatarAppearance end " << mID << llendl;
@@ -7202,7 +7310,10 @@ void LLVOAvatar::processAvatarAppearance( LLMessageSystem* mesgsys )
}
- if( !is_first_appearance_message )
+ // runway - was
+ // if (!is_first_appearance_message )
+ // which means it would be called on second appearance message - probably wrong.
+ if (is_first_appearance_message )
{
onFirstTEMessageReceived();
}
@@ -7223,6 +7334,7 @@ void LLVOAvatar::processAvatarAppearance( LLMessageSystem* mesgsys )
bool drop_visual_params_debug = gSavedSettings.getBOOL("BlockSomeAvatarAppearanceVisualParams") && (ll_rand(2) == 0); // pretend that ~12% of AvatarAppearance messages arrived without a VisualParam block, for testing
if( num_blocks > 1 && !drop_visual_params_debug)
{
+ LL_DEBUGS("Avatar") << avString() << " handle visual params, num_blocks " << num_blocks << LL_ENDL;
BOOL params_changed = FALSE;
BOOL interp_params = FALSE;
@@ -7295,6 +7407,7 @@ void LLVOAvatar::processAvatarAppearance( LLMessageSystem* mesgsys )
else
{
// AvatarAppearance message arrived without visual params
+ LL_DEBUGS("Avatar") << avString() << "no visual params" << LL_ENDL;
if (drop_visual_params_debug)
{
llinfos << "Debug-faked lack of parameters on AvatarAppearance for object: " << getID() << llendl;
@@ -7447,8 +7560,15 @@ void LLVOAvatar::onBakedTextureMasksLoaded( BOOL success, LLViewerFetchedTexture
// static
void LLVOAvatar::onInitialBakedTextureLoaded( BOOL success, LLViewerFetchedTexture *src_vi, LLImageRaw* src, LLImageRaw* aux_src, S32 discard_level, BOOL final, void* userdata )
{
+
+
LLUUID *avatar_idp = (LLUUID *)userdata;
LLVOAvatar *selfp = (LLVOAvatar *)gObjectList.findObject(*avatar_idp);
+
+ if (selfp)
+ {
+ LL_DEBUGS("Avatar") << selfp->avString() << "discard_level " << discard_level << " success " << success << " final " << final << LL_ENDL;
+ }
if (!success && selfp)
{
@@ -7460,13 +7580,20 @@ void LLVOAvatar::onInitialBakedTextureLoaded( BOOL success, LLViewerFetchedTextu
}
}
-void LLVOAvatar::onBakedTextureLoaded(BOOL success, LLViewerFetchedTexture *src_vi, LLImageRaw* src, LLImageRaw* aux_src, S32 discard_level, BOOL final, void* userdata)
+// Static
+void LLVOAvatar::onBakedTextureLoaded(BOOL success,
+ LLViewerFetchedTexture *src_vi, LLImageRaw* src, LLImageRaw* aux_src,
+ S32 discard_level, BOOL final, void* userdata)
{
//llinfos << "onBakedTextureLoaded: " << src_vi->getID() << llendl;
LLUUID id = src_vi->getID();
LLUUID *avatar_idp = (LLUUID *)userdata;
LLVOAvatar *selfp = (LLVOAvatar *)gObjectList.findObject(*avatar_idp);
+ if (selfp)
+ {
+ LL_DEBUGS("Avatar") << selfp->avString() << "discard_level " << discard_level << " success " << success << " final " << final << " id " << src_vi->getID() << LL_ENDL;
+ }
if (selfp && !success)
{
@@ -7488,6 +7615,8 @@ void LLVOAvatar::onBakedTextureLoaded(BOOL success, LLViewerFetchedTexture *src_
// Called when baked texture is loaded and also when we start up with a baked texture
void LLVOAvatar::useBakedTexture( const LLUUID& id )
{
+
+
/* if(id == head_baked->getID())
mHeadBakedLoaded = TRUE;
mLastHeadBakedID = id;
@@ -7498,6 +7627,7 @@ void LLVOAvatar::useBakedTexture( const LLUUID& id )
LLViewerTexture* image_baked = getImage( mBakedTextureDatas[i].mTextureIndex, 0 );
if (id == image_baked->getID())
{
+ LL_DEBUGS("Avatar") << avString() << " i " << i << " id " << id << LL_ENDL;
mBakedTextureDatas[i].mIsLoaded = true;
mBakedTextureDatas[i].mLastTextureIndex = id;
mBakedTextureDatas[i].mIsUsed = true;
@@ -7672,6 +7802,9 @@ void LLVOAvatar::cullAvatarsByPixelArea()
}
}
+ // runway - this doesn't detect gray/grey state.
+ // think we just need to be checking self av since it's the only
+ // one with lltexlayer stuff.
S32 grey_avatars = 0;
if (LLVOAvatar::areAllNearbyInstancesBaked(grey_avatars))
{
@@ -8475,7 +8608,9 @@ void LLVOAvatar::idleUpdateRenderCost()
}
}
- setDebugText(llformat("%d", cost));
+
+ std::string viz_string = LLVOAvatar::rezStatusToString(getRezzedStatus());
+ setDebugText(llformat("%s %d", viz_string.c_str(), cost));
mVisualComplexity = cost;
F32 green = 1.f-llclamp(((F32) cost-(F32)ARC_LIMIT)/(F32)ARC_LIMIT, 0.f, 1.f);
F32 red = llmin((F32) cost/(F32)ARC_LIMIT, 1.f);
diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h
index 6a4e09593c..6fb56a4c0b 100644
--- a/indra/newview/llvoavatar.h
+++ b/indra/newview/llvoavatar.h
@@ -48,6 +48,7 @@
#include "lltexglobalcolor.h"
#include "lldriverparam.h"
#include "material_codes.h" // LL_MCODE_END
+#include "llviewerstats.h"
extern const LLUUID ANIM_AGENT_BODY_NOISE;
extern const LLUUID ANIM_AGENT_BREATHE_ROT;
@@ -277,14 +278,27 @@ public:
public:
BOOL isFullyLoaded() const;
bool isTooComplex() const;
- bool visualParamWeightsAreDefault();
+ bool visualParamWeightsAreDefault();
+ virtual BOOL getIsCloud() const;
+ BOOL isFullyTextured() const;
+ BOOL hasGray() const;
+ S32 getRezzedStatus() const; // 0 = cloud, 1 = gray, 2 = fully textured.
+ void updateRezzedStatusTimers();
+
+ S32 mLastRezzedStatus;
+
+ LLViewerStats::PhaseMap& getPhases()
+ {
+ return mPhases;
+ }
+
protected:
- virtual BOOL getIsCloud();
BOOL updateIsFullyLoaded();
BOOL processFullyLoadedChange(bool loading);
void updateRuthTimer(bool loading);
F32 calcMorphAmount();
private:
+ BOOL mFirstFullyVisible;
BOOL mFullyLoaded;
BOOL mPreviousFullyLoaded;
BOOL mFullyLoadedInitialized;
@@ -292,6 +306,28 @@ private:
S32 mVisualComplexity;
LLFrameTimer mFullyLoadedTimer;
LLFrameTimer mRuthTimer;
+
+public:
+ class ScopedPhaseSetter
+ {
+ public:
+ ScopedPhaseSetter(LLVOAvatar *avatarp, std::string phase_name):
+ mAvatar(avatarp), mPhaseName(phase_name)
+ {
+ if (mAvatar) { mAvatar->getPhases().startPhase(mPhaseName); }
+ }
+ ~ScopedPhaseSetter()
+ {
+ if (mAvatar) { mAvatar->getPhases().stopPhase(mPhaseName); }
+ }
+ private:
+ std::string mPhaseName;
+ LLVOAvatar* mAvatar;
+ };
+
+private:
+ LLViewerStats::PhaseMap mPhases;
+
protected:
LLFrameTimer mInvisibleTimer;
@@ -518,9 +554,10 @@ public:
virtual BOOL isTextureVisible(LLVOAvatarDefines::ETextureIndex type, U32 index = 0) const;
virtual BOOL isTextureVisible(LLVOAvatarDefines::ETextureIndex type, LLWearable *wearable) const;
-protected:
BOOL isFullyBaked();
static BOOL areAllNearbyInstancesBaked(S32& grey_avatars);
+ static void getNearbyRezzedStats(std::vector<S32>& counts);
+ static std::string rezStatusToString(S32 status);
//--------------------------------------------------------------------
// Baked textures
@@ -882,6 +919,7 @@ private:
public:
std::string getFullname() const; // Returns "FirstName LastName"
+ std::string avString() const; // Frequently used string in log messages "Avatar '<full name'"
protected:
static void getAnimLabels(LLDynamicArray<std::string>* labels);
static void getAnimNames(LLDynamicArray<std::string>* names);
@@ -983,7 +1021,9 @@ private:
// Avatar Rez Metrics
//--------------------------------------------------------------------
public:
+ void debugAvatarRezTime(std::string notification_name, std::string comment = "");
F32 debugGetExistenceTimeElapsedF32() const { return mDebugExistenceTimer.getElapsedTimeF32(); }
+
protected:
LLFrameTimer mRuthDebugTimer; // For tracking how long it takes for av to rez
LLFrameTimer mDebugExistenceTimer; // Debugging for how long the avatar has been in memory.
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index f063653cc5..d2609e5587 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -58,6 +58,8 @@
#include "llappearancemgr.h"
#include "llmeshrepository.h"
#include "llvovolume.h"
+#include "llsdutil.h"
+#include "llstartup.h"
#if LL_MSVC
// disable boost::lexical_cast warning
@@ -75,6 +77,39 @@ BOOL isAgentAvatarValid()
(!gAgentAvatarp->isDead()));
}
+void selfStartPhase(const std::string& phase_name)
+{
+ if (isAgentAvatarValid())
+ {
+ gAgentAvatarp->getPhases().startPhase(phase_name);
+ }
+}
+
+void selfStopPhase(const std::string& phase_name)
+{
+ if (isAgentAvatarValid())
+ {
+ gAgentAvatarp->getPhases().stopPhase(phase_name);
+ }
+}
+
+void selfClearPhases()
+{
+ if (isAgentAvatarValid())
+ {
+ gAgentAvatarp->getPhases().clearPhases();
+ gAgentAvatarp->mLastRezzedStatus = -1;
+ }
+}
+
+void selfStopAllPhases()
+{
+ if (isAgentAvatarValid())
+ {
+ gAgentAvatarp->getPhases().stopAllPhases();
+ }
+}
+
using namespace LLVOAvatarDefines;
/*********************************************************************************
@@ -131,7 +166,8 @@ LLVOAvatarSelf::LLVOAvatarSelf(const LLUUID& id,
LLVOAvatar(id, pcode, regionp),
mScreenp(NULL),
mLastRegionHandle(0),
- mRegionCrossingCount(0)
+ mRegionCrossingCount(0),
+ mInitialBakesLoaded(false)
{
gAgentWearables.setAvatarObject(this);
@@ -164,6 +200,7 @@ void LLVOAvatarSelf::initInstance()
{
mDebugBakedTextureTimes[i][0] = -1.0f;
mDebugBakedTextureTimes[i][1] = -1.0f;
+ mInitialBakeIDs[i] = LLUUID::null;
}
status &= buildMenus();
@@ -762,6 +799,41 @@ void LLVOAvatarSelf::stopMotionFromSource(const LLUUID& source_id)
}
}
+//virtual
+U32 LLVOAvatarSelf::processUpdateMessage(LLMessageSystem *mesgsys,
+ void **user_data,
+ U32 block_num,
+ const EObjectUpdateType update_type,
+ LLDataPacker *dp)
+{
+ U32 retval = LLVOAvatar::processUpdateMessage(mesgsys,user_data,block_num,update_type,dp);
+
+ if (mInitialBakesLoaded == false && retval == 0x0)
+ {
+ // call update textures to force the images to be created
+ updateMeshTextures();
+
+ // unpack the texture UUIDs to the texture slots
+ retval = unpackTEMessage(mesgsys, _PREHASH_ObjectData, block_num);
+
+ // need to trigger a few operations to get the avatar to use the new bakes
+ for (U32 i = 0; i < mBakedTextureDatas.size(); i++)
+ {
+ const LLVOAvatarDefines::ETextureIndex te = mBakedTextureDatas[i].mTextureIndex;
+ LLUUID texture_id = getTEImage(te)->getID();
+ setNewBakedTexture(te, texture_id);
+ mInitialBakeIDs[i] = texture_id;
+ }
+
+ onFirstTEMessageReceived();
+
+ mInitialBakesLoaded = true;
+ }
+
+ return retval;
+}
+
+
void LLVOAvatarSelf::setLocalTextureTE(U8 te, LLViewerTexture* image, U32 index)
{
if (te >= TEX_NUM_INDICES)
@@ -1889,7 +1961,7 @@ void LLVOAvatarSelf::dumpTotalLocalTextureByteCount()
llinfos << "Total Avatar LocTex GL:" << (gl_bytes/1024) << "KB" << llendl;
}
-BOOL LLVOAvatarSelf::getIsCloud()
+BOOL LLVOAvatarSelf::getIsCloud() const
{
// do we have our body parts?
if (gAgentWearables.getWearableCount(LLWearableType::WT_SHAPE) == 0 ||
@@ -2055,6 +2127,80 @@ const std::string LLVOAvatarSelf::debugDumpAllLocalTextureDataInfo() const
return text;
}
+// Dump avatar metrics data.
+LLSD LLVOAvatarSelf::metricsData()
+{
+ // runway - add region info
+ LLSD result;
+ result["id"] = getID();
+ result["rez_status"] = LLVOAvatar::rezStatusToString(getRezzedStatus());
+ result["is_self"] = isSelf();
+ std::vector<S32> rez_counts;
+ LLVOAvatar::getNearbyRezzedStats(rez_counts);
+ result["nearby"] = LLSD::emptyMap();
+ for (S32 i=0; i<rez_counts.size(); ++i)
+ {
+ std::string rez_status_name = LLVOAvatar::rezStatusToString(i);
+ result["nearby"][rez_status_name] = rez_counts[i];
+ }
+ result["timers"]["debug_existence"] = mDebugExistenceTimer.getElapsedTimeF32();
+ result["timers"]["ruth_debug"] = mRuthDebugTimer.getElapsedTimeF32();
+ result["timers"]["ruth"] = mRuthTimer.getElapsedTimeF32();
+ result["timers"]["invisible"] = mInvisibleTimer.getElapsedTimeF32();
+ result["timers"]["fully_loaded"] = mFullyLoadedTimer.getElapsedTimeF32();
+ result["phases"] = getPhases().dumpPhases();
+ result["startup"] = LLStartUp::getPhases().dumpPhases();
+
+ return result;
+}
+
+class ViewerAppearanceChangeMetricsResponder: public LLCurl::Responder
+{
+public:
+ ViewerAppearanceChangeMetricsResponder()
+ {
+ }
+
+ virtual void completed(U32 status,
+ const std::string& reason,
+ const LLSD& content)
+ {
+ if (isGoodStatus(status))
+ {
+ LL_DEBUGS("Avatar") << "OK" << LL_ENDL;
+ result(content);
+ }
+ else
+ {
+ LL_WARNS("Avatar") << "Failed " << status << " reason " << reason << LL_ENDL;
+ error(status,reason);
+ }
+ }
+};
+
+void LLVOAvatarSelf::sendAppearanceChangeMetrics()
+{
+ // gAgentAvatarp->stopAllPhases();
+
+ LLSD msg = metricsData();
+ msg["message"] = "ViewerAppearanceChangeMetrics";
+
+ LL_DEBUGS("Avatar") << avString() << "message: " << ll_pretty_print_sd(msg) << LL_ENDL;
+ std::string caps_url;
+ if (getRegion())
+ {
+ // runway - change here to activate.
+ caps_url = getRegion()->getCapability("ViewerMetrics");
+ }
+ if (!caps_url.empty())
+ {
+ LLCurlRequest::headers_t headers;
+ LLHTTPClient::post(caps_url,
+ msg,
+ new ViewerAppearanceChangeMetricsResponder);
+ }
+}
+
const LLUUID& LLVOAvatarSelf::grabBakedTexture(EBakedTextureIndex baked_index) const
{
if (canGrabBakedTexture(baked_index))
@@ -2253,11 +2399,25 @@ void LLVOAvatarSelf::setNewBakedTexture( ETextureIndex te, const LLUUID& uuid )
if (isAllLocalTextureDataFinal())
{
LLNotificationsUtil::add("AvatarRezSelfBakedDoneNotification",args);
+ LL_DEBUGS("Avatar") << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32()
+ << "sec ]"
+ << avString()
+ << "RuthTimer " << (U32)mRuthDebugTimer.getElapsedTimeF32()
+ << " SelfLoadTimer " << (U32)mDebugSelfLoadTimer.getElapsedTimeF32()
+ << " Notification " << "AvatarRezSelfBakedDoneNotification"
+ << llendl;
}
else
{
args["STATUS"] = debugDumpAllLocalTextureDataInfo();
LLNotificationsUtil::add("AvatarRezSelfBakedUpdateNotification",args);
+ LL_DEBUGS("Avatar") << "REZTIME: [ " << (U32)mDebugExistenceTimer.getElapsedTimeF32()
+ << "sec ]"
+ << avString()
+ << "RuthTimer " << (U32)mRuthDebugTimer.getElapsedTimeF32()
+ << " SelfLoadTimer " << (U32)mDebugSelfLoadTimer.getElapsedTimeF32()
+ << " Notification " << "AvatarRezSelfBakedUpdateNotification"
+ << llendl;
}
}
@@ -2265,7 +2425,7 @@ void LLVOAvatarSelf::setNewBakedTexture( ETextureIndex te, const LLUUID& uuid )
}
}
-// FIXME: This is never called. Something may be broken.
+// FIXME: This is not called consistently. Something may be broken.
void LLVOAvatarSelf::outputRezDiagnostics() const
{
if(!gSavedSettings.getBOOL("DebugAvatarLocalTexLoadedTime"))
@@ -2274,11 +2434,11 @@ void LLVOAvatarSelf::outputRezDiagnostics() const
}
const F32 final_time = mDebugSelfLoadTimer.getElapsedTimeF32();
- llinfos << "REZTIME: Myself rez stats:" << llendl;
- llinfos << "\t Time from avatar creation to load wearables: " << (S32)mDebugTimeWearablesLoaded << llendl;
- llinfos << "\t Time from avatar creation to de-cloud: " << (S32)mDebugTimeAvatarVisible << llendl;
- llinfos << "\t Time from avatar creation to de-cloud for others: " << (S32)final_time << llendl;
- llinfos << "\t Load time for each texture: " << llendl;
+ LL_DEBUGS("Avatar") << "REZTIME: Myself rez stats:" << llendl;
+ LL_DEBUGS("Avatar") << "\t Time from avatar creation to load wearables: " << (S32)mDebugTimeWearablesLoaded << llendl;
+ LL_DEBUGS("Avatar") << "\t Time from avatar creation to de-cloud: " << (S32)mDebugTimeAvatarVisible << llendl;
+ LL_DEBUGS("Avatar") << "\t Time from avatar creation to de-cloud for others: " << (S32)final_time << llendl;
+ LL_DEBUGS("Avatar") << "\t Load time for each texture: " << llendl;
for (U32 i = 0; i < LLVOAvatarDefines::TEX_NUM_INDICES; ++i)
{
std::stringstream out;
@@ -2302,12 +2462,14 @@ void LLVOAvatarSelf::outputRezDiagnostics() const
// Don't print out non-existent textures.
if (j != 0)
- llinfos << out.str() << llendl;
+ {
+ LL_DEBUGS("Avatar") << out.str() << LL_ENDL;
+ }
}
- llinfos << "\t Time points for each upload (start / finish)" << llendl;
+ LL_DEBUGS("Avatar") << "\t Time points for each upload (start / finish)" << llendl;
for (U32 i = 0; i < LLVOAvatarDefines::BAKED_NUM_INDICES; ++i)
{
- llinfos << "\t\t (" << i << ") \t" << (S32)mDebugBakedTextureTimes[i][0] << " / " << (S32)mDebugBakedTextureTimes[i][1] << llendl;
+ LL_DEBUGS("Avatar") << "\t\t (" << i << ") \t" << (S32)mDebugBakedTextureTimes[i][0] << " / " << (S32)mDebugBakedTextureTimes[i][1] << llendl;
}
for (LLVOAvatarDefines::LLVOAvatarDictionary::BakedTextures::const_iterator baked_iter = LLVOAvatarDefines::LLVOAvatarDictionary::getInstance()->getBakedTextures().begin();
@@ -2319,15 +2481,16 @@ void LLVOAvatarSelf::outputRezDiagnostics() const
if (!layerset) continue;
const LLTexLayerSetBuffer *layerset_buffer = layerset->getComposite();
if (!layerset_buffer) continue;
- llinfos << layerset_buffer->dumpTextureInfo() << llendl;
+ LL_DEBUGS("Avatar") << layerset_buffer->dumpTextureInfo() << llendl;
}
}
void LLVOAvatarSelf::outputRezTiming(const std::string& msg) const
{
- LL_DEBUGS("Avatar Rez")
+ LL_INFOS("Avatar")
+ << avString()
<< llformat("%s. Time from avatar creation: %.2f", msg.c_str(), mDebugSelfLoadTimer.getElapsedTimeF32())
- << llendl;
+ << LL_ENDL;
}
void LLVOAvatarSelf::reportAvatarRezTime() const
@@ -2351,6 +2514,18 @@ void LLVOAvatarSelf::setCachedBakedTexture( ETextureIndex te, const LLUUID& uuid
{
if ( mBakedTextureDatas[i].mTextureIndex == te && mBakedTextureDatas[i].mTexLayerSet)
{
+ if (mInitialBakeIDs[i] != LLUUID::null)
+ {
+ if (mInitialBakeIDs[i] == uuid)
+ {
+ llinfos << "baked texture correctly loaded at login! " << i << llendl;
+ }
+ else
+ {
+ llwarns << "baked texture does not match id loaded at login!" << i << llendl;
+ }
+ mInitialBakeIDs[i] = LLUUID::null;
+ }
mBakedTextureDatas[i].mTexLayerSet->cancelUpload();
}
}
@@ -2478,6 +2653,20 @@ LLTexLayerSet* LLVOAvatarSelf::getLayerSet(ETextureIndex index) const
return NULL;
}
+LLTexLayerSet* LLVOAvatarSelf::getLayerSet(EBakedTextureIndex baked_index) const
+{
+ /* switch(index)
+ case TEX_HEAD_BAKED:
+ case TEX_HEAD_BODYPAINT:
+ return mHeadLayerSet; */
+ if (baked_index >= 0 && baked_index < BAKED_NUM_INDICES)
+ {
+ return mBakedTextureDatas[baked_index].mTexLayerSet;
+ }
+ return NULL;
+}
+
+
// static
void LLVOAvatarSelf::onCustomizeStart()
{
@@ -2558,49 +2747,6 @@ BOOL LLVOAvatarSelf::needsRenderBeam()
// static
void LLVOAvatarSelf::deleteScratchTextures()
{
- if(gAuditTexture)
- {
- S32 total_tex_size = sScratchTexBytes ;
- S32 tex_size = SCRATCH_TEX_WIDTH * SCRATCH_TEX_HEIGHT ;
-
- if( sScratchTexNames.checkData( GL_LUMINANCE ) )
- {
- LLImageGL::decTextureCounter(tex_size, 1, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= tex_size ;
- }
- if( sScratchTexNames.checkData( GL_ALPHA ) )
- {
- LLImageGL::decTextureCounter(tex_size, 1, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= tex_size ;
- }
- if( sScratchTexNames.checkData( GL_COLOR_INDEX ) )
- {
- LLImageGL::decTextureCounter(tex_size, 1, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= tex_size ;
- }
- if( sScratchTexNames.checkData( LLRender::sGLCoreProfile ? GL_RG : GL_LUMINANCE_ALPHA ) )
- {
- LLImageGL::decTextureCounter(tex_size, 2, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= 2 * tex_size ;
- }
- if( sScratchTexNames.checkData( GL_RGB ) )
- {
- LLImageGL::decTextureCounter(tex_size, 3, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= 3 * tex_size ;
- }
- if( sScratchTexNames.checkData( GL_RGBA ) )
- {
- LLImageGL::decTextureCounter(tex_size, 4, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= 4 * tex_size ;
- }
- //others
- while(total_tex_size > 0)
- {
- LLImageGL::decTextureCounter(tex_size, 4, LLViewerTexture::AVATAR_SCRATCH_TEX) ;
- total_tex_size -= 4 * tex_size ;
- }
- }
-
for( LLGLuint* namep = sScratchTexNames.getFirstData();
namep;
namep = sScratchTexNames.getNextData() )
diff --git a/indra/newview/llvoavatarself.h b/indra/newview/llvoavatarself.h
index 655fb3a012..543891ca63 100644
--- a/indra/newview/llvoavatarself.h
+++ b/indra/newview/llvoavatarself.h
@@ -93,15 +93,27 @@ public:
/*virtual*/ void updateVisualParams();
/*virtual*/ void idleUpdateAppearanceAnimation();
+ /*virtual*/ U32 processUpdateMessage(LLMessageSystem *mesgsys,
+ void **user_data,
+ U32 block_num,
+ const EObjectUpdateType update_type,
+ LLDataPacker *dp);
+
private:
// helper function. Passed in param is assumed to be in avatar's parameter list.
BOOL setParamWeight(LLViewerVisualParam *param, F32 weight, BOOL upload_bake = FALSE );
+
/** Initialization
** **
*******************************************************************************/
+private:
+ LLUUID mInitialBakeIDs[6];
+ bool mInitialBakesLoaded;
+
+
/********************************************************************************
** **
** STATE
@@ -121,7 +133,7 @@ public:
// Loading state
//--------------------------------------------------------------------
public:
- /*virtual*/ BOOL getIsCloud();
+ /*virtual*/ BOOL getIsCloud() const;
//--------------------------------------------------------------------
// Region state
@@ -229,6 +241,7 @@ public:
void requestLayerSetUpload(LLVOAvatarDefines::EBakedTextureIndex i);
void requestLayerSetUpdate(LLVOAvatarDefines::ETextureIndex i);
LLTexLayerSet* getLayerSet(LLVOAvatarDefines::ETextureIndex index) const;
+ LLTexLayerSet* getLayerSet(LLVOAvatarDefines::EBakedTextureIndex baked_index) const;
//--------------------------------------------------------------------
// Composites
@@ -369,6 +382,8 @@ public:
const LLTexLayerSet* debugGetLayerSet(LLVOAvatarDefines::EBakedTextureIndex index) const { return mBakedTextureDatas[index].mTexLayerSet; }
const std::string debugDumpLocalTextureDataInfo(const LLTexLayerSet* layerset) const; // Lists out state of this particular baked texture layer
const std::string debugDumpAllLocalTextureDataInfo() const; // Lists out which baked textures are at highest LOD
+ LLSD metricsData();
+ void sendAppearanceChangeMetrics(); // send data associated with completing a change.
private:
LLFrameTimer mDebugSelfLoadTimer;
F32 mDebugTimeWearablesLoaded;
@@ -387,4 +402,9 @@ extern LLPointer<LLVOAvatarSelf> gAgentAvatarp;
BOOL isAgentAvatarValid();
+void selfStartPhase(const std::string& phase_name);
+void selfStopPhase(const std::string& phase_name);
+void selfStopAllPhases();
+void selfClearPhases();
+
#endif // LL_VO_AVATARSELF_H
diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp
index df1d3f2955..820d1d73e1 100644
--- a/indra/newview/llvoicevivox.cpp
+++ b/indra/newview/llvoicevivox.cpp
@@ -27,8 +27,6 @@
#include "llviewerprecompiledheaders.h"
#include "llvoicevivox.h"
-#include <boost/tokenizer.hpp>
-
#include "llsdutil.h"
// Linden library includes
@@ -47,6 +45,7 @@
#include "llbase64.h"
#include "llviewercontrol.h"
#include "llappviewer.h" // for gDisconnected, gDisableVoice
+#include "llprocess.h"
// Viewer includes
#include "llmutelist.h" // to check for muted avatars
@@ -242,59 +241,21 @@ void LLVivoxVoiceClientCapResponder::result(const LLSD& content)
}
}
-
-
-#if LL_WINDOWS
-static HANDLE sGatewayHandle = 0;
+static LLProcessPtr sGatewayPtr;
static bool isGatewayRunning()
{
- bool result = false;
- if(sGatewayHandle != 0)
- {
- DWORD waitresult = WaitForSingleObject(sGatewayHandle, 0);
- if(waitresult != WAIT_OBJECT_0)
- {
- result = true;
- }
- }
- return result;
-}
-static void killGateway()
-{
- if(sGatewayHandle != 0)
- {
- TerminateProcess(sGatewayHandle,0);
- }
-}
-
-#else // Mac and linux
-
-static pid_t sGatewayPID = 0;
-static bool isGatewayRunning()
-{
- bool result = false;
- if(sGatewayPID != 0)
- {
- // A kill with signal number 0 has no effect, just does error checking. It should return an error if the process no longer exists.
- if(kill(sGatewayPID, 0) == 0)
- {
- result = true;
- }
- }
- return result;
+ return sGatewayPtr && sGatewayPtr->isRunning();
}
static void killGateway()
{
- if(sGatewayPID != 0)
+ if (sGatewayPtr)
{
- kill(sGatewayPID, SIGTERM);
+ sGatewayPtr->kill();
}
}
-#endif
-
///////////////////////////////////////////////////////////////////////////////////////////////
LLVivoxVoiceClient::LLVivoxVoiceClient() :
@@ -790,7 +751,7 @@ void LLVivoxVoiceClient::stateMachine()
}
else if(!isGatewayRunning())
{
- if(true)
+ if (true) // production build, not test
{
// Launch the voice daemon
@@ -809,102 +770,33 @@ void LLVivoxVoiceClient::stateMachine()
#endif
// See if the vivox executable exists
llstat s;
- if(!LLFile::stat(exe_path, &s))
+ if (!LLFile::stat(exe_path, &s))
{
// vivox executable exists. Build the command line and launch the daemon.
+ LLProcess::Params params;
+ params.executable = exe_path;
// SLIM SDK: these arguments are no longer necessary.
// std::string args = " -p tcp -h -c";
- std::string args;
- std::string cmd;
std::string loglevel = gSavedSettings.getString("VivoxDebugLevel");
-
if(loglevel.empty())
{
loglevel = "-1"; // turn logging off completely
}
-
- args += " -ll ";
- args += loglevel;
-
- LL_DEBUGS("Voice") << "Args for SLVoice: " << args << LL_ENDL;
-
-#if LL_WINDOWS
- PROCESS_INFORMATION pinfo;
- STARTUPINFOA sinfo;
-
- memset(&sinfo, 0, sizeof(sinfo));
-
- std::string exe_dir = gDirUtilp->getAppRODataDir();
- cmd = "SLVoice.exe";
- cmd += args;
-
- // So retarded. Windows requires that the second parameter to CreateProcessA be writable (non-const) string...
- char *args2 = new char[args.size() + 1];
- strcpy(args2, args.c_str());
- if(!CreateProcessA(exe_path.c_str(), args2, NULL, NULL, FALSE, 0, NULL, exe_dir.c_str(), &sinfo, &pinfo))
- {
-// DWORD dwErr = GetLastError();
- }
- else
- {
- // foo = pinfo.dwProcessId; // get your pid here if you want to use it later on
- // CloseHandle(pinfo.hProcess); // stops leaks - nothing else
- sGatewayHandle = pinfo.hProcess;
- CloseHandle(pinfo.hThread); // stops leaks - nothing else
- }
-
- delete[] args2;
-#else // LL_WINDOWS
- // This should be the same for mac and linux
- {
- std::vector<std::string> arglist;
- arglist.push_back(exe_path);
-
- // Split the argument string into separate strings for each argument
- typedef boost::tokenizer<boost::char_separator<char> > tokenizer;
- boost::char_separator<char> sep(" ");
- tokenizer tokens(args, sep);
- tokenizer::iterator token_iter;
- for(token_iter = tokens.begin(); token_iter != tokens.end(); ++token_iter)
- {
- arglist.push_back(*token_iter);
- }
-
- // create an argv vector for the child process
- char **fakeargv = new char*[arglist.size() + 1];
- int i;
- for(i=0; i < arglist.size(); i++)
- fakeargv[i] = const_cast<char*>(arglist[i].c_str());
+ params.args.add("-ll");
+ params.args.add(loglevel);
+ params.cwd = gDirUtilp->getAppRODataDir();
+ sGatewayPtr = LLProcess::create(params);
- fakeargv[i] = NULL;
-
- fflush(NULL); // flush all buffers before the child inherits them
- pid_t id = vfork();
- if(id == 0)
- {
- // child
- execv(exe_path.c_str(), fakeargv);
-
- // If we reach this point, the exec failed.
- // Use _exit() instead of exit() per the vfork man page.
- _exit(0);
- }
-
- // parent
- delete[] fakeargv;
- sGatewayPID = id;
- }
-#endif // LL_WINDOWS
mDaemonHost = LLHost(gSavedSettings.getString("VivoxVoiceHost").c_str(), gSavedSettings.getU32("VivoxVoicePort"));
- }
+ }
else
{
LL_INFOS("Voice") << exe_path << " not found." << LL_ENDL;
- }
+ }
}
else
- {
+ {
// SLIM SDK: port changed from 44124 to 44125.
// We can connect to a client gateway running on another host. This is useful for testing.
// To do this, launch the gateway on a nearby host like this:
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index e7c35d8220..080d1f774a 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -4123,6 +4123,9 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
group->mGeometryBytes = 0;
group->mSurfaceArea = 0;
+ //cache object box size since it might be used for determining visibility
+ group->mObjectBoxSize = group->mObjectBounds[1].getLength3().getF32();
+
group->clearDrawMap();
mFaceList.clear();
diff --git a/indra/newview/llworld.cpp b/indra/newview/llworld.cpp
index 3d971e738e..b061c90d98 100644
--- a/indra/newview/llworld.cpp
+++ b/indra/newview/llworld.cpp
@@ -839,7 +839,6 @@ void LLWorld::updateWaterObjects()
// Now, get a list of the holes
S32 x, y;
- F32 water_height = gAgent.getRegion()->getWaterHeight() + 256.f;
for (x = min_x; x <= max_x; x += rwidth)
{
for (y = min_y; y <= max_y; y += rwidth)
@@ -851,7 +850,7 @@ void LLWorld::updateWaterObjects()
waterp->setUseTexture(FALSE);
waterp->setPositionGlobal(LLVector3d(x + rwidth/2,
y + rwidth/2,
- water_height));
+ 256.f+DEFAULT_WATER_HEIGHT));
waterp->setScale(LLVector3((F32)rwidth, (F32)rwidth, 512.f));
gPipeline.createObject(waterp);
mHoleWaterObjects.push_back(waterp);
@@ -908,7 +907,7 @@ void LLWorld::updateWaterObjects()
}
waterp->setRegion(gAgent.getRegion());
- LLVector3d water_pos(water_center_x, water_center_y, water_height) ;
+ LLVector3d water_pos(water_center_x, water_center_y, 256.f+DEFAULT_WATER_HEIGHT) ;
LLVector3 water_scale((F32) dim[0], (F32) dim[1], 512.f);
//stretch out to horizon
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index ab994c71cb..ed636a40b2 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -187,6 +187,7 @@ F32 LLPipeline::RenderShadowFOVCutoff;
BOOL LLPipeline::CameraOffset;
F32 LLPipeline::CameraMaxCoF;
F32 LLPipeline::CameraDoFResScale;
+F32 LLPipeline::RenderAutoHideSurfaceAreaLimit;
const F32 BACKLIGHT_DAY_MAGNITUDE_AVATAR = 0.2f;
const F32 BACKLIGHT_NIGHT_MAGNITUDE_AVATAR = 0.1f;
@@ -592,6 +593,7 @@ void LLPipeline::init()
gSavedSettings.getControl("CameraOffset")->getCommitSignal()->connect(boost::bind(&LLPipeline::refreshCachedSettings));
gSavedSettings.getControl("CameraMaxCoF")->getCommitSignal()->connect(boost::bind(&LLPipeline::refreshCachedSettings));
gSavedSettings.getControl("CameraDoFResScale")->getCommitSignal()->connect(boost::bind(&LLPipeline::refreshCachedSettings));
+ gSavedSettings.getControl("RenderAutoHideSurfaceAreaLimit")->getCommitSignal()->connect(boost::bind(&LLPipeline::refreshCachedSettings));
}
LLPipeline::~LLPipeline()
@@ -846,9 +848,10 @@ bool LLPipeline::allocateScreenBuffer(U32 resX, U32 resY, U32 samples)
if (shadow_detail > 0)
{ //allocate 4 sun shadow maps
+ U32 sun_shadow_map_width = ((U32(resX*scale)+1)&~1); // must be even to avoid a stripe in the horizontal shadow blur
for (U32 i = 0; i < 4; i++)
{
- if (!mShadow[i].allocate(U32(resX*scale),U32(resY*scale), 0, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE)) return false;
+ if (!mShadow[i].allocate(sun_shadow_map_width,U32(resY*scale), 0, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE)) return false;
}
}
else
@@ -864,9 +867,10 @@ bool LLPipeline::allocateScreenBuffer(U32 resX, U32 resY, U32 samples)
if (shadow_detail > 1)
{ //allocate two spot shadow maps
+ U32 spot_shadow_map_width = width;
for (U32 i = 4; i < 6; i++)
{
- if (!mShadow[i].allocate(width, height, 0, TRUE, FALSE)) return false;
+ if (!mShadow[i].allocate(spot_shadow_map_width, height, 0, TRUE, FALSE)) return false;
}
}
else
@@ -1015,6 +1019,7 @@ void LLPipeline::refreshCachedSettings()
CameraOffset = gSavedSettings.getBOOL("CameraOffset");
CameraMaxCoF = gSavedSettings.getF32("CameraMaxCoF");
CameraDoFResScale = gSavedSettings.getF32("CameraDoFResScale");
+ RenderAutoHideSurfaceAreaLimit = gSavedSettings.getF32("RenderAutoHideSurfaceAreaLimit");
updateRenderDeferred();
}
@@ -1136,7 +1141,7 @@ void LLPipeline::createGLBuffers()
LLImageGL::generateTextures(1, &mNoiseMap);
gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mNoiseMap);
- LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_RGB16F_ARB, noiseRes, noiseRes, GL_RGB, GL_FLOAT, noise);
+ LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_RGB16F_ARB, noiseRes, noiseRes, GL_RGB, GL_FLOAT, noise, false);
gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
}
@@ -1151,7 +1156,7 @@ void LLPipeline::createGLBuffers()
LLImageGL::generateTextures(1, &mTrueNoiseMap);
gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mTrueNoiseMap);
- LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_RGB16F_ARB, noiseRes, noiseRes, GL_RGB,GL_FLOAT, noise);
+ LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_RGB16F_ARB, noiseRes, noiseRes, GL_RGB,GL_FLOAT, noise, false);
gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
}
@@ -1207,7 +1212,7 @@ void LLPipeline::createLUTBuffers()
LLImageGL::generateTextures(1, &mLightFunc);
gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mLightFunc);
- LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_R8, lightResX, lightResY, GL_RED, GL_UNSIGNED_BYTE, ls);
+ LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_R8, lightResX, lightResY, GL_RED, GL_UNSIGNED_BYTE, ls, false);
gGL.getTexUnit(0)->setTextureAddressMode(LLTexUnit::TAM_CLAMP);
gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR);
@@ -3365,7 +3370,9 @@ void LLPipeline::postSort(LLCamera& camera)
{
LLSpatialGroup* group = *i;
if (sUseOcclusion &&
- group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ group->isOcclusionState(LLSpatialGroup::OCCLUDED) ||
+ (RenderAutoHideSurfaceAreaLimit > 0.f &&
+ group->mSurfaceArea > RenderAutoHideSurfaceAreaLimit*llmax(group->mObjectBoxSize, 10.f)))
{
continue;
}
@@ -8293,7 +8300,7 @@ static LLFastTimer::DeclareTimer FTM_SHADOW_RENDER("Render Shadows");
static LLFastTimer::DeclareTimer FTM_SHADOW_ALPHA("Alpha Shadow");
static LLFastTimer::DeclareTimer FTM_SHADOW_SIMPLE("Simple Shadow");
-void LLPipeline::renderShadow(glh::matrix4f& view, glh::matrix4f& proj, LLCamera& shadow_cam, LLCullResult &result, BOOL use_shader, BOOL use_occlusion)
+void LLPipeline::renderShadow(glh::matrix4f& view, glh::matrix4f& proj, LLCamera& shadow_cam, LLCullResult &result, BOOL use_shader, BOOL use_occlusion, U32 target_width)
{
LLFastTimer t(FTM_SHADOW_RENDER);
@@ -8384,7 +8391,8 @@ void LLPipeline::renderShadow(glh::matrix4f& view, glh::matrix4f& proj, LLCamera
LLFastTimer ftm(FTM_SHADOW_ALPHA);
gDeferredShadowAlphaMaskProgram.bind();
gDeferredShadowAlphaMaskProgram.setMinimumAlpha(0.598f);
-
+ gDeferredShadowAlphaMaskProgram.uniform1f(LLShaderMgr::DEFERRED_SHADOW_TARGET_WIDTH, (float)target_width);
+
U32 mask = LLVertexBuffer::MAP_VERTEX |
LLVertexBuffer::MAP_TEXCOORD0 |
LLVertexBuffer::MAP_COLOR |
@@ -9237,11 +9245,13 @@ void LLPipeline::generateSunShadow(LLCamera& camera)
mShadow[j].getViewport(gGLViewport);
mShadow[j].clear();
+ U32 target_width = mShadow[j].getWidth();
+
{
static LLCullResult result[4];
//LLGLEnable enable(GL_DEPTH_CLAMP_NV);
- renderShadow(view[j], proj[j], shadow_cam, result[j], TRUE);
+ renderShadow(view[j], proj[j], shadow_cam, result[j], TRUE, TRUE, target_width);
}
mShadow[j].flush();
@@ -9380,11 +9390,13 @@ void LLPipeline::generateSunShadow(LLCamera& camera)
mShadow[i+4].getViewport(gGLViewport);
mShadow[i+4].clear();
+ U32 target_width = mShadow[i+4].getWidth();
+
static LLCullResult result[2];
LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW0+i+4;
- renderShadow(view[i+4], proj[i+4], shadow_cam, result[i], FALSE, FALSE);
+ renderShadow(view[i+4], proj[i+4], shadow_cam, result[i], FALSE, FALSE, target_width);
mShadow[i+4].flush();
}
diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h
index b8b4f164fe..5c623fc9f2 100644
--- a/indra/newview/pipeline.h
+++ b/indra/newview/pipeline.h
@@ -264,7 +264,7 @@ public:
void setHighlightObject(LLDrawable* obj) { mHighlightObject = obj; }
- void renderShadow(glh::matrix4f& view, glh::matrix4f& proj, LLCamera& camera, LLCullResult& result, BOOL use_shader = TRUE, BOOL use_occlusion = TRUE);
+ void renderShadow(glh::matrix4f& view, glh::matrix4f& proj, LLCamera& camera, LLCullResult& result, BOOL use_shader, BOOL use_occlusion, U32 target_width);
void renderHighlights();
void renderDebug();
void renderPhysicsDisplay();
@@ -464,6 +464,7 @@ public:
RENDER_DEBUG_LOD_INFO = 0x04000000,
RENDER_DEBUG_RENDER_COMPLEXITY = 0x08000000,
RENDER_DEBUG_ATTACHMENT_BYTES = 0x10000000,
+ RENDER_DEBUG_TEXEL_DENSITY = 0x20000000
};
public:
@@ -851,6 +852,7 @@ public:
static BOOL CameraOffset;
static F32 CameraMaxCoF;
static F32 CameraDoFResScale;
+ static F32 RenderAutoHideSurfaceAreaLimit;
};
void render_bbox(const LLVector3 &min, const LLVector3 &max);
diff --git a/indra/newview/skins/default/xui/da/floater_model_wizard.xml b/indra/newview/skins/default/xui/da/floater_model_wizard.xml
deleted file mode 100644
index 8ad443581a..0000000000
--- a/indra/newview/skins/default/xui/da/floater_model_wizard.xml
+++ /dev/null
@@ -1,241 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="UPLOAD MODEL WIZARD">
- <button label="5. Upload" name="upload_btn"/>
- <button label="4. Review" name="review_btn"/>
- <button label="3. Physics" name="physics2_btn"/>
- <button label="3. Physics" name="physics_btn"/>
- <button label="2. Optimize" name="optimize_btn"/>
- <button label="1. Choose File" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="header_panel">
- <text name="header_text">
- Upload Model
- </text>
- </panel>
- <text name="description">
- This wizard will help you import mesh models to Second Life. First specify a file containing the model you wish to import. Second Life supports COLLADA (.dae) files.
- </text>
- <panel name="content">
- <text name="Cache location">
- Filename:
- </text>
- <button label="Browse..." label_selected="Browse..." name="browse"/>
- <text name="dimensions">
- X: Y: Z:
- </text>
- <text name="dimension_dividers">
- | |
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="header_panel">
- <text name="header_text">
- Optimize
- </text>
- </panel>
- <text name="description">
- This wizard has optimized your model to improve performance. You may adjust the results of the optimization process bellow or click Next to continue.
- </text>
- <panel name="content">
- <text name="high_detail_text">
- Generate Level of Detail: High
- </text>
- <text name="medium_detail_text">
- Generate Level of Detail: Medium
- </text>
- <text name="low_detail_text">
- Generate Level of Detail: Low
- </text>
- <text name="lowest_detail_text">
- Generate Level of Detail: Lowest
- </text>
- </panel>
- <panel name="content2">
- <text name="lod_label">
- Model Preview:
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="LOD to view in preview render">
- <combo_item name="high">
- High
- </combo_item>
- <combo_item name="medium">
- Medium
- </combo_item>
- <combo_item name="low">
- Low
- </combo_item>
- <combo_item name="lowest">
- Lowest
- </combo_item>
- </combo_box>
- <text name="streaming cost">
- Resource Cost: [COST]
- </text>
- <text name="dimensions">
- X: Y: Z:
- </text>
- <text name="dimension_dividers">
- | |
- </text>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="header_panel">
- <text name="header_text">
- Physics
- </text>
- </panel>
- <text name="description">
- The wizard will create a physical shape, which determines how the object interacts with other objects and avatars. Set the slider to the detail level most appropriate for how your object will be used:
- </text>
- <panel name="content">
- <text name="streaming cost">
- Resource Cost: [COST]
- </text>
- </panel>
- </panel>
- <panel name="physics2_panel">
- <panel name="header_panel">
- <text name="header_text">
- Physics
- </text>
- </panel>
- <text name="description">
- Preview the physics shape below then click Next to continue. To modify the physics shape, click the Back button.
- </text>
- <panel name="content">
- <text name="lod_label">
- Model Preview:
- </text>
- <combo_box name="preview_lod_combo3" tool_tip="LOD to view in preview render">
- <combo_item name="high">
- High
- </combo_item>
- <combo_item name="medium">
- Medium
- </combo_item>
- <combo_item name="low">
- Low
- </combo_item>
- <combo_item name="lowest">
- Lowest
- </combo_item>
- </combo_box>
- <text name="dimensions">
- X: Y: Z:
- </text>
- <text name="dimension_dividers">
- | |
- </text>
- <text name="streaming cost">
- Resource Cost: [COST]
- </text>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="header_panel">
- <text name="header_text">
- Review
- </text>
- </panel>
- <text name="description">
- Review the details below then click. Upload to upload your model. Your L$ balance will be charged when you click Upload.
- </text>
- <panel name="content">
- <text name="lod_label">
- Model Preview:
- </text>
- <combo_box name="preview_lod_combo" tool_tip="LOD to view in preview render">
- <combo_item name="high">
- High
- </combo_item>
- <combo_item name="medium">
- Medium
- </combo_item>
- <combo_item name="low">
- Low
- </combo_item>
- <combo_item name="lowest">
- Lowest
- </combo_item>
- </combo_box>
- <text name="dimensions">
- X: Y: Z:
- </text>
- <text name="dimension_dividers">
- | |
- </text>
- </panel>
- <text name="streaming cost">
- Resource Cost: [COST]
- </text>
- <text name="physics cost">
- Physics Cost: [COST]
- </text>
- </panel>
- <panel name="upload_panel">
- <panel name="header_panel">
- <text name="header_text">
- Upload Complete!
- </text>
- </panel>
- <text name="description">
- Congratulations! Your model has been sucessfully uploaded. You will find the model in the Objects folder in your inventory.
- </text>
- </panel>
- <button label="&lt;&lt; Back" name="back"/>
- <button label="Next &gt;&gt;" name="next"/>
- <button label="Upload" name="upload" tool_tip="Upload to simulator"/>
- <button label="Cancel" name="cancel"/>
- <button label="Close" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Idle
- </string>
- <string name="status_reading_file">
- Loading...
- </string>
- <string name="status_generating_meshes">
- Generating Meshes...
- </string>
- <string name="status_vertex_number_overflow">
- Error: Vertex number is more than 65534, aborted!
- </string>
- <string name="high">
- High
- </string>
- <string name="medium">
- Medium
- </string>
- <string name="low">
- Low
- </string>
- <string name="lowest">
- Lowest
- </string>
- <string name="mesh_status_good">
- Ship it!
- </string>
- <string name="mesh_status_na">
- N/A
- </string>
- <string name="mesh_status_none">
- None
- </string>
- <string name="mesh_status_submesh_mismatch">
- Levels of detail have a different number of textureable faces.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Levels of detail have a different number of mesh instances.
- </string>
- <string name="mesh_status_too_many_vertices">
- Level of detail has too many vertices.
- </string>
- <string name="mesh_status_missing_lod">
- Missing required level of detail.
- </string>
- <string name="layer_all">
- All
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/de/floater_model_wizard.xml b/indra/newview/skins/default/xui/de/floater_model_wizard.xml
deleted file mode 100644
index ee26d51d32..0000000000
--- a/indra/newview/skins/default/xui/de/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="ASSISTENT ZUM HOCHLADEN VON MODELLEN">
- <button label="5. Hochladen" name="upload_btn"/>
- <button label="4. Überprüfen" name="review_btn"/>
- <button label="3. Physik" name="physics_btn"/>
- <button label="2. Optimieren" name="optimize_btn"/>
- <button label="1. Datei auswählen" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Modelldatei auswählen
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Fortgeschrittene Benutzer: Wenn Sie bereits mit Tools zur Erstellung von 3D-Inhalten vertraut sind, können Sie den erweiterten Uploader verwenden.
- </text>
- <button label="Auf Erweitert wechseln" name="switch_to_advanced"/>
- <text name="Cache location">
- Hochzuladende Modelldatei auswählen
- </text>
- <button label="Durchsuchen..." label_selected="Durchsuchen..." name="browse"/>
- <text name="Model types">
- Second Life unterstützt COLLADA-Dateien (.dae).
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- ACHTUNG:
- </text>
- <text name="warning_text">
- Sie können den letzten Schritt nicht abschließen (Modell auf Second Life-Server hochladen). [secondlife:///app/floater/learn_more Weitere Infos], wie Sie Ihr Konto zum Hochladen von Netzmodellen einrichten.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Modell optimieren
- </text>
- </panel>
- <text name="optimize_description">
- Wir haben das Modell auf Leistung optimiert. Sie können es bei Bedarf weiter anpassen.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Detailstufe generieren: hoch
- </text>
- <text name="medium_detail_text">
- Detailstufe generieren: mittel
- </text>
- <text name="low_detail_text">
- Detailstufe generieren: niedrig
- </text>
- <text name="lowest_detail_text">
- Detailstufe generieren: niedrigste
- </text>
- </panel>
- <panel name="content2">
- <button label="Geometrie neu berechnen" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Geometrievorschau
- </text>
- <combo_box name="preview_lod_combo" tool_tip="Detailstufe zur Anzeige in Vorschaudarstellung">
- <combo_item name="high">
- Viel Details
- </combo_item>
- <combo_item name="medium">
- Mittlere Details
- </combo_item>
- <combo_item name="low">
- Wenig Details
- </combo_item>
- <combo_item name="lowest">
- Wenigste Details
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Physik anpassen
- </text>
- </panel>
- <text name="physics_description">
- Wir erstellen eine Form für die Außenhülle des Modells. Passen Sie die Detailstufe der Form wie für den beabsichtigten Zweck erforderlich an.
- </text>
- <panel name="physics_content">
- <button label="Physik neu berechnen" name="recalculate_physics_btn"/>
- <button label="Neu berechnen..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Physikvorschau
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="Detailstufe zur Anzeige in Vorschaudarstellung">
- <combo_item name="high">
- Viel Details
- </combo_item>
- <combo_item name="medium">
- Mittlere Details
- </combo_item>
- <combo_item name="low">
- Wenig Details
- </combo_item>
- <combo_item name="lowest">
- Wenigste Details
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Überprüfen
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Auswirkung auf Parzelle/Region: Prim-Äquivalenzwert [EQUIV]
- </text>
- <text name="review_fee">
- Die für das Hochladen anfallende Gebühr in Höhe von L$ [FEE] wird von Ihrem Konto abgebucht.
- </text>
- <text name="review_confirmation">
- Durch Klicken auf „Hochladen“ bestätigen Sie, dass Sie die erforderlichen Rechte für das im Modell enthaltene Material besitzen.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Upload abgeschlossen
- </text>
- </panel>
- <text name="model_uploaded_text">
- Ihr Modell wurde hochgeladen.
- </text>
- <text name="inventory_text">
- Sie finden das Modell im Objektordner Ihres Inventars.
- </text>
- <text name="charged_fee">
- Von Ihrem Konto wurden [FEE] L$ abgebucht.
- </text>
- </panel>
- <button label="&lt;&lt; Zurück" name="back"/>
- <button label="Weiter &gt;&gt;" name="next"/>
- <button label="Gewichte und Gebühr berechnen &gt;&gt;" name="calculate"/>
- <button label="Berechnen..." name="calculating"/>
- <button label="Hochladen" name="upload" tool_tip="An Simulator hochladen"/>
- <button label="Abbrechen" name="cancel"/>
- <button label="Schließen" name="close"/>
- <spinner name="import_scale" value="1,0"/>
- <string name="status_idle">
- Inaktiv
- </string>
- <string name="status_parse_error">
- DAE-Parsing-Fehler. Details siehe Protokoll.
- </string>
- <string name="status_reading_file">
- Laden...
- </string>
- <string name="status_generating_meshes">
- Netze werden generiert...
- </string>
- <string name="status_vertex_number_overflow">
- Fehler: Anzahl von Vertices überschreitet 65534. Operation abgebrochen.
- </string>
- <string name="bad_element">
- Fehler: ungültiges Element.
- </string>
- <string name="high">
- Hoch
- </string>
- <string name="medium">
- Mittel
- </string>
- <string name="low">
- Niedrig
- </string>
- <string name="lowest">
- Niedrigste
- </string>
- <string name="mesh_status_good">
- Ausliefern
- </string>
- <string name="mesh_status_na">
- --
- </string>
- <string name="mesh_status_none">
- Keine
- </string>
- <string name="mesh_status_submesh_mismatch">
- Detailstufen haben unterschiedliche Anzahl texturfähiger Flächen.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Detailstufen haben unterschiedliche Anzahl von Netzinstanzen.
- </string>
- <string name="mesh_status_too_many_vertices">
- Detailstufe hat zu viele Vertices.
- </string>
- <string name="mesh_status_missing_lod">
- Erforderliche Detailstufe fehlt.
- </string>
- <string name="layer_all">
- Alle
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/en/floater_hardware_settings.xml b/indra/newview/skins/default/xui/en/floater_hardware_settings.xml
index 66bb9d3cea..9deb0d2030 100644
--- a/indra/newview/skins/default/xui/en/floater_hardware_settings.xml
+++ b/indra/newview/skins/default/xui/en/floater_hardware_settings.xml
@@ -132,6 +132,28 @@
name="vbo"
tool_tip="Enabling this on modern hardware gives a performance gain. However, older hardware often has poor implementations of VBOs and you may get crashes when this is enabled."
width="315" />
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="16"
+ layout="topleft"
+ left="10"
+ name="tc label"
+ top_pad="10"
+ width="188">
+ Enable S3TC:
+ </text>
+ <check_box
+ control_name="RenderCompressTextures"
+ height="16"
+ initial_value="true"
+ label="Enable Texture Compression (requires restart)"
+ layout="topleft"
+ left_pad="10"
+ name="texture compression"
+ tool_tip="Compresses textures in video memory, allowing for higher resolution textures to be loaded at the cost of some color quality."
+ width="315" />
<slider
control_name="TextureMemory"
decimal_digits="0"
diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml
index ca73883e53..82014e8836 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -46,7 +46,7 @@
tab_group="2"
top="0"
height="200"
- width="254"
+ width="244"
user_resize="true">
<button
height="20"
@@ -73,10 +73,11 @@
parse_highlights="true"
parse_urls="true"
left="1"
- width="249">
+ width="238">
</chat_history>
<line_editor
bottom="0"
+ left="3"
follows="left|right|bottom"
font="SansSerifSmall"
height="20"
@@ -84,7 +85,7 @@
layout="bottomleft"
name="chat_editor"
tab_group="3"
- width="249">
+ width="236">
</line_editor>
</layout_panel>
</layout_stack>
diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml
index 0e211551e6..5e92a12251 100644
--- a/indra/newview/skins/default/xui/en/floater_model_preview.xml
+++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml
@@ -1,8 +1,16 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<floater can_close="true" can_drag_on_left="false" can_minimize="false"
- can_resize="false" height="480" min_height="480" min_width="940"
- name="Model Preview" title="UPLOAD MODEL" width="940"
- help_topic="upload_model" >
+<floater
+ can_close="true"
+ can_drag_on_left="false"
+ can_minimize="false"
+ can_resize="false"
+ height="480"
+ min_height="480"
+ width="980"
+ min_width="980"
+ name="Model Preview"
+ title="UPLOAD MODEL"
+ help_topic="upload_model" >
<string name="status_idle"></string>
<string name="status_parse_error">Error: Dae parsing issue - see log for details.</string>
@@ -98,7 +106,7 @@
top_pad="15"
left="0"
height="300"
- width="625"
+ width="635"
name="import_tab"
tab_position="top">
<!-- LOD PANEL -->
@@ -116,13 +124,13 @@
left="3"
name="lod_tab_border"
top_pad="0"
- width="619" />
+ width="629" />
<text
follows="left|top"
height="18"
initial_value="Source"
layout="topleft"
- left="75"
+ left="85"
name="source"
text_color="ModelUploaderLabels"
top="15"
@@ -165,7 +173,7 @@
top_pad="10"
valign="top"
value="High"
- width="65" />
+ width="75" />
<combo_box
follows="top|left"
height="20"
@@ -175,10 +183,10 @@
top_delta="-3"
width="135">
<item
- id="Load from file"
+ name="Load from file"
value="Load from file" />
<item
- id="Generate"
+ name="Generate"
value="Generate" />
</combo_box>
<line_editor
@@ -210,10 +218,10 @@
visible="false"
width="135">
<item
- id="Triangle Limit"
+ name="Triangle Limit"
value="Triangle Limit" />
<item
- id="Error Threshold"
+ name="Error Threshold"
value="Error Threshold" />
</combo_box>
<spinner
@@ -290,7 +298,7 @@
top_pad="15"
valign="top"
value="Medium"
- width="65" />
+ width="75" />
<combo_box
follows="top|left"
height="20"
@@ -300,13 +308,13 @@
top_delta="-3"
width="135">
<item
- id="Load from file"
+ name="Load from file"
value="Load from file" />
<item
- id="Generate"
+ name="Generate"
value="Generate" />
<item
- id="Use LoD above"
+ name="Use LoD above"
value="Use LoD above" />
</combo_box>
<line_editor
@@ -339,10 +347,10 @@
top_delta="0"
width="135">
<item
- id="Triangle Limit"
+ name="Triangle Limit"
value="Triangle Limit" />
<item
- id="Error Threshold"
+ name="Error Threshold"
value="Error Threshold" />
</combo_box>
<spinner
@@ -418,7 +426,7 @@
top_pad="15"
valign="top"
value="Low"
- width="65" />
+ width="75" />
<combo_box
follows="top|left"
height="20"
@@ -428,13 +436,13 @@
top_delta="-3"
width="135">
<item
- id="Load from file"
+ name="Load from file"
value="Load from file" />
<item
- id="Generate"
+ name="Generate"
value="Generate" />
<item
- id="Use LoD above"
+ name="Use LoD above"
value="Use LoD above" />
</combo_box>
<line_editor
@@ -467,10 +475,10 @@
top_delta="0"
width="135">
<item
- id="Triangle Limit"
+ name="Triangle Limit"
value="Triangle Limit" />
<item
- id="Error Threshold"
+ name="Error Threshold"
value="Error Threshold" />
</combo_box>
<spinner
@@ -546,7 +554,7 @@
top_pad="15"
valign="top"
value="Lowest"
- width="65" />
+ width="75" />
<combo_box
follows="top|left"
height="20"
@@ -556,13 +564,13 @@
top_delta="-3"
width="135">
<item
- id="Load from file"
+ name="Load from file"
value="Load from file" />
<item
- id="Generate"
+ name="Generate"
value="Generate" />
<item
- id="Use LoD above"
+ name="Use LoD above"
value="Use LoD above" />
</combo_box>
<line_editor
@@ -595,10 +603,10 @@
top_delta="0"
width="135">
<item
- id="Triangle Limit"
+ name="Triangle Limit"
value="Triangle Limit" />
<item
- id="Error Threshold"
+ name="Error Threshold"
value="Error Threshold" />
</combo_box>
<spinner
@@ -1201,7 +1209,7 @@
name="calculate_btn"
top="3"
height="20"
- width="150"
+ width="165"
tool_tip="Calculate weights &amp;fee"/>
<button
follows="top|left"
@@ -1234,7 +1242,7 @@
right="-2"
top="3"
height="20"
- width="155"/>
+ width="275"/>
<!-- ========== WEIGHTS ==========-->
<text
follows="top|left"
@@ -1343,7 +1351,7 @@
layout="topleft"
name="right_panel"
top_pad="5"
- width="290">
+ width="340">
<combo_box
top_pad="3"
follows="left|top"
diff --git a/indra/newview/skins/default/xui/en/floater_model_wizard.xml b/indra/newview/skins/default/xui/en/floater_model_wizard.xml
deleted file mode 100644
index 62b8c5f96e..0000000000
--- a/indra/newview/skins/default/xui/en/floater_model_wizard.xml
+++ /dev/null
@@ -1,841 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<floater
- legacy_header_height="18"
- layout="topleft"
- name="Model Wizard"
- help_topic="model_wizard"
- bg_opaque_image_overlay="0.5 0.5 0.5 1"
- height="480"
- save_rect="true"
- title="UPLOAD MODEL WIZARD"
- width="535">
- <button
- top="32"
- tab_stop="false"
- left="410"
- height="32"
- name="upload_btn"
- enabled="false"
- label="5. Upload"
- border="false"
- image_unselected="BreadCrumbBtn_Right_Off"
- image_selected="BreadCrumbBtn_Right_Press"
- image_hover_unselected="BreadCrumbBtn_Right_Over"
- image_disabled="BreadCrumbBtn_Right_Disabled"
- image_disabled_selected="BreadCrumbBtn_Right_Disabled"
- width="110">
- <button.commit_callback
- function="Wizard.Upload"/>
- </button>
- <button
- top="32"
- left="310"
- height="32"
- tab_stop="false"
- name="review_btn"
- label="4. Review"
- enabled="false"
- border="false"
- image_unselected="BreadCrumbBtn_Middle_Off"
- image_selected="BreadCrumbBtn_Middle_Press"
- image_hover_unselected="BreadCrumbBtn_Middle_Over"
- image_disabled="BreadCrumbBtn_Middle_Disabled"
- image_disabled_selected="BreadCrumbBtn_Middle_Disabled"
- width="110">
- <button.commit_callback
- function="Wizard.Review"/>
- </button>
- <button
- top="32"
- left="210"
- height="32"
- name="physics_btn"
- label="3. Physics"
- tab_stop="false"
- enabled="false"
- border="false"
- image_unselected="BreadCrumbBtn_Middle_Off"
- image_selected="BreadCrumbBtn_Middle_Press"
- image_hover_unselected="BreadCrumbBtn_Middle_Over"
- image_disabled="BreadCrumbBtn_Middle_Disabled"
- image_disabled_selected="BreadCrumbBtn_Middle_Disabled"
- width="110">
- <button.commit_callback
- function="Wizard.Physics"/>
- </button>
- <button
- top="32"
- left="115"
- name="optimize_btn"
- label="2. Optimize"
- tab_stop="false"
- height="32"
- border="false"
- image_unselected="BreadCrumbBtn_Middle_Off"
- image_selected="BreadCrumbBtn_Middle_Press"
- image_hover_unselected="BreadCrumbBtn_Middle_Over"
- image_disabled="BreadCrumbBtn_Middle_Disabled"
- image_disabled_selected="BreadCrumbBtn_Middle_Disabled"
- width="110">
- <button.commit_callback
- function="Wizard.Optimize"/>
- </button>
- <button
- top="32"
- left="15"
- name="choose_file_btn"
- tab_stop="false"
- enabled="false"
- label="1. Choose File"
- height="32"
- image_unselected="BreadCrumbBtn_Left_Off"
- image_selected="BreadCrumbBtn_Left_Press"
- image_hover_unselected="BreadCrumbBtn_Left_Over"
- image_disabled="BreadCrumbBtn_Left_Disabled"
- image_disabled_selected="BreadCrumbBtn_Left_Disabled"
- width="110">
- <button.commit_callback
- function="Wizard.Choose"/>
- </button>
- <panel
- height="388"
- top_pad="0"
- name="choose_file_panel"
- visible="false"
- width="535"
- left="0">
- <panel
- height="22"
- top_pad="15"
- width="505"
- name="choose_file_header_panel"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true"
- left="15">
- <text
- width="200"
- left="10"
- top="3"
- name="choose_file_header_text"
- text_color="White"
- height="10"
- font="SansSerifBig"
- layout="topleft">
- Choose model file
- </text>
- </panel>
- <panel
- top_pad="14"
- left="15"
- height="310"
- width="505"
- name="choose_file_content"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true">
- <text
- height="32"
- left="10"
- name="advanced_users_text"
- text_color="White"
- top="15"
- width="320"
- word_wrap="true">
- Advanced users: If you are familiar with 3D content creation tools you may wish to use the Advanced Uploader.
- </text>
- <button
- follows="left|top"
- height="20"
- label="Switch to Advanced"
- layout="topleft"
- left_delta="0"
- name="switch_to_advanced"
- top_pad="5"
- width="130">
- </button>
- <text
- type="string"
- length="1"
- text_color="White"
- follows="left|top"
- top_pad="30"
- height="10"
- layout="topleft"
- left_delta="0"
- name="Cache location"
- width="320">
- Choose model file to upload
- </text>
- <line_editor
- border_style="line"
- border_thickness="1"
- follows="left|top"
- font="SansSerifSmall"
- height="20"
- layout="topleft"
- left_delta="0"
- max_length="4096"
- name="lod_file"
- top_pad="5"
- width="230" />
- <button
- follows="left|top"
- height="23"
- label="Browse..."
- label_selected="Browse..."
- layout="topleft"
- left_pad="5"
- name="browse"
- top_delta="-1"
- width="85">
- </button>
- <text
- type="string"
- length="1"
- text_color="White"
- follows="left|top"
- top_pad="5"
- height="10"
- layout="topleft"
- left="10"
- name="Model types"
- width="320">
- Second Life supports COLLADA (.dae) files
- </text>
- <!-- Placeholder panel for 3D preview render -->
- <panel
- top="30"
- right="-10"
- name="choose_file_preview_panel"
- bevel_style="none"
- highlight_light_color="0.09 0.09 0.09 1"
- border="true"
- border_style="line"
- height="150"
- follows="all"
- width="150">
- </panel>
- <text
- top_pad="10"
- width="130"
- height="14"
- left_delta="0"
- text_color="White"
- word_wrap="true">
- Dimensions (meters):
- </text>
- <text
- top_pad="0"
- width="160"
- height="15"
- font="SansSerifSmallBold"
- text_color="White"
- name="dimensions"
- left_delta="0">
- X Y Z
- </text>
- <text
- top_delta="0"
- width="160"
- height="15"
- name="dimension_x"
- left="356"/>
- <text
- top_delta="0"
- width="160"
- height="15"
- name="dimension_y"
- left="403"/>
- <text
- top_delta="0"
- width="160"
- height="15"
- name="dimension_z"
- left="450"/>
- <text
- height="16"
- left="10"
- name="warning_label"
- text_color="Yellow"
- top="200"
- visible="false"
- width="320">
- WARNING:
- </text>
- <text
- height="50"
- left="10"
- name="warning_text"
- top_pad="0"
- visible="false"
- width="320"
- word_wrap="true">
- You will not be able to complete the final step of uploading this model to the Second Life servers. [secondlife:///app/floater/learn_more Find out how] to set up your account for mesh model uploads.
- </text>
- </panel>
- </panel>
-
-
- <panel
- height="388"
- top_delta="0"
- name="optimize_panel"
- visible="true"
- width="535"
- left="0">
- <panel
- height="22"
- top_pad="15"
- name="optimize_header_panel"
- width="505"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true"
- left="15">
- <text
- width="200"
- left="10"
- name="optimize_header_text"
- top="3"
- text_color="White"
- height="10"
- font="SansSerifBig"
- layout="topleft">
- Optimize model
- </text>
- </panel>
- <text
- top_pad="14"
- width="460"
- height="20"
- font="SansSerifSmall"
- layout="topleft"
- name="optimize_description"
- word_wrap="true"
- left_delta="5">
- We have optimized the model for performance. Adjust it further if you wish.
- </text>
- <panel
- top_delta="40"
- visible="false"
- left="15"
- height="270"
- width="505"
- name="optimize_content"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true">
- <text
- top="20"
- width="300"
- height="12"
- font="SansSerifBold"
- left="112">Generating Level of Detail</text>
- <progress_bar
- name="optimize_progress_bar"
- image_fill="model_wizard\progress_light.png"
- color_bg="1 1 1 1"
- color_bar="1 1 1 0.96"
- follows="left|right|top"
- width="260"
- height="16"
- image_bar="model_wizard\progress_bar_bg.png"
- top_pad="14"
- left="110"/>
- <icon
- top_pad="10"
- left_delta="0"
- width="13"
- height="12"
- image_name="model_wizard\check_mark.png"/>
- <text
- top_delta="0"
- left_delta="18"
- name="high_detail_text"
- width="200"
- height="14">Generate Level of Detail: High</text>
- <icon
- top_pad="10"
- left_delta="-18"
- width="13"
- height="12"
- image_name="model_wizard\check_mark.png"/>
- <text
- top_delta="0"
- left_delta="18"
- name="medium_detail_text"
- width="200"
- height="14">Generate Level of Detail: Medium</text>
- <icon
- top_pad="10"
- left_delta="-18"
- width="13"
- height="12"
- image_name="model_wizard\check_mark.png"/>
- <text
- top_delta="0"
- left_delta="18"
- name="low_detail_text"
- width="200"
- height="14">Generate Level of Detail: Low</text>
- <icon
- top_pad="10"
- left_delta="-18"
- width="13"
- height="12"
- image_name="model_wizard\check_mark.png"/>
- <text
- top_delta="0"
- left_delta="18"
- name="lowest_detail_text"
- width="200"
- height="14">Generate Level of Detail: Lowest</text>
- </panel>
- <panel
- top_delta="0"
- left_delta="0"
- height="270"
- width="505"
- name="content2"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true">
- <text top="69" left="10" text_color="White" font="SansSerifSmallBold" width="120" height="16" wrap="true">Performance</text>
- <text top="85" left="10" width="120" word_wrap="true" font="SansSerifSmall" height="40">Faster rendering
-Less detail
-Lower prim weight</text>
- <text top="69" left="184" text_color="White" font="SansSerifSmallBold" width="120" height="16" wrap="true">Accuracy</text>
- <text top="85" left="184" width="120" word_wrap="true" font="SansSerifSmall" height="40">Slower rendering
-More detail
-Higher prim weight</text>
-
- <slider
- follows="left|top"
- height="20"
- increment="1"
- layout="topleft"
- left="10"
- max_val="2"
- initial_value="1"
- min_val="0"
- name="accuracy_slider"
- show_text="false"
- top="130"
- width="290" />
- <text
- font="SansSerifSmall"
- top_pad="0"
- width="5"
- left_delta="6"
- height="4">'
- </text>
- <text
- font="SansSerifSmall"
- top_delta="0"
- width="5"
- left_delta="137"
- height="4">'
- </text>
- <text
- font="SansSerifSmall"
- top_delta="0"
- width="5"
- left_delta="137"
- height="4">'
- </text>
- <button
- follows="left|top"
- height="20"
- label="Recalculate Geometry"
- layout="topleft"
- left="80"
- name="recalculate_geometry_btn"
- top_pad="15"
- width="150">
- </button>
- <text top="10" right="-10" width="185" text_color="White" follows="left|top" height="15" name="lod_label">
- Geometry preview
- </text>
- <panel
- right="-10"
- top="32"
- name="optimize_preview_panel"
- bevel_style="none"
- highlight_light_color="0.09 0.09 0.09 1"
- border_style="line"
- border="true"
- height="185"
- follows="all"
- width="185">
- </panel>
- <combo_box left_delta="75" top_pad="10" follows="left|top" list_position="below" height="22"
- name="preview_lod_combo" width="110" tool_tip="LOD to view in preview render">
- <combo_item name="high">
- High detail
- </combo_item>
- <combo_item name="medium">
- Medium detail
- </combo_item>
- <combo_item name="low">
- Low detail
- </combo_item>
- <combo_item name="lowest">
- Lowest detail
- </combo_item>
- </combo_box>
- </panel>
- </panel>
-
- <panel
- height="388"
- top_delta="0"
- name="physics_panel"
- visible="false"
- width="535"
- left="0">
- <panel
- height="22"
- top_pad="15"
- name="physics_header_panel"
- width="505"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true"
- left="15">
- <text
- width="200"
- left="10"
- name="physics_header_text"
- top="3"
- height="10"
- font="SansSerifBig"
- text_color="White"
- layout="topleft">
- Adjust physics
- </text>
- </panel>
- <text
- top_pad="10"
- width="474"
- height="50"
- font="SansSerifSmall"
- layout="topleft"
- name="physics_description"
- word_wrap="true"
- left_delta="5">
- We will create a shape for the outer hull of the model. Adjust the shape's detail level as needed for the intended purpose of your model.
- </text>
- <panel
- top_delta="44"
- left="15"
- height="270"
- width="505"
- name="physics_content"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true">
- <text top="10" left="10" text_color="White" font="SansSerifSmallBold" width="120" halign="right" height="16" wrap="true">Performance</text>
- <text top="26" left="10" width="120" word_wrap="true" font="SansSerifSmall" halign="right" height="40">Faster rendering
-Less detail
-Lower prim weight</text>
- <text top="174" left="10" text_color="White" font="SansSerifSmallBold" width="120" halign="right" height="16" wrap="true">Accuracy</text>
- <text top="190" left="10" width="120" word_wrap="true" font="SansSerifSmall" halign="right" height="40">Slower rendering
-More detail
-Higher prim weight</text>
-
- <slider
- follows="left|top"
- height="190"
- increment=".1"
- layout="topleft"
- left="140"
- max_val="1"
- initial_value="0.5"
- min_val="0"
- name="physics_slider"
- orientation="vertical"
- show_text="false"
- top="25"
- width="22" />
- <text top="10" width="120" word_wrap="true" left_pad="10" height="50">Examples:
-Moving objects
-Flying objects
-Vehicles</text>
- <text top="95" width="120" word_wrap="true" left_delta="0" height="50">Examples:
-Small static objects
-Less detailed objects
-Simple furniture</text>
- <text top="180" width="120" word_wrap="true" left_delta="0" height="50">Examples:
-Static objects
-Detailed objects
-Buildings</text>
- <button
- follows="left|top"
- height="20"
- label="Recalculate physics"
- layout="topleft"
- left="80"
- name="recalculate_physics_btn"
- top_pad="10"
- width="150">
- </button>
- <button
- enabled="false"
- follows="left|top"
- height="20"
- label="Recalculating..."
- layout="topleft"
- left_delta="0"
- name="recalculating_physics_btn"
- top_delta="0"
- visible="false"
- width="150">
- </button>
- <text top="10" right="-10" width="185" text_color="White" follows="left|top" height="15" name="lod_label">
- Physics preview
- </text>
- <panel
- right="-10"
- top="32"
- name="physics_preview_panel"
- bevel_style="none"
- highlight_light_color="0.09 0.09 0.09 1"
- border_style="line"
- border="true"
- height="185"
- follows="all"
- width="185">
- </panel>
- <combo_box left_delta="75" top_pad="10" follows="left|top" list_position="below" height="22"
- name="preview_lod_combo2" width="110" tool_tip="LOD to view in preview render">
- <combo_item name="high">
- High detail
- </combo_item>
- <combo_item name="medium">
- Medium detail
- </combo_item>
- <combo_item name="low">
- Low detail
- </combo_item>
- <combo_item name="lowest">
- Lowest detail
- </combo_item>
- </combo_box>
- </panel>
- </panel>
-
- <panel
- height="388"
- top_delta="0"
- name="review_panel"
- visible="false"
- width="535"
- left="0">
- <panel
- height="22"
- top_pad="15"
- name="review_header_panel"
- width="505"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true"
- left="15">
- <text
- width="200"
- left="10"
- name="review_header_text"
- text_color="White"
- top="3"
- height="10"
- font="SansSerifBig"
- layout="topleft">
- Review
- </text>
- </panel>
- <panel
- top_pad="14"
- left="15"
- height="310"
- width="505"
- name="review_content"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true">
- <text
- top="20"
- width="485"
- font="SansSerifMedium"
- text_color="White"
- left="10"
- name="review_prim_equiv"
- height="16">Impact to parcel/region: [EQUIV] prim equivalents
- </text>
- <text
- top_pad="20"
- width="485"
- font="SansSerifMedium"
- text_color="White"
- left="10"
- name="review_fee"
- height="16">Your account will be charged an upload fee of L$ [FEE].
- </text>
- <text
- top_pad="20"
- width="485"
- font="SansSerifMedium"
- text_color="White"
- left="10"
- name="review_confirmation"
- height="32"
- word_wrap="true">By clicking the upload button, you confirm that you have the appropriate rights to the material contained in the model.
- </text>
- </panel>
- </panel>
-
-
-
-
- <panel
- height="388"
- top_delta="0"
- name="upload_panel"
- visible="false"
- width="535"
- left="0">
- <panel
- height="22"
- top_pad="15"
- name="upload_header_panel"
- width="505"
- bg_opaque_color="DkGray2"
- background_visible="true"
- background_opaque="true"
- left="15">
- <text
- width="200"
- left="10"
- name="upload_header_text"
- top="3"
- text_color="White"
- height="10"
- font="SansSerifBig"
- layout="topleft">
- Upload complete
- </text>
- </panel>
- <text
- top_pad="14"
- width="495"
- height="16"
- font="SansSerifMedium"
- layout="topleft"
- name="model_uploaded_text"
- text_color="White"
- word_wrap="true"
- left="25">
- Your model has been uploaded.
- </text>
- <text
- top_pad="5"
- width="495"
- height="16"
- font="SansSerifMedium"
- layout="topleft"
- name="inventory_text"
- text_color="White"
- word_wrap="true"
- left="25">
- You will find it in the Objects folder in your inventory.
- </text>
- <text
- top_pad="20"
- width="495"
- font="SansSerifMedium"
- text_color="White"
- left="25"
- name="charged_fee"
- height="16">Your account has been charged L$ [FEE].
- </text>
- </panel>
-
-
-
- <button
- top="440"
- right="-285"
- width="90"
- height="22"
- name="back"
- label="&lt;&lt; Back" />
- <button
- top_delta="0"
- right="-190"
- width="90"
- height="22"
- name="next"
- label="Next &gt;&gt; " />
- <button
- top_delta="0"
- left_delta="0"
- width="160"
- height="22"
- name="calculate"
- label="Calculate weights &amp; fee &gt;&gt; " />
- <button
- enabled="false"
- visible="false"
- top_delta="0"
- left_delta="0"
- width="160"
- height="22"
- name="calculating"
- label="Calculating... " />
- <button
- enabled="false"
- top_delta="0"
- right="-150"
- width="90"
- height="22"
- visible="false"
- name="upload"
- tool_tip="Upload to simulator"
- label="Upload" />
- <button
- top_delta="0"
- right="-15"
- width="90"
- height="22"
- name="cancel"
- label="Cancel" />
- <button
- top_delta="0"
- right="-15"
- width="90"
- height="22"
- name="close"
- visible="false"
- label="Close" />
- <spinner visible="false" left="10" height="20" follows="top|left" width="80" top_pad="-50" value="1.0" min_val="0.01" max_val="64.0" name="import_scale"/>
-
- <string name="status_idle">Idle</string>
- <string name="status_parse_error">Dae parsing issue - see log for details.</string>
- <string name="status_reading_file">Loading...</string>
- <string name="status_generating_meshes">Generating Meshes...</string>
- <string name="status_vertex_number_overflow">Error: Vertex number is more than 65534, aborted!</string>
- <string name="bad_element">Error: element is invalid</string>
- <string name="high">High</string>
- <string name="medium">Medium</string>
- <string name="low">Low</string>
- <string name="lowest">Lowest</string>
- <string name="mesh_status_good">Ship it!</string>
- <string name="mesh_status_na">N/A</string>
- <string name="mesh_status_none">None</string>
- <string name="mesh_status_submesh_mismatch">Levels of detail have a different number of textureable faces.</string>
- <string name="mesh_status_mesh_mismatch">Levels of detail have a different number of mesh instances.</string>
- <string name="mesh_status_too_many_vertices">Level of detail has too many vertices.</string>
- <string name="mesh_status_missing_lod">Missing required level of detail.</string>
- <string name="layer_all">All</string>
- <!-- Text to display in physics layer combo box for "all layers" -->
-
-</floater>
diff --git a/indra/newview/skins/default/xui/en/floater_report_abuse.xml b/indra/newview/skins/default/xui/en/floater_report_abuse.xml
index e6d749a3f0..9561f67941 100644
--- a/indra/newview/skins/default/xui/en/floater_report_abuse.xml
+++ b/indra/newview/skins/default/xui/en/floater_report_abuse.xml
@@ -155,6 +155,7 @@
name="object_name"
top_delta="0"
translate="false"
+ parse_urls="false"
use_ellipses="true"
width="185">
Consetetur Sadipscing
diff --git a/indra/newview/skins/default/xui/en/floater_stats.xml b/indra/newview/skins/default/xui/en/floater_stats.xml
index 2fd932786b..9400f7b94f 100644
--- a/indra/newview/skins/default/xui/en/floater_stats.xml
+++ b/indra/newview/skins/default/xui/en/floater_stats.xml
@@ -149,13 +149,52 @@
show_per_sec="true"
show_bar="false">
</stat_bar>
+ <stat_bar
+ name="object_cache_hits"
+ label="Object Cache Hit Rate"
+ stat="object_cache_hits"
+ bar_min="0"
+ bar_max="100"
+ unit_label="%"
+ tick_spacing="20"
+ label_spacing="20"
+ show_history="true"
+ show_per_sec="false"
+ show_bar="false">
+ </stat_bar>
</stat_view>
<!--Texture Stats-->
<stat_view
name="texture"
label="Texture"
show_label="true">
- <stat_bar
+ <stat_bar
+ name="texture_cache_hits"
+ label="Cache Hit Rate"
+ stat="texture_cache_hits"
+ bar_min="0.f"
+ bar_max="100.f"
+ unit_label="%"
+ tick_spacing="20"
+ label_spacing="20"
+ show_history="true"
+ show_per_sec="false"
+ show_bar="false">
+ </stat_bar>
+ <stat_bar
+ name="texture_cache_read_latency"
+ label="Cache Read Latency"
+ unit_label="msec"
+ stat="texture_cache_read_latency"
+ bar_min="0.f"
+ bar_max="1000.f"
+ tick_spacing="100"
+ label_spacing="200"
+ show_history="true"
+ show_per_sec="false"
+ show_bar="false">
+ </stat_bar>
+ <stat_bar
name="numimagesstat"
label="Count"
stat="numimagesstat"
diff --git a/indra/newview/skins/default/xui/en/floater_texture_fetch_debugger.xml b/indra/newview/skins/default/xui/en/floater_texture_fetch_debugger.xml
new file mode 100644
index 0000000000..44b6a63bca
--- /dev/null
+++ b/indra/newview/skins/default/xui/en/floater_texture_fetch_debugger.xml
@@ -0,0 +1,341 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
+<floater
+ legacy_header_height="18"
+ can_minimize="false"
+ height="550"
+ layout="topleft"
+ name="TexFetchDebugger"
+ help_topic="texfetchdebugger"
+ title="Texture Fetching Debugger"
+ width="540">
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left="10"
+ name="total_num_fetched_label"
+ top="30"
+ width="400">
+ 1, Total number of fetched textures: [NUM]
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_num_fetching_requests_label"
+ top_delta="25"
+ width="400">
+ 2, Total number of fetching requests: [NUM]
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_num_cache_hits_label"
+ top_delta="25"
+ width="400">
+ 3, Total number of cache hits: [NUM]
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_num_visible_tex_label"
+ top_delta="25"
+ width="400">
+ 4, Total number of visible textures: [NUM]
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_num_visible_tex_fetch_req_label"
+ top_delta="25"
+ width="450">
+ 5, Total number of visible texture fetching requests: [NUM]
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_fetched_data_label"
+ top_delta="25"
+ width="530">
+ 6, Total number of fetched data: [SIZE1]KB, Decoded Data: [SIZE2]KB, [PIXEL]MPixels
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_fetched_vis_data_label"
+ top_delta="25"
+ width="480">
+ 7, Total number of visible data: [SIZE1]KB, Decoded Data: [SIZE2]KB
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_fetched_rendered_data_label"
+ top_delta="25"
+ width="530">
+ 8, Total number of rendered data: [SIZE1]KB, Decoded Data: [SIZE2]KB, [PIXEL]MPixels
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_cache_read_label"
+ top_delta="25"
+ width="400">
+ 9, Total time on cache readings: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_cache_write_label"
+ top_delta="25"
+ width="400">
+ 10, Total time on cache writings: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_decode_label"
+ top_delta="25"
+ width="400">
+ 11, Total time on decodings: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_gl_label"
+ top_delta="25"
+ width="400">
+ 12, Total time on gl texture creation: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_http_label"
+ top_delta="25"
+ width="400">
+ 13, Total time on HTTP fetching: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_fetch_label"
+ top_delta="25"
+ width="400">
+ 14, Total time on entire fetching: [TIME] seconds
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_refetch_vis_cache_label"
+ top_delta="25"
+ width="540">
+ 15, Refetching visibles from cache, Time: [TIME] seconds, Fetched: [SIZE]KB, [PIXEL]MPixels
+ </text>
+ <text
+ type="string"
+ length="1"
+ follows="left|top"
+ height="25"
+ layout="topleft"
+ left_delta="0"
+ name="total_time_refetch_vis_http_label"
+ top_delta="25"
+ width="540">
+ 16, Refetching visibles from HTTP, Time: [TIME] seconds, Fetched: [SIZE]KB, [PIXEL]MPixels
+ </text>
+ <spinner
+ decimal_digits="2"
+ follows="left|top"
+ height="20"
+ increment="0.01"
+ initial_value="1.0"
+ label="17, Ratio of Texel/Pixel:"
+ label_width="130"
+ layout="topleft"
+ left_delta="0"
+ max_val="10.0"
+ min_val="0.01"
+ name="texel_pixel_ratio"
+ top_delta="30"
+ width="200">
+ <spinner.commit_callback
+ function="TexFetchDebugger.ChangeTexelPixelRatio" />
+ </spinner>
+ <button
+ follows="left|top"
+ height="20"
+ label="Start"
+ layout="topleft"
+ left_delta="0"
+ name="start_btn"
+ top_delta="30"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.Start" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Reset"
+ layout="topleft"
+ left_pad="7"
+ name="clear_btn"
+ top_delta="0"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.Clear" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Close"
+ layout="topleft"
+ left_pad="7"
+ name="close_btn"
+ top_delta="0"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.Close" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Cache Read"
+ layout="topleft"
+ left="10"
+ name="cacheread_btn"
+ top_delta="30"
+ width="80">
+ <button.commit_callback
+ function="TexFetchDebugger.CacheRead" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Cache Write"
+ layout="topleft"
+ left_pad="7"
+ name="cachewrite_btn"
+ top_delta="0"
+ width="80">
+ <button.commit_callback
+ function="TexFetchDebugger.CacheWrite" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="HTTP"
+ layout="topleft"
+ left_pad="7"
+ name="http_btn"
+ top_delta="0"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.HTTPLoad" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Decode"
+ layout="topleft"
+ left_pad="7"
+ name="decode_btn"
+ top_delta="0"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.Decode" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="GL Texture"
+ layout="topleft"
+ left_pad="7"
+ name="gl_btn"
+ top_delta="0"
+ width="70">
+ <button.commit_callback
+ function="TexFetchDebugger.GLTexture" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Refetch Vis Cache"
+ layout="topleft"
+ left="10"
+ name="refetchviscache_btn"
+ top_delta="30"
+ width="120">
+ <button.commit_callback
+ function="TexFetchDebugger.RefetchVisCache" />
+ </button>
+ <button
+ follows="left|top"
+ height="20"
+ label="Refetch Vis HTTP"
+ layout="topleft"
+ left_pad="7"
+ name="refetchvishttp_btn"
+ top_delta="0"
+ width="120">
+ <button.commit_callback
+ function="TexFetchDebugger.RefetchVisHTTP" />
+ </button>
+</floater>
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index 5ba566b175..4e38f005a7 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -291,6 +291,12 @@
function="SideTray.PanelPeopleTab"
parameter="nearby_panel" />
</menu_item_call>
+ <menu_item_call
+ label="Block List"
+ name="Block List">
+ <menu_item_call.on_click
+ function="Communicate.BlockList" />
+ </menu_item_call>
</menu>
<menu
create_jump_keys="true"
@@ -1876,7 +1882,7 @@
<menu_item_check.on_click
function="Advanced.ToggleConsole"
parameter="texture" />
- </menu_item_check>
+ </menu_item_check>
<menu_item_check
label="Debug Console"
name="Debug Console"
@@ -1898,28 +1904,6 @@
parameter="notifications_console" />
</menu_item_call>
<menu_item_check
- label="Texture Size Console"
- name="Texture Size"
- shortcut="control|shift|6">
- <menu_item_check.on_check
- function="Advanced.CheckConsole"
- parameter="texture size" />
- <menu_item_check.on_click
- function="Advanced.ToggleConsole"
- parameter="texture size" />
- </menu_item_check>
- <menu_item_check
- label="Texture Category Console"
- name="Texture Category"
- shortcut="control|shift|7">
- <menu_item_check.on_check
- function="Advanced.CheckConsole"
- parameter="texture category" />
- <menu_item_check.on_click
- function="Advanced.ToggleConsole"
- parameter="texture category" />
- </menu_item_check>
- <menu_item_check
label="Fast Timers"
name="Fast Timers"
shortcut="control|shift|9"
@@ -1953,7 +1937,20 @@
function="Advanced.ToggleConsole"
parameter="scene view" />
</menu_item_check>
-
+ <menu_item_call
+ enabled="false"
+ visible="false"
+ label="Texture Fetch Debug Console"
+ name="Texture Fetch Debug Console">
+ <menu_item_call.on_click
+ function="Floater.Show"
+ parameter="tex_fetch_debugger" />
+ <on_enable
+ function="Develop.SetTexFetchDebugger" />
+ <on_visible
+ function="Develop.SetTexFetchDebugger" />
+ </menu_item_call>
+
<menu_item_separator/>
<menu_item_call
@@ -2439,6 +2436,52 @@
function="Advanced.ToggleInfoDisplay"
parameter="sculpt" />
</menu_item_check>
+ <menu
+ create_jump_keys="true"
+ label="Texture Density"
+ name="Texture Density"
+ tear_off="true">
+ <menu_item_check
+ label="None"
+ name="None">
+ <menu_item_check.on_check
+ function="Advanced.CheckDisplayTextureDensity"
+ parameter="none" />
+ <menu_item_check.on_click
+ function="Advanced.SetDisplayTextureDensity"
+ parameter="none" />
+ </menu_item_check>
+ <menu_item_check
+ label="Current"
+ name="Current">
+ <menu_item_check.on_check
+ function="Advanced.CheckDisplayTextureDensity"
+ parameter="current" />
+ <menu_item_check.on_click
+ function="Advanced.SetDisplayTextureDensity"
+ parameter="current" />
+ </menu_item_check>
+ <menu_item_check
+ label="Desired"
+ name="Desired">
+ <menu_item_check.on_check
+ function="Advanced.CheckDisplayTextureDensity"
+ parameter="desired" />
+ <menu_item_check.on_click
+ function="Advanced.SetDisplayTextureDensity"
+ parameter="desired" />
+ </menu_item_check>
+ <menu_item_check
+ label="Full"
+ name="Full">
+ <menu_item_check.on_check
+ function="Advanced.CheckDisplayTextureDensity"
+ parameter="full" />
+ <menu_item_check.on_click
+ function="Advanced.SetDisplayTextureDensity"
+ parameter="full" />
+ </menu_item_check>
+ </menu>
</menu>
<menu
create_jump_keys="true"
@@ -2606,16 +2649,6 @@
parameter="TextureLoadFullRes" />
</menu_item_check>
<menu_item_check
- label="Audit Textures"
- name="Audit Textures">
- <menu_item_check.on_check
- function="CheckControl"
- parameter="AuditTexture" />
- <menu_item_check.on_click
- function="ToggleControl"
- parameter="AuditTexture" />
- </menu_item_check>
- <menu_item_check
label="Texture Atlas (experimental)"
name="Texture Atlas">
<menu_item_check.on_check
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index afc5b916e7..a26c5bb344 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -1245,6 +1245,25 @@ Visit [_URL] for more information?
<notification
icon="alertmodal.tga"
+ name="IntelOldDriver"
+ type="alertmodal">
+ There is likely a newer driver for your graphics chip. Updating graphics drivers can substantially improve performance.
+
+ Visit [_URL] to check for driver updates?
+ <tag>confirm</tag>
+ <url option="0" name="url">
+ http://www.intel.com/p/en_US/support/detect/graphics
+ </url>
+ <usetemplate
+ ignoretext="My graphics driver is out of date"
+ name="okcancelignore"
+ notext="No"
+ yestext="Yes"/>
+ <tag>fail</tag>
+ </notification>
+
+ <notification
+ icon="alertmodal.tga"
name="UnknownGPU"
type="alertmodal">
Your system contains a graphics card that [APP_NAME] doesn't recognize.
@@ -6373,31 +6392,28 @@ Is this OK?
<notification
icon="notify.tga"
name="ScriptQuestionCaution"
- priority="high"
+ priority="critical"
persist="true"
type="notify">
-An object named &apos;&lt;nolink&gt;[OBJECTNAME]&lt;/nolink&gt;&apos;, owned by &apos;[NAME]&apos; would like to:
-
-[QUESTIONS]
-If you do not trust this object and its creator, you should deny the request.
+Warning: The object &apos;&lt;nolink&gt;[OBJECTNAME]&lt;/nolink&gt;&apos; wants total access to your Linden Dollars account. If you allow access, it can remove funds from your account at any time, or empty your account completely, on an ongoing basis with no additional warnings.
+
+It is rare that such a request is legitimate. Do not allow access if you do not fully understand why it wants access to your account.
-Grant this request?
<tag>confirm</tag>
<form name="form">
<button
index="0"
name="Grant"
- text="Grant"/>
+ text="Allow total access"/>
<button
default="true"
index="1"
name="Deny"
text="Deny"/>
- <button
- index="2"
- name="Details"
- text="Details..."/>
</form>
+ <footer>
+[FOOTERTEXT]
+ </footer>
</notification>
<notification
diff --git a/indra/newview/skins/default/xui/en/panel_script_question_toast.xml b/indra/newview/skins/default/xui/en/panel_script_question_toast.xml
new file mode 100644
index 0000000000..b0436bb6dc
--- /dev/null
+++ b/indra/newview/skins/default/xui/en/panel_script_question_toast.xml
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<panel
+ background_opaque="false"
+ border_visible="false"
+ background_visible="true"
+ bg_alpha_color="PanelNotificationBackground"
+ bg_opaque_color="PanelNotificationBackground"
+ chrome="true"
+ height="270"
+ label="script_question_panel"
+ layout="topleft"
+ left="0"
+ name="panel_script_question_toast"
+ top="0"
+ width="305">
+ <text
+ follows="left|right|top"
+ font="SansSerifBold"
+ height="160"
+ layout="topleft"
+ left="10"
+ mouse_opaque="false"
+ name="top_info_message"
+ parse_highlights="true"
+ parse_urls="true"
+ text_color="NotifyCautionBoxColor"
+ top="10"
+ value=""
+ width="285"
+ wrap="true"/>
+ <panel
+ background_visible="false"
+ follows="left|right|top"
+ height="30"
+ label="buttons_panel"
+ layout="topleft"
+ name="buttons_panel"
+ top_pad="10"
+ width="285">
+ </panel>
+ <text
+ follows="all"
+ font="SansSerifBold"
+ height="55"
+ layout="topleft"
+ mouse_opaque="false"
+ name="bottom_info_message"
+ parse_highlights="true"
+ parse_urls="true"
+ text_color="NotifyCautionBoxColor"
+ top_pad="5"
+ value=""
+ width="285"
+ wrap="true"/>
+</panel>
diff --git a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml
index 6600339ad7..bf2e6bc2d9 100644
--- a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml
+++ b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml
@@ -267,19 +267,19 @@
<combo_box.item
label="Touch (default)"
name="Touch/grab(default)"
- value="Touch/grab (default)" />
+ value="Touch" />
<combo_box.item
label="Sit on object"
name="Sitonobject"
- value="Sit on object" />
+ value="Sit" />
<combo_box.item
label="Buy object"
name="Buyobject"
- value="Buy object" />
+ value="Buy" />
<combo_box.item
label="Pay object"
name="Payobject"
- value="Pay object" />
+ value="Pay" />
<combo_box.item
label="Open"
name="Open"
diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index 4ccec4838a..866ea296c3 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -393,6 +393,7 @@ Please try logging in again in a minute.</string>
<string name="reconnect_nearby">You will now be reconnected to Nearby Voice Chat</string>
<string name="ScriptQuestionCautionChatGranted">'[OBJECTNAME]', an object owned by '[OWNERNAME]', located in [REGIONNAME] at [REGIONPOS], has been granted permission to: [PERMISSIONS].</string>
<string name="ScriptQuestionCautionChatDenied">'[OBJECTNAME]', an object owned by '[OWNERNAME]', located in [REGIONNAME] at [REGIONPOS], has been denied permission to: [PERMISSIONS].</string>
+ <string name="AdditionalPermissionsRequestHeader">If you allow access to your account, you will also be allowing the object to:</string>
<string name="ScriptTakeMoney">Take Linden dollars (L$) from you</string>
<string name="ActOnControlInputs">Act on your control inputs</string>
<string name="RemapControlInputs">Remap your control inputs</string>
diff --git a/indra/newview/skins/default/xui/es/floater_model_wizard.xml b/indra/newview/skins/default/xui/es/floater_model_wizard.xml
deleted file mode 100644
index 5bd6b5e0e5..0000000000
--- a/indra/newview/skins/default/xui/es/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="CARGAR ASISTENTE DE MODELO">
- <button label="5. Subir" name="upload_btn"/>
- <button label="4. Revisar" name="review_btn"/>
- <button label="3. Física" name="physics_btn"/>
- <button label="2. Optimizar" name="optimize_btn"/>
- <button label="1. Seleccionar archivo" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Elige el archivo de modelo
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Usuarios avanzados: si tienes experiencia con las herramientas de creación de contenidos 3D, quizá te interese utilizar la función de subida avanzada.
- </text>
- <button label="Cambiar al modo Avanzado" name="switch_to_advanced"/>
- <text name="Cache location">
- Elige el archivo de modelo que deseas subir
- </text>
- <button label="Examinar..." label_selected="Examinar..." name="browse"/>
- <text name="Model types">
- ‎Second Life admite los archivos COLLADA (.dae)
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- ATENCIÓN:
- </text>
- <text name="warning_text">
- No podrás completar el paso final de la subida de este modelo a los servidores de Second Life. [secondlife:///app/floater/learn_more Averigua cómo] configurar tu cuenta para subir modelos de malla.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Optimizar el modelo
- </text>
- </panel>
- <text name="optimize_description">
- Hemos optimizado el rendimiento del modelo, pero puedes ajustarlo más si lo deseas.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Generar el nivel de detalle: Alto
- </text>
- <text name="medium_detail_text">
- Generar el nivel de detalle: Medio
- </text>
- <text name="low_detail_text">
- Generar el nivel de detalle: Bajo
- </text>
- <text name="lowest_detail_text">
- Generar el nivel de detalle: Mínimo
- </text>
- </panel>
- <panel name="content2">
- <button label="Recalcular la geometría" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Vista previa de geometría
- </text>
- <combo_box name="preview_lod_combo" tool_tip="LOD para ver en renderizado de prueba">
- <combo_item name="high">
- Detalle alto
- </combo_item>
- <combo_item name="medium">
- Detalles medios
- </combo_item>
- <combo_item name="low">
- Detalle bajo
- </combo_item>
- <combo_item name="lowest">
- Detalles mínimos
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Ajustar la física
- </text>
- </panel>
- <text name="physics_description">
- Crearemos una forma para la apariencia exterior del modelo. Ajusta el nivel de detalle de la forma según se necesite para el propósito proyectado del modelo.
- </text>
- <panel name="physics_content">
- <button label="Recalcular física" name="recalculate_physics_btn"/>
- <button label="Recalculando..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Prueba de física
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="LOD para ver en renderizado de prueba">
- <combo_item name="high">
- Detalle alto
- </combo_item>
- <combo_item name="medium">
- Detalles medios
- </combo_item>
- <combo_item name="low">
- Detalle bajo
- </combo_item>
- <combo_item name="lowest">
- Detalles mínimos
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Revisar
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Impacto en la parcela/región: [EQUIV] equivalentes en prim
- </text>
- <text name="review_fee">
- Cargaremos en tu cuenta el precio de subida de L$ [FEE].
- </text>
- <text name="review_confirmation">
- Al pulsar en el botón de subida, confirmas que posees los derechos necesarios sobre el material que contiene el modelo.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Subida finalizada
- </text>
- </panel>
- <text name="model_uploaded_text">
- Se ha subido tu modelo.
- </text>
- <text name="inventory_text">
- Puedes buscar la carpeta Objetos en tu inventario.
- </text>
- <text name="charged_fee">
- Se han cargado [FEE] L$ en tu cuenta.
- </text>
- </panel>
- <button label="&lt;&lt; Atrás" name="back"/>
- <button label="Siguiente &gt;&gt;" name="next"/>
- <button label="Calcular pesos y precio &gt;&gt;" name="calculate"/>
- <button label="Calculando..." name="calculating"/>
- <button label="Subir" name="upload" tool_tip="Cargar al simulador"/>
- <button label="Cancelar" name="cancel"/>
- <button label="Cerrar" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Inactivo
- </string>
- <string name="status_parse_error">
- Problema de análisis de DAE - consulta los datos en el registro.
- </string>
- <string name="status_reading_file">
- Cargando...
- </string>
- <string name="status_generating_meshes">
- Generando redes...
- </string>
- <string name="status_vertex_number_overflow">
- Error: El número de intersección es superior a 65534. Cancelado.
- </string>
- <string name="bad_element">
- Error: el elemento no es válido
- </string>
- <string name="high">
- Alto
- </string>
- <string name="medium">
- Media
- </string>
- <string name="low">
- Bajo
- </string>
- <string name="lowest">
- Mínimo
- </string>
- <string name="mesh_status_good">
- Factúralo.
- </string>
- <string name="mesh_status_na">
- N/A
- </string>
- <string name="mesh_status_none">
- Ninguno
- </string>
- <string name="mesh_status_submesh_mismatch">
- Los niveles de detalle poseen un número distinto de caras a las que se pueden aplicar texturas.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Los niveles de detalle poseen un número distinto de ejemplos de red.
- </string>
- <string name="mesh_status_too_many_vertices">
- El nivel de detalle posee demasiadas intersecciones.
- </string>
- <string name="mesh_status_missing_lod">
- Falta un nivel de detalle requerido.
- </string>
- <string name="layer_all">
- Todo
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/fr/floater_about_land.xml b/indra/newview/skins/default/xui/fr/floater_about_land.xml
index 6f8885487a..49af1a87e1 100644
--- a/indra/newview/skins/default/xui/fr/floater_about_land.xml
+++ b/indra/newview/skins/default/xui/fr/floater_about_land.xml
@@ -439,7 +439,7 @@ musique :
<text name="Sound:">
Son :
</text>
- <check_box label="Limiter les gestes et sons d&apos;objet à cette parcelle" name="check sound local"/>
+ <check_box label="Limiter les sons des gestes et des objets à cette parcelle" name="check sound local"/>
<text name="Avatar Sounds:">
Sons d&apos;avatar :
</text>
diff --git a/indra/newview/skins/default/xui/fr/floater_model_preview.xml b/indra/newview/skins/default/xui/fr/floater_model_preview.xml
index a3b50351ae..0f272891c7 100644
--- a/indra/newview/skins/default/xui/fr/floater_model_preview.xml
+++ b/indra/newview/skins/default/xui/fr/floater_model_preview.xml
@@ -214,7 +214,7 @@
</panel>
</tab_container>
<panel name="weights_and_warning_panel">
- <button label="Calculer les poids et les frais." name="calculate_btn" tool_tip="Calculer les poids et les frais."/>
+ <button label="Calculer les poids et les frais" name="calculate_btn" tool_tip="Calculer les poids et les frais."/>
<button label="Annuler" name="cancel_btn"/>
<button label="Charger le modèle" name="ok_btn" tool_tip="Charger dans le simulateur"/>
<button label="Effacer les paramètres et réinitialiser le formulaire" name="reset_btn"/>
diff --git a/indra/newview/skins/default/xui/fr/floater_model_wizard.xml b/indra/newview/skins/default/xui/fr/floater_model_wizard.xml
deleted file mode 100644
index 128b9d6fa4..0000000000
--- a/indra/newview/skins/default/xui/fr/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="ASSISTANT DE CHARGEMENT DE MODÈLE">
- <button label="5. Chargement" name="upload_btn"/>
- <button label="4. Vérification" name="review_btn"/>
- <button label="3. Propriétés physiques" name="physics_btn"/>
- <button label="2. Optimisation" name="optimize_btn"/>
- <button label="1. Sélection du fichier" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Choisir un fichier de modèle
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Utilisateurs expérimentés : si vous êtes habitué à utiliser des outils de création de contenu en 3D, l&apos;outil de chargement avancé est mis à votre disposition.
- </text>
- <button label="Passer à Avancé" name="switch_to_advanced"/>
- <text name="Cache location">
- Choisir un fichier de modèle à charger
- </text>
- <button label="Parcourir..." label_selected="Parcourir..." name="browse"/>
- <text name="Model types">
- Second Life prend en charge les fichiers COLLADA (.dae).
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- AVERTISSEMENT :
- </text>
- <text name="warning_text">
- Vous ne pourrez pas effectuer l&apos;étape de chargement finale du modèle sur les serveurs Second Life. [secondlife:///app/floater/learn_more Découvrez comment] configurer votre compte pour le chargement de modèles de maillage.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Optimiser le modèle
- </text>
- </panel>
- <text name="optimize_description">
- Le modèle a été optimisé en termes de performances. Vous pouvez l&apos;ajuster si vous le souhaitez.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Générer le niveau de détail : Élevé
- </text>
- <text name="medium_detail_text">
- Générer le niveau de détail : Moyen
- </text>
- <text name="low_detail_text">
- Générer le niveau de détail : Faible
- </text>
- <text name="lowest_detail_text">
- Générer le niveau de détail : Le plus faible
- </text>
- </panel>
- <panel name="content2">
- <button label="Recalcul géométrique" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Aperçu de la géométrie
- </text>
- <combo_box name="preview_lod_combo" tool_tip="Niveau de détail à afficher en rendu d&apos;aperçu.">
- <combo_item name="high">
- Niveau de détail élevé
- </combo_item>
- <combo_item name="medium">
- Niveau de détail moyen
- </combo_item>
- <combo_item name="low">
- Niveau de détail faible
- </combo_item>
- <combo_item name="lowest">
- Niveau de détail le plus faible
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Ajuster les propriétés physiques
- </text>
- </panel>
- <text name="physics_description">
- Une forme va être créée pour l&apos;enveloppe externe du modèle. Ajustez le niveau de détail de la forme en fonction de l&apos;objectif souhaité pour votre modèle.
- </text>
- <panel name="physics_content">
- <button label="Recalcul physique" name="recalculate_physics_btn"/>
- <button label="Recalcul en cours..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Aperçu des propriétés physiques
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="Niveau de détail à afficher en rendu d&apos;aperçu.">
- <combo_item name="high">
- Niveau de détail élevé
- </combo_item>
- <combo_item name="medium">
- Niveau de détail moyen
- </combo_item>
- <combo_item name="low">
- Niveau de détail faible
- </combo_item>
- <combo_item name="lowest">
- Niveau de détail le plus faible
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Vérification
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Impact sur la parcelle/région : équivalent à [EQUIV] prims
- </text>
- <text name="review_fee">
- Votre compte sera débité de [FEE] L$ de frais de chargement.
- </text>
- <text name="review_confirmation">
- En cliquant sur le bouton de chargement, vous confirmez que vous disposez des droits appropriés sur le contenu du modèle.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Chargement terminé
- </text>
- </panel>
- <text name="model_uploaded_text">
- Votre modèle a été chargé.
- </text>
- <text name="inventory_text">
- Vous le trouverez dans le dossier Objets de votre inventaire.
- </text>
- <text name="charged_fee">
- Votre compte a été débité de [FEE] L$.
- </text>
- </panel>
- <button label="&lt;&lt; Préc." name="back"/>
- <button label="Suiv. &gt;&gt;" name="next"/>
- <button label="Calculer les poids et les frais &gt;&gt;" name="calculate"/>
- <button label="Calcul en cours..." name="calculating"/>
- <button label="Charger" name="upload" tool_tip="Charger dans le simulateur."/>
- <button label="Annuler" name="cancel"/>
- <button label="Fermer" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Inactif
- </string>
- <string name="status_parse_error">
- Problème d&apos;analyse de fichier .dae ; reportez-vous au journal pour plus de détails.
- </string>
- <string name="status_reading_file">
- Chargement...
- </string>
- <string name="status_generating_meshes">
- Génération des maillages...
- </string>
- <string name="status_vertex_number_overflow">
- Erreur : valeur de sommet supérieure à 65534. Opération abandonnée.
- </string>
- <string name="bad_element">
- Erreur : élément non valide
- </string>
- <string name="high">
- Élevé
- </string>
- <string name="medium">
- Moyen
- </string>
- <string name="low">
- Faible
- </string>
- <string name="lowest">
- Le plus faible
- </string>
- <string name="mesh_status_good">
- Bon à publier !
- </string>
- <string name="mesh_status_na">
- N/A
- </string>
- <string name="mesh_status_none">
- Aucun
- </string>
- <string name="mesh_status_submesh_mismatch">
- Un nombre différent de faces d&apos;application de texture est associé aux niveaux de détail.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Un nombre différent d&apos;instances de maillage est associé aux niveaux de détail.
- </string>
- <string name="mesh_status_too_many_vertices">
- Trop de sommets pour le niveau de détail.
- </string>
- <string name="mesh_status_missing_lod">
- Niveau de détail requis manquant.
- </string>
- <string name="layer_all">
- Tout
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/fr/strings.xml b/indra/newview/skins/default/xui/fr/strings.xml
index 3eebed450f..8b410128da 100644
--- a/indra/newview/skins/default/xui/fr/strings.xml
+++ b/indra/newview/skins/default/xui/fr/strings.xml
@@ -4509,7 +4509,7 @@ Essayez avec le chemin d&apos;accès à l&apos;éditeur entre guillemets doubles
Backsp
</string>
<string name="Shift">
- Shift
+ Maj
</string>
<string name="Ctrl">
Ctrl
diff --git a/indra/newview/skins/default/xui/it/floater_model_wizard.xml b/indra/newview/skins/default/xui/it/floater_model_wizard.xml
deleted file mode 100644
index ab5fdb29e4..0000000000
--- a/indra/newview/skins/default/xui/it/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="PROCEDURA GUIDATA CARICA MODELLO">
- <button label="5. Carica sul server" name="upload_btn"/>
- <button label="4. Rivedi" name="review_btn"/>
- <button label="3. Fisica" name="physics_btn"/>
- <button label="2. Ottimizza" name="optimize_btn"/>
- <button label="1. Seleziona file" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Seleziona file modello
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Utenti avanzati: Gli utenti che hanno dimestichezza con gli strumenti di creazione 3D possono usare le opzioni di caricamento avanzate.
- </text>
- <button label="Passa a modalità avanzata" name="switch_to_advanced"/>
- <text name="Cache location">
- Scegli il file del modello da caricare
- </text>
- <button label="Sfoglia..." label_selected="Sfoglia..." name="browse"/>
- <text name="Model types">
- Second Life supporta file COLLADA (.dae)
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- ATTENZIONE:
- </text>
- <text name="warning_text">
- Non sarà possibile completare il passaggio finale per il caricamento finale di questo modello sui server di Second Life. [secondlife:///app/floater/learn_more Scopri come] impostare l&apos;account per il caricamento di modelli con reticolo.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Ottimizza modello
- </text>
- </panel>
- <text name="optimize_description">
- Abbiamo ottimizzato il modello per migliorare le prestazioni. Se necessario, può essere regolato ulteriormente.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Genera livello di dettaglio: Alto
- </text>
- <text name="medium_detail_text">
- Genera livello di dettaglio: Medio
- </text>
- <text name="low_detail_text">
- Genera livello di dettaglio: Basso
- </text>
- <text name="lowest_detail_text">
- Genera livello di dettaglio: Bassissimo
- </text>
- </panel>
- <panel name="content2">
- <button label="Ricalcola geometria" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Anteprima geometria
- </text>
- <combo_box name="preview_lod_combo" tool_tip="Livello di dettaglio per anteprima rendering">
- <combo_item name="high">
- Molti dettagli
- </combo_item>
- <combo_item name="medium">
- Dettagli medi
- </combo_item>
- <combo_item name="low">
- Meno dettagli
- </combo_item>
- <combo_item name="lowest">
- Dettaglio minimo
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Modifica fisica
- </text>
- </panel>
- <text name="physics_description">
- Verrà creata una forma per lo scafo esterno del modello. Regola il livello di dettaglio della forma in base al fine desiderato del modello.
- </text>
- <panel name="physics_content">
- <button label="Ricalcola fisica" name="recalculate_physics_btn"/>
- <button label="Ricalcolo in corso..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Anteprima fisica
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="Livello di dettaglio per anteprima rendering">
- <combo_item name="high">
- Molti dettagli
- </combo_item>
- <combo_item name="medium">
- Dettagli medi
- </combo_item>
- <combo_item name="low">
- Meno dettagli
- </combo_item>
- <combo_item name="lowest">
- Dettaglio minimo
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Rivedi
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Impatto sul lotto o sulla regione: [EQUIV] prim equivalenti
- </text>
- <text name="review_fee">
- All&apos;account verrà accreditata una tariffa di caricamento pari a L$ [FEE].
- </text>
- <text name="review_confirmation">
- Facendo clic sul pulsante Carica, confermi di possedere i diritti relativi ai materiali contenuti nel modello.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Caricamento completato
- </text>
- </panel>
- <text name="model_uploaded_text">
- Il modello è stato caricato.
- </text>
- <text name="inventory_text">
- Puoi trovarlo nella cartella Oggetti nel tuo inventario.
- </text>
- <text name="charged_fee">
- La somma di L$ [FEE] è stata addebitata sul tuo account.
- </text>
- </panel>
- <button label="&lt;&lt; Indietro" name="back"/>
- <button label="Avanti &gt;&gt;" name="next"/>
- <button label="Calcolare pesi e tariffa &gt;&gt;" name="calculate"/>
- <button label="Calcolo in corso..." name="calculating"/>
- <button label="Carica" name="upload" tool_tip="Carica al simulatore"/>
- <button label="Annulla" name="cancel"/>
- <button label="Chiudi" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Pausa
- </string>
- <string name="status_parse_error">
- Problema nell&apos;elaborazione DAE - vedi il registro per informazioni al riguardo.
- </string>
- <string name="status_reading_file">
- Caricamento in corso...
- </string>
- <string name="status_generating_meshes">
- Generazione reticoli...
- </string>
- <string name="status_vertex_number_overflow">
- Errore: numero di vertici maggiore di 65534, annullato.
- </string>
- <string name="bad_element">
- Errore: elemento non valido
- </string>
- <string name="high">
- Alto
- </string>
- <string name="medium">
- Medio
- </string>
- <string name="low">
- Basso
- </string>
- <string name="lowest">
- Bassissimo
- </string>
- <string name="mesh_status_good">
- Invia!
- </string>
- <string name="mesh_status_na">
- N/D
- </string>
- <string name="mesh_status_none">
- Nessuno
- </string>
- <string name="mesh_status_submesh_mismatch">
- Ai vari livelli del dettaglio corrispondono numeri diversi di faccette con texture.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Ai vari livelli del dettaglio corrispondono numeri diversi istanze di reticoli.
- </string>
- <string name="mesh_status_too_many_vertices">
- Troppi vertici per il livello di dettaglio.
- </string>
- <string name="mesh_status_missing_lod">
- Livello di dettaglio minimo mancante.
- </string>
- <string name="layer_all">
- Tutto
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/ja/floater_model_wizard.xml b/indra/newview/skins/default/xui/ja/floater_model_wizard.xml
deleted file mode 100644
index 746bd8553c..0000000000
--- a/indra/newview/skins/default/xui/ja/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="モデルウィザードをアップロード">
- <button label="5. アップロード" name="upload_btn"/>
- <button label="4. 確認" name="review_btn"/>
- <button label="3. 物理効果" name="physics_btn"/>
- <button label="2. 最適化" name="optimize_btn"/>
- <button label="1. ファイルを選択" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- モデルファイルを選択
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- 上級ユーザーの場合:3D コンテンツ制作ツールの使用に慣れている方は、高度なアップローダーもお試しください。
- </text>
- <button label="アドバンスモードに切り替える" name="switch_to_advanced"/>
- <text name="Cache location">
- アップロードするモデルファイルを選択
- </text>
- <button label="参照..." label_selected="参照..." name="browse"/>
- <text name="Model types">
- Second Life は COLLADA (.dae) ファイルをサポートします。
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- 警告:
- </text>
- <text name="warning_text">
- このモデルを Second Life サーバーにアップロードするための最終手順を実行できません。[secondlife:///app/floater/learn_more こちらを参照して]、メッシュモデルをアップロードできるようにアカウントを設定してください。
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- モデルを最適化
- </text>
- </panel>
- <text name="optimize_description">
- モデルはパフォーマンスを重視して最適化されています。必要に応じて調整してください。
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- 次の描画詳細度を作成:高
- </text>
- <text name="medium_detail_text">
- 次の描画詳細度を作成:中
- </text>
- <text name="low_detail_text">
- 次の描画詳細度を作成:低
- </text>
- <text name="lowest_detail_text">
- 次の描画詳細度を作成:最低
- </text>
- </panel>
- <panel name="content2">
- <button label="ジオメトリを再計算" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- ジオメトリのプレビュー
- </text>
- <combo_box name="preview_lod_combo" tool_tip="プレビュー表示の LOD 設定">
- <combo_item name="high">
- 高い詳細度
- </combo_item>
- <combo_item name="medium">
- 中の詳細度
- </combo_item>
- <combo_item name="low">
- 低い詳細度
- </combo_item>
- <combo_item name="lowest">
- 最低の詳細度
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- 物理作用の調整
- </text>
- </panel>
- <text name="physics_description">
- モデルの外殻構造のシェイプは弊社が作成します。モデルの目的に応じてシェイプの詳細度を調整してください。
- </text>
- <panel name="physics_content">
- <button label="物理作用を再計算" name="recalculate_physics_btn"/>
- <button label="再計算中..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- 物理作用のプレビュー
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="プレビュー表示の LOD 設定">
- <combo_item name="high">
- 高い詳細度
- </combo_item>
- <combo_item name="medium">
- 中の詳細度
- </combo_item>
- <combo_item name="low">
- 低い詳細度
- </combo_item>
- <combo_item name="lowest">
- 最低の詳細度
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- 確認
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- 区画/リージョンへの負荷:[EQUIV] プリム換算値
- </text>
- <text name="review_fee">
- L$ [FEE] のアップロード料金があなたのアカウントに請求されます。
- </text>
- <text name="review_confirmation">
- アップロードボタンをクリックすることにより、モデルに含まれるマテリアルの所有権や使用許可の所持を認めたことになります。
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- アップロード完了
- </text>
- </panel>
- <text name="model_uploaded_text">
- モデルがアップロードされました。
- </text>
- <text name="inventory_text">
- それはインベントリの「オブジェクト」フォルダにあります。
- </text>
- <text name="charged_fee">
- あなたのアカウントに L$ [FEE] が請求されました。
- </text>
- </panel>
- <button label="&lt;&lt; 戻る" name="back"/>
- <button label="次へ&gt;&gt;" name="next"/>
- <button label="ウェイトと料金の計算 &gt;&gt;" name="calculate"/>
- <button label="計算中..." name="calculating"/>
- <button label="アップロード" name="upload" tool_tip="シミュレーターにアップロード"/>
- <button label="取り消し" name="cancel"/>
- <button label="閉じる" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- 待機状態
- </string>
- <string name="status_parse_error">
- Dae に問題が見つかりました - 詳細についてはログをご参照ください。
- </string>
- <string name="status_reading_file">
- ローディング...
- </string>
- <string name="status_generating_meshes">
- メッシュを作成中
- </string>
- <string name="status_vertex_number_overflow">
- エラー:頂点の数が65534を超過したので中止されました。
- </string>
- <string name="bad_element">
- エラー:要素が無効です
- </string>
- <string name="high">
- 高
- </string>
- <string name="medium">
- 中
- </string>
- <string name="low">
- 低
- </string>
- <string name="lowest">
- 最低
- </string>
- <string name="mesh_status_good">
- 発送
- </string>
- <string name="mesh_status_na">
- 該当なし
- </string>
- <string name="mesh_status_none">
- なし
- </string>
- <string name="mesh_status_submesh_mismatch">
- テクスチャ編集可能な面の数は描画詳細度に応じて異なります。
- </string>
- <string name="mesh_status_mesh_mismatch">
- メッシュインスタンスの数は描画詳細度に応じて異なります。
- </string>
- <string name="mesh_status_too_many_vertices">
- 描画詳細度に対して頂点の数が多すぎます。
- </string>
- <string name="mesh_status_missing_lod">
- 必要な描画詳細度が見つかりません。
- </string>
- <string name="layer_all">
- 全て
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/ja/notifications.xml b/indra/newview/skins/default/xui/ja/notifications.xml
index 54031ccf12..7bf8a7b8be 100644
--- a/indra/newview/skins/default/xui/ja/notifications.xml
+++ b/indra/newview/skins/default/xui/ja/notifications.xml
@@ -2895,6 +2895,18 @@ M キーを押して変更します。
[RESIDENTS]
<usetemplate name="okcancelbuttons" notext="取り消し" yestext="Ok"/>
</notification>
+ <notification name="ShareFolderConfirmation">
+ フォルダは一度に 1 つしか共有できません。
+
+次のアイテムを共有しますか?
+
+&lt;nolink&gt;[ITEMS]&lt;/nolink&gt;
+
+次の住人と共有:
+
+[RESIDENTS]
+ <usetemplate name="okcancelbuttons" notext="取り消し" yestext="Ok"/>
+ </notification>
<notification name="ItemsShared">
アイテムが共有されました。
</notification>
diff --git a/indra/newview/skins/default/xui/pt/floater_model_wizard.xml b/indra/newview/skins/default/xui/pt/floater_model_wizard.xml
deleted file mode 100644
index 0d07303c91..0000000000
--- a/indra/newview/skins/default/xui/pt/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="CARREGAR ASSISTENTE DE MODELAGEM">
- <button label="5. Carregar" name="upload_btn"/>
- <button label="4. Revisar" name="review_btn"/>
- <button label="3. Física" name="physics_btn"/>
- <button label="2. Otimizar" name="optimize_btn"/>
- <button label="1. Selecionra arquivo" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Escolher arquivo de modelo
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Usuários avançados: se você estiver familiarizado com ferramentas de criação de conteúdo 3D, use o Advanced Uploader.
- </text>
- <button label="Trocar para avançado" name="switch_to_advanced"/>
- <text name="Cache location">
- Escolha o arquivo de modelo para upload
- </text>
- <button label="Procurar..." label_selected="Procurar..." name="browse"/>
- <text name="Model types">
- O Second Life oferece suporte a arquivos COLLADA (.dae)
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- AVISO:
- </text>
- <text name="warning_text">
- Não será possível concluir a etapa final do upload desse modelo para os servidores do Second Life. [secondlife:///app/floater/learn_more Saiba como] configurar sua conta para uploads de modelos mesh.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Otimizar modelo
- </text>
- </panel>
- <text name="optimize_description">
- O modelo foi ajustado para desempenho. Faça novos ajustes, se desejar.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Gerar nível de detalhes: Alto
- </text>
- <text name="medium_detail_text">
- Gerar nível de detalhes: Médio
- </text>
- <text name="low_detail_text">
- Gerar nível de detalhes: Baixo
- </text>
- <text name="lowest_detail_text">
- Gerar nível de detalhes: Mais baixo
- </text>
- </panel>
- <panel name="content2">
- <button label="Recalcular geometria" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Visualização da geometria
- </text>
- <combo_box name="preview_lod_combo" tool_tip="LOD para exibir na renderização de visualização">
- <combo_item name="high">
- Máximo de detalhes
- </combo_item>
- <combo_item name="medium">
- Detalhes médios
- </combo_item>
- <combo_item name="low">
- Poucos detalhes
- </combo_item>
- <combo_item name="lowest">
- Mínimo de detalhes
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Ajustar físico
- </text>
- </panel>
- <text name="physics_description">
- Criaremos uma forma para o corpo externo do modelo. Ajuste o nível de detalhes como necessário para a finalidade desejada de seu modelo.
- </text>
- <panel name="physics_content">
- <button label="Recalcular físico" name="recalculate_physics_btn"/>
- <button label="Recalculando..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Visualização do físico
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="LOD para exibir na renderização de visualização">
- <combo_item name="high">
- Máximo de detalhes
- </combo_item>
- <combo_item name="medium">
- Detalhes médios
- </combo_item>
- <combo_item name="low">
- Poucos detalhes
- </combo_item>
- <combo_item name="lowest">
- Mínimo de detalhes
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Revisar
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Impacto no lote/região: [EQUIV] equivalentes de prim
- </text>
- <text name="review_fee">
- Uma tarifa de upload de L$ [FEE] será debitada da sua conta.
- </text>
- <text name="review_confirmation">
- Ao clicar no botão de upload, você confirma que detém os direitos apropriados sobre o material contido no modelo.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Upload concluído
- </text>
- </panel>
- <text name="model_uploaded_text">
- Seu modelo foi carregado.
- </text>
- <text name="inventory_text">
- Disponível na pasta Objetos do seu inventário.
- </text>
- <text name="charged_fee">
- L$ [FEE] foram debitados da sua conta.
- </text>
- </panel>
- <button label="&lt;&lt; Voltar" name="back"/>
- <button label="Próximo &gt;&gt;" name="next"/>
- <button label="Calcular pesos e tarifa &gt;&gt;" name="calculate"/>
- <button label="Calculando..." name="calculating"/>
- <button label="Carregar" name="upload" tool_tip="Carregar no simulador"/>
- <button label="Cancelar" name="cancel"/>
- <button label="Fechar" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Inativo
- </string>
- <string name="status_parse_error">
- Dae parsing - erro, detalhes no log.
- </string>
- <string name="status_reading_file">
- Carregando...
- </string>
- <string name="status_generating_meshes">
- Gerando meshes...
- </string>
- <string name="status_vertex_number_overflow">
- Erro: Número de Vertex acima de 65534. Abortado.
- </string>
- <string name="bad_element">
- Erro: elemento inválido
- </string>
- <string name="high">
- Alto
- </string>
- <string name="medium">
- Médio
- </string>
- <string name="low">
- Baixo
- </string>
- <string name="lowest">
- Mais baixo
- </string>
- <string name="mesh_status_good">
- Entregar!
- </string>
- <string name="mesh_status_na">
- N/D
- </string>
- <string name="mesh_status_none">
- Nenhum
- </string>
- <string name="mesh_status_submesh_mismatch">
- Cada nível de detalhamento têm um número de faces para textura.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Cada nível de detalhamento têm um número de faces para textura.
- </string>
- <string name="mesh_status_too_many_vertices">
- O nível de detalhamento possui vértices demais.
- </string>
- <string name="mesh_status_missing_lod">
- Falta o nível de detalhamento necessário.
- </string>
- <string name="layer_all">
- Tudo
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/pt/menu_viewer.xml b/indra/newview/skins/default/xui/pt/menu_viewer.xml
index d7d5d59a33..fd973bf3c2 100644
--- a/indra/newview/skins/default/xui/pt/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/pt/menu_viewer.xml
@@ -118,7 +118,7 @@
<menu_item_call label="Devolver objeto" name="Return Object back to Owner"/>
</menu>
<menu label="Scripts" name="Scripts">
- <menu_item_call label="Recompilar scripts (LSL)" name="Mono"/>
+ <menu_item_call label="Recompilar scripts (Mono)" name="Mono"/>
<menu_item_call label="Recompilar scripts (LSL)" name="LSL"/>
<menu_item_call label="Resetar scripts" name="Reset Scripts"/>
<menu_item_call label="Scripts em modo execução" name="Set Scripts to Running"/>
@@ -163,7 +163,7 @@
<menu_item_check label="Limitar distância da seleção" name="Limit Select Distance"/>
<menu_item_check label="Disable Camera Constraints" name="Disable Camera Distance"/>
<menu_item_check label="Foto de alta resolução" name="HighResSnapshot"/>
- <menu_item_check label="Compactar fotos para HD" name="QuietSnapshotsToDisk"/>
+ <menu_item_check label="Fotos sem barulho para HD" name="QuietSnapshotsToDisk"/>
<menu label="Ferramentas de desempenho" name="Performance Tools">
<menu_item_call label="Medidor de lag" name="Lag Meter"/>
<menu_item_check label="Barra de estatísticas" name="Statistics Bar"/>
diff --git a/indra/newview/skins/default/xui/ru/floater_model_wizard.xml b/indra/newview/skins/default/xui/ru/floater_model_wizard.xml
deleted file mode 100644
index c1a63bf7da..0000000000
--- a/indra/newview/skins/default/xui/ru/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="ПЕРЕДАТЬ МАСТЕР МОДЕЛИРОВАНИЯ">
- <button label="5. Передать" name="upload_btn"/>
- <button label="4. Просмотр" name="review_btn"/>
- <button label="3. Физика" name="physics_btn"/>
- <button label="2. Оптимизировать" name="optimize_btn"/>
- <button label="1. Выбрать файл" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Выберите файл модели
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Пользователям, работающим в расширенном режиме: если вы умеете создавать трехмерные графические объекты, то, возможно, захотите воспользоваться средством Advanced Uploader, которое предоставляет расширенные возможности передачи объектов.
- </text>
- <button label="Перейти в расширенный режим" name="switch_to_advanced"/>
- <text name="Cache location">
- Выберите файл модели для передачи
- </text>
- <button label="Обзор..." label_selected="Обзор..." name="browse"/>
- <text name="Model types">
- В Second Life поддерживаются файлы COLLADA (.dae)
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- ВНИМАНИЕ!
- </text>
- <text name="warning_text">
- Вы не сможете завершить передачу этой модели на серверы Second Life. [secondlife:///app/floater/learn_more Узнайте, как] настроить в вашем аккаунте передачу сеточных моделей.
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Оптимизировать модель
- </text>
- </panel>
- <text name="optimize_description">
- Мы оптимизировали модель для повышения быстродействия. По желанию можно выполнить дополнительную настройку.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Создать уровень детализации: Высокий
- </text>
- <text name="medium_detail_text">
- Создать уровень детализации: Средний
- </text>
- <text name="low_detail_text">
- Создать уровень детализации: Низкий
- </text>
- <text name="lowest_detail_text">
- Создать уровень детализации: Самый низкий
- </text>
- </panel>
- <panel name="content2">
- <button label="Пересчитать геометрию" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Просмотр геометрии
- </text>
- <combo_box name="preview_lod_combo" tool_tip="Детализация при предварительном просмотре">
- <combo_item name="high">
- Детально
- </combo_item>
- <combo_item name="medium">
- Средняя детализация
- </combo_item>
- <combo_item name="low">
- Мало деталей
- </combo_item>
- <combo_item name="lowest">
- Минимум деталей
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Настроить физические параметры
- </text>
- </panel>
- <text name="physics_description">
- Мы создадим форму для внешнего каркаса модели. Настройте уровень детализации формы в соответствии с целями, для которых предназначена модель.
- </text>
- <panel name="physics_content">
- <button label="Пересчитать физические данные" name="recalculate_physics_btn"/>
- <button label="Пересчет..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Просмотр физических данных
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="Уровень детализации при предварительном просмотре">
- <combo_item name="high">
- Детально
- </combo_item>
- <combo_item name="medium">
- Средняя детализация
- </combo_item>
- <combo_item name="low">
- Мало деталей
- </combo_item>
- <combo_item name="lowest">
- Минимум деталей
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- Просмотр
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Воздействие на участок/регион: эквивалент в примитивах: [EQUIV]
- </text>
- <text name="review_fee">
- За передачу с вашего счета будет снята плата в размере L$[FEE].
- </text>
- <text name="review_confirmation">
- Нажав кнопку «Передать», вы подтверждаете, что у вас есть надлежащие права на все составляющие модели.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Передача завершена
- </text>
- </panel>
- <text name="model_uploaded_text">
- Ваша модель передана.
- </text>
- <text name="inventory_text">
- Находится в папке «Объекты» вашего инвентаря.
- </text>
- <text name="charged_fee">
- С вашего счета снято: L$[FEE].
- </text>
- </panel>
- <button label="&lt;&lt; Назад" name="back"/>
- <button label="Далее &gt;&gt;" name="next"/>
- <button label="Рассчитать вес и плату &gt;&gt;" name="calculate"/>
- <button label="Расчет..." name="calculating"/>
- <button label="Передать" name="upload" tool_tip="Передать в симулятор"/>
- <button label="Отмена" name="cancel"/>
- <button label="Закрыть" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Неактивно
- </string>
- <string name="status_parse_error">
- Проблема при анализе файла DAE – см. подробности в журнале.
- </string>
- <string name="status_reading_file">
- Загрузка...
- </string>
- <string name="status_generating_meshes">
- Создаются меши...
- </string>
- <string name="status_vertex_number_overflow">
- Ошибка. Число вершин превышает 65534. Прервано.
- </string>
- <string name="bad_element">
- Ошибка: недопустимый элемент
- </string>
- <string name="high">
- высокий
- </string>
- <string name="medium">
- средний
- </string>
- <string name="low">
- низкий
- </string>
- <string name="lowest">
- самый низкий
- </string>
- <string name="mesh_status_good">
- Доставлено!
- </string>
- <string name="mesh_status_na">
- Н/Д
- </string>
- <string name="mesh_status_none">
- Нет
- </string>
- <string name="mesh_status_submesh_mismatch">
- Отличается число текстурируемых граней на уровнях детализации.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Отличается число экземпляров меша на уровнях детализации.
- </string>
- <string name="mesh_status_too_many_vertices">
- Слишком много вершин на уровне детализации.
- </string>
- <string name="mesh_status_missing_lod">
- Отсутствует необходимый уровень детализации.
- </string>
- <string name="layer_all">
- Все
- </string>
-</floater>
diff --git a/indra/newview/skins/default/xui/tr/floater_model_wizard.xml b/indra/newview/skins/default/xui/tr/floater_model_wizard.xml
deleted file mode 100644
index 9d8b982c24..0000000000
--- a/indra/newview/skins/default/xui/tr/floater_model_wizard.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<floater name="Model Wizard" title="KARŞIYA MODEL YÜKLEME SİHİRBAZI">
- <button label="5. Karşıya Yükle" name="upload_btn"/>
- <button label="4. İncele" name="review_btn"/>
- <button label="3. Fizik" name="physics_btn"/>
- <button label="2. Optimize et" name="optimize_btn"/>
- <button label="1. Dosya Seç" name="choose_file_btn"/>
- <panel name="choose_file_panel">
- <panel name="choose_file_header_panel">
- <text name="choose_file_header_text">
- Model dosyasını seçin
- </text>
- </panel>
- <panel name="choose_file_content">
- <text name="advanced_users_text">
- Gelişmiş kullanıcılar: Eğer 3B içerik oluşturma araçlarını kullanmayı biliyorsanız, Gelişmiş Karşıya Yükleyiciyi kullanmak isteyebilirsiniz.
- </text>
- <button label="Gelişmişe geç" name="switch_to_advanced"/>
- <text name="Cache location">
- Karşıya yüklenecek model dosyasını seçin
- </text>
- <button label="Gözat..." label_selected="Gözat..." name="browse"/>
- <text name="Model types">
- Second Life, COLLADA (.dae) dosyalarını destekler
- </text>
- <text name="dimensions">
- X Y Z
- </text>
- <text name="warning_label">
- UYARI:
- </text>
- <text name="warning_text">
- Bu modelin Second Life sunucularına nihai karşıya yükleme adımını tamamlayamayacaksınız. Hesabınızı örgü modellerinin karşıya yüklenmesi için ayarlamanın [secondlife:///app/floater/learn_more nasıl yapılacağını öğrenin].
- </text>
- </panel>
- </panel>
- <panel name="optimize_panel">
- <panel name="optimize_header_panel">
- <text name="optimize_header_text">
- Modeli optimize et
- </text>
- </panel>
- <text name="optimize_description">
- Modeli performans için optimize ettik. İstiyorsanız daha da ayarlayabilirsiniz.
- </text>
- <panel name="optimize_content">
- <text name="high_detail_text">
- Ayrıntı Seviyesi Oluştur: Yüksek
- </text>
- <text name="medium_detail_text">
- Ayrıntı Seviyesi Oluştur: Orta
- </text>
- <text name="low_detail_text">
- Ayrıntı Seviyesi Oluştur: Düşük
- </text>
- <text name="lowest_detail_text">
- Ayrıntı Seviyesi Oluştur: En Düşük
- </text>
- </panel>
- <panel name="content2">
- <button label="Geometri hesaplarını tekrar yap" name="recalculate_geometry_btn"/>
- <text name="lod_label">
- Geometri önizleme
- </text>
- <combo_box name="preview_lod_combo" tool_tip="Önizleme işlemesinde görülecek ayrıntı seviyesi">
- <combo_item name="high">
- Çok ayrıntı
- </combo_item>
- <combo_item name="medium">
- Orta düzey ayrıntı
- </combo_item>
- <combo_item name="low">
- Az ayrıntı
- </combo_item>
- <combo_item name="lowest">
- En az ayrıntı
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="physics_panel">
- <panel name="physics_header_panel">
- <text name="physics_header_text">
- Fizik ayarlarını yap
- </text>
- </panel>
- <text name="physics_description">
- Modelin dış gövdesi için bir şekil oluşturacağız. Modelinizin amacına uygun olarak şeklin ayrıntı seviyesini belirleyin.
- </text>
- <panel name="physics_content">
- <button label="Fizik hesaplarını tekrar yap" name="recalculate_physics_btn"/>
- <button label="Tekrar hesaplanıyor..." name="recalculating_physics_btn"/>
- <text name="lod_label">
- Fizik önizleme
- </text>
- <combo_box name="preview_lod_combo2" tool_tip="Önizleme işlemesinde görülecek ayrıntı seviyesi">
- <combo_item name="high">
- Çok ayrıntı
- </combo_item>
- <combo_item name="medium">
- Orta düzey ayrıntı
- </combo_item>
- <combo_item name="low">
- Az ayrıntı
- </combo_item>
- <combo_item name="lowest">
- En az ayrıntı
- </combo_item>
- </combo_box>
- </panel>
- </panel>
- <panel name="review_panel">
- <panel name="review_header_panel">
- <text name="review_header_text">
- İncele
- </text>
- </panel>
- <panel name="review_content">
- <text name="review_prim_equiv">
- Parsele/bölgeye etkisi: [EQUIV] prim eşdeğerleri
- </text>
- <text name="review_fee">
- Hesabınızdan L$ [FEE] karşıya yükleme ücreti düşülecektir.
- </text>
- <text name="review_confirmation">
- Karşıya yükleme düğmesine tıkladığınızda, modelde yer alan malzeme için ilgili haklara sahip olduğunuzu teyid edersiniz.
- </text>
- </panel>
- </panel>
- <panel name="upload_panel">
- <panel name="upload_header_panel">
- <text name="upload_header_text">
- Karşıya yükleme bitti
- </text>
- </panel>
- <text name="model_uploaded_text">
- Modeliniz karşıya yüklendi.
- </text>
- <text name="inventory_text">
- Bunu, envanterinizdeki Nesneler klasöründe bulacaksınız.
- </text>
- <text name="charged_fee">
- Hesabınızdan L$ [FEE] düşüldü.
- </text>
- </panel>
- <button label="&lt;&lt; Geri" name="back"/>
- <button label="Sonraki &gt;&gt;" name="next"/>
- <button label="Ağırlıkları ve ücreti hesapla &gt;&gt;" name="calculate"/>
- <button label="Hesaplanıyor..." name="calculating"/>
- <button label="Karşıya Yükle" name="upload" tool_tip="Simülatöre karşıya yükle"/>
- <button label="İptal" name="cancel"/>
- <button label="Kapat" name="close"/>
- <spinner name="import_scale" value="1.0"/>
- <string name="status_idle">
- Boşta
- </string>
- <string name="status_parse_error">
- Dae ayrıştırma sorunu - ayrıntılar için günlüğe bakın.
- </string>
- <string name="status_reading_file">
- Yükleniyor...
- </string>
- <string name="status_generating_meshes">
- Örgüler Oluşturuluyor...
- </string>
- <string name="status_vertex_number_overflow">
- Hata: Köşe numarası 65534&apos;ten fazla, işlem durduruldu!
- </string>
- <string name="bad_element">
- Hata: Öğe geçersiz
- </string>
- <string name="high">
- Yüksek
- </string>
- <string name="medium">
- Orta
- </string>
- <string name="low">
- Düşük
- </string>
- <string name="lowest">
- En Düşük
- </string>
- <string name="mesh_status_good">
- Uygula!
- </string>
- <string name="mesh_status_na">
- G/D
- </string>
- <string name="mesh_status_none">
- Hiçbiri
- </string>
- <string name="mesh_status_submesh_mismatch">
- Ayrıntı seviyelerinde farklı sayıda dokulanabilir yüz var.
- </string>
- <string name="mesh_status_mesh_mismatch">
- Ayrıntı seviyelerinde farklı sayıda örgü örneği var.
- </string>
- <string name="mesh_status_too_many_vertices">
- Ayrıntı seviyesinde fazla sayıda köşe var.
- </string>
- <string name="mesh_status_missing_lod">
- Gereken ayrıntı seviyesi eksik.
- </string>
- <string name="layer_all">
- Tümü
- </string>
-</floater>
diff --git a/indra/newview/tests/llviewerassetstats_test.cpp b/indra/newview/tests/llviewerassetstats_test.cpp
index 3faddc13c1..f8923b9868 100644
--- a/indra/newview/tests/llviewerassetstats_test.cpp
+++ b/indra/newview/tests/llviewerassetstats_test.cpp
@@ -35,6 +35,31 @@
#include "lluuid.h"
#include "llsdutil.h"
#include "llregionhandle.h"
+#include "../llvoavatar.h"
+
+void LLVOAvatar::getNearbyRezzedStats(std::vector<S32>& counts)
+{
+ counts.resize(3);
+ counts[0] = 0;
+ counts[1] = 0;
+ counts[2] = 1;
+}
+
+// static
+std::string LLVOAvatar::rezStatusToString(S32 rez_status)
+{
+ if (rez_status==0) return "cloud";
+ if (rez_status==1) return "gray";
+ if (rez_status==2) return "textured";
+ return "unknown";
+}
+
+// static
+LLViewerStats::StatsAccumulator& LLViewerStats::PhaseMap::getPhaseStats(const std::string& phase_name)
+{
+ static LLViewerStats::StatsAccumulator junk;
+ return junk;
+}
static const char * all_keys[] =
{
@@ -104,18 +129,25 @@ is_single_key_map(const LLSD & sd, const std::string & key)
{
return sd.isMap() && 1 == sd.size() && sd.has(key);
}
-#endif
static bool
is_double_key_map(const LLSD & sd, const std::string & key1, const std::string & key2)
{
return sd.isMap() && 2 == sd.size() && sd.has(key1) && sd.has(key2);
}
+#endif
+
+static bool
+is_triple_key_map(const LLSD & sd, const std::string & key1, const std::string & key2, const std::string& key3)
+{
+ return sd.isMap() && 3 == sd.size() && sd.has(key1) && sd.has(key2) && sd.has(key3);
+}
+
static bool
is_no_stats_map(const LLSD & sd)
{
- return is_double_key_map(sd, "duration", "regions");
+ return is_triple_key_map(sd, "duration", "regions", "avatar");
}
static bool
@@ -226,7 +258,7 @@ namespace tut
// Once the region is set, we will get a response even with no data collection
it->setRegion(region1_handle);
sd_full = it->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd_full, "duration", "regions"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd_full, "duration", "regions", "avatar"));
ensure("Correct single-slot LLSD array regions", is_single_slot_array(sd_full["regions"], region1_handle));
LLSD sd = sd_full["regions"][0];
@@ -267,7 +299,7 @@ namespace tut
it->setRegion(region1_handle);
LLSD sd = it->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "regions", "duration"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "regions", "duration", "avatar"));
ensure("Correct single-slot LLSD array regions", is_single_slot_array(sd["regions"], region1_handle));
sd = sd[0];
@@ -292,7 +324,7 @@ namespace tut
LLViewerAssetStatsFF::record_dequeue_main(LLViewerAssetType::AT_BODYPART, false, false);
LLSD sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "regions", "duration"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "regions", "duration", "avatar"));
ensure("Correct single-slot LLSD array regions", is_single_slot_array(sd["regions"], region1_handle));
sd = sd["regions"][0];
@@ -332,7 +364,7 @@ namespace tut
LLSD sd = gViewerAssetStatsThread1->asLLSD(false);
ensure("Other collector is empty", is_no_stats_map(sd));
sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "regions", "duration"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "regions", "duration", "avatar"));
ensure("Correct single-slot LLSD array regions", is_single_slot_array(sd["regions"], region1_handle));
sd = sd["regions"][0];
@@ -382,7 +414,7 @@ namespace tut
// std::cout << sd << std::endl;
- ensure("Correct double-key LLSD map root", is_double_key_map(sd, "duration", "regions"));
+ ensure("Correct double-key LLSD map root", is_triple_key_map(sd, "duration", "regions", "avatar"));
ensure("Correct double-slot LLSD array regions", is_double_slot_array(sd["regions"], region1_handle, region2_handle));
LLSD sd1 = get_region(sd, region1_handle);
LLSD sd2 = get_region(sd, region2_handle);
@@ -405,7 +437,7 @@ namespace tut
// Reset leaves current region in place
gViewerAssetStatsMain->reset();
sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "regions", "duration"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "regions", "duration", "avatar"));
ensure("Correct single-slot LLSD array regions (p2)", is_single_slot_array(sd["regions"], region2_handle));
sd2 = sd["regions"][0];
@@ -454,7 +486,7 @@ namespace tut
LLSD sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct double-key LLSD map root", is_double_key_map(sd, "duration", "regions"));
+ ensure("Correct double-key LLSD map root", is_triple_key_map(sd, "duration", "regions", "avatar"));
ensure("Correct double-slot LLSD array regions", is_double_slot_array(sd["regions"], region1_handle, region2_handle));
LLSD sd1 = get_region(sd, region1_handle);
LLSD sd2 = get_region(sd, region2_handle);
@@ -477,7 +509,7 @@ namespace tut
// Reset leaves current region in place
gViewerAssetStatsMain->reset();
sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "duration", "regions"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "duration", "regions", "avatar"));
ensure("Correct single-slot LLSD array regions (p2)", is_single_slot_array(sd["regions"], region2_handle));
sd2 = get_region(sd, region2_handle);
ensure("Region2 is present in results", sd2.isMap());
@@ -523,7 +555,7 @@ namespace tut
LLSD sd = gViewerAssetStatsThread1->asLLSD(false);
ensure("Other collector is empty", is_no_stats_map(sd));
sd = gViewerAssetStatsMain->asLLSD(false);
- ensure("Correct single-key LLSD map root", is_double_key_map(sd, "regions", "duration"));
+ ensure("Correct single-key LLSD map root", is_triple_key_map(sd, "regions", "duration", "avatar"));
ensure("Correct single-slot LLSD array regions", is_single_slot_array(sd["regions"], region1_handle));
sd = get_region(sd, region1_handle);
ensure("Region1 is present in results", sd.isMap());
diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py
index 9bf755c8f8..36267803e3 100644
--- a/indra/newview/viewer_manifest.py
+++ b/indra/newview/viewer_manifest.py
@@ -1025,45 +1025,47 @@ class Linux_i686Manifest(LinuxManifest):
super(Linux_i686Manifest, self).construct()
if self.prefix("../packages/lib/release", dst="lib"):
- self.path("libapr-1.so")
- self.path("libapr-1.so.0")
- self.path("libapr-1.so.0.4.2")
- self.path("libaprutil-1.so")
- self.path("libaprutil-1.so.0")
- self.path("libaprutil-1.so.0.3.10")
- self.path("libbreakpad_client.so.0.0.0")
- self.path("libbreakpad_client.so.0")
- self.path("libbreakpad_client.so")
+ self.path("libapr-1.so*")
+ self.path("libaprutil-1.so*")
+ self.path("libbreakpad_client.so*")
self.path("libcollada14dom.so")
- self.path("libdb-5.1.so")
- self.path("libdb-5.so")
- self.path("libdb.so")
- self.path("libcrypto.so.1.0.0")
- self.path("libexpat.so.1.5.2")
+ self.path("libdb*.so")
+ self.path("libcrypto.so.*")
+ self.path("libexpat.so.*")
self.path("libssl.so.1.0.0")
self.path("libglod.so")
self.path("libminizip.so")
- self.path("libuuid.so")
- self.path("libuuid.so.16")
- self.path("libuuid.so.16.0.22")
- self.path("libSDL-1.2.so.0.11.3")
- self.path("libSDL-1.2.so.0")
- self.path("libdirectfb-1.4.so.5.0.4")
+ self.path("libuuid.so*")
+ self.path("libSDL-1.2.so.*")
+ self.path("libdirectfb-1.*.so.*")
+ self.path("libfusion-1.*.so.*")
+ self.path("libdirect-1.*.so.*")
+ self.path("libopenjpeg.so*")
self.path("libdirectfb-1.4.so.5")
- self.path("libfusion-1.4.so.5.0.4")
self.path("libfusion-1.4.so.5")
- self.path("libdirect-1.4.so.5.0.4")
self.path("libdirect-1.4.so.5")
- self.path("libopenjpeg.so.1.4.0")
- self.path("libopenjpeg.so.1")
- self.path("libopenjpeg.so")
self.path("libalut.so")
self.path("libopenal.so", "libopenal.so.1")
self.path("libopenal.so", "libvivoxoal.so.1") # vivox's sdk expects this soname
- self.path("libfontconfig.so.1.4.4")
- self.path("libtcmalloc.so", "libtcmalloc.so") #formerly called google perf tools
- self.path("libtcmalloc.so.0", "libtcmalloc.so.0") #formerly called google perf tools
- self.path("libtcmalloc.so.0.1.0", "libtcmalloc.so.0.1.0") #formerly called google perf tools
+ # KLUDGE: As of 2012-04-11, the 'fontconfig' package installs
+ # libfontconfig.so.1.4.4, along with symlinks libfontconfig.so.1
+ # and libfontconfig.so. Before we added support for library-file
+ # wildcards, though, this self.path() call specifically named
+ # libfontconfig.so.1.4.4 WITHOUT also copying the symlinks. When I
+ # (nat) changed the call to self.path("libfontconfig.so.*"), we
+ # ended up with the libfontconfig.so.1 symlink in the target
+ # directory as well. But guess what! At least on Ubuntu 10.04,
+ # certain viewer fonts look terrible with libfontconfig.so.1
+ # present in the target directory. Removing that symlink suffices
+ # to improve them. I suspect that means we actually do better when
+ # the viewer fails to find our packaged libfontconfig.so*, falling
+ # back on the system one instead -- but diagnosing and fixing that
+ # is a bit out of scope for the present project. Meanwhile, this
+ # particular wildcard specification gets us exactly what the
+ # previous call did, without having to explicitly state the
+ # version number.
+ self.path("libfontconfig.so.*.*")
+ self.path("libtcmalloc.so*") #formerly called google perf tools
try:
self.path("libfmod-3.75.so")
pass