diff options
author | Loren Shih <seraph@lindenlab.com> | 2011-03-16 14:54:56 -0400 |
---|---|---|
committer | Loren Shih <seraph@lindenlab.com> | 2011-03-16 14:54:56 -0400 |
commit | 037a83cd47e016f70092bccfdb2c13e759c6ff0a (patch) | |
tree | 2183c8ef1364d5f4e784cb91ea4d67b1861b2452 /indra/newview | |
parent | 15b0509c01dbeec6854f4a0a5965e900eda06de1 (diff) | |
parent | 742dd75751f65224d80eb4f7d20daf5a21776c5f (diff) |
Automated merge up from viewer-development into mesh-development
Diffstat (limited to 'indra/newview')
511 files changed, 22425 insertions, 11519 deletions
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 290e8ebbe0..cb0f1c2907 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -255,6 +255,7 @@ set(viewer_SOURCE_FILES llhudeffectlookat.cpp llhudeffectpointat.cpp llhudeffecttrail.cpp + llhudeffectblob.cpp llhudicon.cpp llhudmanager.cpp llhudnametag.cpp @@ -801,6 +802,7 @@ set(viewer_HEADER_FILES llhudeffectlookat.h llhudeffectpointat.h llhudeffecttrail.h + llhudeffectblob.h llhudicon.h llhudmanager.h llhudnametag.h @@ -1316,22 +1318,20 @@ endif (WINDOWS) set(viewer_XUI_FILES skins/default/colors.xml skins/default/textures/textures.xml + skins/minimal/colors.xml + skins/minimal/textures/textures.xml ) file(GLOB DEFAULT_XUI_FILE_GLOB_LIST - ${CMAKE_CURRENT_SOURCE_DIR}/skins/default/xui/en/*.xml) + ${CMAKE_CURRENT_SOURCE_DIR}/skins/*/xui/en/*.xml) list(APPEND viewer_XUI_FILES ${DEFAULT_XUI_FILE_GLOB_LIST}) file(GLOB DEFAULT_WIDGET_FILE_GLOB_LIST - ${CMAKE_CURRENT_SOURCE_DIR}/skins/default/xui/en/widgets/*.xml) + ${CMAKE_CURRENT_SOURCE_DIR}/skins/*/xui/en/widgets/*.xml) list(APPEND viewer_XUI_FILES ${DEFAULT_WIDGET_FILE_GLOB_LIST}) -file(GLOB SILVER_XUI_FILE_GLOB_LIST - ${CMAKE_CURRENT_SOURCE_DIR}/skins/silver/xui/en-us/*.xml) -list(APPEND viewer_XUI_FILES ${SILVER_XUI_FILE_GLOB_LIST}) - # Cannot append empty lists in CMake, wait until we have files here. #file(GLOB SILVER_WIDGET_FILE_GLOB_LIST # ${CMAKE_CURRENT_SOURCE_DIR}/skins/silver/xui/en-us/widgets/*.xml) @@ -1361,6 +1361,7 @@ set(viewer_APPSETTINGS_FILES app_settings/settings_crash_behavior.xml app_settings/settings_files.xml app_settings/settings_per_account.xml + app_settings/settings_minimal.xml app_settings/std_bump.ini app_settings/trees.xml app_settings/ultra_graphics.xml diff --git a/indra/newview/app_settings/CA.pem b/indra/newview/app_settings/CA.pem index 11825bf906..7cebbf48b2 100644 --- a/indra/newview/app_settings/CA.pem +++ b/indra/newview/app_settings/CA.pem @@ -3895,3 +3895,22 @@ xA39CIJ65Zozs28Eg1aV9/Y+Of7TnWhW+U3J3/wD/GghaAGiKK6vMn9gJBIdBX/9 e6ef37VGyiOEFFjnUIbuk0RWty0orN76q/lI/xjCi15XSA/VSq2j4vmnwfZcPTDu glmQ1A== -----END CERTIFICATE----- +-----BEGIN CERTIFICATE----- +MIIDIDCCAomgAwIBAgIENd70zzANBgkqhkiG9w0BAQUFADBOMQswCQYDVQQGEwJV +UzEQMA4GA1UEChMHRXF1aWZheDEtMCsGA1UECxMkRXF1aWZheCBTZWN1cmUgQ2Vy +dGlmaWNhdGUgQXV0aG9yaXR5MB4XDTk4MDgyMjE2NDE1MVoXDTE4MDgyMjE2NDE1 +MVowTjELMAkGA1UEBhMCVVMxEDAOBgNVBAoTB0VxdWlmYXgxLTArBgNVBAsTJEVx +dWlmYXggU2VjdXJlIENlcnRpZmljYXRlIEF1dGhvcml0eTCBnzANBgkqhkiG9w0B +AQEFAAOBjQAwgYkCgYEAwV2xWGcIYu6gmi0fCG2RFGiYCh7+2gRvE4RiIcPRfM6f +BeC4AfBONOziipUEZKzxa1NfBbPLZ4C/QgKO/t0BCezhABRP/PvwDN1Dulsr4R+A +cJkVV5MW8Q+XarfCaCMczE1ZMKxRHjuvK9buY0V7xdlfUNLjUA86iOe/FP3gx7kC +AwEAAaOCAQkwggEFMHAGA1UdHwRpMGcwZaBjoGGkXzBdMQswCQYDVQQGEwJVUzEQ +MA4GA1UEChMHRXF1aWZheDEtMCsGA1UECxMkRXF1aWZheCBTZWN1cmUgQ2VydGlm +aWNhdGUgQXV0aG9yaXR5MQ0wCwYDVQQDEwRDUkwxMBoGA1UdEAQTMBGBDzIwMTgw +ODIyMTY0MTUxWjALBgNVHQ8EBAMCAQYwHwYDVR0jBBgwFoAUSOZo+SvSspXXR9gj +IBBPM5iQn9QwHQYDVR0OBBYEFEjmaPkr0rKV10fYIyAQTzOYkJ/UMAwGA1UdEwQF +MAMBAf8wGgYJKoZIhvZ9B0EABA0wCxsFVjMuMGMDAgbAMA0GCSqGSIb3DQEBBQUA +A4GBAFjOKer89961zgK5F7WF0bnj4JXMJTENAKaSbn+2kmOeUJXRmm/kEd5jhW6Y +7qj/WsjTVbJmcVfewCHrPSqnI0kBBIZCe/zuf6IWUrVnZ9NA2zsmWLIodz2uFHdh +1voqZiegDfqnc1zqcPGUIWVEX/r87yloqaKHee9570+sB3c4 +-----END CERTIFICATE----- diff --git a/indra/newview/app_settings/cmd_line.xml b/indra/newview/app_settings/cmd_line.xml index e4ac455e7c..89e5949fbe 100644 --- a/indra/newview/app_settings/cmd_line.xml +++ b/indra/newview/app_settings/cmd_line.xml @@ -261,6 +261,24 @@ <!-- Special case. Mapped to settings procedurally. --> </map> + <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> + <!-- Special case. Mapped to settings procedurally. --> + </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> <map> <key>desc</key> diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index d0c62817e5..92a3a0299a 100755 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -617,7 +617,7 @@ <key>Type</key> <string>String</string> <key>Value</key> - <string>http://interest.secondlife.com/viewer/avatar</string> + <string></string> </map> <key>AvatarBakedTextureUploadTimeout</key> <map> @@ -2638,7 +2638,7 @@ <key>Type</key> <string>String</string> <key>Value</key> - <string>http://www.secondlife.com</string> + <string></string> </map> <key>DisableCameraConstraints</key> <map> @@ -2882,6 +2882,17 @@ <key>Value</key> <integer>0</integer> </map> + <key>DoubleClickShowWorldMap</key> + <map> + <key>Comment</key> + <string>Enable double-click to show world map from mini map</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> <key>DragAndDropToolTipDelay</key> <map> <key>Comment</key> @@ -3960,6 +3971,17 @@ <key>Value</key> <string>https://my.secondlife.com/[AGENT_NAME]</string> </map> + <key>WebProfileNonProductionURL</key> + <map> + <key>Comment</key> + <string>URL for Web Profiles on Non-Production grids</string> + <key>Persist</key> + <integer>0</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>https://my-demo.secondlife.com/[AGENT_NAME]</string> + </map> <key>HighResSnapshot</key> <map> <key>Comment</key> @@ -11910,7 +11932,7 @@ <key>Type</key> <string>F32</string> <key>Value</key> - <real>3.0</real> + <integer>3</integer> </map> <key>InterpolationPhaseOut</key> <map> @@ -11921,7 +11943,7 @@ <key>Type</key> <string>F32</string> <key>Value</key> - <real>1.0</real> + <integer>1</integer> </map> <key>VerboseLogs</key> <map> @@ -12770,38 +12792,225 @@ <key>Value</key> <real>1200.0</real> </map> - <key>AvatarPickerHintTimeout</key> + <key>SidePanelHintTimeout</key> <map> <key>Comment</key> - <string>Number of seconds to wait before telling resident about avatar picker.</string> + <string>Number of seconds to wait before telling resident about side panel.</string> <key>Persist</key> <integer>1</integer> <key>Type</key> <string>F32</string> <key>Value</key> - <real>600.0</real> + <real>300.0</real> </map> - <key>SidePanelHintTimeout</key> + <key>GroupMembersSortOrder</key> <map> <key>Comment</key> - <string>Number of seconds to wait before telling resident about side panel.</string> + <string>The order by which group members will be sorted (name|donated|online)</string> <key>Persist</key> <integer>1</integer> <key>Type</key> - <string>F32</string> + <string>String</string> <key>Value</key> - <real>300.0</real> + <string>name</string> </map> - <key>GroupMembersSortOrder</key> + <key>SessionSettingsFile</key> <map> <key>Comment</key> - <string>The order by which group members will be sorted (name|donated|online)</string> + <string>Settings that are a applied per session (not saved).</string> <key>Persist</key> <integer>1</integer> <key>Type</key> <string>String</string> <key>Value</key> - <string>name</string> + <string></string> + </map> + <key>UserSessionSettingsFile</key> + <map> + <key>Comment</key> + <string>User settings that are a applied per session (not saved).</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string /> + </map> + <key>OpenSidePanelsInFloaters</key> + <map> + <key>Comment</key> + <string>If true, will always open side panel contents in a floater.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>AvatarInspectorTooltipDelay</key> + <map> + <key>Comment</key> + <string>Seconds before displaying avatar inspector tooltip</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>0.35</real> + </map> + <key>ObjectInspectorTooltipDelay</key> + <map> + <key>Comment</key> + <string>Seconds before displaying object inspector tooltip</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>0.35</real> + </map> + <key>SLURLTeleportDirectly</key> + <map> + <key>Comment</key> + <string>Clicking on a slurl will teleport you directly instead of opening places panel</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableClassifieds</key> + <map> + <key>Comment</key> + <string>Enable creation of new classified ads from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableGroupInfo</key> + <map> + <key>Comment</key> + <string>Enable viewing and editing of group info from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnablePicks</key> + <map> + <key>Comment</key> + <string>Enable editing of picks from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableWorldMap</key> + <map> + <key>Comment</key> + <string>Enable opening world map from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableAvatarPay</key> + <map> + <key>Comment</key> + <string>Enable paying other avatars from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableVoiceCall</key> + <map> + <key>Comment</key> + <string>Enable voice calls from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableAvatarShare</key> + <map> + <key>Comment</key> + <string>Enable sharing from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>SearchFromAddressBar</key> + <map> + <key>Comment</key> + <string>Can enter search queries into navigation address bar</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>LogInventoryDecline</key> + <map> + <key>Comment</key> + <string>Log in system chat whenever an inventory offer is declined</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>UseHTTPInventory</key> + <map> + <key>Comment</key> + <string>Allow use of http inventory transfers instead of UDP</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>ClickToWalk</key> + <map> + <key>Comment</key> + <string>Click in world to walk to location</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ShowOfferedInventory</key> + <map> + <key>Comment</key> + <string>Show inventory window with last inventory offer selected when receiving inventory from other users.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> </map> </map> </llsd> diff --git a/indra/newview/app_settings/settings_files.xml b/indra/newview/app_settings/settings_files.xml index aa5b301959..079a54f957 100644 --- a/indra/newview/app_settings/settings_files.xml +++ b/indra/newview/app_settings/settings_files.xml @@ -1,148 +1,64 @@ -<llsd> - <map> - <key>Locations</key> - <map> - <!-- - The Locations LLSD block specifies the usage pattern of - the settings file types - Each location is represented by a LLSD containing the following values: - PathIndex = hard coded path indicies. - Files = map of files to load - Each file can have: - Requirement = level of necessity for loading. - 0 ( or Req. no key) = do not load - 1 = required, fail if not found - NameFromSetting = Use the given setting to specify the name. Not valid for - "Default" - --> - <key>Comment</key> - <string>List location from which to load files, and the rules about loading those files.</string> - <key>Persist</key> - <integer>0</integer> - <key>Type</key> - <string>LLSD</string> - <key>Value</key> - <map> - <key>Default</key> - <map> - <key>PathIndex</key> - <integer>2</integer> - <key>Files</key> - <map> - <key>Global</key> - <map> - <key>Name</key> - <string>settings.xml</string> - <key>Requirement</key> - <integer>1</integer> - </map> - <key>PerAccount</key> - <map> - <key>Name</key> - <string>settings_per_account.xml</string> - <key>Requirement</key> - <integer>1</integer> - </map> - <key>CrashSettings</key> - <map> - <key>Name</key> - <string>settings_crash_behavior.xml</string> - <key>Requirement</key> - <integer>1</integer> - </map> - <key>Warnings</key> - <map> - <key>Name</key> - <string>ignorable_dialogs.xml</string> - <key>Requirement</key> - <integer>1</integer> - </map> - </map> - </map> - <key>User</key> - <map> - <key>PathIndex</key> - <integer>1</integer> - <key>Files</key> - <map> - <key>Global</key> - <map> - <key>Name</key> - <string>settings.xml</string> - <key>NameFromSetting</key> - <string>ClientSettingsFile</string> - </map> - <key>CrashSettings</key> - <map> - <key>Name</key> - <string>settings_crash_behavior.xml</string> - </map> - <key>Warnings</key> - <map> - <key>Name</key> - <string>ignorable_dialogs.xml</string> - <key>NameFromSetting</key> - <string>WarningSettingsFile</string> - </map> - </map> - </map> - <key>Account</key> - <map> - <key>PathIndex</key> - <integer>3</integer> - <key>Files</key> - <map> - <key>PerAccount</key> - <map> - <key>Name</key> - <string>settings_per_account.xml</string> - <key>NameFromSetting</key> - <string>PerAccountSettingsFile</string> - </map> - </map> - </map> - <key>DefaultSkin</key> - <map> - <key>PathIndex</key> - <integer>17</integer> - <key>Files</key> - <map> - <key>Skinning</key> - <map> - <key>Name</key> - <string>colors.xml</string> - </map> - </map> - </map> - <key>CurrentSkin</key> - <map> - <key>PathIndex</key> - <integer>10</integer> - <key>Files</key> - <map> - <key>Skinning</key> - <map> - <key>Name</key> - <string>colors.xml</string> - </map> - </map> - </map> - <key>UserSkin</key> - <map> - <key>PathIndex</key> - <integer>14</integer> - <key>Files</key> - <map> - <key>Skinning</key> - <map> - <key>Name</key> - <string>colors.xml</string> - <key>NameFromSetting</key> - <string>SkinningSettingsFile</string> - </map> - </map> - </map> - </map> - </map> - </map> -</llsd> +<settings_files> + <group name="Default" + path_index="2"> + <file name="Global" + file_name="settings.xml" + required="true"/> + <file name="PerAccount" + file_name="settings_per_account.xml" + required="true"/> + <file name="CrashSettings" + file_name="settings_crash_behavior.xml" + required="true"/> + <file name="Warnings" + file_name="ignorable_dialogs.xml" + required="true"/> + </group> + <group name="User" + path_index="1"> + <file name="Global" + file_name="settings.xml" + file_name_setting="ClientSettingsFile"/> + <file name="CrashSettings" + file_name="settings_crash_behavior"/> + <file name="Warnings" + file_name="ignorable_dialogs.xml" + file_name_setting="WarningSettingsFile"/> + </group> + <group name="Account" + path_index="3"> + <file name="PerAccount" + file_name="settings_per_account.xml" + file_name_setting="PerAccountSettingsFile"/> + </group> + <group name="Session" + path_index="2"> + <file name="Global" + file_name="session.xml" + file_name_setting="SessionSettingsFile" + persistent="false"/> + </group> + <group name="UserSession" + path_index="1"> + <file name="Global" + file_name="session.xml" + file_name_setting="UserSessionSettingsFile" + persistent="false"/> + </group> + <group name="DefaultSkin" + path_index="17"> + <file name="Skinning" + file_name="colors.xml"/> + </group> + <group name="CurrentSkin" + path_index="10"> + <file name="Skinning" + file_name="colors.xml"/> + </group> + <group name="UserSkin" + path_index="14"> + <file name="Skinning" + file_name="colors.xml" + file_name_setting="SkinningSettingsFile"/> + </group> +</settings_files>
\ No newline at end of file diff --git a/indra/newview/app_settings/settings_minimal.xml b/indra/newview/app_settings/settings_minimal.xml new file mode 100644 index 0000000000..03656f2a53 --- /dev/null +++ b/indra/newview/app_settings/settings_minimal.xml @@ -0,0 +1,406 @@ +<llsd> + <map> + <key>ChannelBottomPanelMargin</key> + <map> + <key>Comment</key> + <string>Space from a lower toast to the Bottom Tray</string> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <integer>2</integer> + </map> + <key>ClickActionBuyEnabled</key> + <map> + <key>Comment</key> + <string>Enable click to buy actions in tool pie menu</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ClickActionPayEnabled</key> + <map> + <key>Comment</key> + <string>Enable click to pay actions in tool pie menu</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableGrab</key> + <map> + <key>Comment</key> + <string>Use Ctrl+mouse to grab and manipulate objects</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableMouselook</key> + <map> + <key>Comment</key> + <string>Allow first person perspective and mouse control of camera</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableVoiceChat</key> + <map> + <key>Comment</key> + <string>Enable talking to other residents with a microphone</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>HelpURLFormat</key> + <map> + <key>Comment</key> + <string>URL pattern for help page; arguments will be encoded; see llviewerhelp.cpp:buildHelpURL for arguments</string> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>http://common-flash-secondlife-com.s3.amazonaws.com/viewer/v2.6/damballah/howto/index.html?topic=[TOPIC]</string> + </map> + <key>PreferredMaturity</key> + <map> + <key>Comment</key> + <string>Setting for the user's preferred maturity level (consts in indra_constants.h)</string> + <key>Type</key> + <string>U32</string> + <key>Value</key> + <integer>21</integer> + </map> + <key>RenderTrackerBeacon</key> + <map> + <key>Comment</key> + <string>Display tracking arrow and beacon to target avatar, teleport destination</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ShowScriptErrors</key> + <map> + <key>Comment</key> + <string>Show script errors</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ShowScriptErrorsLocation</key> + <map> + <key>Comment</key> + <string>Show script error in chat or window</string> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>SkinCurrent</key> + <map> + <key>Comment</key> + <string>The currently selected skin.</string> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>minimal</string> + </map> + <key>UseExternalBrowser</key> + <map> + <key>Comment</key> + <string>Use default browser when opening web pages instead of in-world browser.</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>VoiceCallsRejectAll</key> + <map> + <key>Comment</key> + <string>Silently reject all incoming voice calls.</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>VoiceDisableMic</key> + <map> + <key>Comment</key> + <string>Completely disable the ability to open the mic.</string> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>ScriptsCanShowUI</key> + <map> + <key>Comment</key> + <string>Allow LSL calls (such as LLMapDestination) to spawn viewer UI</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ChatFontSize</key> + <map> + <key>Comment</key> + <string>Size of chat text in chat console (0 = small, 1 = big, 2 = extra large)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>AvatarPickerHintTimeout</key> + <map> + <key>Comment</key> + <string>Number of seconds to wait before telling resident about avatar picker.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>0.0</real> + </map> + <key>RenderShowGroupTitleAll</key> + <map> + <key>Comment</key> + <string>Show group titles in name labels</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>OpenSidePanelsInFloaters</key> + <map> + <key>Comment</key> + <string>If true, will always open side panel contents in a floater.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>AvatarInspectorTooltipDelay</key> + <map> + <key>Comment</key> + <string>Seconds before displaying avatar inspector tooltip</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>0.1</real> + </map> + <key>AFKTimeout</key> + <map> + <key>Comment</key> + <string> + Time before automatically setting AFK (away from keyboard) mode (seconds, 0=never). + Valid values are: 0, 120, 300, 600, 1800 + </string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <real>0</real> + </map> + <key>SLURLTeleportDirectly</key> + <map> + <key>Comment</key> + <string>Clicking on a slurl will teleport you directly instead of opening places panel</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>EnableClassifieds</key> + <map> + <key>Comment</key> + <string>Enable creation of new classified ads</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableGroupInfo</key> + <map> + <key>Comment</key> + <string>Enable viewing and editing of group info.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnablePicks</key> + <map> + <key>Comment</key> + <string>Enable editing of picks</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableWorldMap</key> + <map> + <key>Comment</key> + <string>Enable opening world map from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableAvatarPay</key> + <map> + <key>Comment</key> + <string>Enable paying other avatars from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableVoiceCall</key> + <map> + <key>Comment</key> + <string>Enable voice calls from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableAvatarShare</key> + <map> + <key>Comment</key> + <string>Enable sharing from web link</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>DoubleClickShowWorldMap</key> + <map> + <key>Comment</key> + <string>Enable double-click to show world map from mini map</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>EnableGroupChatPopups</key> + <map> + <key>Comment</key> + <string>Enable Incoming Group Chat Popups</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>SearchFromAddressBar</key> + <map> + <key>Comment</key> + <string>Can enter search queries into navigation address bar</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>DestinationGuideURL</key> + <map> + <key>Comment</key> + <string>Destination guide contents</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>http://common-flash-secondlife-com.s3.amazonaws.com/viewer/v2.6/damballah/guide.html</string> + </map> + <key>AvatarPickerURL</key> + <map> + <key>Comment</key> + <string>Avatar picker contents</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>http://common-flash-secondlife-com.s3.amazonaws.com/viewer/v2.6/damballah/avatars.html</string> + </map> + <key>LogInventoryDecline</key> + <map> + <key>Comment</key> + <string>Log in system chat whenever an inventory offer is declined</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>UseHTTPInventory</key> + <map> + <key>Comment</key> + <string>Allow use of http inventory transfers instead of UDP</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>ClickToWalk</key> + <map> + <key>Comment</key> + <string>Click in world to walk to location</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>1</integer> + </map> + <key>ShowOfferedInventory</key> + <map> + <key>Comment</key> + <string>Show inventory window with last inventory offer selected when receiving inventory from other users.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + </map> +</llsd> diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp index c45be8b05e..24c816d58d 100644 --- a/indra/newview/llappearancemgr.cpp +++ b/indra/newview/llappearancemgr.cpp @@ -2910,6 +2910,9 @@ public: gAgent.setGenderChosen(TRUE); } + // release avatar picker keyboard focus + gFocusMgr.setKeyboardFocus( NULL ); + return true; } }; diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index c7351177a7..85447842e6 100755 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1,4 +1,4 @@ -/** + /** * @file llappviewer.cpp * @brief The LLAppViewer class definitions * @@ -339,6 +339,46 @@ void init_default_trans_args() const char *VFS_DATA_FILE_BASE = "data.db2.x."; const char *VFS_INDEX_FILE_BASE = "index.db2.x."; + +struct SettingsFile : public LLInitParam::Block<SettingsFile> +{ + Mandatory<std::string> name; + Optional<std::string> file_name; + Optional<bool> required, + persistent; + Optional<std::string> file_name_setting; + + SettingsFile() + : name("name"), + file_name("file_name"), + required("required", false), + persistent("persistent", true), + file_name_setting("file_name_setting") + {} +}; + +struct SettingsGroup : public LLInitParam::Block<SettingsGroup> +{ + Mandatory<std::string> name; + Mandatory<S32> path_index; + Multiple<SettingsFile> files; + + SettingsGroup() + : name("name"), + path_index("path_index"), + files("file") + {} +}; + +struct SettingsFiles : public LLInitParam::Block<SettingsFiles> +{ + Multiple<SettingsGroup> groups; + + SettingsFiles() + : groups("group") + {} +}; + static std::string gWindowTitle; LLAppViewer::LLUpdaterInfo *LLAppViewer::sUpdaterInfo = NULL ; @@ -596,7 +636,8 @@ LLAppViewer::LLAppViewer() : mRandomizeFramerate(LLCachedControl<bool>(gSavedSettings,"Randomize Framerate", FALSE)), mPeriodicSlowFrame(LLCachedControl<bool>(gSavedSettings,"Periodic Slow Frame", FALSE)), mFastTimerLogThread(NULL), - mUpdater(new LLUpdaterService()) + mUpdater(new LLUpdaterService()), + mSettingsLocationList(NULL) { if(NULL != sInstance) { @@ -612,6 +653,8 @@ LLAppViewer::LLAppViewer() : LLAppViewer::~LLAppViewer() { + delete mSettingsLocationList; + LLLoginInstance::instance().setUpdaterService(0); destroyMainloopTimeout(); @@ -1922,85 +1965,80 @@ bool LLAppViewer::initLogging() bool LLAppViewer::loadSettingsFromDirectory(const std::string& location_key, bool set_defaults) { - // Find and vet the location key. - if(!mSettingsLocationList.has(location_key)) - { - llerrs << "Requested unknown location: " << location_key << llendl; - return false; - } - - LLSD location = mSettingsLocationList.get(location_key); - - if(!location.has("PathIndex")) - { - llerrs << "Settings location is missing PathIndex value. Settings cannot be loaded." << llendl; - return false; - } - ELLPath path_index = (ELLPath)(location.get("PathIndex").asInteger()); - if(path_index <= LL_PATH_NONE || path_index >= LL_PATH_LAST) + if (!mSettingsLocationList) { - llerrs << "Out of range path index in app_settings/settings_files.xml" << llendl; - return false; + llerrs << "Invalid settings location list" << llendl; } - // Iterate through the locations list of files. - LLSD files = location.get("Files"); - for(LLSD::map_iterator itr = files.beginMap(); itr != files.endMap(); ++itr) + LLControlGroup* global_settings = LLControlGroup::getInstance(sGlobalSettingsName); + for(LLInitParam::ParamIterator<SettingsGroup>::const_iterator it = mSettingsLocationList->groups.begin(), end_it = mSettingsLocationList->groups.end(); + it != end_it; + ++it) { - std::string settings_group = (*itr).first; - llinfos << "Attempting to load settings for the group " << settings_group - << " - from location " << location_key << llendl; + // skip settings groups that aren't the one we requested + if (it->name() != location_key) continue; - if(!LLControlGroup::getInstance(settings_group)) + ELLPath path_index = (ELLPath)it->path_index(); + if(path_index <= LL_PATH_NONE || path_index >= LL_PATH_LAST) { - llwarns << "No matching settings group for name " << settings_group << llendl; - continue; + llerrs << "Out of range path index in app_settings/settings_files.xml" << llendl; + return false; } - LLSD file = (*itr).second; - - std::string full_settings_path; - if(file.has("NameFromSetting")) + LLInitParam::ParamIterator<SettingsFile>::const_iterator file_it, end_file_it; + for (file_it = it->files.begin(), end_file_it = it->files.end(); + file_it != end_file_it; + ++file_it) { - std::string custom_name_setting = file.get("NameFromSetting"); - // *NOTE: Regardless of the group currently being lodaed, - // this setting is always read from the Global settings. - if(LLControlGroup::getInstance(sGlobalSettingsName)->controlExists(custom_name_setting)) + llinfos << "Attempting to load settings for the group " << file_it->name() + << " - from location " << location_key << llendl; + + LLControlGroup* settings_group = LLControlGroup::getInstance(file_it->name); + if(!settings_group) { - std::string file_name = - LLControlGroup::getInstance(sGlobalSettingsName)->getString(custom_name_setting); - full_settings_path = file_name; + llwarns << "No matching settings group for name " << file_it->name() << llendl; + continue; } - } - if(full_settings_path.empty()) - { - std::string file_name = file.get("Name"); - full_settings_path = gDirUtilp->getExpandedFilename(path_index, file_name); - } + std::string full_settings_path; - int requirement = 0; - if(file.has("Requirement")) - { - requirement = file.get("Requirement").asInteger(); - } - - if(!LLControlGroup::getInstance(settings_group)->loadFromFile(full_settings_path, set_defaults)) - { - if(requirement == 1) + if (file_it->file_name_setting.isProvided() + && global_settings->controlExists(file_it->file_name_setting)) { - llwarns << "Error: Cannot load required settings file from: " - << full_settings_path << llendl; - return false; + // try to find filename stored in file_name_setting control + full_settings_path = global_settings->getString(file_it->file_name_setting); + if (!gDirUtilp->fileExists(full_settings_path)) + { + // search in default path + full_settings_path = gDirUtilp->getExpandedFilename((ELLPath)path_index, full_settings_path); + } } else { - llinfos << "Cannot load " << full_settings_path << " - No settings found." << llendl; + // by default, use specified file name + full_settings_path = gDirUtilp->getExpandedFilename((ELLPath)path_index, file_it->file_name()); + } + + if(settings_group->loadFromFile(full_settings_path, set_defaults, file_it->persistent)) + { // success! + llinfos << "Loaded settings file " << full_settings_path << llendl; + } + else + { // failed to load + if(file_it->required) + { + llerrs << "Error: Cannot load required settings file from: " << full_settings_path << llendl; + return false; + } + else + { + // only complain if we actually have a filename at this point + if (!full_settings_path.empty()) + { + llinfos << "Cannot load " << full_settings_path << " - No settings found." << llendl; + } + } } - } - else - { - llinfos << "Loaded settings file " << full_settings_path << llendl; } } @@ -2010,18 +2048,25 @@ bool LLAppViewer::loadSettingsFromDirectory(const std::string& location_key, std::string LLAppViewer::getSettingsFilename(const std::string& location_key, const std::string& file) { - if(mSettingsLocationList.has(location_key)) + for(LLInitParam::ParamIterator<SettingsGroup>::const_iterator it = mSettingsLocationList->groups.begin(), end_it = mSettingsLocationList->groups.end(); + it != end_it; + ++it) { - LLSD location = mSettingsLocationList.get(location_key); - if(location.has("Files")) + if (it->name() == location_key) { - LLSD files = location.get("Files"); - if(files.has(file) && files[file].has("Name")) + LLInitParam::ParamIterator<SettingsFile>::const_iterator file_it, end_file_it; + for (file_it = it->files.begin(), end_file_it = it->files.end(); + file_it != end_file_it; + ++file_it) { - return files.get(file).get("Name").asString(); + if (file_it->name() == file) + { + return file_it->file_name; + } } } } + return std::string(); } @@ -2034,14 +2079,29 @@ bool LLAppViewer::initConfiguration() { //Load settings files list std::string settings_file_list = gDirUtilp->getExpandedFilename(LL_PATH_APP_SETTINGS, "settings_files.xml"); - LLControlGroup settings_control("SettingsFiles"); - llinfos << "Loading settings file list " << settings_file_list << llendl; - if (0 == settings_control.loadFromFile(settings_file_list)) + //LLControlGroup settings_control("SettingsFiles"); + //llinfos << "Loading settings file list " << settings_file_list << llendl; + //if (0 == settings_control.loadFromFile(settings_file_list)) + //{ + // llerrs << "Cannot load default configuration file " << settings_file_list << llendl; + //} + + LLXMLNodePtr root; + BOOL success = LLXMLNode::parseFile(settings_file_list, root, NULL); + if (!success) { llerrs << "Cannot load default configuration file " << settings_file_list << llendl; } - mSettingsLocationList = settings_control.getLLSD("Locations"); + mSettingsLocationList = new SettingsFiles(); + + LLXUIParser parser; + parser.readXUI(root, *mSettingsLocationList, settings_file_list); + + if (!mSettingsLocationList->validateBlock()) + { + llerrs << "Invalid settings file list " << settings_file_list << llendl; + } // The settings and command line parsing have a fragile // order-of-operation: @@ -2152,6 +2212,31 @@ bool LLAppViewer::initConfiguration() // - load overrides from user_settings loadSettingsFromDirectory("User"); + + if (gSavedSettings.getBOOL("FirstRunThisInstall")) + { + gSavedSettings.setString("SessionSettingsFile", "settings_minimal.xml"); + } + + if (clp.hasOption("sessionsettings")) + { + std::string session_settings_filename = clp.getOption("sessionsettings")[0]; + gSavedSettings.setString("SessionSettingsFile", session_settings_filename); + llinfos << "Using session settings filename: " + << session_settings_filename << llendl; + } + loadSettingsFromDirectory("Session"); + + if (clp.hasOption("usersessionsettings")) + { + std::string user_session_settings_filename = clp.getOption("usersessionsettings")[0]; + gSavedSettings.setString("UserSessionSettingsFile", user_session_settings_filename); + llinfos << "Using user session settings filename: " + << user_session_settings_filename << llendl; + + } + loadSettingsFromDirectory("UserSession"); + // - apply command line settings clp.notify(); @@ -3273,6 +3358,20 @@ static bool finish_quit(const LLSD& notification, const LLSD& response) } static LLNotificationFunctorRegistration finish_quit_reg("ConfirmQuit", finish_quit); +static bool switch_standard_skin_and_quit(const LLSD& notification, const LLSD& response) +{ + S32 option = LLNotificationsUtil::getSelectedOption(notification, response); + + if (option == 0) + { + gSavedSettings.setString("SessionSettingsFile", ""); + LLAppViewer::instance()->requestQuit(); + } + return false; +} + +static LLNotificationFunctorRegistration standard_skin_quit_reg("SwitchToStandardSkinAndQuit", switch_standard_skin_and_quit); + void LLAppViewer::userQuit() { if (gDisconnected || gViewerWindow->getProgressView()->getVisible()) diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h index a18e6cbb02..0226211735 100644 --- a/indra/newview/llappviewer.h +++ b/indra/newview/llappviewer.h @@ -253,7 +253,7 @@ private: bool mQuitRequested; // User wants to quit, may have modified documents open. bool mLogoutRequestSent; // Disconnect message sent to simulator, no longer safe to send messages to the sim. S32 mYieldTime; - LLSD mSettingsLocationList; + struct SettingsFiles* mSettingsLocationList; LLWatchdogTimeout* mMainloopTimeout; diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index f3f0cde221..afa8b62c74 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -47,6 +47,7 @@ #include "llfloatergroups.h" #include "llfloaterreg.h" #include "llfloaterpay.h" +#include "llfloaterwebcontent.h" #include "llfloaterworldmap.h" #include "llgiveinventory.h" #include "llinventorybridge.h" @@ -315,7 +316,7 @@ void LLAvatarActions::showProfile(const LLUUID& id) std::string agent_name = LLCacheName::buildUsername(full_name); llinfos << "opening web profile for " << agent_name << llendl; std::string url = getProfileURL(agent_name); - LLWeb::loadWebURLInternal(url); + LLWeb::loadWebURLInternal(url, "", id.asString()); } else { @@ -336,6 +337,24 @@ void LLAvatarActions::showProfile(const LLUUID& id) } } +//static +bool LLAvatarActions::profileVisible(const LLUUID& id) +{ + LLFloaterWebContent *browser = dynamic_cast<LLFloaterWebContent*> (LLFloaterReg::findInstance("web_content", id.asString())); + return browser && browser->isShown(); +} + + +//static +void LLAvatarActions::hideProfile(const LLUUID& id) +{ + LLFloaterWebContent *browser = dynamic_cast<LLFloaterWebContent*> (LLFloaterReg::findInstance("web_content", id.asString())); + if (browser) + { + browser->closeFloater(); + } +} + // static void LLAvatarActions::showOnMap(const LLUUID& id) { diff --git a/indra/newview/llavataractions.h b/indra/newview/llavataractions.h index 2db2918eed..956fed7461 100644 --- a/indra/newview/llavataractions.h +++ b/indra/newview/llavataractions.h @@ -93,6 +93,8 @@ public: * Show avatar profile. */ static void showProfile(const LLUUID& id); + static void hideProfile(const LLUUID& id); + static bool profileVisible(const LLUUID& id); /** * Show avatar on world map. diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp index d8ec4b605c..1fb83fe567 100644 --- a/indra/newview/llbottomtray.cpp +++ b/indra/newview/llbottomtray.cpp @@ -38,12 +38,15 @@ #include "lltexteditor.h" // newview includes +#include "llagent.h" #include "llagentcamera.h" +#include "llavataractions.h" #include "llchiclet.h" #include "llfloatercamera.h" #include "llhints.h" #include "llimfloater.h" // for LLIMFloater #include "llnearbychatbar.h" +#include "llsidetray.h" #include "llspeakbutton.h" #include "llsplitbutton.h" #include "llsyswellwindow.h" @@ -418,10 +421,6 @@ void LLBottomTray::setVisible(BOOL visible) { LLPanel::setVisible(visible); } - if(visible) - gFloaterView->setSnapOffsetBottom(getRect().getHeight()); - else - gFloaterView->setSnapOffsetBottom(0); } S32 LLBottomTray::notifyParent(const LLSD& info) @@ -849,6 +848,24 @@ void LLBottomTray::draw() LLRect rect = mLandingTab->calcScreenRect(); mImageDragIndication->draw(rect.mLeft - w/2, rect.getHeight(), w, h); } + getChild<LLButton>("show_profile_btn")->setToggleState(LLAvatarActions::profileVisible(gAgent.getID())); + + LLPanel* panel = LLSideTray::getInstance()->getPanel("panel_people"); + if (panel && panel->isInVisibleChain()) + { + getChild<LLButton>("show_people_button")->setToggleState(true); + } + else + { + getChild<LLButton>("show_people_button")->setToggleState(false); + } + + LLFloater* help_browser = (LLFloaterReg::findInstance("help_browser")); + bool help_floater_visible = (help_browser && help_browser->isInVisibleChain()); + + getChild<LLButton>("show_help_btn")->setToggleState(help_floater_visible); + + } bool LLBottomTray::onContextMenuItemEnabled(const LLSD& userdata) diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index 5ff22f89ab..d4ec377e03 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -138,10 +138,7 @@ public: if (level == "profile") { - LLSD params; - params["object_id"] = getAvatarId(); - - LLFloaterReg::showInstance("inspect_object", params); + LLFloaterReg::showInstance("inspect_remote_object", mObjectData); } else if (level == "block") { @@ -229,7 +226,7 @@ public: if (mSourceType == CHAT_SOURCE_OBJECT) { - LLFloaterReg::showInstance("inspect_object", LLSD().with("object_id", mAvatarID)); + LLFloaterReg::showInstance("inspect_remote_object", mObjectData); } else if (mSourceType == CHAT_SOURCE_AGENT) { @@ -251,7 +248,7 @@ public: const LLUUID& getAvatarId () const { return mAvatarID;} - void setup(const LLChat& chat,const LLStyle::Params& style_params) + void setup(const LLChat& chat, const LLStyle::Params& style_params, const LLSD& args) { mAvatarID = chat.mFromID; mSessionID = chat.mSessionID; @@ -332,7 +329,8 @@ public: setTimeField(chat); - + + // Set up the icon. LLAvatarIconCtrl* icon = getChild<LLAvatarIconCtrl>("avatar_icon"); if(mSourceType != CHAT_SOURCE_AGENT || mAvatarID.isNull()) @@ -352,6 +350,30 @@ public: case CHAT_SOURCE_UNKNOWN: icon->setValue(LLSD("Unknown_Icon")); } + + // In case the message came from an object, save the object info + // to be able properly show its profile. + if ( chat.mSourceType == CHAT_SOURCE_OBJECT) + { + std::string slurl = args["slurl"].asString(); + if (slurl.empty()) + { + LLViewerRegion *region = LLWorld::getInstance()->getRegionFromPosAgent(chat.mPosAgent); + if(region) + { + LLSLURL region_slurl(region->getName(), chat.mPosAgent); + slurl = region_slurl.getLocationString(); + } + } + + LLSD payload; + payload["object_id"] = chat.mFromID; + payload["name"] = chat.mFromName; + payload["owner_id"] = chat.mOwnerID; + payload["slurl"] = LLWeb::escapeURL(slurl); + + mObjectData = payload; + } } /*virtual*/ void draw() @@ -540,6 +562,7 @@ protected: static LLUICtrl* sInfoCtrl; LLUUID mAvatarID; + LLSD mObjectData; EChatSourceType mSourceType; std::string mFrom; LLUUID mSessionID; @@ -649,10 +672,10 @@ LLView* LLChatHistory::getSeparator() return separator; } -LLView* LLChatHistory::getHeader(const LLChat& chat,const LLStyle::Params& style_params) +LLView* LLChatHistory::getHeader(const LLChat& chat,const LLStyle::Params& style_params, const LLSD& args) { LLChatHistoryHeader* header = LLChatHistoryHeader::createInstance(mMessageHeaderFilename); - header->setup(chat,style_params); + header->setup(chat, style_params, args); return header; } @@ -834,7 +857,7 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL } else { - view = getHeader(chat, style_params); + view = getHeader(chat, style_params, args); if (mEditor->getText().size() == 0) p.top_pad = 0; else diff --git a/indra/newview/llchathistory.h b/indra/newview/llchathistory.h index ac48d7bf29..28344e6a10 100644 --- a/indra/newview/llchathistory.h +++ b/indra/newview/llchathistory.h @@ -94,7 +94,7 @@ class LLChatHistory : public LLUICtrl * Builds a message header. * @return pointer to LLView header object. */ - LLView* getHeader(const LLChat& chat,const LLStyle::Params& style_params); + LLView* getHeader(const LLChat& chat,const LLStyle::Params& style_params, const LLSD& args); void onClickMoreText(); diff --git a/indra/newview/llcommandhandler.cpp b/indra/newview/llcommandhandler.cpp index 360ba080ac..1b6ba02aac 100644 --- a/indra/newview/llcommandhandler.cpp +++ b/indra/newview/llcommandhandler.cpp @@ -35,7 +35,7 @@ // system includes #include <boost/tokenizer.hpp> -#define THROTTLE_PERIOD 15 // required secs between throttled commands +#define THROTTLE_PERIOD 5 // required secs between throttled commands static LLCommandDispatcherListener sCommandDispatcherListener; diff --git a/indra/newview/llfirstuse.cpp b/indra/newview/llfirstuse.cpp index 4d252dc662..e319418def 100644 --- a/indra/newview/llfirstuse.cpp +++ b/indra/newview/llfirstuse.cpp @@ -41,36 +41,35 @@ // static -//std::set<std::string> LLFirstUse::sConfigVariables; -std::set<std::string> LLFirstUse::sConfigVariablesEnabled; +std::set<std::string> LLFirstUse::sConfigVariables; // static -//void LLFirstUse::addConfigVariable(const std::string& var) -//{ -// sConfigVariables.insert(var); -//} +void LLFirstUse::addConfigVariable(const std::string& var) +{ + sConfigVariables.insert(var); +} // static -//void LLFirstUse::disableFirstUse() -//{ -// // Set all first-use warnings to disabled -// for (std::set<std::string>::iterator iter = sConfigVariables.begin(); -// iter != sConfigVariables.end(); ++iter) -// { -// gWarningSettings.setBOOL(*iter, FALSE); -// } -//} +void LLFirstUse::disableFirstUse() +{ + // Set all first-use warnings to disabled + for (std::set<std::string>::iterator iter = sConfigVariables.begin(); + iter != sConfigVariables.end(); ++iter) + { + gWarningSettings.setBOOL(*iter, FALSE); + } +} // static -//void LLFirstUse::resetFirstUse() -//{ -// // Set all first-use warnings to disabled -// for (std::set<std::string>::iterator iter = sConfigVariables.begin(); -// iter != sConfigVariables.end(); ++iter) -// { -// gWarningSettings.setBOOL(*iter, TRUE); -// } -//} +void LLFirstUse::resetFirstUse() +{ + // Set all first-use warnings to disabled + for (std::set<std::string>::iterator iter = sConfigVariables.begin(); + iter != sConfigVariables.end(); ++iter) + { + gWarningSettings.setBOOL(*iter, TRUE); + } +} // static void LLFirstUse::otherAvatarChatFirst(bool enable) @@ -104,13 +103,6 @@ void LLFirstUse::notUsingDestinationGuide(bool enable) firstUseNotification("FirstNotUseDestinationGuide", enable, "HintDestinationGuide", LLSD(), LLSD().with("target", "dest_guide_btn").with("direction", "top")); } -void LLFirstUse::notUsingAvatarPicker(bool enable) -{ - // not doing this yet - firstUseNotification("FirstNotUseAvatarPicker", enable, "HintAvatarPicker", LLSD(), LLSD().with("target", "avatar_picker_btn").with("direction", "top")); -} - - // static void LLFirstUse::notUsingSidePanel(bool enable) { @@ -152,21 +144,13 @@ void LLFirstUse::firstUseNotification(const std::string& control_var, bool enabl if (enable) { - if(sConfigVariablesEnabled.find(control_var) != sConfigVariablesEnabled.end()) - { - return ; //already added - } - if (gSavedSettings.getBOOL("EnableUIHints")) { LL_DEBUGS("LLFirstUse") << "Trigger first use notification " << notification_name << LL_ENDL; // if notification doesn't already exist and this notification hasn't been disabled... if (gWarningSettings.getBOOL(control_var)) - { - sConfigVariablesEnabled.insert(control_var) ; - - // create new notification + { // create new notification LLNotifications::instance().add(LLNotification::Params().name(notification_name).substitutions(args).payload(payload.with("control_var", control_var))); } } @@ -178,6 +162,7 @@ void LLFirstUse::firstUseNotification(const std::string& control_var, bool enabl // redundantly clear settings var here, in case there are no notifications to cancel gWarningSettings.setBOOL(control_var, FALSE); } + } // static diff --git a/indra/newview/llfirstuse.h b/indra/newview/llfirstuse.h index 489f58626a..42b2ec0c60 100644 --- a/indra/newview/llfirstuse.h +++ b/indra/newview/llfirstuse.h @@ -78,16 +78,15 @@ class LLFirstUse public: // Add a config variable to be reset on resetFirstUse() - //static void addConfigVariable(const std::string& var); + static void addConfigVariable(const std::string& var); // Sets all controls back to show the dialogs. - //static void disableFirstUse(); - //static void resetFirstUse(); + static void disableFirstUse(); + static void resetFirstUse(); static void otherAvatarChatFirst(bool enable = true); static void sit(bool enable = true); static void notUsingDestinationGuide(bool enable = true); - static void notUsingAvatarPicker(bool enable = true); static void notUsingSidePanel(bool enable = true); static void notMoving(bool enable = true); static void viewPopup(bool enable = true); @@ -98,8 +97,7 @@ public: protected: static void firstUseNotification(const std::string& control_var, bool enable, const std::string& notification_name, LLSD args = LLSD(), LLSD payload = LLSD()); - //static std::set<std::string> sConfigVariables; - static std::set<std::string> sConfigVariablesEnabled; + static std::set<std::string> sConfigVariables; static void init(); static bool processNotification(const LLSD& notify); diff --git a/indra/newview/llfloatermap.cpp b/indra/newview/llfloatermap.cpp index 80920c80d6..45d1cc2b53 100644 --- a/indra/newview/llfloatermap.cpp +++ b/indra/newview/llfloatermap.cpp @@ -83,8 +83,14 @@ LLFloaterMap::~LLFloaterMap() BOOL LLFloaterMap::postBuild() { mMap = getChild<LLNetMap>("Net Map"); - mMap->setToolTipMsg(gSavedSettings.getBOOL("DoubleClickTeleport") ? - getString("AltToolTipMsg") : getString("ToolTipMsg")); + if (gSavedSettings.getBOOL("DoubleClickTeleport")) + { + mMap->setToolTipMsg(getString("AltToolTipMsg")); + } + else if (gSavedSettings.getBOOL("DoubleClickShowWorldMap")) + { + mMap->setToolTipMsg(getString("ToolTipMsg")); + } sendChildToBack(mMap); mTextBoxNorth = getChild<LLTextBox> ("floater_map_north"); @@ -150,7 +156,7 @@ BOOL LLFloaterMap::handleDoubleClick(S32 x, S32 y, MASK mask) // If DoubleClickTeleport is on, double clicking the minimap will teleport there gAgent.teleportViaLocationLookAt(pos_global); } - else + else if (gSavedSettings.getBOOL("DoubleClickShowWorldMap")) { LLFloaterReg::showInstance("world_map"); } diff --git a/indra/newview/llfloatersidetraytab.cpp b/indra/newview/llfloatersidetraytab.cpp index f13b4db3a0..94407e6da0 100644 --- a/indra/newview/llfloatersidetraytab.cpp +++ b/indra/newview/llfloatersidetraytab.cpp @@ -30,6 +30,7 @@ // newview includes #include "lltransientfloatermgr.h" +#include "llsidetray.h" LLFloaterSideTrayTab::LLFloaterSideTrayTab(const LLSD& key, const Params& params) : LLFloater(key, params) @@ -43,3 +44,8 @@ LLFloaterSideTrayTab::~LLFloaterSideTrayTab() { LLTransientFloaterMgr::getInstance()->removeControlView(LLTransientFloaterMgr::GLOBAL, this); } + +void LLFloaterSideTrayTab::onClose(bool app_quitting) +{ + LLSideTray::getInstance()->setTabDocked(getName(), true); +} diff --git a/indra/newview/llfloatersidetraytab.h b/indra/newview/llfloatersidetraytab.h index e47f82e8ba..89f2444a0e 100644 --- a/indra/newview/llfloatersidetraytab.h +++ b/indra/newview/llfloatersidetraytab.h @@ -42,6 +42,8 @@ class LLFloaterSideTrayTab : public LLFloater public: LLFloaterSideTrayTab(const LLSD& key, const Params& params = getDefaultParams()); ~LLFloaterSideTrayTab(); + + void onClose(bool app_quitting); }; #endif // LL_LLFLOATERSIDETRAYTAB_H diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp index 017cd2fc49..03cf0332a9 100644 --- a/indra/newview/llfloaterworldmap.cpp +++ b/indra/newview/llfloaterworldmap.cpp @@ -110,6 +110,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableWorldMap")) + { + LLNotificationsUtil::add("NoWorldMap", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + if (params.size() == 0) { // support the secondlife:///app/worldmap SLapp @@ -142,6 +148,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableWorldMap")) + { + LLNotificationsUtil::add("NoWorldMap", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + //Make sure we have some parameters if (params.size() == 0) { diff --git a/indra/newview/llgroupactions.cpp b/indra/newview/llgroupactions.cpp index 5393678a6b..7c56e610ce 100644 --- a/indra/newview/llgroupactions.cpp +++ b/indra/newview/llgroupactions.cpp @@ -53,6 +53,12 @@ public: bool handle(const LLSD& tokens, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableGroupInfo")) + { + LLNotificationsUtil::add("NoGroupInfo", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + if (tokens.size() < 1) { return false; diff --git a/indra/newview/llhudeffectblob.cpp b/indra/newview/llhudeffectblob.cpp new file mode 100644 index 0000000000..26e8251899 --- /dev/null +++ b/indra/newview/llhudeffectblob.cpp @@ -0,0 +1,78 @@ +/** + * @file llhudeffecttrail.cpp + * @brief LLHUDEffectSpiral class implementation + * + * $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 "llhudeffectblob.h" + +#include "llagent.h" +#include "llviewercamera.h" +#include "llrendersphere.h" + +LLHUDEffectBlob::LLHUDEffectBlob(const U8 type) +: LLHUDEffect(type), + mPixelSize(10) +{ + mTimer.start(); +} + +LLHUDEffectBlob::~LLHUDEffectBlob() +{ +} + +void LLHUDEffectBlob::render() +{ + F32 time = mTimer.getElapsedTimeF32(); + if (mDuration < time) + { + markDead(); + } + + LLVector3 pos_agent = gAgent.getPosAgentFromGlobal(mPositionGlobal); + + LLVector3 pixel_up, pixel_right; + + LLViewerCamera::instance().getPixelVectors(pos_agent, pixel_up, pixel_right); + + LLGLSPipelineAlpha gls_pipeline_alpha; + gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); + + LLColor4U color = mColor; + color.mV[VALPHA] = (U8)clamp_rescale(time, 0.f, mDuration, 255.f, 0.f); + glColor4ubv(color.mV); + + glPushMatrix(); + glTranslatef(pos_agent.mV[0], pos_agent.mV[1], pos_agent.mV[2]); + F32 scale = pixel_up.magVec() * (F32)mPixelSize; + glScalef(scale, scale, scale); + gSphere.render(0); + glPopMatrix(); +} + +void LLHUDEffectBlob::renderForTimer() +{ +} + diff --git a/indra/newview/llhudeffectblob.h b/indra/newview/llhudeffectblob.h new file mode 100644 index 0000000000..5b0703cdaa --- /dev/null +++ b/indra/newview/llhudeffectblob.h @@ -0,0 +1,50 @@ +/** + * @file llhudeffectblob.h + * @brief LLHUDEffectBlob class definition + * + * $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$ + */ + +#ifndef LL_LLHUDEFFECTBLOB_H +#define LL_LLHUDEFFECTBLOB_H + +#include "llhudeffect.h" + +class LLHUDEffectBlob : public LLHUDEffect +{ +public: + friend class LLHUDObject; + + void setPixelSize(S32 pixels) { mPixelSize = pixels; } + +protected: + LLHUDEffectBlob(const U8 type); + ~LLHUDEffectBlob(); + + /*virtual*/ void render(); + /*virtual*/ void renderForTimer(); +private: + S32 mPixelSize; + LLFrameTimer mTimer; +}; + +#endif // LL_LLHUDEFFECTBLOB_H diff --git a/indra/newview/llhudobject.cpp b/indra/newview/llhudobject.cpp index 5e762ee037..95d57d08d8 100644 --- a/indra/newview/llhudobject.cpp +++ b/indra/newview/llhudobject.cpp @@ -32,6 +32,7 @@ #include "llhudtext.h" #include "llhudicon.h" #include "llhudeffectbeam.h" +#include "llhudeffectblob.h" #include "llhudeffecttrail.h" #include "llhudeffectlookat.h" #include "llhudeffectpointat.h" @@ -237,6 +238,9 @@ LLHUDEffect *LLHUDObject::addHUDEffect(const U8 type) case LL_HUD_EFFECT_POINTAT: hud_objectp = new LLHUDEffectPointAt(type); break; + case LL_HUD_EFFECT_BLOB: + hud_objectp = new LLHUDEffectBlob(type); + break; default: llwarns << "Unknown type of hud effect:" << (U32) type << llendl; } diff --git a/indra/newview/llhudobject.h b/indra/newview/llhudobject.h index 33e6394445..2f7a98c86c 100644 --- a/indra/newview/llhudobject.h +++ b/indra/newview/llhudobject.h @@ -95,7 +95,8 @@ public: LL_HUD_EFFECT_LOOKAT, LL_HUD_EFFECT_POINTAT, LL_HUD_EFFECT_VOICE_VISUALIZER, // Ventrella - LL_HUD_NAME_TAG + LL_HUD_NAME_TAG, + LL_HUD_EFFECT_BLOB }; protected: static void sortObjects(); diff --git a/indra/newview/llinventorymodelbackgroundfetch.cpp b/indra/newview/llinventorymodelbackgroundfetch.cpp index 570e48d526..e31360fcbc 100644 --- a/indra/newview/llinventorymodelbackgroundfetch.cpp +++ b/indra/newview/llinventorymodelbackgroundfetch.cpp @@ -182,7 +182,7 @@ void LLInventoryModelBackgroundFetch::backgroundFetch() { // If we'll be using the capability, we'll be sending batches and the background thing isn't as important. std::string url = gAgent.getRegion()->getCapability("FetchInventoryDescendents2"); - if (!url.empty()) + if (gSavedSettings.getBOOL("UseHTTPInventory") && !url.empty()) { bulkFetch(url); return; diff --git a/indra/newview/lllocationinputctrl.cpp b/indra/newview/lllocationinputctrl.cpp index 55164f6094..5c65dcec34 100644 --- a/indra/newview/lllocationinputctrl.cpp +++ b/indra/newview/lllocationinputctrl.cpp @@ -211,7 +211,6 @@ LLLocationInputCtrl::LLLocationInputCtrl(const LLLocationInputCtrl::Params& p) { // Lets replace default LLLineEditor with LLLocationLineEditor // to make needed escaping while copying and cutting url - this->removeChild(mTextEntry); delete mTextEntry; // Can't access old mTextEntry fields as they are protected, so lets build new params diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp index e4f83ce6b9..3b160ddc8e 100644 --- a/indra/newview/llnavigationbar.cpp +++ b/indra/newview/llnavigationbar.cpp @@ -636,18 +636,19 @@ void LLNavigationBar::onRegionNameResponse( U64 region_handle, const std::string& url, const LLUUID& snapshot_id, bool teleport) { // Invalid location? - if (!region_handle) + if (region_handle) + { + // Teleport to the location. + LLVector3d region_pos = from_region_handle(region_handle); + LLVector3d global_pos = region_pos + (LLVector3d) local_coords; + + llinfos << "Teleporting to: " << LLSLURL(region_name, global_pos).getSLURLString() << llendl; + gAgent.teleportViaLocation(global_pos); + } + else if (gSavedSettings.getBOOL("SearchFromAddressBar")) { invokeSearch(typed_location); - return; } - - // Teleport to the location. - LLVector3d region_pos = from_region_handle(region_handle); - LLVector3d global_pos = region_pos + (LLVector3d) local_coords; - - llinfos << "Teleporting to: " << LLSLURL(region_name, global_pos).getSLURLString() << llendl; - gAgent.teleportViaLocation(global_pos); } void LLNavigationBar::showTeleportHistoryMenu(LLUICtrl* btn_ctrl) diff --git a/indra/newview/llnetmap.cpp b/indra/newview/llnetmap.cpp index 93039d935d..e29078c545 100644 --- a/indra/newview/llnetmap.cpp +++ b/indra/newview/llnetmap.cpp @@ -904,23 +904,29 @@ BOOL LLNetMap::handleClick(S32 x, S32 y, MASK mask) BOOL LLNetMap::handleDoubleClick(S32 x, S32 y, MASK mask) { LLVector3d pos_global = viewPosToGlobal(x, y); - - // If we're not tracking a beacon already, double-click will set one - if (!LLTracker::isTracking(NULL)) + + bool double_click_teleport = gSavedSettings.getBOOL("DoubleClickTeleport"); + bool double_click_show_world_map = gSavedSettings.getBOOL("DoubleClickShowWorldMap"); + + if (double_click_teleport || double_click_show_world_map) { - LLFloaterWorldMap* world_map = LLFloaterWorldMap::getInstance(); - if (world_map) + // If we're not tracking a beacon already, double-click will set one + if (!LLTracker::isTracking(NULL)) { - world_map->trackLocation(pos_global); + LLFloaterWorldMap* world_map = LLFloaterWorldMap::getInstance(); + if (world_map) + { + world_map->trackLocation(pos_global); + } } } - - if (gSavedSettings.getBOOL("DoubleClickTeleport")) + + if (double_click_teleport) { // If DoubleClickTeleport is on, double clicking the minimap will teleport there gAgent.teleportViaLocationLookAt(pos_global); } - else + else if (double_click_show_world_map) { LLFloaterReg::showInstance("world_map"); } diff --git a/indra/newview/llnotificationscripthandler.cpp b/indra/newview/llnotificationscripthandler.cpp index 45590c3cdb..bbb4d03768 100644 --- a/indra/newview/llnotificationscripthandler.cpp +++ b/indra/newview/llnotificationscripthandler.cpp @@ -88,7 +88,7 @@ bool LLScriptHandler::processNotification(const LLSD& notify) initChannel(); } - if(notify["sigtype"].asString() == "add" || notify["sigtype"].asString() == "change") + if(notify["sigtype"].asString() == "add") { if (LLHandlerUtil::canLogToIM(notification)) { diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp index 3b5830f8e0..b472698a49 100644 --- a/indra/newview/llpanellogin.cpp +++ b/indra/newview/llpanellogin.cpp @@ -1,1193 +1,1183 @@ -/** - * @file llpanellogin.cpp - * @brief Login dialog and logo display - * - * $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 "llpanellogin.h" - -#include "indra_constants.h" // for key and mask constants -#include "llfloaterreg.h" -#include "llfontgl.h" -#include "llmd5.h" -#include "llsecondlifeurls.h" -#include "v4color.h" - -#include "llappviewer.h" -#include "llbutton.h" -#include "llcheckboxctrl.h" -#include "llcommandhandler.h" // for secondlife:///app/login/ -#include "llcombobox.h" -#include "llcurl.h" -#include "llviewercontrol.h" -#include "llfloaterpreference.h" -#include "llfocusmgr.h" -#include "lllineeditor.h" -#include "llnotificationsutil.h" -#include "llsecapi.h" -#include "llstartup.h" -#include "lltextbox.h" -#include "llui.h" -#include "lluiconstants.h" -#include "llslurl.h" -#include "llversioninfo.h" -#include "llviewerhelp.h" -#include "llviewertexturelist.h" -#include "llviewermenu.h" // for handle_preferences() -#include "llviewernetwork.h" -#include "llviewerwindow.h" // to link into child list -#include "lluictrlfactory.h" -#include "llhttpclient.h" -#include "llweb.h" -#include "llmediactrl.h" -#include "llrootview.h" - -#include "llfloatertos.h" -#include "lltrans.h" -#include "llglheaders.h" -#include "llpanelloginlistener.h" - -#if LL_WINDOWS -#pragma warning(disable: 4355) // 'this' used in initializer list -#endif // LL_WINDOWS - -#include "llsdserialize.h" - -const S32 BLACK_BORDER_HEIGHT = 160; -const S32 MAX_PASSWORD = 16; - -LLPanelLogin *LLPanelLogin::sInstance = NULL; -BOOL LLPanelLogin::sCapslockDidNotification = FALSE; - -// Helper for converting a user name into the canonical "Firstname Lastname" form. -// For new accounts without a last name "Resident" is added as a last name. -static std::string canonicalize_username(const std::string& name); - -class LLLoginRefreshHandler : public LLCommandHandler -{ -public: - // don't allow from external browsers - LLLoginRefreshHandler() : LLCommandHandler("login_refresh", UNTRUSTED_BLOCK) { } - bool handle(const LLSD& tokens, const LLSD& query_map, LLMediaCtrl* web) - { - if (LLStartUp::getStartupState() < STATE_LOGIN_CLEANUP) - { - LLPanelLogin::loadLoginPage(); - } - return true; - } -}; - -LLLoginRefreshHandler gLoginRefreshHandler; - - -// helper class that trys to download a URL from a web site and calls a method -// on parent class indicating if the web server is working or not -class LLIamHereLogin : public LLHTTPClient::Responder -{ - private: - LLIamHereLogin( LLPanelLogin* parent ) : - mParent( parent ) - {} - - LLPanelLogin* mParent; - - public: - static boost::intrusive_ptr< LLIamHereLogin > build( LLPanelLogin* parent ) - { - return boost::intrusive_ptr< LLIamHereLogin >( new LLIamHereLogin( parent ) ); - }; - - virtual void setParent( LLPanelLogin* parentIn ) - { - mParent = parentIn; - }; - - // We don't actually expect LLSD back, so need to override completedRaw - virtual void completedRaw(U32 status, const std::string& reason, - const LLChannelDescriptors& channels, - const LLIOPipe::buffer_ptr_t& buffer) - { - completed(status, reason, LLSD()); // will call result() or error() - } - - virtual void result( const LLSD& content ) - { - if ( mParent ) - mParent->setSiteIsAlive( true ); - }; - - virtual void error( U32 status, const std::string& reason ) - { - if ( mParent ) - mParent->setSiteIsAlive( false ); - }; -}; - -// this is global and not a class member to keep crud out of the header file -namespace { - boost::intrusive_ptr< LLIamHereLogin > gResponsePtr = 0; -}; - - -//--------------------------------------------------------------------------- -// Public methods -//--------------------------------------------------------------------------- -LLPanelLogin::LLPanelLogin(const LLRect &rect, - BOOL show_server, - void (*callback)(S32 option, void* user_data), - void *cb_data) -: LLPanel(), - mLogoImage(), - mCallback(callback), - mCallbackData(cb_data), - mHtmlAvailable( TRUE ), - mListener(new LLPanelLoginListener(this)) -{ - setBackgroundVisible(FALSE); - setBackgroundOpaque(TRUE); - - // instance management - if (LLPanelLogin::sInstance) - { - llwarns << "Duplicate instance of login view deleted" << llendl; - // Don't leave bad pointer in gFocusMgr - gFocusMgr.setDefaultKeyboardFocus(NULL); - - delete LLPanelLogin::sInstance; - } - - mPasswordModified = FALSE; - LLPanelLogin::sInstance = this; - - LLView* login_holder = gViewerWindow->getLoginPanelHolder(); - if (login_holder) - { - login_holder->addChild(this); - } - - // Logo - mLogoImage = LLUI::getUIImage("startup_logo"); - - buildFromFile( "panel_login.xml"); - - // Legacy login web page is hidden under the menu bar. - // Adjust reg-in-client web browser widget to not be hidden. - if (gSavedSettings.getBOOL("RegInClient")) - { - reshape(rect.getWidth(), rect.getHeight() - MENU_BAR_HEIGHT); - } - else - { - reshape(rect.getWidth(), rect.getHeight()); - } - - getChild<LLLineEditor>("password_edit")->setKeystrokeCallback(onPassKey, this); - - // change z sort of clickable text to be behind buttons - //sendChildToBack(getChildView("channel_text")); - sendChildToBack(getChildView("forgot_password_text")); - - if(LLStartUp::getStartSLURL().getType() != LLSLURL::LOCATION) - { - LLSLURL slurl(gSavedSettings.getString("LoginLocation")); - LLStartUp::setStartSLURL(slurl); - } - updateLocationCombo(false); - - LLComboBox* server_choice_combo = sInstance->getChild<LLComboBox>("server_combo"); - server_choice_combo->setCommitCallback(onSelectServer, NULL); - server_choice_combo->setFocusLostCallback(boost::bind(onServerComboLostFocus, _1)); - updateServerCombo(); - - childSetAction("connect_btn", onClickConnect, this); - - getChild<LLPanel>("login")->setDefaultBtn("connect_btn"); - - std::string channel = LLVersionInfo::getChannel(); - std::string version = llformat("%s (%d)", - LLVersionInfo::getShortVersion().c_str(), - LLVersionInfo::getBuild()); - //LLTextBox* channel_text = getChild<LLTextBox>("channel_text"); - //channel_text->setTextArg("[CHANNEL]", channel); // though not displayed - //channel_text->setTextArg("[VERSION]", version); - //channel_text->setClickedCallback(onClickVersion, this); - - LLTextBox* forgot_password_text = getChild<LLTextBox>("forgot_password_text"); - forgot_password_text->setClickedCallback(onClickForgotPassword, NULL); - - LLTextBox* create_new_account_text = getChild<LLTextBox>("create_new_account_text"); - create_new_account_text->setClickedCallback(onClickNewAccount, NULL); - - LLTextBox* need_help_text = getChild<LLTextBox>("login_help"); - need_help_text->setClickedCallback(onClickHelp, NULL); - - // get the web browser control - LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html"); - web_browser->addObserver(this); - - // Clear the browser's cache to avoid any potential for the cache messing up the login screen. - web_browser->clearCache(); - - reshapeBrowser(); - - // kick off a request to grab the url manually - gResponsePtr = LLIamHereLogin::build( this ); - - LLHTTPClient::head( LLGridManager::getInstance()->getLoginPage(), gResponsePtr ); - - // Show last logged in user favorites in "Start at" combo. - addUsersWithFavoritesToUsername(); - getChild<LLComboBox>("username_combo")->setTextChangedCallback(boost::bind(&LLPanelLogin::addFavoritesToStartLocation, this)); - - updateLocationCombo(false); - -} - -void LLPanelLogin::addUsersWithFavoritesToUsername() -{ - LLComboBox* combo = getChild<LLComboBox>("username_combo"); - if (!combo) return; - std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml"); - LLSD fav_llsd; - llifstream file; - file.open(filename); - if (!file.is_open()) return; - LLSDSerialize::fromXML(fav_llsd, file); - for (LLSD::map_const_iterator iter = fav_llsd.beginMap(); - iter != fav_llsd.endMap(); ++iter) - { - combo->add(iter->first); - } -} - -void LLPanelLogin::addFavoritesToStartLocation() -{ - LLComboBox* combo = getChild<LLComboBox>("start_location_combo"); - if (!combo) return; - int num_items = combo->getItemCount(); - for (int i = num_items - 1; i > 2; i--) - { - combo->remove(i); - } - std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml"); - LLSD fav_llsd; - llifstream file; - file.open(filename); - if (!file.is_open()) return; - LLSDSerialize::fromXML(fav_llsd, file); - for (LLSD::map_const_iterator iter = fav_llsd.beginMap(); - iter != fav_llsd.endMap(); ++iter) - { - std::string user_defined_name = getChild<LLComboBox>("username_combo")->getSimple(); - - // The account name in stored_favorites.xml has Resident last name even if user has - // a single word account name, so it can be compared case-insensitive with the - // user defined "firstname lastname". - S32 res = LLStringUtil::compareInsensitive(canonicalize_username(user_defined_name), iter->first); - if (res != 0) continue; - - combo->addSeparator(); - LLSD user_llsd = iter->second; - for (LLSD::array_const_iterator iter1 = user_llsd.beginArray(); - iter1 != user_llsd.endArray(); ++iter1) - { - std::string label = (*iter1)["name"].asString(); - std::string value = (*iter1)["slurl"].asString(); - if(label != "" && value != "") - { - combo->add(label, value); - } - } - break; - } -} - -// force the size to be correct (XML doesn't seem to be sufficient to do this) -// (with some padding so the other login screen doesn't show through) -void LLPanelLogin::reshapeBrowser() -{ - LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html"); - LLRect rect = gViewerWindow->getWindowRectScaled(); - LLRect html_rect; - html_rect.setCenterAndSize( - rect.getCenterX() - 2, rect.getCenterY() + 40, - rect.getWidth() + 6, rect.getHeight() - 78 ); - web_browser->setRect( html_rect ); - web_browser->reshape( html_rect.getWidth(), html_rect.getHeight(), TRUE ); - reshape( rect.getWidth(), rect.getHeight(), 1 ); -} - -void LLPanelLogin::setSiteIsAlive( bool alive ) -{ - LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html"); - // if the contents of the site was retrieved - if ( alive ) - { - if ( web_browser ) - { - loadLoginPage(); - - // mark as available - mHtmlAvailable = TRUE; - } - } - else - // the site is not available (missing page, server down, other badness) - { - if ( web_browser ) - { - // hide browser control (revealing default one) - web_browser->setVisible( FALSE ); - - // mark as unavailable - mHtmlAvailable = FALSE; - } - } -} - - -LLPanelLogin::~LLPanelLogin() -{ - LLPanelLogin::sInstance = NULL; - - // tell the responder we're not here anymore - if ( gResponsePtr ) - gResponsePtr->setParent( 0 ); - - //// We know we're done with the image, so be rid of it. - //gTextureList.deleteImage( mLogoImage ); - - // Controls having keyboard focus by default - // must reset it on destroy. (EXT-2748) - gFocusMgr.setDefaultKeyboardFocus(NULL); -} - -// virtual -void LLPanelLogin::draw() -{ - glPushMatrix(); - { - F32 image_aspect = 1.333333f; - F32 view_aspect = (F32)getRect().getWidth() / (F32)getRect().getHeight(); - // stretch image to maintain aspect ratio - if (image_aspect > view_aspect) - { - glTranslatef(-0.5f * (image_aspect / view_aspect - 1.f) * getRect().getWidth(), 0.f, 0.f); - glScalef(image_aspect / view_aspect, 1.f, 1.f); - } - - S32 width = getRect().getWidth(); - S32 height = getRect().getHeight(); - - if ( mHtmlAvailable ) - { - if (getChild<LLView>("login_widgets")->getVisible()) - { - // draw a background box in black - gl_rect_2d( 0, height - 264, width, 264, LLColor4::black ); - // draw the bottom part of the background image - // just the blue background to the native client UI - mLogoImage->draw(0, -264, width + 8, mLogoImage->getHeight()); - } - } - else - { - // the HTML login page is not available so default to the original screen - S32 offscreen_part = height / 3; - mLogoImage->draw(0, -offscreen_part, width, height+offscreen_part); - }; - } - glPopMatrix(); - - LLPanel::draw(); -} - -// virtual -BOOL LLPanelLogin::handleKeyHere(KEY key, MASK mask) -{ - if ( KEY_F1 == key ) - { - LLViewerHelp* vhelp = LLViewerHelp::getInstance(); - vhelp->showTopic(vhelp->f1HelpTopic()); - return TRUE; - } - - return LLPanel::handleKeyHere(key, mask); -} - -// virtual -void LLPanelLogin::setFocus(BOOL b) -{ - if(b != hasFocus()) - { - if(b) - { - LLPanelLogin::giveFocus(); - } - else - { - LLPanel::setFocus(b); - } - } -} - -// static -void LLPanelLogin::giveFocus() -{ - if( sInstance ) - { - // Grab focus and move cursor to first blank input field - std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString(); - std::string pass = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString(); - - BOOL have_username = !username.empty(); - BOOL have_pass = !pass.empty(); - - LLLineEditor* edit = NULL; - LLComboBox* combo = NULL; - if (have_username && !have_pass) - { - // User saved his name but not his password. Move - // focus to password field. - edit = sInstance->getChild<LLLineEditor>("password_edit"); - } - else - { - // User doesn't have a name, so start there. - combo = sInstance->getChild<LLComboBox>("username_combo"); - } - - if (edit) - { - edit->setFocus(TRUE); - edit->selectAll(); - } - else if (combo) - { - combo->setFocus(TRUE); - } - } -} - -// static -void LLPanelLogin::showLoginWidgets() -{ - // *NOTE: Mani - This may or may not be obselete code. - // It seems to be part of the defunct? reg-in-client project. - sInstance->getChildView("login_widgets")->setVisible( true); - LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html"); - sInstance->reshapeBrowser(); - // *TODO: Append all the usual login parameters, like first_login=Y etc. - std::string splash_screen_url = LLGridManager::getInstance()->getLoginPage(); - web_browser->navigateTo( splash_screen_url, "text/html" ); - LLUICtrl* username_combo = sInstance->getChild<LLUICtrl>("username_combo"); - username_combo->setFocus(TRUE); -} - -// static -void LLPanelLogin::show(const LLRect &rect, - BOOL show_server, - void (*callback)(S32 option, void* user_data), - void* callback_data) -{ - new LLPanelLogin(rect, show_server, callback, callback_data); - - if( !gFocusMgr.getKeyboardFocus() ) - { - // Grab focus and move cursor to first enabled control - sInstance->setFocus(TRUE); - } - - // Make sure that focus always goes here (and use the latest sInstance that was just created) - gFocusMgr.setDefaultKeyboardFocus(sInstance); -} - -// static -void LLPanelLogin::setFields(LLPointer<LLCredential> credential, - BOOL remember) -{ - if (!sInstance) - { - llwarns << "Attempted fillFields with no login view shown" << llendl; - return; - } - LL_INFOS("Credentials") << "Setting login fields to " << *credential << LL_ENDL; - - LLSD identifier = credential->getIdentifier(); - if((std::string)identifier["type"] == "agent") - { - std::string firstname = identifier["first_name"].asString(); - std::string lastname = identifier["last_name"].asString(); - std::string login_id = firstname; - if (!lastname.empty() && lastname != "Resident") - { - // support traditional First Last name SLURLs - login_id += " "; - login_id += lastname; - } - sInstance->getChild<LLComboBox>("username_combo")->setLabel(login_id); - } - else if((std::string)identifier["type"] == "account") - { - sInstance->getChild<LLComboBox>("username_combo")->setLabel((std::string)identifier["account_name"]); - } - else - { - sInstance->getChild<LLComboBox>("username_combo")->setLabel(std::string()); - } - sInstance->addFavoritesToStartLocation(); - // if the password exists in the credential, set the password field with - // a filler to get some stars - LLSD authenticator = credential->getAuthenticator(); - LL_INFOS("Credentials") << "Setting authenticator field " << authenticator["type"].asString() << LL_ENDL; - if(authenticator.isMap() && - authenticator.has("secret") && - (authenticator["secret"].asString().size() > 0)) - { - - // This is a MD5 hex digest of a password. - // We don't actually use the password input field, - // fill it with MAX_PASSWORD characters so we get a - // nice row of asterixes. - const std::string filler("123456789!123456"); - sInstance->getChild<LLUICtrl>("password_edit")->setValue(std::string("123456789!123456")); - } - else - { - sInstance->getChild<LLUICtrl>("password_edit")->setValue(std::string()); - } - sInstance->getChild<LLUICtrl>("remember_check")->setValue(remember); -} - - -// static -void LLPanelLogin::getFields(LLPointer<LLCredential>& credential, - BOOL& remember) -{ - if (!sInstance) - { - llwarns << "Attempted getFields with no login view shown" << llendl; - return; - } - - // load the credential so we can pass back the stored password or hash if the user did - // not modify the password field. - - credential = gSecAPIHandler->loadCredential(LLGridManager::getInstance()->getGrid()); - - LLSD identifier = LLSD::emptyMap(); - LLSD authenticator = LLSD::emptyMap(); - - if(credential.notNull()) - { - authenticator = credential->getAuthenticator(); - } - - std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString(); - LLStringUtil::trim(username); - std::string password = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString(); - - LL_INFOS2("Credentials", "Authentication") << "retrieving username:" << username << LL_ENDL; - // determine if the username is a first/last form or not. - size_t separator_index = username.find_first_of(' '); - if (separator_index == username.npos - && !LLGridManager::getInstance()->isSystemGrid()) - { - LL_INFOS2("Credentials", "Authentication") << "account: " << username << LL_ENDL; - // single username, so this is a 'clear' identifier - identifier["type"] = CRED_IDENTIFIER_TYPE_ACCOUNT; - identifier["account_name"] = username; - - if (LLPanelLogin::sInstance->mPasswordModified) - { - authenticator = LLSD::emptyMap(); - // password is plaintext - authenticator["type"] = CRED_AUTHENTICATOR_TYPE_CLEAR; - authenticator["secret"] = password; - } - } - else - { - // Be lenient in terms of what separators we allow for two-word names - // and allow legacy users to login with firstname.lastname - separator_index = username.find_first_of(" ._"); - std::string first = username.substr(0, separator_index); - std::string last; - if (separator_index != username.npos) - { - last = username.substr(separator_index+1, username.npos); - LLStringUtil::trim(last); - } - else - { - // ...on Linden grids, single username users as considered to have - // last name "Resident" - // *TODO: Make login.cgi support "account_name" like above - last = "Resident"; - } - - if (last.find_first_of(' ') == last.npos) - { - LL_INFOS2("Credentials", "Authentication") << "agent: " << username << LL_ENDL; - // traditional firstname / lastname - identifier["type"] = CRED_IDENTIFIER_TYPE_AGENT; - identifier["first_name"] = first; - identifier["last_name"] = last; - - if (LLPanelLogin::sInstance->mPasswordModified) - { - authenticator = LLSD::emptyMap(); - authenticator["type"] = CRED_AUTHENTICATOR_TYPE_HASH; - authenticator["algorithm"] = "md5"; - LLMD5 pass((const U8 *)password.c_str()); - char md5pass[33]; /* Flawfinder: ignore */ - pass.hex_digest(md5pass); - authenticator["secret"] = md5pass; - } - } - } - credential = gSecAPIHandler->createCredential(LLGridManager::getInstance()->getGrid(), identifier, authenticator); - remember = sInstance->getChild<LLUICtrl>("remember_check")->getValue(); -} - -// static -BOOL LLPanelLogin::isGridComboDirty() -{ - BOOL user_picked = FALSE; - if (!sInstance) - { - llwarns << "Attempted getServer with no login view shown" << llendl; - } - else - { - LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo"); - user_picked = combo->isDirty(); - } - return user_picked; -} - -// static -BOOL LLPanelLogin::areCredentialFieldsDirty() -{ - if (!sInstance) - { - llwarns << "Attempted getServer with no login view shown" << llendl; - } - else - { - std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString(); - LLStringUtil::trim(username); - std::string password = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString(); - LLComboBox* combo = sInstance->getChild<LLComboBox>("username_combo"); - if(combo && combo->isDirty()) - { - return true; - } - LLLineEditor* ctrl = sInstance->getChild<LLLineEditor>("password_edit"); - if(ctrl && ctrl->isDirty()) - { - return true; - } - } - return false; -} - - -// static -void LLPanelLogin::updateLocationCombo( bool force_visible ) -{ - if (!sInstance) - { - return; - } - - LLComboBox* combo = sInstance->getChild<LLComboBox>("start_location_combo"); - - switch(LLStartUp::getStartSLURL().getType()) - { - case LLSLURL::LOCATION: - { - - combo->setCurrentByIndex( 2 ); - combo->setTextEntry(LLStartUp::getStartSLURL().getLocationString()); - break; - } - case LLSLURL::HOME_LOCATION: - combo->setCurrentByIndex(1); - break; - default: - combo->setCurrentByIndex(0); - break; - } - - BOOL show_start = TRUE; - - if ( ! force_visible ) - show_start = gSavedSettings.getBOOL("ShowStartLocation"); - - sInstance->getChildView("start_location_combo")->setVisible( show_start); - sInstance->getChildView("start_location_text")->setVisible( show_start); - - BOOL show_server = gSavedSettings.getBOOL("ForceShowGrid"); - sInstance->getChildView("server_combo_text")->setVisible( show_server); - sInstance->getChildView("server_combo")->setVisible( show_server); -} - -// static -void LLPanelLogin::updateStartSLURL() -{ - if (!sInstance) return; - - LLComboBox* combo = sInstance->getChild<LLComboBox>("start_location_combo"); - S32 index = combo->getCurrentIndex(); - - switch (index) - { - case 0: - { - LLStartUp::setStartSLURL(LLSLURL(LLSLURL::SIM_LOCATION_LAST)); - break; - } - case 1: - { - LLStartUp::setStartSLURL(LLSLURL(LLSLURL::SIM_LOCATION_HOME)); - break; - } - default: - { - LLSLURL slurl = LLSLURL(combo->getValue().asString()); - if(slurl.getType() == LLSLURL::LOCATION) - { - // we've changed the grid, so update the grid selection - LLStartUp::setStartSLURL(slurl); - } - break; - } - } -} - - -void LLPanelLogin::setLocation(const LLSLURL& slurl) -{ - LLStartUp::setStartSLURL(slurl); - updateServer(); -} - -// static -void LLPanelLogin::closePanel() -{ - if (sInstance) - { - LLPanelLogin::sInstance->getParent()->removeChild( LLPanelLogin::sInstance ); - - delete sInstance; - sInstance = NULL; - } -} - -// static -void LLPanelLogin::setAlwaysRefresh(bool refresh) -{ - if (LLStartUp::getStartupState() >= STATE_LOGIN_CLEANUP) return; - - LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html"); - - if (web_browser) - { - web_browser->setAlwaysRefresh(refresh); - } -} - - - -void LLPanelLogin::loadLoginPage() -{ - if (!sInstance) return; - - std::ostringstream oStr; - - std::string login_page = LLGridManager::getInstance()->getLoginPage(); - - oStr << login_page; - - // Use the right delimeter depending on how LLURI parses the URL - LLURI login_page_uri = LLURI(login_page); - - std::string first_query_delimiter = "&"; - if (login_page_uri.queryMap().size() == 0) - { - first_query_delimiter = "?"; - } - - // Language - std::string language = LLUI::getLanguage(); - oStr << first_query_delimiter<<"lang=" << language; - - // First Login? - if (gSavedSettings.getBOOL("FirstLoginThisInstall")) - { - oStr << "&firstlogin=TRUE"; - } - - // Channel and Version - std::string version = llformat("%s (%d)", - LLVersionInfo::getShortVersion().c_str(), - LLVersionInfo::getBuild()); - - char* curl_channel = curl_escape(LLVersionInfo::getChannel().c_str(), 0); - char* curl_version = curl_escape(version.c_str(), 0); - - oStr << "&channel=" << curl_channel; - oStr << "&version=" << curl_version; - - curl_free(curl_channel); - curl_free(curl_version); - - // Grid - char* curl_grid = curl_escape(LLGridManager::getInstance()->getGridLabel().c_str(), 0); - oStr << "&grid=" << curl_grid; - curl_free(curl_grid); - - // add OS info - char * os_info = curl_escape(LLAppViewer::instance()->getOSInfo().getOSStringSimple().c_str(), 0); - oStr << "&os=" << os_info; - curl_free(os_info); - - - gViewerWindow->setMenuBackgroundColor(false, !LLGridManager::getInstance()->isInProductionGrid()); - gLoginMenuBarView->setBackgroundColor(gMenuBarView->getBackgroundColor()); - - LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html"); - - // navigate to the "real" page - if (gSavedSettings.getBOOL("RegInClient")) - { - web_browser->setFocus(TRUE); - login_page = sInstance->getString("reg_in_client_url"); - web_browser->navigateTo(login_page, "text/html"); - } - else - { - web_browser->navigateTo( oStr.str(), "text/html" ); - } -} - -void LLPanelLogin::handleMediaEvent(LLPluginClassMedia* /*self*/, EMediaEvent event) -{ - if(event == MEDIA_EVENT_NAVIGATE_COMPLETE) - { - LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html"); - if (web_browser) - { - // *HACK HACK HACK HACK! - /* Stuff a Tab key into the browser now so that the first field will - ** get the focus! The embedded javascript on the page that properly - ** sets the initial focus in a real web browser is not working inside - ** the viewer, so this is an UGLY HACK WORKAROUND for now. - */ - // Commented out as it's not reliable - //web_browser->handleKey(KEY_TAB, MASK_NONE, false); - } - } -} - -//--------------------------------------------------------------------------- -// Protected methods -//--------------------------------------------------------------------------- - -// static -void LLPanelLogin::onClickConnect(void *) -{ - if (sInstance && sInstance->mCallback) - { - // tell the responder we're not here anymore - if ( gResponsePtr ) - gResponsePtr->setParent( 0 ); - - // JC - Make sure the fields all get committed. - sInstance->setFocus(FALSE); - - LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo"); - LLSD combo_val = combo->getSelectedValue(); - if (combo_val.isUndefined()) - { - combo_val = combo->getValue(); - } - if(combo_val.isUndefined()) - { - LLNotificationsUtil::add("StartRegionEmpty"); - return; - } - try - { - LLGridManager::getInstance()->setGridChoice(combo_val.asString()); - } - catch (LLInvalidGridName ex) - { - LLSD args; - args["GRID"] = combo_val.asString(); - LLNotificationsUtil::add("InvalidGrid", args); - return; - } - updateStartSLURL(); - std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString(); - - - if(username.empty()) - { - // user must type in something into the username field - LLNotificationsUtil::add("MustHaveAccountToLogIn"); - } - else - { - LLPointer<LLCredential> cred; - BOOL remember; - getFields(cred, remember); - std::string identifier_type; - cred->identifierType(identifier_type); - LLSD allowed_credential_types; - LLGridManager::getInstance()->getLoginIdentifierTypes(allowed_credential_types); - - // check the typed in credential type against the credential types expected by the server. - for(LLSD::array_iterator i = allowed_credential_types.beginArray(); - i != allowed_credential_types.endArray(); - i++) - { - - if(i->asString() == identifier_type) - { - // yay correct credential type - sInstance->mCallback(0, sInstance->mCallbackData); - return; - } - } - - // Right now, maingrid is the only thing that is picky about - // credential format, as it doesn't yet allow account (single username) - // format creds. - Rox. James, we wanna fix the message when we change - // this. - LLNotificationsUtil::add("InvalidCredentialFormat"); - } - } -} - -/* -// static -bool LLPanelLogin::newAccountAlertCallback(const LLSD& notification, const LLSD& response) -{ - S32 option = LLNotificationsUtil::getSelectedOption(notification, response); - if (0 == option) - { - llinfos << "Going to account creation URL" << llendl; - LLWeb::loadURLExternal( LLNotifications::instance().getGlobalString("CREATE_ACCOUNT_URL")); - } - else - { - sInstance->setFocus(TRUE); - } - return false; -} -*/ - -// static -void LLPanelLogin::onClickNewAccount(void*) -{ - LLWeb::loadURLExternal(sInstance->getString("create_account_url")); -} - - -// static -void LLPanelLogin::onClickVersion(void*) -{ - LLFloaterReg::showInstance("sl_about"); -} - -//static -void LLPanelLogin::onClickForgotPassword(void*) -{ - if (sInstance ) - { - LLWeb::loadURLExternal(sInstance->getString( "forgot_password_url" )); - } -} - -//static -void LLPanelLogin::onClickHelp(void*) -{ - if (sInstance) - { - LLViewerHelp* vhelp = LLViewerHelp::getInstance(); - vhelp->showTopic(vhelp->preLoginTopic()); - } -} - -// static -void LLPanelLogin::onPassKey(LLLineEditor* caller, void* user_data) -{ - LLPanelLogin *This = (LLPanelLogin *) user_data; - This->mPasswordModified = TRUE; - if (gKeyboard->getKeyDown(KEY_CAPSLOCK) && sCapslockDidNotification == FALSE) - { -// *TODO: use another way to notify user about enabled caps lock, see EXT-6858 - sCapslockDidNotification = TRUE; - } -} - - -void LLPanelLogin::updateServer() -{ - try - { - - updateServerCombo(); - // if they've selected another grid, we should load the credentials - // for that grid and set them to the UI. - if(sInstance && !sInstance->areCredentialFieldsDirty()) - { - LLPointer<LLCredential> credential = gSecAPIHandler->loadCredential(LLGridManager::getInstance()->getGrid()); - bool remember = sInstance->getChild<LLUICtrl>("remember_check")->getValue(); - sInstance->setFields(credential, remember); - } - // grid changed so show new splash screen (possibly) - loadLoginPage(); - updateLocationCombo(LLStartUp::getStartSLURL().getType() == LLSLURL::LOCATION); - } - catch (LLInvalidGridName ex) - { - // do nothing - } -} - -void LLPanelLogin::updateServerCombo() -{ - if (!sInstance) - { - return; - } - // We add all of the possible values, sorted, and then add a bar and the current value at the top - LLComboBox* server_choice_combo = sInstance->getChild<LLComboBox>("server_combo"); - server_choice_combo->removeall(); - - std::map<std::string, std::string> known_grids = LLGridManager::getInstance()->getKnownGrids(!gSavedSettings.getBOOL("ShowBetaGrids")); - - for (std::map<std::string, std::string>::iterator grid_choice = known_grids.begin(); - grid_choice != known_grids.end(); - grid_choice++) - { - if (!grid_choice->first.empty()) - { - server_choice_combo->add(grid_choice->second, grid_choice->first); - } - } - server_choice_combo->sortByName(); - - server_choice_combo->addSeparator(ADD_TOP); - - server_choice_combo->add(LLGridManager::getInstance()->getGridLabel(), - LLGridManager::getInstance()->getGrid(), ADD_TOP); - - server_choice_combo->selectFirstItem(); -} - -// static -void LLPanelLogin::onSelectServer(LLUICtrl*, void*) -{ - // *NOTE: The paramters for this method are ignored. - // LLPanelLogin::onServerComboLostFocus(LLFocusableElement* fe, void*) - // calls this method. - LL_INFOS("AppInit") << "onSelectServer" << LL_ENDL; - // The user twiddled with the grid choice ui. - // apply the selection to the grid setting. - LLPointer<LLCredential> credential; - - LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo"); - LLSD combo_val = combo->getSelectedValue(); - if (combo_val.isUndefined()) - { - combo_val = combo->getValue(); - } - - combo = sInstance->getChild<LLComboBox>("start_location_combo"); - combo->setCurrentByIndex(1); - LLStartUp::setStartSLURL(LLSLURL(gSavedSettings.getString("LoginLocation"))); - LLGridManager::getInstance()->setGridChoice(combo_val.asString()); - // This new selection will override preset uris - // from the command line. - updateServer(); - updateLocationCombo(false); - updateLoginPanelLinks(); -} - -void LLPanelLogin::onServerComboLostFocus(LLFocusableElement* fe) -{ - if (!sInstance) - { - return; - } - - LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo"); - if(fe == combo) - { - onSelectServer(combo, NULL); - } -} - -void LLPanelLogin::updateLoginPanelLinks() -{ - LLSD grid_data; - LLGridManager::getInstance()->getGridInfo(grid_data); - bool system_grid = grid_data.has(GRID_IS_SYSTEM_GRID_VALUE); - - // need to call through sInstance, as it's called from onSelectServer, which - // is static. - sInstance->getChildView("create_new_account_text")->setVisible( system_grid); - sInstance->getChildView("forgot_password_text")->setVisible( system_grid); -} - -std::string canonicalize_username(const std::string& name) -{ - std::string cname = name; - LLStringUtil::trim(cname); - - // determine if the username is a first/last form or not. - size_t separator_index = cname.find_first_of(" ._"); - std::string first = cname.substr(0, separator_index); - std::string last; - if (separator_index != cname.npos) - { - last = cname.substr(separator_index+1, cname.npos); - LLStringUtil::trim(last); - } - else - { - // ...on Linden grids, single username users as considered to have - // last name "Resident" - last = "Resident"; - } - - // Username in traditional "firstname lastname" form. - return first + ' ' + last; -} +/**
+ * @file llpanellogin.cpp
+ * @brief Login dialog and logo display
+ *
+ * $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 "llpanellogin.h"
+
+#include "indra_constants.h" // for key and mask constants
+#include "llfloaterreg.h"
+#include "llfontgl.h"
+#include "llmd5.h"
+#include "llsecondlifeurls.h"
+#include "v4color.h"
+
+#include "llappviewer.h"
+#include "llbutton.h"
+#include "llcheckboxctrl.h"
+#include "llcommandhandler.h" // for secondlife:///app/login/
+#include "llcombobox.h"
+#include "llcurl.h"
+#include "llviewercontrol.h"
+#include "llfloaterpreference.h"
+#include "llfocusmgr.h"
+#include "lllineeditor.h"
+#include "llnotificationsutil.h"
+#include "llsecapi.h"
+#include "llstartup.h"
+#include "lltextbox.h"
+#include "llui.h"
+#include "lluiconstants.h"
+#include "llslurl.h"
+#include "llversioninfo.h"
+#include "llviewerhelp.h"
+#include "llviewertexturelist.h"
+#include "llviewermenu.h" // for handle_preferences()
+#include "llviewernetwork.h"
+#include "llviewerwindow.h" // to link into child list
+#include "lluictrlfactory.h"
+#include "llhttpclient.h"
+#include "llweb.h"
+#include "llmediactrl.h"
+#include "llrootview.h"
+
+#include "llfloatertos.h"
+#include "lltrans.h"
+#include "llglheaders.h"
+#include "llpanelloginlistener.h"
+
+#if LL_WINDOWS
+#pragma warning(disable: 4355) // 'this' used in initializer list
+#endif // LL_WINDOWS
+
+#include "llsdserialize.h"
+
+const S32 BLACK_BORDER_HEIGHT = 160;
+const S32 MAX_PASSWORD = 16;
+
+LLPanelLogin *LLPanelLogin::sInstance = NULL;
+BOOL LLPanelLogin::sCapslockDidNotification = FALSE;
+
+
+class LLLoginRefreshHandler : public LLCommandHandler
+{
+public:
+ // don't allow from external browsers
+ LLLoginRefreshHandler() : LLCommandHandler("login_refresh", UNTRUSTED_BLOCK) { }
+ bool handle(const LLSD& tokens, const LLSD& query_map, LLMediaCtrl* web)
+ {
+ if (LLStartUp::getStartupState() < STATE_LOGIN_CLEANUP)
+ {
+ LLPanelLogin::loadLoginPage();
+ }
+ return true;
+ }
+};
+
+LLLoginRefreshHandler gLoginRefreshHandler;
+
+
+// helper class that trys to download a URL from a web site and calls a method
+// on parent class indicating if the web server is working or not
+class LLIamHereLogin : public LLHTTPClient::Responder
+{
+ private:
+ LLIamHereLogin( LLPanelLogin* parent ) :
+ mParent( parent )
+ {}
+
+ LLPanelLogin* mParent;
+
+ public:
+ static boost::intrusive_ptr< LLIamHereLogin > build( LLPanelLogin* parent )
+ {
+ return boost::intrusive_ptr< LLIamHereLogin >( new LLIamHereLogin( parent ) );
+ };
+
+ virtual void setParent( LLPanelLogin* parentIn )
+ {
+ mParent = parentIn;
+ };
+
+ // We don't actually expect LLSD back, so need to override completedRaw
+ virtual void completedRaw(U32 status, const std::string& reason,
+ const LLChannelDescriptors& channels,
+ const LLIOPipe::buffer_ptr_t& buffer)
+ {
+ completed(status, reason, LLSD()); // will call result() or error()
+ }
+
+ virtual void result( const LLSD& content )
+ {
+ if ( mParent )
+ mParent->setSiteIsAlive( true );
+ };
+
+ virtual void error( U32 status, const std::string& reason )
+ {
+ if ( mParent )
+ mParent->setSiteIsAlive( false );
+ };
+};
+
+// this is global and not a class member to keep crud out of the header file
+namespace {
+ boost::intrusive_ptr< LLIamHereLogin > gResponsePtr = 0;
+};
+
+
+//---------------------------------------------------------------------------
+// Public methods
+//---------------------------------------------------------------------------
+LLPanelLogin::LLPanelLogin(const LLRect &rect,
+ BOOL show_server,
+ void (*callback)(S32 option, void* user_data),
+ void *cb_data)
+: LLPanel(),
+ mLogoImage(),
+ mCallback(callback),
+ mCallbackData(cb_data),
+ mHtmlAvailable( TRUE ),
+ mListener(new LLPanelLoginListener(this))
+{
+ setBackgroundVisible(FALSE);
+ setBackgroundOpaque(TRUE);
+
+ // instance management
+ if (LLPanelLogin::sInstance)
+ {
+ llwarns << "Duplicate instance of login view deleted" << llendl;
+ // Don't leave bad pointer in gFocusMgr
+ gFocusMgr.setDefaultKeyboardFocus(NULL);
+
+ delete LLPanelLogin::sInstance;
+ }
+
+ mPasswordModified = FALSE;
+ LLPanelLogin::sInstance = this;
+
+ LLView* login_holder = gViewerWindow->getLoginPanelHolder();
+ if (login_holder)
+ {
+ login_holder->addChild(this);
+ }
+
+ // Logo
+ mLogoImage = LLUI::getUIImage("startup_logo");
+
+ buildFromFile( "panel_login.xml");
+
+ // Legacy login web page is hidden under the menu bar.
+ // Adjust reg-in-client web browser widget to not be hidden.
+ if (gSavedSettings.getBOOL("RegInClient"))
+ {
+ reshape(rect.getWidth(), rect.getHeight() - MENU_BAR_HEIGHT);
+ }
+ else
+ {
+ reshape(rect.getWidth(), rect.getHeight());
+ }
+
+ getChild<LLLineEditor>("password_edit")->setKeystrokeCallback(onPassKey, this);
+
+ // change z sort of clickable text to be behind buttons
+ //sendChildToBack(getChildView("channel_text"));
+ sendChildToBack(getChildView("forgot_password_text"));
+
+ if(LLStartUp::getStartSLURL().getType() != LLSLURL::LOCATION)
+ {
+ LLSLURL slurl(gSavedSettings.getString("LoginLocation"));
+ LLStartUp::setStartSLURL(slurl);
+ }
+ updateLocationCombo(false);
+
+ gSavedSettings.getControl("SessionSettingsFile")->getSignal()->connect(boost::bind(&onModeChange));
+
+ LLComboBox* server_choice_combo = sInstance->getChild<LLComboBox>("server_combo");
+ server_choice_combo->setCommitCallback(onSelectServer, NULL);
+ server_choice_combo->setFocusLostCallback(boost::bind(onServerComboLostFocus, _1));
+ updateServerCombo();
+
+ childSetAction("connect_btn", onClickConnect, this);
+
+ getChild<LLPanel>("login")->setDefaultBtn("connect_btn");
+
+ std::string channel = LLVersionInfo::getChannel();
+ std::string version = llformat("%s (%d)",
+ LLVersionInfo::getShortVersion().c_str(),
+ LLVersionInfo::getBuild());
+ //LLTextBox* channel_text = getChild<LLTextBox>("channel_text");
+ //channel_text->setTextArg("[CHANNEL]", channel); // though not displayed
+ //channel_text->setTextArg("[VERSION]", version);
+ //channel_text->setClickedCallback(onClickVersion, this);
+
+ LLTextBox* forgot_password_text = getChild<LLTextBox>("forgot_password_text");
+ forgot_password_text->setClickedCallback(onClickForgotPassword, NULL);
+
+ LLTextBox* create_new_account_text = getChild<LLTextBox>("create_new_account_text");
+ create_new_account_text->setClickedCallback(onClickNewAccount, NULL);
+
+ LLTextBox* need_help_text = getChild<LLTextBox>("login_help");
+ need_help_text->setClickedCallback(onClickHelp, NULL);
+
+ // get the web browser control
+ LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html");
+ web_browser->addObserver(this);
+
+ // Clear the browser's cache to avoid any potential for the cache messing up the login screen.
+ web_browser->clearCache();
+
+ reshapeBrowser();
+
+ // kick off a request to grab the url manually
+ gResponsePtr = LLIamHereLogin::build( this );
+
+ LLHTTPClient::head( LLGridManager::getInstance()->getLoginPage(), gResponsePtr );
+
+ // Show last logged in user favorites in "Start at" combo.
+ addUsersWithFavoritesToUsername();
+ getChild<LLComboBox>("username_combo")->setTextChangedCallback(boost::bind(&LLPanelLogin::addFavoritesToStartLocation, this));
+
+ updateLocationCombo(false);
+
+}
+
+void LLPanelLogin::addUsersWithFavoritesToUsername()
+{
+ LLComboBox* combo = getChild<LLComboBox>("username_combo");
+ if (!combo) return;
+ std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml");
+ LLSD fav_llsd;
+ llifstream file;
+ file.open(filename);
+ if (!file.is_open()) return;
+ LLSDSerialize::fromXML(fav_llsd, file);
+ for (LLSD::map_const_iterator iter = fav_llsd.beginMap();
+ iter != fav_llsd.endMap(); ++iter)
+ {
+ combo->add(iter->first);
+ }
+}
+
+void LLPanelLogin::addFavoritesToStartLocation()
+{
+ LLComboBox* combo = getChild<LLComboBox>("start_location_combo");
+ if (!combo) return;
+ int num_items = combo->getItemCount();
+ for (int i = num_items - 1; i > 2; i--)
+ {
+ combo->remove(i);
+ }
+ std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml");
+ LLSD fav_llsd;
+ llifstream file;
+ file.open(filename);
+ if (!file.is_open()) return;
+ LLSDSerialize::fromXML(fav_llsd, file);
+ for (LLSD::map_const_iterator iter = fav_llsd.beginMap();
+ iter != fav_llsd.endMap(); ++iter)
+ {
+ if(iter->first != getChild<LLComboBox>("username_combo")->getSimple()) continue;
+ combo->addSeparator();
+ LLSD user_llsd = iter->second;
+ for (LLSD::array_const_iterator iter1 = user_llsd.beginArray();
+ iter1 != user_llsd.endArray(); ++iter1)
+ {
+ std::string label = (*iter1)["name"].asString();
+ std::string value = (*iter1)["slurl"].asString();
+ if(label != "" && value != "")
+ {
+ combo->add(label, value);
+ }
+ }
+ break;
+ }
+}
+
+// force the size to be correct (XML doesn't seem to be sufficient to do this)
+// (with some padding so the other login screen doesn't show through)
+void LLPanelLogin::reshapeBrowser()
+{
+ LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html");
+ LLRect rect = gViewerWindow->getWindowRectScaled();
+ LLRect html_rect;
+ html_rect.setCenterAndSize(
+ rect.getCenterX() - 2, rect.getCenterY() + 40,
+ rect.getWidth() + 6, rect.getHeight() - 78 );
+ web_browser->setRect( html_rect );
+ web_browser->reshape( html_rect.getWidth(), html_rect.getHeight(), TRUE );
+ reshape( rect.getWidth(), rect.getHeight(), 1 );
+}
+
+void LLPanelLogin::setSiteIsAlive( bool alive )
+{
+ LLMediaCtrl* web_browser = getChild<LLMediaCtrl>("login_html");
+ // if the contents of the site was retrieved
+ if ( alive )
+ {
+ if ( web_browser )
+ {
+ loadLoginPage();
+
+ // mark as available
+ mHtmlAvailable = TRUE;
+ }
+ }
+ else
+ // the site is not available (missing page, server down, other badness)
+ {
+ if ( web_browser )
+ {
+ // hide browser control (revealing default one)
+ web_browser->setVisible( FALSE );
+
+ // mark as unavailable
+ mHtmlAvailable = FALSE;
+ }
+ }
+}
+
+
+LLPanelLogin::~LLPanelLogin()
+{
+ LLPanelLogin::sInstance = NULL;
+
+ // tell the responder we're not here anymore
+ if ( gResponsePtr )
+ gResponsePtr->setParent( 0 );
+
+ //// We know we're done with the image, so be rid of it.
+ //gTextureList.deleteImage( mLogoImage );
+
+ // Controls having keyboard focus by default
+ // must reset it on destroy. (EXT-2748)
+ gFocusMgr.setDefaultKeyboardFocus(NULL);
+}
+
+// virtual
+void LLPanelLogin::draw()
+{
+ glPushMatrix();
+ {
+ F32 image_aspect = 1.333333f;
+ F32 view_aspect = (F32)getRect().getWidth() / (F32)getRect().getHeight();
+ // stretch image to maintain aspect ratio
+ if (image_aspect > view_aspect)
+ {
+ glTranslatef(-0.5f * (image_aspect / view_aspect - 1.f) * getRect().getWidth(), 0.f, 0.f);
+ glScalef(image_aspect / view_aspect, 1.f, 1.f);
+ }
+
+ S32 width = getRect().getWidth();
+ S32 height = getRect().getHeight();
+
+ if ( mHtmlAvailable )
+ {
+ if (getChild<LLView>("login_widgets")->getVisible())
+ {
+ // draw a background box in black
+ gl_rect_2d( 0, height - 264, width, 264, LLColor4::black );
+ // draw the bottom part of the background image
+ // just the blue background to the native client UI
+ mLogoImage->draw(0, -264, width + 8, mLogoImage->getHeight());
+ }
+ }
+ else
+ {
+ // the HTML login page is not available so default to the original screen
+ S32 offscreen_part = height / 3;
+ mLogoImage->draw(0, -offscreen_part, width, height+offscreen_part);
+ };
+ }
+ glPopMatrix();
+
+ LLPanel::draw();
+}
+
+// virtual
+BOOL LLPanelLogin::handleKeyHere(KEY key, MASK mask)
+{
+ if ( KEY_F1 == key )
+ {
+ LLViewerHelp* vhelp = LLViewerHelp::getInstance();
+ vhelp->showTopic(vhelp->f1HelpTopic());
+ return TRUE;
+ }
+
+ return LLPanel::handleKeyHere(key, mask);
+}
+
+// virtual
+void LLPanelLogin::setFocus(BOOL b)
+{
+ if(b != hasFocus())
+ {
+ if(b)
+ {
+ LLPanelLogin::giveFocus();
+ }
+ else
+ {
+ LLPanel::setFocus(b);
+ }
+ }
+}
+
+// static
+void LLPanelLogin::giveFocus()
+{
+ if( sInstance )
+ {
+ // Grab focus and move cursor to first blank input field
+ std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString();
+ std::string pass = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString();
+
+ BOOL have_username = !username.empty();
+ BOOL have_pass = !pass.empty();
+
+ LLLineEditor* edit = NULL;
+ LLComboBox* combo = NULL;
+ if (have_username && !have_pass)
+ {
+ // User saved his name but not his password. Move
+ // focus to password field.
+ edit = sInstance->getChild<LLLineEditor>("password_edit");
+ }
+ else
+ {
+ // User doesn't have a name, so start there.
+ combo = sInstance->getChild<LLComboBox>("username_combo");
+ }
+
+ if (edit)
+ {
+ edit->setFocus(TRUE);
+ edit->selectAll();
+ }
+ else if (combo)
+ {
+ combo->setFocus(TRUE);
+ }
+ }
+}
+
+// static
+void LLPanelLogin::showLoginWidgets()
+{
+ // *NOTE: Mani - This may or may not be obselete code.
+ // It seems to be part of the defunct? reg-in-client project.
+ sInstance->getChildView("login_widgets")->setVisible( true);
+ LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html");
+ sInstance->reshapeBrowser();
+ // *TODO: Append all the usual login parameters, like first_login=Y etc.
+ std::string splash_screen_url = LLGridManager::getInstance()->getLoginPage();
+ web_browser->navigateTo( splash_screen_url, "text/html" );
+ LLUICtrl* username_combo = sInstance->getChild<LLUICtrl>("username_combo");
+ username_combo->setFocus(TRUE);
+}
+
+// static
+void LLPanelLogin::show(const LLRect &rect,
+ BOOL show_server,
+ void (*callback)(S32 option, void* user_data),
+ void* callback_data)
+{
+ new LLPanelLogin(rect, show_server, callback, callback_data);
+
+ if( !gFocusMgr.getKeyboardFocus() )
+ {
+ // Grab focus and move cursor to first enabled control
+ sInstance->setFocus(TRUE);
+ }
+
+ // Make sure that focus always goes here (and use the latest sInstance that was just created)
+ gFocusMgr.setDefaultKeyboardFocus(sInstance);
+}
+
+// static
+void LLPanelLogin::setFields(LLPointer<LLCredential> credential,
+ BOOL remember)
+{
+ if (!sInstance)
+ {
+ llwarns << "Attempted fillFields with no login view shown" << llendl;
+ return;
+ }
+ LL_INFOS("Credentials") << "Setting login fields to " << *credential << LL_ENDL;
+
+ LLSD identifier = credential->getIdentifier();
+ if((std::string)identifier["type"] == "agent")
+ {
+ std::string firstname = identifier["first_name"].asString();
+ std::string lastname = identifier["last_name"].asString();
+ std::string login_id = firstname;
+ if (!lastname.empty() && lastname != "Resident")
+ {
+ // support traditional First Last name SLURLs
+ login_id += " ";
+ login_id += lastname;
+ }
+ sInstance->getChild<LLComboBox>("username_combo")->setLabel(login_id);
+ }
+ else if((std::string)identifier["type"] == "account")
+ {
+ sInstance->getChild<LLComboBox>("username_combo")->setLabel((std::string)identifier["account_name"]);
+ }
+ else
+ {
+ sInstance->getChild<LLComboBox>("username_combo")->setLabel(std::string());
+ }
+ sInstance->addFavoritesToStartLocation();
+ // if the password exists in the credential, set the password field with
+ // a filler to get some stars
+ LLSD authenticator = credential->getAuthenticator();
+ LL_INFOS("Credentials") << "Setting authenticator field " << authenticator["type"].asString() << LL_ENDL;
+ if(authenticator.isMap() &&
+ authenticator.has("secret") &&
+ (authenticator["secret"].asString().size() > 0))
+ {
+
+ // This is a MD5 hex digest of a password.
+ // We don't actually use the password input field,
+ // fill it with MAX_PASSWORD characters so we get a
+ // nice row of asterixes.
+ const std::string filler("123456789!123456");
+ sInstance->getChild<LLUICtrl>("password_edit")->setValue(std::string("123456789!123456"));
+ }
+ else
+ {
+ sInstance->getChild<LLUICtrl>("password_edit")->setValue(std::string());
+ }
+ sInstance->getChild<LLUICtrl>("remember_check")->setValue(remember);
+}
+
+
+// static
+void LLPanelLogin::getFields(LLPointer<LLCredential>& credential,
+ BOOL& remember)
+{
+ if (!sInstance)
+ {
+ llwarns << "Attempted getFields with no login view shown" << llendl;
+ return;
+ }
+
+ // load the credential so we can pass back the stored password or hash if the user did
+ // not modify the password field.
+
+ credential = gSecAPIHandler->loadCredential(LLGridManager::getInstance()->getGrid());
+
+ LLSD identifier = LLSD::emptyMap();
+ LLSD authenticator = LLSD::emptyMap();
+
+ if(credential.notNull())
+ {
+ authenticator = credential->getAuthenticator();
+ }
+
+ std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString();
+ LLStringUtil::trim(username);
+ std::string password = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString();
+
+ LL_INFOS2("Credentials", "Authentication") << "retrieving username:" << username << LL_ENDL;
+ // determine if the username is a first/last form or not.
+ size_t separator_index = username.find_first_of(' ');
+ if (separator_index == username.npos
+ && !LLGridManager::getInstance()->isSystemGrid())
+ {
+ LL_INFOS2("Credentials", "Authentication") << "account: " << username << LL_ENDL;
+ // single username, so this is a 'clear' identifier
+ identifier["type"] = CRED_IDENTIFIER_TYPE_ACCOUNT;
+ identifier["account_name"] = username;
+
+ if (LLPanelLogin::sInstance->mPasswordModified)
+ {
+ authenticator = LLSD::emptyMap();
+ // password is plaintext
+ authenticator["type"] = CRED_AUTHENTICATOR_TYPE_CLEAR;
+ authenticator["secret"] = password;
+ }
+ }
+ else
+ {
+ // Be lenient in terms of what separators we allow for two-word names
+ // and allow legacy users to login with firstname.lastname
+ separator_index = username.find_first_of(" ._");
+ std::string first = username.substr(0, separator_index);
+ std::string last;
+ if (separator_index != username.npos)
+ {
+ last = username.substr(separator_index+1, username.npos);
+ LLStringUtil::trim(last);
+ }
+ else
+ {
+ // ...on Linden grids, single username users as considered to have
+ // last name "Resident"
+ // *TODO: Make login.cgi support "account_name" like above
+ last = "Resident";
+ }
+
+ if (last.find_first_of(' ') == last.npos)
+ {
+ LL_INFOS2("Credentials", "Authentication") << "agent: " << username << LL_ENDL;
+ // traditional firstname / lastname
+ identifier["type"] = CRED_IDENTIFIER_TYPE_AGENT;
+ identifier["first_name"] = first;
+ identifier["last_name"] = last;
+
+ if (LLPanelLogin::sInstance->mPasswordModified)
+ {
+ authenticator = LLSD::emptyMap();
+ authenticator["type"] = CRED_AUTHENTICATOR_TYPE_HASH;
+ authenticator["algorithm"] = "md5";
+ LLMD5 pass((const U8 *)password.c_str());
+ char md5pass[33]; /* Flawfinder: ignore */
+ pass.hex_digest(md5pass);
+ authenticator["secret"] = md5pass;
+ }
+ }
+ }
+ credential = gSecAPIHandler->createCredential(LLGridManager::getInstance()->getGrid(), identifier, authenticator);
+ remember = sInstance->getChild<LLUICtrl>("remember_check")->getValue();
+}
+
+// static
+BOOL LLPanelLogin::isGridComboDirty()
+{
+ BOOL user_picked = FALSE;
+ if (!sInstance)
+ {
+ llwarns << "Attempted getServer with no login view shown" << llendl;
+ }
+ else
+ {
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo");
+ user_picked = combo->isDirty();
+ }
+ return user_picked;
+}
+
+// static
+BOOL LLPanelLogin::areCredentialFieldsDirty()
+{
+ if (!sInstance)
+ {
+ llwarns << "Attempted getServer with no login view shown" << llendl;
+ }
+ else
+ {
+ std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString();
+ LLStringUtil::trim(username);
+ std::string password = sInstance->getChild<LLUICtrl>("password_edit")->getValue().asString();
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("username_combo");
+ if(combo && combo->isDirty())
+ {
+ return true;
+ }
+ LLLineEditor* ctrl = sInstance->getChild<LLLineEditor>("password_edit");
+ if(ctrl && ctrl->isDirty())
+ {
+ return true;
+ }
+ }
+ return false;
+}
+
+
+// static
+void LLPanelLogin::updateLocationCombo( bool force_visible )
+{
+ if (!sInstance)
+ {
+ return;
+ }
+
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("start_location_combo");
+
+ switch(LLStartUp::getStartSLURL().getType())
+ {
+ case LLSLURL::LOCATION:
+ {
+
+ combo->setCurrentByIndex( 2 );
+ combo->setTextEntry(LLStartUp::getStartSLURL().getLocationString());
+ break;
+ }
+ case LLSLURL::HOME_LOCATION:
+ combo->setCurrentByIndex(1);
+ break;
+ default:
+ combo->setCurrentByIndex(0);
+ break;
+ }
+
+ BOOL show_start = TRUE;
+
+ if ( ! force_visible )
+ show_start = gSavedSettings.getBOOL("ShowStartLocation");
+
+ sInstance->getChildView("start_location_combo")->setVisible( show_start);
+ sInstance->getChildView("start_location_text")->setVisible( show_start);
+
+ BOOL show_server = gSavedSettings.getBOOL("ForceShowGrid");
+ sInstance->getChildView("server_combo_text")->setVisible( show_server);
+ sInstance->getChildView("server_combo")->setVisible( show_server);
+}
+
+// static
+void LLPanelLogin::updateStartSLURL()
+{
+ if (!sInstance) return;
+
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("start_location_combo");
+ S32 index = combo->getCurrentIndex();
+
+ switch (index)
+ {
+ case 0:
+ {
+ LLStartUp::setStartSLURL(LLSLURL(LLSLURL::SIM_LOCATION_LAST));
+ break;
+ }
+ case 1:
+ {
+ LLStartUp::setStartSLURL(LLSLURL(LLSLURL::SIM_LOCATION_HOME));
+ break;
+ }
+ default:
+ {
+ LLSLURL slurl = LLSLURL(combo->getValue().asString());
+ if(slurl.getType() == LLSLURL::LOCATION)
+ {
+ // we've changed the grid, so update the grid selection
+ LLStartUp::setStartSLURL(slurl);
+ }
+ break;
+ }
+ }
+}
+
+
+void LLPanelLogin::setLocation(const LLSLURL& slurl)
+{
+ LLStartUp::setStartSLURL(slurl);
+ updateServer();
+}
+
+// static
+void LLPanelLogin::closePanel()
+{
+ if (sInstance)
+ {
+ LLPanelLogin::sInstance->getParent()->removeChild( LLPanelLogin::sInstance );
+
+ delete sInstance;
+ sInstance = NULL;
+ }
+}
+
+// static
+void LLPanelLogin::setAlwaysRefresh(bool refresh)
+{
+ if (LLStartUp::getStartupState() >= STATE_LOGIN_CLEANUP) return;
+
+ LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html");
+
+ if (web_browser)
+ {
+ web_browser->setAlwaysRefresh(refresh);
+ }
+}
+
+
+
+void LLPanelLogin::loadLoginPage()
+{
+ if (!sInstance) return;
+
+ std::ostringstream oStr;
+
+ std::string login_page = LLGridManager::getInstance()->getLoginPage();
+
+ oStr << login_page;
+
+ // Use the right delimeter depending on how LLURI parses the URL
+ LLURI login_page_uri = LLURI(login_page);
+
+ std::string first_query_delimiter = "&";
+ if (login_page_uri.queryMap().size() == 0)
+ {
+ first_query_delimiter = "?";
+ }
+
+ // Language
+ std::string language = LLUI::getLanguage();
+ oStr << first_query_delimiter<<"lang=" << language;
+
+ // First Login?
+ if (gSavedSettings.getBOOL("FirstLoginThisInstall"))
+ {
+ oStr << "&firstlogin=TRUE";
+ }
+
+ // Channel and Version
+ std::string version = llformat("%s (%d)",
+ LLVersionInfo::getShortVersion().c_str(),
+ LLVersionInfo::getBuild());
+
+ char* curl_channel = curl_escape(LLVersionInfo::getChannel().c_str(), 0);
+ char* curl_version = curl_escape(version.c_str(), 0);
+
+ oStr << "&channel=" << curl_channel;
+ oStr << "&version=" << curl_version;
+
+ curl_free(curl_channel);
+ curl_free(curl_version);
+
+ // Grid
+ char* curl_grid = curl_escape(LLGridManager::getInstance()->getGridLabel().c_str(), 0);
+ oStr << "&grid=" << curl_grid;
+ curl_free(curl_grid);
+
+ // add OS info
+ char * os_info = curl_escape(LLAppViewer::instance()->getOSInfo().getOSStringSimple().c_str(), 0);
+ oStr << "&os=" << os_info;
+ curl_free(os_info);
+
+
+ gViewerWindow->setMenuBackgroundColor(false, !LLGridManager::getInstance()->isInProductionGrid());
+ gLoginMenuBarView->setBackgroundColor(gMenuBarView->getBackgroundColor());
+
+ LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html");
+
+ // navigate to the "real" page
+ if (gSavedSettings.getBOOL("RegInClient"))
+ {
+ web_browser->setFocus(TRUE);
+ login_page = sInstance->getString("reg_in_client_url");
+ web_browser->navigateTo(login_page, "text/html");
+ }
+ else
+ {
+ web_browser->navigateTo( oStr.str(), "text/html" );
+ }
+}
+
+void LLPanelLogin::handleMediaEvent(LLPluginClassMedia* /*self*/, EMediaEvent event)
+{
+ if(event == MEDIA_EVENT_NAVIGATE_COMPLETE)
+ {
+ LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html");
+ if (web_browser)
+ {
+ // *HACK HACK HACK HACK!
+ /* Stuff a Tab key into the browser now so that the first field will
+ ** get the focus! The embedded javascript on the page that properly
+ ** sets the initial focus in a real web browser is not working inside
+ ** the viewer, so this is an UGLY HACK WORKAROUND for now.
+ */
+ // Commented out as it's not reliable
+ //web_browser->handleKey(KEY_TAB, MASK_NONE, false);
+ }
+ }
+}
+
+//---------------------------------------------------------------------------
+// Protected methods
+//---------------------------------------------------------------------------
+
+// static
+void LLPanelLogin::onClickConnect(void *)
+{
+ if (sInstance && sInstance->mCallback)
+ {
+ // tell the responder we're not here anymore
+ if ( gResponsePtr )
+ gResponsePtr->setParent( 0 );
+
+ // JC - Make sure the fields all get committed.
+ sInstance->setFocus(FALSE);
+
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo");
+ LLSD combo_val = combo->getSelectedValue();
+ if (combo_val.isUndefined())
+ {
+ combo_val = combo->getValue();
+ }
+ if(combo_val.isUndefined())
+ {
+ LLNotificationsUtil::add("StartRegionEmpty");
+ return;
+ }
+ try
+ {
+ LLGridManager::getInstance()->setGridChoice(combo_val.asString());
+ }
+ catch (LLInvalidGridName ex)
+ {
+ LLSD args;
+ args["GRID"] = combo_val.asString();
+ LLNotificationsUtil::add("InvalidGrid", args);
+ return;
+ }
+ updateStartSLURL();
+ std::string username = sInstance->getChild<LLUICtrl>("username_combo")->getValue().asString();
+
+
+ if(username.empty())
+ {
+ // user must type in something into the username field
+ LLNotificationsUtil::add("MustHaveAccountToLogIn");
+ }
+ else
+ {
+ LLPointer<LLCredential> cred;
+ BOOL remember;
+ getFields(cred, remember);
+ std::string identifier_type;
+ cred->identifierType(identifier_type);
+ LLSD allowed_credential_types;
+ LLGridManager::getInstance()->getLoginIdentifierTypes(allowed_credential_types);
+
+ // check the typed in credential type against the credential types expected by the server.
+ for(LLSD::array_iterator i = allowed_credential_types.beginArray();
+ i != allowed_credential_types.endArray();
+ i++)
+ {
+
+ if(i->asString() == identifier_type)
+ {
+ // yay correct credential type
+ sInstance->mCallback(0, sInstance->mCallbackData);
+ return;
+ }
+ }
+
+ // Right now, maingrid is the only thing that is picky about
+ // credential format, as it doesn't yet allow account (single username)
+ // format creds. - Rox. James, we wanna fix the message when we change
+ // this.
+ LLNotificationsUtil::add("InvalidCredentialFormat");
+ }
+ }
+}
+
+/*
+// static
+bool LLPanelLogin::newAccountAlertCallback(const LLSD& notification, const LLSD& response)
+{
+ S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
+ if (0 == option)
+ {
+ llinfos << "Going to account creation URL" << llendl;
+ LLWeb::loadURLExternal( LLNotifications::instance().getGlobalString("CREATE_ACCOUNT_URL"));
+ }
+ else
+ {
+ sInstance->setFocus(TRUE);
+ }
+ return false;
+}
+*/
+
+// static
+void LLPanelLogin::onClickNewAccount(void*)
+{
+ LLWeb::loadURLExternal(sInstance->getString("create_account_url"));
+}
+
+
+// static
+void LLPanelLogin::onClickVersion(void*)
+{
+ LLFloaterReg::showInstance("sl_about");
+}
+
+//static
+void LLPanelLogin::onClickForgotPassword(void*)
+{
+ if (sInstance )
+ {
+ LLWeb::loadURLExternal(sInstance->getString( "forgot_password_url" ));
+ }
+}
+
+//static
+void LLPanelLogin::onClickHelp(void*)
+{
+ if (sInstance)
+ {
+ LLViewerHelp* vhelp = LLViewerHelp::getInstance();
+ vhelp->showTopic(vhelp->preLoginTopic());
+ }
+}
+
+// static
+void LLPanelLogin::onPassKey(LLLineEditor* caller, void* user_data)
+{
+ LLPanelLogin *This = (LLPanelLogin *) user_data;
+ This->mPasswordModified = TRUE;
+ if (gKeyboard->getKeyDown(KEY_CAPSLOCK) && sCapslockDidNotification == FALSE)
+ {
+// *TODO: use another way to notify user about enabled caps lock, see EXT-6858
+ sCapslockDidNotification = TRUE;
+ }
+}
+
+
+void LLPanelLogin::updateServer()
+{
+ try
+ {
+
+ updateServerCombo();
+ // if they've selected another grid, we should load the credentials
+ // for that grid and set them to the UI.
+ if(sInstance && !sInstance->areCredentialFieldsDirty())
+ {
+ LLPointer<LLCredential> credential = gSecAPIHandler->loadCredential(LLGridManager::getInstance()->getGrid());
+ bool remember = sInstance->getChild<LLUICtrl>("remember_check")->getValue();
+ sInstance->setFields(credential, remember);
+ }
+ // grid changed so show new splash screen (possibly)
+ loadLoginPage();
+ updateLocationCombo(LLStartUp::getStartSLURL().getType() == LLSLURL::LOCATION);
+ }
+ catch (LLInvalidGridName ex)
+ {
+ // do nothing
+ }
+}
+
+void LLPanelLogin::updateServerCombo()
+{
+ if (!sInstance)
+ {
+ return;
+ }
+ // We add all of the possible values, sorted, and then add a bar and the current value at the top
+ LLComboBox* server_choice_combo = sInstance->getChild<LLComboBox>("server_combo");
+ server_choice_combo->removeall();
+
+ std::map<std::string, std::string> known_grids = LLGridManager::getInstance()->getKnownGrids(!gSavedSettings.getBOOL("ShowBetaGrids"));
+
+ for (std::map<std::string, std::string>::iterator grid_choice = known_grids.begin();
+ grid_choice != known_grids.end();
+ grid_choice++)
+ {
+ if (!grid_choice->first.empty())
+ {
+ server_choice_combo->add(grid_choice->second, grid_choice->first);
+ }
+ }
+ server_choice_combo->sortByName();
+
+ server_choice_combo->addSeparator(ADD_TOP);
+
+ server_choice_combo->add(LLGridManager::getInstance()->getGridLabel(),
+ LLGridManager::getInstance()->getGrid(), ADD_TOP);
+
+ server_choice_combo->selectFirstItem();
+}
+
+// static
+void LLPanelLogin::onSelectServer(LLUICtrl*, void*)
+{
+ // *NOTE: The paramters for this method are ignored.
+ // LLPanelLogin::onServerComboLostFocus(LLFocusableElement* fe, void*)
+ // calls this method.
+ LL_INFOS("AppInit") << "onSelectServer" << LL_ENDL;
+ // The user twiddled with the grid choice ui.
+ // apply the selection to the grid setting.
+ LLPointer<LLCredential> credential;
+
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo");
+ LLSD combo_val = combo->getSelectedValue();
+ if (combo_val.isUndefined())
+ {
+ combo_val = combo->getValue();
+ }
+
+ combo = sInstance->getChild<LLComboBox>("start_location_combo");
+ combo->setCurrentByIndex(1);
+ LLStartUp::setStartSLURL(LLSLURL(gSavedSettings.getString("LoginLocation")));
+ LLGridManager::getInstance()->setGridChoice(combo_val.asString());
+ // This new selection will override preset uris
+ // from the command line.
+ updateServer();
+ updateLocationCombo(false);
+ updateLoginPanelLinks();
+}
+
+void LLPanelLogin::onServerComboLostFocus(LLFocusableElement* fe)
+{
+ if (!sInstance)
+ {
+ return;
+ }
+
+ LLComboBox* combo = sInstance->getChild<LLComboBox>("server_combo");
+ if(fe == combo)
+ {
+ onSelectServer(combo, NULL);
+ }
+}
+
+void LLPanelLogin::updateLoginPanelLinks()
+{
+ LLSD grid_data;
+ LLGridManager::getInstance()->getGridInfo(grid_data);
+ bool system_grid = grid_data.has(GRID_IS_SYSTEM_GRID_VALUE);
+
+ // need to call through sInstance, as it's called from onSelectServer, which
+ // is static.
+ sInstance->getChildView("create_new_account_text")->setVisible( system_grid);
+ sInstance->getChildView("forgot_password_text")->setVisible( system_grid);
+}
+
+//static
+void LLPanelLogin::onModeChange()
+{
+ LLNotificationsUtil::add("ModeChange", LLSD(), LLSD(), boost::bind(&onModeChangeConfirm, _1, _2));
+}
+
+//static
+void LLPanelLogin::onModeChangeConfirm(const LLSD& notification, const LLSD& response)
+{
+ S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
+ switch (option)
+ {
+ case 0:
+ LLAppViewer::instance()->requestQuit();
+ break;
+ case 1:
+ // do nothing
+ break;
+ default:
+ break;
+ }
+}
diff --git a/indra/newview/llpanellogin.h b/indra/newview/llpanellogin.h index 1ef6539ecc..1430bec832 100644 --- a/indra/newview/llpanellogin.h +++ b/indra/newview/llpanellogin.h @@ -98,6 +98,8 @@ private: static void onServerComboLostFocus(LLFocusableElement*); static void updateServerCombo(); static void updateStartSLURL(); + static void onModeChange(); + static void onModeChangeConfirm(const LLSD& notification, const LLSD& response); static void updateLoginPanelLinks(); diff --git a/indra/newview/llpanelpicks.cpp b/indra/newview/llpanelpicks.cpp index c4f3866cad..ddce83c616 100644 --- a/indra/newview/llpanelpicks.cpp +++ b/indra/newview/llpanelpicks.cpp @@ -70,6 +70,7 @@ static const std::string CLASSIFIED_NAME("classified_name"); static LLRegisterPanelClassWrapper<LLPanelPicks> t_panel_picks("panel_picks"); + class LLPickHandler : public LLCommandHandler, public LLAvatarPropertiesObserver { @@ -83,6 +84,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnablePicks")) + { + LLNotificationsUtil::add("NoPicks", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + // handle app/classified/create urls first if (params.size() == 1 && params[0].asString() == "create") { @@ -189,6 +196,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableClassifieds")) + { + LLNotificationsUtil::add("NoClassifieds", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + // handle app/classified/create urls first if (params.size() == 1 && params[0].asString() == "create") { diff --git a/indra/newview/llpanelprofile.cpp b/indra/newview/llpanelprofile.cpp index 4f13c0c022..fd5c3362bb 100644 --- a/indra/newview/llpanelprofile.cpp +++ b/indra/newview/llpanelprofile.cpp @@ -31,16 +31,27 @@ #include "llavataractions.h" #include "llfloaterreg.h" #include "llcommandhandler.h" +#include "llnotificationsutil.h" #include "llpanelpicks.h" #include "lltabcontainer.h" #include "llviewercontrol.h" +#include "llviewernetwork.h" static const std::string PANEL_PICKS = "panel_picks"; static const std::string PANEL_PROFILE = "panel_profile"; std::string getProfileURL(const std::string& agent_name) { - std::string url = gSavedSettings.getString("WebProfileURL"); + std::string url; + + if (LLGridManager::getInstance()->isInProductionGrid()) + { + url = gSavedSettings.getString("WebProfileURL"); + } + else + { + url = gSavedSettings.getString("WebProfileNonProductionURL"); + } LLSD subs; subs["AGENT_NAME"] = agent_name; url = LLWeb::expandURLSubstitutions(url,subs); @@ -105,6 +116,12 @@ public: if (verb == "pay") { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableAvatarPay")) + { + LLNotificationsUtil::add("NoAvatarPay", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + LLAvatarActions::pay(avatar_id); return true; } diff --git a/indra/newview/llshareavatarhandler.cpp b/indra/newview/llshareavatarhandler.cpp index 34194970b8..6b4f1d3dc6 100644 --- a/indra/newview/llshareavatarhandler.cpp +++ b/indra/newview/llshareavatarhandler.cpp @@ -27,6 +27,8 @@ #include "llviewerprecompiledheaders.h" #include "llcommandhandler.h" #include "llavataractions.h" +#include "llnotificationsutil.h" +#include "llui.h" class LLShareWithAvatarHandler : public LLCommandHandler { @@ -38,6 +40,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableAvatarShare")) + { + LLNotificationsUtil::add("NoAvatarShare", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + //Make sure we have some parameters if (params.size() == 0) { diff --git a/indra/newview/llsidetray.cpp b/indra/newview/llsidetray.cpp index eb537c7d7b..8aaa7f0e13 100644 --- a/indra/newview/llsidetray.cpp +++ b/indra/newview/llsidetray.cpp @@ -629,8 +629,16 @@ LLPanel* LLSideTray::openChildPanel(LLSideTrayTab* tab, const std::string& panel std::string tab_name = tab->getName(); + bool tab_attached = isTabAttached(tab_name); + + if (tab_attached && LLUI::sSettingGroups["config"]->getBOOL("OpenSidePanelsInFloaters")) + { + tab->toggleTabDocked(); + tab_attached = false; + } + // Select tab and expand Side Tray only when a tab is attached. - if (isTabAttached(tab_name)) + if (tab_attached) { selectTabByName(tab_name); if (mCollapsed) @@ -641,14 +649,7 @@ LLPanel* LLSideTray::openChildPanel(LLSideTrayTab* tab, const std::string& panel LLFloater* floater_tab = LLFloaterReg::getInstance("side_bar_tab", tab_name); if (!floater_tab) return NULL; - // Restore the floater if it was minimized. - if (floater_tab->isMinimized()) - { - floater_tab->setMinimized(FALSE); - } - - // Send the floater to the front. - floater_tab->setFrontmost(); + floater_tab->openFloater(panel_name); } LLSideTrayPanelContainer* container = dynamic_cast<LLSideTrayPanelContainer*>(view->getParent()); @@ -979,16 +980,7 @@ void LLSideTray::reflectCollapseChange() { updateSidetrayVisibility(); - if(mCollapsed) - { - gFloaterView->setSnapOffsetRight(0); - setFocus(FALSE); - } - else - { - gFloaterView->setSnapOffsetRight(getRect().getWidth()); - setFocus(TRUE); - } + setFocus(!mCollapsed); gFloaterView->refresh(); } @@ -1161,23 +1153,43 @@ void LLSideTray::reshape(S32 width, S32 height, BOOL called_from_parent) */ LLPanel* LLSideTray::showPanel (const std::string& panel_name, const LLSD& params) { + LLPanel* new_panel = NULL; + // Look up the tab in the list of detached tabs. child_vector_const_iter_t child_it; for ( child_it = mDetachedTabs.begin(); child_it != mDetachedTabs.end(); ++child_it) { - LLPanel* panel = openChildPanel(*child_it, panel_name, params); - if (panel) return panel; - } + new_panel = openChildPanel(*child_it, panel_name, params); + if (new_panel) break; + } // Look up the tab in the list of attached tabs. for ( child_it = mTabs.begin(); child_it != mTabs.end(); ++child_it) - { - LLPanel* panel = openChildPanel(*child_it, panel_name, params); - if (panel) return panel; + { + new_panel = openChildPanel(*child_it, panel_name, params); + if (new_panel) break; + } + + return new_panel; +} + +void LLSideTray::hidePanel(const std::string& panel_name) +{ + LLPanel* panelp = getPanel(panel_name); + if (panelp) + { + if(isTabAttached(panel_name)) + { + collapseSideBar(); + } + else + { + LLFloaterReg::hideInstance("side_bar_tab", panel_name); + } } - return NULL; } + void LLSideTray::togglePanel(LLPanel* &sub_panel, const std::string& panel_name, const LLSD& params) { if(!sub_panel) @@ -1267,6 +1279,42 @@ bool LLSideTray::isPanelActive(const std::string& panel_name) return (panel->getName() == panel_name); } +void LLSideTray::setTabDocked(const std::string& tab_name, bool dock) +{ + LLSideTrayTab* tab = getTab(tab_name); + if (!tab) + { // not a docked tab, look through detached tabs + for(child_vector_iter_t tab_it = mDetachedTabs.begin(), tab_end_it = mDetachedTabs.end(); + tab_it != tab_end_it; + ++tab_it) + { + if ((*tab_it)->getName() == tab_name) + { + tab = *tab_it; + break; + } + } + + } + + if (tab) + { + bool tab_attached = isTabAttached(tab_name); + LLFloater* floater_tab = LLFloaterReg::getInstance("side_bar_tab", tab_name); + if (!floater_tab) return; + + if (dock && !tab_attached) + { + tab->dock(floater_tab); + } + else if (!dock && tab_attached) + { + tab->undock(floater_tab); + } + } +} + + void LLSideTray::updateSidetrayVisibility() { // set visibility of parent container based on collapsed state diff --git a/indra/newview/llsidetray.h b/indra/newview/llsidetray.h index 184d78845f..2516b5689f 100644 --- a/indra/newview/llsidetray.h +++ b/indra/newview/llsidetray.h @@ -97,6 +97,8 @@ public: */ LLPanel* showPanel (const std::string& panel_name, const LLSD& params = LLSD()); + void hidePanel (const std::string& panel_name); + /** * Toggling Side Tray tab which contains "sub_panel" child of "panel_name" panel. * If "sub_panel" is not visible Side Tray is opened to display it, @@ -112,6 +114,8 @@ public: LLPanel* getActivePanel (); bool isPanelActive (const std::string& panel_name); + void setTabDocked(const std::string& tab_name, bool dock); + /* * get the panel of given type T (don't show it or do anything else with it) */ @@ -215,7 +219,7 @@ private: if (LLSideTray::instanceCreated()) LLSideTray::getInstance()->setEnabled(FALSE); } - + private: LLPanel* mButtonsPanel; typedef std::map<std::string,LLButton*> button_map_t; diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index aee3e6cfe9..86087ba0a1 100755 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -1704,9 +1704,6 @@ bool idle_startup() // Set the show start location to true, now that the user has logged // on with this install. gSavedSettings.setBOOL("ShowStartLocation", TRUE); - - LLSideTray::getInstance()->showPanel("panel_home", LLSD()); - } // We're successfully logged in. diff --git a/indra/newview/lltoast.cpp b/indra/newview/lltoast.cpp index fd5582d6f7..e0b07ed408 100644 --- a/indra/newview/lltoast.cpp +++ b/indra/newview/lltoast.cpp @@ -99,7 +99,6 @@ LLToast::Params::Params() LLToast::LLToast(const LLToast::Params& p) : LLModalDialog(LLSD(), p.is_modal), - mPanel(p.panel), mToastLifetime(p.lifetime_secs), mToastFadingTime(p.fading_time_secs), mNotificationID(p.notif_id), @@ -108,6 +107,7 @@ LLToast::LLToast(const LLToast::Params& p) mCanBeStored(p.can_be_stored), mHideBtnEnabled(p.enable_hide_btn), mHideBtn(NULL), + mPanel(NULL), mNotification(p.notification), mIsHidden(false), mHideBtnPressed(false), @@ -128,9 +128,9 @@ LLToast::LLToast(const LLToast::Params& p) setBackgroundOpaque(TRUE); // *TODO: obsolete updateTransparency(); - if(mPanel) + if(p.panel()) { - insertPanel(mPanel); + insertPanel(p.panel); } if(mHideBtnEnabled) @@ -309,6 +309,7 @@ void LLToast::reshapeToPanel() void LLToast::insertPanel(LLPanel* panel) { + mPanel = panel; mWrapperPanel->addChild(panel); reshapeToPanel(); } diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index 562b9219b4..582f50ba37 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -79,8 +79,11 @@ static ECursorType cursor_from_parcel_media(U8 click_action); LLToolPie::LLToolPie() : LLTool(std::string("Pie")), - mGrabMouseButtonDown( FALSE ), - mMouseOutsideSlop( FALSE ), + mMouseButtonDown( false ), + mMouseOutsideSlop( false ), + mMouseSteerX(-1), + mMouseSteerY(-1), + mAbortClickToWalk(false), mClickAction(0), mClickActionBuyEnabled( gSavedSettings.getBOOL("ClickActionBuyEnabled") ), mClickActionPayEnabled( gSavedSettings.getBOOL("ClickActionPayEnabled") ) @@ -99,12 +102,17 @@ BOOL LLToolPie::handleAnyMouseClick(S32 x, S32 y, MASK mask, EClickType clicktyp BOOL LLToolPie::handleMouseDown(S32 x, S32 y, MASK mask) { + mMouseOutsideSlop = FALSE; + mMouseDownX = x; + mMouseDownY = y; + //left mouse down always picks transparent mPick = gViewerWindow->pickImmediate(x, y, TRUE); mPick.mKeyMask = mask; - mGrabMouseButtonDown = TRUE; + + mMouseButtonDown = true; - pickLeftMouseDownCallback(); + handleLeftClickPick(); return TRUE; } @@ -119,7 +127,7 @@ BOOL LLToolPie::handleRightMouseDown(S32 x, S32 y, MASK mask) // claim not handled so UI focus stays same - pickRightMouseDownCallback(); + handleRightClickPick(); return FALSE; } @@ -136,7 +144,7 @@ BOOL LLToolPie::handleScrollWheel(S32 x, S32 y, S32 clicks) } // True if you selected an object. -BOOL LLToolPie::pickLeftMouseDownCallback() +BOOL LLToolPie::handleLeftClickPick() { S32 x = mPick.mMousePt.mX; S32 y = mPick.mMousePt.mY; @@ -292,7 +300,12 @@ BOOL LLToolPie::pickLeftMouseDownCallback() } // put focus back "in world" - gFocusMgr.setKeyboardFocus(NULL); + if (gFocusMgr.getKeyboardFocus()) + { + // don't click to walk on attempt to give focus to world + mAbortClickToWalk = true; + gFocusMgr.setKeyboardFocus(NULL); + } BOOL touchable = (object && object->flagHandleTouch()) || (parent && parent->flagHandleTouch()); @@ -304,6 +317,7 @@ BOOL LLToolPie::pickLeftMouseDownCallback() ) { gGrabTransientTool = this; + mMouseButtonDown = false; LLToolMgr::getInstance()->getCurrentToolset()->selectTool( LLToolGrab::getInstance() ); return LLToolGrab::getInstance()->handleObjectHit( mPick ); } @@ -319,9 +333,9 @@ BOOL LLToolPie::pickLeftMouseDownCallback() if (!gSavedSettings.getBOOL("LeftClickShowMenu")) { // mouse already released - if (!mGrabMouseButtonDown) + if (!mMouseButtonDown) { - return TRUE; + return true; } while( object && object->isAttachment() && !object->flagHandleTouch()) @@ -333,9 +347,10 @@ BOOL LLToolPie::pickLeftMouseDownCallback() } object = (LLViewerObject*)object->getParent(); } - if (object && object == gAgentAvatarp) + if (object && object == gAgentAvatarp && !gSavedSettings.getBOOL("ClickToWalk")) { // we left clicked on avatar, switch to focus mode + mMouseButtonDown = false; LLToolMgr::getInstance()->setTransientTool(LLToolCamera::getInstance()); gViewerWindow->hideCursor(); LLToolCamera::getInstance()->setMouseCapture(TRUE); @@ -513,7 +528,28 @@ void LLToolPie::selectionPropertiesReceived() BOOL LLToolPie::handleHover(S32 x, S32 y, MASK mask) { + if (!mMouseOutsideSlop + && mMouseButtonDown + && gSavedSettings.getBOOL("ClickToWalk")) + { + S32 delta_x = x - mMouseDownX; + S32 delta_y = y - mMouseDownY; + S32 threshold = gSavedSettings.getS32("DragAndDropDistanceThreshold"); + if (delta_x * delta_x + delta_y * delta_y > threshold * threshold) + { + startCameraSteering(); + } + } + mHoverPick = gViewerWindow->pickImmediate(x, y, FALSE); + + if (inCameraSteerMode()) + { + steerCameraWithMouse(x, y); + gViewerWindow->setCursor(UI_CURSOR_TOOLGRAB); + return TRUE; + } + // perform a separate pick that detects transparent objects since they respond to 1-click actions LLPickInfo click_action_pick = gViewerWindow->pickImmediate(x, y, TRUE); @@ -584,39 +620,62 @@ BOOL LLToolPie::handleHover(S32 x, S32 y, MASK mask) BOOL LLToolPie::handleMouseUp(S32 x, S32 y, MASK mask) { LLViewerObject* obj = mPick.getObject(); - - handleMediaMouseUp(); - U8 click_action = final_click_action(obj); - if (click_action != CLICK_ACTION_NONE) + + // let media have first pass at click + if (handleMediaMouseUp() || LLViewerMediaFocus::getInstance()->getFocus()) + { + mAbortClickToWalk = true; + } + stopCameraSteering(); + mMouseButtonDown = false; + + if (click_action == CLICK_ACTION_NONE // not doing 1-click action + && gSavedSettings.getBOOL("ClickToWalk") // click to walk enabled + && !gAgent.getFlying() // don't auto-navigate while flying until that works + && !mAbortClickToWalk // another behavior hasn't cancelled click to walk + && !mPick.mPosGlobal.isExactlyZero() // valid coordinates for pick + && (mPick.mPickType == LLPickInfo::PICK_LAND // we clicked on land + || mPick.mObjectID.notNull())) // or on an object { - switch(click_action) + // handle special cases of steering picks + LLViewerObject* avatar_object = mPick.getObject(); + + // get pointer to avatar + while (avatar_object && !avatar_object->isAvatar()) { - // NOTE: mClickActionBuyEnabled flag enables/disables BUY action but setting cursor to default is okay - case CLICK_ACTION_BUY: - // NOTE: mClickActionPayEnabled flag enables/disables PAY action but setting cursor to default is okay - case CLICK_ACTION_PAY: - case CLICK_ACTION_OPEN: - case CLICK_ACTION_ZOOM: - case CLICK_ACTION_PLAY: - case CLICK_ACTION_OPEN_MEDIA: - // Because these actions open UI dialogs, we won't change - // the cursor again until the next hover and GL pick over - // the world. Keep the cursor an arrow, assuming that - // after the user moves off the UI, they won't be on the - // same object anymore. - gViewerWindow->setCursor(UI_CURSOR_ARROW); - // Make sure the hover-picked object is ignored. - //gToolTipView->resetLastHoverObject(); - break; - default: - break; + avatar_object = (LLViewerObject*)avatar_object->getParent(); + } + + if (avatar_object && ((LLVOAvatar*)avatar_object)->isSelf()) + { + const F64 SELF_CLICK_WALK_DISTANCE = 3.0; + // pretend we picked some point a bit in front of avatar + mPick.mPosGlobal = gAgent.getPositionGlobal() + LLVector3d(LLViewerCamera::instance().getAtAxis()) * SELF_CLICK_WALK_DISTANCE; } + gAgentCamera.setFocusOnAvatar(TRUE, TRUE); + if(mAutoPilotDestination) { mAutoPilotDestination->markDead(); } + mAutoPilotDestination = (LLHUDEffectBlob *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_BLOB, FALSE); + mAutoPilotDestination->setPositionGlobal(mPick.mPosGlobal); + mAutoPilotDestination->setPixelSize(5); + mAutoPilotDestination->setColor(LLColor4U(50, 50, 200)); + mAutoPilotDestination->setDuration(3.f); + + handle_go_to(); + mAbortClickToWalk = false; + + return TRUE; + } + gViewerWindow->setCursor(UI_CURSOR_ARROW); + if (hasMouseCapture()) + { + setMouseCapture(FALSE); } - mGrabMouseButtonDown = FALSE; LLToolMgr::getInstance()->clearTransientTool(); gAgentCamera.setLookAt(LOOKAT_TARGET_CONVERSATION, obj); // maybe look at object/person clicked on + + mAbortClickToWalk = false; return LLTool::handleMouseUp(x, y, mask); } @@ -936,7 +995,7 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l p.click_callback(boost::bind(showAvatarInspector, hover_object->getID())); p.visible_time_near(6.f); p.visible_time_far(3.f); - p.delay_time(0.35f); + p.delay_time(gSavedSettings.getF32("AvatarInspectorTooltipDelay")); p.wrap(false); LLToolTipMgr::instance().show(p); @@ -1054,7 +1113,7 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l p.click_homepage_callback(boost::bind(VisitHomePage, mHoverPick)); p.visible_time_near(6.f); p.visible_time_far(3.f); - p.delay_time(0.35f); + p.delay_time(gSavedSettings.getF32("ObjectInspectorTooltipDelay")); p.wrap(false); LLToolTipMgr::instance().show(p); @@ -1237,6 +1296,10 @@ void LLToolPie::VisitHomePage(const LLPickInfo& info) } } +void LLToolPie::handleSelect() +{ + mAbortClickToWalk = true; +} void LLToolPie::handleDeselect() { @@ -1275,10 +1338,20 @@ void LLToolPie::stopEditing() void LLToolPie::onMouseCaptureLost() { - mMouseOutsideSlop = FALSE; + stopCameraSteering(); + mMouseButtonDown = false; handleMediaMouseUp(); } +void LLToolPie::stopCameraSteering() +{ + mMouseOutsideSlop = false; +} + +bool LLToolPie::inCameraSteerMode() +{ + return mMouseButtonDown && mMouseOutsideSlop && gSavedSettings.getBOOL("ClickToWalk"); +} // true if x,y outside small box around start_x,start_y BOOL LLToolPie::outsideSlop(S32 x, S32 y, S32 start_x, S32 start_y) @@ -1444,8 +1517,6 @@ bool LLToolPie::handleMediaMouseUp() mMediaMouseCaptureID.setNull(); - setMouseCapture(FALSE); - result = true; } @@ -1508,7 +1579,7 @@ static ECursorType cursor_from_parcel_media(U8 click_action) // True if we handled the event. -BOOL LLToolPie::pickRightMouseDownCallback() +BOOL LLToolPie::handleRightClickPick() { S32 x = mPick.mMousePt.mX; S32 y = mPick.mMousePt.mY; @@ -1630,10 +1701,148 @@ BOOL LLToolPie::pickRightMouseDownCallback() void LLToolPie::showVisualContextMenuEffect() { - // VEFFECT: ShowPie - LLHUDEffectSpiral *effectp = (LLHUDEffectSpiral *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_SPHERE, TRUE); - effectp->setPositionGlobal(mPick.mPosGlobal); - effectp->setColor(LLColor4U(gAgent.getEffectColor())); - effectp->setDuration(0.25f); + // VEFFECT: ShowPie + LLHUDEffectSpiral *effectp = (LLHUDEffectSpiral *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_SPHERE, TRUE); + effectp->setPositionGlobal(mPick.mPosGlobal); + effectp->setColor(LLColor4U(gAgent.getEffectColor())); + effectp->setDuration(0.25f); +} + + +bool intersect_ray_with_sphere( const LLVector3& ray_pt, const LLVector3& ray_dir, const LLVector3& sphere_center, F32 sphere_radius, LLVector3& intersection_pt) +{ + // do ray/sphere intersection by solving quadratic equation + LLVector3 sphere_to_ray_start_vec = ray_pt - sphere_center; + F32 B = 2.f * ray_dir * sphere_to_ray_start_vec; + F32 C = sphere_to_ray_start_vec.lengthSquared() - (sphere_radius * sphere_radius); + + F32 discriminant = B*B - 4.f*C; + if (discriminant > 0.f) + { // intersection detected, now find closest one + F32 t0 = (-B - sqrtf(discriminant)) / 2.f; + if (t0 > 0.f) + { + intersection_pt = ray_pt + ray_dir * t0; + } + else + { + F32 t1 = (-B + sqrtf(discriminant)) / 2.f; + intersection_pt = ray_pt + ray_dir * t1; + } + return true; + } + + return false; +} + +void LLToolPie::startCameraSteering() +{ + mMouseOutsideSlop = true; + mAbortClickToWalk = true; + if (gAgentCamera.getFocusOnAvatar()) + { + mSteerPick = mPick; + + // handle special cases of steering picks + LLViewerObject* avatar_object = mSteerPick.getObject(); + + // get pointer to avatar + while (avatar_object && !avatar_object->isAvatar()) + { + avatar_object = (LLViewerObject*)avatar_object->getParent(); + } + + // if clicking on own avatar... + if (avatar_object && ((LLVOAvatar*)avatar_object)->isSelf()) + { + // ...project pick point a few meters in front of avatar + mSteerPick.mPosGlobal = gAgent.getPositionGlobal() + LLVector3d(LLViewerCamera::instance().getAtAxis()) * 3.0; + } + + if (!mSteerPick.isValid()) + { + mSteerPick.mPosGlobal = gAgent.getPosGlobalFromAgent( + LLViewerCamera::instance().getOrigin() + gViewerWindow->mouseDirectionGlobal(mSteerPick.mMousePt.mX, mSteerPick.mMousePt.mY) * 100.f); + } + + setMouseCapture(TRUE); + + mMouseSteerX = mMouseDownX; + mMouseSteerY = mMouseDownY; + const LLVector3 camera_to_rotation_center = gAgent.getFrameAgent().getOrigin() - LLViewerCamera::instance().getOrigin(); + const LLVector3 rotation_center_to_pick = gAgent.getPosAgentFromGlobal(mSteerPick.mPosGlobal) - gAgent.getFrameAgent().getOrigin(); + + mClockwise = camera_to_rotation_center * rotation_center_to_pick < 0.f; + if (mMouseSteerGrabPoint) { mMouseSteerGrabPoint->markDead(); } + mMouseSteerGrabPoint = (LLHUDEffectBlob *)LLHUDManager::getInstance()->createViewerEffect(LLHUDObject::LL_HUD_EFFECT_BLOB, FALSE); + mMouseSteerGrabPoint->setPositionGlobal(mSteerPick.mPosGlobal); + mMouseSteerGrabPoint->setColor(LLColor4U(50, 50, 200)); + mMouseSteerGrabPoint->setPixelSize(5); + mMouseSteerGrabPoint->setDuration(2.f); + } +} + +void LLToolPie::steerCameraWithMouse(S32 x, S32 y) +{ + const F32 MIN_ROTATION_RADIUS_FRACTION = 0.2f; + + const LLVector3 pick_pos = gAgent.getPosAgentFromGlobal(mSteerPick.mPosGlobal); + const LLVector3 rotation_center = gAgent.getFrameAgent().getOrigin(); + // FIXME: get this to work with camera tilt (i.e. sitting on a rotating object) + const LLVector3 rotation_up_axis(LLVector3::z_axis); + + LLVector3 object_rotation_center = rotation_center + parallel_component(pick_pos - rotation_center, rotation_up_axis); + F32 min_rotation_radius = MIN_ROTATION_RADIUS_FRACTION * dist_vec(rotation_center, LLViewerCamera::instance().getOrigin());; + F32 pick_distance_from_rotation_center = llclamp(dist_vec(pick_pos, object_rotation_center), min_rotation_radius, F32_MAX); + + LLVector3 mouse_ray = orthogonal_component(gViewerWindow->mouseDirectionGlobal(x, y), rotation_up_axis); + mouse_ray.normalize(); + + LLVector3 old_mouse_ray = orthogonal_component(gViewerWindow->mouseDirectionGlobal(mMouseSteerX, mMouseSteerY), rotation_up_axis); + old_mouse_ray.normalize(); + + LLVector3 camera_pos = gAgentCamera.getCameraPositionAgent(); + LLVector3 camera_to_rotation_center = object_rotation_center - camera_pos; + LLVector3 adjusted_camera_pos = camera_pos + projected_vec(camera_to_rotation_center, rotation_up_axis); + LLVector3 rotation_fwd_axis = LLViewerCamera::instance().getAtAxis() - projected_vec(LLViewerCamera::instance().getAtAxis(), rotation_up_axis); + rotation_fwd_axis.normalize(); + F32 pick_dist = dist_vec(pick_pos, adjusted_camera_pos); + + LLVector3 mouse_on_sphere; + bool mouse_hit_sphere = intersect_ray_with_sphere(adjusted_camera_pos + (mouse_ray * pick_dist * 1.1f), + -1.f * mouse_ray, + object_rotation_center, + pick_distance_from_rotation_center, + mouse_on_sphere); + + LLVector3 old_mouse_on_sphere; + intersect_ray_with_sphere(adjusted_camera_pos + (old_mouse_ray * pick_dist * 1.1f), + -1.f * old_mouse_ray, + object_rotation_center, + pick_distance_from_rotation_center, + old_mouse_on_sphere); + + if (mouse_hit_sphere) + { + // calculate rotation frame in screen space + LLVector3 screen_rotation_up_axis = orthogonal_component(rotation_up_axis, LLViewerCamera::instance().getAtAxis()); + screen_rotation_up_axis.normalize(); + + LLVector3 screen_rotation_left_axis = screen_rotation_up_axis % LLViewerCamera::instance().getAtAxis(); + + LLVector3 rotation_furthest_pt = object_rotation_center + pick_distance_from_rotation_center * rotation_fwd_axis; + F32 mouse_lateral_distance = llclamp(((mouse_on_sphere - rotation_furthest_pt) * screen_rotation_left_axis) / pick_distance_from_rotation_center, -1.f, 1.f); + F32 old_mouse_lateral_distance = llclamp(((old_mouse_on_sphere - rotation_furthest_pt) * screen_rotation_left_axis) / pick_distance_from_rotation_center, -1.f, 1.f); + + F32 yaw_angle = asinf(mouse_lateral_distance); + F32 old_yaw_angle = asinf(old_mouse_lateral_distance); + + F32 delta_angle = yaw_angle - old_yaw_angle; + if (!mClockwise) delta_angle *= -1.f; + + gAgent.yaw(delta_angle); + mMouseSteerX = x; + mMouseSteerY = y; + } } diff --git a/indra/newview/lltoolpie.h b/indra/newview/lltoolpie.h index 77200a1da4..22e77a3159 100644 --- a/indra/newview/lltoolpie.h +++ b/indra/newview/lltoolpie.h @@ -30,6 +30,7 @@ #include "lltool.h" #include "lluuid.h" #include "llviewerwindow.h" // for LLPickInfo +#include "llhudeffectblob.h" // for LLPointer<LLHudEffectBlob>, apparently class LLViewerObject; class LLObjectSelection; @@ -56,6 +57,7 @@ public: virtual void stopEditing(); virtual void onMouseCaptureLost(); + virtual void handleSelect(); virtual void handleDeselect(); virtual LLTool* getOverrideTool(MASK mask); @@ -75,8 +77,8 @@ public: private: BOOL outsideSlop (S32 x, S32 y, S32 start_x, S32 start_y); - BOOL pickLeftMouseDownCallback(); - BOOL pickRightMouseDownCallback(); + BOOL handleLeftClickPick(); + BOOL handleRightClickPick(); BOOL useClickAction (MASK mask, LLViewerObject* object,LLViewerObject* parent); void showVisualContextMenuEffect(); @@ -88,12 +90,26 @@ private: BOOL handleTooltipLand(std::string line, std::string tooltip_msg); BOOL handleTooltipObject( LLViewerObject* hover_object, std::string line, std::string tooltip_msg); + void steerCameraWithMouse(S32 x, S32 y); + void startCameraSteering(); + void stopCameraSteering(); + bool inCameraSteerMode(); + private: - BOOL mGrabMouseButtonDown; - BOOL mMouseOutsideSlop; // for this drag, has mouse moved outside slop region + bool mMouseButtonDown; + bool mMouseOutsideSlop; // for this drag, has mouse moved outside slop region + S32 mMouseDownX; + S32 mMouseDownY; + S32 mMouseSteerX; + S32 mMouseSteerY; + LLPointer<LLHUDEffectBlob> mAutoPilotDestination; + LLPointer<LLHUDEffectBlob> mMouseSteerGrabPoint; + bool mClockwise; + bool mAbortClickToWalk; LLUUID mMediaMouseCaptureID; LLPickInfo mPick; LLPickInfo mHoverPick; + LLPickInfo mSteerPick; LLPointer<LLViewerObject> mClickActionObject; U8 mClickAction; LLSafeHandle<LLObjectSelection> mLeftClickSelection; diff --git a/indra/newview/llurldispatcher.cpp b/indra/newview/llurldispatcher.cpp index bd4d3c2b78..ebbb045f0a 100644 --- a/indra/newview/llurldispatcher.cpp +++ b/indra/newview/llurldispatcher.cpp @@ -180,7 +180,7 @@ bool LLURLDispatcherImpl::dispatchRegion(const LLSLURL& slurl, bool right_mouse) LLWorldMapMessage::getInstance()->sendNamedRegionRequest(slurl.getRegion(), LLURLDispatcherImpl::regionNameCallback, slurl.getSLURLString(), - false); // don't teleport + LLUI::sSettingGroups["config"]->getBOOL("SLURLTeleportDirectly")); // don't teleport return true; } diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp index a8d5c9776c..6d3316cf6a 100644 --- a/indra/newview/llviewermedia.cpp +++ b/indra/newview/llviewermedia.cpp @@ -59,6 +59,8 @@ #include "lluuid.h" #include "llkeyboard.h" #include "llmutelist.h" +#include "llpanelprofile.h" +#include "llappviewer.h" //#include "llfirstuse.h" #include "llwindow.h" @@ -292,6 +294,43 @@ public: }; +class LLViewerMediaWebProfileResponder : public LLHTTPClient::Responder +{ +LOG_CLASS(LLViewerMediaWebProfileResponder); +public: + LLViewerMediaWebProfileResponder(std::string host) + { + mHost = host; + } + + ~LLViewerMediaWebProfileResponder() + { + } + + /* virtual */ void completedHeader(U32 status, const std::string& reason, const LLSD& content) + { + LL_WARNS("MediaAuth") << "status = " << status << ", reason = " << reason << LL_ENDL; + LL_WARNS("MediaAuth") << content << LL_ENDL; + + std::string cookie = content["set-cookie"].asString(); + + LLViewerMedia::getCookieStore()->setCookiesFromHost(cookie, mHost); + } + + void completedRaw( + U32 status, + const std::string& reason, + const LLChannelDescriptors& channels, + const LLIOPipe::buffer_ptr_t& buffer) + { + // This is just here to disable the default behavior (attempting to parse the response as llsd). + // We don't care about the content of the response, only the set-cookie header. + } + + std::string mHost; +}; + + LLPluginCookieStore *LLViewerMedia::sCookieStore = NULL; LLURL LLViewerMedia::sOpenIDURL; std::string LLViewerMedia::sOpenIDCookie; @@ -1351,6 +1390,19 @@ void LLViewerMedia::setOpenIDCookie() // *HACK: Doing this here is nasty, find a better way. LLWebSharing::instance().setOpenIDCookie(sOpenIDCookie); + + // Do a web profile get so we can store the cookie + LLSD headers = LLSD::emptyMap(); + headers["Accept"] = "*/*"; + headers["Cookie"] = sOpenIDCookie; + headers["User-Agent"] = getCurrentUserAgent(); + + std::string profile_url = getProfileURL(""); + LLURL raw_profile_url( profile_url.c_str() ); + + LLHTTPClient::get(profile_url, + new LLViewerMediaWebProfileResponder(raw_profile_url.getAuthority()), + headers); } } @@ -1833,17 +1885,12 @@ bool LLViewerMediaImpl::initializePlugin(const std::string& media_type) media_source->ignore_ssl_cert_errors(true); } - // NOTE: Removed as per STORM-927 - SSL handshake failed - setting local self-signed certs like this - // seems to screw things up big time. For now, devs will need to add these certs locally and Qt will pick them up. -// // start by assuming the default CA file will be used -// std::string ca_path = gDirUtilp->getExpandedFilename( LL_PATH_APP_SETTINGS, "lindenlab.pem" ); -// // default turned off so pick up the user specified path -// if( ! gSavedSettings.getBOOL("BrowserUseDefaultCAFile")) -// { -// ca_path = gSavedSettings.getString("BrowserCAFilePath"); -// } -// // set the path to the CA.pem file -// media_source->addCertificateFilePath( ca_path ); + // the correct way to deal with certs it to load ours from CA.pem and append them to the ones + // Qt/WebKit loads from your system location. + // Note: This needs the new CA.pem file with the Equifax Secure Certificate Authority + // cert at the bottom: (MIIDIDCCAomgAwIBAgIENd70zzANBg) + std::string ca_path = gDirUtilp->getExpandedFilename( LL_PATH_APP_SETTINGS, "CA.pem" ); + media_source->addCertificateFilePath( ca_path ); media_source->proxy_setup(gSavedSettings.getBOOL("BrowserProxyEnabled"), gSavedSettings.getString("BrowserProxyAddress"), gSavedSettings.getS32("BrowserProxyPort")); diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 89d533da28..26b6ffa19e 100755 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -842,12 +842,14 @@ class LLAdvancedCheckFeature : public view_listener_t } }; -void LLDestinationAndAvatarShow(const LLSD& value) +void toggle_destination_and_avatar_picker(const LLSD& show) { - S32 panel_idx = value.isDefined() ? value.asInteger() : -1; + S32 panel_idx = show.isDefined() ? show.asInteger() : -1; LLView* container = gViewerWindow->getRootView()->getChildView("avatar_picker_and_destination_guide_container"); LLMediaCtrl* destinations = container->findChild<LLMediaCtrl>("destination_guide_contents"); LLMediaCtrl* avatar_picker = container->findChild<LLMediaCtrl>("avatar_picker_contents"); + LLButton* avatar_btn = gViewerWindow->getRootView()->getChildView("bottom_tray")->getChild<LLButton>("avatar_btn"); + LLButton* destination_btn = gViewerWindow->getRootView()->getChildView("bottom_tray")->getChild<LLButton>("destination_btn"); switch(panel_idx) { @@ -856,17 +858,22 @@ void LLDestinationAndAvatarShow(const LLSD& value) destinations->setVisible(true); avatar_picker->setVisible(false); LLFirstUse::notUsingDestinationGuide(false); + avatar_btn->setToggleState(false); + destination_btn->setToggleState(true); break; case 1: container->setVisible(true); destinations->setVisible(false); avatar_picker->setVisible(true); - LLFirstUse::notUsingAvatarPicker(false); + avatar_btn->setToggleState(true); + destination_btn->setToggleState(false); break; default: container->setVisible(false); destinations->setVisible(false); avatar_picker->setVisible(false); + avatar_btn->setToggleState(false); + destination_btn->setToggleState(false); break; } }; @@ -5559,20 +5566,42 @@ class LLShowHelp : public view_listener_t } }; -class LLShowSidetrayPanel : public view_listener_t +class LLToggleHelp : public view_listener_t { bool handleEvent(const LLSD& userdata) { - std::string panel_name = userdata.asString(); - // Toggle the panel - if (!LLSideTray::getInstance()->isPanelActive(panel_name)) + LLFloater* help_browser = (LLFloaterReg::findInstance("help_browser")); + if (help_browser && help_browser->isInVisibleChain()) { - // LLFloaterInventory::showAgentInventory(); - LLSideTray::getInstance()->showPanel(panel_name, LLSD()); + help_browser->closeFloater(); } else { - LLSideTray::getInstance()->collapseSideBar(); + std::string help_topic = userdata.asString(); + LLViewerHelp* vhelp = LLViewerHelp::getInstance(); + vhelp->showTopic(help_topic); + } + return true; + } +}; + +class LLShowSidetrayPanel : public view_listener_t +{ + bool handleEvent(const LLSD& userdata) + { + std::string panel_name = userdata.asString(); + + LLPanel* panel = LLSideTray::getInstance()->getPanel(panel_name); + if (panel) + { + if (panel->isInVisibleChain()) + { + LLSideTray::getInstance()->hidePanel(panel_name); + } + else + { + LLSideTray::getInstance()->showPanel(panel_name); + } } return true; } @@ -5701,6 +5730,44 @@ class LLShowAgentProfile : public view_listener_t } }; +class LLToggleAgentProfile : public view_listener_t +{ + bool handleEvent(const LLSD& userdata) + { + LLUUID agent_id; + if (userdata.asString() == "agent") + { + agent_id = gAgent.getID(); + } + else if (userdata.asString() == "hit object") + { + LLViewerObject* objectp = LLSelectMgr::getInstance()->getSelection()->getPrimaryObject(); + if (objectp) + { + agent_id = objectp->getID(); + } + } + else + { + agent_id = userdata.asUUID(); + } + + LLVOAvatar* avatar = find_avatar_from_object(agent_id); + if (avatar) + { + if (!LLAvatarActions::profileVisible(avatar->getID())) + { + LLAvatarActions::showProfile(avatar->getID()); + } + else + { + LLAvatarActions::hideProfile(avatar->getID()); + } + } + return true; + } +}; + class LLLandEdit : public view_listener_t { bool handleEvent(const LLSD& userdata) @@ -8095,8 +8162,10 @@ void initialize_menus() commit.add("ReportAbuse", boost::bind(&handle_report_abuse)); commit.add("BuyCurrency", boost::bind(&handle_buy_currency)); view_listener_t::addMenu(new LLShowHelp(), "ShowHelp"); + view_listener_t::addMenu(new LLToggleHelp(), "ToggleHelp"); view_listener_t::addMenu(new LLPromptShowURL(), "PromptShowURL"); view_listener_t::addMenu(new LLShowAgentProfile(), "ShowAgentProfile"); + view_listener_t::addMenu(new LLToggleAgentProfile(), "ToggleAgentProfile"); view_listener_t::addMenu(new LLToggleControl(), "ToggleControl"); view_listener_t::addMenu(new LLCheckControl(), "CheckControl"); view_listener_t::addMenu(new LLGoToObject(), "GoToObject"); @@ -8117,5 +8186,6 @@ void initialize_menus() view_listener_t::addMenu(new LLToggleUIHints(), "ToggleUIHints"); - commit.add("DestinationAndAvatar.show", boost::bind(&LLDestinationAndAvatarShow, _2)); + commit.add("Destination.show", boost::bind(&toggle_destination_and_avatar_picker, 0)); + commit.add("Avatar.show", boost::bind(&toggle_destination_and_avatar_picker, 1)); } diff --git a/indra/newview/llviewermenu.h b/indra/newview/llviewermenu.h index 87cb4efbc4..b4e239b0cd 100644 --- a/indra/newview/llviewermenu.h +++ b/indra/newview/llviewermenu.h @@ -126,6 +126,8 @@ bool enable_pay_object(); bool enable_buy_object(); bool handle_go_to(); +void toggle_destination_and_avatar_picker(const LLSD& show); + // Export to XML or Collada void handle_export_selected( void * ); diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index d0de742283..bb7f6453bc 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1199,7 +1199,6 @@ void open_inventory_offer(const uuid_vec_t& objects, const std::string& from_nam // Highlight item const BOOL auto_open = gSavedSettings.getBOOL("ShowInInventory") && // don't open if showininventory is false - !(asset_type == LLAssetType::AT_CALLINGCARD) && // don't open if it's a calling card !from_name.empty(); // don't open if it's not from anyone. LLInventoryPanel *active_panel = LLInventoryPanel::getActiveInventoryPanel(auto_open); if(active_panel) @@ -1463,15 +1462,18 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD& // This is an offer from an agent. In this case, the back // end has already copied the items into your inventory, // so we can fetch it out of our inventory. - LLOpenAgentOffer* open_agent_offer = new LLOpenAgentOffer(mObjectID, from_string); - open_agent_offer->startFetch(); - if(catp || (itemp && itemp->isFinished())) + if (gSavedSettings.getBOOL("ShowOfferedInventory")) { - open_agent_offer->done(); - } - else - { - opener = open_agent_offer; + LLOpenAgentOffer* open_agent_offer = new LLOpenAgentOffer(mObjectID, from_string); + open_agent_offer->startFetch(); + if(catp || (itemp && itemp->isFinished())) + { + open_agent_offer->done(); + } + else + { + opener = open_agent_offer; + } } } break; @@ -1715,15 +1717,18 @@ bool LLOfferInfo::inventory_task_offer_callback(const LLSD& notification, const msg->addBinaryDataFast(_PREHASH_BinaryBucket, EMPTY_BINARY_BUCKET, EMPTY_BINARY_BUCKET_SIZE); // send the message msg->sendReliable(mHost); + + if (gSavedSettings.getBOOL("LogInventoryDecline")) { LLStringUtil::format_map_t log_message_args; log_message_args["DESC"] = mDesc; log_message_args["NAME"] = mFromName; log_message = LLTrans::getString("InvOfferDecline", log_message_args); + + LLSD args; + args["MESSAGE"] = log_message; + LLNotificationsUtil::add("SystemMessage", args); } - LLSD args; - args["MESSAGE"] = log_message; - LLNotificationsUtil::add("SystemMessage", args); if (busy && (!mFromGroup && !mFromObject)) { diff --git a/indra/newview/llviewernetwork.cpp b/indra/newview/llviewernetwork.cpp index b91e407c6d..a59afdc28a 100644 --- a/indra/newview/llviewernetwork.cpp +++ b/indra/newview/llviewernetwork.cpp @@ -31,6 +31,7 @@ #include "llviewercontrol.h" #include "llsdserialize.h" #include "llsecapi.h" +#include "lltrans.h" #include "llweb.h" @@ -504,7 +505,8 @@ void LLGridManager::setGridChoice(const std::string& grid) addGrid(grid_data); } mGrid = grid; - gSavedSettings.setString("CurrentGrid", grid); + gSavedSettings.setString("CurrentGrid", grid); + updateIsInProductionGrid(); } diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index 1d18858750..dc0ee88554 100644 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -67,6 +67,7 @@ #include "llworld.h" #include "llspatialpartition.h" #include "stringize.h" +#include "llviewercontrol.h" #ifdef LL_WINDOWS #pragma warning(disable:4355) @@ -1390,10 +1391,15 @@ void LLViewerRegion::setSeedCapability(const std::string& url) capabilityNames.append("EventQueueGet"); capabilityNames.append("ObjectMedia"); capabilityNames.append("ObjectMediaNavigate"); - capabilityNames.append("FetchLib2"); - capabilityNames.append("FetchLibDescendents2"); - capabilityNames.append("FetchInventory2"); - capabilityNames.append("FetchInventoryDescendents2"); + + if (gSavedSettings.getBOOL("UseHTTPInventory")) + { + capabilityNames.append("FetchLib2"); + capabilityNames.append("FetchLibDescendents2"); + capabilityNames.append("FetchInventory2"); + capabilityNames.append("FetchInventoryDescendents2"); + } + capabilityNames.append("GetDisplayNames"); capabilityNames.append("GetTexture"); capabilityNames.append("GetMesh"); diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index 09d25af349..221d1114a7 100644 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -854,6 +854,8 @@ void send_stats() body["DisplayNamesEnabled"] = gSavedSettings.getBOOL("UseDisplayNames"); body["DisplayNamesShowUsername"] = gSavedSettings.getBOOL("NameTagShowUsernames"); + body["MinimalSkin"] = !gSavedSettings.getString("SessionSettingsFile").empty(); + LLViewerStats::getInstance()->addToMessage(body); LLHTTPClient::post(url, body, new ViewerStatsResponder()); } diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 5d91a0045a..f1acd34e11 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -1755,6 +1755,7 @@ void LLViewerWindow::initBase() // Constrain floaters to inside the menu and status bar regions. gFloaterView = main_view->getChild<LLFloaterView>("Floater View"); + gFloaterView->setFloaterSnapView(main_view->getChild<LLView>("floater_snap_region")->getHandle()); gSnapshotFloaterView = main_view->getChild<LLSnapshotFloaterView>("Snapshot Floater View"); @@ -1916,6 +1917,7 @@ void LLViewerWindow::initWorldUI() buttons_panel_container->addChild(buttons_panel); LLView* avatar_picker_destination_guide_container = gViewerWindow->getRootView()->getChild<LLView>("avatar_picker_and_destination_guide_container"); + avatar_picker_destination_guide_container->getChild<LLButton>("close")->setCommitCallback(boost::bind(toggle_destination_and_avatar_picker, LLSD())); LLMediaCtrl* destinations = avatar_picker_destination_guide_container->findChild<LLMediaCtrl>("destination_guide_contents"); LLMediaCtrl* avatar_picker = avatar_picker_destination_guide_container->findChild<LLMediaCtrl>("avatar_picker_contents"); if (destinations) @@ -2699,10 +2701,6 @@ void LLViewerWindow::updateUI() { LLFirstUse::notUsingDestinationGuide(); } - if (gLoggedInTime.getElapsedTimeF32() > gSavedSettings.getF32("AvatarPickerHintTimeout")) - { - LLFirstUse::notUsingAvatarPicker(); - } if (gLoggedInTime.getElapsedTimeF32() > gSavedSettings.getF32("SidePanelHintTimeout")) { LLFirstUse::notUsingSidePanel(); diff --git a/indra/newview/llvoicecallhandler.cpp b/indra/newview/llvoicecallhandler.cpp index 274bd75208..2050dab689 100644 --- a/indra/newview/llvoicecallhandler.cpp +++ b/indra/newview/llvoicecallhandler.cpp @@ -27,6 +27,8 @@ #include "llviewerprecompiledheaders.h" #include "llcommandhandler.h" #include "llavataractions.h" +#include "llnotificationsutil.h" +#include "llui.h" class LLVoiceCallAvatarHandler : public LLCommandHandler { @@ -38,6 +40,12 @@ public: bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) { + if (!LLUI::sSettingGroups["config"]->getBOOL("EnableVoiceCall")) + { + LLNotificationsUtil::add("NoVoiceCall", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit")); + return true; + } + //Make sure we have some parameters if (params.size() == 0) { diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index eaa6ba231d..24486a7411 100755 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -1,9695 +1,9694 @@ -/** - * @file pipeline.cpp - * @brief Rendering pipeline. - * - * $LicenseInfo:firstyear=2005&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 "pipeline.h" - -// library includes -#include "llaudioengine.h" // For debugging. -#include "imageids.h" -#include "llerror.h" -#include "llviewercontrol.h" -#include "llfasttimer.h" -#include "llfontgl.h" -#include "llmemtype.h" -#include "llnamevalue.h" -#include "llpointer.h" -#include "llprimitive.h" -#include "llvolume.h" -#include "material_codes.h" -#include "timing.h" -#include "v3color.h" -#include "llui.h" -#include "llglheaders.h" -#include "llrender.h" -#include "llwindow.h" // swapBuffers() - -// newview includes -#include "llagent.h" -#include "llagentcamera.h" -#include "lldrawable.h" -#include "lldrawpoolalpha.h" -#include "lldrawpoolavatar.h" -#include "lldrawpoolground.h" -#include "lldrawpoolbump.h" -#include "lldrawpooltree.h" -#include "lldrawpoolwater.h" -#include "llface.h" -#include "llfeaturemanager.h" -#include "llfloatertelehub.h" -#include "llfloaterreg.h" -#include "llgldbg.h" -#include "llhudmanager.h" -#include "llhudnametag.h" -#include "llhudtext.h" -#include "lllightconstants.h" -#include "llmeshrepository.h" -#include "llresmgr.h" -#include "llselectmgr.h" -#include "llsky.h" -#include "lltracker.h" -#include "lltool.h" -#include "lltoolmgr.h" -#include "llviewercamera.h" -#include "llviewermediafocus.h" -#include "llviewertexturelist.h" -#include "llviewerobject.h" -#include "llviewerobjectlist.h" -#include "llviewerparcelmgr.h" -#include "llviewerregion.h" // for audio debugging. -#include "llviewerwindow.h" // For getSpinAxis -#include "llvoavatarself.h" -#include "llvoground.h" -#include "llvosky.h" -#include "llvotree.h" -#include "llvovolume.h" -#include "llvosurfacepatch.h" -#include "llvowater.h" -#include "llvotree.h" -#include "llvopartgroup.h" -#include "llworld.h" -#include "llcubemap.h" -#include "llviewershadermgr.h" -#include "llviewerstats.h" -#include "llviewerjoystick.h" -#include "llviewerdisplay.h" -#include "llwlparammanager.h" -#include "llwaterparammanager.h" -#include "llspatialpartition.h" -#include "llmutelist.h" -#include "lltoolpie.h" -#include "llcurl.h" - - -void check_stack_depth(S32 stack_depth) -{ - if (gDebugGL || gDebugSession) - { - GLint depth; - glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth); - if (depth != stack_depth) - { - if (gDebugSession) - { - ll_fail("GL matrix stack corrupted."); - } - else - { - llerrs << "GL matrix stack corrupted!" << llendl; - } - } - } -} - -#ifdef _DEBUG -// Debug indices is disabled for now for debug performance - djs 4/24/02 -//#define DEBUG_INDICES -#else -//#define DEBUG_INDICES -#endif - -const F32 BACKLIGHT_DAY_MAGNITUDE_AVATAR = 0.2f; -const F32 BACKLIGHT_NIGHT_MAGNITUDE_AVATAR = 0.1f; -const F32 BACKLIGHT_DAY_MAGNITUDE_OBJECT = 0.1f; -const F32 BACKLIGHT_NIGHT_MAGNITUDE_OBJECT = 0.08f; -const S32 MAX_OFFSCREEN_GEOMETRY_CHANGES_PER_FRAME = 10; -const U32 REFLECTION_MAP_RES = 128; - -// Max number of occluders to search for. JC -const S32 MAX_OCCLUDER_COUNT = 2; - -extern S32 gBoxFrame; -//extern BOOL gHideSelectedObjects; -extern BOOL gDisplaySwapBuffers; -extern BOOL gDebugGL; - -// hack counter for rendering a fixed number of frames after toggling -// fullscreen to work around DEV-5361 -static S32 sDelayedVBOEnable = 0; - -BOOL gAvatarBacklight = FALSE; - -BOOL gDebugPipeline = FALSE; -LLPipeline gPipeline; -const LLMatrix4* gGLLastMatrix = NULL; - -LLFastTimer::DeclareTimer FTM_RENDER_GEOMETRY("Geometry"); -LLFastTimer::DeclareTimer FTM_RENDER_GRASS("Grass"); -LLFastTimer::DeclareTimer FTM_RENDER_INVISIBLE("Invisible"); -LLFastTimer::DeclareTimer FTM_RENDER_OCCLUSION("Occlusion"); -LLFastTimer::DeclareTimer FTM_RENDER_SHINY("Shiny"); -LLFastTimer::DeclareTimer FTM_RENDER_SIMPLE("Simple"); -LLFastTimer::DeclareTimer FTM_RENDER_TERRAIN("Terrain"); -LLFastTimer::DeclareTimer FTM_RENDER_TREES("Trees"); -LLFastTimer::DeclareTimer FTM_RENDER_UI("UI"); -LLFastTimer::DeclareTimer FTM_RENDER_WATER("Water"); -LLFastTimer::DeclareTimer FTM_RENDER_WL_SKY("Windlight Sky"); -LLFastTimer::DeclareTimer FTM_RENDER_ALPHA("Alpha Objects"); -LLFastTimer::DeclareTimer FTM_RENDER_CHARACTERS("Avatars"); -LLFastTimer::DeclareTimer FTM_RENDER_BUMP("Bump"); -LLFastTimer::DeclareTimer FTM_RENDER_FULLBRIGHT("Fullbright"); -LLFastTimer::DeclareTimer FTM_RENDER_GLOW("Glow"); -LLFastTimer::DeclareTimer FTM_GEO_UPDATE("Geo Update"); -LLFastTimer::DeclareTimer FTM_POOLRENDER("RenderPool"); -LLFastTimer::DeclareTimer FTM_POOLS("Pools"); -LLFastTimer::DeclareTimer FTM_RENDER_BLOOM_FBO("First FBO"); -LLFastTimer::DeclareTimer FTM_STATESORT("Sort Draw State"); -LLFastTimer::DeclareTimer FTM_PIPELINE("Pipeline"); -LLFastTimer::DeclareTimer FTM_CLIENT_COPY("Client Copy"); -LLFastTimer::DeclareTimer FTM_RENDER_DEFERRED("Deferred Shading"); - - -static LLFastTimer::DeclareTimer FTM_STATESORT_DRAWABLE("Sort Drawables"); -static LLFastTimer::DeclareTimer FTM_STATESORT_POSTSORT("Post Sort"); - -//---------------------------------------- -std::string gPoolNames[] = -{ - // Correspond to LLDrawpool enum render type - "NONE", - "POOL_SIMPLE", - "POOL_GROUND", - "POOL_FULLBRIGHT", - "POOL_BUMP", - "POOL_TERRAIN," - "POOL_SKY", - "POOL_WL_SKY", - "POOL_TREE", - "POOL_GRASS", - "POOL_INVISIBLE", - "POOL_AVATAR", - "POOL_VOIDWATER", - "POOL_WATER", - "POOL_GLOW", - "POOL_ALPHA" -}; - -void drawBox(const LLVector3& c, const LLVector3& r); -void drawBoxOutline(const LLVector3& pos, const LLVector3& size); - -U32 nhpo2(U32 v) -{ - U32 r = 1; - while (r < v) { - r *= 2; - } - return r; -} - -glh::matrix4f glh_copy_matrix(GLdouble* src) -{ - glh::matrix4f ret; - for (U32 i = 0; i < 16; i++) - { - ret.m[i] = (F32) src[i]; - } - return ret; -} - -glh::matrix4f glh_get_current_modelview() -{ - return glh_copy_matrix(gGLModelView); -} - -glh::matrix4f glh_get_current_projection() -{ - return glh_copy_matrix(gGLProjection); -} - -void glh_copy_matrix(const glh::matrix4f& src, GLdouble* dst) -{ - for (U32 i = 0; i < 16; i++) - { - dst[i] = src.m[i]; - } -} - -void glh_set_current_modelview(const glh::matrix4f& mat) -{ - glh_copy_matrix(mat, gGLModelView); -} - -void glh_set_current_projection(glh::matrix4f& mat) -{ - glh_copy_matrix(mat, gGLProjection); -} - -glh::matrix4f gl_ortho(GLfloat left, GLfloat right, GLfloat bottom, GLfloat top, GLfloat znear, GLfloat zfar) -{ - glh::matrix4f ret( - 2.f/(right-left), 0.f, 0.f, -(right+left)/(right-left), - 0.f, 2.f/(top-bottom), 0.f, -(top+bottom)/(top-bottom), - 0.f, 0.f, -2.f/(zfar-znear), -(zfar+znear)/(zfar-znear), - 0.f, 0.f, 0.f, 1.f); - - return ret; -} - -void display_update_camera(); -//---------------------------------------- - -S32 LLPipeline::sCompiles = 0; - -BOOL LLPipeline::sPickAvatar = TRUE; -BOOL LLPipeline::sDynamicLOD = TRUE; -BOOL LLPipeline::sShowHUDAttachments = TRUE; -BOOL LLPipeline::sRenderPhysicalBeacons = TRUE; -BOOL LLPipeline::sRenderScriptedBeacons = FALSE; -BOOL LLPipeline::sRenderScriptedTouchBeacons = TRUE; -BOOL LLPipeline::sRenderParticleBeacons = FALSE; -BOOL LLPipeline::sRenderSoundBeacons = FALSE; -BOOL LLPipeline::sRenderBeacons = FALSE; -BOOL LLPipeline::sRenderHighlight = TRUE; -BOOL LLPipeline::sForceOldBakedUpload = FALSE; -S32 LLPipeline::sUseOcclusion = 0; -BOOL LLPipeline::sDelayVBUpdate = TRUE; -BOOL LLPipeline::sAutoMaskAlphaDeferred = TRUE; -BOOL LLPipeline::sAutoMaskAlphaNonDeferred = FALSE; -BOOL LLPipeline::sDisableShaders = FALSE; -BOOL LLPipeline::sRenderBump = TRUE; -BOOL LLPipeline::sBakeSunlight = FALSE; -BOOL LLPipeline::sNoAlpha = FALSE; -BOOL LLPipeline::sUseTriStrips = TRUE; -BOOL LLPipeline::sUseFarClip = TRUE; -BOOL LLPipeline::sShadowRender = FALSE; -BOOL LLPipeline::sWaterReflections = FALSE; -BOOL LLPipeline::sRenderGlow = FALSE; -BOOL LLPipeline::sReflectionRender = FALSE; -BOOL LLPipeline::sImpostorRender = FALSE; -BOOL LLPipeline::sUnderWaterRender = FALSE; -BOOL LLPipeline::sTextureBindTest = FALSE; -BOOL LLPipeline::sRenderFrameTest = FALSE; -BOOL LLPipeline::sRenderAttachedLights = TRUE; -BOOL LLPipeline::sRenderAttachedParticles = TRUE; -BOOL LLPipeline::sRenderDeferred = FALSE; -S32 LLPipeline::sVisibleLightCount = 0; -F32 LLPipeline::sMinRenderSize = 0.f; - - -static LLCullResult* sCull = NULL; - -static const U32 gl_cube_face[] = -{ - GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB, - GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB, - GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB, - GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB, - GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB, - GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB, -}; - -void validate_framebuffer_object(); - - -void addDeferredAttachments(LLRenderTarget& target) -{ - target.addColorAttachment(GL_RGBA); //specular - target.addColorAttachment(GL_RGBA); //normal+z -} - -LLPipeline::LLPipeline() : - mBackfaceCull(FALSE), - mBatchCount(0), - mMatrixOpCount(0), - mTextureMatrixOps(0), - mMaxBatchSize(0), - mMinBatchSize(0), - mMeanBatchSize(0), - mTrianglesDrawn(0), - mNumVisibleNodes(0), - mVerticesRelit(0), - mLightingChanges(0), - mGeometryChanges(0), - mNumVisibleFaces(0), - - mInitialized(FALSE), - mVertexShadersEnabled(FALSE), - mVertexShadersLoaded(0), - mRenderDebugFeatureMask(0), - mRenderDebugMask(0), - mOldRenderDebugMask(0), - mGroupQ1Locked(false), - mGroupQ2Locked(false), - mLastRebuildPool(NULL), - mAlphaPool(NULL), - mSkyPool(NULL), - mTerrainPool(NULL), - mWaterPool(NULL), - mGroundPool(NULL), - mSimplePool(NULL), - mFullbrightPool(NULL), - mInvisiblePool(NULL), - mGlowPool(NULL), - mBumpPool(NULL), - mWLSkyPool(NULL), - mLightMask(0), - mLightMovingMask(0), - mLightingDetail(0), - mScreenWidth(0), - mScreenHeight(0) -{ - mNoiseMap = 0; - mTrueNoiseMap = 0; - mLightFunc = 0; -} - -void LLPipeline::init() -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_INIT); - - sDynamicLOD = gSavedSettings.getBOOL("RenderDynamicLOD"); - sRenderBump = gSavedSettings.getBOOL("RenderObjectBump"); - sUseTriStrips = gSavedSettings.getBOOL("RenderUseTriStrips"); - LLVertexBuffer::sUseStreamDraw = gSavedSettings.getBOOL("RenderUseStreamVBO"); - LLVertexBuffer::sPreferStreamDraw = gSavedSettings.getBOOL("RenderPreferStreamDraw"); - sRenderAttachedLights = gSavedSettings.getBOOL("RenderAttachedLights"); - sRenderAttachedParticles = gSavedSettings.getBOOL("RenderAttachedParticles"); - - mInitialized = TRUE; - - stop_glerror(); - - //create render pass pools - getPool(LLDrawPool::POOL_ALPHA); - getPool(LLDrawPool::POOL_SIMPLE); - getPool(LLDrawPool::POOL_GRASS); - getPool(LLDrawPool::POOL_FULLBRIGHT); - getPool(LLDrawPool::POOL_INVISIBLE); - getPool(LLDrawPool::POOL_BUMP); - getPool(LLDrawPool::POOL_GLOW); - - LLViewerStats::getInstance()->mTrianglesDrawnStat.reset(); - resetFrameStats(); - - for (U32 i = 0; i < NUM_RENDER_TYPES; ++i) - { - mRenderTypeEnabled[i] = TRUE; //all rendering types start enabled - } - - mRenderDebugFeatureMask = 0xffffffff; // All debugging features on - mRenderDebugMask = 0; // All debug starts off - - // Don't turn on ground when this is set - // Mac Books with intel 950s need this - if(!gSavedSettings.getBOOL("RenderGround")) - { - toggleRenderType(RENDER_TYPE_GROUND); - } - - // make sure RenderPerformanceTest persists (hackity hack hack) - // disables non-object rendering (UI, sky, water, etc) - if (gSavedSettings.getBOOL("RenderPerformanceTest")) - { - gSavedSettings.setBOOL("RenderPerformanceTest", FALSE); - gSavedSettings.setBOOL("RenderPerformanceTest", TRUE); - } - - mOldRenderDebugMask = mRenderDebugMask; - - mBackfaceCull = TRUE; - - stop_glerror(); - - // Enable features - - LLViewerShaderMgr::instance()->setShaders(); - - stop_glerror(); - - for (U32 i = 0; i < 2; ++i) - { - mSpotLightFade[i] = 1.f; - } - - setLightingDetail(-1); -} - -LLPipeline::~LLPipeline() -{ - -} - -void LLPipeline::cleanup() -{ - assertInitialized(); - - mGroupQ1.clear() ; - mGroupQ2.clear() ; - - for(pool_set_t::iterator iter = mPools.begin(); - iter != mPools.end(); ) - { - pool_set_t::iterator curiter = iter++; - LLDrawPool* poolp = *curiter; - if (poolp->isFacePool()) - { - LLFacePool* face_pool = (LLFacePool*) poolp; - if (face_pool->mReferences.empty()) - { - mPools.erase(curiter); - removeFromQuickLookup( poolp ); - delete poolp; - } - } - else - { - mPools.erase(curiter); - removeFromQuickLookup( poolp ); - delete poolp; - } - } - - if (!mTerrainPools.empty()) - { - llwarns << "Terrain Pools not cleaned up" << llendl; - } - if (!mTreePools.empty()) - { - llwarns << "Tree Pools not cleaned up" << llendl; - } - - delete mAlphaPool; - mAlphaPool = NULL; - delete mSkyPool; - mSkyPool = NULL; - delete mTerrainPool; - mTerrainPool = NULL; - delete mWaterPool; - mWaterPool = NULL; - delete mGroundPool; - mGroundPool = NULL; - delete mSimplePool; - mSimplePool = NULL; - delete mFullbrightPool; - mFullbrightPool = NULL; - delete mInvisiblePool; - mInvisiblePool = NULL; - delete mGlowPool; - mGlowPool = NULL; - delete mBumpPool; - mBumpPool = NULL; - // don't delete wl sky pool it was handled above in the for loop - //delete mWLSkyPool; - mWLSkyPool = NULL; - - releaseGLBuffers(); - - mFaceSelectImagep = NULL; - - mMovedBridge.clear(); - - mInitialized = FALSE; -} - -//============================================================================ - -void LLPipeline::destroyGL() -{ - stop_glerror(); - unloadShaders(); - mHighlightFaces.clear(); - - resetDrawOrders(); - - resetVertexBuffers(); - - releaseGLBuffers(); - - if (LLVertexBuffer::sEnableVBOs) - { - // render 30 frames after switching to work around DEV-5361 - sDelayedVBOEnable = 30; - LLVertexBuffer::sEnableVBOs = FALSE; - } -} - -static LLFastTimer::DeclareTimer FTM_RESIZE_SCREEN_TEXTURE("Resize Screen Texture"); - -void LLPipeline::resizeScreenTexture() -{ - LLFastTimer ft(FTM_RESIZE_SCREEN_TEXTURE); - if (gPipeline.canUseVertexShaders() && assertInitialized()) - { - GLuint resX = gViewerWindow->getWorldViewWidthRaw(); - GLuint resY = gViewerWindow->getWorldViewHeightRaw(); - - allocateScreenBuffer(resX,resY); - } -} - -void LLPipeline::allocatePhysicsBuffer() -{ - GLuint resX = gViewerWindow->getWorldViewWidthRaw(); - GLuint resY = gViewerWindow->getWorldViewHeightRaw(); - - if (mPhysicsDisplay.getWidth() != resX || mPhysicsDisplay.getHeight() != resY) - { - mPhysicsDisplay.allocate(resX, resY, GL_RGBA, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - if (mSampleBuffer.getWidth() == mPhysicsDisplay.getWidth() && - mSampleBuffer.getHeight() == mPhysicsDisplay.getHeight()) - { - mPhysicsDisplay.setSampleBuffer(&mSampleBuffer); - } - } -} - -void LLPipeline::allocateScreenBuffer(U32 resX, U32 resY) -{ - // remember these dimensions - mScreenWidth = resX; - mScreenHeight = resY; - - //never use more than 4 samples for render targets - U32 samples = llmin(gSavedSettings.getU32("RenderFSAASamples"), (U32) 4); - if (gGLManager.mIsATI) - { //disable multisampling of render targets where ATI is involved - samples = 0; - } - - U32 res_mod = gSavedSettings.getU32("RenderResolutionDivisor"); - - if (res_mod > 1 && res_mod < resX && res_mod < resY) - { - resX /= res_mod; - resY /= res_mod; - } - - if (gSavedSettings.getBOOL("RenderUIBuffer")) - { - mUIScreen.allocate(resX,resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - } - - if (LLPipeline::sRenderDeferred) - { - S32 shadow_detail = gSavedSettings.getS32("RenderShadowDetail"); - BOOL ssao = gSavedSettings.getBOOL("RenderDeferredSSAO"); - bool gi = LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED); - - //allocate deferred rendering color buffers - mDeferredScreen.allocate(resX, resY, GL_RGBA, TRUE, TRUE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - mDeferredDepth.allocate(resX, resY, 0, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - addDeferredAttachments(mDeferredScreen); - - mScreen.allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - mEdgeMap.allocate(resX, resY, GL_ALPHA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - - if (shadow_detail > 0 || ssao) - { //only need mDeferredLight[0] for shadows OR ssao - mDeferredLight[0].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE); - } - else - { - mDeferredLight[0].release(); - } - - if (ssao) - { //only need mDeferredLight[1] for ssao - mDeferredLight[1].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE); - } - else - { - mDeferredLight[1].release(); - } - - if (gi) - { //only need mDeferredLight[2] and mGIMapPost for gi - mDeferredLight[2].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE); - for (U32 i = 0; i < 2; i++) - { - mGIMapPost[i].allocate(resX,resY, GL_RGB, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE); - } - } - else - { - mDeferredLight[2].release(); - - for (U32 i = 0; i < 2; i++) - { - mGIMapPost[i].release(); - } - } - - F32 scale = gSavedSettings.getF32("RenderShadowResolutionScale"); - - //HACK: make alpha masking work on ATI depth shadows (work around for ATI driver bug) - U32 shadow_fmt = gGLManager.mIsATI ? GL_ALPHA : 0; - - if (shadow_detail > 0) - { //allocate 4 sun shadow maps - for (U32 i = 0; i < 4; i++) - { - mShadow[i].allocate(U32(resX*scale),U32(resY*scale), shadow_fmt, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE); - } - } - else - { - for (U32 i = 0; i < 4; i++) - { - mShadow[i].release(); - } - } - - U32 width = nhpo2(U32(resX*scale))/2; - U32 height = width; - - if (shadow_detail > 1) - { //allocate two spot shadow maps - for (U32 i = 4; i < 6; i++) - { - mShadow[i].allocate(width, height, shadow_fmt, TRUE, FALSE); - } - } - else - { - for (U32 i = 4; i < 6; i++) - { - mShadow[i].release(); - } - } - - width = nhpo2(resX)/2; - height = nhpo2(resY)/2; - mLuminanceMap.allocate(width,height, GL_RGBA, FALSE, FALSE); - } - else - { - for (U32 i = 0; i < 3; i++) - { - mDeferredLight[i].release(); - } - for (U32 i = 0; i < 2; i++) - { - mGIMapPost[i].release(); - } - for (U32 i = 0; i < 6; i++) - { - mShadow[i].release(); - } - mScreen.release(); - mDeferredScreen.release(); //make sure to release any render targets that share a depth buffer with mDeferredScreen first - mDeferredDepth.release(); - mEdgeMap.release(); - mLuminanceMap.release(); - - mScreen.allocate(resX, resY, GL_RGBA, TRUE, TRUE, LLTexUnit::TT_RECT_TEXTURE, FALSE); - } - - if (LLRenderTarget::sUseFBO && samples > 1) - { - mSampleBuffer.allocate(resX,resY,GL_RGBA,TRUE,TRUE,LLTexUnit::TT_RECT_TEXTURE,FALSE,samples); - if (LLPipeline::sRenderDeferred) - { - addDeferredAttachments(mSampleBuffer); - mDeferredScreen.setSampleBuffer(&mSampleBuffer); - mEdgeMap.setSampleBuffer(&mSampleBuffer); - } - - mScreen.setSampleBuffer(&mSampleBuffer); - - stop_glerror(); - } - else - { - mSampleBuffer.release(); - } - - if (LLPipeline::sRenderDeferred) - { //share depth buffer between deferred targets - mDeferredScreen.shareDepthBuffer(mScreen); - for (U32 i = 0; i < 3; i++) - { //share stencil buffer with screen space lightmap to stencil out sky - if (mDeferredLight[i].getTexture(0)) - { - mDeferredScreen.shareDepthBuffer(mDeferredLight[i]); - } - } - } - - gGL.getTexUnit(0)->disable(); - - stop_glerror(); - -} - -//static -void LLPipeline::updateRenderDeferred() -{ - BOOL deferred = ((gSavedSettings.getBOOL("RenderDeferred") && - LLRenderTarget::sUseFBO && - LLFeatureManager::getInstance()->isFeatureAvailable("RenderDeferred") && - gSavedSettings.getBOOL("VertexShaderEnable") && - gSavedSettings.getBOOL("RenderAvatarVP") && - gSavedSettings.getBOOL("WindLightUseAtmosShaders")) ? TRUE : FALSE) && - !gUseWireframe; - - sRenderDeferred = deferred; - if (deferred) - { //must render glow when rendering deferred since post effect pass is needed to present any lighting at all - sRenderGlow = TRUE; - } -} - -void LLPipeline::releaseGLBuffers() -{ - assertInitialized(); - - if (mNoiseMap) - { - LLImageGL::deleteTextures(1, &mNoiseMap); - mNoiseMap = 0; - } - - if (mTrueNoiseMap) - { - LLImageGL::deleteTextures(1, &mTrueNoiseMap); - mTrueNoiseMap = 0; - } - - if (mLightFunc) - { - LLImageGL::deleteTextures(1, &mLightFunc); - mLightFunc = 0; - } - - mWaterRef.release(); - mWaterDis.release(); - mScreen.release(); - mPhysicsDisplay.release(); - mUIScreen.release(); - mSampleBuffer.release(); - mDeferredScreen.release(); - mDeferredDepth.release(); - for (U32 i = 0; i < 3; i++) - { - mDeferredLight[i].release(); - } - - mEdgeMap.release(); - mGIMap.release(); - mGIMapPost[0].release(); - mGIMapPost[1].release(); - mHighlight.release(); - mLuminanceMap.release(); - - for (U32 i = 0; i < 6; i++) - { - mShadow[i].release(); - } - - for (U32 i = 0; i < 3; i++) - { - mGlow[i].release(); - } - - gBumpImageList.destroyGL(); - LLVOAvatar::resetImpostors(); -} - -void LLPipeline::createGLBuffers() -{ - LLMemType mt_cb(LLMemType::MTYPE_PIPELINE_CREATE_BUFFERS); - assertInitialized(); - - updateRenderDeferred(); - - if (LLPipeline::sWaterReflections) - { //water reflection texture - U32 res = (U32) gSavedSettings.getS32("RenderWaterRefResolution"); - - mWaterRef.allocate(res,res,GL_RGBA,TRUE,FALSE); - mWaterDis.allocate(res,res,GL_RGBA,TRUE,FALSE); - } - - mHighlight.allocate(256,256,GL_RGBA, FALSE, FALSE); - - stop_glerror(); - - GLuint resX = gViewerWindow->getWorldViewWidthRaw(); - GLuint resY = gViewerWindow->getWorldViewHeightRaw(); - - if (LLPipeline::sRenderGlow) - { //screen space glow buffers - const U32 glow_res = llmax(1, - llmin(512, 1 << gSavedSettings.getS32("RenderGlowResolutionPow"))); - - for (U32 i = 0; i < 3; i++) - { - mGlow[i].allocate(512,glow_res,GL_RGBA,FALSE,FALSE); - } - - allocateScreenBuffer(resX,resY); - mScreenWidth = 0; - mScreenHeight = 0; - } - - if (sRenderDeferred) - { - if (!mNoiseMap) - { - const U32 noiseRes = 128; - LLVector3 noise[noiseRes*noiseRes]; - - F32 scaler = gSavedSettings.getF32("RenderDeferredNoise")/100.f; - for (U32 i = 0; i < noiseRes*noiseRes; ++i) - { - noise[i] = LLVector3(ll_frand()-0.5f, ll_frand()-0.5f, 0.f); - noise[i].normVec(); - noise[i].mV[2] = ll_frand()*scaler+1.f-scaler/2.f; - } - - 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); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - if (!mTrueNoiseMap) - { - const U32 noiseRes = 128; - F32 noise[noiseRes*noiseRes*3]; - for (U32 i = 0; i < noiseRes*noiseRes*3; i++) - { - noise[i] = ll_frand()*2.0-1.0; - } - - 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); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - if (!mLightFunc) - { - U32 lightResX = gSavedSettings.getU32("RenderSpecularResX"); - U32 lightResY = gSavedSettings.getU32("RenderSpecularResY"); - U8* lg = new U8[lightResX*lightResY]; - - for (U32 y = 0; y < lightResY; ++y) - { - for (U32 x = 0; x < lightResX; ++x) - { - //spec func - F32 sa = (F32) x/(lightResX-1); - F32 spec = (F32) y/(lightResY-1); - //lg[y*lightResX+x] = (U8) (powf(sa, 128.f*spec*spec)*255); - - //F32 sp = acosf(sa)/(1.f-spec); - - sa = powf(sa, gSavedSettings.getF32("RenderSpecularExponent")); - F32 a = acosf(sa*0.25f+0.75f); - F32 m = llmax(0.5f-spec*0.5f, 0.001f); - F32 t2 = tanf(a)/m; - t2 *= t2; - - F32 c4a = (3.f+4.f*cosf(2.f*a)+cosf(4.f*a))/8.f; - F32 bd = 1.f/(4.f*m*m*c4a)*powf(F_E, -t2); - - lg[y*lightResX+x] = (U8) (llclamp(bd, 0.f, 1.f)*255); - } - } - - LLImageGL::generateTextures(1, &mLightFunc); - gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mLightFunc); - LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_ALPHA, lightResX, lightResY, GL_ALPHA, GL_UNSIGNED_BYTE, lg); - gGL.getTexUnit(0)->setTextureAddressMode(LLTexUnit::TAM_CLAMP); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR); - - delete [] lg; - } - - if (gSavedSettings.getBOOL("RenderDeferredGI")) - { - mGIMap.allocate(512,512,GL_RGBA, TRUE, FALSE); - addDeferredAttachments(mGIMap); - } - } - - gBumpImageList.restoreGL(); -} - -void LLPipeline::restoreGL() -{ - LLMemType mt_cb(LLMemType::MTYPE_PIPELINE_RESTORE_GL); - assertInitialized(); - - if (mVertexShadersEnabled) - { - LLViewerShaderMgr::instance()->setShaders(); - } - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - part->restoreGL(); - } - } - } -} - - -BOOL LLPipeline::canUseVertexShaders() -{ - if (sDisableShaders || - !gGLManager.mHasVertexShader || - !gGLManager.mHasFragmentShader || - !LLFeatureManager::getInstance()->isFeatureAvailable("VertexShaderEnable") || - (assertInitialized() && mVertexShadersLoaded != 1) ) - { - return FALSE; - } - else - { - return TRUE; - } -} - -BOOL LLPipeline::canUseWindLightShaders() const -{ - return (!LLPipeline::sDisableShaders && - gWLSkyProgram.mProgramObject != 0 && - LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_WINDLIGHT) > 1); -} - -BOOL LLPipeline::canUseWindLightShadersOnObjects() const -{ - return (canUseWindLightShaders() - && LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_OBJECT) > 0); -} - -BOOL LLPipeline::canUseAntiAliasing() const -{ - return TRUE; -} - -void LLPipeline::unloadShaders() -{ - LLMemType mt_us(LLMemType::MTYPE_PIPELINE_UNLOAD_SHADERS); - LLViewerShaderMgr::instance()->unloadShaders(); - - mVertexShadersLoaded = 0; -} - -void LLPipeline::assertInitializedDoError() -{ - llerrs << "LLPipeline used when uninitialized." << llendl; -} - -//============================================================================ - -void LLPipeline::enableShadows(const BOOL enable_shadows) -{ - //should probably do something here to wrangle shadows.... -} - -S32 LLPipeline::getMaxLightingDetail() const -{ - /*if (mVertexShaderLevel[SHADER_OBJECT] >= LLDrawPoolSimple::SHADER_LEVEL_LOCAL_LIGHTS) - { - return 3; - } - else*/ - { - return 1; - } -} - -S32 LLPipeline::setLightingDetail(S32 level) -{ - LLMemType mt_ld(LLMemType::MTYPE_PIPELINE_LIGHTING_DETAIL); - - if (level < 0) - { - if (gSavedSettings.getBOOL("RenderLocalLights")) - { - level = 1; - } - else - { - level = 0; - } - } - level = llclamp(level, 0, getMaxLightingDetail()); - mLightingDetail = level; - - return mLightingDetail; -} - -class LLOctreeDirtyTexture : public LLOctreeTraveler<LLDrawable> -{ -public: - const std::set<LLViewerFetchedTexture*>& mTextures; - - LLOctreeDirtyTexture(const std::set<LLViewerFetchedTexture*>& textures) : mTextures(textures) { } - - virtual void visit(const LLOctreeNode<LLDrawable>* node) - { - LLSpatialGroup* group = (LLSpatialGroup*) node->getListener(0); - - if (!group->isState(LLSpatialGroup::GEOM_DIRTY) && !group->getData().empty()) - { - for (LLSpatialGroup::draw_map_t::iterator i = group->mDrawMap.begin(); i != group->mDrawMap.end(); ++i) - { - for (LLSpatialGroup::drawmap_elem_t::iterator j = i->second.begin(); j != i->second.end(); ++j) - { - LLDrawInfo* params = *j; - LLViewerFetchedTexture* tex = LLViewerTextureManager::staticCastToFetchedTexture(params->mTexture); - if (tex && mTextures.find(tex) != mTextures.end()) - { - group->setState(LLSpatialGroup::GEOM_DIRTY); - } - } - } - } - - for (LLSpatialGroup::bridge_list_t::iterator i = group->mBridgeList.begin(); i != group->mBridgeList.end(); ++i) - { - LLSpatialBridge* bridge = *i; - traverse(bridge->mOctree); - } - } -}; - -// Called when a texture changes # of channels (causes faces to move to alpha pool) -void LLPipeline::dirtyPoolObjectTextures(const std::set<LLViewerFetchedTexture*>& textures) -{ - assertInitialized(); - - // *TODO: This is inefficient and causes frame spikes; need a better way to do this - // Most of the time is spent in dirty.traverse. - - for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter) - { - LLDrawPool *poolp = *iter; - if (poolp->isFacePool()) - { - ((LLFacePool*) poolp)->dirtyTextures(textures); - } - } - - LLOctreeDirtyTexture dirty(textures); - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - dirty.traverse(part->mOctree); - } - } - } -} - -LLDrawPool *LLPipeline::findPool(const U32 type, LLViewerTexture *tex0) -{ - assertInitialized(); - - LLDrawPool *poolp = NULL; - switch( type ) - { - case LLDrawPool::POOL_SIMPLE: - poolp = mSimplePool; - break; - - case LLDrawPool::POOL_GRASS: - poolp = mGrassPool; - break; - - case LLDrawPool::POOL_FULLBRIGHT: - poolp = mFullbrightPool; - break; - - case LLDrawPool::POOL_INVISIBLE: - poolp = mInvisiblePool; - break; - - case LLDrawPool::POOL_GLOW: - poolp = mGlowPool; - break; - - case LLDrawPool::POOL_TREE: - poolp = get_if_there(mTreePools, (uintptr_t)tex0, (LLDrawPool*)0 ); - break; - - case LLDrawPool::POOL_TERRAIN: - poolp = get_if_there(mTerrainPools, (uintptr_t)tex0, (LLDrawPool*)0 ); - break; - - case LLDrawPool::POOL_BUMP: - poolp = mBumpPool; - break; - - case LLDrawPool::POOL_ALPHA: - poolp = mAlphaPool; - break; - - case LLDrawPool::POOL_AVATAR: - break; // Do nothing - - case LLDrawPool::POOL_SKY: - poolp = mSkyPool; - break; - - case LLDrawPool::POOL_WATER: - poolp = mWaterPool; - break; - - case LLDrawPool::POOL_GROUND: - poolp = mGroundPool; - break; - - case LLDrawPool::POOL_WL_SKY: - poolp = mWLSkyPool; - break; - - default: - llassert(0); - llerrs << "Invalid Pool Type in LLPipeline::findPool() type=" << type << llendl; - break; - } - - return poolp; -} - - -LLDrawPool *LLPipeline::getPool(const U32 type, LLViewerTexture *tex0) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE); - LLDrawPool *poolp = findPool(type, tex0); - if (poolp) - { - return poolp; - } - - LLDrawPool *new_poolp = LLDrawPool::createPool(type, tex0); - addPool( new_poolp ); - - return new_poolp; -} - - -// static -LLDrawPool* LLPipeline::getPoolFromTE(const LLTextureEntry* te, LLViewerTexture* imagep) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE); - U32 type = getPoolTypeFromTE(te, imagep); - return gPipeline.getPool(type, imagep); -} - -//static -U32 LLPipeline::getPoolTypeFromTE(const LLTextureEntry* te, LLViewerTexture* imagep) -{ - LLMemType mt_gpt(LLMemType::MTYPE_PIPELINE_GET_POOL_TYPE); - - if (!te || !imagep) - { - return 0; - } - - bool alpha = te->getColor().mV[3] < 0.999f; - if (imagep) - { - alpha = alpha || (imagep->getComponents() == 4 && imagep->getType() != LLViewerTexture::MEDIA_TEXTURE) || (imagep->getComponents() == 2); - } - - if (alpha) - { - return LLDrawPool::POOL_ALPHA; - } - else if ((te->getBumpmap() || te->getShiny())) - { - return LLDrawPool::POOL_BUMP; - } - else - { - return LLDrawPool::POOL_SIMPLE; - } -} - - -void LLPipeline::addPool(LLDrawPool *new_poolp) -{ - LLMemType mt_a(LLMemType::MTYPE_PIPELINE_ADD_POOL); - assertInitialized(); - mPools.insert(new_poolp); - addToQuickLookup( new_poolp ); -} - -void LLPipeline::allocDrawable(LLViewerObject *vobj) -{ - LLMemType mt_ad(LLMemType::MTYPE_PIPELINE_ALLOCATE_DRAWABLE); - LLDrawable *drawable = new LLDrawable(); - vobj->mDrawable = drawable; - - drawable->mVObjp = vobj; - - //encompass completely sheared objects by taking - //the most extreme point possible (<1,1,0.5>) - drawable->setRadius(LLVector3(1,1,0.5f).scaleVec(vobj->getScale()).length()); - if (vobj->isOrphaned()) - { - drawable->setState(LLDrawable::FORCE_INVISIBLE); - } - drawable->updateXform(TRUE); -} - - -static LLFastTimer::DeclareTimer FTM_UNLINK("Unlink"); -static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_MOVE_LIST("Movelist"); -static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_SPATIAL_PARTITION("Spatial Partition"); -static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_LIGHT_SET("Light Set"); -static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_HIGHLIGHT_SET("Highlight Set"); - -void LLPipeline::unlinkDrawable(LLDrawable *drawable) -{ - LLFastTimer t(FTM_UNLINK); - - assertInitialized(); - - LLPointer<LLDrawable> drawablep = drawable; // make sure this doesn't get deleted before we are done - - // Based on flags, remove the drawable from the queues that it's on. - if (drawablep->isState(LLDrawable::ON_MOVE_LIST)) - { - LLFastTimer t(FTM_REMOVE_FROM_MOVE_LIST); - LLDrawable::drawable_vector_t::iterator iter = std::find(mMovedList.begin(), mMovedList.end(), drawablep); - if (iter != mMovedList.end()) - { - mMovedList.erase(iter); - } - } - - if (drawablep->getSpatialGroup()) - { - LLFastTimer t(FTM_REMOVE_FROM_SPATIAL_PARTITION); - if (!drawablep->getSpatialGroup()->mSpatialPartition->remove(drawablep, drawablep->getSpatialGroup())) - { -#ifdef LL_RELEASE_FOR_DOWNLOAD - llwarns << "Couldn't remove object from spatial group!" << llendl; -#else - llerrs << "Couldn't remove object from spatial group!" << llendl; -#endif - } - } - - { - LLFastTimer t(FTM_REMOVE_FROM_LIGHT_SET); - mLights.erase(drawablep); - - for (light_set_t::iterator iter = mNearbyLights.begin(); - iter != mNearbyLights.end(); iter++) - { - if (iter->drawable == drawablep) - { - mNearbyLights.erase(iter); - break; - } - } - } - - { - LLFastTimer t(FTM_REMOVE_FROM_HIGHLIGHT_SET); - HighlightItem item(drawablep); - mHighlightSet.erase(item); - - if (mHighlightObject == drawablep) - { - mHighlightObject = NULL; - } - } - - for (U32 i = 0; i < 2; ++i) - { - if (mShadowSpotLight[i] == drawablep) - { - mShadowSpotLight[i] = NULL; - } - - if (mTargetShadowSpotLight[i] == drawablep) - { - mTargetShadowSpotLight[i] = NULL; - } - } - - -} - -U32 LLPipeline::addObject(LLViewerObject *vobj) -{ - LLMemType mt_ao(LLMemType::MTYPE_PIPELINE_ADD_OBJECT); - if (gNoRender) - { - return 0; - } - - if (gSavedSettings.getBOOL("RenderDelayCreation")) - { - mCreateQ.push_back(vobj); - } - else - { - createObject(vobj); - } - - return 1; -} - -void LLPipeline::createObjects(F32 max_dtime) -{ - LLFastTimer ftm(FTM_GEO_UPDATE); - LLMemType mt(LLMemType::MTYPE_PIPELINE_CREATE_OBJECTS); - - LLTimer update_timer; - - while (!mCreateQ.empty() && update_timer.getElapsedTimeF32() < max_dtime) - { - LLViewerObject* vobj = mCreateQ.front(); - if (!vobj->isDead()) - { - createObject(vobj); - } - mCreateQ.pop_front(); - } - - //for (LLViewerObject::vobj_list_t::iterator iter = mCreateQ.begin(); iter != mCreateQ.end(); ++iter) - //{ - // createObject(*iter); - //} - - //mCreateQ.clear(); -} - -void LLPipeline::createObject(LLViewerObject* vobj) -{ - LLDrawable* drawablep = vobj->mDrawable; - - if (!drawablep) - { - drawablep = vobj->createDrawable(this); - } - else - { - llerrs << "Redundant drawable creation!" << llendl; - } - - llassert(drawablep); - - if (vobj->getParent()) - { - vobj->setDrawableParent(((LLViewerObject*)vobj->getParent())->mDrawable); // LLPipeline::addObject 1 - } - else - { - vobj->setDrawableParent(NULL); // LLPipeline::addObject 2 - } - - markRebuild(drawablep, LLDrawable::REBUILD_ALL, TRUE); - - if (drawablep->getVOVolume() && gSavedSettings.getBOOL("RenderAnimateRes")) - { - // fun animated res - drawablep->updateXform(TRUE); - drawablep->clearState(LLDrawable::MOVE_UNDAMPED); - drawablep->setScale(LLVector3(0,0,0)); - drawablep->makeActive(); - } -} - - -void LLPipeline::resetFrameStats() -{ - assertInitialized(); - - LLViewerStats::getInstance()->mTrianglesDrawnStat.addValue(mTrianglesDrawn/1000.f); - - if (mBatchCount > 0) - { - mMeanBatchSize = gPipeline.mTrianglesDrawn/gPipeline.mBatchCount; - } - mTrianglesDrawn = 0; - sCompiles = 0; - mVerticesRelit = 0; - mLightingChanges = 0; - mGeometryChanges = 0; - mNumVisibleFaces = 0; - - if (mOldRenderDebugMask != mRenderDebugMask) - { - gObjectList.clearDebugText(); - mOldRenderDebugMask = mRenderDebugMask; - } - -} - -//external functions for asynchronous updating -void LLPipeline::updateMoveDampedAsync(LLDrawable* drawablep) -{ - if (gSavedSettings.getBOOL("FreezeTime")) - { - return; - } - if (!drawablep) - { - llerrs << "updateMove called with NULL drawablep" << llendl; - return; - } - if (drawablep->isState(LLDrawable::EARLY_MOVE)) - { - return; - } - - assertInitialized(); - - // update drawable now - drawablep->clearState(LLDrawable::MOVE_UNDAMPED); // force to DAMPED - drawablep->updateMove(); // returns done - drawablep->setState(LLDrawable::EARLY_MOVE); // flag says we already did an undamped move this frame - // Put on move list so that EARLY_MOVE gets cleared - if (!drawablep->isState(LLDrawable::ON_MOVE_LIST)) - { - mMovedList.push_back(drawablep); - drawablep->setState(LLDrawable::ON_MOVE_LIST); - } -} - -void LLPipeline::updateMoveNormalAsync(LLDrawable* drawablep) -{ - if (gSavedSettings.getBOOL("FreezeTime")) - { - return; - } - if (!drawablep) - { - llerrs << "updateMove called with NULL drawablep" << llendl; - return; - } - if (drawablep->isState(LLDrawable::EARLY_MOVE)) - { - return; - } - - assertInitialized(); - - // update drawable now - drawablep->setState(LLDrawable::MOVE_UNDAMPED); // force to UNDAMPED - drawablep->updateMove(); - drawablep->setState(LLDrawable::EARLY_MOVE); // flag says we already did an undamped move this frame - // Put on move list so that EARLY_MOVE gets cleared - if (!drawablep->isState(LLDrawable::ON_MOVE_LIST)) - { - mMovedList.push_back(drawablep); - drawablep->setState(LLDrawable::ON_MOVE_LIST); - } -} - -void LLPipeline::updateMovedList(LLDrawable::drawable_vector_t& moved_list) -{ - for (LLDrawable::drawable_vector_t::iterator iter = moved_list.begin(); - iter != moved_list.end(); ) - { - LLDrawable::drawable_vector_t::iterator curiter = iter++; - LLDrawable *drawablep = *curiter; - BOOL done = TRUE; - if (!drawablep->isDead() && (!drawablep->isState(LLDrawable::EARLY_MOVE))) - { - done = drawablep->updateMove(); - } - drawablep->clearState(LLDrawable::EARLY_MOVE | LLDrawable::MOVE_UNDAMPED); - if (done) - { - drawablep->clearState(LLDrawable::ON_MOVE_LIST); - iter = moved_list.erase(curiter); - } - } -} - -static LLFastTimer::DeclareTimer FTM_OCTREE_BALANCE("Balance Octree"); -static LLFastTimer::DeclareTimer FTM_UPDATE_MOVE("Update Move"); - -void LLPipeline::updateMove() -{ - LLFastTimer t(FTM_UPDATE_MOVE); - LLMemType mt_um(LLMemType::MTYPE_PIPELINE_UPDATE_MOVE); - - if (gSavedSettings.getBOOL("FreezeTime")) - { - return; - } - - assertInitialized(); - - { - static LLFastTimer::DeclareTimer ftm("Retexture"); - LLFastTimer t(ftm); - - for (LLDrawable::drawable_set_t::iterator iter = mRetexturedList.begin(); - iter != mRetexturedList.end(); ++iter) - { - LLDrawable* drawablep = *iter; - if (drawablep && !drawablep->isDead()) - { - drawablep->updateTexture(); - } - } - mRetexturedList.clear(); - } - - { - static LLFastTimer::DeclareTimer ftm("Moved List"); - LLFastTimer t(ftm); - updateMovedList(mMovedList); - } - - //balance octrees - { - LLFastTimer ot(FTM_OCTREE_BALANCE); - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - part->mOctree->balance(); - } - } - } - } -} - -///////////////////////////////////////////////////////////////////////////// -// Culling and occlusion testing -///////////////////////////////////////////////////////////////////////////// - -//static -F32 LLPipeline::calcPixelArea(LLVector3 center, LLVector3 size, LLCamera &camera) -{ - LLVector3 lookAt = center - camera.getOrigin(); - F32 dist = lookAt.length(); - - //ramp down distance for nearby objects - //shrink dist by dist/16. - if (dist < 16.f) - { - dist /= 16.f; - dist *= dist; - dist *= 16.f; - } - - //get area of circle around node - F32 app_angle = atanf(size.length()/dist); - F32 radius = app_angle*LLDrawable::sCurPixelAngle; - return radius*radius * F_PI; -} - -//static -F32 LLPipeline::calcPixelArea(const LLVector4a& center, const LLVector4a& size, LLCamera &camera) -{ - LLVector4a origin; - origin.load3(camera.getOrigin().mV); - - LLVector4a lookAt; - lookAt.setSub(center, origin); - F32 dist = lookAt.getLength3().getF32(); - - //ramp down distance for nearby objects - //shrink dist by dist/16. - if (dist < 16.f) - { - dist /= 16.f; - dist *= dist; - dist *= 16.f; - } - - //get area of circle around node - F32 app_angle = atanf(size.getLength3().getF32()/dist); - F32 radius = app_angle*LLDrawable::sCurPixelAngle; - return radius*radius * F_PI; -} - -void LLPipeline::grabReferences(LLCullResult& result) -{ - sCull = &result; -} - -void LLPipeline::clearReferences() -{ - sCull = NULL; -} - -void check_references(LLSpatialGroup* group, LLDrawable* drawable) -{ - for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i) - { - if (drawable == *i) - { - llerrs << "LLDrawable deleted while actively reference by LLPipeline." << llendl; - } - } -} - -void check_references(LLDrawable* drawable, LLFace* face) -{ - for (S32 i = 0; i < drawable->getNumFaces(); ++i) - { - if (drawable->getFace(i) == face) - { - llerrs << "LLFace deleted while actively referenced by LLPipeline." << llendl; - } - } -} - -void check_references(LLSpatialGroup* group, LLFace* face) -{ - for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i) - { - LLDrawable* drawable = *i; - check_references(drawable, face); - } -} - -void LLPipeline::checkReferences(LLFace* face) -{ -#if 0 - if (sCull) - { - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, face); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, face); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, face); - } - - for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList(); iter != sCull->endVisibleList(); ++iter) - { - LLDrawable* drawable = *iter; - check_references(drawable, face); - } - } -#endif -} - -void LLPipeline::checkReferences(LLDrawable* drawable) -{ -#if 0 - if (sCull) - { - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, drawable); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, drawable); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, drawable); - } - - for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList(); iter != sCull->endVisibleList(); ++iter) - { - if (drawable == *iter) - { - llerrs << "LLDrawable deleted while actively referenced by LLPipeline." << llendl; - } - } - } -#endif -} - -void check_references(LLSpatialGroup* group, LLDrawInfo* draw_info) -{ - for (LLSpatialGroup::draw_map_t::iterator i = group->mDrawMap.begin(); i != group->mDrawMap.end(); ++i) - { - LLSpatialGroup::drawmap_elem_t& draw_vec = i->second; - for (LLSpatialGroup::drawmap_elem_t::iterator j = draw_vec.begin(); j != draw_vec.end(); ++j) - { - LLDrawInfo* params = *j; - if (params == draw_info) - { - llerrs << "LLDrawInfo deleted while actively referenced by LLPipeline." << llendl; - } - } - } -} - - -void LLPipeline::checkReferences(LLDrawInfo* draw_info) -{ -#if 0 - if (sCull) - { - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, draw_info); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, draw_info); - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - check_references(group, draw_info); - } - } -#endif -} - -void LLPipeline::checkReferences(LLSpatialGroup* group) -{ -#if 0 - if (sCull) - { - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - if (group == *iter) - { - llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl; - } - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter) - { - if (group == *iter) - { - llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl; - } - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter) - { - if (group == *iter) - { - llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl; - } - } - } -#endif -} - - -BOOL LLPipeline::visibleObjectsInFrustum(LLCamera& camera) -{ - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - if (hasRenderType(part->mDrawableType)) - { - if (part->visibleObjectsInFrustum(camera)) - { - return TRUE; - } - } - } - } - } - - return FALSE; -} - -BOOL LLPipeline::getVisibleExtents(LLCamera& camera, LLVector3& min, LLVector3& max) -{ - const F32 X = 65536.f; - - min = LLVector3(X,X,X); - max = LLVector3(-X,-X,-X); - - U32 saved_camera_id = LLViewerCamera::sCurCameraID; - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WORLD; - - BOOL res = TRUE; - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - if (hasRenderType(part->mDrawableType)) - { - if (!part->getVisibleExtents(camera, min, max)) - { - res = FALSE; - } - } - } - } - } - - LLViewerCamera::sCurCameraID = saved_camera_id; - - return res; -} - -static LLFastTimer::DeclareTimer FTM_CULL("Object Culling"); - -void LLPipeline::updateCull(LLCamera& camera, LLCullResult& result, S32 water_clip) -{ - LLFastTimer t(FTM_CULL); - LLMemType mt_uc(LLMemType::MTYPE_PIPELINE_UPDATE_CULL); - - grabReferences(result); - - sCull->clear(); - - BOOL to_texture = LLPipeline::sUseOcclusion > 1 && - !hasRenderType(LLPipeline::RENDER_TYPE_HUD) && - LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD && - gPipeline.canUseVertexShaders() && - sRenderGlow; - - if (to_texture) - { - mScreen.bindTarget(); - } - - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadMatrixd(gGLLastProjection); - glMatrixMode(GL_MODELVIEW); - glPushMatrix(); - gGLLastMatrix = NULL; - glLoadMatrixd(gGLLastModelView); - - - LLVertexBuffer::unbind(); - LLGLDisable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - if (sUseOcclusion > 1) - { - gGL.setColorMask(false, false); - } - - LLGLDepthTest depth(GL_TRUE, GL_FALSE); - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - if (water_clip != 0) - { - LLPlane plane(LLVector3(0,0, (F32) -water_clip), (F32) water_clip*region->getWaterHeight()); - camera.setUserClipPlane(plane); - } - else - { - camera.disableUserClipPlane(); - } - - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - if (hasRenderType(part->mDrawableType)) - { - part->cull(camera); - } - } - } - } - - camera.disableUserClipPlane(); - - if (hasRenderType(LLPipeline::RENDER_TYPE_SKY) && - gSky.mVOSkyp.notNull() && - gSky.mVOSkyp->mDrawable.notNull()) - { - gSky.mVOSkyp->mDrawable->setVisible(camera); - sCull->pushDrawable(gSky.mVOSkyp->mDrawable); - gSky.updateCull(); - stop_glerror(); - } - - if (hasRenderType(LLPipeline::RENDER_TYPE_GROUND) && - !gPipeline.canUseWindLightShaders() && - gSky.mVOGroundp.notNull() && - gSky.mVOGroundp->mDrawable.notNull() && - !LLPipeline::sWaterReflections) - { - gSky.mVOGroundp->mDrawable->setVisible(camera); - sCull->pushDrawable(gSky.mVOGroundp->mDrawable); - } - - - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - - if (sUseOcclusion > 1) - { - gGL.setColorMask(true, false); - } - - if (to_texture) - { - mScreen.flush(); - } -} - -void LLPipeline::markNotCulled(LLSpatialGroup* group, LLCamera& camera) -{ - if (group->getData().empty()) - { - return; - } - - group->setVisible(); - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD) - { - group->updateDistance(camera); - } - - const F32 MINIMUM_PIXEL_AREA = 16.f; - - if (group->mPixelArea < MINIMUM_PIXEL_AREA) - { - return; - } - - if (sMinRenderSize > 0.f && - llmax(llmax(group->mBounds[1][0], group->mBounds[1][1]), group->mBounds[1][2]) < sMinRenderSize) - { - return; - } - - assertInitialized(); - - if (!group->mSpatialPartition->mRenderByGroup) - { //render by drawable - sCull->pushDrawableGroup(group); - } - else - { //render by group - sCull->pushVisibleGroup(group); - } - - mNumVisibleNodes++; -} - -void LLPipeline::markOccluder(LLSpatialGroup* group) -{ - if (sUseOcclusion > 1 && group && !group->isOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION)) - { - LLSpatialGroup* parent = group->getParent(); - - if (!parent || !parent->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { //only mark top most occluders as active occlusion - sCull->pushOcclusionGroup(group); - group->setOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION); - - if (parent && - !parent->isOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION) && - parent->getElementCount() == 0 && - parent->needsUpdate()) - { - sCull->pushOcclusionGroup(group); - parent->setOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION); - } - } - } -} - -void LLPipeline::doOcclusion(LLCamera& camera) -{ - if (LLPipeline::sUseOcclusion > 1 && sCull->hasOcclusionGroups()) - { - LLVertexBuffer::unbind(); - - if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_OCCLUSION)) - { - gGL.setColorMask(true, false, false, false); - } - else - { - gGL.setColorMask(false, false); - } - LLGLDisable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - LLGLDepthTest depth(GL_TRUE, GL_FALSE); - - LLGLDisable cull(GL_CULL_FACE); - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginOcclusionGroups(); iter != sCull->endOcclusionGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - group->doOcclusion(&camera); - group->clearOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION); - } - - gGL.setColorMask(true, false); - } -} - -BOOL LLPipeline::updateDrawableGeom(LLDrawable* drawablep, BOOL priority) -{ - BOOL update_complete = drawablep->updateGeometry(priority); - if (update_complete && assertInitialized()) - { - drawablep->setState(LLDrawable::BUILT); - mGeometryChanges++; - } - return update_complete; -} - -void LLPipeline::updateGL() -{ - while (!LLGLUpdate::sGLQ.empty()) - { - LLGLUpdate* glu = LLGLUpdate::sGLQ.front(); - glu->updateGL(); - glu->mInQ = FALSE; - LLGLUpdate::sGLQ.pop_front(); - } -} - -void LLPipeline::rebuildPriorityGroups() -{ - LLTimer update_timer; - LLMemType mt(LLMemType::MTYPE_PIPELINE); - - assertInitialized(); - - gMeshRepo.notifyLoadedMeshes(); - - mGroupQ1Locked = true; - // Iterate through all drawables on the priority build queue, - for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ1.begin(); - iter != mGroupQ1.end(); ++iter) - { - LLSpatialGroup* group = *iter; - group->rebuildGeom(); - group->clearState(LLSpatialGroup::IN_BUILD_Q1); - } - - mGroupQ1.clear(); - mGroupQ1Locked = false; - -} - -void LLPipeline::rebuildGroups() -{ - if (mGroupQ2.empty()) - { - return; - } - - mGroupQ2Locked = true; - // Iterate through some drawables on the non-priority build queue - S32 size = (S32) mGroupQ2.size(); - S32 min_count = llclamp((S32) ((F32) (size * size)/4096*0.25f), 1, size); - - S32 count = 0; - - std::sort(mGroupQ2.begin(), mGroupQ2.end(), LLSpatialGroup::CompareUpdateUrgency()); - - LLSpatialGroup::sg_vector_t::iterator iter; - LLSpatialGroup::sg_vector_t::iterator last_iter = mGroupQ2.begin(); - - for (iter = mGroupQ2.begin(); - iter != mGroupQ2.end() && count <= min_count; ++iter) - { - LLSpatialGroup* group = *iter; - last_iter = iter; - - if (!group->isDead()) - { - group->rebuildGeom(); - - if (group->mSpatialPartition->mRenderByGroup) - { - count++; - } - } - - group->clearState(LLSpatialGroup::IN_BUILD_Q2); - } - - mGroupQ2.erase(mGroupQ2.begin(), ++last_iter); - - mGroupQ2Locked = false; - - updateMovedList(mMovedBridge); -} - -void LLPipeline::updateGeom(F32 max_dtime) -{ - LLTimer update_timer; - LLMemType mt(LLMemType::MTYPE_PIPELINE_UPDATE_GEOM); - LLPointer<LLDrawable> drawablep; - - LLFastTimer t(FTM_GEO_UPDATE); - - assertInitialized(); - - if (sDelayedVBOEnable > 0) - { - if (--sDelayedVBOEnable <= 0) - { - resetVertexBuffers(); - LLVertexBuffer::sEnableVBOs = TRUE; - } - } - - // notify various object types to reset internal cost metrics, etc. - // for now, only LLVOVolume does this to throttle LOD changes - LLVOVolume::preUpdateGeom(); - - // Iterate through all drawables on the priority build queue, - for (LLDrawable::drawable_list_t::iterator iter = mBuildQ1.begin(); - iter != mBuildQ1.end();) - { - LLDrawable::drawable_list_t::iterator curiter = iter++; - LLDrawable* drawablep = *curiter; - if (drawablep && !drawablep->isDead()) - { - if (drawablep->isState(LLDrawable::IN_REBUILD_Q2)) - { - drawablep->clearState(LLDrawable::IN_REBUILD_Q2); - LLDrawable::drawable_list_t::iterator find = std::find(mBuildQ2.begin(), mBuildQ2.end(), drawablep); - if (find != mBuildQ2.end()) - { - mBuildQ2.erase(find); - } - } - - if (updateDrawableGeom(drawablep, TRUE)) - { - drawablep->clearState(LLDrawable::IN_REBUILD_Q1); - mBuildQ1.erase(curiter); - } - } - else - { - mBuildQ1.erase(curiter); - } - } - - // Iterate through some drawables on the non-priority build queue - S32 min_count = 16; - S32 size = (S32) mBuildQ2.size(); - if (size > 1024) - { - min_count = llclamp((S32) (size * (F32) size/4096), 16, size); - } - - S32 count = 0; - - max_dtime = llmax(update_timer.getElapsedTimeF32()+0.001f, max_dtime); - LLSpatialGroup* last_group = NULL; - LLSpatialBridge* last_bridge = NULL; - - for (LLDrawable::drawable_list_t::iterator iter = mBuildQ2.begin(); - iter != mBuildQ2.end(); ) - { - LLDrawable::drawable_list_t::iterator curiter = iter++; - LLDrawable* drawablep = *curiter; - - LLSpatialBridge* bridge = drawablep->isRoot() ? drawablep->getSpatialBridge() : - drawablep->getParent()->getSpatialBridge(); - - if (drawablep->getSpatialGroup() != last_group && - (!last_bridge || bridge != last_bridge) && - (update_timer.getElapsedTimeF32() >= max_dtime) && count > min_count) - { - break; - } - - //make sure updates don't stop in the middle of a spatial group - //to avoid thrashing (objects are enqueued by group) - last_group = drawablep->getSpatialGroup(); - last_bridge = bridge; - - BOOL update_complete = TRUE; - if (!drawablep->isDead()) - { - update_complete = updateDrawableGeom(drawablep, FALSE); - count++; - } - if (update_complete) - { - drawablep->clearState(LLDrawable::IN_REBUILD_Q2); - mBuildQ2.erase(curiter); - } - } - - updateMovedList(mMovedBridge); -} - -void LLPipeline::markVisible(LLDrawable *drawablep, LLCamera& camera) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_VISIBLE); - - if(drawablep && !drawablep->isDead()) - { - if (drawablep->isSpatialBridge()) - { - const LLDrawable* root = ((LLSpatialBridge*) drawablep)->mDrawable; - llassert(root); // trying to catch a bad assumption - if (root && // // this test may not be needed, see above - root->getVObj()->isAttachment()) - { - LLDrawable* rootparent = root->getParent(); - if (rootparent) // this IS sometimes NULL - { - LLViewerObject *vobj = rootparent->getVObj(); - llassert(vobj); // trying to catch a bad assumption - if (vobj) // this test may not be needed, see above - { - const LLVOAvatar* av = vobj->asAvatar(); - if (av && av->isImpostor()) - { - return; - } - } - } - } - sCull->pushBridge((LLSpatialBridge*) drawablep); - } - else - { - sCull->pushDrawable(drawablep); - } - - drawablep->setVisible(camera); - } -} - -void LLPipeline::markMoved(LLDrawable *drawablep, BOOL damped_motion) -{ - LLMemType mt_mm(LLMemType::MTYPE_PIPELINE_MARK_MOVED); - - if (!drawablep) - { - //llerrs << "Sending null drawable to moved list!" << llendl; - return; - } - - if (drawablep->isDead()) - { - llwarns << "Marking NULL or dead drawable moved!" << llendl; - return; - } - - if (drawablep->getParent()) - { - //ensure that parent drawables are moved first - markMoved(drawablep->getParent(), damped_motion); - } - - assertInitialized(); - - if (!drawablep->isState(LLDrawable::ON_MOVE_LIST)) - { - if (drawablep->isSpatialBridge()) - { - mMovedBridge.push_back(drawablep); - } - else - { - mMovedList.push_back(drawablep); - } - drawablep->setState(LLDrawable::ON_MOVE_LIST); - } - if (damped_motion == FALSE) - { - drawablep->setState(LLDrawable::MOVE_UNDAMPED); // UNDAMPED trumps DAMPED - } - else if (drawablep->isState(LLDrawable::MOVE_UNDAMPED)) - { - drawablep->clearState(LLDrawable::MOVE_UNDAMPED); - } -} - -void LLPipeline::markShift(LLDrawable *drawablep) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_SHIFT); - - if (!drawablep || drawablep->isDead()) - { - return; - } - - assertInitialized(); - - if (!drawablep->isState(LLDrawable::ON_SHIFT_LIST)) - { - drawablep->getVObj()->setChanged(LLXform::SHIFTED | LLXform::SILHOUETTE); - if (drawablep->getParent()) - { - markShift(drawablep->getParent()); - } - mShiftList.push_back(drawablep); - drawablep->setState(LLDrawable::ON_SHIFT_LIST); - } -} - -void LLPipeline::shiftObjects(const LLVector3 &offset) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_SHIFT_OBJECTS); - - assertInitialized(); - - glClear(GL_DEPTH_BUFFER_BIT); - gDepthDirty = TRUE; - - LLVector4a offseta; - offseta.load3(offset.mV); - - for (LLDrawable::drawable_vector_t::iterator iter = mShiftList.begin(); - iter != mShiftList.end(); iter++) - { - LLDrawable *drawablep = *iter; - if (drawablep->isDead()) - { - continue; - } - drawablep->shiftPos(offseta); - drawablep->clearState(LLDrawable::ON_SHIFT_LIST); - } - mShiftList.resize(0); - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - part->shift(offseta); - } - } - } - - LLHUDText::shiftAll(offset); - LLHUDNameTag::shiftAll(offset); - display_update_camera(); -} - -void LLPipeline::markTextured(LLDrawable *drawablep) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_TEXTURED); - - if (drawablep && !drawablep->isDead() && assertInitialized()) - { - mRetexturedList.insert(drawablep); - } -} - -void LLPipeline::markGLRebuild(LLGLUpdate* glu) -{ - if (glu && !glu->mInQ) - { - LLGLUpdate::sGLQ.push_back(glu); - glu->mInQ = TRUE; - } -} - -void LLPipeline::markRebuild(LLSpatialGroup* group, BOOL priority) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE); - - if (group && !group->isDead() && group->mSpatialPartition) - { - if (group->mSpatialPartition->mPartitionType == LLViewerRegion::PARTITION_HUD) - { - priority = TRUE; - } - - if (priority) - { - if (!group->isState(LLSpatialGroup::IN_BUILD_Q1)) - { - llassert_always(!mGroupQ1Locked); - - mGroupQ1.push_back(group); - group->setState(LLSpatialGroup::IN_BUILD_Q1); - - if (group->isState(LLSpatialGroup::IN_BUILD_Q2)) - { - LLSpatialGroup::sg_vector_t::iterator iter = std::find(mGroupQ2.begin(), mGroupQ2.end(), group); - if (iter != mGroupQ2.end()) - { - mGroupQ2.erase(iter); - } - group->clearState(LLSpatialGroup::IN_BUILD_Q2); - } - } - } - else if (!group->isState(LLSpatialGroup::IN_BUILD_Q2 | LLSpatialGroup::IN_BUILD_Q1)) - { - llassert_always(!mGroupQ2Locked); - mGroupQ2.push_back(group); - group->setState(LLSpatialGroup::IN_BUILD_Q2); - - } - } -} - -void LLPipeline::markRebuild(LLDrawable *drawablep, LLDrawable::EDrawableFlags flag, BOOL priority) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_REBUILD); - - if (drawablep && !drawablep->isDead() && assertInitialized()) - { - if (!drawablep->isState(LLDrawable::BUILT)) - { - priority = TRUE; - } - if (priority) - { - if (!drawablep->isState(LLDrawable::IN_REBUILD_Q1)) - { - mBuildQ1.push_back(drawablep); - drawablep->setState(LLDrawable::IN_REBUILD_Q1); // mark drawable as being in priority queue - } - } - else if (!drawablep->isState(LLDrawable::IN_REBUILD_Q2)) - { - mBuildQ2.push_back(drawablep); - drawablep->setState(LLDrawable::IN_REBUILD_Q2); // need flag here because it is just a list - } - if (flag & (LLDrawable::REBUILD_VOLUME | LLDrawable::REBUILD_POSITION)) - { - drawablep->getVObj()->setChanged(LLXform::SILHOUETTE); - } - drawablep->setState(flag); - } -} - -static LLFastTimer::DeclareTimer FTM_RESET_DRAWORDER("Reset Draw Order"); - -void LLPipeline::stateSort(LLCamera& camera, LLCullResult &result) -{ - if (hasAnyRenderType(LLPipeline::RENDER_TYPE_AVATAR, - LLPipeline::RENDER_TYPE_GROUND, - LLPipeline::RENDER_TYPE_TERRAIN, - LLPipeline::RENDER_TYPE_TREE, - LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_VOIDWATER, - LLPipeline::RENDER_TYPE_WATER, - LLPipeline::END_RENDER_TYPES)) - { - //clear faces from face pools - LLFastTimer t(FTM_RESET_DRAWORDER); - gPipeline.resetDrawOrders(); - } - - LLFastTimer ftm(FTM_STATESORT); - LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT); - - //LLVertexBuffer::unbind(); - - grabReferences(result); - for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - group->checkOcclusion(); - if (sUseOcclusion > 1 && group->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { - markOccluder(group); - } - else - { - group->setVisible(); - for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i) - { - markVisible(*i, camera); - } - } - } - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD) - { - LLSpatialGroup* last_group = NULL; - for (LLCullResult::bridge_list_t::iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i) - { - LLCullResult::bridge_list_t::iterator cur_iter = i; - LLSpatialBridge* bridge = *cur_iter; - LLSpatialGroup* group = bridge->getSpatialGroup(); - - if (last_group == NULL) - { - last_group = group; - } - - if (!bridge->isDead() && group && !group->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { - stateSort(bridge, camera); - } - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD && - last_group != group && last_group->changeLOD()) - { - last_group->mLastUpdateDistance = last_group->mDistance; - } - - last_group = group; - } - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD && - last_group && last_group->changeLOD()) - { - last_group->mLastUpdateDistance = last_group->mDistance; - } - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - group->checkOcclusion(); - if (sUseOcclusion > 1 && group->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { - markOccluder(group); - } - else - { - group->setVisible(); - stateSort(group, camera); - } - } - - { - LLFastTimer ftm(FTM_STATESORT_DRAWABLE); - for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList(); - iter != sCull->endVisibleList(); ++iter) - { - LLDrawable *drawablep = *iter; - if (!drawablep->isDead()) - { - stateSort(drawablep, camera); - } - } - } - { - LLFastTimer ftm(FTM_CLIENT_COPY); - LLVertexBuffer::clientCopy(); - } - - postSort(camera); -} - -void LLPipeline::stateSort(LLSpatialGroup* group, LLCamera& camera) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT); - if (group->changeLOD()) - { - for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i) - { - LLDrawable* drawablep = *i; - stateSort(drawablep, camera); - } - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD) - { //avoid redundant stateSort calls - group->mLastUpdateDistance = group->mDistance; - } - } - -} - -void LLPipeline::stateSort(LLSpatialBridge* bridge, LLCamera& camera) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT); - if (bridge->getSpatialGroup()->changeLOD()) - { - bool force_update = false; - bridge->updateDistance(camera, force_update); - } -} - -void LLPipeline::stateSort(LLDrawable* drawablep, LLCamera& camera) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT); - - if (!drawablep - || drawablep->isDead() - || !hasRenderType(drawablep->getRenderType())) - { - return; - } - - if (LLSelectMgr::getInstance()->mHideSelectedObjects) - { - if (drawablep->getVObj().notNull() && - drawablep->getVObj()->isSelected()) - { - return; - } - } - - if (drawablep->isAvatar()) - { //don't draw avatars beyond render distance or if we don't have a spatial group. - if ((drawablep->getSpatialGroup() == NULL) || - (drawablep->getSpatialGroup()->mDistance > LLVOAvatar::sRenderDistance)) - { - return; - } - - LLVOAvatar* avatarp = (LLVOAvatar*) drawablep->getVObj().get(); - if (!avatarp->isVisible()) - { - return; - } - } - - assertInitialized(); - - if (hasRenderType(drawablep->mRenderType)) - { - if (!drawablep->isState(LLDrawable::INVISIBLE|LLDrawable::FORCE_INVISIBLE)) - { - drawablep->setVisible(camera, NULL, FALSE); - } - else if (drawablep->isState(LLDrawable::CLEAR_INVISIBLE)) - { - // clear invisible flag here to avoid single frame glitch - drawablep->clearState(LLDrawable::FORCE_INVISIBLE|LLDrawable::CLEAR_INVISIBLE); - } - } - - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD) - { - //if (drawablep->isVisible()) isVisible() check here is redundant, if it wasn't visible, it wouldn't be here - { - if (!drawablep->isActive()) - { - bool force_update = false; - drawablep->updateDistance(camera, force_update); - } - else if (drawablep->isAvatar()) - { - bool force_update = false; - drawablep->updateDistance(camera, force_update); // calls vobj->updateLOD() which calls LLVOAvatar::updateVisibility() - } - } - } - - if (!drawablep->getVOVolume()) - { - for (LLDrawable::face_list_t::iterator iter = drawablep->mFaces.begin(); - iter != drawablep->mFaces.end(); iter++) - { - LLFace* facep = *iter; - - if (facep->hasGeometry()) - { - if (facep->getPool()) - { - facep->getPool()->enqueue(facep); - } - else - { - break; - } - } - } - } - - - mNumVisibleFaces += drawablep->getNumFaces(); -} - - -void forAllDrawables(LLCullResult::sg_list_t::iterator begin, - LLCullResult::sg_list_t::iterator end, - void (*func)(LLDrawable*)) -{ - for (LLCullResult::sg_list_t::iterator i = begin; i != end; ++i) - { - for (LLSpatialGroup::element_iter j = (*i)->getData().begin(); j != (*i)->getData().end(); ++j) - { - func(*j); - } - } -} - -void LLPipeline::forAllVisibleDrawables(void (*func)(LLDrawable*)) -{ - forAllDrawables(sCull->beginDrawableGroups(), sCull->endDrawableGroups(), func); - forAllDrawables(sCull->beginVisibleGroups(), sCull->endVisibleGroups(), func); -} - -//function for creating scripted beacons -void renderScriptedBeacons(LLDrawable* drawablep) -{ - LLViewerObject *vobj = drawablep->getVObj(); - if (vobj - && !vobj->isAvatar() - && !vobj->getParent() - && vobj->flagScripted()) - { - if (gPipeline.sRenderBeacons) - { - gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(1.f, 0.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth")); - } - - if (gPipeline.sRenderHighlight) - { - S32 face_id; - S32 count = drawablep->getNumFaces(); - for (face_id = 0; face_id < count; face_id++) - { - gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) ); - } - } - } -} - -void renderScriptedTouchBeacons(LLDrawable* drawablep) -{ - LLViewerObject *vobj = drawablep->getVObj(); - if (vobj - && !vobj->isAvatar() - && !vobj->getParent() - && vobj->flagScripted() - && vobj->flagHandleTouch()) - { - if (gPipeline.sRenderBeacons) - { - gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(1.f, 0.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth")); - } - - if (gPipeline.sRenderHighlight) - { - S32 face_id; - S32 count = drawablep->getNumFaces(); - for (face_id = 0; face_id < count; face_id++) - { - gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) ); - } - } - } -} - -void renderPhysicalBeacons(LLDrawable* drawablep) -{ - LLViewerObject *vobj = drawablep->getVObj(); - if (vobj - && !vobj->isAvatar() - //&& !vobj->getParent() - && vobj->usePhysics()) - { - if (gPipeline.sRenderBeacons) - { - gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(0.f, 1.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth")); - } - - if (gPipeline.sRenderHighlight) - { - S32 face_id; - S32 count = drawablep->getNumFaces(); - for (face_id = 0; face_id < count; face_id++) - { - gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) ); - } - } - } -} - -void renderParticleBeacons(LLDrawable* drawablep) -{ - // Look for attachments, objects, etc. - LLViewerObject *vobj = drawablep->getVObj(); - if (vobj - && vobj->isParticleSource()) - { - if (gPipeline.sRenderBeacons) - { - LLColor4 light_blue(0.5f, 0.5f, 1.f, 0.5f); - gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", light_blue, LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth")); - } - - if (gPipeline.sRenderHighlight) - { - S32 face_id; - S32 count = drawablep->getNumFaces(); - for (face_id = 0; face_id < count; face_id++) - { - gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) ); - } - } - } -} - -void renderSoundHighlights(LLDrawable* drawablep) -{ - // Look for attachments, objects, etc. - LLViewerObject *vobj = drawablep->getVObj(); - if (vobj && vobj->isAudioSource()) - { - if (gPipeline.sRenderHighlight) - { - S32 face_id; - S32 count = drawablep->getNumFaces(); - for (face_id = 0; face_id < count; face_id++) - { - gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) ); - } - } - } -} - -void LLPipeline::postSort(LLCamera& camera) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_POST_SORT); - LLFastTimer ftm(FTM_STATESORT_POSTSORT); - - assertInitialized(); - - llpushcallstacks ; - //rebuild drawable geometry - for (LLCullResult::sg_list_t::iterator i = sCull->beginDrawableGroups(); i != sCull->endDrawableGroups(); ++i) - { - LLSpatialGroup* group = *i; - if (!sUseOcclusion || - !group->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { - group->rebuildGeom(); - } - } - llpushcallstacks ; - //rebuild groups - sCull->assertDrawMapsEmpty(); - - rebuildPriorityGroups(); - llpushcallstacks ; - - const S32 bin_count = 1024*8; - - static LLCullResult::drawinfo_list_t alpha_bins[bin_count]; - static U32 bin_size[bin_count]; - - //clear one bin per frame to avoid memory bloat - static S32 clear_idx = 0; - clear_idx = (1+clear_idx)%bin_count; - alpha_bins[clear_idx].clear(); - - for (U32 j = 0; j < bin_count; j++) - { - bin_size[j] = 0; - } - - //build render map - for (LLCullResult::sg_list_t::iterator i = sCull->beginVisibleGroups(); i != sCull->endVisibleGroups(); ++i) - { - LLSpatialGroup* group = *i; - if (sUseOcclusion && - group->isOcclusionState(LLSpatialGroup::OCCLUDED)) - { - continue; - } - - if (group->isState(LLSpatialGroup::NEW_DRAWINFO) && group->isState(LLSpatialGroup::GEOM_DIRTY)) - { //no way this group is going to be drawable without a rebuild - group->rebuildGeom(); - } - - for (LLSpatialGroup::draw_map_t::iterator j = group->mDrawMap.begin(); j != group->mDrawMap.end(); ++j) - { - LLSpatialGroup::drawmap_elem_t& src_vec = j->second; - if (!hasRenderType(j->first)) - { - continue; - } - - for (LLSpatialGroup::drawmap_elem_t::iterator k = src_vec.begin(); k != src_vec.end(); ++k) - { - if (sMinRenderSize > 0.f) - { - LLVector4a bounds; - bounds.setSub((*k)->mExtents[1],(*k)->mExtents[0]); - - if (llmax(llmax(bounds[0], bounds[1]), bounds[2]) > sMinRenderSize) - { - sCull->pushDrawInfo(j->first, *k); - } - } - else - { - sCull->pushDrawInfo(j->first, *k); - } - } - } - - if (hasRenderType(LLPipeline::RENDER_TYPE_PASS_ALPHA)) - { - LLSpatialGroup::draw_map_t::iterator alpha = group->mDrawMap.find(LLRenderPass::PASS_ALPHA); - - if (alpha != group->mDrawMap.end()) - { //store alpha groups for sorting - LLSpatialBridge* bridge = group->mSpatialPartition->asBridge(); - if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD) - { - if (bridge) - { - LLCamera trans_camera = bridge->transformCamera(camera); - group->updateDistance(trans_camera); - } - else - { - group->updateDistance(camera); - } - } - - if (hasRenderType(LLDrawPool::POOL_ALPHA)) - { - sCull->pushAlphaGroup(group); - } - } - } - } - - if (!sShadowRender) - { - //sort by texture or bump map - for (U32 i = 0; i < LLRenderPass::NUM_RENDER_TYPES; ++i) - { - if (i == LLRenderPass::PASS_BUMP) - { - std::sort(sCull->beginRenderMap(i), sCull->endRenderMap(i), LLDrawInfo::CompareBump()); - } - else - { - std::sort(sCull->beginRenderMap(i), sCull->endRenderMap(i), LLDrawInfo::CompareTexturePtrMatrix()); - } - } - - std::sort(sCull->beginAlphaGroups(), sCull->endAlphaGroups(), LLSpatialGroup::CompareDepthGreater()); - } - llpushcallstacks ; - // only render if the flag is set. The flag is only set if we are in edit mode or the toggle is set in the menus - if (LLFloaterReg::instanceVisible("beacons") && !sShadowRender) - { - if (sRenderScriptedTouchBeacons) - { - // Only show the beacon on the root object. - forAllVisibleDrawables(renderScriptedTouchBeacons); - } - else - if (sRenderScriptedBeacons) - { - // Only show the beacon on the root object. - forAllVisibleDrawables(renderScriptedBeacons); - } - - if (sRenderPhysicalBeacons) - { - // Only show the beacon on the root object. - forAllVisibleDrawables(renderPhysicalBeacons); - } - - if (sRenderParticleBeacons) - { - forAllVisibleDrawables(renderParticleBeacons); - } - - // If god mode, also show audio cues - if (sRenderSoundBeacons && gAudiop) - { - // Walk all sound sources and render out beacons for them. Note, this isn't done in the ForAllVisibleDrawables function, because some are not visible. - LLAudioEngine::source_map::iterator iter; - for (iter = gAudiop->mAllSources.begin(); iter != gAudiop->mAllSources.end(); ++iter) - { - LLAudioSource *sourcep = iter->second; - - LLVector3d pos_global = sourcep->getPositionGlobal(); - LLVector3 pos = gAgent.getPosAgentFromGlobal(pos_global); - if (gPipeline.sRenderBeacons) - { - //pos += LLVector3(0.f, 0.f, 0.2f); - gObjectList.addDebugBeacon(pos, "", LLColor4(1.f, 1.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth")); - } - } - // now deal with highlights for all those seeable sound sources - forAllVisibleDrawables(renderSoundHighlights); - } - } - llpushcallstacks ; - // If managing your telehub, draw beacons at telehub and currently selected spawnpoint. - if (LLFloaterTelehub::renderBeacons()) - { - LLFloaterTelehub::addBeacons(); - } - - if (!sShadowRender) - { - mSelectedFaces.clear(); - - // Draw face highlights for selected faces. - if (LLSelectMgr::getInstance()->getTEMode()) - { - struct f : public LLSelectedTEFunctor - { - virtual bool apply(LLViewerObject* object, S32 te) - { - if (object->mDrawable) - { - gPipeline.mSelectedFaces.push_back(object->mDrawable->getFace(te)); - } - return true; - } - } func; - LLSelectMgr::getInstance()->getSelection()->applyToTEs(&func); - } - } - - //LLSpatialGroup::sNoDelete = FALSE; - llpushcallstacks ; -} - - -void render_hud_elements() -{ - LLMemType mt_rhe(LLMemType::MTYPE_PIPELINE_RENDER_HUD_ELS); - LLFastTimer t(FTM_RENDER_UI); - gPipeline.disableLights(); - - LLGLDisable fog(GL_FOG); - LLGLSUIDefault gls_ui; - - LLGLEnable stencil(GL_STENCIL_TEST); - glStencilFunc(GL_ALWAYS, 255, 0xFFFFFFFF); - glStencilMask(0xFFFFFFFF); - glStencilOp(GL_KEEP, GL_KEEP, GL_REPLACE); - - gGL.color4f(1,1,1,1); - if (!LLPipeline::sReflectionRender && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI)) - { - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - gViewerWindow->renderSelections(FALSE, FALSE, FALSE); // For HUD version in render_ui_3d() - - // Draw the tracking overlays - LLTracker::render3D(); - - // Show the property lines - LLWorld::getInstance()->renderPropertyLines(); - LLViewerParcelMgr::getInstance()->render(); - LLViewerParcelMgr::getInstance()->renderParcelCollision(); - - // Render name tags. - LLHUDObject::renderAll(); - } - else if (gForceRenderLandFence) - { - // This is only set when not rendering the UI, for parcel snapshots - LLViewerParcelMgr::getInstance()->render(); - } - else if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - LLHUDText::renderAllHUD(); - } - gGL.flush(); -} - -void LLPipeline::renderHighlights() -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_RENDER_HL); - - assertInitialized(); - - // Draw 3D UI elements here (before we clear the Z buffer in POOL_HUD) - // Render highlighted faces. - LLGLSPipelineAlpha gls_pipeline_alpha; - LLColor4 color(1.f, 1.f, 1.f, 0.5f); - LLGLEnable color_mat(GL_COLOR_MATERIAL); - disableLights(); - - if (!hasRenderType(LLPipeline::RENDER_TYPE_HUD) && !mHighlightSet.empty()) - { //draw blurry highlight image over screen - LLGLEnable blend(GL_BLEND); - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS); - LLGLDisable test(GL_ALPHA_TEST); - - LLGLEnable stencil(GL_STENCIL_TEST); - gGL.flush(); - glStencilMask(0xFFFFFFFF); - glClearStencil(1); - glClear(GL_STENCIL_BUFFER_BIT); - - glStencilFunc(GL_ALWAYS, 0, 0xFFFFFFFF); - glStencilOp(GL_REPLACE, GL_REPLACE, GL_REPLACE); - - gGL.setColorMask(false, false); - for (std::set<HighlightItem>::iterator iter = mHighlightSet.begin(); iter != mHighlightSet.end(); ++iter) - { - renderHighlight(iter->mItem->getVObj(), 1.f); - } - gGL.setColorMask(true, false); - - glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - glStencilFunc(GL_NOTEQUAL, 0, 0xFFFFFFFF); - - //gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA); - - gGL.pushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - gGL.pushMatrix(); - glLoadIdentity(); - - gGL.getTexUnit(0)->bind(&mHighlight); - - LLVector2 tc1; - LLVector2 tc2; - - tc1.setVec(0,0); - tc2.setVec(2,2); - - gGL.begin(LLRender::TRIANGLES); - - F32 scale = gSavedSettings.getF32("RenderHighlightBrightness"); - LLColor4 color = gSavedSettings.getColor4("RenderHighlightColor"); - F32 thickness = gSavedSettings.getF32("RenderHighlightThickness"); - - for (S32 pass = 0; pass < 2; ++pass) - { - if (pass == 0) - { - gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA); - } - else - { - gGL.setSceneBlendType(LLRender::BT_ALPHA); - } - - for (S32 i = 0; i < 8; ++i) - { - for (S32 j = 0; j < 8; ++j) - { - LLVector2 tc(i-4+0.5f, j-4+0.5f); - - F32 dist = 1.f-(tc.length()/sqrtf(32.f)); - dist *= scale/64.f; - - tc *= thickness; - tc.mV[0] = (tc.mV[0])/mHighlight.getWidth(); - tc.mV[1] = (tc.mV[1])/mHighlight.getHeight(); - - gGL.color4f(color.mV[0], - color.mV[1], - color.mV[2], - color.mV[3]*dist); - - gGL.texCoord2f(tc.mV[0]+tc1.mV[0], tc.mV[1]+tc2.mV[1]); - gGL.vertex2f(-1,3); - - gGL.texCoord2f(tc.mV[0]+tc1.mV[0], tc.mV[1]+tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc.mV[0]+tc2.mV[0], tc.mV[1]+tc1.mV[1]); - gGL.vertex2f(3,-1); - } - } - } - - gGL.end(); - - gGL.popMatrix(); - glMatrixMode(GL_MODELVIEW); - gGL.popMatrix(); - - //gGL.setSceneBlendType(LLRender::BT_ALPHA); - } - - if ((LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0)) - { - gHighlightProgram.bind(); - gHighlightProgram.vertexAttrib4f(LLViewerShaderMgr::MATERIAL_COLOR,1,1,1,0.5f); - } - - if (hasRenderDebugFeatureMask(RENDER_DEBUG_FEATURE_SELECTED)) - { - // Make sure the selection image gets downloaded and decoded - if (!mFaceSelectImagep) - { - mFaceSelectImagep = LLViewerTextureManager::getFetchedTexture(IMG_FACE_SELECT); - } - mFaceSelectImagep->addTextureStats((F32)MAX_IMAGE_AREA); - - U32 count = mSelectedFaces.size(); - for (U32 i = 0; i < count; i++) - { - LLFace *facep = mSelectedFaces[i]; - if (!facep || facep->getDrawable()->isDead()) - { - llerrs << "Bad face on selection" << llendl; - return; - } - - facep->renderSelected(mFaceSelectImagep, color); - } - } - - if (hasRenderDebugFeatureMask(RENDER_DEBUG_FEATURE_SELECTED)) - { - // Paint 'em red! - color.setVec(1.f, 0.f, 0.f, 0.5f); - if ((LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0)) - { - gHighlightProgram.vertexAttrib4f(LLViewerShaderMgr::MATERIAL_COLOR,1,0,0,0.5f); - } - int count = mHighlightFaces.size(); - for (S32 i = 0; i < count; i++) - { - LLFace* facep = mHighlightFaces[i]; - facep->renderSelected(LLViewerTexture::sNullImagep, color); - } - } - - // Contains a list of the faces of objects that are physical or - // have touch-handlers. - mHighlightFaces.clear(); - - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0) - { - gHighlightProgram.unbind(); - } -} - -//debug use -U32 LLPipeline::sCurRenderPoolType = 0 ; - -void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_RENDER_GEOM); - LLFastTimer t(FTM_RENDER_GEOMETRY); - - assertInitialized(); - - F64 saved_modelview[16]; - F64 saved_projection[16]; - - //HACK: preserve/restore matrices around HUD render - if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - for (U32 i = 0; i < 16; i++) - { - saved_modelview[i] = gGLModelView[i]; - saved_projection[i] = gGLProjection[i]; - } - } - - S32 stack_depth = 0; - - if (gDebugGL) - { - glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &stack_depth); - } - - /////////////////////////////////////////// - // - // Sync and verify GL state - // - // - - stop_glerror(); - - LLVertexBuffer::unbind(); - - // Do verification of GL state - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - if (mRenderDebugMask & RENDER_DEBUG_VERIFY) - { - if (!verify()) - { - llerrs << "Pipeline verification failed!" << llendl; - } - } - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:ForceVBO"); - - // Initialize lots of GL state to "safe" values - glMatrixMode(GL_TEXTURE); - glLoadIdentity(); - glMatrixMode(GL_MODELVIEW); - - LLGLSPipeline gls_pipeline; - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - - LLGLState gls_color_material(GL_COLOR_MATERIAL, mLightingDetail < 2); - - // Toggle backface culling for debugging - LLGLEnable cull_face(mBackfaceCull ? GL_CULL_FACE : 0); - // Set fog - BOOL use_fog = hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_FOG); - LLGLEnable fog_enable(use_fog && - !gPipeline.canUseWindLightShadersOnObjects() ? GL_FOG : 0); - gSky.updateFog(camera.getFar()); - if (!use_fog) - { - sUnderWaterRender = FALSE; - } - - gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sDefaultImagep); - LLViewerFetchedTexture::sDefaultImagep->setAddressMode(LLTexUnit::TAM_WRAP); - - ////////////////////////////////////////////// - // - // Actually render all of the geometry - // - // - stop_glerror(); - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPools"); - - for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter) - { - LLDrawPool *poolp = *iter; - if (hasRenderType(poolp->getType())) - { - poolp->prerender(); - } - } - - { - LLFastTimer t(FTM_POOLS); - - // HACK: don't calculate local lights if we're rendering the HUD! - // Removing this check will cause bad flickering when there are - // HUD elements being rendered AND the user is in flycam mode -nyx - if (!gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - calcNearbyLights(camera); - setupHWLights(NULL); - } - - BOOL occlude = sUseOcclusion > 1; - U32 cur_type = 0; - - pool_set_t::iterator iter1 = mPools.begin(); - while ( iter1 != mPools.end() ) - { - LLDrawPool *poolp = *iter1; - - cur_type = poolp->getType(); - - //debug use - sCurRenderPoolType = cur_type ; - - if (occlude && cur_type >= LLDrawPool::POOL_GRASS) - { - occlude = FALSE; - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - doOcclusion(camera); - } - - pool_set_t::iterator iter2 = iter1; - if (hasRenderType(poolp->getType()) && poolp->getNumPasses() > 0) - { - LLFastTimer t(FTM_POOLRENDER); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - for( S32 i = 0; i < poolp->getNumPasses(); i++ ) - { - LLVertexBuffer::unbind(); - poolp->beginRenderPass(i); - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - - p->render(i); - } - poolp->endRenderPass(i); - LLVertexBuffer::unbind(); - if (gDebugGL) - { - check_stack_depth(stack_depth); - std::string msg = llformat("%s pass %d", gPoolNames[cur_type].c_str(), i); - LLGLState::checkStates(msg); - LLGLState::checkTextureChannels(msg); - LLGLState::checkClientArrays(msg); - } - } - } - else - { - // Skip all pools of this type - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - } - } - iter1 = iter2; - stop_glerror(); - } - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPoolsEnd"); - - LLVertexBuffer::unbind(); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - if (occlude) - { - occlude = FALSE; - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - doOcclusion(camera); - } - } - - LLVertexBuffer::unbind(); - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - - - stop_glerror(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderHighlights"); - - if (!sReflectionRender) - { - renderHighlights(); - } - - // Contains a list of the faces of objects that are physical or - // have touch-handlers. - mHighlightFaces.clear(); - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDebug"); - - renderDebug(); - - LLVertexBuffer::unbind(); - - if (!LLPipeline::sReflectionRender && !LLPipeline::sRenderDeferred) - { - if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI)) - { - // Render debugging beacons. - gObjectList.renderObjectBeacons(); - gObjectList.resetObjectBeacons(); - } - else - { - // Make sure particle effects disappear - LLHUDObject::renderAllForTimer(); - } - } - else - { - // Make sure particle effects disappear - LLHUDObject::renderAllForTimer(); - } - - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomEnd"); - - //HACK: preserve/restore matrices around HUD render - if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - for (U32 i = 0; i < 16; i++) - { - gGLModelView[i] = saved_modelview[i]; - gGLProjection[i] = saved_projection[i]; - } - } - - LLVertexBuffer::unbind(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); -} - -void LLPipeline::renderGeomDeferred(LLCamera& camera) -{ - LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomDeferred"); - - LLMemType mt_rgd(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_DEFFERRED); - LLFastTimer t(FTM_RENDER_GEOMETRY); - - LLFastTimer t2(FTM_POOLS); - - LLGLEnable cull(GL_CULL_FACE); - - LLGLEnable stencil(GL_STENCIL_TEST); - glStencilFunc(GL_ALWAYS, 1, 0xFFFFFFFF); - stop_glerror(); - glStencilOp(GL_KEEP, GL_KEEP, GL_REPLACE); - stop_glerror(); - - for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter) - { - LLDrawPool *poolp = *iter; - if (hasRenderType(poolp->getType())) - { - poolp->prerender(); - } - } - - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - - LLVertexBuffer::unbind(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - U32 cur_type = 0; - - gGL.setColorMask(true, true); - - pool_set_t::iterator iter1 = mPools.begin(); - - while ( iter1 != mPools.end() ) - { - LLDrawPool *poolp = *iter1; - - cur_type = poolp->getType(); - - pool_set_t::iterator iter2 = iter1; - if (hasRenderType(poolp->getType()) && poolp->getNumDeferredPasses() > 0) - { - LLFastTimer t(FTM_POOLRENDER); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - for( S32 i = 0; i < poolp->getNumDeferredPasses(); i++ ) - { - LLVertexBuffer::unbind(); - poolp->beginDeferredPass(i); - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - - p->renderDeferred(i); - } - poolp->endDeferredPass(i); - LLVertexBuffer::unbind(); - - if (gDebugGL || gDebugPipeline) - { - GLint depth; - glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth); - if (depth > 3) - { - llerrs << "GL matrix stack corrupted!" << llendl; - } - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - } - } - } - else - { - // Skip all pools of this type - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - } - } - iter1 = iter2; - stop_glerror(); - } - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - gGL.setColorMask(true, false); -} - -void LLPipeline::renderGeomPostDeferred(LLCamera& camera) -{ - LLMemType mt_rgpd(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_POST_DEF); - LLFastTimer t(FTM_POOLS); - U32 cur_type = 0; - - LLGLEnable cull(GL_CULL_FACE); - - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - - calcNearbyLights(camera); - setupHWLights(NULL); - - gGL.setColorMask(true, false); - - pool_set_t::iterator iter1 = mPools.begin(); - BOOL occlude = LLPipeline::sUseOcclusion > 1; - - while ( iter1 != mPools.end() ) - { - LLDrawPool *poolp = *iter1; - - cur_type = poolp->getType(); - - if (occlude && cur_type >= LLDrawPool::POOL_GRASS) - { - occlude = FALSE; - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - doOcclusion(camera); - gGL.setColorMask(true, false); - } - - pool_set_t::iterator iter2 = iter1; - if (hasRenderType(poolp->getType()) && poolp->getNumPostDeferredPasses() > 0) - { - LLFastTimer t(FTM_POOLRENDER); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - for( S32 i = 0; i < poolp->getNumPostDeferredPasses(); i++ ) - { - LLVertexBuffer::unbind(); - poolp->beginPostDeferredPass(i); - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - - p->renderPostDeferred(i); - } - poolp->endPostDeferredPass(i); - LLVertexBuffer::unbind(); - - if (gDebugGL || gDebugPipeline) - { - GLint depth; - glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth); - if (depth > 3) - { - llerrs << "GL matrix stack corrupted!" << llendl; - } - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - } - } - } - else - { - // Skip all pools of this type - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - } - } - iter1 = iter2; - stop_glerror(); - } - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - if (occlude) - { - occlude = FALSE; - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - doOcclusion(camera); - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - } -} - -void LLPipeline::renderGeomShadow(LLCamera& camera) -{ - LLMemType mt_rgs(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_SHADOW); - U32 cur_type = 0; - - LLGLEnable cull(GL_CULL_FACE); - - LLVertexBuffer::unbind(); - - pool_set_t::iterator iter1 = mPools.begin(); - - while ( iter1 != mPools.end() ) - { - LLDrawPool *poolp = *iter1; - - cur_type = poolp->getType(); - - pool_set_t::iterator iter2 = iter1; - if (hasRenderType(poolp->getType()) && poolp->getNumShadowPasses() > 0) - { - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - - for( S32 i = 0; i < poolp->getNumShadowPasses(); i++ ) - { - LLVertexBuffer::unbind(); - poolp->beginShadowPass(i); - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - - p->renderShadow(i); - } - poolp->endShadowPass(i); - LLVertexBuffer::unbind(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - } - } - else - { - // Skip all pools of this type - for (iter2 = iter1; iter2 != mPools.end(); iter2++) - { - LLDrawPool *p = *iter2; - if (p->getType() != cur_type) - { - break; - } - } - } - iter1 = iter2; - stop_glerror(); - } - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); -} - - -void LLPipeline::addTrianglesDrawn(S32 index_count, U32 render_type) -{ - assertInitialized(); - S32 count = 0; - if (render_type == LLRender::TRIANGLE_STRIP) - { - count = index_count-2; - } - else - { - count = index_count/3; - } - - mTrianglesDrawn += count; - mBatchCount++; - mMaxBatchSize = llmax(mMaxBatchSize, count); - mMinBatchSize = llmin(mMinBatchSize, count); - - if (LLPipeline::sRenderFrameTest) - { - gViewerWindow->getWindow()->swapBuffers(); - ms_sleep(16); - } -} - -void LLPipeline::renderPhysicsDisplay() -{ - if (!hasRenderDebugMask(LLPipeline::RENDER_DEBUG_PHYSICS_SHAPES)) - { - return; - } - - allocatePhysicsBuffer(); - - gGL.flush(); - mPhysicsDisplay.bindTarget(); - glClearColor(0,0,0,1); - gGL.setColorMask(true, true); - mPhysicsDisplay.clear(); - glClearColor(0,0,0,0); - - gGL.setColorMask(true, false); - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - if (hasRenderType(part->mDrawableType)) - { - part->renderPhysicsShapes(); - } - } - } - } - - for (LLCullResult::bridge_list_t::const_iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i) - { - LLSpatialBridge* bridge = *i; - if (!bridge->isDead() && hasRenderType(bridge->mDrawableType)) - { - glPushMatrix(); - glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix); - bridge->renderPhysicsShapes(); - glPopMatrix(); - } - } - - - gGL.flush(); - mPhysicsDisplay.flush(); -} - - -void LLPipeline::renderDebug() -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE); - - assertInitialized(); - - gGL.color4f(1,1,1,1); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - gGL.setColorMask(true, false); - - bool hud_only = hasRenderType(LLPipeline::RENDER_TYPE_HUD); - - // Debug stuff. - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - if ( hud_only && (part->mDrawableType == RENDER_TYPE_HUD || part->mDrawableType == RENDER_TYPE_HUD_PARTICLES) || - !hud_only && hasRenderType(part->mDrawableType) ) - { - part->renderDebug(); - } - } - } - } - - for (LLCullResult::bridge_list_t::const_iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i) - { - LLSpatialBridge* bridge = *i; - if (!bridge->isDead() && hasRenderType(bridge->mDrawableType)) - { - glPushMatrix(); - glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix); - bridge->renderDebug(); - glPopMatrix(); - } - } - - if (gSavedSettings.getBOOL("DebugShowUploadCost")) - { - std::set<LLUUID> textures; - std::set<LLUUID> sculpts; - std::set<LLUUID> meshes; - - BOOL selected = TRUE; - if (LLSelectMgr::getInstance()->getSelection()->isEmpty()) - { - selected = FALSE; - } - - for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter) - { - LLSpatialGroup* group = *iter; - LLSpatialGroup::OctreeNode* node = group->mOctreeNode; - for (LLSpatialGroup::OctreeNode::element_iter elem = node->getData().begin(); elem != node->getData().end(); ++elem) - { - LLDrawable* drawable = *elem; - LLVOVolume* volume = drawable->getVOVolume(); - if (volume && volume->isSelected() == selected) - { - for (U32 i = 0; i < volume->getNumTEs(); ++i) - { - LLTextureEntry* te = volume->getTE(i); - textures.insert(te->getID()); - } - - if (volume->isSculpted()) - { - LLUUID sculpt_id = volume->getVolume()->getParams().getSculptID(); - if (volume->isMesh()) - { - meshes.insert(sculpt_id); - } - else - { - sculpts.insert(sculpt_id); - } - } - } - } - } - - gPipeline.mDebugTextureUploadCost = textures.size() * 10; - gPipeline.mDebugSculptUploadCost = sculpts.size()*10; - - U32 mesh_cost = 0; - - for (std::set<LLUUID>::iterator iter = meshes.begin(); iter != meshes.end(); ++iter) - { - mesh_cost += gMeshRepo.getResourceCost(*iter)*10; - } - - gPipeline.mDebugMeshUploadCost = mesh_cost; - } - - if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - LLVertexBuffer::unbind(); - - LLGLEnable blend(GL_BLEND); - LLGLDepthTest depth(TRUE, FALSE); - LLGLDisable cull(GL_CULL_FACE); - - gGL.color4f(1,1,1,1); - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - F32 a = 0.1f; - - F32 col[] = - { - 1,0,0,a, - 0,1,0,a, - 0,0,1,a, - 1,0,1,a, - - 1,1,0,a, - 0,1,1,a, - 1,1,1,a, - 1,0,1,a, - }; - - for (U32 i = 0; i < 8; i++) - { - LLVector3* frust = mShadowCamera[i].mAgentFrustum; - - if (i > 3) - { //render shadow frusta as volumes - if (mShadowFrustPoints[i-4].empty()) - { - continue; - } - - gGL.color4fv(col+(i-4)*4); - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV); - gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[5].mV); - gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[6].mV); - gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[7].mV); - gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV); - gGL.end(); - - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.vertex3fv(frust[0].mV); - gGL.vertex3fv(frust[1].mV); - gGL.vertex3fv(frust[3].mV); - gGL.vertex3fv(frust[2].mV); - gGL.end(); - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.vertex3fv(frust[4].mV); - gGL.vertex3fv(frust[5].mV); - gGL.vertex3fv(frust[7].mV); - gGL.vertex3fv(frust[6].mV); - gGL.end(); - } - - - if (i < 4) - { - - //if (i == 0 || !mShadowFrustPoints[i].empty()) - { - //render visible point cloud - gGL.flush(); - glPointSize(8.f); - gGL.begin(LLRender::POINTS); - - F32* c = col+i*4; - gGL.color3fv(c); - - for (U32 j = 0; j < mShadowFrustPoints[i].size(); ++j) - { - gGL.vertex3fv(mShadowFrustPoints[i][j].mV); - - } - gGL.end(); - - gGL.flush(); - glPointSize(1.f); - - LLVector3* ext = mShadowExtents[i]; - LLVector3 pos = (ext[0]+ext[1])*0.5f; - LLVector3 size = (ext[1]-ext[0])*0.5f; - drawBoxOutline(pos, size); - - //render camera frustum splits as outlines - gGL.begin(LLRender::LINES); - gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[1].mV); - gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[2].mV); - gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[3].mV); - gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[0].mV); - gGL.vertex3fv(frust[4].mV); gGL.vertex3fv(frust[5].mV); - gGL.vertex3fv(frust[5].mV); gGL.vertex3fv(frust[6].mV); - gGL.vertex3fv(frust[6].mV); gGL.vertex3fv(frust[7].mV); - gGL.vertex3fv(frust[7].mV); gGL.vertex3fv(frust[4].mV); - gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV); - gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[5].mV); - gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[6].mV); - gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[7].mV); - gGL.end(); - } - } - - /*gGL.flush(); - glLineWidth(16-i*2); - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 j = 0; j < LLViewerRegion::NUM_PARTITIONS; j++) - { - LLSpatialPartition* part = region->getSpatialPartition(j); - if (part) - { - if (hasRenderType(part->mDrawableType)) - { - part->renderIntersectingBBoxes(&mShadowCamera[i]); - } - } - } - } - gGL.flush(); - glLineWidth(1.f);*/ - } - } - - if (mRenderDebugMask & RENDER_DEBUG_COMPOSITION) - { - // Debug composition layers - F32 x, y; - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - if (gAgent.getRegion()) - { - gGL.begin(LLRender::POINTS); - // Draw the composition layer for the region that I'm in. - for (x = 0; x <= 260; x++) - { - for (y = 0; y <= 260; y++) - { - if ((x > 255) || (y > 255)) - { - gGL.color4f(1.f, 0.f, 0.f, 1.f); - } - else - { - gGL.color4f(0.f, 0.f, 1.f, 1.f); - } - F32 z = gAgent.getRegion()->getCompositionXY((S32)x, (S32)y); - z *= 5.f; - z += 50.f; - gGL.vertex3f(x, y, z); - } - } - gGL.end(); - } - } - - if (mRenderDebugMask & LLPipeline::RENDER_DEBUG_BUILD_QUEUE) - { - U32 count = 0; - U32 size = mGroupQ2.size(); - LLColor4 col; - - LLVertexBuffer::unbind(); - LLGLEnable blend(GL_BLEND); - gGL.setSceneBlendType(LLRender::BT_ALPHA); - LLGLDepthTest depth(GL_TRUE, GL_FALSE); - gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep); - - gGL.pushMatrix(); - glLoadMatrixd(gGLModelView); - gGLLastMatrix = NULL; - - for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ2.begin(); iter != mGroupQ2.end(); ++iter) - { - LLSpatialGroup* group = *iter; - if (group->isDead()) - { - continue; - } - - LLSpatialBridge* bridge = group->mSpatialPartition->asBridge(); - - if (bridge && (!bridge->mDrawable || bridge->mDrawable->isDead())) - { - continue; - } - - if (bridge) - { - gGL.pushMatrix(); - glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix); - } - - F32 alpha = llclamp((F32) (size-count)/size, 0.f, 1.f); - - - LLVector2 c(1.f-alpha, alpha); - c.normVec(); - - - ++count; - col.set(c.mV[0], c.mV[1], 0, alpha*0.5f+0.5f); - group->drawObjectBox(col); - - if (bridge) - { - gGL.popMatrix(); - } - } - - gGL.popMatrix(); - } - - gGL.flush(); - - gPipeline.renderPhysicsDisplay(); -} - -void LLPipeline::rebuildPools() -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_REBUILD_POOLS); - - assertInitialized(); - - S32 max_count = mPools.size(); - pool_set_t::iterator iter1 = mPools.upper_bound(mLastRebuildPool); - while(max_count > 0 && mPools.size() > 0) // && num_rebuilds < MAX_REBUILDS) - { - if (iter1 == mPools.end()) - { - iter1 = mPools.begin(); - } - LLDrawPool* poolp = *iter1; - - if (poolp->isDead()) - { - mPools.erase(iter1++); - removeFromQuickLookup( poolp ); - if (poolp == mLastRebuildPool) - { - mLastRebuildPool = NULL; - } - delete poolp; - } - else - { - mLastRebuildPool = poolp; - iter1++; - } - max_count--; - } - - if (isAgentAvatarValid()) - { - gAgentAvatarp->rebuildHUD(); - } -} - -void LLPipeline::addToQuickLookup( LLDrawPool* new_poolp ) -{ - LLMemType mt(LLMemType::MTYPE_PIPELINE_QUICK_LOOKUP); - - assertInitialized(); - - switch( new_poolp->getType() ) - { - case LLDrawPool::POOL_SIMPLE: - if (mSimplePool) - { - llassert(0); - llwarns << "Ignoring duplicate simple pool." << llendl; - } - else - { - mSimplePool = (LLRenderPass*) new_poolp; - } - break; - - case LLDrawPool::POOL_GRASS: - if (mGrassPool) - { - llassert(0); - llwarns << "Ignoring duplicate grass pool." << llendl; - } - else - { - mGrassPool = (LLRenderPass*) new_poolp; - } - break; - - case LLDrawPool::POOL_FULLBRIGHT: - if (mFullbrightPool) - { - llassert(0); - llwarns << "Ignoring duplicate simple pool." << llendl; - } - else - { - mFullbrightPool = (LLRenderPass*) new_poolp; - } - break; - - case LLDrawPool::POOL_INVISIBLE: - if (mInvisiblePool) - { - llassert(0); - llwarns << "Ignoring duplicate simple pool." << llendl; - } - else - { - mInvisiblePool = (LLRenderPass*) new_poolp; - } - break; - - case LLDrawPool::POOL_GLOW: - if (mGlowPool) - { - llassert(0); - llwarns << "Ignoring duplicate glow pool." << llendl; - } - else - { - mGlowPool = (LLRenderPass*) new_poolp; - } - break; - - case LLDrawPool::POOL_TREE: - mTreePools[ uintptr_t(new_poolp->getTexture()) ] = new_poolp ; - break; - - case LLDrawPool::POOL_TERRAIN: - mTerrainPools[ uintptr_t(new_poolp->getTexture()) ] = new_poolp ; - break; - - case LLDrawPool::POOL_BUMP: - if (mBumpPool) - { - llassert(0); - llwarns << "Ignoring duplicate bump pool." << llendl; - } - else - { - mBumpPool = new_poolp; - } - break; - - case LLDrawPool::POOL_ALPHA: - if( mAlphaPool ) - { - llassert(0); - llwarns << "LLPipeline::addPool(): Ignoring duplicate Alpha pool" << llendl; - } - else - { - mAlphaPool = new_poolp; - } - break; - - case LLDrawPool::POOL_AVATAR: - break; // Do nothing - - case LLDrawPool::POOL_SKY: - if( mSkyPool ) - { - llassert(0); - llwarns << "LLPipeline::addPool(): Ignoring duplicate Sky pool" << llendl; - } - else - { - mSkyPool = new_poolp; - } - break; - - case LLDrawPool::POOL_WATER: - if( mWaterPool ) - { - llassert(0); - llwarns << "LLPipeline::addPool(): Ignoring duplicate Water pool" << llendl; - } - else - { - mWaterPool = new_poolp; - } - break; - - case LLDrawPool::POOL_GROUND: - if( mGroundPool ) - { - llassert(0); - llwarns << "LLPipeline::addPool(): Ignoring duplicate Ground Pool" << llendl; - } - else - { - mGroundPool = new_poolp; - } - break; - - case LLDrawPool::POOL_WL_SKY: - if( mWLSkyPool ) - { - llassert(0); - llwarns << "LLPipeline::addPool(): Ignoring duplicate WLSky Pool" << llendl; - } - else - { - mWLSkyPool = new_poolp; - } - break; - - default: - llassert(0); - llwarns << "Invalid Pool Type in LLPipeline::addPool()" << llendl; - break; - } -} - -void LLPipeline::removePool( LLDrawPool* poolp ) -{ - assertInitialized(); - removeFromQuickLookup(poolp); - mPools.erase(poolp); - delete poolp; -} - -void LLPipeline::removeFromQuickLookup( LLDrawPool* poolp ) -{ - assertInitialized(); - LLMemType mt(LLMemType::MTYPE_PIPELINE); - switch( poolp->getType() ) - { - case LLDrawPool::POOL_SIMPLE: - llassert(mSimplePool == poolp); - mSimplePool = NULL; - break; - - case LLDrawPool::POOL_GRASS: - llassert(mGrassPool == poolp); - mGrassPool = NULL; - break; - - case LLDrawPool::POOL_FULLBRIGHT: - llassert(mFullbrightPool == poolp); - mFullbrightPool = NULL; - break; - - case LLDrawPool::POOL_INVISIBLE: - llassert(mInvisiblePool == poolp); - mInvisiblePool = NULL; - break; - - case LLDrawPool::POOL_WL_SKY: - llassert(mWLSkyPool == poolp); - mWLSkyPool = NULL; - break; - - case LLDrawPool::POOL_GLOW: - llassert(mGlowPool == poolp); - mGlowPool = NULL; - break; - - case LLDrawPool::POOL_TREE: - #ifdef _DEBUG - { - BOOL found = mTreePools.erase( (uintptr_t)poolp->getTexture() ); - llassert( found ); - } - #else - mTreePools.erase( (uintptr_t)poolp->getTexture() ); - #endif - break; - - case LLDrawPool::POOL_TERRAIN: - #ifdef _DEBUG - { - BOOL found = mTerrainPools.erase( (uintptr_t)poolp->getTexture() ); - llassert( found ); - } - #else - mTerrainPools.erase( (uintptr_t)poolp->getTexture() ); - #endif - break; - - case LLDrawPool::POOL_BUMP: - llassert( poolp == mBumpPool ); - mBumpPool = NULL; - break; - - case LLDrawPool::POOL_ALPHA: - llassert( poolp == mAlphaPool ); - mAlphaPool = NULL; - break; - - case LLDrawPool::POOL_AVATAR: - break; // Do nothing - - case LLDrawPool::POOL_SKY: - llassert( poolp == mSkyPool ); - mSkyPool = NULL; - break; - - case LLDrawPool::POOL_WATER: - llassert( poolp == mWaterPool ); - mWaterPool = NULL; - break; - - case LLDrawPool::POOL_GROUND: - llassert( poolp == mGroundPool ); - mGroundPool = NULL; - break; - - default: - llassert(0); - llwarns << "Invalid Pool Type in LLPipeline::removeFromQuickLookup() type=" << poolp->getType() << llendl; - break; - } -} - -void LLPipeline::resetDrawOrders() -{ - assertInitialized(); - // Iterate through all of the draw pools and rebuild them. - for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter) - { - LLDrawPool *poolp = *iter; - poolp->resetDrawOrders(); - } -} - -//============================================================================ -// Once-per-frame setup of hardware lights, -// including sun/moon, avatar backlight, and up to 6 local lights - -void LLPipeline::setupAvatarLights(BOOL for_edit) -{ - assertInitialized(); - - if (for_edit) - { - LLColor4 diffuse(1.f, 1.f, 1.f, 0.f); - LLVector4 light_pos_cam(-8.f, 0.25f, 10.f, 0.f); // w==0 => directional light - LLMatrix4 camera_mat = LLViewerCamera::getInstance()->getModelview(); - LLMatrix4 camera_rot(camera_mat.getMat3()); - camera_rot.invert(); - LLVector4 light_pos = light_pos_cam * camera_rot; - - light_pos.normalize(); - - LLLightState* light = gGL.getLight(1); - - mHWLightColors[1] = diffuse; - - light->setDiffuse(diffuse); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - light->setPosition(light_pos); - light->setConstantAttenuation(1.f); - light->setLinearAttenuation(0.f); - light->setQuadraticAttenuation(0.f); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - } - else if (gAvatarBacklight) // Always true (unless overridden in a devs .ini) - { - LLVector3 opposite_pos = -1.f * mSunDir; - LLVector3 orthog_light_pos = mSunDir % LLVector3::z_axis; - LLVector4 backlight_pos = LLVector4(lerp(opposite_pos, orthog_light_pos, 0.3f), 0.0f); - backlight_pos.normalize(); - - LLColor4 light_diffuse = mSunDiffuse; - LLColor4 backlight_diffuse(1.f - light_diffuse.mV[VRED], 1.f - light_diffuse.mV[VGREEN], 1.f - light_diffuse.mV[VBLUE], 1.f); - F32 max_component = 0.001f; - for (S32 i = 0; i < 3; i++) - { - if (backlight_diffuse.mV[i] > max_component) - { - max_component = backlight_diffuse.mV[i]; - } - } - F32 backlight_mag; - if (gSky.getSunDirection().mV[2] >= LLSky::NIGHTTIME_ELEVATION_COS) - { - backlight_mag = BACKLIGHT_DAY_MAGNITUDE_OBJECT; - } - else - { - backlight_mag = BACKLIGHT_NIGHT_MAGNITUDE_OBJECT; - } - backlight_diffuse *= backlight_mag / max_component; - - mHWLightColors[1] = backlight_diffuse; - - LLLightState* light = gGL.getLight(1); - - light->setPosition(backlight_pos); - light->setDiffuse(backlight_diffuse); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - light->setConstantAttenuation(1.f); - light->setLinearAttenuation(0.f); - light->setQuadraticAttenuation(0.f); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - } - else - { - LLLightState* light = gGL.getLight(1); - - mHWLightColors[1] = LLColor4::black; - - light->setDiffuse(LLColor4::black); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - } -} - -static F32 calc_light_dist(LLVOVolume* light, const LLVector3& cam_pos, F32 max_dist) -{ - F32 inten = light->getLightIntensity(); - if (inten < .001f) - { - return max_dist; - } - F32 radius = light->getLightRadius(); - BOOL selected = light->isSelected(); - LLVector3 dpos = light->getRenderPosition() - cam_pos; - F32 dist2 = dpos.lengthSquared(); - if (!selected && dist2 > (max_dist + radius)*(max_dist + radius)) - { - return max_dist; - } - F32 dist = (F32) sqrt(dist2); - dist *= 1.f / inten; - dist -= radius; - if (selected) - { - dist -= 10000.f; // selected lights get highest priority - } - if (light->mDrawable.notNull() && light->mDrawable->isState(LLDrawable::ACTIVE)) - { - // moving lights get a little higher priority (too much causes artifacts) - dist -= light->getLightRadius()*0.25f; - } - return dist; -} - -void LLPipeline::calcNearbyLights(LLCamera& camera) -{ - assertInitialized(); - - if (LLPipeline::sReflectionRender) - { - return; - } - - if (mLightingDetail >= 1) - { - // mNearbyLight (and all light_set_t's) are sorted such that - // begin() == the closest light and rbegin() == the farthest light - const S32 MAX_LOCAL_LIGHTS = 6; -// LLVector3 cam_pos = gAgent.getCameraPositionAgent(); - LLVector3 cam_pos = LLViewerJoystick::getInstance()->getOverrideCamera() ? - camera.getOrigin() : - gAgent.getPositionAgent(); - - F32 max_dist = LIGHT_MAX_RADIUS * 4.f; // ignore enitrely lights > 4 * max light rad - - // UPDATE THE EXISTING NEARBY LIGHTS - light_set_t cur_nearby_lights; - for (light_set_t::iterator iter = mNearbyLights.begin(); - iter != mNearbyLights.end(); iter++) - { - const Light* light = &(*iter); - LLDrawable* drawable = light->drawable; - LLVOVolume* volight = drawable->getVOVolume(); - if (!volight || !drawable->isState(LLDrawable::LIGHT)) - { - drawable->clearState(LLDrawable::NEARBY_LIGHT); - continue; - } - if (light->fade <= -LIGHT_FADE_TIME) - { - drawable->clearState(LLDrawable::NEARBY_LIGHT); - continue; - } - if (!sRenderAttachedLights && volight && volight->isAttachment()) - { - drawable->clearState(LLDrawable::NEARBY_LIGHT); - continue; - } - - F32 dist = calc_light_dist(volight, cam_pos, max_dist); - cur_nearby_lights.insert(Light(drawable, dist, light->fade)); - } - mNearbyLights = cur_nearby_lights; - - // FIND NEW LIGHTS THAT ARE IN RANGE - light_set_t new_nearby_lights; - for (LLDrawable::drawable_set_t::iterator iter = mLights.begin(); - iter != mLights.end(); ++iter) - { - LLDrawable* drawable = *iter; - LLVOVolume* light = drawable->getVOVolume(); - if (!light || drawable->isState(LLDrawable::NEARBY_LIGHT)) - { - continue; - } - if (light->isHUDAttachment()) - { - continue; // no lighting from HUD objects - } - F32 dist = calc_light_dist(light, cam_pos, max_dist); - if (dist >= max_dist) - { - continue; - } - if (!sRenderAttachedLights && light && light->isAttachment()) - { - continue; - } - new_nearby_lights.insert(Light(drawable, dist, 0.f)); - if (new_nearby_lights.size() > (U32)MAX_LOCAL_LIGHTS) - { - new_nearby_lights.erase(--new_nearby_lights.end()); - const Light& last = *new_nearby_lights.rbegin(); - max_dist = last.dist; - } - } - - // INSERT ANY NEW LIGHTS - for (light_set_t::iterator iter = new_nearby_lights.begin(); - iter != new_nearby_lights.end(); iter++) - { - const Light* light = &(*iter); - if (mNearbyLights.size() < (U32)MAX_LOCAL_LIGHTS) - { - mNearbyLights.insert(*light); - ((LLDrawable*) light->drawable)->setState(LLDrawable::NEARBY_LIGHT); - } - else - { - // crazy cast so that we can overwrite the fade value - // even though gcc enforces sets as const - // (fade value doesn't affect sort so this is safe) - Light* farthest_light = ((Light*) (&(*(mNearbyLights.rbegin())))); - if (light->dist < farthest_light->dist) - { - if (farthest_light->fade >= 0.f) - { - farthest_light->fade = -gFrameIntervalSeconds; - } - } - else - { - break; // none of the other lights are closer - } - } - } - - } -} - -void LLPipeline::setupHWLights(LLDrawPool* pool) -{ - assertInitialized(); - - // Ambient - LLColor4 ambient = gSky.getTotalAmbientColor(); - glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV); - - // Light 0 = Sun or Moon (All objects) - { - if (gSky.getSunDirection().mV[2] >= LLSky::NIGHTTIME_ELEVATION_COS) - { - mSunDir.setVec(gSky.getSunDirection()); - mSunDiffuse.setVec(gSky.getSunDiffuseColor()); - } - else - { - mSunDir.setVec(gSky.getMoonDirection()); - mSunDiffuse.setVec(gSky.getMoonDiffuseColor()); - } - - F32 max_color = llmax(mSunDiffuse.mV[0], mSunDiffuse.mV[1], mSunDiffuse.mV[2]); - if (max_color > 1.f) - { - mSunDiffuse *= 1.f/max_color; - } - mSunDiffuse.clamp(); - - LLVector4 light_pos(mSunDir, 0.0f); - LLColor4 light_diffuse = mSunDiffuse; - mHWLightColors[0] = light_diffuse; - - LLLightState* light = gGL.getLight(0); - light->setPosition(light_pos); - light->setDiffuse(light_diffuse); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - light->setConstantAttenuation(1.f); - light->setLinearAttenuation(0.f); - light->setQuadraticAttenuation(0.f); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - } - - // Light 1 = Backlight (for avatars) - // (set by enableLightsAvatar) - - S32 cur_light = 2; - - // Nearby lights = LIGHT 2-7 - - mLightMovingMask = 0; - - if (mLightingDetail >= 1) - { - for (light_set_t::iterator iter = mNearbyLights.begin(); - iter != mNearbyLights.end(); ++iter) - { - LLDrawable* drawable = iter->drawable; - LLVOVolume* light = drawable->getVOVolume(); - if (!light) - { - continue; - } - if (drawable->isState(LLDrawable::ACTIVE)) - { - mLightMovingMask |= (1<<cur_light); - } - - LLColor4 light_color = light->getLightColor(); - light_color.mV[3] = 0.0f; - - F32 fade = iter->fade; - if (fade < LIGHT_FADE_TIME) - { - // fade in/out light - if (fade >= 0.f) - { - fade = fade / LIGHT_FADE_TIME; - ((Light*) (&(*iter)))->fade += gFrameIntervalSeconds; - } - else - { - fade = 1.f + fade / LIGHT_FADE_TIME; - ((Light*) (&(*iter)))->fade -= gFrameIntervalSeconds; - } - fade = llclamp(fade,0.f,1.f); - light_color *= fade; - } - - LLVector3 light_pos(light->getRenderPosition()); - LLVector4 light_pos_gl(light_pos, 1.0f); - - F32 light_radius = llmax(light->getLightRadius(), 0.001f); - - F32 x = (3.f * (1.f + light->getLightFalloff())); // why this magic? probably trying to match a historic behavior. - float linatten = x / (light_radius); // % of brightness at radius - - mHWLightColors[cur_light] = light_color; - LLLightState* light_state = gGL.getLight(cur_light); - - light_state->setPosition(light_pos_gl); - light_state->setDiffuse(light_color); - light_state->setAmbient(LLColor4::black); - light_state->setConstantAttenuation(0.f); - light_state->setLinearAttenuation(linatten); - light_state->setQuadraticAttenuation(0.f); - - if (light->isLightSpotlight() // directional (spot-)light - && (LLPipeline::sRenderDeferred || gSavedSettings.getBOOL("RenderSpotLightsInNondeferred"))) // these are only rendered as GL spotlights if we're in deferred rendering mode *or* the setting forces them on - { - LLVector3 spotparams = light->getSpotLightParams(); - LLQuaternion quat = light->getRenderRotation(); - LLVector3 at_axis(0,0,-1); // this matches deferred rendering's object light direction - at_axis *= quat; - - light_state->setSpotDirection(at_axis); - light_state->setSpotCutoff(90.f); - light_state->setSpotExponent(2.f); - - light_state->setSpecular(LLColor4::black); - } - else // omnidirectional (point) light - { - light_state->setSpotExponent(0.f); - light_state->setSpotCutoff(180.f); - - // we use specular.w = 1.0 as a cheap hack for the shaders to know that this is omnidirectional rather than a spotlight - const LLColor4 specular(0.f, 0.f, 0.f, 1.f); - light_state->setSpecular(specular); - } - cur_light++; - if (cur_light >= 8) - { - break; // safety - } - } - } - for ( ; cur_light < 8 ; cur_light++) - { - mHWLightColors[cur_light] = LLColor4::black; - LLLightState* light = gGL.getLight(cur_light); - - light->setDiffuse(LLColor4::black); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - } - if (gAgentAvatarp && - gAgentAvatarp->mSpecialRenderMode == 3) - { - LLColor4 light_color = LLColor4::white; - light_color.mV[3] = 0.0f; - - LLVector3 light_pos(LLViewerCamera::getInstance()->getOrigin()); - LLVector4 light_pos_gl(light_pos, 1.0f); - - F32 light_radius = 16.f; - - F32 x = 3.f; - float linatten = x / (light_radius); // % of brightness at radius - - mHWLightColors[2] = light_color; - LLLightState* light = gGL.getLight(2); - - light->setPosition(light_pos_gl); - light->setDiffuse(light_color); - light->setAmbient(LLColor4::black); - light->setSpecular(LLColor4::black); - light->setQuadraticAttenuation(0.f); - light->setConstantAttenuation(0.f); - light->setLinearAttenuation(linatten); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - } - - // Init GL state - glDisable(GL_LIGHTING); - for (S32 i = 0; i < 8; ++i) - { - gGL.getLight(i)->disable(); - } - mLightMask = 0; -} - -void LLPipeline::enableLights(U32 mask) -{ - assertInitialized(); - - if (mLightingDetail == 0) - { - mask &= 0xf003; // sun and backlight only (and fullbright bit) - } - if (mLightMask != mask) - { - stop_glerror(); - if (!mLightMask) - { - glEnable(GL_LIGHTING); - } - if (mask) - { - stop_glerror(); - for (S32 i=0; i<8; i++) - { - LLLightState* light = gGL.getLight(i); - if (mask & (1<<i)) - { - light->enable(); - light->setDiffuse(mHWLightColors[i]); - } - else - { - light->disable(); - light->setDiffuse(LLColor4::black); - } - } - stop_glerror(); - } - else - { - glDisable(GL_LIGHTING); - } - stop_glerror(); - mLightMask = mask; - LLColor4 ambient = gSky.getTotalAmbientColor(); - glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV); - stop_glerror(); - } -} - -void LLPipeline::enableLightsStatic() -{ - assertInitialized(); - U32 mask = 0x01; // Sun - if (mLightingDetail >= 2) - { - mask |= mLightMovingMask; // Hardware moving lights - } - else - { - mask |= 0xff & (~2); // Hardware local lights - } - enableLights(mask); -} - -void LLPipeline::enableLightsDynamic() -{ - assertInitialized(); - U32 mask = 0xff & (~2); // Local lights - enableLights(mask); - - if (isAgentAvatarValid() && getLightingDetail() <= 0) - { - if (gAgentAvatarp->mSpecialRenderMode == 0) // normal - { - gPipeline.enableLightsAvatar(); - } - else if (gAgentAvatarp->mSpecialRenderMode >= 1) // anim preview - { - gPipeline.enableLightsAvatarEdit(LLColor4(0.7f, 0.6f, 0.3f, 1.f)); - } - } -} - -void LLPipeline::enableLightsAvatar() -{ - U32 mask = 0xff; // All lights - setupAvatarLights(FALSE); - enableLights(mask); -} - -void LLPipeline::enableLightsPreview() -{ - disableLights(); - - glEnable(GL_LIGHTING); - LLColor4 ambient = gSavedSettings.getColor4("PreviewAmbientColor"); - glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV); - - - LLColor4 diffuse0 = gSavedSettings.getColor4("PreviewDiffuse0"); - LLColor4 specular0 = gSavedSettings.getColor4("PreviewSpecular0"); - LLColor4 diffuse1 = gSavedSettings.getColor4("PreviewDiffuse1"); - LLColor4 specular1 = gSavedSettings.getColor4("PreviewSpecular1"); - LLColor4 diffuse2 = gSavedSettings.getColor4("PreviewDiffuse2"); - LLColor4 specular2 = gSavedSettings.getColor4("PreviewSpecular2"); - - LLVector3 dir0 = gSavedSettings.getVector3("PreviewDirection0"); - LLVector3 dir1 = gSavedSettings.getVector3("PreviewDirection1"); - LLVector3 dir2 = gSavedSettings.getVector3("PreviewDirection2"); - - dir0.normVec(); - dir1.normVec(); - dir2.normVec(); - - LLVector4 light_pos(dir0, 0.0f); - - LLLightState* light = gGL.getLight(0); - - light->enable(); - light->setPosition(light_pos); - light->setDiffuse(diffuse0); - light->setAmbient(LLColor4::black); - light->setSpecular(specular0); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - - light_pos = LLVector4(dir1, 0.f); - - light = gGL.getLight(1); - light->enable(); - light->setPosition(light_pos); - light->setDiffuse(diffuse1); - light->setAmbient(LLColor4::black); - light->setSpecular(specular1); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); - - light_pos = LLVector4(dir2, 0.f); - light = gGL.getLight(2); - light->enable(); - light->setPosition(light_pos); - light->setDiffuse(diffuse2); - light->setAmbient(LLColor4::black); - light->setSpecular(specular2); - light->setSpotExponent(0.f); - light->setSpotCutoff(180.f); -} - - -void LLPipeline::enableLightsAvatarEdit(const LLColor4& color) -{ - U32 mask = 0x2002; // Avatar backlight only, set ambient - setupAvatarLights(TRUE); - enableLights(mask); - - glLightModelfv(GL_LIGHT_MODEL_AMBIENT,color.mV); -} - -void LLPipeline::enableLightsFullbright(const LLColor4& color) -{ - assertInitialized(); - U32 mask = 0x1000; // Non-0 mask, set ambient - enableLights(mask); - - glLightModelfv(GL_LIGHT_MODEL_AMBIENT,color.mV); -} - -void LLPipeline::disableLights() -{ - enableLights(0); // no lighting (full bright) -} - -//============================================================================ - -class LLMenuItemGL; -class LLInvFVBridge; -struct cat_folder_pair; -class LLVOBranch; -class LLVOLeaf; - -void LLPipeline::findReferences(LLDrawable *drawablep) -{ - assertInitialized(); - if (mLights.find(drawablep) != mLights.end()) - { - llinfos << "In mLights" << llendl; - } - if (std::find(mMovedList.begin(), mMovedList.end(), drawablep) != mMovedList.end()) - { - llinfos << "In mMovedList" << llendl; - } - if (std::find(mShiftList.begin(), mShiftList.end(), drawablep) != mShiftList.end()) - { - llinfos << "In mShiftList" << llendl; - } - if (mRetexturedList.find(drawablep) != mRetexturedList.end()) - { - llinfos << "In mRetexturedList" << llendl; - } - - if (std::find(mBuildQ1.begin(), mBuildQ1.end(), drawablep) != mBuildQ1.end()) - { - llinfos << "In mBuildQ1" << llendl; - } - if (std::find(mBuildQ2.begin(), mBuildQ2.end(), drawablep) != mBuildQ2.end()) - { - llinfos << "In mBuildQ2" << llendl; - } - - S32 count; - - count = gObjectList.findReferences(drawablep); - if (count) - { - llinfos << "In other drawables: " << count << " references" << llendl; - } -} - -BOOL LLPipeline::verify() -{ - BOOL ok = assertInitialized(); - if (ok) - { - for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter) - { - LLDrawPool *poolp = *iter; - if (!poolp->verify()) - { - ok = FALSE; - } - } - } - - if (!ok) - { - llwarns << "Pipeline verify failed!" << llendl; - } - return ok; -} - -////////////////////////////// -// -// Collision detection -// -// - -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/** - * A method to compute a ray-AABB intersection. - * Original code by Andrew Woo, from "Graphics Gems", Academic Press, 1990 - * Optimized code by Pierre Terdiman, 2000 (~20-30% faster on my Celeron 500) - * Epsilon value added by Klaus Hartmann. (discarding it saves a few cycles only) - * - * Hence this version is faster as well as more robust than the original one. - * - * Should work provided: - * 1) the integer representation of 0.0f is 0x00000000 - * 2) the sign bit of the float is the most significant one - * - * Report bugs: p.terdiman@codercorner.com - * - * \param aabb [in] the axis-aligned bounding box - * \param origin [in] ray origin - * \param dir [in] ray direction - * \param coord [out] impact coordinates - * \return true if ray intersects AABB - */ -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -//#define RAYAABB_EPSILON 0.00001f -#define IR(x) ((U32&)x) - -bool LLRayAABB(const LLVector3 ¢er, const LLVector3 &size, const LLVector3& origin, const LLVector3& dir, LLVector3 &coord, F32 epsilon) -{ - BOOL Inside = TRUE; - LLVector3 MinB = center - size; - LLVector3 MaxB = center + size; - LLVector3 MaxT; - MaxT.mV[VX]=MaxT.mV[VY]=MaxT.mV[VZ]=-1.0f; - - // Find candidate planes. - for(U32 i=0;i<3;i++) - { - if(origin.mV[i] < MinB.mV[i]) - { - coord.mV[i] = MinB.mV[i]; - Inside = FALSE; - - // Calculate T distances to candidate planes - if(IR(dir.mV[i])) MaxT.mV[i] = (MinB.mV[i] - origin.mV[i]) / dir.mV[i]; - } - else if(origin.mV[i] > MaxB.mV[i]) - { - coord.mV[i] = MaxB.mV[i]; - Inside = FALSE; - - // Calculate T distances to candidate planes - if(IR(dir.mV[i])) MaxT.mV[i] = (MaxB.mV[i] - origin.mV[i]) / dir.mV[i]; - } - } - - // Ray origin inside bounding box - if(Inside) - { - coord = origin; - return true; - } - - // Get largest of the maxT's for final choice of intersection - U32 WhichPlane = 0; - if(MaxT.mV[1] > MaxT.mV[WhichPlane]) WhichPlane = 1; - if(MaxT.mV[2] > MaxT.mV[WhichPlane]) WhichPlane = 2; - - // Check final candidate actually inside box - if(IR(MaxT.mV[WhichPlane])&0x80000000) return false; - - for(U32 i=0;i<3;i++) - { - if(i!=WhichPlane) - { - coord.mV[i] = origin.mV[i] + MaxT.mV[WhichPlane] * dir.mV[i]; - if (epsilon > 0) - { - if(coord.mV[i] < MinB.mV[i] - epsilon || coord.mV[i] > MaxB.mV[i] + epsilon) return false; - } - else - { - if(coord.mV[i] < MinB.mV[i] || coord.mV[i] > MaxB.mV[i]) return false; - } - } - } - return true; // ray hits box -} - -////////////////////////////// -// -// Macros, functions, and inline methods from other classes -// -// - -void LLPipeline::setLight(LLDrawable *drawablep, BOOL is_light) -{ - if (drawablep && assertInitialized()) - { - if (is_light) - { - mLights.insert(drawablep); - drawablep->setState(LLDrawable::LIGHT); - } - else - { - drawablep->clearState(LLDrawable::LIGHT); - mLights.erase(drawablep); - } - } -} - -//static -void LLPipeline::toggleRenderType(U32 type) -{ - gPipeline.mRenderTypeEnabled[type] = !gPipeline.mRenderTypeEnabled[type]; - if (type == LLPipeline::RENDER_TYPE_WATER) - { - gPipeline.mRenderTypeEnabled[LLPipeline::RENDER_TYPE_VOIDWATER] = !gPipeline.mRenderTypeEnabled[LLPipeline::RENDER_TYPE_VOIDWATER]; - } -} - -//static -void LLPipeline::toggleRenderTypeControl(void* data) -{ - U32 type = (U32)(intptr_t)data; - U32 bit = (1<<type); - if (gPipeline.hasRenderType(type)) - { - llinfos << "Toggling render type mask " << std::hex << bit << " off" << std::dec << llendl; - } - else - { - llinfos << "Toggling render type mask " << std::hex << bit << " on" << std::dec << llendl; - } - gPipeline.toggleRenderType(type); -} - -//static -BOOL LLPipeline::hasRenderTypeControl(void* data) -{ - U32 type = (U32)(intptr_t)data; - return gPipeline.hasRenderType(type); -} - -// Allows UI items labeled "Hide foo" instead of "Show foo" -//static -BOOL LLPipeline::toggleRenderTypeControlNegated(void* data) -{ - S32 type = (S32)(intptr_t)data; - return !gPipeline.hasRenderType(type); -} - -//static -void LLPipeline::toggleRenderDebug(void* data) -{ - U32 bit = (U32)(intptr_t)data; - if (gPipeline.hasRenderDebugMask(bit)) - { - llinfos << "Toggling render debug mask " << std::hex << bit << " off" << std::dec << llendl; - } - else - { - llinfos << "Toggling render debug mask " << std::hex << bit << " on" << std::dec << llendl; - } - gPipeline.mRenderDebugMask ^= bit; -} - - -//static -BOOL LLPipeline::toggleRenderDebugControl(void* data) -{ - U32 bit = (U32)(intptr_t)data; - return gPipeline.hasRenderDebugMask(bit); -} - -//static -void LLPipeline::toggleRenderDebugFeature(void* data) -{ - U32 bit = (U32)(intptr_t)data; - gPipeline.mRenderDebugFeatureMask ^= bit; -} - - -//static -BOOL LLPipeline::toggleRenderDebugFeatureControl(void* data) -{ - U32 bit = (U32)(intptr_t)data; - return gPipeline.hasRenderDebugFeatureMask(bit); -} - -void LLPipeline::setRenderDebugFeatureControl(U32 bit, bool value) -{ - if (value) - { - gPipeline.mRenderDebugFeatureMask |= bit; - } - else - { - gPipeline.mRenderDebugFeatureMask &= !bit; - } -} - -// static -void LLPipeline::setRenderScriptedBeacons(BOOL val) -{ - sRenderScriptedBeacons = val; -} - -// static -void LLPipeline::toggleRenderScriptedBeacons(void*) -{ - sRenderScriptedBeacons = !sRenderScriptedBeacons; -} - -// static -BOOL LLPipeline::getRenderScriptedBeacons(void*) -{ - return sRenderScriptedBeacons; -} - -// static -void LLPipeline::setRenderScriptedTouchBeacons(BOOL val) -{ - sRenderScriptedTouchBeacons = val; -} - -// static -void LLPipeline::toggleRenderScriptedTouchBeacons(void*) -{ - sRenderScriptedTouchBeacons = !sRenderScriptedTouchBeacons; -} - -// static -BOOL LLPipeline::getRenderScriptedTouchBeacons(void*) -{ - return sRenderScriptedTouchBeacons; -} - -// static -void LLPipeline::setRenderPhysicalBeacons(BOOL val) -{ - sRenderPhysicalBeacons = val; -} - -// static -void LLPipeline::toggleRenderPhysicalBeacons(void*) -{ - sRenderPhysicalBeacons = !sRenderPhysicalBeacons; -} - -// static -BOOL LLPipeline::getRenderPhysicalBeacons(void*) -{ - return sRenderPhysicalBeacons; -} - -// static -void LLPipeline::setRenderParticleBeacons(BOOL val) -{ - sRenderParticleBeacons = val; -} - -// static -void LLPipeline::toggleRenderParticleBeacons(void*) -{ - sRenderParticleBeacons = !sRenderParticleBeacons; -} - -// static -BOOL LLPipeline::getRenderParticleBeacons(void*) -{ - return sRenderParticleBeacons; -} - -// static -void LLPipeline::setRenderSoundBeacons(BOOL val) -{ - sRenderSoundBeacons = val; -} - -// static -void LLPipeline::toggleRenderSoundBeacons(void*) -{ - sRenderSoundBeacons = !sRenderSoundBeacons; -} - -// static -BOOL LLPipeline::getRenderSoundBeacons(void*) -{ - return sRenderSoundBeacons; -} - -// static -void LLPipeline::setRenderBeacons(BOOL val) -{ - sRenderBeacons = val; -} - -// static -void LLPipeline::toggleRenderBeacons(void*) -{ - sRenderBeacons = !sRenderBeacons; -} - -// static -BOOL LLPipeline::getRenderBeacons(void*) -{ - return sRenderBeacons; -} - -// static -void LLPipeline::setRenderHighlights(BOOL val) -{ - sRenderHighlight = val; -} - -// static -void LLPipeline::toggleRenderHighlights(void*) -{ - sRenderHighlight = !sRenderHighlight; -} - -// static -BOOL LLPipeline::getRenderHighlights(void*) -{ - return sRenderHighlight; -} - -LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector3& start, const LLVector3& end, - BOOL pick_transparent, - S32* face_hit, - LLVector3* intersection, // return the intersection point - LLVector2* tex_coord, // return the texture coordinates of the intersection point - LLVector3* normal, // return the surface normal at the intersection point - LLVector3* bi_normal // return the surface bi-normal at the intersection point - ) -{ - LLDrawable* drawable = NULL; - - LLVector3 local_end = end; - - LLVector3 position; - - sPickAvatar = FALSE; //LLToolMgr::getInstance()->inBuildMode() ? FALSE : TRUE; - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - - for (U32 j = 0; j < LLViewerRegion::NUM_PARTITIONS; j++) - { - if ((j == LLViewerRegion::PARTITION_VOLUME) || - (j == LLViewerRegion::PARTITION_BRIDGE) || - (j == LLViewerRegion::PARTITION_TERRAIN) || - (j == LLViewerRegion::PARTITION_TREE) || - (j == LLViewerRegion::PARTITION_GRASS)) // only check these partitions for now - { - LLSpatialPartition* part = region->getSpatialPartition(j); - if (part && hasRenderType(part->mDrawableType)) - { - LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, bi_normal); - if (hit) - { - drawable = hit; - local_end = position; - } - } - } - } - } - - if (!sPickAvatar) - { - //save hit info in case we need to restore - //due to attachment override - LLVector3 local_normal; - LLVector3 local_binormal; - LLVector2 local_texcoord; - S32 local_face_hit = -1; - - if (face_hit) - { - local_face_hit = *face_hit; - } - if (tex_coord) - { - local_texcoord = *tex_coord; - } - if (bi_normal) - { - local_binormal = *bi_normal; - } - if (normal) - { - local_normal = *normal; - } - - const F32 ATTACHMENT_OVERRIDE_DIST = 0.1f; - - //check against avatars - sPickAvatar = TRUE; - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - - LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_BRIDGE); - if (part && hasRenderType(part->mDrawableType)) - { - LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, bi_normal); - if (hit) - { - if (!drawable || - !drawable->getVObj()->isAttachment() || - (position-local_end).magVec() > ATTACHMENT_OVERRIDE_DIST) - { //avatar overrides if previously hit drawable is not an attachment or - //attachment is far enough away from detected intersection - drawable = hit; - local_end = position; - } - else - { //prioritize attachments over avatars - position = local_end; - - if (face_hit) - { - *face_hit = local_face_hit; - } - if (tex_coord) - { - *tex_coord = local_texcoord; - } - if (bi_normal) - { - *bi_normal = local_binormal; - } - if (normal) - { - *normal = local_normal; - } - } - } - } - } - } - - //check all avatar nametags (silly, isn't it?) - for (std::vector< LLCharacter* >::iterator iter = LLCharacter::sInstances.begin(); - iter != LLCharacter::sInstances.end(); - ++iter) - { - LLVOAvatar* av = (LLVOAvatar*) *iter; - if (av->mNameText.notNull() - && av->mNameText->lineSegmentIntersect(start, local_end, position)) - { - drawable = av->mDrawable; - local_end = position; - } - } - - if (intersection) - { - *intersection = position; - } - - return drawable ? drawable->getVObj().get() : NULL; -} - -LLViewerObject* LLPipeline::lineSegmentIntersectInHUD(const LLVector3& start, const LLVector3& end, - BOOL pick_transparent, - S32* face_hit, - LLVector3* intersection, // return the intersection point - LLVector2* tex_coord, // return the texture coordinates of the intersection point - LLVector3* normal, // return the surface normal at the intersection point - LLVector3* bi_normal // return the surface bi-normal at the intersection point - ) -{ - LLDrawable* drawable = NULL; - - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - - BOOL toggle = FALSE; - if (!hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - toggleRenderType(LLPipeline::RENDER_TYPE_HUD); - toggle = TRUE; - } - - LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_HUD); - if (part) - { - LLDrawable* hit = part->lineSegmentIntersect(start, end, pick_transparent, face_hit, intersection, tex_coord, normal, bi_normal); - if (hit) - { - drawable = hit; - } - } - - if (toggle) - { - toggleRenderType(LLPipeline::RENDER_TYPE_HUD); - } - } - return drawable ? drawable->getVObj().get() : NULL; -} - -LLSpatialPartition* LLPipeline::getSpatialPartition(LLViewerObject* vobj) -{ - if (vobj) - { - LLViewerRegion* region = vobj->getRegion(); - if (region) - { - return region->getSpatialPartition(vobj->getPartitionType()); - } - } - return NULL; -} - - -void LLPipeline::resetVertexBuffers(LLDrawable* drawable) -{ - if (!drawable || drawable->isDead()) - { - return; - } - - for (S32 i = 0; i < drawable->getNumFaces(); i++) - { - LLFace* facep = drawable->getFace(i); - facep->clearVertexBuffer(); - } -} - -void LLPipeline::resetVertexBuffers() -{ - for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin(); - iter != LLWorld::getInstance()->getRegionList().end(); ++iter) - { - LLViewerRegion* region = *iter; - for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++) - { - LLSpatialPartition* part = region->getSpatialPartition(i); - if (part) - { - part->resetVertexBuffers(); - } - } - } - - resetDrawOrders(); - - gSky.resetVertexBuffers(); - - if (LLVertexBuffer::sGLCount > 0) - { - LLVertexBuffer::cleanupClass(); - } - - //delete all name pool caches - LLGLNamePool::cleanupPools(); - - if (LLVertexBuffer::sGLCount > 0) - { - llwarns << "VBO wipe failed." << llendl; - } - - if (!LLVertexBuffer::sStreamIBOPool.mNameList.empty() || - !LLVertexBuffer::sStreamVBOPool.mNameList.empty() || - !LLVertexBuffer::sDynamicIBOPool.mNameList.empty() || - !LLVertexBuffer::sDynamicVBOPool.mNameList.empty()) - { - llwarns << "VBO name pool cleanup failed." << llendl; - } - - LLVertexBuffer::unbind(); - - sRenderBump = gSavedSettings.getBOOL("RenderObjectBump"); - sUseTriStrips = gSavedSettings.getBOOL("RenderUseTriStrips"); - LLVertexBuffer::sUseStreamDraw = gSavedSettings.getBOOL("RenderUseStreamVBO"); - LLVertexBuffer::sPreferStreamDraw = gSavedSettings.getBOOL("RenderPreferStreamDraw"); - LLVertexBuffer::sEnableVBOs = gSavedSettings.getBOOL("RenderVBOEnable"); - LLVertexBuffer::sDisableVBOMapping = LLVertexBuffer::sEnableVBOs && gSavedSettings.getBOOL("RenderVBOMappingDisable") ; - sBakeSunlight = gSavedSettings.getBOOL("RenderBakeSunlight"); - sNoAlpha = gSavedSettings.getBOOL("RenderNoAlpha"); - LLPipeline::sTextureBindTest = gSavedSettings.getBOOL("RenderDebugTextureBind"); -} - -void LLPipeline::renderObjects(U32 type, U32 mask, BOOL texture) -{ - LLMemType mt_ro(LLMemType::MTYPE_PIPELINE_RENDER_OBJECTS); - assertInitialized(); - glLoadMatrixd(gGLModelView); - gGLLastMatrix = NULL; - mSimplePool->pushBatches(type, mask); - glLoadMatrixd(gGLModelView); - gGLLastMatrix = NULL; -} - -void apply_cube_face_rotation(U32 face) -{ - switch (face) - { - case 0: - glRotatef(90.f, 0, 1, 0); - glRotatef(180.f, 1, 0, 0); - break; - case 2: - glRotatef(-90.f, 1, 0, 0); - break; - case 4: - glRotatef(180.f, 0, 1, 0); - glRotatef(180.f, 0, 0, 1); - break; - case 1: - glRotatef(-90.f, 0, 1, 0); - glRotatef(180.f, 1, 0, 0); - break; - case 3: - glRotatef(90, 1, 0, 0); - break; - case 5: - glRotatef(180, 0, 0, 1); - break; - } -} - -void validate_framebuffer_object() -{ - GLenum status; - status = glCheckFramebufferStatus(GL_FRAMEBUFFER_EXT); - switch(status) - { - case GL_FRAMEBUFFER_COMPLETE: - //framebuffer OK, no error. - break; - case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: - // frame buffer not OK: probably means unsupported depth buffer format - llerrs << "Framebuffer Incomplete Missing Attachment." << llendl; - break; - case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT: - // frame buffer not OK: probably means unsupported depth buffer format - llerrs << "Framebuffer Incomplete Attachment." << llendl; - break; - case GL_FRAMEBUFFER_UNSUPPORTED: - /* choose different formats */ - llerrs << "Framebuffer unsupported." << llendl; - break; - default: - llerrs << "Unknown framebuffer status." << llendl; - break; - } -} - -void LLPipeline::bindScreenToTexture() -{ - -} - -static LLFastTimer::DeclareTimer FTM_RENDER_BLOOM("Bloom"); - -void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield) -{ - LLMemType mt_ru(LLMemType::MTYPE_PIPELINE_RENDER_BLOOM); - if (!(gPipeline.canUseVertexShaders() && - sRenderGlow)) - { - return; - } - - LLVertexBuffer::unbind(); - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - - assertInitialized(); - - if (gUseWireframe) - { - glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - } - - U32 res_mod = gSavedSettings.getU32("RenderResolutionDivisor"); - - LLVector2 tc1(0,0); - LLVector2 tc2((F32) gViewerWindow->getWorldViewWidthRaw()*2, - (F32) gViewerWindow->getWorldViewHeightRaw()*2); - - if (res_mod > 1) - { - tc2 /= (F32) res_mod; - } - - LLFastTimer ftm(FTM_RENDER_BLOOM); - gGL.color4f(1,1,1,1); - LLGLDepthTest depth(GL_FALSE); - LLGLDisable blend(GL_BLEND); - LLGLDisable cull(GL_CULL_FACE); - - enableLightsFullbright(LLColor4(1,1,1,1)); - - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_MODELVIEW); - glPushMatrix(); - glLoadIdentity(); - - LLGLDisable test(GL_ALPHA_TEST); - - gGL.setColorMask(true, true); - glClearColor(0,0,0,0); - - /*if (for_snapshot) - { - gGL.getTexUnit(0)->bind(&mGlow[1]); - { - //LLGLEnable stencil(GL_STENCIL_TEST); - //glStencilFunc(GL_NOTEQUAL, 255, 0xFFFFFFFF); - //glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - //LLGLDisable blend(GL_BLEND); - - // If the snapshot is constructed from tiles, calculate which - // tile we're in. - - //from LLViewerCamera::setPerpsective - if (zoom_factor > 1.f) - { - int pos_y = subfield / llceil(zoom_factor); - int pos_x = subfield - (pos_y*llceil(zoom_factor)); - F32 size = 1.f/zoom_factor; - - tc1.set(pos_x*size, pos_y*size); - tc2 = tc1 + LLVector2(size,size); - } - else - { - tc2.set(1,1); - } - - LLGLEnable blend(GL_BLEND); - gGL.setSceneBlendType(LLRender::BT_ADD); - - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.color4f(1,1,1,1); - gGL.texCoord2f(tc1.mV[0], tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc1.mV[0], tc2.mV[1]); - gGL.vertex2f(-1,1); - - gGL.texCoord2f(tc2.mV[0], tc1.mV[1]); - gGL.vertex2f(1,-1); - - gGL.texCoord2f(tc2.mV[0], tc2.mV[1]); - gGL.vertex2f(1,1); - - gGL.end(); - - gGL.flush(); - gGL.setSceneBlendType(LLRender::BT_ALPHA); - } - - gGL.flush(); - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - - return; - }*/ - - { - { - LLFastTimer ftm(FTM_RENDER_BLOOM_FBO); - mGlow[2].bindTarget(); - mGlow[2].clear(); - } - - gGlowExtractProgram.bind(); - F32 minLum = llmax(gSavedSettings.getF32("RenderGlowMinLuminance"), 0.0f); - F32 maxAlpha = gSavedSettings.getF32("RenderGlowMaxExtractAlpha"); - F32 warmthAmount = gSavedSettings.getF32("RenderGlowWarmthAmount"); - LLVector3 lumWeights = gSavedSettings.getVector3("RenderGlowLumWeights"); - LLVector3 warmthWeights = gSavedSettings.getVector3("RenderGlowWarmthWeights"); - gGlowExtractProgram.uniform1f("minLuminance", minLum); - gGlowExtractProgram.uniform1f("maxExtractAlpha", maxAlpha); - gGlowExtractProgram.uniform3f("lumWeights", lumWeights.mV[0], lumWeights.mV[1], lumWeights.mV[2]); - gGlowExtractProgram.uniform3f("warmthWeights", warmthWeights.mV[0], warmthWeights.mV[1], warmthWeights.mV[2]); - gGlowExtractProgram.uniform1f("warmthAmount", warmthAmount); - LLGLEnable blend_on(GL_BLEND); - LLGLEnable test(GL_ALPHA_TEST); - gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT); - gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA); - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - gGL.getTexUnit(0)->disable(); - gGL.getTexUnit(0)->enable(LLTexUnit::TT_RECT_TEXTURE); - gGL.getTexUnit(0)->bind(&mScreen); - - gGL.color4f(1,1,1,1); - gPipeline.enableLightsFullbright(LLColor4(1,1,1,1)); - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.texCoord2f(tc1.mV[0], tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc1.mV[0], tc2.mV[1]); - gGL.vertex2f(-1,3); - - gGL.texCoord2f(tc2.mV[0], tc1.mV[1]); - gGL.vertex2f(3,-1); - - gGL.end(); - - gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE); - - mGlow[2].flush(); - } - - tc1.setVec(0,0); - tc2.setVec(2,2); - - // power of two between 1 and 1024 - U32 glowResPow = gSavedSettings.getS32("RenderGlowResolutionPow"); - const U32 glow_res = llmax(1, - llmin(1024, 1 << glowResPow)); - - S32 kernel = gSavedSettings.getS32("RenderGlowIterations")*2; - F32 delta = gSavedSettings.getF32("RenderGlowWidth") / glow_res; - // Use half the glow width if we have the res set to less than 9 so that it looks - // almost the same in either case. - if (glowResPow < 9) - { - delta *= 0.5f; - } - F32 strength = gSavedSettings.getF32("RenderGlowStrength"); - - gGlowProgram.bind(); - gGlowProgram.uniform1f("glowStrength", strength); - - for (S32 i = 0; i < kernel; i++) - { - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - { - LLFastTimer ftm(FTM_RENDER_BLOOM_FBO); - mGlow[i%2].bindTarget(); - mGlow[i%2].clear(); - } - - if (i == 0) - { - gGL.getTexUnit(0)->bind(&mGlow[2]); - } - else - { - gGL.getTexUnit(0)->bind(&mGlow[(i-1)%2]); - } - - if (i%2 == 0) - { - gGlowProgram.uniform2f("glowDelta", delta, 0); - } - else - { - gGlowProgram.uniform2f("glowDelta", 0, delta); - } - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.texCoord2f(tc1.mV[0], tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc1.mV[0], tc2.mV[1]); - gGL.vertex2f(-1,3); - - gGL.texCoord2f(tc2.mV[0], tc1.mV[1]); - gGL.vertex2f(3,-1); - - gGL.end(); - - mGlow[i%2].flush(); - } - - gGlowProgram.unbind(); - - if (LLRenderTarget::sUseFBO) - { - LLFastTimer ftm(FTM_RENDER_BLOOM_FBO); - glBindFramebuffer(GL_FRAMEBUFFER, 0); - } - - gGLViewport[0] = gViewerWindow->getWorldViewRectRaw().mLeft; - gGLViewport[1] = gViewerWindow->getWorldViewRectRaw().mBottom; - gGLViewport[2] = gViewerWindow->getWorldViewRectRaw().getWidth(); - gGLViewport[3] = gViewerWindow->getWorldViewRectRaw().getHeight(); - glViewport(gGLViewport[0], gGLViewport[1], gGLViewport[2], gGLViewport[3]); - - tc2.setVec((F32) gViewerWindow->getWorldViewWidthRaw(), - (F32) gViewerWindow->getWorldViewHeightRaw()); - - gGL.flush(); - - LLVertexBuffer::unbind(); - - if (LLPipeline::sRenderDeferred && !LLViewerCamera::getInstance()->cameraUnderWater()) - { - LLGLSLShader* shader = &gDeferredPostProgram; - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2) - { - shader = &gDeferredGIFinalProgram; - } - - LLGLDisable blend(GL_BLEND); - bindDeferredShader(*shader); - - //depth of field focal plane calculations - - static F32 current_distance = 16.f; - static F32 start_distance = 16.f; - static F32 transition_time = 1.f; - - LLVector3 focus_point; - - LLViewerObject* obj = LLViewerMediaFocus::getInstance()->getFocusedObject(); - if (obj && obj->mDrawable && obj->isSelected()) - { - S32 face_idx = LLViewerMediaFocus::getInstance()->getFocusedFace(); - if (obj && obj->mDrawable) - { - LLFace* face = obj->mDrawable->getFace(face_idx); - if (face) - { - focus_point = face->getPositionAgent(); - } - } - } +/**
+ * @file pipeline.cpp
+ * @brief Rendering pipeline.
+ *
+ * $LicenseInfo:firstyear=2005&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 "pipeline.h"
+
+// library includes
+#include "llaudioengine.h" // For debugging.
+#include "imageids.h"
+#include "llerror.h"
+#include "llviewercontrol.h"
+#include "llfasttimer.h"
+#include "llfontgl.h"
+#include "llmemtype.h"
+#include "llnamevalue.h"
+#include "llpointer.h"
+#include "llprimitive.h"
+#include "llvolume.h"
+#include "material_codes.h"
+#include "timing.h"
+#include "v3color.h"
+#include "llui.h"
+#include "llglheaders.h"
+#include "llrender.h"
+#include "llwindow.h" // swapBuffers()
+
+// newview includes
+#include "llagent.h"
+#include "llagentcamera.h"
+#include "lldrawable.h"
+#include "lldrawpoolalpha.h"
+#include "lldrawpoolavatar.h"
+#include "lldrawpoolground.h"
+#include "lldrawpoolbump.h"
+#include "lldrawpooltree.h"
+#include "lldrawpoolwater.h"
+#include "llface.h"
+#include "llfeaturemanager.h"
+#include "llfloatertelehub.h"
+#include "llfloaterreg.h"
+#include "llgldbg.h"
+#include "llhudmanager.h"
+#include "llhudnametag.h"
+#include "llhudtext.h"
+#include "lllightconstants.h"
+#include "llmeshrepository.h"
+#include "llresmgr.h"
+#include "llselectmgr.h"
+#include "llsky.h"
+#include "lltracker.h"
+#include "lltool.h"
+#include "lltoolmgr.h"
+#include "llviewercamera.h"
+#include "llviewermediafocus.h"
+#include "llviewertexturelist.h"
+#include "llviewerobject.h"
+#include "llviewerobjectlist.h"
+#include "llviewerparcelmgr.h"
+#include "llviewerregion.h" // for audio debugging.
+#include "llviewerwindow.h" // For getSpinAxis
+#include "llvoavatarself.h"
+#include "llvoground.h"
+#include "llvosky.h"
+#include "llvotree.h"
+#include "llvovolume.h"
+#include "llvosurfacepatch.h"
+#include "llvowater.h"
+#include "llvotree.h"
+#include "llvopartgroup.h"
+#include "llworld.h"
+#include "llcubemap.h"
+#include "llviewershadermgr.h"
+#include "llviewerstats.h"
+#include "llviewerjoystick.h"
+#include "llviewerdisplay.h"
+#include "llwlparammanager.h"
+#include "llwaterparammanager.h"
+#include "llspatialpartition.h"
+#include "llmutelist.h"
+#include "lltoolpie.h"
+#include "llcurl.h"
+
+
+void check_stack_depth(S32 stack_depth)
+{
+ if (gDebugGL || gDebugSession)
+ {
+ GLint depth;
+ glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth);
+ if (depth != stack_depth)
+ {
+ if (gDebugSession)
+ {
+ ll_fail("GL matrix stack corrupted.");
+ }
+ else
+ {
+ llerrs << "GL matrix stack corrupted!" << llendl;
+ }
+ }
+ }
+}
+
+#ifdef _DEBUG
+// Debug indices is disabled for now for debug performance - djs 4/24/02
+//#define DEBUG_INDICES
+#else
+//#define DEBUG_INDICES
+#endif
+
+const F32 BACKLIGHT_DAY_MAGNITUDE_AVATAR = 0.2f;
+const F32 BACKLIGHT_NIGHT_MAGNITUDE_AVATAR = 0.1f;
+const F32 BACKLIGHT_DAY_MAGNITUDE_OBJECT = 0.1f;
+const F32 BACKLIGHT_NIGHT_MAGNITUDE_OBJECT = 0.08f;
+const S32 MAX_OFFSCREEN_GEOMETRY_CHANGES_PER_FRAME = 10;
+const U32 REFLECTION_MAP_RES = 128;
+
+// Max number of occluders to search for. JC
+const S32 MAX_OCCLUDER_COUNT = 2;
+
+extern S32 gBoxFrame;
+//extern BOOL gHideSelectedObjects;
+extern BOOL gDisplaySwapBuffers;
+extern BOOL gDebugGL;
+
+// hack counter for rendering a fixed number of frames after toggling
+// fullscreen to work around DEV-5361
+static S32 sDelayedVBOEnable = 0;
+
+BOOL gAvatarBacklight = FALSE;
+
+BOOL gDebugPipeline = FALSE;
+LLPipeline gPipeline;
+const LLMatrix4* gGLLastMatrix = NULL;
+
+LLFastTimer::DeclareTimer FTM_RENDER_GEOMETRY("Geometry");
+LLFastTimer::DeclareTimer FTM_RENDER_GRASS("Grass");
+LLFastTimer::DeclareTimer FTM_RENDER_INVISIBLE("Invisible");
+LLFastTimer::DeclareTimer FTM_RENDER_OCCLUSION("Occlusion");
+LLFastTimer::DeclareTimer FTM_RENDER_SHINY("Shiny");
+LLFastTimer::DeclareTimer FTM_RENDER_SIMPLE("Simple");
+LLFastTimer::DeclareTimer FTM_RENDER_TERRAIN("Terrain");
+LLFastTimer::DeclareTimer FTM_RENDER_TREES("Trees");
+LLFastTimer::DeclareTimer FTM_RENDER_UI("UI");
+LLFastTimer::DeclareTimer FTM_RENDER_WATER("Water");
+LLFastTimer::DeclareTimer FTM_RENDER_WL_SKY("Windlight Sky");
+LLFastTimer::DeclareTimer FTM_RENDER_ALPHA("Alpha Objects");
+LLFastTimer::DeclareTimer FTM_RENDER_CHARACTERS("Avatars");
+LLFastTimer::DeclareTimer FTM_RENDER_BUMP("Bump");
+LLFastTimer::DeclareTimer FTM_RENDER_FULLBRIGHT("Fullbright");
+LLFastTimer::DeclareTimer FTM_RENDER_GLOW("Glow");
+LLFastTimer::DeclareTimer FTM_GEO_UPDATE("Geo Update");
+LLFastTimer::DeclareTimer FTM_POOLRENDER("RenderPool");
+LLFastTimer::DeclareTimer FTM_POOLS("Pools");
+LLFastTimer::DeclareTimer FTM_RENDER_BLOOM_FBO("First FBO");
+LLFastTimer::DeclareTimer FTM_STATESORT("Sort Draw State");
+LLFastTimer::DeclareTimer FTM_PIPELINE("Pipeline");
+LLFastTimer::DeclareTimer FTM_CLIENT_COPY("Client Copy");
+LLFastTimer::DeclareTimer FTM_RENDER_DEFERRED("Deferred Shading");
+
+
+static LLFastTimer::DeclareTimer FTM_STATESORT_DRAWABLE("Sort Drawables");
+static LLFastTimer::DeclareTimer FTM_STATESORT_POSTSORT("Post Sort");
+
+//----------------------------------------
+std::string gPoolNames[] =
+{
+ // Correspond to LLDrawpool enum render type
+ "NONE",
+ "POOL_SIMPLE",
+ "POOL_GROUND",
+ "POOL_FULLBRIGHT",
+ "POOL_BUMP",
+ "POOL_TERRAIN,"
+ "POOL_SKY",
+ "POOL_WL_SKY",
+ "POOL_TREE",
+ "POOL_GRASS",
+ "POOL_INVISIBLE",
+ "POOL_AVATAR",
+ "POOL_VOIDWATER",
+ "POOL_WATER",
+ "POOL_GLOW",
+ "POOL_ALPHA"
+};
+
+void drawBox(const LLVector3& c, const LLVector3& r);
+void drawBoxOutline(const LLVector3& pos, const LLVector3& size);
+
+U32 nhpo2(U32 v)
+{
+ U32 r = 1;
+ while (r < v) {
+ r *= 2;
+ }
+ return r;
+}
+
+glh::matrix4f glh_copy_matrix(GLdouble* src)
+{
+ glh::matrix4f ret;
+ for (U32 i = 0; i < 16; i++)
+ {
+ ret.m[i] = (F32) src[i];
+ }
+ return ret;
+}
+
+glh::matrix4f glh_get_current_modelview()
+{
+ return glh_copy_matrix(gGLModelView);
+}
+
+glh::matrix4f glh_get_current_projection()
+{
+ return glh_copy_matrix(gGLProjection);
+}
+
+void glh_copy_matrix(const glh::matrix4f& src, GLdouble* dst)
+{
+ for (U32 i = 0; i < 16; i++)
+ {
+ dst[i] = src.m[i];
+ }
+}
+
+void glh_set_current_modelview(const glh::matrix4f& mat)
+{
+ glh_copy_matrix(mat, gGLModelView);
+}
+
+void glh_set_current_projection(glh::matrix4f& mat)
+{
+ glh_copy_matrix(mat, gGLProjection);
+}
+
+glh::matrix4f gl_ortho(GLfloat left, GLfloat right, GLfloat bottom, GLfloat top, GLfloat znear, GLfloat zfar)
+{
+ glh::matrix4f ret(
+ 2.f/(right-left), 0.f, 0.f, -(right+left)/(right-left),
+ 0.f, 2.f/(top-bottom), 0.f, -(top+bottom)/(top-bottom),
+ 0.f, 0.f, -2.f/(zfar-znear), -(zfar+znear)/(zfar-znear),
+ 0.f, 0.f, 0.f, 1.f);
+
+ return ret;
+}
+
+void display_update_camera();
+//----------------------------------------
+
+S32 LLPipeline::sCompiles = 0;
+
+BOOL LLPipeline::sPickAvatar = TRUE;
+BOOL LLPipeline::sDynamicLOD = TRUE;
+BOOL LLPipeline::sShowHUDAttachments = TRUE;
+BOOL LLPipeline::sRenderPhysicalBeacons = TRUE;
+BOOL LLPipeline::sRenderScriptedBeacons = FALSE;
+BOOL LLPipeline::sRenderScriptedTouchBeacons = TRUE;
+BOOL LLPipeline::sRenderParticleBeacons = FALSE;
+BOOL LLPipeline::sRenderSoundBeacons = FALSE;
+BOOL LLPipeline::sRenderBeacons = FALSE;
+BOOL LLPipeline::sRenderHighlight = TRUE;
+BOOL LLPipeline::sForceOldBakedUpload = FALSE;
+S32 LLPipeline::sUseOcclusion = 0;
+BOOL LLPipeline::sDelayVBUpdate = TRUE;
+BOOL LLPipeline::sAutoMaskAlphaDeferred = TRUE;
+BOOL LLPipeline::sAutoMaskAlphaNonDeferred = FALSE;
+BOOL LLPipeline::sDisableShaders = FALSE;
+BOOL LLPipeline::sRenderBump = TRUE;
+BOOL LLPipeline::sBakeSunlight = FALSE;
+BOOL LLPipeline::sNoAlpha = FALSE;
+BOOL LLPipeline::sUseTriStrips = TRUE;
+BOOL LLPipeline::sUseFarClip = TRUE;
+BOOL LLPipeline::sShadowRender = FALSE;
+BOOL LLPipeline::sWaterReflections = FALSE;
+BOOL LLPipeline::sRenderGlow = FALSE;
+BOOL LLPipeline::sReflectionRender = FALSE;
+BOOL LLPipeline::sImpostorRender = FALSE;
+BOOL LLPipeline::sUnderWaterRender = FALSE;
+BOOL LLPipeline::sTextureBindTest = FALSE;
+BOOL LLPipeline::sRenderFrameTest = FALSE;
+BOOL LLPipeline::sRenderAttachedLights = TRUE;
+BOOL LLPipeline::sRenderAttachedParticles = TRUE;
+BOOL LLPipeline::sRenderDeferred = FALSE;
+S32 LLPipeline::sVisibleLightCount = 0;
+F32 LLPipeline::sMinRenderSize = 0.f;
+
+
+static LLCullResult* sCull = NULL;
+
+static const U32 gl_cube_face[] =
+{
+ GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB,
+ GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB,
+ GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB,
+ GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB,
+ GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB,
+ GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB,
+};
+
+void validate_framebuffer_object();
+
+
+void addDeferredAttachments(LLRenderTarget& target)
+{
+ target.addColorAttachment(GL_RGBA); //specular
+ target.addColorAttachment(GL_RGBA); //normal+z
+}
+
+LLPipeline::LLPipeline() :
+ mBackfaceCull(FALSE),
+ mBatchCount(0),
+ mMatrixOpCount(0),
+ mTextureMatrixOps(0),
+ mMaxBatchSize(0),
+ mMinBatchSize(0),
+ mMeanBatchSize(0),
+ mTrianglesDrawn(0),
+ mNumVisibleNodes(0),
+ mVerticesRelit(0),
+ mLightingChanges(0),
+ mGeometryChanges(0),
+ mNumVisibleFaces(0),
+
+ mInitialized(FALSE),
+ mVertexShadersEnabled(FALSE),
+ mVertexShadersLoaded(0),
+ mRenderDebugFeatureMask(0),
+ mRenderDebugMask(0),
+ mOldRenderDebugMask(0),
+ mGroupQ1Locked(false),
+ mGroupQ2Locked(false),
+ mLastRebuildPool(NULL),
+ mAlphaPool(NULL),
+ mSkyPool(NULL),
+ mTerrainPool(NULL),
+ mWaterPool(NULL),
+ mGroundPool(NULL),
+ mSimplePool(NULL),
+ mFullbrightPool(NULL),
+ mInvisiblePool(NULL),
+ mGlowPool(NULL),
+ mBumpPool(NULL),
+ mWLSkyPool(NULL),
+ mLightMask(0),
+ mLightMovingMask(0),
+ mLightingDetail(0),
+ mScreenWidth(0),
+ mScreenHeight(0)
+{
+ mNoiseMap = 0;
+ mTrueNoiseMap = 0;
+ mLightFunc = 0;
+}
+
+void LLPipeline::init()
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_INIT);
+
+ sDynamicLOD = gSavedSettings.getBOOL("RenderDynamicLOD");
+ sRenderBump = gSavedSettings.getBOOL("RenderObjectBump");
+ sUseTriStrips = gSavedSettings.getBOOL("RenderUseTriStrips");
+ LLVertexBuffer::sUseStreamDraw = gSavedSettings.getBOOL("RenderUseStreamVBO");
+ LLVertexBuffer::sPreferStreamDraw = gSavedSettings.getBOOL("RenderPreferStreamDraw");
+ sRenderAttachedLights = gSavedSettings.getBOOL("RenderAttachedLights");
+ sRenderAttachedParticles = gSavedSettings.getBOOL("RenderAttachedParticles");
+
+ mInitialized = TRUE;
+
+ stop_glerror();
+
+ //create render pass pools
+ getPool(LLDrawPool::POOL_ALPHA);
+ getPool(LLDrawPool::POOL_SIMPLE);
+ getPool(LLDrawPool::POOL_GRASS);
+ getPool(LLDrawPool::POOL_FULLBRIGHT);
+ getPool(LLDrawPool::POOL_INVISIBLE);
+ getPool(LLDrawPool::POOL_BUMP);
+ getPool(LLDrawPool::POOL_GLOW);
+
+ LLViewerStats::getInstance()->mTrianglesDrawnStat.reset();
+ resetFrameStats();
+
+ for (U32 i = 0; i < NUM_RENDER_TYPES; ++i)
+ {
+ mRenderTypeEnabled[i] = TRUE; //all rendering types start enabled
+ }
+
+ mRenderDebugFeatureMask = 0xffffffff; // All debugging features on
+ mRenderDebugMask = 0; // All debug starts off
+
+ // Don't turn on ground when this is set
+ // Mac Books with intel 950s need this
+ if(!gSavedSettings.getBOOL("RenderGround"))
+ {
+ toggleRenderType(RENDER_TYPE_GROUND);
+ }
+
+ // make sure RenderPerformanceTest persists (hackity hack hack)
+ // disables non-object rendering (UI, sky, water, etc)
+ if (gSavedSettings.getBOOL("RenderPerformanceTest"))
+ {
+ gSavedSettings.setBOOL("RenderPerformanceTest", FALSE);
+ gSavedSettings.setBOOL("RenderPerformanceTest", TRUE);
+ }
+
+ mOldRenderDebugMask = mRenderDebugMask;
+
+ mBackfaceCull = TRUE;
+
+ stop_glerror();
+
+ // Enable features
+
+ LLViewerShaderMgr::instance()->setShaders();
+
+ stop_glerror();
+
+ for (U32 i = 0; i < 2; ++i)
+ {
+ mSpotLightFade[i] = 1.f;
+ }
+
+ setLightingDetail(-1);
+}
+
+LLPipeline::~LLPipeline()
+{
+
+}
+
+void LLPipeline::cleanup()
+{
+ assertInitialized();
+
+ mGroupQ1.clear() ;
+ mGroupQ2.clear() ;
+
+ for(pool_set_t::iterator iter = mPools.begin();
+ iter != mPools.end(); )
+ {
+ pool_set_t::iterator curiter = iter++;
+ LLDrawPool* poolp = *curiter;
+ if (poolp->isFacePool())
+ {
+ LLFacePool* face_pool = (LLFacePool*) poolp;
+ if (face_pool->mReferences.empty())
+ {
+ mPools.erase(curiter);
+ removeFromQuickLookup( poolp );
+ delete poolp;
+ }
+ }
+ else
+ {
+ mPools.erase(curiter);
+ removeFromQuickLookup( poolp );
+ delete poolp;
+ }
+ }
+
+ if (!mTerrainPools.empty())
+ {
+ llwarns << "Terrain Pools not cleaned up" << llendl;
+ }
+ if (!mTreePools.empty())
+ {
+ llwarns << "Tree Pools not cleaned up" << llendl;
+ }
+
+ delete mAlphaPool;
+ mAlphaPool = NULL;
+ delete mSkyPool;
+ mSkyPool = NULL;
+ delete mTerrainPool;
+ mTerrainPool = NULL;
+ delete mWaterPool;
+ mWaterPool = NULL;
+ delete mGroundPool;
+ mGroundPool = NULL;
+ delete mSimplePool;
+ mSimplePool = NULL;
+ delete mFullbrightPool;
+ mFullbrightPool = NULL;
+ delete mInvisiblePool;
+ mInvisiblePool = NULL;
+ delete mGlowPool;
+ mGlowPool = NULL;
+ delete mBumpPool;
+ mBumpPool = NULL;
+ // don't delete wl sky pool it was handled above in the for loop
+ //delete mWLSkyPool;
+ mWLSkyPool = NULL;
+
+ releaseGLBuffers();
+
+ mFaceSelectImagep = NULL;
+
+ mMovedBridge.clear();
+
+ mInitialized = FALSE;
+}
+
+//============================================================================
+
+void LLPipeline::destroyGL()
+{
+ stop_glerror();
+ unloadShaders();
+ mHighlightFaces.clear();
+
+ resetDrawOrders();
+
+ resetVertexBuffers();
+
+ releaseGLBuffers();
+
+ if (LLVertexBuffer::sEnableVBOs)
+ {
+ // render 30 frames after switching to work around DEV-5361
+ sDelayedVBOEnable = 30;
+ LLVertexBuffer::sEnableVBOs = FALSE;
+ }
+}
+
+static LLFastTimer::DeclareTimer FTM_RESIZE_SCREEN_TEXTURE("Resize Screen Texture");
+
+void LLPipeline::resizeScreenTexture()
+{
+ LLFastTimer ft(FTM_RESIZE_SCREEN_TEXTURE);
+ if (gPipeline.canUseVertexShaders() && assertInitialized())
+ {
+ GLuint resX = gViewerWindow->getWorldViewWidthRaw();
+ GLuint resY = gViewerWindow->getWorldViewHeightRaw();
+
+ allocateScreenBuffer(resX,resY);
+ }
+}
+
+void LLPipeline::allocatePhysicsBuffer()
+{
+ GLuint resX = gViewerWindow->getWorldViewWidthRaw();
+ GLuint resY = gViewerWindow->getWorldViewHeightRaw();
+
+ if (mPhysicsDisplay.getWidth() != resX || mPhysicsDisplay.getHeight() != resY)
+ {
+ mPhysicsDisplay.allocate(resX, resY, GL_RGBA, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ if (mSampleBuffer.getWidth() == mPhysicsDisplay.getWidth() &&
+ mSampleBuffer.getHeight() == mPhysicsDisplay.getHeight())
+ {
+ mPhysicsDisplay.setSampleBuffer(&mSampleBuffer);
+ }
+ }
+}
+
+void LLPipeline::allocateScreenBuffer(U32 resX, U32 resY)
+{
+ // remember these dimensions
+ mScreenWidth = resX;
+ mScreenHeight = resY;
+
+ //never use more than 4 samples for render targets
+ U32 samples = llmin(gSavedSettings.getU32("RenderFSAASamples"), (U32) 4);
+ if (gGLManager.mIsATI)
+ { //disable multisampling of render targets where ATI is involved
+ samples = 0;
+ }
+
+ U32 res_mod = gSavedSettings.getU32("RenderResolutionDivisor");
+
+ if (res_mod > 1 && res_mod < resX && res_mod < resY)
+ {
+ resX /= res_mod;
+ resY /= res_mod;
+ }
+
+ if (gSavedSettings.getBOOL("RenderUIBuffer"))
+ {
+ mUIScreen.allocate(resX,resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ }
+
+ if (LLPipeline::sRenderDeferred)
+ {
+ S32 shadow_detail = gSavedSettings.getS32("RenderShadowDetail");
+ BOOL ssao = gSavedSettings.getBOOL("RenderDeferredSSAO");
+ bool gi = LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED);
+
+ //allocate deferred rendering color buffers
+ mDeferredScreen.allocate(resX, resY, GL_RGBA, TRUE, TRUE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ mDeferredDepth.allocate(resX, resY, 0, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ addDeferredAttachments(mDeferredScreen);
+
+ mScreen.allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ mEdgeMap.allocate(resX, resY, GL_ALPHA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+
+ if (shadow_detail > 0 || ssao)
+ { //only need mDeferredLight[0] for shadows OR ssao
+ mDeferredLight[0].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE);
+ }
+ else
+ {
+ mDeferredLight[0].release();
+ }
+
+ if (ssao)
+ { //only need mDeferredLight[1] for ssao
+ mDeferredLight[1].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE);
+ }
+ else
+ {
+ mDeferredLight[1].release();
+ }
+
+ if (gi)
+ { //only need mDeferredLight[2] and mGIMapPost for gi
+ mDeferredLight[2].allocate(resX, resY, GL_RGBA, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE);
+ for (U32 i = 0; i < 2; i++)
+ {
+ mGIMapPost[i].allocate(resX,resY, GL_RGB, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE);
+ }
+ }
+ else
+ {
+ mDeferredLight[2].release();
+
+ for (U32 i = 0; i < 2; i++)
+ {
+ mGIMapPost[i].release();
+ }
+ }
+
+ F32 scale = gSavedSettings.getF32("RenderShadowResolutionScale");
+
+ //HACK: make alpha masking work on ATI depth shadows (work around for ATI driver bug)
+ U32 shadow_fmt = gGLManager.mIsATI ? GL_ALPHA : 0;
+
+ if (shadow_detail > 0)
+ { //allocate 4 sun shadow maps
+ for (U32 i = 0; i < 4; i++)
+ {
+ mShadow[i].allocate(U32(resX*scale),U32(resY*scale), shadow_fmt, TRUE, FALSE, LLTexUnit::TT_RECT_TEXTURE);
+ }
+ }
+ else
+ {
+ for (U32 i = 0; i < 4; i++)
+ {
+ mShadow[i].release();
+ }
+ }
+
+ U32 width = nhpo2(U32(resX*scale))/2;
+ U32 height = width;
+
+ if (shadow_detail > 1)
+ { //allocate two spot shadow maps
+ for (U32 i = 4; i < 6; i++)
+ {
+ mShadow[i].allocate(width, height, shadow_fmt, TRUE, FALSE);
+ }
+ }
+ else
+ {
+ for (U32 i = 4; i < 6; i++)
+ {
+ mShadow[i].release();
+ }
+ }
+
+ width = nhpo2(resX)/2;
+ height = nhpo2(resY)/2;
+ mLuminanceMap.allocate(width,height, GL_RGBA, FALSE, FALSE);
+ }
+ else
+ {
+ for (U32 i = 0; i < 3; i++)
+ {
+ mDeferredLight[i].release();
+ }
+ for (U32 i = 0; i < 2; i++)
+ {
+ mGIMapPost[i].release();
+ }
+ for (U32 i = 0; i < 6; i++)
+ {
+ mShadow[i].release();
+ }
+ mScreen.release();
+ mDeferredScreen.release(); //make sure to release any render targets that share a depth buffer with mDeferredScreen first
+ mDeferredDepth.release();
+ mEdgeMap.release();
+ mLuminanceMap.release();
+
+ mScreen.allocate(resX, resY, GL_RGBA, TRUE, TRUE, LLTexUnit::TT_RECT_TEXTURE, FALSE);
+ }
+
+ if (LLRenderTarget::sUseFBO && samples > 1)
+ {
+ mSampleBuffer.allocate(resX,resY,GL_RGBA,TRUE,TRUE,LLTexUnit::TT_RECT_TEXTURE,FALSE,samples);
+ if (LLPipeline::sRenderDeferred)
+ {
+ addDeferredAttachments(mSampleBuffer);
+ mDeferredScreen.setSampleBuffer(&mSampleBuffer);
+ mEdgeMap.setSampleBuffer(&mSampleBuffer);
+ }
+
+ mScreen.setSampleBuffer(&mSampleBuffer);
+
+ stop_glerror();
+ }
+ else
+ {
+ mSampleBuffer.release();
+ }
+
+ if (LLPipeline::sRenderDeferred)
+ { //share depth buffer between deferred targets
+ mDeferredScreen.shareDepthBuffer(mScreen);
+ for (U32 i = 0; i < 3; i++)
+ { //share stencil buffer with screen space lightmap to stencil out sky
+ if (mDeferredLight[i].getTexture(0))
+ {
+ mDeferredScreen.shareDepthBuffer(mDeferredLight[i]);
+ }
+ }
+ }
+
+ gGL.getTexUnit(0)->disable();
+
+ stop_glerror();
+
+}
+
+//static
+void LLPipeline::updateRenderDeferred()
+{
+ BOOL deferred = ((gSavedSettings.getBOOL("RenderDeferred") &&
+ LLRenderTarget::sUseFBO &&
+ LLFeatureManager::getInstance()->isFeatureAvailable("RenderDeferred") &&
+ gSavedSettings.getBOOL("VertexShaderEnable") &&
+ gSavedSettings.getBOOL("RenderAvatarVP") &&
+ gSavedSettings.getBOOL("WindLightUseAtmosShaders")) ? TRUE : FALSE) &&
+ !gUseWireframe;
+
+ sRenderDeferred = deferred;
+ if (deferred)
+ { //must render glow when rendering deferred since post effect pass is needed to present any lighting at all
+ sRenderGlow = TRUE;
+ }
+}
+
+void LLPipeline::releaseGLBuffers()
+{
+ assertInitialized();
+
+ if (mNoiseMap)
+ {
+ LLImageGL::deleteTextures(1, &mNoiseMap);
+ mNoiseMap = 0;
+ }
+
+ if (mTrueNoiseMap)
+ {
+ LLImageGL::deleteTextures(1, &mTrueNoiseMap);
+ mTrueNoiseMap = 0;
+ }
+
+ if (mLightFunc)
+ {
+ LLImageGL::deleteTextures(1, &mLightFunc);
+ mLightFunc = 0;
+ }
+
+ mWaterRef.release();
+ mWaterDis.release();
+ mScreen.release();
+ mPhysicsDisplay.release();
+ mUIScreen.release();
+ mSampleBuffer.release();
+ mDeferredScreen.release();
+ mDeferredDepth.release();
+ for (U32 i = 0; i < 3; i++)
+ {
+ mDeferredLight[i].release();
+ }
+
+ mEdgeMap.release();
+ mGIMap.release();
+ mGIMapPost[0].release();
+ mGIMapPost[1].release();
+ mHighlight.release();
+ mLuminanceMap.release();
+
+ for (U32 i = 0; i < 6; i++)
+ {
+ mShadow[i].release();
+ }
+
+ for (U32 i = 0; i < 3; i++)
+ {
+ mGlow[i].release();
+ }
+
+ gBumpImageList.destroyGL();
+ LLVOAvatar::resetImpostors();
+}
+
+void LLPipeline::createGLBuffers()
+{
+ LLMemType mt_cb(LLMemType::MTYPE_PIPELINE_CREATE_BUFFERS);
+ assertInitialized();
+
+ updateRenderDeferred();
+
+ if (LLPipeline::sWaterReflections)
+ { //water reflection texture
+ U32 res = (U32) gSavedSettings.getS32("RenderWaterRefResolution");
+
+ mWaterRef.allocate(res,res,GL_RGBA,TRUE,FALSE);
+ mWaterDis.allocate(res,res,GL_RGBA,TRUE,FALSE);
+ }
+
+ mHighlight.allocate(256,256,GL_RGBA, FALSE, FALSE);
+
+ stop_glerror();
+
+ GLuint resX = gViewerWindow->getWorldViewWidthRaw();
+ GLuint resY = gViewerWindow->getWorldViewHeightRaw();
+
+ if (LLPipeline::sRenderGlow)
+ { //screen space glow buffers
+ const U32 glow_res = llmax(1,
+ llmin(512, 1 << gSavedSettings.getS32("RenderGlowResolutionPow")));
+
+ for (U32 i = 0; i < 3; i++)
+ {
+ mGlow[i].allocate(512,glow_res,GL_RGBA,FALSE,FALSE);
+ }
+
+ allocateScreenBuffer(resX,resY);
+ mScreenWidth = 0;
+ mScreenHeight = 0;
+ }
+
+ if (sRenderDeferred)
+ {
+ if (!mNoiseMap)
+ {
+ const U32 noiseRes = 128;
+ LLVector3 noise[noiseRes*noiseRes];
+
+ F32 scaler = gSavedSettings.getF32("RenderDeferredNoise")/100.f;
+ for (U32 i = 0; i < noiseRes*noiseRes; ++i)
+ {
+ noise[i] = LLVector3(ll_frand()-0.5f, ll_frand()-0.5f, 0.f);
+ noise[i].normVec();
+ noise[i].mV[2] = ll_frand()*scaler+1.f-scaler/2.f;
+ }
+
+ 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);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ if (!mTrueNoiseMap)
+ {
+ const U32 noiseRes = 128;
+ F32 noise[noiseRes*noiseRes*3];
+ for (U32 i = 0; i < noiseRes*noiseRes*3; i++)
+ {
+ noise[i] = ll_frand()*2.0-1.0;
+ }
+
+ 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);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ if (!mLightFunc)
+ {
+ U32 lightResX = gSavedSettings.getU32("RenderSpecularResX");
+ U32 lightResY = gSavedSettings.getU32("RenderSpecularResY");
+ U8* lg = new U8[lightResX*lightResY];
+
+ for (U32 y = 0; y < lightResY; ++y)
+ {
+ for (U32 x = 0; x < lightResX; ++x)
+ {
+ //spec func
+ F32 sa = (F32) x/(lightResX-1);
+ F32 spec = (F32) y/(lightResY-1);
+ //lg[y*lightResX+x] = (U8) (powf(sa, 128.f*spec*spec)*255);
+
+ //F32 sp = acosf(sa)/(1.f-spec);
+
+ sa = powf(sa, gSavedSettings.getF32("RenderSpecularExponent"));
+ F32 a = acosf(sa*0.25f+0.75f);
+ F32 m = llmax(0.5f-spec*0.5f, 0.001f);
+ F32 t2 = tanf(a)/m;
+ t2 *= t2;
+
+ F32 c4a = (3.f+4.f*cosf(2.f*a)+cosf(4.f*a))/8.f;
+ F32 bd = 1.f/(4.f*m*m*c4a)*powf(F_E, -t2);
+
+ lg[y*lightResX+x] = (U8) (llclamp(bd, 0.f, 1.f)*255);
+ }
+ }
+
+ LLImageGL::generateTextures(1, &mLightFunc);
+ gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mLightFunc);
+ LLImageGL::setManualImage(LLTexUnit::getInternalType(LLTexUnit::TT_TEXTURE), 0, GL_ALPHA, lightResX, lightResY, GL_ALPHA, GL_UNSIGNED_BYTE, lg);
+ gGL.getTexUnit(0)->setTextureAddressMode(LLTexUnit::TAM_CLAMP);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR);
+
+ delete [] lg;
+ }
+
+ if (gSavedSettings.getBOOL("RenderDeferredGI"))
+ {
+ mGIMap.allocate(512,512,GL_RGBA, TRUE, FALSE);
+ addDeferredAttachments(mGIMap);
+ }
+ }
+
+ gBumpImageList.restoreGL();
+}
+
+void LLPipeline::restoreGL()
+{
+ LLMemType mt_cb(LLMemType::MTYPE_PIPELINE_RESTORE_GL);
+ assertInitialized();
+
+ if (mVertexShadersEnabled)
+ {
+ LLViewerShaderMgr::instance()->setShaders();
+ }
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ part->restoreGL();
+ }
+ }
+ }
+}
+
+
+BOOL LLPipeline::canUseVertexShaders()
+{
+ if (sDisableShaders ||
+ !gGLManager.mHasVertexShader ||
+ !gGLManager.mHasFragmentShader ||
+ !LLFeatureManager::getInstance()->isFeatureAvailable("VertexShaderEnable") ||
+ (assertInitialized() && mVertexShadersLoaded != 1) )
+ {
+ return FALSE;
+ }
+ else
+ {
+ return TRUE;
+ }
+}
+
+BOOL LLPipeline::canUseWindLightShaders() const
+{
+ return (!LLPipeline::sDisableShaders &&
+ gWLSkyProgram.mProgramObject != 0 &&
+ LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_WINDLIGHT) > 1);
+}
+
+BOOL LLPipeline::canUseWindLightShadersOnObjects() const
+{
+ return (canUseWindLightShaders()
+ && LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_OBJECT) > 0);
+}
+
+BOOL LLPipeline::canUseAntiAliasing() const
+{
+ return TRUE;
+}
+
+void LLPipeline::unloadShaders()
+{
+ LLMemType mt_us(LLMemType::MTYPE_PIPELINE_UNLOAD_SHADERS);
+ LLViewerShaderMgr::instance()->unloadShaders();
+
+ mVertexShadersLoaded = 0;
+}
+
+void LLPipeline::assertInitializedDoError()
+{
+ llerrs << "LLPipeline used when uninitialized." << llendl;
+}
+
+//============================================================================
+
+void LLPipeline::enableShadows(const BOOL enable_shadows)
+{
+ //should probably do something here to wrangle shadows....
+}
+
+S32 LLPipeline::getMaxLightingDetail() const
+{
+ /*if (mVertexShaderLevel[SHADER_OBJECT] >= LLDrawPoolSimple::SHADER_LEVEL_LOCAL_LIGHTS)
+ {
+ return 3;
+ }
+ else*/
+ {
+ return 1;
+ }
+}
+
+S32 LLPipeline::setLightingDetail(S32 level)
+{
+ LLMemType mt_ld(LLMemType::MTYPE_PIPELINE_LIGHTING_DETAIL);
+
+ if (level < 0)
+ {
+ if (gSavedSettings.getBOOL("RenderLocalLights"))
+ {
+ level = 1;
+ }
+ else
+ {
+ level = 0;
+ }
+ }
+ level = llclamp(level, 0, getMaxLightingDetail());
+ mLightingDetail = level;
+
+ return mLightingDetail;
+}
+
+class LLOctreeDirtyTexture : public LLOctreeTraveler<LLDrawable>
+{
+public:
+ const std::set<LLViewerFetchedTexture*>& mTextures;
+
+ LLOctreeDirtyTexture(const std::set<LLViewerFetchedTexture*>& textures) : mTextures(textures) { }
+
+ virtual void visit(const LLOctreeNode<LLDrawable>* node)
+ {
+ LLSpatialGroup* group = (LLSpatialGroup*) node->getListener(0);
+
+ if (!group->isState(LLSpatialGroup::GEOM_DIRTY) && !group->getData().empty())
+ {
+ for (LLSpatialGroup::draw_map_t::iterator i = group->mDrawMap.begin(); i != group->mDrawMap.end(); ++i)
+ {
+ for (LLSpatialGroup::drawmap_elem_t::iterator j = i->second.begin(); j != i->second.end(); ++j)
+ {
+ LLDrawInfo* params = *j;
+ LLViewerFetchedTexture* tex = LLViewerTextureManager::staticCastToFetchedTexture(params->mTexture);
+ if (tex && mTextures.find(tex) != mTextures.end())
+ {
+ group->setState(LLSpatialGroup::GEOM_DIRTY);
+ }
+ }
+ }
+ }
+
+ for (LLSpatialGroup::bridge_list_t::iterator i = group->mBridgeList.begin(); i != group->mBridgeList.end(); ++i)
+ {
+ LLSpatialBridge* bridge = *i;
+ traverse(bridge->mOctree);
+ }
+ }
+};
+
+// Called when a texture changes # of channels (causes faces to move to alpha pool)
+void LLPipeline::dirtyPoolObjectTextures(const std::set<LLViewerFetchedTexture*>& textures)
+{
+ assertInitialized();
+
+ // *TODO: This is inefficient and causes frame spikes; need a better way to do this
+ // Most of the time is spent in dirty.traverse.
+
+ for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter)
+ {
+ LLDrawPool *poolp = *iter;
+ if (poolp->isFacePool())
+ {
+ ((LLFacePool*) poolp)->dirtyTextures(textures);
+ }
+ }
+
+ LLOctreeDirtyTexture dirty(textures);
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ dirty.traverse(part->mOctree);
+ }
+ }
+ }
+}
+
+LLDrawPool *LLPipeline::findPool(const U32 type, LLViewerTexture *tex0)
+{
+ assertInitialized();
+
+ LLDrawPool *poolp = NULL;
+ switch( type )
+ {
+ case LLDrawPool::POOL_SIMPLE:
+ poolp = mSimplePool;
+ break;
+
+ case LLDrawPool::POOL_GRASS:
+ poolp = mGrassPool;
+ break;
+
+ case LLDrawPool::POOL_FULLBRIGHT:
+ poolp = mFullbrightPool;
+ break;
+
+ case LLDrawPool::POOL_INVISIBLE:
+ poolp = mInvisiblePool;
+ break;
+
+ case LLDrawPool::POOL_GLOW:
+ poolp = mGlowPool;
+ break;
+
+ case LLDrawPool::POOL_TREE:
+ poolp = get_if_there(mTreePools, (uintptr_t)tex0, (LLDrawPool*)0 );
+ break;
+
+ case LLDrawPool::POOL_TERRAIN:
+ poolp = get_if_there(mTerrainPools, (uintptr_t)tex0, (LLDrawPool*)0 );
+ break;
+
+ case LLDrawPool::POOL_BUMP:
+ poolp = mBumpPool;
+ break;
+
+ case LLDrawPool::POOL_ALPHA:
+ poolp = mAlphaPool;
+ break;
+
+ case LLDrawPool::POOL_AVATAR:
+ break; // Do nothing
+
+ case LLDrawPool::POOL_SKY:
+ poolp = mSkyPool;
+ break;
+
+ case LLDrawPool::POOL_WATER:
+ poolp = mWaterPool;
+ break;
+
+ case LLDrawPool::POOL_GROUND:
+ poolp = mGroundPool;
+ break;
+
+ case LLDrawPool::POOL_WL_SKY:
+ poolp = mWLSkyPool;
+ break;
+
+ default:
+ llassert(0);
+ llerrs << "Invalid Pool Type in LLPipeline::findPool() type=" << type << llendl;
+ break;
+ }
+
+ return poolp;
+}
+
+
+LLDrawPool *LLPipeline::getPool(const U32 type, LLViewerTexture *tex0)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+ LLDrawPool *poolp = findPool(type, tex0);
+ if (poolp)
+ {
+ return poolp;
+ }
+
+ LLDrawPool *new_poolp = LLDrawPool::createPool(type, tex0);
+ addPool( new_poolp );
+
+ return new_poolp;
+}
+
+
+// static
+LLDrawPool* LLPipeline::getPoolFromTE(const LLTextureEntry* te, LLViewerTexture* imagep)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+ U32 type = getPoolTypeFromTE(te, imagep);
+ return gPipeline.getPool(type, imagep);
+}
+
+//static
+U32 LLPipeline::getPoolTypeFromTE(const LLTextureEntry* te, LLViewerTexture* imagep)
+{
+ LLMemType mt_gpt(LLMemType::MTYPE_PIPELINE_GET_POOL_TYPE);
+
+ if (!te || !imagep)
+ {
+ return 0;
+ }
+
+ bool alpha = te->getColor().mV[3] < 0.999f;
+ if (imagep)
+ {
+ alpha = alpha || (imagep->getComponents() == 4 && imagep->getType() != LLViewerTexture::MEDIA_TEXTURE) || (imagep->getComponents() == 2);
+ }
+
+ if (alpha)
+ {
+ return LLDrawPool::POOL_ALPHA;
+ }
+ else if ((te->getBumpmap() || te->getShiny()))
+ {
+ return LLDrawPool::POOL_BUMP;
+ }
+ else
+ {
+ return LLDrawPool::POOL_SIMPLE;
+ }
+}
+
+
+void LLPipeline::addPool(LLDrawPool *new_poolp)
+{
+ LLMemType mt_a(LLMemType::MTYPE_PIPELINE_ADD_POOL);
+ assertInitialized();
+ mPools.insert(new_poolp);
+ addToQuickLookup( new_poolp );
+}
+
+void LLPipeline::allocDrawable(LLViewerObject *vobj)
+{
+ LLMemType mt_ad(LLMemType::MTYPE_PIPELINE_ALLOCATE_DRAWABLE);
+ LLDrawable *drawable = new LLDrawable();
+ vobj->mDrawable = drawable;
+
+ drawable->mVObjp = vobj;
+
+ //encompass completely sheared objects by taking
+ //the most extreme point possible (<1,1,0.5>)
+ drawable->setRadius(LLVector3(1,1,0.5f).scaleVec(vobj->getScale()).length());
+ if (vobj->isOrphaned())
+ {
+ drawable->setState(LLDrawable::FORCE_INVISIBLE);
+ }
+ drawable->updateXform(TRUE);
+}
+
+
+static LLFastTimer::DeclareTimer FTM_UNLINK("Unlink");
+static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_MOVE_LIST("Movelist");
+static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_SPATIAL_PARTITION("Spatial Partition");
+static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_LIGHT_SET("Light Set");
+static LLFastTimer::DeclareTimer FTM_REMOVE_FROM_HIGHLIGHT_SET("Highlight Set");
+
+void LLPipeline::unlinkDrawable(LLDrawable *drawable)
+{
+ LLFastTimer t(FTM_UNLINK);
+
+ assertInitialized();
+
+ LLPointer<LLDrawable> drawablep = drawable; // make sure this doesn't get deleted before we are done
+
+ // Based on flags, remove the drawable from the queues that it's on.
+ if (drawablep->isState(LLDrawable::ON_MOVE_LIST))
+ {
+ LLFastTimer t(FTM_REMOVE_FROM_MOVE_LIST);
+ LLDrawable::drawable_vector_t::iterator iter = std::find(mMovedList.begin(), mMovedList.end(), drawablep);
+ if (iter != mMovedList.end())
+ {
+ mMovedList.erase(iter);
+ }
+ }
+
+ if (drawablep->getSpatialGroup())
+ {
+ LLFastTimer t(FTM_REMOVE_FROM_SPATIAL_PARTITION);
+ if (!drawablep->getSpatialGroup()->mSpatialPartition->remove(drawablep, drawablep->getSpatialGroup()))
+ {
+#ifdef LL_RELEASE_FOR_DOWNLOAD
+ llwarns << "Couldn't remove object from spatial group!" << llendl;
+#else
+ llerrs << "Couldn't remove object from spatial group!" << llendl;
+#endif
+ }
+ }
+
+ {
+ LLFastTimer t(FTM_REMOVE_FROM_LIGHT_SET);
+ mLights.erase(drawablep);
+
+ for (light_set_t::iterator iter = mNearbyLights.begin();
+ iter != mNearbyLights.end(); iter++)
+ {
+ if (iter->drawable == drawablep)
+ {
+ mNearbyLights.erase(iter);
+ break;
+ }
+ }
+ }
+
+ {
+ LLFastTimer t(FTM_REMOVE_FROM_HIGHLIGHT_SET);
+ HighlightItem item(drawablep);
+ mHighlightSet.erase(item);
+
+ if (mHighlightObject == drawablep)
+ {
+ mHighlightObject = NULL;
+ }
+ }
+
+ for (U32 i = 0; i < 2; ++i)
+ {
+ if (mShadowSpotLight[i] == drawablep)
+ {
+ mShadowSpotLight[i] = NULL;
+ }
+
+ if (mTargetShadowSpotLight[i] == drawablep)
+ {
+ mTargetShadowSpotLight[i] = NULL;
+ }
+ }
+
+
+}
+
+U32 LLPipeline::addObject(LLViewerObject *vobj)
+{
+ LLMemType mt_ao(LLMemType::MTYPE_PIPELINE_ADD_OBJECT);
+ if (gNoRender)
+ {
+ return 0;
+ }
+
+ if (gSavedSettings.getBOOL("RenderDelayCreation"))
+ {
+ mCreateQ.push_back(vobj);
+ }
+ else
+ {
+ createObject(vobj);
+ }
+
+ return 1;
+}
+
+void LLPipeline::createObjects(F32 max_dtime)
+{
+ LLFastTimer ftm(FTM_GEO_UPDATE);
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_CREATE_OBJECTS);
+
+ LLTimer update_timer;
+
+ while (!mCreateQ.empty() && update_timer.getElapsedTimeF32() < max_dtime)
+ {
+ LLViewerObject* vobj = mCreateQ.front();
+ if (!vobj->isDead())
+ {
+ createObject(vobj);
+ }
+ mCreateQ.pop_front();
+ }
+
+ //for (LLViewerObject::vobj_list_t::iterator iter = mCreateQ.begin(); iter != mCreateQ.end(); ++iter)
+ //{
+ // createObject(*iter);
+ //}
+
+ //mCreateQ.clear();
+}
+
+void LLPipeline::createObject(LLViewerObject* vobj)
+{
+ LLDrawable* drawablep = vobj->mDrawable;
+
+ if (!drawablep)
+ {
+ drawablep = vobj->createDrawable(this);
+ }
+ else
+ {
+ llerrs << "Redundant drawable creation!" << llendl;
+ }
+
+ llassert(drawablep);
+
+ if (vobj->getParent())
+ {
+ vobj->setDrawableParent(((LLViewerObject*)vobj->getParent())->mDrawable); // LLPipeline::addObject 1
+ }
+ else
+ {
+ vobj->setDrawableParent(NULL); // LLPipeline::addObject 2
+ }
+
+ markRebuild(drawablep, LLDrawable::REBUILD_ALL, TRUE);
+
+ if (drawablep->getVOVolume() && gSavedSettings.getBOOL("RenderAnimateRes"))
+ {
+ // fun animated res
+ drawablep->updateXform(TRUE);
+ drawablep->clearState(LLDrawable::MOVE_UNDAMPED);
+ drawablep->setScale(LLVector3(0,0,0));
+ drawablep->makeActive();
+ }
+}
+
+
+void LLPipeline::resetFrameStats()
+{
+ assertInitialized();
+
+ LLViewerStats::getInstance()->mTrianglesDrawnStat.addValue(mTrianglesDrawn/1000.f);
+
+ if (mBatchCount > 0)
+ {
+ mMeanBatchSize = gPipeline.mTrianglesDrawn/gPipeline.mBatchCount;
+ }
+ mTrianglesDrawn = 0;
+ sCompiles = 0;
+ mVerticesRelit = 0;
+ mLightingChanges = 0;
+ mGeometryChanges = 0;
+ mNumVisibleFaces = 0;
+
+ if (mOldRenderDebugMask != mRenderDebugMask)
+ {
+ gObjectList.clearDebugText();
+ mOldRenderDebugMask = mRenderDebugMask;
+ }
+
+}
+
+//external functions for asynchronous updating
+void LLPipeline::updateMoveDampedAsync(LLDrawable* drawablep)
+{
+ if (gSavedSettings.getBOOL("FreezeTime"))
+ {
+ return;
+ }
+ if (!drawablep)
+ {
+ llerrs << "updateMove called with NULL drawablep" << llendl;
+ return;
+ }
+ if (drawablep->isState(LLDrawable::EARLY_MOVE))
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ // update drawable now
+ drawablep->clearState(LLDrawable::MOVE_UNDAMPED); // force to DAMPED
+ drawablep->updateMove(); // returns done
+ drawablep->setState(LLDrawable::EARLY_MOVE); // flag says we already did an undamped move this frame
+ // Put on move list so that EARLY_MOVE gets cleared
+ if (!drawablep->isState(LLDrawable::ON_MOVE_LIST))
+ {
+ mMovedList.push_back(drawablep);
+ drawablep->setState(LLDrawable::ON_MOVE_LIST);
+ }
+}
+
+void LLPipeline::updateMoveNormalAsync(LLDrawable* drawablep)
+{
+ if (gSavedSettings.getBOOL("FreezeTime"))
+ {
+ return;
+ }
+ if (!drawablep)
+ {
+ llerrs << "updateMove called with NULL drawablep" << llendl;
+ return;
+ }
+ if (drawablep->isState(LLDrawable::EARLY_MOVE))
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ // update drawable now
+ drawablep->setState(LLDrawable::MOVE_UNDAMPED); // force to UNDAMPED
+ drawablep->updateMove();
+ drawablep->setState(LLDrawable::EARLY_MOVE); // flag says we already did an undamped move this frame
+ // Put on move list so that EARLY_MOVE gets cleared
+ if (!drawablep->isState(LLDrawable::ON_MOVE_LIST))
+ {
+ mMovedList.push_back(drawablep);
+ drawablep->setState(LLDrawable::ON_MOVE_LIST);
+ }
+}
+
+void LLPipeline::updateMovedList(LLDrawable::drawable_vector_t& moved_list)
+{
+ for (LLDrawable::drawable_vector_t::iterator iter = moved_list.begin();
+ iter != moved_list.end(); )
+ {
+ LLDrawable::drawable_vector_t::iterator curiter = iter++;
+ LLDrawable *drawablep = *curiter;
+ BOOL done = TRUE;
+ if (!drawablep->isDead() && (!drawablep->isState(LLDrawable::EARLY_MOVE)))
+ {
+ done = drawablep->updateMove();
+ }
+ drawablep->clearState(LLDrawable::EARLY_MOVE | LLDrawable::MOVE_UNDAMPED);
+ if (done)
+ {
+ drawablep->clearState(LLDrawable::ON_MOVE_LIST);
+ iter = moved_list.erase(curiter);
+ }
+ }
+}
+
+static LLFastTimer::DeclareTimer FTM_OCTREE_BALANCE("Balance Octree");
+static LLFastTimer::DeclareTimer FTM_UPDATE_MOVE("Update Move");
+
+void LLPipeline::updateMove()
+{
+ LLFastTimer t(FTM_UPDATE_MOVE);
+ LLMemType mt_um(LLMemType::MTYPE_PIPELINE_UPDATE_MOVE);
+
+ if (gSavedSettings.getBOOL("FreezeTime"))
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ {
+ static LLFastTimer::DeclareTimer ftm("Retexture");
+ LLFastTimer t(ftm);
+
+ for (LLDrawable::drawable_set_t::iterator iter = mRetexturedList.begin();
+ iter != mRetexturedList.end(); ++iter)
+ {
+ LLDrawable* drawablep = *iter;
+ if (drawablep && !drawablep->isDead())
+ {
+ drawablep->updateTexture();
+ }
+ }
+ mRetexturedList.clear();
+ }
+
+ {
+ static LLFastTimer::DeclareTimer ftm("Moved List");
+ LLFastTimer t(ftm);
+ updateMovedList(mMovedList);
+ }
+
+ //balance octrees
+ {
+ LLFastTimer ot(FTM_OCTREE_BALANCE);
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ part->mOctree->balance();
+ }
+ }
+ }
+ }
+}
+
+/////////////////////////////////////////////////////////////////////////////
+// Culling and occlusion testing
+/////////////////////////////////////////////////////////////////////////////
+
+//static
+F32 LLPipeline::calcPixelArea(LLVector3 center, LLVector3 size, LLCamera &camera)
+{
+ LLVector3 lookAt = center - camera.getOrigin();
+ F32 dist = lookAt.length();
+
+ //ramp down distance for nearby objects
+ //shrink dist by dist/16.
+ if (dist < 16.f)
+ {
+ dist /= 16.f;
+ dist *= dist;
+ dist *= 16.f;
+ }
+
+ //get area of circle around node
+ F32 app_angle = atanf(size.length()/dist);
+ F32 radius = app_angle*LLDrawable::sCurPixelAngle;
+ return radius*radius * F_PI;
+}
+
+//static
+F32 LLPipeline::calcPixelArea(const LLVector4a& center, const LLVector4a& size, LLCamera &camera)
+{
+ LLVector4a origin;
+ origin.load3(camera.getOrigin().mV);
+
+ LLVector4a lookAt;
+ lookAt.setSub(center, origin);
+ F32 dist = lookAt.getLength3().getF32();
+
+ //ramp down distance for nearby objects
+ //shrink dist by dist/16.
+ if (dist < 16.f)
+ {
+ dist /= 16.f;
+ dist *= dist;
+ dist *= 16.f;
+ }
+
+ //get area of circle around node
+ F32 app_angle = atanf(size.getLength3().getF32()/dist);
+ F32 radius = app_angle*LLDrawable::sCurPixelAngle;
+ return radius*radius * F_PI;
+}
+
+void LLPipeline::grabReferences(LLCullResult& result)
+{
+ sCull = &result;
+}
+
+void LLPipeline::clearReferences()
+{
+ sCull = NULL;
+}
+
+void check_references(LLSpatialGroup* group, LLDrawable* drawable)
+{
+ for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i)
+ {
+ if (drawable == *i)
+ {
+ llerrs << "LLDrawable deleted while actively reference by LLPipeline." << llendl;
+ }
+ }
+}
+
+void check_references(LLDrawable* drawable, LLFace* face)
+{
+ for (S32 i = 0; i < drawable->getNumFaces(); ++i)
+ {
+ if (drawable->getFace(i) == face)
+ {
+ llerrs << "LLFace deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+}
+
+void check_references(LLSpatialGroup* group, LLFace* face)
+{
+ for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i)
+ {
+ LLDrawable* drawable = *i;
+ check_references(drawable, face);
+ }
+}
+
+void LLPipeline::checkReferences(LLFace* face)
+{
+#if 0
+ if (sCull)
+ {
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, face);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, face);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, face);
+ }
+
+ for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList(); iter != sCull->endVisibleList(); ++iter)
+ {
+ LLDrawable* drawable = *iter;
+ check_references(drawable, face);
+ }
+ }
+#endif
+}
+
+void LLPipeline::checkReferences(LLDrawable* drawable)
+{
+#if 0
+ if (sCull)
+ {
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, drawable);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, drawable);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, drawable);
+ }
+
+ for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList(); iter != sCull->endVisibleList(); ++iter)
+ {
+ if (drawable == *iter)
+ {
+ llerrs << "LLDrawable deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+ }
+#endif
+}
+
+void check_references(LLSpatialGroup* group, LLDrawInfo* draw_info)
+{
+ for (LLSpatialGroup::draw_map_t::iterator i = group->mDrawMap.begin(); i != group->mDrawMap.end(); ++i)
+ {
+ LLSpatialGroup::drawmap_elem_t& draw_vec = i->second;
+ for (LLSpatialGroup::drawmap_elem_t::iterator j = draw_vec.begin(); j != draw_vec.end(); ++j)
+ {
+ LLDrawInfo* params = *j;
+ if (params == draw_info)
+ {
+ llerrs << "LLDrawInfo deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+ }
+}
+
+
+void LLPipeline::checkReferences(LLDrawInfo* draw_info)
+{
+#if 0
+ if (sCull)
+ {
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, draw_info);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, draw_info);
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ check_references(group, draw_info);
+ }
+ }
+#endif
+}
+
+void LLPipeline::checkReferences(LLSpatialGroup* group)
+{
+#if 0
+ if (sCull)
+ {
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ if (group == *iter)
+ {
+ llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginAlphaGroups(); iter != sCull->endAlphaGroups(); ++iter)
+ {
+ if (group == *iter)
+ {
+ llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter)
+ {
+ if (group == *iter)
+ {
+ llerrs << "LLSpatialGroup deleted while actively referenced by LLPipeline." << llendl;
+ }
+ }
+ }
+#endif
+}
+
+
+BOOL LLPipeline::visibleObjectsInFrustum(LLCamera& camera)
+{
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ if (hasRenderType(part->mDrawableType))
+ {
+ if (part->visibleObjectsInFrustum(camera))
+ {
+ return TRUE;
+ }
+ }
+ }
+ }
+ }
+
+ return FALSE;
+}
+
+BOOL LLPipeline::getVisibleExtents(LLCamera& camera, LLVector3& min, LLVector3& max)
+{
+ const F32 X = 65536.f;
+
+ min = LLVector3(X,X,X);
+ max = LLVector3(-X,-X,-X);
+
+ U32 saved_camera_id = LLViewerCamera::sCurCameraID;
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WORLD;
+
+ BOOL res = TRUE;
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ if (hasRenderType(part->mDrawableType))
+ {
+ if (!part->getVisibleExtents(camera, min, max))
+ {
+ res = FALSE;
+ }
+ }
+ }
+ }
+ }
+
+ LLViewerCamera::sCurCameraID = saved_camera_id;
+
+ return res;
+}
+
+static LLFastTimer::DeclareTimer FTM_CULL("Object Culling");
+
+void LLPipeline::updateCull(LLCamera& camera, LLCullResult& result, S32 water_clip)
+{
+ LLFastTimer t(FTM_CULL);
+ LLMemType mt_uc(LLMemType::MTYPE_PIPELINE_UPDATE_CULL);
+
+ grabReferences(result);
+
+ sCull->clear();
+
+ BOOL to_texture = LLPipeline::sUseOcclusion > 1 &&
+ !hasRenderType(LLPipeline::RENDER_TYPE_HUD) &&
+ LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD &&
+ gPipeline.canUseVertexShaders() &&
+ sRenderGlow;
+
+ if (to_texture)
+ {
+ mScreen.bindTarget();
+ }
+
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadMatrixd(gGLLastProjection);
+ glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLLastModelView);
+
+
+ LLVertexBuffer::unbind();
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+
+ if (sUseOcclusion > 1)
+ {
+ gGL.setColorMask(false, false);
+ }
+
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE);
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ if (water_clip != 0)
+ {
+ LLPlane plane(LLVector3(0,0, (F32) -water_clip), (F32) water_clip*region->getWaterHeight());
+ camera.setUserClipPlane(plane);
+ }
+ else
+ {
+ camera.disableUserClipPlane();
+ }
+
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ if (hasRenderType(part->mDrawableType))
+ {
+ part->cull(camera);
+ }
+ }
+ }
+ }
+
+ camera.disableUserClipPlane();
+
+ if (hasRenderType(LLPipeline::RENDER_TYPE_SKY) &&
+ gSky.mVOSkyp.notNull() &&
+ gSky.mVOSkyp->mDrawable.notNull())
+ {
+ gSky.mVOSkyp->mDrawable->setVisible(camera);
+ sCull->pushDrawable(gSky.mVOSkyp->mDrawable);
+ gSky.updateCull();
+ stop_glerror();
+ }
+
+ if (hasRenderType(LLPipeline::RENDER_TYPE_GROUND) &&
+ !gPipeline.canUseWindLightShaders() &&
+ gSky.mVOGroundp.notNull() &&
+ gSky.mVOGroundp->mDrawable.notNull() &&
+ !LLPipeline::sWaterReflections)
+ {
+ gSky.mVOGroundp->mDrawable->setVisible(camera);
+ sCull->pushDrawable(gSky.mVOGroundp->mDrawable);
+ }
+
+
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+
+ if (sUseOcclusion > 1)
+ {
+ gGL.setColorMask(true, false);
+ }
+
+ if (to_texture)
+ {
+ mScreen.flush();
+ }
+}
+
+void LLPipeline::markNotCulled(LLSpatialGroup* group, LLCamera& camera)
+{
+ if (group->getData().empty())
+ {
+ return;
+ }
+
+ group->setVisible();
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ {
+ group->updateDistance(camera);
+ }
+
+ const F32 MINIMUM_PIXEL_AREA = 16.f;
+
+ if (group->mPixelArea < MINIMUM_PIXEL_AREA)
+ {
+ return;
+ }
+
+ if (sMinRenderSize > 0.f &&
+ llmax(llmax(group->mBounds[1][0], group->mBounds[1][1]), group->mBounds[1][2]) < sMinRenderSize)
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ if (!group->mSpatialPartition->mRenderByGroup)
+ { //render by drawable
+ sCull->pushDrawableGroup(group);
+ }
+ else
+ { //render by group
+ sCull->pushVisibleGroup(group);
+ }
+
+ mNumVisibleNodes++;
+}
+
+void LLPipeline::markOccluder(LLSpatialGroup* group)
+{
+ if (sUseOcclusion > 1 && group && !group->isOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION))
+ {
+ LLSpatialGroup* parent = group->getParent();
+
+ if (!parent || !parent->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ { //only mark top most occluders as active occlusion
+ sCull->pushOcclusionGroup(group);
+ group->setOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION);
+
+ if (parent &&
+ !parent->isOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION) &&
+ parent->getElementCount() == 0 &&
+ parent->needsUpdate())
+ {
+ sCull->pushOcclusionGroup(group);
+ parent->setOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION);
+ }
+ }
+ }
+}
+
+void LLPipeline::doOcclusion(LLCamera& camera)
+{
+ if (LLPipeline::sUseOcclusion > 1 && sCull->hasOcclusionGroups())
+ {
+ LLVertexBuffer::unbind();
+
+ if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_OCCLUSION))
+ {
+ gGL.setColorMask(true, false, false, false);
+ }
+ else
+ {
+ gGL.setColorMask(false, false);
+ }
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE);
+
+ LLGLDisable cull(GL_CULL_FACE);
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginOcclusionGroups(); iter != sCull->endOcclusionGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ group->doOcclusion(&camera);
+ group->clearOcclusionState(LLSpatialGroup::ACTIVE_OCCLUSION);
+ }
+
+ gGL.setColorMask(true, false);
+ }
+}
+
+BOOL LLPipeline::updateDrawableGeom(LLDrawable* drawablep, BOOL priority)
+{
+ BOOL update_complete = drawablep->updateGeometry(priority);
+ if (update_complete && assertInitialized())
+ {
+ drawablep->setState(LLDrawable::BUILT);
+ mGeometryChanges++;
+ }
+ return update_complete;
+}
+
+void LLPipeline::updateGL()
+{
+ while (!LLGLUpdate::sGLQ.empty())
+ {
+ LLGLUpdate* glu = LLGLUpdate::sGLQ.front();
+ glu->updateGL();
+ glu->mInQ = FALSE;
+ LLGLUpdate::sGLQ.pop_front();
+ }
+}
+
+void LLPipeline::rebuildPriorityGroups()
+{
+ LLTimer update_timer;
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+
+ assertInitialized();
+
+ gMeshRepo.notifyLoadedMeshes();
+
+ mGroupQ1Locked = true;
+ // Iterate through all drawables on the priority build queue,
+ for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ1.begin();
+ iter != mGroupQ1.end(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ group->rebuildGeom();
+ group->clearState(LLSpatialGroup::IN_BUILD_Q1);
+ }
+
+ mGroupQ1.clear();
+ mGroupQ1Locked = false;
+
+}
+
+void LLPipeline::rebuildGroups()
+{
+ if (mGroupQ2.empty())
+ {
+ return;
+ }
+
+ mGroupQ2Locked = true;
+ // Iterate through some drawables on the non-priority build queue
+ S32 size = (S32) mGroupQ2.size();
+ S32 min_count = llclamp((S32) ((F32) (size * size)/4096*0.25f), 1, size);
+
+ S32 count = 0;
+
+ std::sort(mGroupQ2.begin(), mGroupQ2.end(), LLSpatialGroup::CompareUpdateUrgency());
+
+ LLSpatialGroup::sg_vector_t::iterator iter;
+ LLSpatialGroup::sg_vector_t::iterator last_iter = mGroupQ2.begin();
+
+ for (iter = mGroupQ2.begin();
+ iter != mGroupQ2.end() && count <= min_count; ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ last_iter = iter;
+
+ if (!group->isDead())
+ {
+ group->rebuildGeom();
+
+ if (group->mSpatialPartition->mRenderByGroup)
+ {
+ count++;
+ }
+ }
+
+ group->clearState(LLSpatialGroup::IN_BUILD_Q2);
+ }
+
+ mGroupQ2.erase(mGroupQ2.begin(), ++last_iter);
+
+ mGroupQ2Locked = false;
+
+ updateMovedList(mMovedBridge);
+}
+
+void LLPipeline::updateGeom(F32 max_dtime)
+{
+ LLTimer update_timer;
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_UPDATE_GEOM);
+ LLPointer<LLDrawable> drawablep;
+
+ LLFastTimer t(FTM_GEO_UPDATE);
+
+ assertInitialized();
+
+ if (sDelayedVBOEnable > 0)
+ {
+ if (--sDelayedVBOEnable <= 0)
+ {
+ resetVertexBuffers();
+ LLVertexBuffer::sEnableVBOs = TRUE;
+ }
+ }
+
+ // notify various object types to reset internal cost metrics, etc.
+ // for now, only LLVOVolume does this to throttle LOD changes
+ LLVOVolume::preUpdateGeom();
+
+ // Iterate through all drawables on the priority build queue,
+ for (LLDrawable::drawable_list_t::iterator iter = mBuildQ1.begin();
+ iter != mBuildQ1.end();)
+ {
+ LLDrawable::drawable_list_t::iterator curiter = iter++;
+ LLDrawable* drawablep = *curiter;
+ if (drawablep && !drawablep->isDead())
+ {
+ if (drawablep->isState(LLDrawable::IN_REBUILD_Q2))
+ {
+ drawablep->clearState(LLDrawable::IN_REBUILD_Q2);
+ LLDrawable::drawable_list_t::iterator find = std::find(mBuildQ2.begin(), mBuildQ2.end(), drawablep);
+ if (find != mBuildQ2.end())
+ {
+ mBuildQ2.erase(find);
+ }
+ }
+
+ if (updateDrawableGeom(drawablep, TRUE))
+ {
+ drawablep->clearState(LLDrawable::IN_REBUILD_Q1);
+ mBuildQ1.erase(curiter);
+ }
+ }
+ else
+ {
+ mBuildQ1.erase(curiter);
+ }
+ }
+
+ // Iterate through some drawables on the non-priority build queue
+ S32 min_count = 16;
+ S32 size = (S32) mBuildQ2.size();
+ if (size > 1024)
+ {
+ min_count = llclamp((S32) (size * (F32) size/4096), 16, size);
+ }
+
+ S32 count = 0;
+
+ max_dtime = llmax(update_timer.getElapsedTimeF32()+0.001f, max_dtime);
+ LLSpatialGroup* last_group = NULL;
+ LLSpatialBridge* last_bridge = NULL;
+
+ for (LLDrawable::drawable_list_t::iterator iter = mBuildQ2.begin();
+ iter != mBuildQ2.end(); )
+ {
+ LLDrawable::drawable_list_t::iterator curiter = iter++;
+ LLDrawable* drawablep = *curiter;
+
+ LLSpatialBridge* bridge = drawablep->isRoot() ? drawablep->getSpatialBridge() :
+ drawablep->getParent()->getSpatialBridge();
+
+ if (drawablep->getSpatialGroup() != last_group &&
+ (!last_bridge || bridge != last_bridge) &&
+ (update_timer.getElapsedTimeF32() >= max_dtime) && count > min_count)
+ {
+ break;
+ }
+
+ //make sure updates don't stop in the middle of a spatial group
+ //to avoid thrashing (objects are enqueued by group)
+ last_group = drawablep->getSpatialGroup();
+ last_bridge = bridge;
+
+ BOOL update_complete = TRUE;
+ if (!drawablep->isDead())
+ {
+ update_complete = updateDrawableGeom(drawablep, FALSE);
+ count++;
+ }
+ if (update_complete)
+ {
+ drawablep->clearState(LLDrawable::IN_REBUILD_Q2);
+ mBuildQ2.erase(curiter);
+ }
+ }
+
+ updateMovedList(mMovedBridge);
+}
+
+void LLPipeline::markVisible(LLDrawable *drawablep, LLCamera& camera)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_VISIBLE);
+
+ if(drawablep && !drawablep->isDead())
+ {
+ if (drawablep->isSpatialBridge())
+ {
+ const LLDrawable* root = ((LLSpatialBridge*) drawablep)->mDrawable;
+ llassert(root); // trying to catch a bad assumption
+ if (root && // // this test may not be needed, see above
+ root->getVObj()->isAttachment())
+ {
+ LLDrawable* rootparent = root->getParent();
+ if (rootparent) // this IS sometimes NULL
+ {
+ LLViewerObject *vobj = rootparent->getVObj();
+ llassert(vobj); // trying to catch a bad assumption
+ if (vobj) // this test may not be needed, see above
+ {
+ const LLVOAvatar* av = vobj->asAvatar();
+ if (av && av->isImpostor())
+ {
+ return;
+ }
+ }
+ }
+ }
+ sCull->pushBridge((LLSpatialBridge*) drawablep);
+ }
+ else
+ {
+ sCull->pushDrawable(drawablep);
+ }
+
+ drawablep->setVisible(camera);
+ }
+}
+
+void LLPipeline::markMoved(LLDrawable *drawablep, BOOL damped_motion)
+{
+ LLMemType mt_mm(LLMemType::MTYPE_PIPELINE_MARK_MOVED);
+
+ if (!drawablep)
+ {
+ //llerrs << "Sending null drawable to moved list!" << llendl;
+ return;
+ }
+
+ if (drawablep->isDead())
+ {
+ llwarns << "Marking NULL or dead drawable moved!" << llendl;
+ return;
+ }
+
+ if (drawablep->getParent())
+ {
+ //ensure that parent drawables are moved first
+ markMoved(drawablep->getParent(), damped_motion);
+ }
+
+ assertInitialized();
+
+ if (!drawablep->isState(LLDrawable::ON_MOVE_LIST))
+ {
+ if (drawablep->isSpatialBridge())
+ {
+ mMovedBridge.push_back(drawablep);
+ }
+ else
+ {
+ mMovedList.push_back(drawablep);
+ }
+ drawablep->setState(LLDrawable::ON_MOVE_LIST);
+ }
+ if (damped_motion == FALSE)
+ {
+ drawablep->setState(LLDrawable::MOVE_UNDAMPED); // UNDAMPED trumps DAMPED
+ }
+ else if (drawablep->isState(LLDrawable::MOVE_UNDAMPED))
+ {
+ drawablep->clearState(LLDrawable::MOVE_UNDAMPED);
+ }
+}
+
+void LLPipeline::markShift(LLDrawable *drawablep)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_SHIFT);
+
+ if (!drawablep || drawablep->isDead())
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ if (!drawablep->isState(LLDrawable::ON_SHIFT_LIST))
+ {
+ drawablep->getVObj()->setChanged(LLXform::SHIFTED | LLXform::SILHOUETTE);
+ if (drawablep->getParent())
+ {
+ markShift(drawablep->getParent());
+ }
+ mShiftList.push_back(drawablep);
+ drawablep->setState(LLDrawable::ON_SHIFT_LIST);
+ }
+}
+
+void LLPipeline::shiftObjects(const LLVector3 &offset)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_SHIFT_OBJECTS);
+
+ assertInitialized();
+
+ glClear(GL_DEPTH_BUFFER_BIT);
+ gDepthDirty = TRUE;
+
+ LLVector4a offseta;
+ offseta.load3(offset.mV);
+
+ for (LLDrawable::drawable_vector_t::iterator iter = mShiftList.begin();
+ iter != mShiftList.end(); iter++)
+ {
+ LLDrawable *drawablep = *iter;
+ if (drawablep->isDead())
+ {
+ continue;
+ }
+ drawablep->shiftPos(offseta);
+ drawablep->clearState(LLDrawable::ON_SHIFT_LIST);
+ }
+ mShiftList.resize(0);
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ part->shift(offseta);
+ }
+ }
+ }
+
+ LLHUDText::shiftAll(offset);
+ LLHUDNameTag::shiftAll(offset);
+ display_update_camera();
+}
+
+void LLPipeline::markTextured(LLDrawable *drawablep)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_TEXTURED);
+
+ if (drawablep && !drawablep->isDead() && assertInitialized())
+ {
+ mRetexturedList.insert(drawablep);
+ }
+}
+
+void LLPipeline::markGLRebuild(LLGLUpdate* glu)
+{
+ if (glu && !glu->mInQ)
+ {
+ LLGLUpdate::sGLQ.push_back(glu);
+ glu->mInQ = TRUE;
+ }
+}
+
+void LLPipeline::markRebuild(LLSpatialGroup* group, BOOL priority)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+
+ if (group && !group->isDead() && group->mSpatialPartition)
+ {
+ if (group->mSpatialPartition->mPartitionType == LLViewerRegion::PARTITION_HUD)
+ {
+ priority = TRUE;
+ }
+
+ if (priority)
+ {
+ if (!group->isState(LLSpatialGroup::IN_BUILD_Q1))
+ {
+ llassert_always(!mGroupQ1Locked);
+
+ mGroupQ1.push_back(group);
+ group->setState(LLSpatialGroup::IN_BUILD_Q1);
+
+ if (group->isState(LLSpatialGroup::IN_BUILD_Q2))
+ {
+ LLSpatialGroup::sg_vector_t::iterator iter = std::find(mGroupQ2.begin(), mGroupQ2.end(), group);
+ if (iter != mGroupQ2.end())
+ {
+ mGroupQ2.erase(iter);
+ }
+ group->clearState(LLSpatialGroup::IN_BUILD_Q2);
+ }
+ }
+ }
+ else if (!group->isState(LLSpatialGroup::IN_BUILD_Q2 | LLSpatialGroup::IN_BUILD_Q1))
+ {
+ llassert_always(!mGroupQ2Locked);
+ mGroupQ2.push_back(group);
+ group->setState(LLSpatialGroup::IN_BUILD_Q2);
+
+ }
+ }
+}
+
+void LLPipeline::markRebuild(LLDrawable *drawablep, LLDrawable::EDrawableFlags flag, BOOL priority)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_MARK_REBUILD);
+
+ if (drawablep && !drawablep->isDead() && assertInitialized())
+ {
+ if (!drawablep->isState(LLDrawable::BUILT))
+ {
+ priority = TRUE;
+ }
+ if (priority)
+ {
+ if (!drawablep->isState(LLDrawable::IN_REBUILD_Q1))
+ {
+ mBuildQ1.push_back(drawablep);
+ drawablep->setState(LLDrawable::IN_REBUILD_Q1); // mark drawable as being in priority queue
+ }
+ }
+ else if (!drawablep->isState(LLDrawable::IN_REBUILD_Q2))
+ {
+ mBuildQ2.push_back(drawablep);
+ drawablep->setState(LLDrawable::IN_REBUILD_Q2); // need flag here because it is just a list
+ }
+ if (flag & (LLDrawable::REBUILD_VOLUME | LLDrawable::REBUILD_POSITION))
+ {
+ drawablep->getVObj()->setChanged(LLXform::SILHOUETTE);
+ }
+ drawablep->setState(flag);
+ }
+}
+
+static LLFastTimer::DeclareTimer FTM_RESET_DRAWORDER("Reset Draw Order");
+
+void LLPipeline::stateSort(LLCamera& camera, LLCullResult &result)
+{
+ if (hasAnyRenderType(LLPipeline::RENDER_TYPE_AVATAR,
+ LLPipeline::RENDER_TYPE_GROUND,
+ LLPipeline::RENDER_TYPE_TERRAIN,
+ LLPipeline::RENDER_TYPE_TREE,
+ LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_VOIDWATER,
+ LLPipeline::RENDER_TYPE_WATER,
+ LLPipeline::END_RENDER_TYPES))
+ {
+ //clear faces from face pools
+ LLFastTimer t(FTM_RESET_DRAWORDER);
+ gPipeline.resetDrawOrders();
+ }
+
+ LLFastTimer ftm(FTM_STATESORT);
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT);
+
+ //LLVertexBuffer::unbind();
+
+ grabReferences(result);
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginDrawableGroups(); iter != sCull->endDrawableGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ group->checkOcclusion();
+ if (sUseOcclusion > 1 && group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ markOccluder(group);
+ }
+ else
+ {
+ group->setVisible();
+ for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i)
+ {
+ markVisible(*i, camera);
+ }
+ }
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ {
+ LLSpatialGroup* last_group = NULL;
+ for (LLCullResult::bridge_list_t::iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i)
+ {
+ LLCullResult::bridge_list_t::iterator cur_iter = i;
+ LLSpatialBridge* bridge = *cur_iter;
+ LLSpatialGroup* group = bridge->getSpatialGroup();
+
+ if (last_group == NULL)
+ {
+ last_group = group;
+ }
+
+ if (!bridge->isDead() && group && !group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ stateSort(bridge, camera);
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD &&
+ last_group != group && last_group->changeLOD())
+ {
+ last_group->mLastUpdateDistance = last_group->mDistance;
+ }
+
+ last_group = group;
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD &&
+ last_group && last_group->changeLOD())
+ {
+ last_group->mLastUpdateDistance = last_group->mDistance;
+ }
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ group->checkOcclusion();
+ if (sUseOcclusion > 1 && group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ markOccluder(group);
+ }
+ else
+ {
+ group->setVisible();
+ stateSort(group, camera);
+ }
+ }
+
+ {
+ LLFastTimer ftm(FTM_STATESORT_DRAWABLE);
+ for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList();
+ iter != sCull->endVisibleList(); ++iter)
+ {
+ LLDrawable *drawablep = *iter;
+ if (!drawablep->isDead())
+ {
+ stateSort(drawablep, camera);
+ }
+ }
+ }
+ {
+ LLFastTimer ftm(FTM_CLIENT_COPY);
+ LLVertexBuffer::clientCopy();
+ }
+
+ postSort(camera);
+}
+
+void LLPipeline::stateSort(LLSpatialGroup* group, LLCamera& camera)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT);
+ if (group->changeLOD())
+ {
+ for (LLSpatialGroup::element_iter i = group->getData().begin(); i != group->getData().end(); ++i)
+ {
+ LLDrawable* drawablep = *i;
+ stateSort(drawablep, camera);
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ { //avoid redundant stateSort calls
+ group->mLastUpdateDistance = group->mDistance;
+ }
+ }
+
+}
+
+void LLPipeline::stateSort(LLSpatialBridge* bridge, LLCamera& camera)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT);
+ if (bridge->getSpatialGroup()->changeLOD())
+ {
+ bool force_update = false;
+ bridge->updateDistance(camera, force_update);
+ }
+}
+
+void LLPipeline::stateSort(LLDrawable* drawablep, LLCamera& camera)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_STATE_SORT);
+
+ if (!drawablep
+ || drawablep->isDead()
+ || !hasRenderType(drawablep->getRenderType()))
+ {
+ return;
+ }
+
+ if (LLSelectMgr::getInstance()->mHideSelectedObjects)
+ {
+ if (drawablep->getVObj().notNull() &&
+ drawablep->getVObj()->isSelected())
+ {
+ return;
+ }
+ }
+
+ if (drawablep->isAvatar())
+ { //don't draw avatars beyond render distance or if we don't have a spatial group.
+ if ((drawablep->getSpatialGroup() == NULL) ||
+ (drawablep->getSpatialGroup()->mDistance > LLVOAvatar::sRenderDistance))
+ {
+ return;
+ }
+
+ LLVOAvatar* avatarp = (LLVOAvatar*) drawablep->getVObj().get();
+ if (!avatarp->isVisible())
+ {
+ return;
+ }
+ }
+
+ assertInitialized();
+
+ if (hasRenderType(drawablep->mRenderType))
+ {
+ if (!drawablep->isState(LLDrawable::INVISIBLE|LLDrawable::FORCE_INVISIBLE))
+ {
+ drawablep->setVisible(camera, NULL, FALSE);
+ }
+ else if (drawablep->isState(LLDrawable::CLEAR_INVISIBLE))
+ {
+ // clear invisible flag here to avoid single frame glitch
+ drawablep->clearState(LLDrawable::FORCE_INVISIBLE|LLDrawable::CLEAR_INVISIBLE);
+ }
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ {
+ //if (drawablep->isVisible()) isVisible() check here is redundant, if it wasn't visible, it wouldn't be here
+ {
+ if (!drawablep->isActive())
+ {
+ bool force_update = false;
+ drawablep->updateDistance(camera, force_update);
+ }
+ else if (drawablep->isAvatar())
+ {
+ bool force_update = false;
+ drawablep->updateDistance(camera, force_update); // calls vobj->updateLOD() which calls LLVOAvatar::updateVisibility()
+ }
+ }
+ }
+
+ if (!drawablep->getVOVolume())
+ {
+ for (LLDrawable::face_list_t::iterator iter = drawablep->mFaces.begin();
+ iter != drawablep->mFaces.end(); iter++)
+ {
+ LLFace* facep = *iter;
+
+ if (facep->hasGeometry())
+ {
+ if (facep->getPool())
+ {
+ facep->getPool()->enqueue(facep);
+ }
+ else
+ {
+ break;
+ }
+ }
+ }
+ }
+
+
+ mNumVisibleFaces += drawablep->getNumFaces();
+}
+
+
+void forAllDrawables(LLCullResult::sg_list_t::iterator begin,
+ LLCullResult::sg_list_t::iterator end,
+ void (*func)(LLDrawable*))
+{
+ for (LLCullResult::sg_list_t::iterator i = begin; i != end; ++i)
+ {
+ for (LLSpatialGroup::element_iter j = (*i)->getData().begin(); j != (*i)->getData().end(); ++j)
+ {
+ func(*j);
+ }
+ }
+}
+
+void LLPipeline::forAllVisibleDrawables(void (*func)(LLDrawable*))
+{
+ forAllDrawables(sCull->beginDrawableGroups(), sCull->endDrawableGroups(), func);
+ forAllDrawables(sCull->beginVisibleGroups(), sCull->endVisibleGroups(), func);
+}
+
+//function for creating scripted beacons
+void renderScriptedBeacons(LLDrawable* drawablep)
+{
+ LLViewerObject *vobj = drawablep->getVObj();
+ if (vobj
+ && !vobj->isAvatar()
+ && !vobj->getParent()
+ && vobj->flagScripted())
+ {
+ if (gPipeline.sRenderBeacons)
+ {
+ gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(1.f, 0.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth"));
+ }
+
+ if (gPipeline.sRenderHighlight)
+ {
+ S32 face_id;
+ S32 count = drawablep->getNumFaces();
+ for (face_id = 0; face_id < count; face_id++)
+ {
+ gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) );
+ }
+ }
+ }
+}
+
+void renderScriptedTouchBeacons(LLDrawable* drawablep)
+{
+ LLViewerObject *vobj = drawablep->getVObj();
+ if (vobj
+ && !vobj->isAvatar()
+ && !vobj->getParent()
+ && vobj->flagScripted()
+ && vobj->flagHandleTouch())
+ {
+ if (gPipeline.sRenderBeacons)
+ {
+ gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(1.f, 0.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth"));
+ }
+
+ if (gPipeline.sRenderHighlight)
+ {
+ S32 face_id;
+ S32 count = drawablep->getNumFaces();
+ for (face_id = 0; face_id < count; face_id++)
+ {
+ gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) );
+ }
+ }
+ }
+}
+
+void renderPhysicalBeacons(LLDrawable* drawablep)
+{
+ LLViewerObject *vobj = drawablep->getVObj();
+ if (vobj
+ && !vobj->isAvatar()
+ //&& !vobj->getParent()
+ && vobj->usePhysics())
+ {
+ if (gPipeline.sRenderBeacons)
+ {
+ gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", LLColor4(0.f, 1.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth"));
+ }
+
+ if (gPipeline.sRenderHighlight)
+ {
+ S32 face_id;
+ S32 count = drawablep->getNumFaces();
+ for (face_id = 0; face_id < count; face_id++)
+ {
+ gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) );
+ }
+ }
+ }
+}
+
+void renderParticleBeacons(LLDrawable* drawablep)
+{
+ // Look for attachments, objects, etc.
+ LLViewerObject *vobj = drawablep->getVObj();
+ if (vobj
+ && vobj->isParticleSource())
+ {
+ if (gPipeline.sRenderBeacons)
+ {
+ LLColor4 light_blue(0.5f, 0.5f, 1.f, 0.5f);
+ gObjectList.addDebugBeacon(vobj->getPositionAgent(), "", light_blue, LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth"));
+ }
+
+ if (gPipeline.sRenderHighlight)
+ {
+ S32 face_id;
+ S32 count = drawablep->getNumFaces();
+ for (face_id = 0; face_id < count; face_id++)
+ {
+ gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) );
+ }
+ }
+ }
+}
+
+void renderSoundHighlights(LLDrawable* drawablep)
+{
+ // Look for attachments, objects, etc.
+ LLViewerObject *vobj = drawablep->getVObj();
+ if (vobj && vobj->isAudioSource())
+ {
+ if (gPipeline.sRenderHighlight)
+ {
+ S32 face_id;
+ S32 count = drawablep->getNumFaces();
+ for (face_id = 0; face_id < count; face_id++)
+ {
+ gPipeline.mHighlightFaces.push_back(drawablep->getFace(face_id) );
+ }
+ }
+ }
+}
+
+void LLPipeline::postSort(LLCamera& camera)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_POST_SORT);
+ LLFastTimer ftm(FTM_STATESORT_POSTSORT);
+
+ assertInitialized();
+
+ llpushcallstacks ;
+ //rebuild drawable geometry
+ for (LLCullResult::sg_list_t::iterator i = sCull->beginDrawableGroups(); i != sCull->endDrawableGroups(); ++i)
+ {
+ LLSpatialGroup* group = *i;
+ if (!sUseOcclusion ||
+ !group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ group->rebuildGeom();
+ }
+ }
+ llpushcallstacks ;
+ //rebuild groups
+ sCull->assertDrawMapsEmpty();
+
+ rebuildPriorityGroups();
+ llpushcallstacks ;
+
+ const S32 bin_count = 1024*8;
+
+ static LLCullResult::drawinfo_list_t alpha_bins[bin_count];
+ static U32 bin_size[bin_count];
+
+ //clear one bin per frame to avoid memory bloat
+ static S32 clear_idx = 0;
+ clear_idx = (1+clear_idx)%bin_count;
+ alpha_bins[clear_idx].clear();
+
+ for (U32 j = 0; j < bin_count; j++)
+ {
+ bin_size[j] = 0;
+ }
+
+ //build render map
+ for (LLCullResult::sg_list_t::iterator i = sCull->beginVisibleGroups(); i != sCull->endVisibleGroups(); ++i)
+ {
+ LLSpatialGroup* group = *i;
+ if (sUseOcclusion &&
+ group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ continue;
+ }
+
+ if (group->isState(LLSpatialGroup::NEW_DRAWINFO) && group->isState(LLSpatialGroup::GEOM_DIRTY))
+ { //no way this group is going to be drawable without a rebuild
+ group->rebuildGeom();
+ }
+
+ for (LLSpatialGroup::draw_map_t::iterator j = group->mDrawMap.begin(); j != group->mDrawMap.end(); ++j)
+ {
+ LLSpatialGroup::drawmap_elem_t& src_vec = j->second;
+ if (!hasRenderType(j->first))
+ {
+ continue;
+ }
+
+ for (LLSpatialGroup::drawmap_elem_t::iterator k = src_vec.begin(); k != src_vec.end(); ++k)
+ {
+ if (sMinRenderSize > 0.f)
+ {
+ LLVector4a bounds;
+ bounds.setSub((*k)->mExtents[1],(*k)->mExtents[0]);
+
+ if (llmax(llmax(bounds[0], bounds[1]), bounds[2]) > sMinRenderSize)
+ {
+ sCull->pushDrawInfo(j->first, *k);
+ }
+ }
+ else
+ {
+ sCull->pushDrawInfo(j->first, *k);
+ }
+ }
+ }
+
+ if (hasRenderType(LLPipeline::RENDER_TYPE_PASS_ALPHA))
+ {
+ LLSpatialGroup::draw_map_t::iterator alpha = group->mDrawMap.find(LLRenderPass::PASS_ALPHA);
+
+ if (alpha != group->mDrawMap.end())
+ { //store alpha groups for sorting
+ LLSpatialBridge* bridge = group->mSpatialPartition->asBridge();
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ {
+ if (bridge)
+ {
+ LLCamera trans_camera = bridge->transformCamera(camera);
+ group->updateDistance(trans_camera);
+ }
+ else
+ {
+ group->updateDistance(camera);
+ }
+ }
+
+ if (hasRenderType(LLDrawPool::POOL_ALPHA))
+ {
+ sCull->pushAlphaGroup(group);
+ }
+ }
+ }
+ }
+
+ if (!sShadowRender)
+ {
+ //sort by texture or bump map
+ for (U32 i = 0; i < LLRenderPass::NUM_RENDER_TYPES; ++i)
+ {
+ if (i == LLRenderPass::PASS_BUMP)
+ {
+ std::sort(sCull->beginRenderMap(i), sCull->endRenderMap(i), LLDrawInfo::CompareBump());
+ }
+ else
+ {
+ std::sort(sCull->beginRenderMap(i), sCull->endRenderMap(i), LLDrawInfo::CompareTexturePtrMatrix());
+ }
+ }
+
+ std::sort(sCull->beginAlphaGroups(), sCull->endAlphaGroups(), LLSpatialGroup::CompareDepthGreater());
+ }
+ llpushcallstacks ;
+ // only render if the flag is set. The flag is only set if we are in edit mode or the toggle is set in the menus
+ if (LLFloaterReg::instanceVisible("beacons") && !sShadowRender)
+ {
+ if (sRenderScriptedTouchBeacons)
+ {
+ // Only show the beacon on the root object.
+ forAllVisibleDrawables(renderScriptedTouchBeacons);
+ }
+ else
+ if (sRenderScriptedBeacons)
+ {
+ // Only show the beacon on the root object.
+ forAllVisibleDrawables(renderScriptedBeacons);
+ }
+
+ if (sRenderPhysicalBeacons)
+ {
+ // Only show the beacon on the root object.
+ forAllVisibleDrawables(renderPhysicalBeacons);
+ }
+
+ if (sRenderParticleBeacons)
+ {
+ forAllVisibleDrawables(renderParticleBeacons);
+ }
+
+ // If god mode, also show audio cues
+ if (sRenderSoundBeacons && gAudiop)
+ {
+ // Walk all sound sources and render out beacons for them. Note, this isn't done in the ForAllVisibleDrawables function, because some are not visible.
+ LLAudioEngine::source_map::iterator iter;
+ for (iter = gAudiop->mAllSources.begin(); iter != gAudiop->mAllSources.end(); ++iter)
+ {
+ LLAudioSource *sourcep = iter->second;
+
+ LLVector3d pos_global = sourcep->getPositionGlobal();
+ LLVector3 pos = gAgent.getPosAgentFromGlobal(pos_global);
+ if (gPipeline.sRenderBeacons)
+ {
+ //pos += LLVector3(0.f, 0.f, 0.2f);
+ gObjectList.addDebugBeacon(pos, "", LLColor4(1.f, 1.f, 0.f, 0.5f), LLColor4(1.f, 1.f, 1.f, 0.5f), gSavedSettings.getS32("DebugBeaconLineWidth"));
+ }
+ }
+ // now deal with highlights for all those seeable sound sources
+ forAllVisibleDrawables(renderSoundHighlights);
+ }
+ }
+ llpushcallstacks ;
+ // If managing your telehub, draw beacons at telehub and currently selected spawnpoint.
+ if (LLFloaterTelehub::renderBeacons())
+ {
+ LLFloaterTelehub::addBeacons();
+ }
+
+ if (!sShadowRender)
+ {
+ mSelectedFaces.clear();
+
+ // Draw face highlights for selected faces.
+ if (LLSelectMgr::getInstance()->getTEMode())
+ {
+ struct f : public LLSelectedTEFunctor
+ {
+ virtual bool apply(LLViewerObject* object, S32 te)
+ {
+ if (object->mDrawable)
+ {
+ gPipeline.mSelectedFaces.push_back(object->mDrawable->getFace(te));
+ }
+ return true;
+ }
+ } func;
+ LLSelectMgr::getInstance()->getSelection()->applyToTEs(&func);
+ }
+ }
+
+ //LLSpatialGroup::sNoDelete = FALSE;
+ llpushcallstacks ;
+}
+
+
+void render_hud_elements()
+{
+ LLMemType mt_rhe(LLMemType::MTYPE_PIPELINE_RENDER_HUD_ELS);
+ LLFastTimer t(FTM_RENDER_UI);
+ gPipeline.disableLights();
+
+ LLGLDisable fog(GL_FOG);
+ LLGLSUIDefault gls_ui;
+
+ LLGLEnable stencil(GL_STENCIL_TEST);
+ glStencilFunc(GL_ALWAYS, 255, 0xFFFFFFFF);
+ glStencilMask(0xFFFFFFFF);
+ glStencilOp(GL_KEEP, GL_KEEP, GL_REPLACE);
+
+ gGL.color4f(1,1,1,1);
+ if (!LLPipeline::sReflectionRender && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI))
+ {
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+ gViewerWindow->renderSelections(FALSE, FALSE, FALSE); // For HUD version in render_ui_3d()
+
+ // Draw the tracking overlays
+ LLTracker::render3D();
+
+ // Show the property lines
+ LLWorld::getInstance()->renderPropertyLines();
+ LLViewerParcelMgr::getInstance()->render();
+ LLViewerParcelMgr::getInstance()->renderParcelCollision();
+
+ // Render name tags.
+ LLHUDObject::renderAll();
+ }
+ else if (gForceRenderLandFence)
+ {
+ // This is only set when not rendering the UI, for parcel snapshots
+ LLViewerParcelMgr::getInstance()->render();
+ }
+ else if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ LLHUDText::renderAllHUD();
+ }
+ gGL.flush();
+}
+
+void LLPipeline::renderHighlights()
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_RENDER_HL);
+
+ assertInitialized();
+
+ // Draw 3D UI elements here (before we clear the Z buffer in POOL_HUD)
+ // Render highlighted faces.
+ LLGLSPipelineAlpha gls_pipeline_alpha;
+ LLColor4 color(1.f, 1.f, 1.f, 0.5f);
+ LLGLEnable color_mat(GL_COLOR_MATERIAL);
+ disableLights();
+
+ if (!hasRenderType(LLPipeline::RENDER_TYPE_HUD) && !mHighlightSet.empty())
+ { //draw blurry highlight image over screen
+ LLGLEnable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS);
+ LLGLDisable test(GL_ALPHA_TEST);
+
+ LLGLEnable stencil(GL_STENCIL_TEST);
+ gGL.flush();
+ glStencilMask(0xFFFFFFFF);
+ glClearStencil(1);
+ glClear(GL_STENCIL_BUFFER_BIT);
+
+ glStencilFunc(GL_ALWAYS, 0, 0xFFFFFFFF);
+ glStencilOp(GL_REPLACE, GL_REPLACE, GL_REPLACE);
+
+ gGL.setColorMask(false, false);
+ for (std::set<HighlightItem>::iterator iter = mHighlightSet.begin(); iter != mHighlightSet.end(); ++iter)
+ {
+ renderHighlight(iter->mItem->getVObj(), 1.f);
+ }
+ gGL.setColorMask(true, false);
+
+ glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
+ glStencilFunc(GL_NOTEQUAL, 0, 0xFFFFFFFF);
+
+ //gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA);
+
+ gGL.pushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ gGL.pushMatrix();
+ glLoadIdentity();
+
+ gGL.getTexUnit(0)->bind(&mHighlight);
+
+ LLVector2 tc1;
+ LLVector2 tc2;
+
+ tc1.setVec(0,0);
+ tc2.setVec(2,2);
+
+ gGL.begin(LLRender::TRIANGLES);
+
+ F32 scale = gSavedSettings.getF32("RenderHighlightBrightness");
+ LLColor4 color = gSavedSettings.getColor4("RenderHighlightColor");
+ F32 thickness = gSavedSettings.getF32("RenderHighlightThickness");
+
+ for (S32 pass = 0; pass < 2; ++pass)
+ {
+ if (pass == 0)
+ {
+ gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA);
+ }
+ else
+ {
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+ }
+
+ for (S32 i = 0; i < 8; ++i)
+ {
+ for (S32 j = 0; j < 8; ++j)
+ {
+ LLVector2 tc(i-4+0.5f, j-4+0.5f);
+
+ F32 dist = 1.f-(tc.length()/sqrtf(32.f));
+ dist *= scale/64.f;
+
+ tc *= thickness;
+ tc.mV[0] = (tc.mV[0])/mHighlight.getWidth();
+ tc.mV[1] = (tc.mV[1])/mHighlight.getHeight();
+
+ gGL.color4f(color.mV[0],
+ color.mV[1],
+ color.mV[2],
+ color.mV[3]*dist);
+
+ gGL.texCoord2f(tc.mV[0]+tc1.mV[0], tc.mV[1]+tc2.mV[1]);
+ gGL.vertex2f(-1,3);
+
+ gGL.texCoord2f(tc.mV[0]+tc1.mV[0], tc.mV[1]+tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc.mV[0]+tc2.mV[0], tc.mV[1]+tc1.mV[1]);
+ gGL.vertex2f(3,-1);
+ }
+ }
+ }
+
+ gGL.end();
+
+ gGL.popMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ gGL.popMatrix();
+
+ //gGL.setSceneBlendType(LLRender::BT_ALPHA);
+ }
+
+ if ((LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0))
+ {
+ gHighlightProgram.bind();
+ gHighlightProgram.vertexAttrib4f(LLViewerShaderMgr::MATERIAL_COLOR,1,1,1,0.5f);
+ }
+
+ if (hasRenderDebugFeatureMask(RENDER_DEBUG_FEATURE_SELECTED))
+ {
+ // Make sure the selection image gets downloaded and decoded
+ if (!mFaceSelectImagep)
+ {
+ mFaceSelectImagep = LLViewerTextureManager::getFetchedTexture(IMG_FACE_SELECT);
+ }
+ mFaceSelectImagep->addTextureStats((F32)MAX_IMAGE_AREA);
+
+ U32 count = mSelectedFaces.size();
+ for (U32 i = 0; i < count; i++)
+ {
+ LLFace *facep = mSelectedFaces[i];
+ if (!facep || facep->getDrawable()->isDead())
+ {
+ llerrs << "Bad face on selection" << llendl;
+ return;
+ }
+
+ facep->renderSelected(mFaceSelectImagep, color);
+ }
+ }
+
+ if (hasRenderDebugFeatureMask(RENDER_DEBUG_FEATURE_SELECTED))
+ {
+ // Paint 'em red!
+ color.setVec(1.f, 0.f, 0.f, 0.5f);
+ if ((LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0))
+ {
+ gHighlightProgram.vertexAttrib4f(LLViewerShaderMgr::MATERIAL_COLOR,1,0,0,0.5f);
+ }
+ int count = mHighlightFaces.size();
+ for (S32 i = 0; i < count; i++)
+ {
+ LLFace* facep = mHighlightFaces[i];
+ facep->renderSelected(LLViewerTexture::sNullImagep, color);
+ }
+ }
+
+ // Contains a list of the faces of objects that are physical or
+ // have touch-handlers.
+ mHighlightFaces.clear();
+
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_INTERFACE) > 0)
+ {
+ gHighlightProgram.unbind();
+ }
+}
+
+//debug use
+U32 LLPipeline::sCurRenderPoolType = 0 ;
+
+void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_RENDER_GEOM);
+ LLFastTimer t(FTM_RENDER_GEOMETRY);
+
+ assertInitialized();
+
+ F64 saved_modelview[16];
+ F64 saved_projection[16];
+
+ //HACK: preserve/restore matrices around HUD render
+ if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ for (U32 i = 0; i < 16; i++)
+ {
+ saved_modelview[i] = gGLModelView[i];
+ saved_projection[i] = gGLProjection[i];
+ }
+ }
+
+ S32 stack_depth = 0;
+
+ if (gDebugGL)
+ {
+ glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &stack_depth);
+ }
+
+ ///////////////////////////////////////////
+ //
+ // Sync and verify GL state
+ //
+ //
+
+ stop_glerror();
+
+ LLVertexBuffer::unbind();
+
+ // Do verification of GL state
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+ if (mRenderDebugMask & RENDER_DEBUG_VERIFY)
+ {
+ if (!verify())
+ {
+ llerrs << "Pipeline verification failed!" << llendl;
+ }
+ }
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:ForceVBO");
+
+ // Initialize lots of GL state to "safe" values
+ glMatrixMode(GL_TEXTURE);
+ glLoadIdentity();
+ glMatrixMode(GL_MODELVIEW);
+
+ LLGLSPipeline gls_pipeline;
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+
+ LLGLState gls_color_material(GL_COLOR_MATERIAL, mLightingDetail < 2);
+
+ // Toggle backface culling for debugging
+ LLGLEnable cull_face(mBackfaceCull ? GL_CULL_FACE : 0);
+ // Set fog
+ BOOL use_fog = hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_FOG);
+ LLGLEnable fog_enable(use_fog &&
+ !gPipeline.canUseWindLightShadersOnObjects() ? GL_FOG : 0);
+ gSky.updateFog(camera.getFar());
+ if (!use_fog)
+ {
+ sUnderWaterRender = FALSE;
+ }
+
+ gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sDefaultImagep);
+ LLViewerFetchedTexture::sDefaultImagep->setAddressMode(LLTexUnit::TAM_WRAP);
+
+ //////////////////////////////////////////////
+ //
+ // Actually render all of the geometry
+ //
+ //
+ stop_glerror();
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPools");
+
+ for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter)
+ {
+ LLDrawPool *poolp = *iter;
+ if (hasRenderType(poolp->getType()))
+ {
+ poolp->prerender();
+ }
+ }
+
+ {
+ LLFastTimer t(FTM_POOLS);
+
+ // HACK: don't calculate local lights if we're rendering the HUD!
+ // Removing this check will cause bad flickering when there are
+ // HUD elements being rendered AND the user is in flycam mode -nyx
+ if (!gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ calcNearbyLights(camera);
+ setupHWLights(NULL);
+ }
+
+ BOOL occlude = sUseOcclusion > 1;
+ U32 cur_type = 0;
+
+ pool_set_t::iterator iter1 = mPools.begin();
+ while ( iter1 != mPools.end() )
+ {
+ LLDrawPool *poolp = *iter1;
+
+ cur_type = poolp->getType();
+
+ //debug use
+ sCurRenderPoolType = cur_type ;
+
+ if (occlude && cur_type >= LLDrawPool::POOL_GRASS)
+ {
+ occlude = FALSE;
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ doOcclusion(camera);
+ }
+
+ pool_set_t::iterator iter2 = iter1;
+ if (hasRenderType(poolp->getType()) && poolp->getNumPasses() > 0)
+ {
+ LLFastTimer t(FTM_POOLRENDER);
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ for( S32 i = 0; i < poolp->getNumPasses(); i++ )
+ {
+ LLVertexBuffer::unbind();
+ poolp->beginRenderPass(i);
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+
+ p->render(i);
+ }
+ poolp->endRenderPass(i);
+ LLVertexBuffer::unbind();
+ if (gDebugGL)
+ {
+ check_stack_depth(stack_depth);
+ std::string msg = llformat("%s pass %d", gPoolNames[cur_type].c_str(), i);
+ LLGLState::checkStates(msg);
+ LLGLState::checkTextureChannels(msg);
+ LLGLState::checkClientArrays(msg);
+ }
+ }
+ }
+ else
+ {
+ // Skip all pools of this type
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+ }
+ }
+ iter1 = iter2;
+ stop_glerror();
+ }
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPoolsEnd");
+
+ LLVertexBuffer::unbind();
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ if (occlude)
+ {
+ occlude = FALSE;
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ doOcclusion(camera);
+ }
+ }
+
+ LLVertexBuffer::unbind();
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+
+
+ stop_glerror();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderHighlights");
+
+ if (!sReflectionRender)
+ {
+ renderHighlights();
+ }
+
+ // Contains a list of the faces of objects that are physical or
+ // have touch-handlers.
+ mHighlightFaces.clear();
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDebug");
+
+ renderDebug();
+
+ LLVertexBuffer::unbind();
+
+ if (!LLPipeline::sReflectionRender && !LLPipeline::sRenderDeferred)
+ {
+ if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI))
+ {
+ // Render debugging beacons.
+ gObjectList.renderObjectBeacons();
+ gObjectList.resetObjectBeacons();
+ }
+ else
+ {
+ // Make sure particle effects disappear
+ LLHUDObject::renderAllForTimer();
+ }
+ }
+ else
+ {
+ // Make sure particle effects disappear
+ LLHUDObject::renderAllForTimer();
+ }
+
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomEnd");
+
+ //HACK: preserve/restore matrices around HUD render
+ if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ for (U32 i = 0; i < 16; i++)
+ {
+ gGLModelView[i] = saved_modelview[i];
+ gGLProjection[i] = saved_projection[i];
+ }
+ }
+
+ LLVertexBuffer::unbind();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+}
+
+void LLPipeline::renderGeomDeferred(LLCamera& camera)
+{
+ LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomDeferred");
+
+ LLMemType mt_rgd(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_DEFFERRED);
+ LLFastTimer t(FTM_RENDER_GEOMETRY);
+
+ LLFastTimer t2(FTM_POOLS);
+
+ LLGLEnable cull(GL_CULL_FACE);
+
+ LLGLEnable stencil(GL_STENCIL_TEST);
+ glStencilFunc(GL_ALWAYS, 1, 0xFFFFFFFF);
+ stop_glerror();
+ glStencilOp(GL_KEEP, GL_KEEP, GL_REPLACE);
+ stop_glerror();
+
+ for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter)
+ {
+ LLDrawPool *poolp = *iter;
+ if (hasRenderType(poolp->getType()))
+ {
+ poolp->prerender();
+ }
+ }
+
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+
+ LLVertexBuffer::unbind();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+ U32 cur_type = 0;
+
+ gGL.setColorMask(true, true);
+
+ pool_set_t::iterator iter1 = mPools.begin();
+
+ while ( iter1 != mPools.end() )
+ {
+ LLDrawPool *poolp = *iter1;
+
+ cur_type = poolp->getType();
+
+ pool_set_t::iterator iter2 = iter1;
+ if (hasRenderType(poolp->getType()) && poolp->getNumDeferredPasses() > 0)
+ {
+ LLFastTimer t(FTM_POOLRENDER);
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ for( S32 i = 0; i < poolp->getNumDeferredPasses(); i++ )
+ {
+ LLVertexBuffer::unbind();
+ poolp->beginDeferredPass(i);
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+
+ p->renderDeferred(i);
+ }
+ poolp->endDeferredPass(i);
+ LLVertexBuffer::unbind();
+
+ if (gDebugGL || gDebugPipeline)
+ {
+ GLint depth;
+ glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth);
+ if (depth > 3)
+ {
+ llerrs << "GL matrix stack corrupted!" << llendl;
+ }
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+ }
+ }
+ }
+ else
+ {
+ // Skip all pools of this type
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+ }
+ }
+ iter1 = iter2;
+ stop_glerror();
+ }
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ gGL.setColorMask(true, false);
+}
+
+void LLPipeline::renderGeomPostDeferred(LLCamera& camera)
+{
+ LLMemType mt_rgpd(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_POST_DEF);
+ LLFastTimer t(FTM_POOLS);
+ U32 cur_type = 0;
+
+ LLGLEnable cull(GL_CULL_FACE);
+
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+
+ calcNearbyLights(camera);
+ setupHWLights(NULL);
+
+ gGL.setColorMask(true, false);
+
+ pool_set_t::iterator iter1 = mPools.begin();
+ BOOL occlude = LLPipeline::sUseOcclusion > 1;
+
+ while ( iter1 != mPools.end() )
+ {
+ LLDrawPool *poolp = *iter1;
+
+ cur_type = poolp->getType();
+
+ if (occlude && cur_type >= LLDrawPool::POOL_GRASS)
+ {
+ occlude = FALSE;
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ doOcclusion(camera);
+ gGL.setColorMask(true, false);
+ }
+
+ pool_set_t::iterator iter2 = iter1;
+ if (hasRenderType(poolp->getType()) && poolp->getNumPostDeferredPasses() > 0)
+ {
+ LLFastTimer t(FTM_POOLRENDER);
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ for( S32 i = 0; i < poolp->getNumPostDeferredPasses(); i++ )
+ {
+ LLVertexBuffer::unbind();
+ poolp->beginPostDeferredPass(i);
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+
+ p->renderPostDeferred(i);
+ }
+ poolp->endPostDeferredPass(i);
+ LLVertexBuffer::unbind();
+
+ if (gDebugGL || gDebugPipeline)
+ {
+ GLint depth;
+ glGetIntegerv(GL_MODELVIEW_STACK_DEPTH, &depth);
+ if (depth > 3)
+ {
+ llerrs << "GL matrix stack corrupted!" << llendl;
+ }
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+ }
+ }
+ }
+ else
+ {
+ // Skip all pools of this type
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+ }
+ }
+ iter1 = iter2;
+ stop_glerror();
+ }
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ if (occlude)
+ {
+ occlude = FALSE;
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ doOcclusion(camera);
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ }
+}
+
+void LLPipeline::renderGeomShadow(LLCamera& camera)
+{
+ LLMemType mt_rgs(LLMemType::MTYPE_PIPELINE_RENDER_GEOM_SHADOW);
+ U32 cur_type = 0;
+
+ LLGLEnable cull(GL_CULL_FACE);
+
+ LLVertexBuffer::unbind();
+
+ pool_set_t::iterator iter1 = mPools.begin();
+
+ while ( iter1 != mPools.end() )
+ {
+ LLDrawPool *poolp = *iter1;
+
+ cur_type = poolp->getType();
+
+ pool_set_t::iterator iter2 = iter1;
+ if (hasRenderType(poolp->getType()) && poolp->getNumShadowPasses() > 0)
+ {
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+
+ for( S32 i = 0; i < poolp->getNumShadowPasses(); i++ )
+ {
+ LLVertexBuffer::unbind();
+ poolp->beginShadowPass(i);
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+
+ p->renderShadow(i);
+ }
+ poolp->endShadowPass(i);
+ LLVertexBuffer::unbind();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+ }
+ }
+ else
+ {
+ // Skip all pools of this type
+ for (iter2 = iter1; iter2 != mPools.end(); iter2++)
+ {
+ LLDrawPool *p = *iter2;
+ if (p->getType() != cur_type)
+ {
+ break;
+ }
+ }
+ }
+ iter1 = iter2;
+ stop_glerror();
+ }
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+}
+
+
+void LLPipeline::addTrianglesDrawn(S32 index_count, U32 render_type)
+{
+ assertInitialized();
+ S32 count = 0;
+ if (render_type == LLRender::TRIANGLE_STRIP)
+ {
+ count = index_count-2;
+ }
+ else
+ {
+ count = index_count/3;
+ }
+
+ mTrianglesDrawn += count;
+ mBatchCount++;
+ mMaxBatchSize = llmax(mMaxBatchSize, count);
+ mMinBatchSize = llmin(mMinBatchSize, count);
+
+ if (LLPipeline::sRenderFrameTest)
+ {
+ gViewerWindow->getWindow()->swapBuffers();
+ ms_sleep(16);
+ }
+}
+
+void LLPipeline::renderPhysicsDisplay()
+{
+ if (!hasRenderDebugMask(LLPipeline::RENDER_DEBUG_PHYSICS_SHAPES))
+ {
+ return;
+ }
+
+ allocatePhysicsBuffer();
+
+ gGL.flush();
+ mPhysicsDisplay.bindTarget();
+ glClearColor(0,0,0,1);
+ gGL.setColorMask(true, true);
+ mPhysicsDisplay.clear();
+ glClearColor(0,0,0,0);
+
+ gGL.setColorMask(true, false);
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ if (hasRenderType(part->mDrawableType))
+ {
+ part->renderPhysicsShapes();
+ }
+ }
+ }
+ }
+
+ for (LLCullResult::bridge_list_t::const_iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i)
+ {
+ LLSpatialBridge* bridge = *i;
+ if (!bridge->isDead() && hasRenderType(bridge->mDrawableType))
+ {
+ glPushMatrix();
+ glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix);
+ bridge->renderPhysicsShapes();
+ glPopMatrix();
+ }
+ }
+
+
+ gGL.flush();
+ mPhysicsDisplay.flush();
+}
+
+
+void LLPipeline::renderDebug()
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+
+ assertInitialized();
+
+ gGL.color4f(1,1,1,1);
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ gGL.setColorMask(true, false);
+
+ bool hud_only = hasRenderType(LLPipeline::RENDER_TYPE_HUD);
+
+ // Debug stuff.
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ if ( hud_only && (part->mDrawableType == RENDER_TYPE_HUD || part->mDrawableType == RENDER_TYPE_HUD_PARTICLES) ||
+ !hud_only && hasRenderType(part->mDrawableType) )
+ {
+ part->renderDebug();
+ }
+ }
+ }
+ }
+
+ for (LLCullResult::bridge_list_t::const_iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i)
+ {
+ LLSpatialBridge* bridge = *i;
+ if (!bridge->isDead() && hasRenderType(bridge->mDrawableType))
+ {
+ glPushMatrix();
+ glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix);
+ bridge->renderDebug();
+ glPopMatrix();
+ }
+ }
+
+ if (gSavedSettings.getBOOL("DebugShowUploadCost"))
+ {
+ std::set<LLUUID> textures;
+ std::set<LLUUID> sculpts;
+ std::set<LLUUID> meshes;
+
+ BOOL selected = TRUE;
+ if (LLSelectMgr::getInstance()->getSelection()->isEmpty())
+ {
+ selected = FALSE;
+ }
+
+ for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ LLSpatialGroup::OctreeNode* node = group->mOctreeNode;
+ for (LLSpatialGroup::OctreeNode::element_iter elem = node->getData().begin(); elem != node->getData().end(); ++elem)
+ {
+ LLDrawable* drawable = *elem;
+ LLVOVolume* volume = drawable->getVOVolume();
+ if (volume && volume->isSelected() == selected)
+ {
+ for (U32 i = 0; i < volume->getNumTEs(); ++i)
+ {
+ LLTextureEntry* te = volume->getTE(i);
+ textures.insert(te->getID());
+ }
+
+ if (volume->isSculpted())
+ {
+ LLUUID sculpt_id = volume->getVolume()->getParams().getSculptID();
+ if (volume->isMesh())
+ {
+ meshes.insert(sculpt_id);
+ }
+ else
+ {
+ sculpts.insert(sculpt_id);
+ }
+ }
+ }
+ }
+ }
+
+ gPipeline.mDebugTextureUploadCost = textures.size() * 10;
+ gPipeline.mDebugSculptUploadCost = sculpts.size()*10;
+
+ U32 mesh_cost = 0;
+
+ for (std::set<LLUUID>::iterator iter = meshes.begin(); iter != meshes.end(); ++iter)
+ {
+ mesh_cost += gMeshRepo.getResourceCost(*iter)*10;
+ }
+
+ gPipeline.mDebugMeshUploadCost = mesh_cost;
+ }
+
+ if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ LLVertexBuffer::unbind();
+
+ LLGLEnable blend(GL_BLEND);
+ LLGLDepthTest depth(TRUE, FALSE);
+ LLGLDisable cull(GL_CULL_FACE);
+
+ gGL.color4f(1,1,1,1);
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+
+ F32 a = 0.1f;
+
+ F32 col[] =
+ {
+ 1,0,0,a,
+ 0,1,0,a,
+ 0,0,1,a,
+ 1,0,1,a,
+
+ 1,1,0,a,
+ 0,1,1,a,
+ 1,1,1,a,
+ 1,0,1,a,
+ };
+
+ for (U32 i = 0; i < 8; i++)
+ {
+ LLVector3* frust = mShadowCamera[i].mAgentFrustum;
+
+ if (i > 3)
+ { //render shadow frusta as volumes
+ if (mShadowFrustPoints[i-4].empty())
+ {
+ continue;
+ }
+
+ gGL.color4fv(col+(i-4)*4);
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV);
+ gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[5].mV);
+ gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[6].mV);
+ gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[7].mV);
+ gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV);
+ gGL.end();
+
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.vertex3fv(frust[0].mV);
+ gGL.vertex3fv(frust[1].mV);
+ gGL.vertex3fv(frust[3].mV);
+ gGL.vertex3fv(frust[2].mV);
+ gGL.end();
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.vertex3fv(frust[4].mV);
+ gGL.vertex3fv(frust[5].mV);
+ gGL.vertex3fv(frust[7].mV);
+ gGL.vertex3fv(frust[6].mV);
+ gGL.end();
+ }
+
+
+ if (i < 4)
+ {
+
+ //if (i == 0 || !mShadowFrustPoints[i].empty())
+ {
+ //render visible point cloud
+ gGL.flush();
+ glPointSize(8.f);
+ gGL.begin(LLRender::POINTS);
+
+ F32* c = col+i*4;
+ gGL.color3fv(c);
+
+ for (U32 j = 0; j < mShadowFrustPoints[i].size(); ++j)
+ {
+ gGL.vertex3fv(mShadowFrustPoints[i][j].mV);
+
+ }
+ gGL.end();
+
+ gGL.flush();
+ glPointSize(1.f);
+
+ LLVector3* ext = mShadowExtents[i];
+ LLVector3 pos = (ext[0]+ext[1])*0.5f;
+ LLVector3 size = (ext[1]-ext[0])*0.5f;
+ drawBoxOutline(pos, size);
+
+ //render camera frustum splits as outlines
+ gGL.begin(LLRender::LINES);
+ gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[1].mV);
+ gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[2].mV);
+ gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[3].mV);
+ gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[0].mV);
+ gGL.vertex3fv(frust[4].mV); gGL.vertex3fv(frust[5].mV);
+ gGL.vertex3fv(frust[5].mV); gGL.vertex3fv(frust[6].mV);
+ gGL.vertex3fv(frust[6].mV); gGL.vertex3fv(frust[7].mV);
+ gGL.vertex3fv(frust[7].mV); gGL.vertex3fv(frust[4].mV);
+ gGL.vertex3fv(frust[0].mV); gGL.vertex3fv(frust[4].mV);
+ gGL.vertex3fv(frust[1].mV); gGL.vertex3fv(frust[5].mV);
+ gGL.vertex3fv(frust[2].mV); gGL.vertex3fv(frust[6].mV);
+ gGL.vertex3fv(frust[3].mV); gGL.vertex3fv(frust[7].mV);
+ gGL.end();
+ }
+ }
+
+ /*gGL.flush();
+ glLineWidth(16-i*2);
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 j = 0; j < LLViewerRegion::NUM_PARTITIONS; j++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(j);
+ if (part)
+ {
+ if (hasRenderType(part->mDrawableType))
+ {
+ part->renderIntersectingBBoxes(&mShadowCamera[i]);
+ }
+ }
+ }
+ }
+ gGL.flush();
+ glLineWidth(1.f);*/
+ }
+ }
+
+ if (mRenderDebugMask & RENDER_DEBUG_COMPOSITION)
+ {
+ // Debug composition layers
+ F32 x, y;
+
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+
+ if (gAgent.getRegion())
+ {
+ gGL.begin(LLRender::POINTS);
+ // Draw the composition layer for the region that I'm in.
+ for (x = 0; x <= 260; x++)
+ {
+ for (y = 0; y <= 260; y++)
+ {
+ if ((x > 255) || (y > 255))
+ {
+ gGL.color4f(1.f, 0.f, 0.f, 1.f);
+ }
+ else
+ {
+ gGL.color4f(0.f, 0.f, 1.f, 1.f);
+ }
+ F32 z = gAgent.getRegion()->getCompositionXY((S32)x, (S32)y);
+ z *= 5.f;
+ z += 50.f;
+ gGL.vertex3f(x, y, z);
+ }
+ }
+ gGL.end();
+ }
+ }
+
+ if (mRenderDebugMask & LLPipeline::RENDER_DEBUG_BUILD_QUEUE)
+ {
+ U32 count = 0;
+ U32 size = mGroupQ2.size();
+ LLColor4 col;
+
+ LLVertexBuffer::unbind();
+ LLGLEnable blend(GL_BLEND);
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE);
+ gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep);
+
+ gGL.pushMatrix();
+ glLoadMatrixd(gGLModelView);
+ gGLLastMatrix = NULL;
+
+ for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ2.begin(); iter != mGroupQ2.end(); ++iter)
+ {
+ LLSpatialGroup* group = *iter;
+ if (group->isDead())
+ {
+ continue;
+ }
+
+ LLSpatialBridge* bridge = group->mSpatialPartition->asBridge();
+
+ if (bridge && (!bridge->mDrawable || bridge->mDrawable->isDead()))
+ {
+ continue;
+ }
+
+ if (bridge)
+ {
+ gGL.pushMatrix();
+ glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix);
+ }
+
+ F32 alpha = llclamp((F32) (size-count)/size, 0.f, 1.f);
+
+
+ LLVector2 c(1.f-alpha, alpha);
+ c.normVec();
+
+
+ ++count;
+ col.set(c.mV[0], c.mV[1], 0, alpha*0.5f+0.5f);
+ group->drawObjectBox(col);
+
+ if (bridge)
+ {
+ gGL.popMatrix();
+ }
+ }
+
+ gGL.popMatrix();
+ }
+
+ gGL.flush();
+
+ gPipeline.renderPhysicsDisplay();
+}
+
+void LLPipeline::rebuildPools()
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_REBUILD_POOLS);
+
+ assertInitialized();
+
+ S32 max_count = mPools.size();
+ pool_set_t::iterator iter1 = mPools.upper_bound(mLastRebuildPool);
+ while(max_count > 0 && mPools.size() > 0) // && num_rebuilds < MAX_REBUILDS)
+ {
+ if (iter1 == mPools.end())
+ {
+ iter1 = mPools.begin();
+ }
+ LLDrawPool* poolp = *iter1;
+
+ if (poolp->isDead())
+ {
+ mPools.erase(iter1++);
+ removeFromQuickLookup( poolp );
+ if (poolp == mLastRebuildPool)
+ {
+ mLastRebuildPool = NULL;
+ }
+ delete poolp;
+ }
+ else
+ {
+ mLastRebuildPool = poolp;
+ iter1++;
+ }
+ max_count--;
+ }
+
+ if (isAgentAvatarValid())
+ {
+ gAgentAvatarp->rebuildHUD();
+ }
+}
+
+void LLPipeline::addToQuickLookup( LLDrawPool* new_poolp )
+{
+ LLMemType mt(LLMemType::MTYPE_PIPELINE_QUICK_LOOKUP);
+
+ assertInitialized();
+
+ switch( new_poolp->getType() )
+ {
+ case LLDrawPool::POOL_SIMPLE:
+ if (mSimplePool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate simple pool." << llendl;
+ }
+ else
+ {
+ mSimplePool = (LLRenderPass*) new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_GRASS:
+ if (mGrassPool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate grass pool." << llendl;
+ }
+ else
+ {
+ mGrassPool = (LLRenderPass*) new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_FULLBRIGHT:
+ if (mFullbrightPool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate simple pool." << llendl;
+ }
+ else
+ {
+ mFullbrightPool = (LLRenderPass*) new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_INVISIBLE:
+ if (mInvisiblePool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate simple pool." << llendl;
+ }
+ else
+ {
+ mInvisiblePool = (LLRenderPass*) new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_GLOW:
+ if (mGlowPool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate glow pool." << llendl;
+ }
+ else
+ {
+ mGlowPool = (LLRenderPass*) new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_TREE:
+ mTreePools[ uintptr_t(new_poolp->getTexture()) ] = new_poolp ;
+ break;
+
+ case LLDrawPool::POOL_TERRAIN:
+ mTerrainPools[ uintptr_t(new_poolp->getTexture()) ] = new_poolp ;
+ break;
+
+ case LLDrawPool::POOL_BUMP:
+ if (mBumpPool)
+ {
+ llassert(0);
+ llwarns << "Ignoring duplicate bump pool." << llendl;
+ }
+ else
+ {
+ mBumpPool = new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_ALPHA:
+ if( mAlphaPool )
+ {
+ llassert(0);
+ llwarns << "LLPipeline::addPool(): Ignoring duplicate Alpha pool" << llendl;
+ }
+ else
+ {
+ mAlphaPool = new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_AVATAR:
+ break; // Do nothing
+
+ case LLDrawPool::POOL_SKY:
+ if( mSkyPool )
+ {
+ llassert(0);
+ llwarns << "LLPipeline::addPool(): Ignoring duplicate Sky pool" << llendl;
+ }
+ else
+ {
+ mSkyPool = new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_WATER:
+ if( mWaterPool )
+ {
+ llassert(0);
+ llwarns << "LLPipeline::addPool(): Ignoring duplicate Water pool" << llendl;
+ }
+ else
+ {
+ mWaterPool = new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_GROUND:
+ if( mGroundPool )
+ {
+ llassert(0);
+ llwarns << "LLPipeline::addPool(): Ignoring duplicate Ground Pool" << llendl;
+ }
+ else
+ {
+ mGroundPool = new_poolp;
+ }
+ break;
+
+ case LLDrawPool::POOL_WL_SKY:
+ if( mWLSkyPool )
+ {
+ llassert(0);
+ llwarns << "LLPipeline::addPool(): Ignoring duplicate WLSky Pool" << llendl;
+ }
+ else
+ {
+ mWLSkyPool = new_poolp;
+ }
+ break;
+
+ default:
+ llassert(0);
+ llwarns << "Invalid Pool Type in LLPipeline::addPool()" << llendl;
+ break;
+ }
+}
+
+void LLPipeline::removePool( LLDrawPool* poolp )
+{
+ assertInitialized();
+ removeFromQuickLookup(poolp);
+ mPools.erase(poolp);
+ delete poolp;
+}
+
+void LLPipeline::removeFromQuickLookup( LLDrawPool* poolp )
+{
+ assertInitialized();
+ LLMemType mt(LLMemType::MTYPE_PIPELINE);
+ switch( poolp->getType() )
+ {
+ case LLDrawPool::POOL_SIMPLE:
+ llassert(mSimplePool == poolp);
+ mSimplePool = NULL;
+ break;
+
+ case LLDrawPool::POOL_GRASS:
+ llassert(mGrassPool == poolp);
+ mGrassPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_FULLBRIGHT:
+ llassert(mFullbrightPool == poolp);
+ mFullbrightPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_INVISIBLE:
+ llassert(mInvisiblePool == poolp);
+ mInvisiblePool = NULL;
+ break;
+
+ case LLDrawPool::POOL_WL_SKY:
+ llassert(mWLSkyPool == poolp);
+ mWLSkyPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_GLOW:
+ llassert(mGlowPool == poolp);
+ mGlowPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_TREE:
+ #ifdef _DEBUG
+ {
+ BOOL found = mTreePools.erase( (uintptr_t)poolp->getTexture() );
+ llassert( found );
+ }
+ #else
+ mTreePools.erase( (uintptr_t)poolp->getTexture() );
+ #endif
+ break;
+
+ case LLDrawPool::POOL_TERRAIN:
+ #ifdef _DEBUG
+ {
+ BOOL found = mTerrainPools.erase( (uintptr_t)poolp->getTexture() );
+ llassert( found );
+ }
+ #else
+ mTerrainPools.erase( (uintptr_t)poolp->getTexture() );
+ #endif
+ break;
+
+ case LLDrawPool::POOL_BUMP:
+ llassert( poolp == mBumpPool );
+ mBumpPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_ALPHA:
+ llassert( poolp == mAlphaPool );
+ mAlphaPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_AVATAR:
+ break; // Do nothing
+
+ case LLDrawPool::POOL_SKY:
+ llassert( poolp == mSkyPool );
+ mSkyPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_WATER:
+ llassert( poolp == mWaterPool );
+ mWaterPool = NULL;
+ break;
+
+ case LLDrawPool::POOL_GROUND:
+ llassert( poolp == mGroundPool );
+ mGroundPool = NULL;
+ break;
+
+ default:
+ llassert(0);
+ llwarns << "Invalid Pool Type in LLPipeline::removeFromQuickLookup() type=" << poolp->getType() << llendl;
+ break;
+ }
+}
+
+void LLPipeline::resetDrawOrders()
+{
+ assertInitialized();
+ // Iterate through all of the draw pools and rebuild them.
+ for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter)
+ {
+ LLDrawPool *poolp = *iter;
+ poolp->resetDrawOrders();
+ }
+}
+
+//============================================================================
+// Once-per-frame setup of hardware lights,
+// including sun/moon, avatar backlight, and up to 6 local lights
+
+void LLPipeline::setupAvatarLights(BOOL for_edit)
+{
+ assertInitialized();
+
+ if (for_edit)
+ {
+ LLColor4 diffuse(1.f, 1.f, 1.f, 0.f);
+ LLVector4 light_pos_cam(-8.f, 0.25f, 10.f, 0.f); // w==0 => directional light
+ LLMatrix4 camera_mat = LLViewerCamera::getInstance()->getModelview();
+ LLMatrix4 camera_rot(camera_mat.getMat3());
+ camera_rot.invert();
+ LLVector4 light_pos = light_pos_cam * camera_rot;
+
+ light_pos.normalize();
+
+ LLLightState* light = gGL.getLight(1);
+
+ mHWLightColors[1] = diffuse;
+
+ light->setDiffuse(diffuse);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ light->setPosition(light_pos);
+ light->setConstantAttenuation(1.f);
+ light->setLinearAttenuation(0.f);
+ light->setQuadraticAttenuation(0.f);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+ }
+ else if (gAvatarBacklight) // Always true (unless overridden in a devs .ini)
+ {
+ LLVector3 opposite_pos = -1.f * mSunDir;
+ LLVector3 orthog_light_pos = mSunDir % LLVector3::z_axis;
+ LLVector4 backlight_pos = LLVector4(lerp(opposite_pos, orthog_light_pos, 0.3f), 0.0f);
+ backlight_pos.normalize();
+
+ LLColor4 light_diffuse = mSunDiffuse;
+ LLColor4 backlight_diffuse(1.f - light_diffuse.mV[VRED], 1.f - light_diffuse.mV[VGREEN], 1.f - light_diffuse.mV[VBLUE], 1.f);
+ F32 max_component = 0.001f;
+ for (S32 i = 0; i < 3; i++)
+ {
+ if (backlight_diffuse.mV[i] > max_component)
+ {
+ max_component = backlight_diffuse.mV[i];
+ }
+ }
+ F32 backlight_mag;
+ if (gSky.getSunDirection().mV[2] >= LLSky::NIGHTTIME_ELEVATION_COS)
+ {
+ backlight_mag = BACKLIGHT_DAY_MAGNITUDE_OBJECT;
+ }
+ else
+ {
+ backlight_mag = BACKLIGHT_NIGHT_MAGNITUDE_OBJECT;
+ }
+ backlight_diffuse *= backlight_mag / max_component;
+
+ mHWLightColors[1] = backlight_diffuse;
+
+ LLLightState* light = gGL.getLight(1);
+
+ light->setPosition(backlight_pos);
+ light->setDiffuse(backlight_diffuse);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ light->setConstantAttenuation(1.f);
+ light->setLinearAttenuation(0.f);
+ light->setQuadraticAttenuation(0.f);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+ }
+ else
+ {
+ LLLightState* light = gGL.getLight(1);
+
+ mHWLightColors[1] = LLColor4::black;
+
+ light->setDiffuse(LLColor4::black);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ }
+}
+
+static F32 calc_light_dist(LLVOVolume* light, const LLVector3& cam_pos, F32 max_dist)
+{
+ F32 inten = light->getLightIntensity();
+ if (inten < .001f)
+ {
+ return max_dist;
+ }
+ F32 radius = light->getLightRadius();
+ BOOL selected = light->isSelected();
+ LLVector3 dpos = light->getRenderPosition() - cam_pos;
+ F32 dist2 = dpos.lengthSquared();
+ if (!selected && dist2 > (max_dist + radius)*(max_dist + radius))
+ {
+ return max_dist;
+ }
+ F32 dist = (F32) sqrt(dist2);
+ dist *= 1.f / inten;
+ dist -= radius;
+ if (selected)
+ {
+ dist -= 10000.f; // selected lights get highest priority
+ }
+ if (light->mDrawable.notNull() && light->mDrawable->isState(LLDrawable::ACTIVE))
+ {
+ // moving lights get a little higher priority (too much causes artifacts)
+ dist -= light->getLightRadius()*0.25f;
+ }
+ return dist;
+}
+
+void LLPipeline::calcNearbyLights(LLCamera& camera)
+{
+ assertInitialized();
+
+ if (LLPipeline::sReflectionRender)
+ {
+ return;
+ }
+
+ if (mLightingDetail >= 1)
+ {
+ // mNearbyLight (and all light_set_t's) are sorted such that
+ // begin() == the closest light and rbegin() == the farthest light
+ const S32 MAX_LOCAL_LIGHTS = 6;
+// LLVector3 cam_pos = gAgent.getCameraPositionAgent();
+ LLVector3 cam_pos = LLViewerJoystick::getInstance()->getOverrideCamera() ?
+ camera.getOrigin() :
+ gAgent.getPositionAgent();
+
+ F32 max_dist = LIGHT_MAX_RADIUS * 4.f; // ignore enitrely lights > 4 * max light rad
+
+ // UPDATE THE EXISTING NEARBY LIGHTS
+ light_set_t cur_nearby_lights;
+ for (light_set_t::iterator iter = mNearbyLights.begin();
+ iter != mNearbyLights.end(); iter++)
+ {
+ const Light* light = &(*iter);
+ LLDrawable* drawable = light->drawable;
+ LLVOVolume* volight = drawable->getVOVolume();
+ if (!volight || !drawable->isState(LLDrawable::LIGHT))
+ {
+ drawable->clearState(LLDrawable::NEARBY_LIGHT);
+ continue;
+ }
+ if (light->fade <= -LIGHT_FADE_TIME)
+ {
+ drawable->clearState(LLDrawable::NEARBY_LIGHT);
+ continue;
+ }
+ if (!sRenderAttachedLights && volight && volight->isAttachment())
+ {
+ drawable->clearState(LLDrawable::NEARBY_LIGHT);
+ continue;
+ }
+
+ F32 dist = calc_light_dist(volight, cam_pos, max_dist);
+ cur_nearby_lights.insert(Light(drawable, dist, light->fade));
+ }
+ mNearbyLights = cur_nearby_lights;
+
+ // FIND NEW LIGHTS THAT ARE IN RANGE
+ light_set_t new_nearby_lights;
+ for (LLDrawable::drawable_set_t::iterator iter = mLights.begin();
+ iter != mLights.end(); ++iter)
+ {
+ LLDrawable* drawable = *iter;
+ LLVOVolume* light = drawable->getVOVolume();
+ if (!light || drawable->isState(LLDrawable::NEARBY_LIGHT))
+ {
+ continue;
+ }
+ if (light->isHUDAttachment())
+ {
+ continue; // no lighting from HUD objects
+ }
+ F32 dist = calc_light_dist(light, cam_pos, max_dist);
+ if (dist >= max_dist)
+ {
+ continue;
+ }
+ if (!sRenderAttachedLights && light && light->isAttachment())
+ {
+ continue;
+ }
+ new_nearby_lights.insert(Light(drawable, dist, 0.f));
+ if (new_nearby_lights.size() > (U32)MAX_LOCAL_LIGHTS)
+ {
+ new_nearby_lights.erase(--new_nearby_lights.end());
+ const Light& last = *new_nearby_lights.rbegin();
+ max_dist = last.dist;
+ }
+ }
+
+ // INSERT ANY NEW LIGHTS
+ for (light_set_t::iterator iter = new_nearby_lights.begin();
+ iter != new_nearby_lights.end(); iter++)
+ {
+ const Light* light = &(*iter);
+ if (mNearbyLights.size() < (U32)MAX_LOCAL_LIGHTS)
+ {
+ mNearbyLights.insert(*light);
+ ((LLDrawable*) light->drawable)->setState(LLDrawable::NEARBY_LIGHT);
+ }
+ else
+ {
+ // crazy cast so that we can overwrite the fade value
+ // even though gcc enforces sets as const
+ // (fade value doesn't affect sort so this is safe)
+ Light* farthest_light = ((Light*) (&(*(mNearbyLights.rbegin()))));
+ if (light->dist < farthest_light->dist)
+ {
+ if (farthest_light->fade >= 0.f)
+ {
+ farthest_light->fade = -gFrameIntervalSeconds;
+ }
+ }
+ else
+ {
+ break; // none of the other lights are closer
+ }
+ }
+ }
+
+ }
+}
+
+void LLPipeline::setupHWLights(LLDrawPool* pool)
+{
+ assertInitialized();
+
+ // Ambient
+ LLColor4 ambient = gSky.getTotalAmbientColor();
+ glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV);
+
+ // Light 0 = Sun or Moon (All objects)
+ {
+ if (gSky.getSunDirection().mV[2] >= LLSky::NIGHTTIME_ELEVATION_COS)
+ {
+ mSunDir.setVec(gSky.getSunDirection());
+ mSunDiffuse.setVec(gSky.getSunDiffuseColor());
+ }
+ else
+ {
+ mSunDir.setVec(gSky.getMoonDirection());
+ mSunDiffuse.setVec(gSky.getMoonDiffuseColor());
+ }
+
+ F32 max_color = llmax(mSunDiffuse.mV[0], mSunDiffuse.mV[1], mSunDiffuse.mV[2]);
+ if (max_color > 1.f)
+ {
+ mSunDiffuse *= 1.f/max_color;
+ }
+ mSunDiffuse.clamp();
+
+ LLVector4 light_pos(mSunDir, 0.0f);
+ LLColor4 light_diffuse = mSunDiffuse;
+ mHWLightColors[0] = light_diffuse;
+
+ LLLightState* light = gGL.getLight(0);
+ light->setPosition(light_pos);
+ light->setDiffuse(light_diffuse);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ light->setConstantAttenuation(1.f);
+ light->setLinearAttenuation(0.f);
+ light->setQuadraticAttenuation(0.f);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+ }
+
+ // Light 1 = Backlight (for avatars)
+ // (set by enableLightsAvatar)
+
+ S32 cur_light = 2;
+
+ // Nearby lights = LIGHT 2-7
+
+ mLightMovingMask = 0;
+
+ if (mLightingDetail >= 1)
+ {
+ for (light_set_t::iterator iter = mNearbyLights.begin();
+ iter != mNearbyLights.end(); ++iter)
+ {
+ LLDrawable* drawable = iter->drawable;
+ LLVOVolume* light = drawable->getVOVolume();
+ if (!light)
+ {
+ continue;
+ }
+ if (drawable->isState(LLDrawable::ACTIVE))
+ {
+ mLightMovingMask |= (1<<cur_light);
+ }
+
+ LLColor4 light_color = light->getLightColor();
+ light_color.mV[3] = 0.0f;
+
+ F32 fade = iter->fade;
+ if (fade < LIGHT_FADE_TIME)
+ {
+ // fade in/out light
+ if (fade >= 0.f)
+ {
+ fade = fade / LIGHT_FADE_TIME;
+ ((Light*) (&(*iter)))->fade += gFrameIntervalSeconds;
+ }
+ else
+ {
+ fade = 1.f + fade / LIGHT_FADE_TIME;
+ ((Light*) (&(*iter)))->fade -= gFrameIntervalSeconds;
+ }
+ fade = llclamp(fade,0.f,1.f);
+ light_color *= fade;
+ }
+
+ LLVector3 light_pos(light->getRenderPosition());
+ LLVector4 light_pos_gl(light_pos, 1.0f);
+
+ F32 light_radius = llmax(light->getLightRadius(), 0.001f);
+
+ F32 x = (3.f * (1.f + light->getLightFalloff())); // why this magic? probably trying to match a historic behavior.
+ float linatten = x / (light_radius); // % of brightness at radius
+
+ mHWLightColors[cur_light] = light_color;
+ LLLightState* light_state = gGL.getLight(cur_light);
+
+ light_state->setPosition(light_pos_gl);
+ light_state->setDiffuse(light_color);
+ light_state->setAmbient(LLColor4::black);
+ light_state->setConstantAttenuation(0.f);
+ light_state->setLinearAttenuation(linatten);
+ light_state->setQuadraticAttenuation(0.f);
+
+ if (light->isLightSpotlight() // directional (spot-)light
+ && (LLPipeline::sRenderDeferred || gSavedSettings.getBOOL("RenderSpotLightsInNondeferred"))) // these are only rendered as GL spotlights if we're in deferred rendering mode *or* the setting forces them on
+ {
+ LLVector3 spotparams = light->getSpotLightParams();
+ LLQuaternion quat = light->getRenderRotation();
+ LLVector3 at_axis(0,0,-1); // this matches deferred rendering's object light direction
+ at_axis *= quat;
+
+ light_state->setSpotDirection(at_axis);
+ light_state->setSpotCutoff(90.f);
+ light_state->setSpotExponent(2.f);
+
+ light_state->setSpecular(LLColor4::black);
+ }
+ else // omnidirectional (point) light
+ {
+ light_state->setSpotExponent(0.f);
+ light_state->setSpotCutoff(180.f);
+
+ // we use specular.w = 1.0 as a cheap hack for the shaders to know that this is omnidirectional rather than a spotlight
+ const LLColor4 specular(0.f, 0.f, 0.f, 1.f);
+ light_state->setSpecular(specular);
+ }
+ cur_light++;
+ if (cur_light >= 8)
+ {
+ break; // safety
+ }
+ }
+ }
+ for ( ; cur_light < 8 ; cur_light++)
+ {
+ mHWLightColors[cur_light] = LLColor4::black;
+ LLLightState* light = gGL.getLight(cur_light);
+
+ light->setDiffuse(LLColor4::black);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ }
+ if (gAgentAvatarp &&
+ gAgentAvatarp->mSpecialRenderMode == 3)
+ {
+ LLColor4 light_color = LLColor4::white;
+ light_color.mV[3] = 0.0f;
+
+ LLVector3 light_pos(LLViewerCamera::getInstance()->getOrigin());
+ LLVector4 light_pos_gl(light_pos, 1.0f);
+
+ F32 light_radius = 16.f;
+
+ F32 x = 3.f;
+ float linatten = x / (light_radius); // % of brightness at radius
+
+ mHWLightColors[2] = light_color;
+ LLLightState* light = gGL.getLight(2);
+
+ light->setPosition(light_pos_gl);
+ light->setDiffuse(light_color);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(LLColor4::black);
+ light->setQuadraticAttenuation(0.f);
+ light->setConstantAttenuation(0.f);
+ light->setLinearAttenuation(linatten);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+ }
+
+ // Init GL state
+ glDisable(GL_LIGHTING);
+ for (S32 i = 0; i < 8; ++i)
+ {
+ gGL.getLight(i)->disable();
+ }
+ mLightMask = 0;
+}
+
+void LLPipeline::enableLights(U32 mask)
+{
+ assertInitialized();
+
+ if (mLightingDetail == 0)
+ {
+ mask &= 0xf003; // sun and backlight only (and fullbright bit)
+ }
+ if (mLightMask != mask)
+ {
+ stop_glerror();
+ if (!mLightMask)
+ {
+ glEnable(GL_LIGHTING);
+ }
+ if (mask)
+ {
+ stop_glerror();
+ for (S32 i=0; i<8; i++)
+ {
+ LLLightState* light = gGL.getLight(i);
+ if (mask & (1<<i))
+ {
+ light->enable();
+ light->setDiffuse(mHWLightColors[i]);
+ }
+ else
+ {
+ light->disable();
+ light->setDiffuse(LLColor4::black);
+ }
+ }
+ stop_glerror();
+ }
+ else
+ {
+ glDisable(GL_LIGHTING);
+ }
+ stop_glerror();
+ mLightMask = mask;
+ LLColor4 ambient = gSky.getTotalAmbientColor();
+ glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV);
+ stop_glerror();
+ }
+}
+
+void LLPipeline::enableLightsStatic()
+{
+ assertInitialized();
+ U32 mask = 0x01; // Sun
+ if (mLightingDetail >= 2)
+ {
+ mask |= mLightMovingMask; // Hardware moving lights
+ }
+ else
+ {
+ mask |= 0xff & (~2); // Hardware local lights
+ }
+ enableLights(mask);
+}
+
+void LLPipeline::enableLightsDynamic()
+{
+ assertInitialized();
+ U32 mask = 0xff & (~2); // Local lights
+ enableLights(mask);
+
+ if (isAgentAvatarValid() && getLightingDetail() <= 0)
+ {
+ if (gAgentAvatarp->mSpecialRenderMode == 0) // normal
+ {
+ gPipeline.enableLightsAvatar();
+ }
+ else if (gAgentAvatarp->mSpecialRenderMode >= 1) // anim preview
+ {
+ gPipeline.enableLightsAvatarEdit(LLColor4(0.7f, 0.6f, 0.3f, 1.f));
+ }
+ }
+}
+
+void LLPipeline::enableLightsAvatar()
+{
+ U32 mask = 0xff; // All lights
+ setupAvatarLights(FALSE);
+ enableLights(mask);
+}
+
+void LLPipeline::enableLightsPreview()
+{
+ disableLights();
+
+ glEnable(GL_LIGHTING);
+ LLColor4 ambient = gSavedSettings.getColor4("PreviewAmbientColor");
+ glLightModelfv(GL_LIGHT_MODEL_AMBIENT,ambient.mV);
+
+
+ LLColor4 diffuse0 = gSavedSettings.getColor4("PreviewDiffuse0");
+ LLColor4 specular0 = gSavedSettings.getColor4("PreviewSpecular0");
+ LLColor4 diffuse1 = gSavedSettings.getColor4("PreviewDiffuse1");
+ LLColor4 specular1 = gSavedSettings.getColor4("PreviewSpecular1");
+ LLColor4 diffuse2 = gSavedSettings.getColor4("PreviewDiffuse2");
+ LLColor4 specular2 = gSavedSettings.getColor4("PreviewSpecular2");
+
+ LLVector3 dir0 = gSavedSettings.getVector3("PreviewDirection0");
+ LLVector3 dir1 = gSavedSettings.getVector3("PreviewDirection1");
+ LLVector3 dir2 = gSavedSettings.getVector3("PreviewDirection2");
+
+ dir0.normVec();
+ dir1.normVec();
+ dir2.normVec();
+
+ LLVector4 light_pos(dir0, 0.0f);
+
+ LLLightState* light = gGL.getLight(0);
+
+ light->enable();
+ light->setPosition(light_pos);
+ light->setDiffuse(diffuse0);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(specular0);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+
+ light_pos = LLVector4(dir1, 0.f);
+
+ light = gGL.getLight(1);
+ light->enable();
+ light->setPosition(light_pos);
+ light->setDiffuse(diffuse1);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(specular1);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+
+ light_pos = LLVector4(dir2, 0.f);
+ light = gGL.getLight(2);
+ light->enable();
+ light->setPosition(light_pos);
+ light->setDiffuse(diffuse2);
+ light->setAmbient(LLColor4::black);
+ light->setSpecular(specular2);
+ light->setSpotExponent(0.f);
+ light->setSpotCutoff(180.f);
+}
+
+
+void LLPipeline::enableLightsAvatarEdit(const LLColor4& color)
+{
+ U32 mask = 0x2002; // Avatar backlight only, set ambient
+ setupAvatarLights(TRUE);
+ enableLights(mask);
+
+ glLightModelfv(GL_LIGHT_MODEL_AMBIENT,color.mV);
+}
+
+void LLPipeline::enableLightsFullbright(const LLColor4& color)
+{
+ assertInitialized();
+ U32 mask = 0x1000; // Non-0 mask, set ambient
+ enableLights(mask);
+
+ glLightModelfv(GL_LIGHT_MODEL_AMBIENT,color.mV);
+}
+
+void LLPipeline::disableLights()
+{
+ enableLights(0); // no lighting (full bright)
+}
+
+//============================================================================
+
+class LLMenuItemGL;
+class LLInvFVBridge;
+struct cat_folder_pair;
+class LLVOBranch;
+class LLVOLeaf;
+
+void LLPipeline::findReferences(LLDrawable *drawablep)
+{
+ assertInitialized();
+ if (mLights.find(drawablep) != mLights.end())
+ {
+ llinfos << "In mLights" << llendl;
+ }
+ if (std::find(mMovedList.begin(), mMovedList.end(), drawablep) != mMovedList.end())
+ {
+ llinfos << "In mMovedList" << llendl;
+ }
+ if (std::find(mShiftList.begin(), mShiftList.end(), drawablep) != mShiftList.end())
+ {
+ llinfos << "In mShiftList" << llendl;
+ }
+ if (mRetexturedList.find(drawablep) != mRetexturedList.end())
+ {
+ llinfos << "In mRetexturedList" << llendl;
+ }
+
+ if (std::find(mBuildQ1.begin(), mBuildQ1.end(), drawablep) != mBuildQ1.end())
+ {
+ llinfos << "In mBuildQ1" << llendl;
+ }
+ if (std::find(mBuildQ2.begin(), mBuildQ2.end(), drawablep) != mBuildQ2.end())
+ {
+ llinfos << "In mBuildQ2" << llendl;
+ }
+
+ S32 count;
+
+ count = gObjectList.findReferences(drawablep);
+ if (count)
+ {
+ llinfos << "In other drawables: " << count << " references" << llendl;
+ }
+}
+
+BOOL LLPipeline::verify()
+{
+ BOOL ok = assertInitialized();
+ if (ok)
+ {
+ for (pool_set_t::iterator iter = mPools.begin(); iter != mPools.end(); ++iter)
+ {
+ LLDrawPool *poolp = *iter;
+ if (!poolp->verify())
+ {
+ ok = FALSE;
+ }
+ }
+ }
+
+ if (!ok)
+ {
+ llwarns << "Pipeline verify failed!" << llendl;
+ }
+ return ok;
+}
+
+//////////////////////////////
+//
+// Collision detection
+//
+//
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+/**
+ * A method to compute a ray-AABB intersection.
+ * Original code by Andrew Woo, from "Graphics Gems", Academic Press, 1990
+ * Optimized code by Pierre Terdiman, 2000 (~20-30% faster on my Celeron 500)
+ * Epsilon value added by Klaus Hartmann. (discarding it saves a few cycles only)
+ *
+ * Hence this version is faster as well as more robust than the original one.
+ *
+ * Should work provided:
+ * 1) the integer representation of 0.0f is 0x00000000
+ * 2) the sign bit of the float is the most significant one
+ *
+ * Report bugs: p.terdiman@codercorner.com
+ *
+ * \param aabb [in] the axis-aligned bounding box
+ * \param origin [in] ray origin
+ * \param dir [in] ray direction
+ * \param coord [out] impact coordinates
+ * \return true if ray intersects AABB
+ */
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+//#define RAYAABB_EPSILON 0.00001f
+#define IR(x) ((U32&)x)
+
+bool LLRayAABB(const LLVector3 ¢er, const LLVector3 &size, const LLVector3& origin, const LLVector3& dir, LLVector3 &coord, F32 epsilon)
+{
+ BOOL Inside = TRUE;
+ LLVector3 MinB = center - size;
+ LLVector3 MaxB = center + size;
+ LLVector3 MaxT;
+ MaxT.mV[VX]=MaxT.mV[VY]=MaxT.mV[VZ]=-1.0f;
+
+ // Find candidate planes.
+ for(U32 i=0;i<3;i++)
+ {
+ if(origin.mV[i] < MinB.mV[i])
+ {
+ coord.mV[i] = MinB.mV[i];
+ Inside = FALSE;
+
+ // Calculate T distances to candidate planes
+ if(IR(dir.mV[i])) MaxT.mV[i] = (MinB.mV[i] - origin.mV[i]) / dir.mV[i];
+ }
+ else if(origin.mV[i] > MaxB.mV[i])
+ {
+ coord.mV[i] = MaxB.mV[i];
+ Inside = FALSE;
+
+ // Calculate T distances to candidate planes
+ if(IR(dir.mV[i])) MaxT.mV[i] = (MaxB.mV[i] - origin.mV[i]) / dir.mV[i];
+ }
+ }
+
+ // Ray origin inside bounding box
+ if(Inside)
+ {
+ coord = origin;
+ return true;
+ }
+
+ // Get largest of the maxT's for final choice of intersection
+ U32 WhichPlane = 0;
+ if(MaxT.mV[1] > MaxT.mV[WhichPlane]) WhichPlane = 1;
+ if(MaxT.mV[2] > MaxT.mV[WhichPlane]) WhichPlane = 2;
+
+ // Check final candidate actually inside box
+ if(IR(MaxT.mV[WhichPlane])&0x80000000) return false;
+
+ for(U32 i=0;i<3;i++)
+ {
+ if(i!=WhichPlane)
+ {
+ coord.mV[i] = origin.mV[i] + MaxT.mV[WhichPlane] * dir.mV[i];
+ if (epsilon > 0)
+ {
+ if(coord.mV[i] < MinB.mV[i] - epsilon || coord.mV[i] > MaxB.mV[i] + epsilon) return false;
+ }
+ else
+ {
+ if(coord.mV[i] < MinB.mV[i] || coord.mV[i] > MaxB.mV[i]) return false;
+ }
+ }
+ }
+ return true; // ray hits box
+}
+
+//////////////////////////////
+//
+// Macros, functions, and inline methods from other classes
+//
+//
+
+void LLPipeline::setLight(LLDrawable *drawablep, BOOL is_light)
+{
+ if (drawablep && assertInitialized())
+ {
+ if (is_light)
+ {
+ mLights.insert(drawablep);
+ drawablep->setState(LLDrawable::LIGHT);
+ }
+ else
+ {
+ drawablep->clearState(LLDrawable::LIGHT);
+ mLights.erase(drawablep);
+ }
+ }
+}
+
+//static
+void LLPipeline::toggleRenderType(U32 type)
+{
+ gPipeline.mRenderTypeEnabled[type] = !gPipeline.mRenderTypeEnabled[type];
+ if (type == LLPipeline::RENDER_TYPE_WATER)
+ {
+ gPipeline.mRenderTypeEnabled[LLPipeline::RENDER_TYPE_VOIDWATER] = !gPipeline.mRenderTypeEnabled[LLPipeline::RENDER_TYPE_VOIDWATER];
+ }
+}
+
+//static
+void LLPipeline::toggleRenderTypeControl(void* data)
+{
+ U32 type = (U32)(intptr_t)data;
+ U32 bit = (1<<type);
+ if (gPipeline.hasRenderType(type))
+ {
+ llinfos << "Toggling render type mask " << std::hex << bit << " off" << std::dec << llendl;
+ }
+ else
+ {
+ llinfos << "Toggling render type mask " << std::hex << bit << " on" << std::dec << llendl;
+ }
+ gPipeline.toggleRenderType(type);
+}
+
+//static
+BOOL LLPipeline::hasRenderTypeControl(void* data)
+{
+ U32 type = (U32)(intptr_t)data;
+ return gPipeline.hasRenderType(type);
+}
+
+// Allows UI items labeled "Hide foo" instead of "Show foo"
+//static
+BOOL LLPipeline::toggleRenderTypeControlNegated(void* data)
+{
+ S32 type = (S32)(intptr_t)data;
+ return !gPipeline.hasRenderType(type);
+}
+
+//static
+void LLPipeline::toggleRenderDebug(void* data)
+{
+ U32 bit = (U32)(intptr_t)data;
+ if (gPipeline.hasRenderDebugMask(bit))
+ {
+ llinfos << "Toggling render debug mask " << std::hex << bit << " off" << std::dec << llendl;
+ }
+ else
+ {
+ llinfos << "Toggling render debug mask " << std::hex << bit << " on" << std::dec << llendl;
+ }
+ gPipeline.mRenderDebugMask ^= bit;
+}
+
+
+//static
+BOOL LLPipeline::toggleRenderDebugControl(void* data)
+{
+ U32 bit = (U32)(intptr_t)data;
+ return gPipeline.hasRenderDebugMask(bit);
+}
+
+//static
+void LLPipeline::toggleRenderDebugFeature(void* data)
+{
+ U32 bit = (U32)(intptr_t)data;
+ gPipeline.mRenderDebugFeatureMask ^= bit;
+}
+
+
+//static
+BOOL LLPipeline::toggleRenderDebugFeatureControl(void* data)
+{
+ U32 bit = (U32)(intptr_t)data;
+ return gPipeline.hasRenderDebugFeatureMask(bit);
+}
+
+void LLPipeline::setRenderDebugFeatureControl(U32 bit, bool value)
+{
+ if (value)
+ {
+ gPipeline.mRenderDebugFeatureMask |= bit;
+ }
+ else
+ {
+ gPipeline.mRenderDebugFeatureMask &= !bit;
+ }
+}
+
+// static
+void LLPipeline::setRenderScriptedBeacons(BOOL val)
+{
+ sRenderScriptedBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderScriptedBeacons(void*)
+{
+ sRenderScriptedBeacons = !sRenderScriptedBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderScriptedBeacons(void*)
+{
+ return sRenderScriptedBeacons;
+}
+
+// static
+void LLPipeline::setRenderScriptedTouchBeacons(BOOL val)
+{
+ sRenderScriptedTouchBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderScriptedTouchBeacons(void*)
+{
+ sRenderScriptedTouchBeacons = !sRenderScriptedTouchBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderScriptedTouchBeacons(void*)
+{
+ return sRenderScriptedTouchBeacons;
+}
+
+// static
+void LLPipeline::setRenderPhysicalBeacons(BOOL val)
+{
+ sRenderPhysicalBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderPhysicalBeacons(void*)
+{
+ sRenderPhysicalBeacons = !sRenderPhysicalBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderPhysicalBeacons(void*)
+{
+ return sRenderPhysicalBeacons;
+}
+
+// static
+void LLPipeline::setRenderParticleBeacons(BOOL val)
+{
+ sRenderParticleBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderParticleBeacons(void*)
+{
+ sRenderParticleBeacons = !sRenderParticleBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderParticleBeacons(void*)
+{
+ return sRenderParticleBeacons;
+}
+
+// static
+void LLPipeline::setRenderSoundBeacons(BOOL val)
+{
+ sRenderSoundBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderSoundBeacons(void*)
+{
+ sRenderSoundBeacons = !sRenderSoundBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderSoundBeacons(void*)
+{
+ return sRenderSoundBeacons;
+}
+
+// static
+void LLPipeline::setRenderBeacons(BOOL val)
+{
+ sRenderBeacons = val;
+}
+
+// static
+void LLPipeline::toggleRenderBeacons(void*)
+{
+ sRenderBeacons = !sRenderBeacons;
+}
+
+// static
+BOOL LLPipeline::getRenderBeacons(void*)
+{
+ return sRenderBeacons;
+}
+
+// static
+void LLPipeline::setRenderHighlights(BOOL val)
+{
+ sRenderHighlight = val;
+}
+
+// static
+void LLPipeline::toggleRenderHighlights(void*)
+{
+ sRenderHighlight = !sRenderHighlight;
+}
+
+// static
+BOOL LLPipeline::getRenderHighlights(void*)
+{
+ return sRenderHighlight;
+}
+
+LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector3& start, const LLVector3& end,
+ BOOL pick_transparent,
+ S32* face_hit,
+ LLVector3* intersection, // return the intersection point
+ LLVector2* tex_coord, // return the texture coordinates of the intersection point
+ LLVector3* normal, // return the surface normal at the intersection point
+ LLVector3* bi_normal // return the surface bi-normal at the intersection point
+ )
+{
+ LLDrawable* drawable = NULL;
+
+ LLVector3 local_end = end;
+
+ LLVector3 position;
+
+ sPickAvatar = FALSE; //LLToolMgr::getInstance()->inBuildMode() ? FALSE : TRUE;
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+
+ for (U32 j = 0; j < LLViewerRegion::NUM_PARTITIONS; j++)
+ {
+ if ((j == LLViewerRegion::PARTITION_VOLUME) ||
+ (j == LLViewerRegion::PARTITION_BRIDGE) ||
+ (j == LLViewerRegion::PARTITION_TERRAIN) ||
+ (j == LLViewerRegion::PARTITION_TREE) ||
+ (j == LLViewerRegion::PARTITION_GRASS)) // only check these partitions for now
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(j);
+ if (part && hasRenderType(part->mDrawableType))
+ {
+ LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, bi_normal);
+ if (hit)
+ {
+ drawable = hit;
+ local_end = position;
+ }
+ }
+ }
+ }
+ }
+
+ if (!sPickAvatar)
+ {
+ //save hit info in case we need to restore
+ //due to attachment override
+ LLVector3 local_normal;
+ LLVector3 local_binormal;
+ LLVector2 local_texcoord;
+ S32 local_face_hit = -1;
+
+ if (face_hit)
+ {
+ local_face_hit = *face_hit;
+ }
+ if (tex_coord)
+ {
+ local_texcoord = *tex_coord;
+ }
+ if (bi_normal)
+ {
+ local_binormal = *bi_normal;
+ }
+ if (normal)
+ {
+ local_normal = *normal;
+ }
+
+ const F32 ATTACHMENT_OVERRIDE_DIST = 0.1f;
+
+ //check against avatars
+ sPickAvatar = TRUE;
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+
+ LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_BRIDGE);
+ if (part && hasRenderType(part->mDrawableType))
+ {
+ LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, bi_normal);
+ if (hit)
+ {
+ if (!drawable ||
+ !drawable->getVObj()->isAttachment() ||
+ (position-local_end).magVec() > ATTACHMENT_OVERRIDE_DIST)
+ { //avatar overrides if previously hit drawable is not an attachment or
+ //attachment is far enough away from detected intersection
+ drawable = hit;
+ local_end = position;
+ }
+ else
+ { //prioritize attachments over avatars
+ position = local_end;
+
+ if (face_hit)
+ {
+ *face_hit = local_face_hit;
+ }
+ if (tex_coord)
+ {
+ *tex_coord = local_texcoord;
+ }
+ if (bi_normal)
+ {
+ *bi_normal = local_binormal;
+ }
+ if (normal)
+ {
+ *normal = local_normal;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ //check all avatar nametags (silly, isn't it?)
+ for (std::vector< LLCharacter* >::iterator iter = LLCharacter::sInstances.begin();
+ iter != LLCharacter::sInstances.end();
+ ++iter)
+ {
+ LLVOAvatar* av = (LLVOAvatar*) *iter;
+ if (av->mNameText.notNull()
+ && av->mNameText->lineSegmentIntersect(start, local_end, position))
+ {
+ drawable = av->mDrawable;
+ local_end = position;
+ }
+ }
+
+ if (intersection)
+ {
+ *intersection = position;
+ }
+
+ return drawable ? drawable->getVObj().get() : NULL;
+}
+
+LLViewerObject* LLPipeline::lineSegmentIntersectInHUD(const LLVector3& start, const LLVector3& end,
+ BOOL pick_transparent,
+ S32* face_hit,
+ LLVector3* intersection, // return the intersection point
+ LLVector2* tex_coord, // return the texture coordinates of the intersection point
+ LLVector3* normal, // return the surface normal at the intersection point
+ LLVector3* bi_normal // return the surface bi-normal at the intersection point
+ )
+{
+ LLDrawable* drawable = NULL;
+
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+
+ BOOL toggle = FALSE;
+ if (!hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ toggleRenderType(LLPipeline::RENDER_TYPE_HUD);
+ toggle = TRUE;
+ }
+
+ LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_HUD);
+ if (part)
+ {
+ LLDrawable* hit = part->lineSegmentIntersect(start, end, pick_transparent, face_hit, intersection, tex_coord, normal, bi_normal);
+ if (hit)
+ {
+ drawable = hit;
+ }
+ }
+
+ if (toggle)
+ {
+ toggleRenderType(LLPipeline::RENDER_TYPE_HUD);
+ }
+ }
+ return drawable ? drawable->getVObj().get() : NULL;
+}
+
+LLSpatialPartition* LLPipeline::getSpatialPartition(LLViewerObject* vobj)
+{
+ if (vobj)
+ {
+ LLViewerRegion* region = vobj->getRegion();
+ if (region)
+ {
+ return region->getSpatialPartition(vobj->getPartitionType());
+ }
+ }
+ return NULL;
+}
+
+
+void LLPipeline::resetVertexBuffers(LLDrawable* drawable)
+{
+ if (!drawable || drawable->isDead())
+ {
+ return;
+ }
+
+ for (S32 i = 0; i < drawable->getNumFaces(); i++)
+ {
+ LLFace* facep = drawable->getFace(i);
+ facep->clearVertexBuffer();
+ }
+}
+
+void LLPipeline::resetVertexBuffers()
+{
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ {
+ LLViewerRegion* region = *iter;
+ for (U32 i = 0; i < LLViewerRegion::NUM_PARTITIONS; i++)
+ {
+ LLSpatialPartition* part = region->getSpatialPartition(i);
+ if (part)
+ {
+ part->resetVertexBuffers();
+ }
+ }
+ }
+
+ resetDrawOrders();
+
+ gSky.resetVertexBuffers();
+
+ if (LLVertexBuffer::sGLCount > 0)
+ {
+ LLVertexBuffer::cleanupClass();
+ }
+
+ //delete all name pool caches
+ LLGLNamePool::cleanupPools();
+
+ if (LLVertexBuffer::sGLCount > 0)
+ {
+ llwarns << "VBO wipe failed." << llendl;
+ }
+
+ if (!LLVertexBuffer::sStreamIBOPool.mNameList.empty() ||
+ !LLVertexBuffer::sStreamVBOPool.mNameList.empty() ||
+ !LLVertexBuffer::sDynamicIBOPool.mNameList.empty() ||
+ !LLVertexBuffer::sDynamicVBOPool.mNameList.empty())
+ {
+ llwarns << "VBO name pool cleanup failed." << llendl;
+ }
+
+ LLVertexBuffer::unbind();
+
+ sRenderBump = gSavedSettings.getBOOL("RenderObjectBump");
+ sUseTriStrips = gSavedSettings.getBOOL("RenderUseTriStrips");
+ LLVertexBuffer::sUseStreamDraw = gSavedSettings.getBOOL("RenderUseStreamVBO");
+ LLVertexBuffer::sPreferStreamDraw = gSavedSettings.getBOOL("RenderPreferStreamDraw");
+ LLVertexBuffer::sEnableVBOs = gSavedSettings.getBOOL("RenderVBOEnable");
+ LLVertexBuffer::sDisableVBOMapping = LLVertexBuffer::sEnableVBOs && gSavedSettings.getBOOL("RenderVBOMappingDisable") ;
+ sBakeSunlight = gSavedSettings.getBOOL("RenderBakeSunlight");
+ sNoAlpha = gSavedSettings.getBOOL("RenderNoAlpha");
+ LLPipeline::sTextureBindTest = gSavedSettings.getBOOL("RenderDebugTextureBind");
+}
+
+void LLPipeline::renderObjects(U32 type, U32 mask, BOOL texture)
+{
+ LLMemType mt_ro(LLMemType::MTYPE_PIPELINE_RENDER_OBJECTS);
+ assertInitialized();
+ glLoadMatrixd(gGLModelView);
+ gGLLastMatrix = NULL;
+ mSimplePool->pushBatches(type, mask);
+ glLoadMatrixd(gGLModelView);
+ gGLLastMatrix = NULL;
+}
+
+void apply_cube_face_rotation(U32 face)
+{
+ switch (face)
+ {
+ case 0:
+ glRotatef(90.f, 0, 1, 0);
+ glRotatef(180.f, 1, 0, 0);
+ break;
+ case 2:
+ glRotatef(-90.f, 1, 0, 0);
+ break;
+ case 4:
+ glRotatef(180.f, 0, 1, 0);
+ glRotatef(180.f, 0, 0, 1);
+ break;
+ case 1:
+ glRotatef(-90.f, 0, 1, 0);
+ glRotatef(180.f, 1, 0, 0);
+ break;
+ case 3:
+ glRotatef(90, 1, 0, 0);
+ break;
+ case 5:
+ glRotatef(180, 0, 0, 1);
+ break;
+ }
+}
+
+void validate_framebuffer_object()
+{
+ GLenum status;
+ status = glCheckFramebufferStatus(GL_FRAMEBUFFER_EXT);
+ switch(status)
+ {
+ case GL_FRAMEBUFFER_COMPLETE:
+ //framebuffer OK, no error.
+ break;
+ case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
+ // frame buffer not OK: probably means unsupported depth buffer format
+ llerrs << "Framebuffer Incomplete Missing Attachment." << llendl;
+ break;
+ case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
+ // frame buffer not OK: probably means unsupported depth buffer format
+ llerrs << "Framebuffer Incomplete Attachment." << llendl;
+ break;
+ case GL_FRAMEBUFFER_UNSUPPORTED:
+ /* choose different formats */
+ llerrs << "Framebuffer unsupported." << llendl;
+ break;
+ default:
+ llerrs << "Unknown framebuffer status." << llendl;
+ break;
+ }
+}
+
+void LLPipeline::bindScreenToTexture()
+{
+
+}
+
+static LLFastTimer::DeclareTimer FTM_RENDER_BLOOM("Bloom");
+
+void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield)
+{
+ LLMemType mt_ru(LLMemType::MTYPE_PIPELINE_RENDER_BLOOM);
+ if (!(gPipeline.canUseVertexShaders() &&
+ sRenderGlow))
+ {
+ return;
+ }
+
+ LLVertexBuffer::unbind();
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+
+ assertInitialized();
+
+ if (gUseWireframe)
+ {
+ glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
+ }
+
+ U32 res_mod = gSavedSettings.getU32("RenderResolutionDivisor");
+
+ LLVector2 tc1(0,0);
+ LLVector2 tc2((F32) gViewerWindow->getWorldViewWidthRaw()*2,
+ (F32) gViewerWindow->getWorldViewHeightRaw()*2);
+
+ if (res_mod > 1)
+ {
+ tc2 /= (F32) res_mod;
+ }
+
+ LLFastTimer ftm(FTM_RENDER_BLOOM);
+ gGL.color4f(1,1,1,1);
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable cull(GL_CULL_FACE);
+
+ enableLightsFullbright(LLColor4(1,1,1,1));
+
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
+ glLoadIdentity();
+
+ LLGLDisable test(GL_ALPHA_TEST);
+
+ gGL.setColorMask(true, true);
+ glClearColor(0,0,0,0);
+
+ /*if (for_snapshot)
+ {
+ gGL.getTexUnit(0)->bind(&mGlow[1]);
+ {
+ //LLGLEnable stencil(GL_STENCIL_TEST);
+ //glStencilFunc(GL_NOTEQUAL, 255, 0xFFFFFFFF);
+ //glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
+ //LLGLDisable blend(GL_BLEND);
+
+ // If the snapshot is constructed from tiles, calculate which
+ // tile we're in.
+
+ //from LLViewerCamera::setPerpsective
+ if (zoom_factor > 1.f)
+ {
+ int pos_y = subfield / llceil(zoom_factor);
+ int pos_x = subfield - (pos_y*llceil(zoom_factor));
+ F32 size = 1.f/zoom_factor;
+
+ tc1.set(pos_x*size, pos_y*size);
+ tc2 = tc1 + LLVector2(size,size);
+ }
+ else
+ {
+ tc2.set(1,1);
+ }
+
+ LLGLEnable blend(GL_BLEND);
+ gGL.setSceneBlendType(LLRender::BT_ADD);
+
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.color4f(1,1,1,1);
+ gGL.texCoord2f(tc1.mV[0], tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc1.mV[0], tc2.mV[1]);
+ gGL.vertex2f(-1,1);
+
+ gGL.texCoord2f(tc2.mV[0], tc1.mV[1]);
+ gGL.vertex2f(1,-1);
+
+ gGL.texCoord2f(tc2.mV[0], tc2.mV[1]);
+ gGL.vertex2f(1,1);
+
+ gGL.end();
+
+ gGL.flush();
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+ }
+
+ gGL.flush();
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+
+ return;
+ }*/
+
+ {
+ {
+ LLFastTimer ftm(FTM_RENDER_BLOOM_FBO);
+ mGlow[2].bindTarget();
+ mGlow[2].clear();
+ }
+
+ gGlowExtractProgram.bind();
+ F32 minLum = llmax(gSavedSettings.getF32("RenderGlowMinLuminance"), 0.0f);
+ F32 maxAlpha = gSavedSettings.getF32("RenderGlowMaxExtractAlpha");
+ F32 warmthAmount = gSavedSettings.getF32("RenderGlowWarmthAmount");
+ LLVector3 lumWeights = gSavedSettings.getVector3("RenderGlowLumWeights");
+ LLVector3 warmthWeights = gSavedSettings.getVector3("RenderGlowWarmthWeights");
+ gGlowExtractProgram.uniform1f("minLuminance", minLum);
+ gGlowExtractProgram.uniform1f("maxExtractAlpha", maxAlpha);
+ gGlowExtractProgram.uniform3f("lumWeights", lumWeights.mV[0], lumWeights.mV[1], lumWeights.mV[2]);
+ gGlowExtractProgram.uniform3f("warmthWeights", warmthWeights.mV[0], warmthWeights.mV[1], warmthWeights.mV[2]);
+ gGlowExtractProgram.uniform1f("warmthAmount", warmthAmount);
+ LLGLEnable blend_on(GL_BLEND);
+ LLGLEnable test(GL_ALPHA_TEST);
+ gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT);
+ gGL.setSceneBlendType(LLRender::BT_ADD_WITH_ALPHA);
+
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ gGL.getTexUnit(0)->disable();
+ gGL.getTexUnit(0)->enable(LLTexUnit::TT_RECT_TEXTURE);
+ gGL.getTexUnit(0)->bind(&mScreen);
+
+ gGL.color4f(1,1,1,1);
+ gPipeline.enableLightsFullbright(LLColor4(1,1,1,1));
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.texCoord2f(tc1.mV[0], tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc1.mV[0], tc2.mV[1]);
+ gGL.vertex2f(-1,3);
+
+ gGL.texCoord2f(tc2.mV[0], tc1.mV[1]);
+ gGL.vertex2f(3,-1);
+
+ gGL.end();
+
+ gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE);
+
+ mGlow[2].flush();
+ }
+
+ tc1.setVec(0,0);
+ tc2.setVec(2,2);
+
+ // power of two between 1 and 1024
+ U32 glowResPow = gSavedSettings.getS32("RenderGlowResolutionPow");
+ const U32 glow_res = llmax(1,
+ llmin(1024, 1 << glowResPow));
+
+ S32 kernel = gSavedSettings.getS32("RenderGlowIterations")*2;
+ F32 delta = gSavedSettings.getF32("RenderGlowWidth") / glow_res;
+ // Use half the glow width if we have the res set to less than 9 so that it looks
+ // almost the same in either case.
+ if (glowResPow < 9)
+ {
+ delta *= 0.5f;
+ }
+ F32 strength = gSavedSettings.getF32("RenderGlowStrength");
+
+ gGlowProgram.bind();
+ gGlowProgram.uniform1f("glowStrength", strength);
+
+ for (S32 i = 0; i < kernel; i++)
+ {
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ {
+ LLFastTimer ftm(FTM_RENDER_BLOOM_FBO);
+ mGlow[i%2].bindTarget();
+ mGlow[i%2].clear();
+ }
+
+ if (i == 0)
+ {
+ gGL.getTexUnit(0)->bind(&mGlow[2]);
+ }
+ else
+ {
+ gGL.getTexUnit(0)->bind(&mGlow[(i-1)%2]);
+ }
+
+ if (i%2 == 0)
+ {
+ gGlowProgram.uniform2f("glowDelta", delta, 0);
+ }
+ else
+ {
+ gGlowProgram.uniform2f("glowDelta", 0, delta);
+ }
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.texCoord2f(tc1.mV[0], tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc1.mV[0], tc2.mV[1]);
+ gGL.vertex2f(-1,3);
+
+ gGL.texCoord2f(tc2.mV[0], tc1.mV[1]);
+ gGL.vertex2f(3,-1);
+
+ gGL.end();
+
+ mGlow[i%2].flush();
+ }
+
+ gGlowProgram.unbind();
+
+ if (LLRenderTarget::sUseFBO)
+ {
+ LLFastTimer ftm(FTM_RENDER_BLOOM_FBO);
+ glBindFramebuffer(GL_FRAMEBUFFER, 0);
+ }
+
+ gGLViewport[0] = gViewerWindow->getWorldViewRectRaw().mLeft;
+ gGLViewport[1] = gViewerWindow->getWorldViewRectRaw().mBottom;
+ gGLViewport[2] = gViewerWindow->getWorldViewRectRaw().getWidth();
+ gGLViewport[3] = gViewerWindow->getWorldViewRectRaw().getHeight();
+ glViewport(gGLViewport[0], gGLViewport[1], gGLViewport[2], gGLViewport[3]);
+
+ tc2.setVec((F32) gViewerWindow->getWorldViewWidthRaw(),
+ (F32) gViewerWindow->getWorldViewHeightRaw());
+
+ gGL.flush();
+
+ LLVertexBuffer::unbind();
+
+ if (LLPipeline::sRenderDeferred && !LLViewerCamera::getInstance()->cameraUnderWater())
+ {
+ LLGLSLShader* shader = &gDeferredPostProgram;
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2)
+ {
+ shader = &gDeferredGIFinalProgram;
+ }
+
+ LLGLDisable blend(GL_BLEND);
+ bindDeferredShader(*shader);
+
+ //depth of field focal plane calculations
+
+ static F32 current_distance = 16.f;
+ static F32 start_distance = 16.f;
+ static F32 transition_time = 1.f;
+
+ LLVector3 focus_point;
+
+ LLViewerObject* obj = LLViewerMediaFocus::getInstance()->getFocusedObject();
+ if (obj && obj->mDrawable && obj->isSelected())
+ {
+ S32 face_idx = LLViewerMediaFocus::getInstance()->getFocusedFace();
+ if (obj && obj->mDrawable)
+ {
+ LLFace* face = obj->mDrawable->getFace(face_idx);
+ if (face)
+ {
+ focus_point = face->getPositionAgent();
+ }
+ }
+ }
if (focus_point.isExactlyZero())
{
if (LLViewerJoystick::getInstance()->getOverrideCamera())
- { - focus_point = gDebugRaycastIntersection; - } - else if (gAgentCamera.cameraMouselook()) - { - gViewerWindow->cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE, - NULL, - &focus_point); - } - else - { + {
+ focus_point = gDebugRaycastIntersection;
+ }
+ else if (gAgentCamera.cameraMouselook())
+ {
+ gViewerWindow->cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE,
+ NULL,
+ &focus_point);
+ }
+ else
+ {
LLViewerObject* obj = gAgentCamera.getFocusObject();
if (obj)
{
focus_point = LLVector3(gAgentCamera.getFocusGlobal()-gAgent.getRegion()->getOriginGlobal());
- } - else - { - focus_point = gDebugRaycastIntersection; - } - } - } - - LLVector3 eye = LLViewerCamera::getInstance()->getOrigin(); - F32 target_distance = 16.f; - if (!focus_point.isExactlyZero()) - { - target_distance = LLViewerCamera::getInstance()->getAtAxis() * (focus_point-eye); - } - - if (transition_time >= 1.f && - fabsf(current_distance-target_distance)/current_distance > 0.01f) - { //large shift happened, interpolate smoothly to new target distance - transition_time = 0.f; - start_distance = current_distance; - } - else if (transition_time < 1.f) - { //currently in a transition, continue interpolating - transition_time += 1.f/gSavedSettings.getF32("CameraFocusTransitionTime")*gFrameIntervalSeconds; - transition_time = llmin(transition_time, 1.f); - - F32 t = cosf(transition_time*F_PI+F_PI)*0.5f+0.5f; - current_distance = start_distance + (target_distance-start_distance)*t; - } - else - { //small or no change, just snap to target distance - current_distance = target_distance; - } - - //convert to mm - F32 subject_distance = current_distance*1000.f; - F32 fnumber = gSavedSettings.getF32("CameraFNumber"); - F32 default_focal_length = gSavedSettings.getF32("CameraFocalLength"); - - if (LLToolMgr::getInstance()->inBuildMode()) - { //squish focal length when in build mode so DoF doesn't make editing objects difficult - default_focal_length = 5.f; - } - - F32 fov = LLViewerCamera::getInstance()->getView(); - - const F32 default_fov = gSavedSettings.getF32("CameraFieldOfView") * F_PI/180.f; - //const F32 default_aspect_ratio = gSavedSettings.getF32("CameraAspectRatio"); - - //F32 aspect_ratio = (F32) mScreen.getWidth()/(F32)mScreen.getHeight(); - - F32 dv = 2.f*default_focal_length * tanf(default_fov/2.f); - //F32 dh = 2.f*default_focal_length * tanf(default_fov*default_aspect_ratio/2.f); - - F32 focal_length = dv/(2*tanf(fov/2.f)); - - //F32 tan_pixel_angle = tanf(LLDrawable::sCurPixelAngle); - - // from wikipedia -- c = |s2-s1|/s2 * f^2/(N(S1-f)) - // where N = fnumber - // s2 = dot distance - // s1 = subject distance - // f = focal length - // - - F32 blur_constant = focal_length*focal_length/(fnumber*(subject_distance-focal_length)); - blur_constant /= 1000.f; //convert to meters for shader - F32 magnification = focal_length/(subject_distance-focal_length); - - shader->uniform1f("focal_distance", -subject_distance/1000.f); - shader->uniform1f("blur_constant", blur_constant); - shader->uniform1f("tan_pixel_angle", tanf(1.f/LLDrawable::sCurPixelAngle)); - shader->uniform1f("magnification", magnification); - - S32 channel = shader->enableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mScreen.bindTexture(0, channel); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - //channel = shader->enableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE); - //if (channel > -1) - //{ - //gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - //} - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.texCoord2f(tc1.mV[0], tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc1.mV[0], tc2.mV[1]); - gGL.vertex2f(-1,3); - - gGL.texCoord2f(tc2.mV[0], tc1.mV[1]); - gGL.vertex2f(3,-1); - - gGL.end(); - - unbindDeferredShader(*shader); - } - else - { - if (res_mod > 1) - { - tc2 /= (F32) res_mod; - } - - U32 mask = LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0 | LLVertexBuffer::MAP_TEXCOORD1; - LLPointer<LLVertexBuffer> buff = new LLVertexBuffer(mask, 0); - buff->allocateBuffer(3,0,TRUE); - - LLStrider<LLVector3> v; - LLStrider<LLVector2> uv1; - LLStrider<LLVector2> uv2; - - buff->getVertexStrider(v); - buff->getTexCoord0Strider(uv1); - buff->getTexCoord1Strider(uv2); - - uv1[0] = LLVector2(0, 0); - uv1[1] = LLVector2(0, 2); - uv1[2] = LLVector2(2, 0); - - uv2[0] = LLVector2(0, 0); - uv2[1] = LLVector2(0, tc2.mV[1]*2.f); - uv2[2] = LLVector2(tc2.mV[0]*2.f, 0); - - v[0] = LLVector3(-1,-1,0); - v[1] = LLVector3(-1,3,0); - v[2] = LLVector3(3,-1,0); - - buff->setBuffer(0); - - LLGLDisable blend(GL_BLEND); - - //tex unit 0 - gGL.getTexUnit(0)->setTextureColorBlend(LLTexUnit::TBO_REPLACE, LLTexUnit::TBS_TEX_COLOR); - - gGL.getTexUnit(0)->bind(&mGlow[1]); - gGL.getTexUnit(1)->activate(); - gGL.getTexUnit(1)->enable(LLTexUnit::TT_RECT_TEXTURE); - - - //tex unit 1 - gGL.getTexUnit(1)->setTextureColorBlend(LLTexUnit::TBO_ADD, LLTexUnit::TBS_TEX_COLOR, LLTexUnit::TBS_PREV_COLOR); - - gGL.getTexUnit(1)->bind(&mScreen); - gGL.getTexUnit(1)->activate(); - - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - - buff->setBuffer(mask); - buff->drawArrays(LLRender::TRIANGLE_STRIP, 0, 3); - - gGL.getTexUnit(1)->disable(); - gGL.getTexUnit(1)->setTextureBlendType(LLTexUnit::TB_MULT); - - gGL.getTexUnit(0)->activate(); - gGL.getTexUnit(0)->setTextureBlendType(LLTexUnit::TB_MULT); - } - - if (LLRenderTarget::sUseFBO) - { //copy depth buffer from mScreen to framebuffer - LLRenderTarget::copyContentsToFramebuffer(mScreen, 0, 0, mScreen.getWidth(), mScreen.getHeight(), - 0, 0, mScreen.getWidth(), mScreen.getHeight(), GL_DEPTH_BUFFER_BIT, GL_NEAREST); - } - - gGL.setSceneBlendType(LLRender::BT_ALPHA); - - if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_PHYSICS_SHAPES)) - { - LLVector2 tc1(0,0); - LLVector2 tc2((F32) gViewerWindow->getWorldViewWidthRaw()*2, - (F32) gViewerWindow->getWorldViewHeightRaw()*2); - - LLGLEnable blend(GL_BLEND); - gGL.color4f(1,1,1,0.75f); - - gGL.getTexUnit(0)->bind(&mPhysicsDisplay); - - gGL.begin(LLRender::TRIANGLE_STRIP); - gGL.texCoord2f(tc1.mV[0], tc1.mV[1]); - gGL.vertex2f(-1,-1); - - gGL.texCoord2f(tc1.mV[0], tc2.mV[1]); - gGL.vertex2f(-1,3); - - gGL.texCoord2f(tc2.mV[0], tc1.mV[1]); - gGL.vertex2f(3,-1); - - gGL.end(); - gGL.flush(); - } - - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - - LLVertexBuffer::unbind(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - -} - -static LLFastTimer::DeclareTimer FTM_BIND_DEFERRED("Bind Deferred"); - -void LLPipeline::bindDeferredShader(LLGLSLShader& shader, U32 light_index, LLRenderTarget* gi_source, LLRenderTarget* last_gi_post, U32 noise_map) -{ - LLFastTimer t(FTM_BIND_DEFERRED); - - if (noise_map == 0xFFFFFFFF) - { - noise_map = mNoiseMap; - } - - LLGLState::checkTextureChannels(); - - shader.bind(); - S32 channel = 0; - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredScreen.bindTexture(0,channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SPECULAR, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredScreen.bindTexture(1, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_NORMAL, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredScreen.bindTexture(2, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - if (gi_source) - { - BOOL has_gi = FALSE; - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_DIFFUSE); - if (channel > -1) - { - has_gi = TRUE; - gi_source->bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_SPECULAR); - if (channel > -1) - { - has_gi = TRUE; - gi_source->bindTexture(1, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_NORMAL); - if (channel > -1) - { - has_gi = TRUE; - gi_source->bindTexture(2, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_MIN_POS); - if (channel > -1) - { - has_gi = TRUE; - gi_source->bindTexture(1, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_MAX_POS); - if (channel > -1) - { - has_gi = TRUE; - gi_source->bindTexture(3, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_DIFFUSE); - if (channel > -1) - { - has_gi = TRUE; - last_gi_post->bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_NORMAL); - if (channel > -1) - { - has_gi = TRUE; - last_gi_post->bindTexture(2, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MAX_POS); - if (channel > -1) - { - has_gi = TRUE; - last_gi_post->bindTexture(1, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MIN_POS); - if (channel > -1) - { - has_gi = TRUE; - last_gi_post->bindTexture(3, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_DEPTH); - if (channel > -1) - { - has_gi = TRUE; - gGL.getTexUnit(channel)->bind(gi_source, TRUE); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - stop_glerror(); - - glTexParameteri(LLTexUnit::getInternalType(mGIMap.getUsage()), GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE); - glTexParameteri(LLTexUnit::getInternalType(mGIMap.getUsage()), GL_DEPTH_TEXTURE_MODE_ARB, GL_ALPHA); - - stop_glerror(); - } - - if (has_gi) - { - F32 range_x = llmin(mGIRange.mV[0], 1.f); - F32 range_y = llmin(mGIRange.mV[1], 1.f); - - LLVector2 scale(range_x,range_y); - - LLVector2 kern[25]; - - for (S32 i = 0; i < 5; ++i) - { - for (S32 j = 0; j < 5; ++j) - { - S32 idx = i*5+j; - kern[idx].mV[0] = (i-2)*0.5f; - kern[idx].mV[1] = (j-2)*0.5f; - kern[idx].scaleVec(scale); - } - } - - shader.uniform2fv("gi_kern", 25, (F32*) kern); - shader.uniformMatrix4fv("gi_mat", 1, FALSE, mGIMatrix.m); - shader.uniformMatrix4fv("gi_mat_proj", 1, FALSE, mGIMatrixProj.m); - shader.uniformMatrix4fv("gi_inv_proj", 1, FALSE, mGIInvProj.m); - shader.uniformMatrix4fv("gi_norm_mat", 1, FALSE, mGINormalMatrix.m); - } - } - - /*channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_POSITION, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredScreen.bindTexture(3, channel); - }*/ - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - gGL.getTexUnit(channel)->bind(&mDeferredDepth, TRUE); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - stop_glerror(); - - glTexParameteri(LLTexUnit::getInternalType(mDeferredDepth.getUsage()), GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE); - glTexParameteri(LLTexUnit::getInternalType(mDeferredDepth.getUsage()), GL_DEPTH_TEXTURE_MODE_ARB, GL_ALPHA); - - stop_glerror(); - - glh::matrix4f projection = glh_get_current_projection(); - glh::matrix4f inv_proj = projection.inverse(); - - shader.uniformMatrix4fv("inv_proj", 1, FALSE, inv_proj.m); - shader.uniform4f("viewport", (F32) gGLViewport[0], - (F32) gGLViewport[1], - (F32) gGLViewport[2], - (F32) gGLViewport[3]); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_NOISE); - if (channel > -1) - { - gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, noise_map); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LIGHTFUNC); - if (channel > -1) - { - gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, mLightFunc); - } - - stop_glerror(); - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredLight[light_index].bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LUMINANCE); - if (channel > -1) - { - gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, mLuminanceMap.getTexture(), true); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_BLOOM); - if (channel > -1) - { - mGlow[1].bindTexture(0, channel); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - gi_source->bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_EDGE, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mEdgeMap.bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SUN_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredLight[1].bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LOCAL_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - if (channel > -1) - { - mDeferredLight[2].bindTexture(0, channel); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - } - - - stop_glerror(); - - for (U32 i = 0; i < 4; i++) - { - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i, LLTexUnit::TT_RECT_TEXTURE); - stop_glerror(); - if (channel > -1) - { - stop_glerror(); - gGL.getTexUnit(channel)->bind(&mShadow[i], TRUE); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - gGL.getTexUnit(channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP); - stop_glerror(); - - glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE_ARB); - glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL); - stop_glerror(); - } - } - - for (U32 i = 4; i < 6; i++) - { - channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i); - stop_glerror(); - if (channel > -1) - { - stop_glerror(); - gGL.getTexUnit(channel)->bind(&mShadow[i], TRUE); - gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR); - gGL.getTexUnit(channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP); - stop_glerror(); - - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE_ARB); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL); - stop_glerror(); - } - } - - stop_glerror(); - - F32 mat[16*6]; - for (U32 i = 0; i < 16; i++) - { - mat[i] = mSunShadowMatrix[0].m[i]; - mat[i+16] = mSunShadowMatrix[1].m[i]; - mat[i+32] = mSunShadowMatrix[2].m[i]; - mat[i+48] = mSunShadowMatrix[3].m[i]; - mat[i+64] = mSunShadowMatrix[4].m[i]; - mat[i+80] = mSunShadowMatrix[5].m[i]; - } - - shader.uniformMatrix4fv("shadow_matrix[0]", 6, FALSE, mat); - shader.uniformMatrix4fv("shadow_matrix", 6, FALSE, mat); - - stop_glerror(); - - channel = shader.enableTexture(LLViewerShaderMgr::ENVIRONMENT_MAP, LLTexUnit::TT_CUBE_MAP); - if (channel > -1) - { - LLCubeMap* cube_map = gSky.mVOSkyp ? gSky.mVOSkyp->getCubeMap() : NULL; - if (cube_map) - { - cube_map->enable(channel); - cube_map->bind(); - F64* m = gGLModelView; - - - F32 mat[] = { m[0], m[1], m[2], - m[4], m[5], m[6], - m[8], m[9], m[10] }; - - shader.uniform3fv("env_mat[0]", 3, mat); - shader.uniform3fv("env_mat", 3, mat); - } - } - - shader.uniform4fv("shadow_clip", 1, mSunClipPlanes.mV); - shader.uniform1f("sun_wash", gSavedSettings.getF32("RenderDeferredSunWash")); - shader.uniform1f("shadow_noise", gSavedSettings.getF32("RenderShadowNoise")); - shader.uniform1f("blur_size", gSavedSettings.getF32("RenderShadowBlurSize")); - - shader.uniform1f("ssao_radius", gSavedSettings.getF32("RenderSSAOScale")); - shader.uniform1f("ssao_max_radius", gSavedSettings.getU32("RenderSSAOMaxScale")); - - F32 ssao_factor = gSavedSettings.getF32("RenderSSAOFactor"); - shader.uniform1f("ssao_factor", ssao_factor); - shader.uniform1f("ssao_factor_inv", 1.0/ssao_factor); - - LLVector3 ssao_effect = gSavedSettings.getVector3("RenderSSAOEffect"); - F32 matrix_diag = (ssao_effect[0] + 2.0*ssao_effect[1])/3.0; - F32 matrix_nondiag = (ssao_effect[0] - ssao_effect[1])/3.0; - // This matrix scales (proj of color onto <1/rt(3),1/rt(3),1/rt(3)>) by - // value factor, and scales remainder by saturation factor - F32 ssao_effect_mat[] = { matrix_diag, matrix_nondiag, matrix_nondiag, - matrix_nondiag, matrix_diag, matrix_nondiag, - matrix_nondiag, matrix_nondiag, matrix_diag}; - shader.uniformMatrix3fv("ssao_effect_mat", 1, GL_FALSE, ssao_effect_mat); - - F32 shadow_offset_error = 1.f + gSavedSettings.getF32("RenderShadowOffsetError") * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2]); - F32 shadow_bias_error = 1.f + gSavedSettings.getF32("RenderShadowBiasError") * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2]); - - shader.uniform2f("screen_res", mDeferredScreen.getWidth(), mDeferredScreen.getHeight()); - shader.uniform1f("near_clip", LLViewerCamera::getInstance()->getNear()*2.f); - shader.uniform1f ("shadow_offset", gSavedSettings.getF32("RenderShadowOffset")*shadow_offset_error); - shader.uniform1f("shadow_bias", gSavedSettings.getF32("RenderShadowBias")*shadow_bias_error); - shader.uniform1f ("spot_shadow_offset", gSavedSettings.getF32("RenderSpotShadowOffset")); - shader.uniform1f("spot_shadow_bias", gSavedSettings.getF32("RenderSpotShadowBias")); - - shader.uniform1f("lum_scale", gSavedSettings.getF32("RenderLuminanceScale")); - shader.uniform1f("sun_lum_scale", gSavedSettings.getF32("RenderSunLuminanceScale")); - shader.uniform1f("sun_lum_offset", gSavedSettings.getF32("RenderSunLuminanceOffset")); - shader.uniform1f("lum_lod", gSavedSettings.getF32("RenderLuminanceDetail")); - shader.uniform1f("gi_range", gSavedSettings.getF32("RenderGIRange")); - shader.uniform1f("gi_brightness", gSavedSettings.getF32("RenderGIBrightness")); - shader.uniform1f("gi_luminance", gSavedSettings.getF32("RenderGILuminance")); - shader.uniform1f("gi_edge_weight", gSavedSettings.getF32("RenderGIBlurEdgeWeight")); - shader.uniform1f("gi_blur_brightness", gSavedSettings.getF32("RenderGIBlurBrightness")); - shader.uniform1f("gi_sample_width", mGILightRadius); - shader.uniform1f("gi_noise", gSavedSettings.getF32("RenderGINoise")); - shader.uniform1f("gi_attenuation", gSavedSettings.getF32("RenderGIAttenuation")); - shader.uniform1f("gi_ambiance", gSavedSettings.getF32("RenderGIAmbiance")); - shader.uniform2f("shadow_res", mShadow[0].getWidth(), mShadow[0].getHeight()); - shader.uniform2f("proj_shadow_res", mShadow[4].getWidth(), mShadow[4].getHeight()); - shader.uniform1f("depth_cutoff", gSavedSettings.getF32("RenderEdgeDepthCutoff")); - shader.uniform1f("norm_cutoff", gSavedSettings.getF32("RenderEdgeNormCutoff")); - - - if (shader.getUniformLocation("norm_mat") >= 0) - { - glh::matrix4f norm_mat = glh_get_current_modelview().inverse().transpose(); - shader.uniformMatrix4fv("norm_mat", 1, FALSE, norm_mat.m); - } -} - -static LLFastTimer::DeclareTimer FTM_GI_TRACE("Trace"); -static LLFastTimer::DeclareTimer FTM_GI_GATHER("Gather"); -static LLFastTimer::DeclareTimer FTM_SUN_SHADOW("Shadow Map"); -static LLFastTimer::DeclareTimer FTM_SOFTEN_SHADOW("Shadow Soften"); -static LLFastTimer::DeclareTimer FTM_EDGE_DETECTION("Find Edges"); -static LLFastTimer::DeclareTimer FTM_LOCAL_LIGHTS("Local Lights"); -static LLFastTimer::DeclareTimer FTM_ATMOSPHERICS("Atmospherics"); -static LLFastTimer::DeclareTimer FTM_FULLSCREEN_LIGHTS("Fullscreen Lights"); -static LLFastTimer::DeclareTimer FTM_PROJECTORS("Projectors"); -static LLFastTimer::DeclareTimer FTM_POST("Post"); - - -void LLPipeline::renderDeferredLighting() -{ - if (!sCull) - { - return; - } - - { - LLFastTimer ftm(FTM_RENDER_DEFERRED); - - LLViewerCamera* camera = LLViewerCamera::getInstance(); - { - LLGLDepthTest depth(GL_TRUE); - mDeferredDepth.copyContents(mDeferredScreen, 0, 0, mDeferredScreen.getWidth(), mDeferredScreen.getHeight(), - 0, 0, mDeferredDepth.getWidth(), mDeferredDepth.getHeight(), GL_DEPTH_BUFFER_BIT, GL_NEAREST); - } - - LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0); - - if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) - { - gPipeline.toggleRenderType(LLPipeline::RENDER_TYPE_HUD); - } - - //ati doesn't seem to love actually using the stencil buffer on FBO's - LLGLEnable stencil(GL_STENCIL_TEST); - glStencilFunc(GL_EQUAL, 1, 0xFFFFFFFF); - glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - - gGL.setColorMask(true, true); - - //draw a cube around every light - LLVertexBuffer::unbind(); - - LLGLEnable cull(GL_CULL_FACE); - LLGLEnable blend(GL_BLEND); - - glh::matrix4f mat = glh_copy_matrix(gGLModelView); - - F32 vert[] = - { - -1,1, - -1,-3, - 3,1, - }; - glVertexPointer(2, GL_FLOAT, 0, vert); - glColor3f(1,1,1); - - { - setupHWLights(NULL); //to set mSunDir; - LLVector4 dir(mSunDir, 0.f); - glh::vec4f tc(dir.mV); - mat.mult_matrix_vec(tc); - glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], 0); - } - - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - - if (gSavedSettings.getBOOL("RenderDeferredSSAO") || gSavedSettings.getS32("RenderShadowDetail") > 0) - { - mDeferredLight[0].bindTarget(); - { //paint shadow/SSAO light map (direct lighting lightmap) - LLFastTimer ftm(FTM_SUN_SHADOW); - bindDeferredShader(gDeferredSunProgram, 0); - - glClearColor(1,1,1,1); - mDeferredLight[0].clear(GL_COLOR_BUFFER_BIT); - glClearColor(0,0,0,0); - - glh::matrix4f inv_trans = glh_get_current_modelview().inverse().transpose(); - - const U32 slice = 32; - F32 offset[slice*3]; - for (U32 i = 0; i < 4; i++) - { - for (U32 j = 0; j < 8; j++) - { - glh::vec3f v; - v.set_value(sinf(6.284f/8*j), cosf(6.284f/8*j), -(F32) i); - v.normalize(); - inv_trans.mult_matrix_vec(v); - v.normalize(); - offset[(i*8+j)*3+0] = v.v[0]; - offset[(i*8+j)*3+1] = v.v[2]; - offset[(i*8+j)*3+2] = v.v[1]; - } - } - - gDeferredSunProgram.uniform3fv("offset", slice, offset); - gDeferredSunProgram.uniform2f("screenRes", mDeferredLight[0].getWidth(), mDeferredLight[0].getHeight()); - - { - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS); - stop_glerror(); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - stop_glerror(); - } - - unbindDeferredShader(gDeferredSunProgram); - } - mDeferredLight[0].flush(); - } - - { //global illumination specific block (still experimental) - if (gSavedSettings.getBOOL("RenderDeferredBlurLight") && - gSavedSettings.getBOOL("RenderDeferredGI")) - { - LLFastTimer ftm(FTM_EDGE_DETECTION); - //generate edge map - LLGLDisable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - LLGLDepthTest depth(GL_FALSE); - LLGLDisable stencil(GL_STENCIL_TEST); - - { - gDeferredEdgeProgram.bind(); - mEdgeMap.bindTarget(); - bindDeferredShader(gDeferredEdgeProgram); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - unbindDeferredShader(gDeferredEdgeProgram); - mEdgeMap.flush(); - } - } - - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2) - { - { //get luminance map from previous frame's light map - LLGLEnable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - LLGLDepthTest depth(GL_FALSE); - LLGLDisable stencil(GL_STENCIL_TEST); - - //static F32 fade = 1.f; - - { - gGL.setSceneBlendType(LLRender::BT_ALPHA); - gLuminanceGatherProgram.bind(); - gLuminanceGatherProgram.uniform2f("screen_res", mDeferredLight[0].getWidth(), mDeferredLight[0].getHeight()); - mLuminanceMap.bindTarget(); - bindDeferredShader(gLuminanceGatherProgram); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - unbindDeferredShader(gLuminanceGatherProgram); - mLuminanceMap.flush(); - gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mLuminanceMap.getTexture(), true); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR); - glGenerateMipmap(GL_TEXTURE_2D); - } - } - - { //paint noisy GI map (bounce lighting lightmap) - LLFastTimer ftm(FTM_GI_TRACE); - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_FALSE); - LLGLDisable test(GL_ALPHA_TEST); - - mGIMapPost[0].bindTarget(); - - bindDeferredShader(gDeferredGIProgram, 0, &mGIMap, 0, mTrueNoiseMap); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - unbindDeferredShader(gDeferredGIProgram); - mGIMapPost[0].flush(); - } - - U32 pass_count = 0; - if (gSavedSettings.getBOOL("RenderDeferredBlurLight")) - { - pass_count = llclamp(gSavedSettings.getU32("RenderGIBlurPasses"), (U32) 1, (U32) 128); - } - - for (U32 i = 0; i < pass_count; ++i) - { //gather/soften indirect lighting map - LLFastTimer ftm(FTM_GI_GATHER); - bindDeferredShader(gDeferredPostGIProgram, 0, &mGIMapPost[0], NULL, mTrueNoiseMap); - F32 blur_size = gSavedSettings.getF32("RenderGIBlurSize")/((F32) i * gSavedSettings.getF32("RenderGIBlurIncrement")+1.f); - gDeferredPostGIProgram.uniform2f("delta", 1.f, 0.f); - gDeferredPostGIProgram.uniform1f("kern_scale", blur_size); - gDeferredPostGIProgram.uniform1f("gi_blur_brightness", gSavedSettings.getF32("RenderGIBlurBrightness")); - - mGIMapPost[1].bindTarget(); - { - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_FALSE); - stop_glerror(); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - stop_glerror(); - } - - mGIMapPost[1].flush(); - unbindDeferredShader(gDeferredPostGIProgram); - bindDeferredShader(gDeferredPostGIProgram, 0, &mGIMapPost[1], NULL, mTrueNoiseMap); - mGIMapPost[0].bindTarget(); - - gDeferredPostGIProgram.uniform2f("delta", 0.f, 1.f); - - { - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_FALSE); - stop_glerror(); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 4); - stop_glerror(); - } - mGIMapPost[0].flush(); - unbindDeferredShader(gDeferredPostGIProgram); - } - } - } - - if (gSavedSettings.getBOOL("RenderDeferredSSAO")) - { //soften direct lighting lightmap - LLFastTimer ftm(FTM_SOFTEN_SHADOW); - //blur lightmap - mDeferredLight[1].bindTarget(); - - glClearColor(1,1,1,1); - mDeferredLight[1].clear(GL_COLOR_BUFFER_BIT); - glClearColor(0,0,0,0); - - bindDeferredShader(gDeferredBlurLightProgram); - - LLVector3 go = gSavedSettings.getVector3("RenderShadowGaussian"); - const U32 kern_length = 4; - F32 blur_size = gSavedSettings.getF32("RenderShadowBlurSize"); - F32 dist_factor = gSavedSettings.getF32("RenderShadowBlurDistFactor"); - - // sample symmetrically with the middle sample falling exactly on 0.0 - F32 x = 0.f; - - LLVector3 gauss[32]; // xweight, yweight, offset - - for (U32 i = 0; i < kern_length; i++) - { - gauss[i].mV[0] = llgaussian(x, go.mV[0]); - gauss[i].mV[1] = llgaussian(x, go.mV[1]); - gauss[i].mV[2] = x; - x += 1.f; - } - - gDeferredBlurLightProgram.uniform2f("delta", 1.f, 0.f); - gDeferredBlurLightProgram.uniform1f("dist_factor", dist_factor); - gDeferredBlurLightProgram.uniform3fv("kern", kern_length, gauss[0].mV); - gDeferredBlurLightProgram.uniform1f("kern_scale", blur_size * (kern_length/2.f - 0.5f)); - - { - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS); - stop_glerror(); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - stop_glerror(); - } - - mDeferredLight[1].flush(); - unbindDeferredShader(gDeferredBlurLightProgram); - - bindDeferredShader(gDeferredBlurLightProgram, 1); - mDeferredLight[0].bindTarget(); - - gDeferredBlurLightProgram.uniform2f("delta", 0.f, 1.f); - - { - LLGLDisable blend(GL_BLEND); - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS); - stop_glerror(); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - stop_glerror(); - } - mDeferredLight[0].flush(); - unbindDeferredShader(gDeferredBlurLightProgram); - } - - stop_glerror(); - glPopMatrix(); - stop_glerror(); - glMatrixMode(GL_MODELVIEW); - stop_glerror(); - glPopMatrix(); - stop_glerror(); - - //copy depth and stencil from deferred screen - //mScreen.copyContents(mDeferredScreen, 0, 0, mDeferredScreen.getWidth(), mDeferredScreen.getHeight(), - // 0, 0, mScreen.getWidth(), mScreen.getHeight(), GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT, GL_NEAREST); - - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2) - { - mDeferredLight[1].bindTarget(); - // clear color buffer here (GI) - zeroing alpha (glow) is important or it will accumulate against sky - glClearColor(0,0,0,0); - mScreen.clear(GL_COLOR_BUFFER_BIT); - } - else - { - mScreen.bindTarget(); - // clear color buffer here - zeroing alpha (glow) is important or it will accumulate against sky - glClearColor(0,0,0,0); - mScreen.clear(GL_COLOR_BUFFER_BIT); - } - - if (gSavedSettings.getBOOL("RenderDeferredAtmospheric")) - { //apply sunlight contribution - LLFastTimer ftm(FTM_ATMOSPHERICS); - bindDeferredShader(gDeferredSoftenProgram, 0, &mGIMapPost[0]); - { - LLGLDepthTest depth(GL_FALSE); - LLGLDisable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - - //full screen blit - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - - glVertexPointer(2, GL_FLOAT, 0, vert); - - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - } - - unbindDeferredShader(gDeferredSoftenProgram); - } - - { //render sky - LLGLDisable blend(GL_BLEND); - LLGLDisable stencil(GL_STENCIL_TEST); - gGL.setSceneBlendType(LLRender::BT_ALPHA); - - gPipeline.pushRenderTypeMask(); - - gPipeline.andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_CLOUDS, - LLPipeline::RENDER_TYPE_WL_SKY, - LLPipeline::END_RENDER_TYPES); - - - renderGeomPostDeferred(*LLViewerCamera::getInstance()); - gPipeline.popRenderTypeMask(); - } - - BOOL render_local = gSavedSettings.getBOOL("RenderLocalLights"); - - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2) - { - mDeferredLight[1].flush(); - mDeferredLight[2].bindTarget(); - mDeferredLight[2].clear(GL_COLOR_BUFFER_BIT); - } - - if (render_local) - { - gGL.setSceneBlendType(LLRender::BT_ADD); - std::list<LLVector4> fullscreen_lights; - LLDrawable::drawable_list_t spot_lights; - LLDrawable::drawable_list_t fullscreen_spot_lights; - - for (U32 i = 0; i < 2; i++) - { - mTargetShadowSpotLight[i] = NULL; - } - - std::list<LLVector4> light_colors; - - LLVertexBuffer::unbind(); - - F32 v[24]; - glVertexPointer(3, GL_FLOAT, 0, v); - - { - bindDeferredShader(gDeferredLightProgram); - LLGLDepthTest depth(GL_TRUE, GL_FALSE); - for (LLDrawable::drawable_set_t::iterator iter = mLights.begin(); iter != mLights.end(); ++iter) - { - LLDrawable* drawablep = *iter; - - LLVOVolume* volume = drawablep->getVOVolume(); - if (!volume) - { - continue; - } - - if (volume->isAttachment()) - { - if (!sRenderAttachedLights) - { - continue; - } - } - - - LLVector4a center; - center.load3(drawablep->getPositionAgent().mV); - const F32* c = center.getF32ptr(); - F32 s = volume->getLightRadius()*1.5f; - - LLColor3 col = volume->getLightColor(); - col *= volume->getLightIntensity(); - - if (col.magVecSquared() < 0.001f) - { - continue; - } - - if (s <= 0.001f) - { - continue; - } - - LLVector4a sa; - sa.splat(s); - if (camera->AABBInFrustumNoFarClip(center, sa) == 0) - { - continue; - } - - sVisibleLightCount++; - - glh::vec3f tc(c); - mat.mult_matrix_vec(tc); - - //vertex positions are encoded so the 3 bits of their vertex index - //correspond to their axis facing, with bit position 3,2,1 matching - //axis facing x,y,z, bit set meaning positive facing, bit clear - //meaning negative facing - v[0] = c[0]-s; v[1] = c[1]-s; v[2] = c[2]-s; // 0 - 0000 - v[3] = c[0]-s; v[4] = c[1]-s; v[5] = c[2]+s; // 1 - 0001 - v[6] = c[0]-s; v[7] = c[1]+s; v[8] = c[2]-s; // 2 - 0010 - v[9] = c[0]-s; v[10] = c[1]+s; v[11] = c[2]+s; // 3 - 0011 - - v[12] = c[0]+s; v[13] = c[1]-s; v[14] = c[2]-s; // 4 - 0100 - v[15] = c[0]+s; v[16] = c[1]-s; v[17] = c[2]+s; // 5 - 0101 - v[18] = c[0]+s; v[19] = c[1]+s; v[20] = c[2]-s; // 6 - 0110 - v[21] = c[0]+s; v[22] = c[1]+s; v[23] = c[2]+s; // 7 - 0111 - - if (camera->getOrigin().mV[0] > c[0] + s + 0.2f || - camera->getOrigin().mV[0] < c[0] - s - 0.2f || - camera->getOrigin().mV[1] > c[1] + s + 0.2f || - camera->getOrigin().mV[1] < c[1] - s - 0.2f || - camera->getOrigin().mV[2] > c[2] + s + 0.2f || - camera->getOrigin().mV[2] < c[2] - s - 0.2f) - { //draw box if camera is outside box - if (render_local) - { - if (volume->isLightSpotlight()) - { - drawablep->getVOVolume()->updateSpotLightPriority(); - spot_lights.push_back(drawablep); - continue; - } - - LLFastTimer ftm(FTM_LOCAL_LIGHTS); - glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s); - glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f); - glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8, - GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center)); - stop_glerror(); - } - } - else - { - if (volume->isLightSpotlight()) - { - drawablep->getVOVolume()->updateSpotLightPriority(); - fullscreen_spot_lights.push_back(drawablep); - continue; - } - - fullscreen_lights.push_back(LLVector4(tc.v[0], tc.v[1], tc.v[2], s*s)); - light_colors.push_back(LLVector4(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f)); - } - } - unbindDeferredShader(gDeferredLightProgram); - } - - if (!spot_lights.empty()) - { - LLGLDepthTest depth(GL_TRUE, GL_FALSE); - bindDeferredShader(gDeferredSpotLightProgram); - - gDeferredSpotLightProgram.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION); - - for (LLDrawable::drawable_list_t::iterator iter = spot_lights.begin(); iter != spot_lights.end(); ++iter) - { - LLFastTimer ftm(FTM_PROJECTORS); - LLDrawable* drawablep = *iter; - - LLVOVolume* volume = drawablep->getVOVolume(); - - LLVector4a center; - center.load3(drawablep->getPositionAgent().mV); - const F32* c = center.getF32ptr(); - F32 s = volume->getLightRadius()*1.5f; - - sVisibleLightCount++; - - glh::vec3f tc(c); - mat.mult_matrix_vec(tc); - - setupSpotLight(gDeferredSpotLightProgram, drawablep); - - LLColor3 col = volume->getLightColor(); - col *= volume->getLightIntensity(); - - //vertex positions are encoded so the 3 bits of their vertex index - //correspond to their axis facing, with bit position 3,2,1 matching - //axis facing x,y,z, bit set meaning positive facing, bit clear - //meaning negative facing - v[0] = c[0]-s; v[1] = c[1]-s; v[2] = c[2]-s; // 0 - 0000 - v[3] = c[0]-s; v[4] = c[1]-s; v[5] = c[2]+s; // 1 - 0001 - v[6] = c[0]-s; v[7] = c[1]+s; v[8] = c[2]-s; // 2 - 0010 - v[9] = c[0]-s; v[10] = c[1]+s; v[11] = c[2]+s; // 3 - 0011 - - v[12] = c[0]+s; v[13] = c[1]-s; v[14] = c[2]-s; // 4 - 0100 - v[15] = c[0]+s; v[16] = c[1]-s; v[17] = c[2]+s; // 5 - 0101 - v[18] = c[0]+s; v[19] = c[1]+s; v[20] = c[2]-s; // 6 - 0110 - v[21] = c[0]+s; v[22] = c[1]+s; v[23] = c[2]+s; // 7 - 0111 - - glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s); - glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f); - glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8, - GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center)); - } - gDeferredSpotLightProgram.disableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION); - unbindDeferredShader(gDeferredSpotLightProgram); - } - - { - bindDeferredShader(gDeferredMultiLightProgram); - - LLGLDepthTest depth(GL_FALSE); - - //full screen blit - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - - U32 count = 0; - - const U32 max_count = 8; - LLVector4 light[max_count]; - LLVector4 col[max_count]; - - glVertexPointer(2, GL_FLOAT, 0, vert); - - F32 far_z = 0.f; - - while (!fullscreen_lights.empty()) - { - LLFastTimer ftm(FTM_FULLSCREEN_LIGHTS); - light[count] = fullscreen_lights.front(); - fullscreen_lights.pop_front(); - col[count] = light_colors.front(); - light_colors.pop_front(); - - far_z = llmin(light[count].mV[2]-sqrtf(light[count].mV[3]), far_z); - - count++; - if (count == max_count || fullscreen_lights.empty()) - { - gDeferredMultiLightProgram.uniform1i("light_count", count); - gDeferredMultiLightProgram.uniform4fv("light", count, (GLfloat*) light); - gDeferredMultiLightProgram.uniform4fv("light_col", count, (GLfloat*) col); - gDeferredMultiLightProgram.uniform1f("far_z", far_z); - far_z = 0.f; - count = 0; - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - } - } - - unbindDeferredShader(gDeferredMultiLightProgram); - - bindDeferredShader(gDeferredMultiSpotLightProgram); - - gDeferredMultiSpotLightProgram.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION); - - for (LLDrawable::drawable_list_t::iterator iter = fullscreen_spot_lights.begin(); iter != fullscreen_spot_lights.end(); ++iter) - { - LLFastTimer ftm(FTM_PROJECTORS); - LLDrawable* drawablep = *iter; - - LLVOVolume* volume = drawablep->getVOVolume(); - - LLVector3 center = drawablep->getPositionAgent(); - F32* c = center.mV; - F32 s = volume->getLightRadius()*1.5f; - - sVisibleLightCount++; - - glh::vec3f tc(c); - mat.mult_matrix_vec(tc); - - setupSpotLight(gDeferredMultiSpotLightProgram, drawablep); - - LLColor3 col = volume->getLightColor(); - col *= volume->getLightIntensity(); - - glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s); - glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f); - glDrawArrays(GL_TRIANGLE_STRIP, 0, 3); - } - - gDeferredMultiSpotLightProgram.disableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION); - unbindDeferredShader(gDeferredMultiSpotLightProgram); - - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - } - } - - gGL.setColorMask(true, true); - - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2) - { - mDeferredLight[2].flush(); - - mScreen.bindTarget(); - mScreen.clear(GL_COLOR_BUFFER_BIT); - - gGL.setSceneBlendType(LLRender::BT_ALPHA); - - { //mix various light maps (local, sun, gi) - LLFastTimer ftm(FTM_POST); - LLGLDisable blend(GL_BLEND); - LLGLDisable test(GL_ALPHA_TEST); - LLGLDepthTest depth(GL_FALSE); - LLGLDisable stencil(GL_STENCIL_TEST); - - bindDeferredShader(gDeferredPostProgram, 0, &mGIMapPost[0]); - - gDeferredPostProgram.bind(); - - LLVertexBuffer::unbind(); - - glVertexPointer(2, GL_FLOAT, 0, vert); - glColor3f(1,1,1); - - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - - glDrawArrays(GL_TRIANGLES, 0, 3); - - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - - unbindDeferredShader(gDeferredPostProgram); - } - } - } - - { //render non-deferred geometry (alpha, fullbright, glow) - LLGLDisable blend(GL_BLEND); - LLGLDisable stencil(GL_STENCIL_TEST); - - pushRenderTypeMask(); - andRenderTypeMask(LLPipeline::RENDER_TYPE_ALPHA, - LLPipeline::RENDER_TYPE_FULLBRIGHT, - LLPipeline::RENDER_TYPE_VOLUME, - LLPipeline::RENDER_TYPE_GLOW, - LLPipeline::RENDER_TYPE_BUMP, - LLPipeline::RENDER_TYPE_PASS_SIMPLE, - LLPipeline::RENDER_TYPE_PASS_ALPHA, - LLPipeline::RENDER_TYPE_PASS_ALPHA_MASK, - LLPipeline::RENDER_TYPE_PASS_BUMP, - LLPipeline::RENDER_TYPE_PASS_POST_BUMP, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_ALPHA_MASK, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY, - LLPipeline::RENDER_TYPE_PASS_GLOW, - LLPipeline::RENDER_TYPE_PASS_GRASS, - LLPipeline::RENDER_TYPE_PASS_SHINY, - LLPipeline::RENDER_TYPE_PASS_INVISIBLE, - LLPipeline::RENDER_TYPE_PASS_INVISI_SHINY, - LLPipeline::RENDER_TYPE_AVATAR, - END_RENDER_TYPES); - - renderGeomPostDeferred(*LLViewerCamera::getInstance()); - popRenderTypeMask(); - } - - { - //render highlights, etc. - renderHighlights(); - mHighlightFaces.clear(); - - renderDebug(); - - LLVertexBuffer::unbind(); - - if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI)) - { - // Render debugging beacons. - gObjectList.renderObjectBeacons(); - LLHUDObject::renderAll(); - gObjectList.resetObjectBeacons(); - } - } - - mScreen.flush(); - -} - -void LLPipeline::setupSpotLight(LLGLSLShader& shader, LLDrawable* drawablep) -{ - //construct frustum - LLVOVolume* volume = drawablep->getVOVolume(); - LLVector3 params = volume->getSpotLightParams(); - - F32 fov = params.mV[0]; - F32 focus = params.mV[1]; - - LLVector3 pos = drawablep->getPositionAgent(); - LLQuaternion quat = volume->getRenderRotation(); - LLVector3 scale = volume->getScale(); - - //get near clip plane - LLVector3 at_axis(0,0,-scale.mV[2]*0.5f); - at_axis *= quat; - - LLVector3 np = pos+at_axis; - at_axis.normVec(); - - //get origin that has given fov for plane np, at_axis, and given scale - F32 dist = (scale.mV[1]*0.5f)/tanf(fov*0.5f); - - LLVector3 origin = np - at_axis*dist; - - //matrix from volume space to agent space - LLMatrix4 light_mat(quat, LLVector4(origin,1.f)); - - glh::matrix4f light_to_agent((F32*) light_mat.mMatrix); - glh::matrix4f light_to_screen = glh_get_current_modelview() * light_to_agent; - - glh::matrix4f screen_to_light = light_to_screen.inverse(); - - F32 s = volume->getLightRadius()*1.5f; - F32 near_clip = dist; - F32 width = scale.mV[VX]; - F32 height = scale.mV[VY]; - F32 far_clip = s+dist-scale.mV[VZ]; - - F32 fovy = fov * RAD_TO_DEG; - F32 aspect = width/height; - - glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f, - 0.f, 0.5f, 0.f, 0.5f, - 0.f, 0.f, 0.5f, 0.5f, - 0.f, 0.f, 0.f, 1.f); - - glh::vec3f p1(0, 0, -(near_clip+0.01f)); - glh::vec3f p2(0, 0, -(near_clip+1.f)); - - glh::vec3f screen_origin(0, 0, 0); - - light_to_screen.mult_matrix_vec(p1); - light_to_screen.mult_matrix_vec(p2); - light_to_screen.mult_matrix_vec(screen_origin); - - glh::vec3f n = p2-p1; - n.normalize(); - - F32 proj_range = far_clip - near_clip; - glh::matrix4f light_proj = gl_perspective(fovy, aspect, near_clip, far_clip); - screen_to_light = trans * light_proj * screen_to_light; - shader.uniformMatrix4fv("proj_mat", 1, FALSE, screen_to_light.m); - shader.uniform1f("proj_near", near_clip); - shader.uniform3fv("proj_p", 1, p1.v); - shader.uniform3fv("proj_n", 1, n.v); - shader.uniform3fv("proj_origin", 1, screen_origin.v); - shader.uniform1f("proj_range", proj_range); - shader.uniform1f("proj_ambiance", params.mV[2]); - S32 s_idx = -1; - - for (U32 i = 0; i < 2; i++) - { - if (mShadowSpotLight[i] == drawablep) - { - s_idx = i; - } - } - - shader.uniform1i("proj_shadow_idx", s_idx); - - if (s_idx >= 0) - { - shader.uniform1f("shadow_fade", 1.f-mSpotLightFade[s_idx]); - } - else - { - shader.uniform1f("shadow_fade", 1.f); - } - - { - LLDrawable* potential = drawablep; - //determine if this is a good light for casting shadows - F32 m_pri = volume->getSpotLightPriority(); - - for (U32 i = 0; i < 2; i++) - { - F32 pri = 0.f; - - if (mTargetShadowSpotLight[i].notNull()) - { - pri = mTargetShadowSpotLight[i]->getVOVolume()->getSpotLightPriority(); - } - - if (m_pri > pri) - { - LLDrawable* temp = mTargetShadowSpotLight[i]; - mTargetShadowSpotLight[i] = potential; - potential = temp; - m_pri = pri; - } - } - } - - LLViewerTexture* img = volume->getLightTexture(); - - S32 channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION); - - if (channel > -1 && img) - { - gGL.getTexUnit(channel)->bind(img); - - F32 lod_range = logf(img->getWidth())/logf(2.f); - - shader.uniform1f("proj_focus", focus); - shader.uniform1f("proj_lod", lod_range); - shader.uniform1f("proj_ambient_lod", llclamp((proj_range-focus)/proj_range*lod_range, 0.f, 1.f)); - } -} - -void LLPipeline::unbindDeferredShader(LLGLSLShader &shader) -{ - stop_glerror(); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_POSITION, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_NORMAL, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_SPECULAR, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_EDGE, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_SUN_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_LOCAL_LIGHT, LLTexUnit::TT_RECT_TEXTURE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_LUMINANCE); - shader.disableTexture(LLViewerShaderMgr::DIFFUSE_MAP); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MIP); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_BLOOM); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_NORMAL); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_DIFFUSE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_SPECULAR); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_DEPTH); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MIN_POS); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MAX_POS); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_NORMAL); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_DIFFUSE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MIN_POS); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MAX_POS); - - for (U32 i = 0; i < 4; i++) - { - if (shader.disableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i, LLTexUnit::TT_RECT_TEXTURE) > -1) - { - glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE); - } - } - - for (U32 i = 4; i < 6; i++) - { - if (shader.disableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i) > -1) - { - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE); - } - } - - shader.disableTexture(LLViewerShaderMgr::DEFERRED_NOISE); - shader.disableTexture(LLViewerShaderMgr::DEFERRED_LIGHTFUNC); - - S32 channel = shader.disableTexture(LLViewerShaderMgr::ENVIRONMENT_MAP, LLTexUnit::TT_CUBE_MAP); - if (channel > -1) - { - LLCubeMap* cube_map = gSky.mVOSkyp ? gSky.mVOSkyp->getCubeMap() : NULL; - if (cube_map) - { - cube_map->disable(); - } - } - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - gGL.getTexUnit(0)->activate(); - shader.unbind(); - - LLGLState::checkTextureChannels(); -} - -inline float sgn(float a) -{ - if (a > 0.0F) return (1.0F); - if (a < 0.0F) return (-1.0F); - return (0.0F); -} - -void LLPipeline::generateWaterReflection(LLCamera& camera_in) -{ - if (LLPipeline::sWaterReflections && assertInitialized() && LLDrawPoolWater::sNeedsReflectionUpdate) - { - BOOL skip_avatar_update = FALSE; - if (!isAgentAvatarValid() || gAgentCamera.getCameraAnimating() || gAgentCamera.getCameraMode() != CAMERA_MODE_MOUSELOOK) - { - skip_avatar_update = TRUE; - } - - if (!skip_avatar_update) - { - gAgentAvatarp->updateAttachmentVisibility(CAMERA_MODE_THIRD_PERSON); - } - LLVertexBuffer::unbind(); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - LLCamera camera = camera_in; - camera.setFar(camera.getFar()*0.87654321f); - LLPipeline::sReflectionRender = TRUE; - - gPipeline.pushRenderTypeMask(); - - glh::matrix4f projection = glh_get_current_projection(); - glh::matrix4f mat; - - stop_glerror(); - LLPlane plane; - - F32 height = gAgent.getRegion()->getWaterHeight(); - F32 to_clip = fabsf(camera.getOrigin().mV[2]-height); - F32 pad = -to_clip*0.05f; //amount to "pad" clip plane by - - //plane params - LLVector3 pnorm; - F32 pd; - - S32 water_clip = 0; - if (!LLViewerCamera::getInstance()->cameraUnderWater()) - { //camera is above water, clip plane points up - pnorm.setVec(0,0,1); - pd = -height; - plane.setVec(pnorm, pd); - water_clip = -1; - } - else - { //camera is below water, clip plane points down - pnorm = LLVector3(0,0,-1); - pd = height; - plane.setVec(pnorm, pd); - water_clip = 1; - } - - if (!LLViewerCamera::getInstance()->cameraUnderWater()) - { //generate planar reflection map - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - glClearColor(0,0,0,0); - mWaterRef.bindTarget(); - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WATER0; - gGL.setColorMask(true, true); - mWaterRef.clear(); - gGL.setColorMask(true, false); - - mWaterRef.getViewport(gGLViewport); - - stop_glerror(); - - glPushMatrix(); - - mat.set_scale(glh::vec3f(1,1,-1)); - mat.set_translate(glh::vec3f(0,0,height*2.f)); - - glh::matrix4f current = glh_get_current_modelview(); - - mat = current * mat; - - glh_set_current_modelview(mat); - glLoadMatrixf(mat.m); - - LLViewerCamera::updateFrustumPlanes(camera, FALSE, TRUE); - - glh::matrix4f inv_mat = mat.inverse(); - - glh::vec3f origin(0,0,0); - inv_mat.mult_matrix_vec(origin); - - camera.setOrigin(origin.v); - - glCullFace(GL_FRONT); - - static LLCullResult ref_result; - - if (LLDrawPoolWater::sNeedsDistortionUpdate) - { - //initial sky pass (no user clip plane) - { //mask out everything but the sky - gPipeline.pushRenderTypeMask(); - gPipeline.andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_WL_SKY, - LLPipeline::END_RENDER_TYPES); - - static LLCullResult result; - updateCull(camera, result); - stateSort(camera, result); - - andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_CLOUDS, - LLPipeline::RENDER_TYPE_WL_SKY, - LLPipeline::END_RENDER_TYPES); - - //bad pop here - renderGeom(camera, TRUE); - - gPipeline.popRenderTypeMask(); - } - - gPipeline.pushRenderTypeMask(); - - clearRenderTypeMask(LLPipeline::RENDER_TYPE_WATER, - LLPipeline::RENDER_TYPE_VOIDWATER, - LLPipeline::RENDER_TYPE_GROUND, - LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_CLOUDS, - LLPipeline::END_RENDER_TYPES); - - S32 detail = gSavedSettings.getS32("RenderReflectionDetail"); - if (detail > 0) - { //mask out selected geometry based on reflection detail - if (detail < 4) - { - clearRenderTypeMask(LLPipeline::RENDER_TYPE_PARTICLES, END_RENDER_TYPES); - if (detail < 3) - { - clearRenderTypeMask(LLPipeline::RENDER_TYPE_AVATAR, END_RENDER_TYPES); - if (detail < 2) - { - clearRenderTypeMask(LLPipeline::RENDER_TYPE_VOLUME, END_RENDER_TYPES); - } - } - } - - LLGLUserClipPlane clip_plane(plane, mat, projection); - LLGLDisable cull(GL_CULL_FACE); - updateCull(camera, ref_result, 1); - stateSort(camera, ref_result); - } - - if (LLDrawPoolWater::sNeedsDistortionUpdate) - { - if (gSavedSettings.getS32("RenderReflectionDetail") > 0) - { - gPipeline.grabReferences(ref_result); - LLGLUserClipPlane clip_plane(plane, mat, projection); - renderGeom(camera); - } - } - - gPipeline.popRenderTypeMask(); - } - glCullFace(GL_BACK); - glPopMatrix(); - mWaterRef.flush(); - glh_set_current_modelview(current); - } - - camera.setOrigin(camera_in.getOrigin()); - //render distortion map - static BOOL last_update = TRUE; - if (last_update) - { - camera.setFar(camera_in.getFar()); - clearRenderTypeMask(LLPipeline::RENDER_TYPE_WATER, - LLPipeline::RENDER_TYPE_VOIDWATER, - LLPipeline::RENDER_TYPE_GROUND, - END_RENDER_TYPES); - stop_glerror(); - - LLPipeline::sUnderWaterRender = LLViewerCamera::getInstance()->cameraUnderWater() ? FALSE : TRUE; - - if (LLPipeline::sUnderWaterRender) - { - clearRenderTypeMask(LLPipeline::RENDER_TYPE_GROUND, - LLPipeline::RENDER_TYPE_SKY, - LLPipeline::RENDER_TYPE_CLOUDS, - LLPipeline::RENDER_TYPE_WL_SKY, - END_RENDER_TYPES); - } - LLViewerCamera::updateFrustumPlanes(camera); - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - LLColor4& col = LLDrawPoolWater::sWaterFogColor; - glClearColor(col.mV[0], col.mV[1], col.mV[2], 0.f); - mWaterDis.bindTarget(); - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WATER1; - mWaterDis.getViewport(gGLViewport); - - if (!LLPipeline::sUnderWaterRender || LLDrawPoolWater::sNeedsReflectionUpdate) - { - //clip out geometry on the same side of water as the camera - mat = glh_get_current_modelview(); - LLGLUserClipPlane clip_plane(LLPlane(-pnorm, -(pd+pad)), mat, projection); - static LLCullResult result; - updateCull(camera, result, water_clip); - stateSort(camera, result); - - gGL.setColorMask(true, true); - mWaterDis.clear(); - gGL.setColorMask(true, false); - - renderGeom(camera); - } - - LLPipeline::sUnderWaterRender = FALSE; - mWaterDis.flush(); - } - last_update = LLDrawPoolWater::sNeedsReflectionUpdate && LLDrawPoolWater::sNeedsDistortionUpdate; - - LLRenderTarget::unbindTarget(); - - LLPipeline::sReflectionRender = FALSE; - - if (!LLRenderTarget::sUseFBO) - { - glClear(GL_DEPTH_BUFFER_BIT); - } - glClearColor(0.f, 0.f, 0.f, 0.f); - gViewerWindow->setup3DViewport(); - gPipeline.popRenderTypeMask(); - LLDrawPoolWater::sNeedsReflectionUpdate = FALSE; - LLDrawPoolWater::sNeedsDistortionUpdate = FALSE; - LLPlane npnorm(-pnorm, -pd); - LLViewerCamera::getInstance()->setUserClipPlane(npnorm); - - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - if (!skip_avatar_update) - { - gAgentAvatarp->updateAttachmentVisibility(gAgentCamera.getCameraMode()); - } - - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WORLD; - } -} - -glh::matrix4f look(const LLVector3 pos, const LLVector3 dir, const LLVector3 up) -{ - glh::matrix4f ret; - - LLVector3 dirN; - LLVector3 upN; - LLVector3 lftN; - - lftN = dir % up; - lftN.normVec(); - - upN = lftN % dir; - upN.normVec(); - - dirN = dir; - dirN.normVec(); - - ret.m[ 0] = lftN[0]; - ret.m[ 1] = upN[0]; - ret.m[ 2] = -dirN[0]; - ret.m[ 3] = 0.f; - - ret.m[ 4] = lftN[1]; - ret.m[ 5] = upN[1]; - ret.m[ 6] = -dirN[1]; - ret.m[ 7] = 0.f; - - ret.m[ 8] = lftN[2]; - ret.m[ 9] = upN[2]; - ret.m[10] = -dirN[2]; - ret.m[11] = 0.f; - - ret.m[12] = -(lftN*pos); - ret.m[13] = -(upN*pos); - ret.m[14] = dirN*pos; - ret.m[15] = 1.f; - - return ret; -} - -glh::matrix4f scale_translate_to_fit(const LLVector3 min, const LLVector3 max) -{ - glh::matrix4f ret; - ret.m[ 0] = 2/(max[0]-min[0]); - ret.m[ 4] = 0; - ret.m[ 8] = 0; - ret.m[12] = -(max[0]+min[0])/(max[0]-min[0]); - - ret.m[ 1] = 0; - ret.m[ 5] = 2/(max[1]-min[1]); - ret.m[ 9] = 0; - ret.m[13] = -(max[1]+min[1])/(max[1]-min[1]); - - ret.m[ 2] = 0; - ret.m[ 6] = 0; - ret.m[10] = 2/(max[2]-min[2]); - ret.m[14] = -(max[2]+min[2])/(max[2]-min[2]); - - ret.m[ 3] = 0; - ret.m[ 7] = 0; - ret.m[11] = 0; - ret.m[15] = 1; - - return ret; -} - -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) -{ - LLFastTimer t(FTM_SHADOW_RENDER); - - //clip out geometry on the same side of water as the camera - S32 occlude = LLPipeline::sUseOcclusion; - if (!use_occlusion) - { - LLPipeline::sUseOcclusion = 0; - } - LLPipeline::sShadowRender = TRUE; - - U32 types[] = { LLRenderPass::PASS_SIMPLE, LLRenderPass::PASS_FULLBRIGHT, LLRenderPass::PASS_SHINY, LLRenderPass::PASS_BUMP, LLRenderPass::PASS_FULLBRIGHT_SHINY }; - LLGLEnable cull(GL_CULL_FACE); - - if (use_shader) - { - gDeferredShadowProgram.bind(); - } - - updateCull(shadow_cam, result); - stateSort(shadow_cam, result); - - //generate shadow map - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadMatrixf(proj.m); - glMatrixMode(GL_MODELVIEW); - glPushMatrix(); - glLoadMatrixd(gGLModelView); - - stop_glerror(); - gGLLastMatrix = NULL; - - { - //LLGLDepthTest depth(GL_TRUE); - //glClear(GL_DEPTH_BUFFER_BIT); - } - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - glColor4f(1,1,1,1); - - stop_glerror(); - - gGL.setColorMask(false, false); - - //glCullFace(GL_FRONT); - - LLVertexBuffer::unbind(); - - { - LLFastTimer ftm(FTM_SHADOW_SIMPLE); - LLGLDisable test(GL_ALPHA_TEST); - gGL.getTexUnit(0)->disable(); - for (U32 i = 0; i < sizeof(types)/sizeof(U32); ++i) - { - renderObjects(types[i], LLVertexBuffer::MAP_VERTEX, FALSE); - } - gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE); - } - - if (use_shader) - { - gDeferredShadowProgram.unbind(); - renderGeomShadow(shadow_cam); - gDeferredShadowProgram.bind(); - } - else - { - renderGeomShadow(shadow_cam); - } - - { - LLFastTimer ftm(FTM_SHADOW_ALPHA); - LLGLEnable test(GL_ALPHA_TEST); - gGL.setAlphaRejectSettings(LLRender::CF_GREATER, 0.6f); - renderObjects(LLRenderPass::PASS_ALPHA_SHADOW, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0 | LLVertexBuffer::MAP_COLOR, TRUE); - glColor4f(1,1,1,1); - renderObjects(LLRenderPass::PASS_GRASS, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0, TRUE); - gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT); - } - - //glCullFace(GL_BACK); - - gGLLastMatrix = NULL; - glLoadMatrixd(gGLModelView); - doOcclusion(shadow_cam); - - if (use_shader) - { - gDeferredShadowProgram.unbind(); - } - - gGL.setColorMask(true, true); - - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - gGLLastMatrix = NULL; - - LLPipeline::sUseOcclusion = occlude; - LLPipeline::sShadowRender = FALSE; -} - -static LLFastTimer::DeclareTimer FTM_VISIBLE_CLOUD("Visible Cloud"); -BOOL LLPipeline::getVisiblePointCloud(LLCamera& camera, LLVector3& min, LLVector3& max, std::vector<LLVector3>& fp, LLVector3 light_dir) -{ - LLFastTimer t(FTM_VISIBLE_CLOUD); - //get point cloud of intersection of frust and min, max - - if (getVisibleExtents(camera, min, max)) - { - return FALSE; - } - - //get set of planes on bounding box - LLPlane bp[] = { - LLPlane(min, LLVector3(-1,0,0)), - LLPlane(min, LLVector3(0,-1,0)), - LLPlane(min, LLVector3(0,0,-1)), - LLPlane(max, LLVector3(1,0,0)), - LLPlane(max, LLVector3(0,1,0)), - LLPlane(max, LLVector3(0,0,1))}; - - //potential points - std::vector<LLVector3> pp; - - //add corners of AABB - pp.push_back(LLVector3(min.mV[0], min.mV[1], min.mV[2])); - pp.push_back(LLVector3(max.mV[0], min.mV[1], min.mV[2])); - pp.push_back(LLVector3(min.mV[0], max.mV[1], min.mV[2])); - pp.push_back(LLVector3(max.mV[0], max.mV[1], min.mV[2])); - pp.push_back(LLVector3(min.mV[0], min.mV[1], max.mV[2])); - pp.push_back(LLVector3(max.mV[0], min.mV[1], max.mV[2])); - pp.push_back(LLVector3(min.mV[0], max.mV[1], max.mV[2])); - pp.push_back(LLVector3(max.mV[0], max.mV[1], max.mV[2])); - - //add corners of camera frustum - for (U32 i = 0; i < 8; i++) - { - pp.push_back(camera.mAgentFrustum[i]); - } - - - //bounding box line segments - U32 bs[] = - { - 0,1, - 1,3, - 3,2, - 2,0, - - 4,5, - 5,7, - 7,6, - 6,4, - - 0,4, - 1,5, - 3,7, - 2,6 - }; - - for (U32 i = 0; i < 12; i++) - { //for each line segment in bounding box - for (U32 j = 0; j < 6; j++) - { //for each plane in camera frustum - const LLPlane& cp = camera.getAgentPlane(j); - const LLVector3& v1 = pp[bs[i*2+0]]; - const LLVector3& v2 = pp[bs[i*2+1]]; - LLVector3 n; - cp.getVector3(n); - - LLVector3 line = v1-v2; - - F32 d1 = line*n; - F32 d2 = -cp.dist(v2); - - F32 t = d2/d1; - - if (t > 0.f && t < 1.f) - { - LLVector3 intersect = v2+line*t; - pp.push_back(intersect); - } - } - } - - //camera frustum line segments - const U32 fs[] = - { - 0,1, - 1,2, - 2,3, - 3,0, - - 4,5, - 5,6, - 6,7, - 7,4, - - 0,4, - 1,5, - 2,6, - 3,7 - }; - - LLVector3 center = (max+min)*0.5f; - LLVector3 size = (max-min)*0.5f; - - for (U32 i = 0; i < 12; i++) - { - for (U32 j = 0; j < 6; ++j) - { - const LLVector3& v1 = pp[fs[i*2+0]+8]; - const LLVector3& v2 = pp[fs[i*2+1]+8]; - const LLPlane& cp = bp[j]; - LLVector3 n; - cp.getVector3(n); - - LLVector3 line = v1-v2; - - F32 d1 = line*n; - F32 d2 = -cp.dist(v2); - - F32 t = d2/d1; - - if (t > 0.f && t < 1.f) - { - LLVector3 intersect = v2+line*t; - pp.push_back(intersect); - } - } - } - - LLVector3 ext[] = { min-LLVector3(0.05f,0.05f,0.05f), - max+LLVector3(0.05f,0.05f,0.05f) }; - - for (U32 i = 0; i < pp.size(); ++i) - { - bool found = true; - - const F32* p = pp[i].mV; - - for (U32 j = 0; j < 3; ++j) - { - if (p[j] < ext[0].mV[j] || - p[j] > ext[1].mV[j]) - { - found = false; - break; - } - } - - for (U32 j = 0; j < 6; ++j) - { - const LLPlane& cp = camera.getAgentPlane(j); - F32 dist = cp.dist(pp[i]); - if (dist > 0.05f) //point is above some plane, not contained - { - found = false; - break; - } - } - - if (found) - { - fp.push_back(pp[i]); - } - } - - if (fp.empty()) - { - return FALSE; - } - - return TRUE; -} - -void LLPipeline::generateGI(LLCamera& camera, LLVector3& lightDir, std::vector<LLVector3>& vpc) -{ - if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) < 3) - { - return; - } - - LLVector3 up; - - //LLGLEnable depth_clamp(GL_DEPTH_CLAMP_NV); - - if (lightDir.mV[2] > 0.5f) - { - up = LLVector3(1,0,0); - } - else - { - up = LLVector3(0, 0, 1); - } - - - F32 gi_range = gSavedSettings.getF32("RenderGIRange"); - - U32 res = mGIMap.getWidth(); - - F32 atten = llmax(gSavedSettings.getF32("RenderGIAttenuation"), 0.001f); - - //set radius to range at which distance attenuation of incoming photons is near 0 - - F32 lrad = sqrtf(1.f/(atten*0.01f)); - - F32 lrange = lrad+gi_range*0.5f; - - LLVector3 pad(lrange,lrange,lrange); - - glh::matrix4f view = look(LLVector3(128.f,128.f,128.f), lightDir, up); - - LLVector3 cp = camera.getOrigin()+camera.getAtAxis()*(gi_range*0.5f); - - glh::vec3f scp(cp.mV); - view.mult_matrix_vec(scp); - cp.setVec(scp.v); - - F32 pix_width = lrange/(res*0.5f); - - //move cp to the nearest pix_width - for (U32 i = 0; i < 3; i++) - { - cp.mV[i] = llround(cp.mV[i], pix_width); - } - - LLVector3 min = cp-pad; - LLVector3 max = cp+pad; - - //set mGIRange to range in tc space[0,1] that covers texture block of intersecting lights around a point - mGIRange.mV[0] = (max.mV[0]-min.mV[0])/res; - mGIRange.mV[1] = (max.mV[1]-min.mV[1])/res; - mGILightRadius = lrad/lrange*0.5f; - - glh::matrix4f proj = gl_ortho(min.mV[0], max.mV[0], - min.mV[1], max.mV[1], - -max.mV[2], -min.mV[2]); - - LLCamera sun_cam = camera; - - glh::matrix4f eye_view = glh_get_current_modelview(); - - //get eye space to camera space matrix - mGIMatrix = view*eye_view.inverse(); - mGINormalMatrix = mGIMatrix.inverse().transpose(); - mGIInvProj = proj.inverse(); - mGIMatrixProj = proj*mGIMatrix; - - //translate and scale to [0,1] - glh::matrix4f trans(.5f, 0.f, 0.f, .5f, - 0.f, 0.5f, 0.f, 0.5f, - 0.f, 0.f, 0.5f, 0.5f, - 0.f, 0.f, 0.f, 1.f); - - mGIMatrixProj = trans*mGIMatrixProj; - - glh_set_current_modelview(view); - glh_set_current_projection(proj); - - LLViewerCamera::updateFrustumPlanes(sun_cam, TRUE, FALSE, TRUE); - - sun_cam.ignoreAgentFrustumPlane(LLCamera::AGENT_PLANE_NEAR); - static LLCullResult result; - - pushRenderTypeMask(); - - andRenderTypeMask(LLPipeline::RENDER_TYPE_SIMPLE, - LLPipeline::RENDER_TYPE_FULLBRIGHT, - LLPipeline::RENDER_TYPE_BUMP, - LLPipeline::RENDER_TYPE_VOLUME, - LLPipeline::RENDER_TYPE_TREE, - LLPipeline::RENDER_TYPE_TERRAIN, - LLPipeline::RENDER_TYPE_WATER, - LLPipeline::RENDER_TYPE_VOIDWATER, - LLPipeline::RENDER_TYPE_PASS_ALPHA_SHADOW, - LLPipeline::RENDER_TYPE_AVATAR, - LLPipeline::RENDER_TYPE_PASS_SIMPLE, - LLPipeline::RENDER_TYPE_PASS_BUMP, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT, - LLPipeline::RENDER_TYPE_PASS_SHINY, - END_RENDER_TYPES); - - - - S32 occlude = LLPipeline::sUseOcclusion; - //LLPipeline::sUseOcclusion = 0; - LLPipeline::sShadowRender = TRUE; - - //only render large objects into GI map - sMinRenderSize = gSavedSettings.getF32("RenderGIMinRenderSize"); - - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_GI_SOURCE; - mGIMap.bindTarget(); - - F64 last_modelview[16]; - F64 last_projection[16]; - for (U32 i = 0; i < 16; i++) - { - last_modelview[i] = gGLLastModelView[i]; - last_projection[i] = gGLLastProjection[i]; - gGLLastModelView[i] = mGIModelview.m[i]; - gGLLastProjection[i] = mGIProjection.m[i]; - } - - sun_cam.setOrigin(0.f, 0.f, 0.f); - updateCull(sun_cam, result); - stateSort(sun_cam, result); - - for (U32 i = 0; i < 16; i++) - { - gGLLastModelView[i] = last_modelview[i]; - gGLLastProjection[i] = last_projection[i]; - } - - mGIProjection = proj; - mGIModelview = view; - - LLGLEnable cull(GL_CULL_FACE); - - //generate GI map - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadMatrixf(proj.m); - glMatrixMode(GL_MODELVIEW); - glPushMatrix(); - glLoadMatrixf(view.m); - - stop_glerror(); - gGLLastMatrix = NULL; - - mGIMap.clear(); - - { - //LLGLEnable enable(GL_DEPTH_CLAMP_NV); - renderGeomDeferred(camera); - } - - mGIMap.flush(); - - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - gGLLastMatrix = NULL; - - LLPipeline::sUseOcclusion = occlude; - LLPipeline::sShadowRender = FALSE; - sMinRenderSize = 0.f; - - popRenderTypeMask(); - -} - -void LLPipeline::renderHighlight(const LLViewerObject* obj, F32 fade) -{ - if (obj && obj->getVolume()) - { - for (LLViewerObject::child_list_t::const_iterator iter = obj->getChildren().begin(); iter != obj->getChildren().end(); ++iter) - { - renderHighlight(*iter, fade); - } - - LLDrawable* drawable = obj->mDrawable; - if (drawable) - { - for (S32 i = 0; i < drawable->getNumFaces(); ++i) - { - LLFace* face = drawable->getFace(i); - if (face) - { - face->renderSelected(LLViewerTexture::sNullImagep, LLColor4(1,1,1,fade)); - } - } - } - } -} - -void LLPipeline::generateHighlight(LLCamera& camera) -{ - //render highlighted object as white into offscreen render target - if (mHighlightObject.notNull()) - { - mHighlightSet.insert(HighlightItem(mHighlightObject)); - } - - if (!mHighlightSet.empty()) - { - F32 transition = gFrameIntervalSeconds/gSavedSettings.getF32("RenderHighlightFadeTime"); - - LLGLDisable test(GL_ALPHA_TEST); - LLGLDepthTest depth(GL_FALSE); - mHighlight.bindTarget(); - disableLights(); - gGL.setColorMask(true, true); - mHighlight.clear(); - - gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep); - for (std::set<HighlightItem>::iterator iter = mHighlightSet.begin(); iter != mHighlightSet.end(); ) - { - std::set<HighlightItem>::iterator cur_iter = iter++; - - if (cur_iter->mItem.isNull()) - { - mHighlightSet.erase(cur_iter); - continue; - } - - if (cur_iter->mItem == mHighlightObject) - { - cur_iter->incrFade(transition); - } - else - { - cur_iter->incrFade(-transition); - if (cur_iter->mFade <= 0.f) - { - mHighlightSet.erase(cur_iter); - continue; - } - } - - renderHighlight(cur_iter->mItem->getVObj(), cur_iter->mFade); - } - - mHighlight.flush(); - gGL.setColorMask(true, false); - gViewerWindow->setup3DViewport(); - } -} - - -void LLPipeline::generateSunShadow(LLCamera& camera) -{ - if (!sRenderDeferred || gSavedSettings.getS32("RenderShadowDetail") <= 0) - { - return; - } - - F64 last_modelview[16]; - F64 last_projection[16]; - for (U32 i = 0; i < 16; i++) - { //store last_modelview of world camera - last_modelview[i] = gGLLastModelView[i]; - last_projection[i] = gGLLastProjection[i]; - } - - pushRenderTypeMask(); - andRenderTypeMask(LLPipeline::RENDER_TYPE_SIMPLE, - LLPipeline::RENDER_TYPE_ALPHA, - LLPipeline::RENDER_TYPE_GRASS, - LLPipeline::RENDER_TYPE_FULLBRIGHT, - LLPipeline::RENDER_TYPE_BUMP, - LLPipeline::RENDER_TYPE_VOLUME, - LLPipeline::RENDER_TYPE_AVATAR, - LLPipeline::RENDER_TYPE_TREE, - LLPipeline::RENDER_TYPE_TERRAIN, - LLPipeline::RENDER_TYPE_WATER, - LLPipeline::RENDER_TYPE_VOIDWATER, - LLPipeline::RENDER_TYPE_PASS_ALPHA_SHADOW, - LLPipeline::RENDER_TYPE_PASS_SIMPLE, - LLPipeline::RENDER_TYPE_PASS_BUMP, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT, - LLPipeline::RENDER_TYPE_PASS_SHINY, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY, - END_RENDER_TYPES); - - gGL.setColorMask(false, false); - - //get sun view matrix - - //store current projection/modelview matrix - glh::matrix4f saved_proj = glh_get_current_projection(); - glh::matrix4f saved_view = glh_get_current_modelview(); - glh::matrix4f inv_view = saved_view.inverse(); - - glh::matrix4f view[6]; - glh::matrix4f proj[6]; - - //clip contains parallel split distances for 3 splits - LLVector3 clip = gSavedSettings.getVector3("RenderShadowClipPlanes"); - - //F32 slope_threshold = gSavedSettings.getF32("RenderShadowSlopeThreshold"); - - //far clip on last split is minimum of camera view distance and 128 - mSunClipPlanes = LLVector4(clip, clip.mV[2] * clip.mV[2]/clip.mV[1]); - - clip = gSavedSettings.getVector3("RenderShadowOrthoClipPlanes"); - mSunOrthoClipPlanes = LLVector4(clip, clip.mV[2]*clip.mV[2]/clip.mV[1]); - - //currently used for amount to extrude frusta corners for constructing shadow frusta - LLVector3 n = gSavedSettings.getVector3("RenderShadowNearDist"); - //F32 nearDist[] = { n.mV[0], n.mV[1], n.mV[2], n.mV[2] }; - - //put together a universal "near clip" plane for shadow frusta - LLPlane shadow_near_clip; - { - LLVector3 p = gAgent.getPositionAgent(); - p += mSunDir * gSavedSettings.getF32("RenderFarClip")*2.f; - shadow_near_clip.setVec(p, mSunDir); - } - - LLVector3 lightDir = -mSunDir; - lightDir.normVec(); - - glh::vec3f light_dir(lightDir.mV); - - //create light space camera matrix - - LLVector3 at = lightDir; - - LLVector3 up = camera.getAtAxis(); - - if (fabsf(up*lightDir) > 0.75f) - { - up = camera.getUpAxis(); - } - - /*LLVector3 left = up%at; - up = at%left;*/ - - up.normVec(); - at.normVec(); - - - LLCamera main_camera = camera; - - F32 near_clip = 0.f; - { - //get visible point cloud - std::vector<LLVector3> fp; - - main_camera.calcAgentFrustumPlanes(main_camera.mAgentFrustum); - - LLVector3 min,max; - getVisiblePointCloud(main_camera,min,max,fp); - - if (fp.empty()) - { - if (!hasRenderDebugMask(RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowCamera[0] = main_camera; - mShadowExtents[0][0] = min; - mShadowExtents[0][1] = max; - - mShadowFrustPoints[0].clear(); - mShadowFrustPoints[1].clear(); - mShadowFrustPoints[2].clear(); - mShadowFrustPoints[3].clear(); - } - popRenderTypeMask(); - return; - } - - generateGI(camera, lightDir, fp); - - //get good split distances for frustum - for (U32 i = 0; i < fp.size(); ++i) - { - glh::vec3f v(fp[i].mV); - saved_view.mult_matrix_vec(v); - fp[i].setVec(v.v); - } - - min = fp[0]; - max = fp[0]; - - //get camera space bounding box - for (U32 i = 1; i < fp.size(); ++i) - { - update_min_max(min, max, fp[i]); - } - - near_clip = -max.mV[2]; - F32 far_clip = -min.mV[2]*2.f; - - far_clip = llmin(far_clip, 128.f); - far_clip = llmin(far_clip, camera.getFar()); - - F32 range = far_clip-near_clip; - - LLVector3 split_exp = gSavedSettings.getVector3("RenderShadowSplitExponent"); - - F32 da = 1.f-llmax( fabsf(lightDir*up), fabsf(lightDir*camera.getLeftAxis()) ); - - da = powf(da, split_exp.mV[2]); - - - F32 sxp = split_exp.mV[1] + (split_exp.mV[0]-split_exp.mV[1])*da; - - - for (U32 i = 0; i < 4; ++i) - { - F32 x = (F32)(i+1)/4.f; - x = powf(x, sxp); - mSunClipPlanes.mV[i] = near_clip+range*x; - } - } - - // convenience array of 4 near clip plane distances - F32 dist[] = { near_clip, mSunClipPlanes.mV[0], mSunClipPlanes.mV[1], mSunClipPlanes.mV[2], mSunClipPlanes.mV[3] }; - - for (S32 j = 0; j < 4; j++) - { - if (!hasRenderDebugMask(RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowFrustPoints[j].clear(); - } - - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW0+j; - - //restore render matrices - glh_set_current_modelview(saved_view); - glh_set_current_projection(saved_proj); - - LLVector3 eye = camera.getOrigin(); - - //camera used for shadow cull/render - LLCamera shadow_cam; - - //create world space camera frustum for this split - shadow_cam = camera; - shadow_cam.setFar(16.f); - - LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE); - - LLVector3* frust = shadow_cam.mAgentFrustum; - - LLVector3 pn = shadow_cam.getAtAxis(); - - LLVector3 min, max; - - //construct 8 corners of split frustum section - for (U32 i = 0; i < 4; i++) - { - LLVector3 delta = frust[i+4]-eye; - delta += (frust[i+4]-frust[(i+2)%4+4])*0.05f; - delta.normVec(); - F32 dp = delta*pn; - frust[i] = eye + (delta*dist[j]*0.95f)/dp; - frust[i+4] = eye + (delta*dist[j+1]*1.05f)/dp; - } - - shadow_cam.calcAgentFrustumPlanes(frust); - shadow_cam.mFrustumCornerDist = 0.f; - - if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowCamera[j] = shadow_cam; - } - - std::vector<LLVector3> fp; - - if (!gPipeline.getVisiblePointCloud(shadow_cam, min, max, fp, lightDir)) - { - //no possible shadow receivers - if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowExtents[j][0] = LLVector3(); - mShadowExtents[j][1] = LLVector3(); - mShadowCamera[j+4] = shadow_cam; - } - - mShadow[j].bindTarget(); - { - LLGLDepthTest depth(GL_TRUE); - mShadow[j].clear(); - } - mShadow[j].flush(); - - mShadowError.mV[j] = 0.f; - mShadowFOV.mV[j] = 0.f; - - continue; - } - - if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowExtents[j][0] = min; - mShadowExtents[j][1] = max; - mShadowFrustPoints[j] = fp; - } - - - //find a good origin for shadow projection - LLVector3 origin; - - //get a temporary view projection - view[j] = look(camera.getOrigin(), lightDir, -up); - - std::vector<LLVector3> wpf; - - for (U32 i = 0; i < fp.size(); i++) - { - glh::vec3f p = glh::vec3f(fp[i].mV); - view[j].mult_matrix_vec(p); - wpf.push_back(LLVector3(p.v)); - } - - min = wpf[0]; - max = wpf[0]; - - for (U32 i = 0; i < fp.size(); ++i) - { //get AABB in camera space - update_min_max(min, max, wpf[i]); - } - - // Construct a perspective transform with perspective along y-axis that contains - // points in wpf - //Known: - // - far clip plane - // - near clip plane - // - points in frustum - //Find: - // - origin - - //get some "interesting" points of reference - LLVector3 center = (min+max)*0.5f; - LLVector3 size = (max-min)*0.5f; - LLVector3 near_center = center; - near_center.mV[1] += size.mV[1]*2.f; - - - //put all points in wpf in quadrant 0, reletive to center of min/max - //get the best fit line using least squares - F32 bfm = 0.f; - F32 bfb = 0.f; - - for (U32 i = 0; i < wpf.size(); ++i) - { - wpf[i] -= center; - wpf[i].mV[0] = fabsf(wpf[i].mV[0]); - wpf[i].mV[2] = fabsf(wpf[i].mV[2]); - } - - if (!wpf.empty()) - { - F32 sx = 0.f; - F32 sx2 = 0.f; - F32 sy = 0.f; - F32 sxy = 0.f; - - for (U32 i = 0; i < wpf.size(); ++i) - { - sx += wpf[i].mV[0]; - sx2 += wpf[i].mV[0]*wpf[i].mV[0]; - sy += wpf[i].mV[1]; - sxy += wpf[i].mV[0]*wpf[i].mV[1]; - } - - bfm = (sy*sx-wpf.size()*sxy)/(sx*sx-wpf.size()*sx2); - bfb = (sx*sxy-sy*sx2)/(sx*sx-bfm*sx2); - } - - { - // best fit line is y=bfm*x+bfb - - //find point that is furthest to the right of line - F32 off_x = -1.f; - LLVector3 lp; - - for (U32 i = 0; i < wpf.size(); ++i) - { - //y = bfm*x+bfb - //x = (y-bfb)/bfm - F32 lx = (wpf[i].mV[1]-bfb)/bfm; - - lx = wpf[i].mV[0]-lx; - - if (off_x < lx) - { - off_x = lx; - lp = wpf[i]; - } - } - - //get line with slope bfm through lp - // bfb = y-bfm*x - bfb = lp.mV[1]-bfm*lp.mV[0]; - - //calculate error - mShadowError.mV[j] = 0.f; - - for (U32 i = 0; i < wpf.size(); ++i) - { - F32 lx = (wpf[i].mV[1]-bfb)/bfm; - mShadowError.mV[j] += fabsf(wpf[i].mV[0]-lx); - } - - mShadowError.mV[j] /= wpf.size(); - mShadowError.mV[j] /= size.mV[0]; - - if (mShadowError.mV[j] > gSavedSettings.getF32("RenderShadowErrorCutoff")) - { //just use ortho projection - mShadowFOV.mV[j] = -1.f; - origin.clearVec(); - proj[j] = gl_ortho(min.mV[0], max.mV[0], - min.mV[1], max.mV[1], - -max.mV[2], -min.mV[2]); - } - else - { - //origin is where line x = 0; - origin.setVec(0,bfb,0); - - F32 fovz = 1.f; - F32 fovx = 1.f; - - LLVector3 zp; - LLVector3 xp; - - for (U32 i = 0; i < wpf.size(); ++i) - { - LLVector3 atz = wpf[i]-origin; - atz.mV[0] = 0.f; - atz.normVec(); - if (fovz > -atz.mV[1]) - { - zp = wpf[i]; - fovz = -atz.mV[1]; - } - - LLVector3 atx = wpf[i]-origin; - atx.mV[2] = 0.f; - atx.normVec(); - if (fovx > -atx.mV[1]) - { - fovx = -atx.mV[1]; - xp = wpf[i]; - } - } - - fovx = acos(fovx); - fovz = acos(fovz); - - F32 cutoff = llmin(gSavedSettings.getF32("RenderShadowFOVCutoff"), 1.4f); - - mShadowFOV.mV[j] = fovx; - - if (fovx < cutoff && fovz > cutoff) - { - //x is a good fit, but z is too big, move away from zp enough so that fovz matches cutoff - F32 d = zp.mV[2]/tan(cutoff); - F32 ny = zp.mV[1] + fabsf(d); - - origin.mV[1] = ny; - - fovz = 1.f; - fovx = 1.f; - - for (U32 i = 0; i < wpf.size(); ++i) - { - LLVector3 atz = wpf[i]-origin; - atz.mV[0] = 0.f; - atz.normVec(); - fovz = llmin(fovz, -atz.mV[1]); - - LLVector3 atx = wpf[i]-origin; - atx.mV[2] = 0.f; - atx.normVec(); - fovx = llmin(fovx, -atx.mV[1]); - } - - fovx = acos(fovx); - fovz = acos(fovz); - - if (fovx > cutoff || llround(fovz, 0.01f) > cutoff) - { - // llerrs << "WTF?" << llendl; - } - - mShadowFOV.mV[j] = cutoff; - } - - - origin += center; - - F32 ynear = -(max.mV[1]-origin.mV[1]); - F32 yfar = -(min.mV[1]-origin.mV[1]); - - if (ynear < 0.1f) //keep a sensible near clip plane - { - F32 diff = 0.1f-ynear; - origin.mV[1] += diff; - ynear += diff; - yfar += diff; - } - - if (fovx > cutoff) - { //just use ortho projection - origin.clearVec(); - mShadowError.mV[j] = -1.f; - proj[j] = gl_ortho(min.mV[0], max.mV[0], - min.mV[1], max.mV[1], - -max.mV[2], -min.mV[2]); - } - else - { - //get perspective projection - view[j] = view[j].inverse(); - - glh::vec3f origin_agent(origin.mV); - - //translate view to origin - view[j].mult_matrix_vec(origin_agent); - - eye = LLVector3(origin_agent.v); - - if (!hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - mShadowFrustOrigin[j] = eye; - } - - view[j] = look(LLVector3(origin_agent.v), lightDir, -up); - - F32 fx = 1.f/tanf(fovx); - F32 fz = 1.f/tanf(fovz); - - proj[j] = glh::matrix4f(-fx, 0, 0, 0, - 0, (yfar+ynear)/(ynear-yfar), 0, (2.f*yfar*ynear)/(ynear-yfar), - 0, 0, -fz, 0, - 0, -1.f, 0, 0); - } - } - } - - shadow_cam.setFar(128.f); - shadow_cam.setOriginAndLookAt(eye, up, center); - - shadow_cam.setOrigin(0,0,0); - - glh_set_current_modelview(view[j]); - glh_set_current_projection(proj[j]); - - LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE); - - //shadow_cam.ignoreAgentFrustumPlane(LLCamera::AGENT_PLANE_NEAR); - shadow_cam.getAgentPlane(LLCamera::AGENT_PLANE_NEAR).set(shadow_near_clip); - - //translate and scale to from [-1, 1] to [0, 1] - glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f, - 0.f, 0.5f, 0.f, 0.5f, - 0.f, 0.f, 0.5f, 0.5f, - 0.f, 0.f, 0.f, 1.f); - - glh_set_current_modelview(view[j]); - glh_set_current_projection(proj[j]); - - for (U32 i = 0; i < 16; i++) - { - gGLLastModelView[i] = mShadowModelview[j].m[i]; - gGLLastProjection[i] = mShadowProjection[j].m[i]; - } - - mShadowModelview[j] = view[j]; - mShadowProjection[j] = proj[j]; - - - mSunShadowMatrix[j] = trans*proj[j]*view[j]*inv_view; - - stop_glerror(); - - mShadow[j].bindTarget(); - mShadow[j].getViewport(gGLViewport); - mShadow[j].clear(); - - { - static LLCullResult result[4]; - - //LLGLEnable enable(GL_DEPTH_CLAMP_NV); - renderShadow(view[j], proj[j], shadow_cam, result[j], TRUE); - } - - mShadow[j].flush(); - - if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA)) - { - LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE); - mShadowCamera[j+4] = shadow_cam; - } - } - - - //hack to disable projector shadows - bool gen_shadow = gSavedSettings.getS32("RenderShadowDetail") > 1; - - if (gen_shadow) - { - F32 fade_amt = gFrameIntervalSeconds * llmax(LLViewerCamera::getInstance()->getVelocityStat()->getCurrentPerSec(), 1.f); - - //update shadow targets - for (U32 i = 0; i < 2; i++) - { //for each current shadow - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW4+i; - - if (mShadowSpotLight[i].notNull() && - (mShadowSpotLight[i] == mTargetShadowSpotLight[0] || - mShadowSpotLight[i] == mTargetShadowSpotLight[1])) - { //keep this spotlight - mSpotLightFade[i] = llmin(mSpotLightFade[i]+fade_amt, 1.f); - } - else - { //fade out this light - mSpotLightFade[i] = llmax(mSpotLightFade[i]-fade_amt, 0.f); - - if (mSpotLightFade[i] == 0.f || mShadowSpotLight[i].isNull()) - { //faded out, grab one of the pending spots (whichever one isn't already taken) - if (mTargetShadowSpotLight[0] != mShadowSpotLight[(i+1)%2]) - { - mShadowSpotLight[i] = mTargetShadowSpotLight[0]; - } - else - { - mShadowSpotLight[i] = mTargetShadowSpotLight[1]; - } - } - } - } - - for (S32 i = 0; i < 2; i++) - { - glh_set_current_modelview(saved_view); - glh_set_current_projection(saved_proj); - - if (mShadowSpotLight[i].isNull()) - { - continue; - } - - LLVOVolume* volume = mShadowSpotLight[i]->getVOVolume(); - - if (!volume) - { - mShadowSpotLight[i] = NULL; - continue; - } - - LLDrawable* drawable = mShadowSpotLight[i]; - - LLVector3 params = volume->getSpotLightParams(); - F32 fov = params.mV[0]; - - //get agent->light space matrix (modelview) - LLVector3 center = drawable->getPositionAgent(); - LLQuaternion quat = volume->getRenderRotation(); - - //get near clip plane - LLVector3 scale = volume->getScale(); - LLVector3 at_axis(0,0,-scale.mV[2]*0.5f); - at_axis *= quat; - - LLVector3 np = center+at_axis; - at_axis.normVec(); - - //get origin that has given fov for plane np, at_axis, and given scale - F32 dist = (scale.mV[1]*0.5f)/tanf(fov*0.5f); - - LLVector3 origin = np - at_axis*dist; - - LLMatrix4 mat(quat, LLVector4(origin, 1.f)); - - view[i+4] = glh::matrix4f((F32*) mat.mMatrix); - - view[i+4] = view[i+4].inverse(); - - //get perspective matrix - F32 near_clip = dist+0.01f; - F32 width = scale.mV[VX]; - F32 height = scale.mV[VY]; - F32 far_clip = dist+volume->getLightRadius()*1.5f; - - F32 fovy = fov * RAD_TO_DEG; - F32 aspect = width/height; - - proj[i+4] = gl_perspective(fovy, aspect, near_clip, far_clip); - - //translate and scale to from [-1, 1] to [0, 1] - glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f, - 0.f, 0.5f, 0.f, 0.5f, - 0.f, 0.f, 0.5f, 0.5f, - 0.f, 0.f, 0.f, 1.f); - - glh_set_current_modelview(view[i+4]); - glh_set_current_projection(proj[i+4]); - - mSunShadowMatrix[i+4] = trans*proj[i+4]*view[i+4]*inv_view; - - for (U32 j = 0; j < 16; j++) - { - gGLLastModelView[j] = mShadowModelview[i+4].m[j]; - gGLLastProjection[j] = mShadowProjection[i+4].m[j]; - } - - mShadowModelview[i+4] = view[i+4]; - mShadowProjection[i+4] = proj[i+4]; - - LLCamera shadow_cam = camera; - shadow_cam.setFar(far_clip); - shadow_cam.setOrigin(origin); - - LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE); - - stop_glerror(); - - mShadow[i+4].bindTarget(); - mShadow[i+4].getViewport(gGLViewport); - mShadow[i+4].clear(); - - static LLCullResult result[2]; - - LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW0+i+4; - - renderShadow(view[i+4], proj[i+4], shadow_cam, result[i], FALSE, FALSE); - - mShadow[i+4].flush(); - } - } - - if (!gSavedSettings.getBOOL("CameraOffset")) - { - glh_set_current_modelview(saved_view); - glh_set_current_projection(saved_proj); - } - else - { - glh_set_current_modelview(view[1]); - glh_set_current_projection(proj[1]); - glLoadMatrixf(view[1].m); - glMatrixMode(GL_PROJECTION); - glLoadMatrixf(proj[1].m); - glMatrixMode(GL_MODELVIEW); - } - gGL.setColorMask(true, false); - - for (U32 i = 0; i < 16; i++) - { - gGLLastModelView[i] = last_modelview[i]; - gGLLastProjection[i] = last_projection[i]; - } - - popRenderTypeMask(); -} - -void LLPipeline::renderGroups(LLRenderPass* pass, U32 type, U32 mask, BOOL texture) -{ - for (LLCullResult::sg_list_t::iterator i = sCull->beginVisibleGroups(); i != sCull->endVisibleGroups(); ++i) - { - LLSpatialGroup* group = *i; - if (!group->isDead() && - (!sUseOcclusion || !group->isOcclusionState(LLSpatialGroup::OCCLUDED)) && - gPipeline.hasRenderType(group->mSpatialPartition->mDrawableType) && - group->mDrawMap.find(type) != group->mDrawMap.end()) - { - pass->renderGroup(group,type,mask,texture); - } - } -} - -void LLPipeline::generateImpostor(LLVOAvatar* avatar) -{ - LLMemType mt_gi(LLMemType::MTYPE_PIPELINE_GENERATE_IMPOSTOR); - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); - - static LLCullResult result; - result.clear(); - grabReferences(result); - - if (!avatar || !avatar->mDrawable) - { - return; - } - - assertInitialized(); - - BOOL muted = LLMuteList::getInstance()->isMuted(avatar->getID()); - - pushRenderTypeMask(); - - if (muted) - { - andRenderTypeMask(LLPipeline::RENDER_TYPE_AVATAR, END_RENDER_TYPES); - } - else - { - andRenderTypeMask(LLPipeline::RENDER_TYPE_VOLUME, - LLPipeline::RENDER_TYPE_AVATAR, - LLPipeline::RENDER_TYPE_BUMP, - LLPipeline::RENDER_TYPE_GRASS, - LLPipeline::RENDER_TYPE_SIMPLE, - LLPipeline::RENDER_TYPE_FULLBRIGHT, - LLPipeline::RENDER_TYPE_ALPHA, - LLPipeline::RENDER_TYPE_INVISIBLE, - LLPipeline::RENDER_TYPE_PASS_SIMPLE, - LLPipeline::RENDER_TYPE_PASS_ALPHA, - LLPipeline::RENDER_TYPE_PASS_ALPHA_MASK, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_ALPHA_MASK, - LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY, - LLPipeline::RENDER_TYPE_PASS_SHINY, - LLPipeline::RENDER_TYPE_PASS_INVISIBLE, - LLPipeline::RENDER_TYPE_PASS_INVISI_SHINY, - END_RENDER_TYPES); - } - - S32 occlusion = sUseOcclusion; - sUseOcclusion = 0; - sReflectionRender = sRenderDeferred ? FALSE : TRUE; - sShadowRender = TRUE; - sImpostorRender = TRUE; - - LLViewerCamera* viewer_camera = LLViewerCamera::getInstance(); - markVisible(avatar->mDrawable, *viewer_camera); - LLVOAvatar::sUseImpostors = FALSE; - - LLVOAvatar::attachment_map_t::iterator iter; - for (iter = avatar->mAttachmentPoints.begin(); - iter != avatar->mAttachmentPoints.end(); - ++iter) - { - LLViewerJointAttachment *attachment = iter->second; - for (LLViewerJointAttachment::attachedobjs_vec_t::iterator attachment_iter = attachment->mAttachedObjects.begin(); - attachment_iter != attachment->mAttachedObjects.end(); - ++attachment_iter) - { - if (LLViewerObject* attached_object = (*attachment_iter)) - { - markVisible(attached_object->mDrawable->getSpatialBridge(), *viewer_camera); - } - } - } - - stateSort(*LLViewerCamera::getInstance(), result); - - const LLVector4a* ext = avatar->mDrawable->getSpatialExtents(); - LLVector3 pos(avatar->getRenderPosition()+avatar->getImpostorOffset()); - - LLCamera camera = *viewer_camera; - - camera.lookAt(viewer_camera->getOrigin(), pos, viewer_camera->getUpAxis()); - - LLVector2 tdim; - - - LLVector4a half_height; - half_height.setSub(ext[1], ext[0]); - half_height.mul(0.5f); - - LLVector4a left; - left.load3(camera.getLeftAxis().mV); - left.mul(left); - left.normalize3fast(); - - LLVector4a up; - up.load3(camera.getUpAxis().mV); - up.mul(up); - up.normalize3fast(); - - tdim.mV[0] = fabsf(half_height.dot3(left).getF32()); - tdim.mV[1] = fabsf(half_height.dot3(up).getF32()); - - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - - F32 distance = (pos-camera.getOrigin()).length(); - F32 fov = atanf(tdim.mV[1]/distance)*2.f*RAD_TO_DEG; - F32 aspect = tdim.mV[0]/tdim.mV[1]; - glh::matrix4f persp = gl_perspective(fov, aspect, 1.f, 256.f); - glh_set_current_projection(persp); - glLoadMatrixf(persp.m); - - glMatrixMode(GL_MODELVIEW); - glPushMatrix(); - glh::matrix4f mat; - camera.getOpenGLTransform(mat.m); - - mat = glh::matrix4f((GLfloat*) OGL_TO_CFR_ROTATION) * mat; - - glLoadMatrixf(mat.m); - glh_set_current_modelview(mat); - - glClearColor(0.0f,0.0f,0.0f,0.0f); - gGL.setColorMask(true, true); - - // get the number of pixels per angle - F32 pa = gViewerWindow->getWindowHeightRaw() / (RAD_TO_DEG * viewer_camera->getView()); - - //get resolution based on angle width and height of impostor (double desired resolution to prevent aliasing) - U32 resY = llmin(nhpo2((U32) (fov*pa)), (U32) 512); - U32 resX = llmin(nhpo2((U32) (atanf(tdim.mV[0]/distance)*2.f*RAD_TO_DEG*pa)), (U32) 512); - - if (!avatar->mImpostor.isComplete() || resX != avatar->mImpostor.getWidth() || - resY != avatar->mImpostor.getHeight()) - { - avatar->mImpostor.allocate(resX,resY,GL_RGBA,TRUE,FALSE); - - if (LLPipeline::sRenderDeferred) - { - addDeferredAttachments(avatar->mImpostor); - } - - gGL.getTexUnit(0)->bind(&avatar->mImpostor); - gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT); - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - } - - avatar->mImpostor.bindTarget(); - - if (LLPipeline::sRenderDeferred) - { - avatar->mImpostor.clear(); - renderGeomDeferred(camera); - renderGeomPostDeferred(camera); - } - else - { - LLGLEnable scissor(GL_SCISSOR_TEST); - glScissor(0, 0, resX, resY); - avatar->mImpostor.clear(); - renderGeom(camera); - } - - { //create alpha mask based on depth buffer (grey out if muted) - if (LLPipeline::sRenderDeferred) - { - GLuint buff = GL_COLOR_ATTACHMENT0; - glDrawBuffersARB(1, &buff); - } - - LLGLDisable blend(GL_BLEND); - - if (muted) - { - gGL.setColorMask(true, true); - } - else - { - gGL.setColorMask(false, true); - } - - gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); - - LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_GREATER); - - gGL.flush(); - - glPushMatrix(); - glLoadIdentity(); - glMatrixMode(GL_PROJECTION); - glPushMatrix(); - glLoadIdentity(); - - static const F32 clip_plane = 0.99999f; - - gGL.color4ub(64,64,64,255); - gGL.begin(LLRender::QUADS); - gGL.vertex3f(-1, -1, clip_plane); - gGL.vertex3f(1, -1, clip_plane); - gGL.vertex3f(1, 1, clip_plane); - gGL.vertex3f(-1, 1, clip_plane); - gGL.end(); - gGL.flush(); - - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - } - - avatar->mImpostor.flush(); - - avatar->setImpostorDim(tdim); - - LLVOAvatar::sUseImpostors = TRUE; - sUseOcclusion = occlusion; - sReflectionRender = FALSE; - sImpostorRender = FALSE; - sShadowRender = FALSE; - popRenderTypeMask(); - - glMatrixMode(GL_PROJECTION); - glPopMatrix(); - glMatrixMode(GL_MODELVIEW); - glPopMatrix(); - - avatar->mNeedsImpostorUpdate = FALSE; - avatar->cacheImpostorValues(); - - LLVertexBuffer::unbind(); - LLGLState::checkStates(); - LLGLState::checkTextureChannels(); - LLGLState::checkClientArrays(); -} - -BOOL LLPipeline::hasRenderBatches(const U32 type) const -{ - return sCull->getRenderMapSize(type) > 0; -} - -LLCullResult::drawinfo_list_t::iterator LLPipeline::beginRenderMap(U32 type) -{ - return sCull->beginRenderMap(type); -} - -LLCullResult::drawinfo_list_t::iterator LLPipeline::endRenderMap(U32 type) -{ - return sCull->endRenderMap(type); -} - -LLCullResult::sg_list_t::iterator LLPipeline::beginAlphaGroups() -{ - return sCull->beginAlphaGroups(); -} - -LLCullResult::sg_list_t::iterator LLPipeline::endAlphaGroups() -{ - return sCull->endAlphaGroups(); -} - -BOOL LLPipeline::hasRenderType(const U32 type) const -{ - // STORM-365 : LLViewerJointAttachment::setAttachmentVisibility() is setting type to 0 to actually mean "do not render" - // We then need to test that value here and return FALSE to prevent attachment to render (in mouselook for instance) - // TODO: reintroduce RENDER_TYPE_NONE in LLRenderTypeMask and initialize its mRenderTypeEnabled[RENDER_TYPE_NONE] to FALSE explicitely - return (type == 0 ? FALSE : mRenderTypeEnabled[type]); -} - -void LLPipeline::setRenderTypeMask(U32 type, ...) -{ - va_list args; - - va_start(args, type); - while (type < END_RENDER_TYPES) - { - mRenderTypeEnabled[type] = TRUE; - type = va_arg(args, U32); - } - va_end(args); - - if (type > END_RENDER_TYPES) - { - llerrs << "Invalid render type." << llendl; - } -} - -BOOL LLPipeline::hasAnyRenderType(U32 type, ...) const -{ - va_list args; - - va_start(args, type); - while (type < END_RENDER_TYPES) - { - if (mRenderTypeEnabled[type]) - { - return TRUE; - } - type = va_arg(args, U32); - } - va_end(args); - - if (type > END_RENDER_TYPES) - { - llerrs << "Invalid render type." << llendl; - } - - return FALSE; -} - -void LLPipeline::pushRenderTypeMask() -{ - std::string cur_mask; - cur_mask.assign((const char*) mRenderTypeEnabled, sizeof(mRenderTypeEnabled)); - mRenderTypeEnableStack.push(cur_mask); -} - -void LLPipeline::popRenderTypeMask() -{ - if (mRenderTypeEnableStack.empty()) - { - llerrs << "Depleted render type stack." << llendl; - } - - memcpy(mRenderTypeEnabled, mRenderTypeEnableStack.top().data(), sizeof(mRenderTypeEnabled)); - mRenderTypeEnableStack.pop(); -} - -void LLPipeline::andRenderTypeMask(U32 type, ...) -{ - va_list args; - - BOOL tmp[NUM_RENDER_TYPES]; - for (U32 i = 0; i < NUM_RENDER_TYPES; ++i) - { - tmp[i] = FALSE; - } - - va_start(args, type); - while (type < END_RENDER_TYPES) - { - if (mRenderTypeEnabled[type]) - { - tmp[type] = TRUE; - } - - type = va_arg(args, U32); - } - va_end(args); - - if (type > END_RENDER_TYPES) - { - llerrs << "Invalid render type." << llendl; - } - - for (U32 i = 0; i < LLPipeline::NUM_RENDER_TYPES; ++i) - { - mRenderTypeEnabled[i] = tmp[i]; - } - -} - -void LLPipeline::clearRenderTypeMask(U32 type, ...) -{ - va_list args; - - va_start(args, type); - while (type < END_RENDER_TYPES) - { - mRenderTypeEnabled[type] = FALSE; - - type = va_arg(args, U32); - } - va_end(args); - - if (type > END_RENDER_TYPES) - { - llerrs << "Invalid render type." << llendl; - } -} - - + }
+ else
+ {
+ focus_point = gDebugRaycastIntersection;
+ }
+ }
+ }
+
+ LLVector3 eye = LLViewerCamera::getInstance()->getOrigin();
+ F32 target_distance = 16.f;
+ if (!focus_point.isExactlyZero())
+ {
+ target_distance = LLViewerCamera::getInstance()->getAtAxis() * (focus_point-eye);
+ }
+
+ if (transition_time >= 1.f &&
+ fabsf(current_distance-target_distance)/current_distance > 0.01f)
+ { //large shift happened, interpolate smoothly to new target distance
+ transition_time = 0.f;
+ start_distance = current_distance;
+ }
+ else if (transition_time < 1.f)
+ { //currently in a transition, continue interpolating
+ transition_time += 1.f/gSavedSettings.getF32("CameraFocusTransitionTime")*gFrameIntervalSeconds;
+ transition_time = llmin(transition_time, 1.f);
+
+ F32 t = cosf(transition_time*F_PI+F_PI)*0.5f+0.5f;
+ current_distance = start_distance + (target_distance-start_distance)*t;
+ }
+ else
+ { //small or no change, just snap to target distance
+ current_distance = target_distance;
+ }
+
+ //convert to mm
+ F32 subject_distance = current_distance*1000.f;
+ F32 fnumber = gSavedSettings.getF32("CameraFNumber");
+ F32 default_focal_length = gSavedSettings.getF32("CameraFocalLength");
+
+ if (LLToolMgr::getInstance()->inBuildMode())
+ { //squish focal length when in build mode so DoF doesn't make editing objects difficult
+ default_focal_length = 5.f;
+ }
+
+ F32 fov = LLViewerCamera::getInstance()->getView();
+
+ const F32 default_fov = gSavedSettings.getF32("CameraFieldOfView") * F_PI/180.f;
+ //const F32 default_aspect_ratio = gSavedSettings.getF32("CameraAspectRatio");
+
+ //F32 aspect_ratio = (F32) mScreen.getWidth()/(F32)mScreen.getHeight();
+
+ F32 dv = 2.f*default_focal_length * tanf(default_fov/2.f);
+ //F32 dh = 2.f*default_focal_length * tanf(default_fov*default_aspect_ratio/2.f);
+
+ F32 focal_length = dv/(2*tanf(fov/2.f));
+
+ //F32 tan_pixel_angle = tanf(LLDrawable::sCurPixelAngle);
+
+ // from wikipedia -- c = |s2-s1|/s2 * f^2/(N(S1-f))
+ // where N = fnumber
+ // s2 = dot distance
+ // s1 = subject distance
+ // f = focal length
+ //
+
+ F32 blur_constant = focal_length*focal_length/(fnumber*(subject_distance-focal_length));
+ blur_constant /= 1000.f; //convert to meters for shader
+ F32 magnification = focal_length/(subject_distance-focal_length);
+
+ shader->uniform1f("focal_distance", -subject_distance/1000.f);
+ shader->uniform1f("blur_constant", blur_constant);
+ shader->uniform1f("tan_pixel_angle", tanf(1.f/LLDrawable::sCurPixelAngle));
+ shader->uniform1f("magnification", magnification);
+
+ S32 channel = shader->enableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mScreen.bindTexture(0, channel);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+ //channel = shader->enableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE);
+ //if (channel > -1)
+ //{
+ //gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ //}
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.texCoord2f(tc1.mV[0], tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc1.mV[0], tc2.mV[1]);
+ gGL.vertex2f(-1,3);
+
+ gGL.texCoord2f(tc2.mV[0], tc1.mV[1]);
+ gGL.vertex2f(3,-1);
+
+ gGL.end();
+
+ unbindDeferredShader(*shader);
+ }
+ else
+ {
+ if (res_mod > 1)
+ {
+ tc2 /= (F32) res_mod;
+ }
+
+ U32 mask = LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0 | LLVertexBuffer::MAP_TEXCOORD1;
+ LLPointer<LLVertexBuffer> buff = new LLVertexBuffer(mask, 0);
+ buff->allocateBuffer(3,0,TRUE);
+
+ LLStrider<LLVector3> v;
+ LLStrider<LLVector2> uv1;
+ LLStrider<LLVector2> uv2;
+
+ buff->getVertexStrider(v);
+ buff->getTexCoord0Strider(uv1);
+ buff->getTexCoord1Strider(uv2);
+
+ uv1[0] = LLVector2(0, 0);
+ uv1[1] = LLVector2(0, 2);
+ uv1[2] = LLVector2(2, 0);
+
+ uv2[0] = LLVector2(0, 0);
+ uv2[1] = LLVector2(0, tc2.mV[1]*2.f);
+ uv2[2] = LLVector2(tc2.mV[0]*2.f, 0);
+
+ v[0] = LLVector3(-1,-1,0);
+ v[1] = LLVector3(-1,3,0);
+ v[2] = LLVector3(3,-1,0);
+
+ buff->setBuffer(0);
+
+ LLGLDisable blend(GL_BLEND);
+
+ //tex unit 0
+ gGL.getTexUnit(0)->setTextureColorBlend(LLTexUnit::TBO_REPLACE, LLTexUnit::TBS_TEX_COLOR);
+
+ gGL.getTexUnit(0)->bind(&mGlow[1]);
+ gGL.getTexUnit(1)->activate();
+ gGL.getTexUnit(1)->enable(LLTexUnit::TT_RECT_TEXTURE);
+
+
+ //tex unit 1
+ gGL.getTexUnit(1)->setTextureColorBlend(LLTexUnit::TBO_ADD, LLTexUnit::TBS_TEX_COLOR, LLTexUnit::TBS_PREV_COLOR);
+
+ gGL.getTexUnit(1)->bind(&mScreen);
+ gGL.getTexUnit(1)->activate();
+
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+
+ buff->setBuffer(mask);
+ buff->drawArrays(LLRender::TRIANGLE_STRIP, 0, 3);
+
+ gGL.getTexUnit(1)->disable();
+ gGL.getTexUnit(1)->setTextureBlendType(LLTexUnit::TB_MULT);
+
+ gGL.getTexUnit(0)->activate();
+ gGL.getTexUnit(0)->setTextureBlendType(LLTexUnit::TB_MULT);
+ }
+
+ if (LLRenderTarget::sUseFBO)
+ { //copy depth buffer from mScreen to framebuffer
+ LLRenderTarget::copyContentsToFramebuffer(mScreen, 0, 0, mScreen.getWidth(), mScreen.getHeight(),
+ 0, 0, mScreen.getWidth(), mScreen.getHeight(), GL_DEPTH_BUFFER_BIT, GL_NEAREST);
+ }
+
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+
+ if (hasRenderDebugMask(LLPipeline::RENDER_DEBUG_PHYSICS_SHAPES))
+ {
+ LLVector2 tc1(0,0);
+ LLVector2 tc2((F32) gViewerWindow->getWorldViewWidthRaw()*2,
+ (F32) gViewerWindow->getWorldViewHeightRaw()*2);
+
+ LLGLEnable blend(GL_BLEND);
+ gGL.color4f(1,1,1,0.75f);
+
+ gGL.getTexUnit(0)->bind(&mPhysicsDisplay);
+
+ gGL.begin(LLRender::TRIANGLE_STRIP);
+ gGL.texCoord2f(tc1.mV[0], tc1.mV[1]);
+ gGL.vertex2f(-1,-1);
+
+ gGL.texCoord2f(tc1.mV[0], tc2.mV[1]);
+ gGL.vertex2f(-1,3);
+
+ gGL.texCoord2f(tc2.mV[0], tc1.mV[1]);
+ gGL.vertex2f(3,-1);
+
+ gGL.end();
+ gGL.flush();
+ }
+
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+
+ LLVertexBuffer::unbind();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+
+}
+
+static LLFastTimer::DeclareTimer FTM_BIND_DEFERRED("Bind Deferred");
+
+void LLPipeline::bindDeferredShader(LLGLSLShader& shader, U32 light_index, LLRenderTarget* gi_source, LLRenderTarget* last_gi_post, U32 noise_map)
+{
+ LLFastTimer t(FTM_BIND_DEFERRED);
+
+ if (noise_map == 0xFFFFFFFF)
+ {
+ noise_map = mNoiseMap;
+ }
+
+ LLGLState::checkTextureChannels();
+
+ shader.bind();
+ S32 channel = 0;
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredScreen.bindTexture(0,channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SPECULAR, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredScreen.bindTexture(1, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_NORMAL, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredScreen.bindTexture(2, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ if (gi_source)
+ {
+ BOOL has_gi = FALSE;
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_DIFFUSE);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gi_source->bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_SPECULAR);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gi_source->bindTexture(1, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_NORMAL);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gi_source->bindTexture(2, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_MIN_POS);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gi_source->bindTexture(1, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_MAX_POS);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gi_source->bindTexture(3, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_DIFFUSE);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ last_gi_post->bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_NORMAL);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ last_gi_post->bindTexture(2, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MAX_POS);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ last_gi_post->bindTexture(1, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MIN_POS);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ last_gi_post->bindTexture(3, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_DEPTH);
+ if (channel > -1)
+ {
+ has_gi = TRUE;
+ gGL.getTexUnit(channel)->bind(gi_source, TRUE);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ stop_glerror();
+
+ glTexParameteri(LLTexUnit::getInternalType(mGIMap.getUsage()), GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE);
+ glTexParameteri(LLTexUnit::getInternalType(mGIMap.getUsage()), GL_DEPTH_TEXTURE_MODE_ARB, GL_ALPHA);
+
+ stop_glerror();
+ }
+
+ if (has_gi)
+ {
+ F32 range_x = llmin(mGIRange.mV[0], 1.f);
+ F32 range_y = llmin(mGIRange.mV[1], 1.f);
+
+ LLVector2 scale(range_x,range_y);
+
+ LLVector2 kern[25];
+
+ for (S32 i = 0; i < 5; ++i)
+ {
+ for (S32 j = 0; j < 5; ++j)
+ {
+ S32 idx = i*5+j;
+ kern[idx].mV[0] = (i-2)*0.5f;
+ kern[idx].mV[1] = (j-2)*0.5f;
+ kern[idx].scaleVec(scale);
+ }
+ }
+
+ shader.uniform2fv("gi_kern", 25, (F32*) kern);
+ shader.uniformMatrix4fv("gi_mat", 1, FALSE, mGIMatrix.m);
+ shader.uniformMatrix4fv("gi_mat_proj", 1, FALSE, mGIMatrixProj.m);
+ shader.uniformMatrix4fv("gi_inv_proj", 1, FALSE, mGIInvProj.m);
+ shader.uniformMatrix4fv("gi_norm_mat", 1, FALSE, mGINormalMatrix.m);
+ }
+ }
+
+ /*channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_POSITION, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredScreen.bindTexture(3, channel);
+ }*/
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ gGL.getTexUnit(channel)->bind(&mDeferredDepth, TRUE);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ stop_glerror();
+
+ glTexParameteri(LLTexUnit::getInternalType(mDeferredDepth.getUsage()), GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE);
+ glTexParameteri(LLTexUnit::getInternalType(mDeferredDepth.getUsage()), GL_DEPTH_TEXTURE_MODE_ARB, GL_ALPHA);
+
+ stop_glerror();
+
+ glh::matrix4f projection = glh_get_current_projection();
+ glh::matrix4f inv_proj = projection.inverse();
+
+ shader.uniformMatrix4fv("inv_proj", 1, FALSE, inv_proj.m);
+ shader.uniform4f("viewport", (F32) gGLViewport[0],
+ (F32) gGLViewport[1],
+ (F32) gGLViewport[2],
+ (F32) gGLViewport[3]);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_NOISE);
+ if (channel > -1)
+ {
+ gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, noise_map);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LIGHTFUNC);
+ if (channel > -1)
+ {
+ gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, mLightFunc);
+ }
+
+ stop_glerror();
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredLight[light_index].bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LUMINANCE);
+ if (channel > -1)
+ {
+ gGL.getTexUnit(channel)->bindManual(LLTexUnit::TT_TEXTURE, mLuminanceMap.getTexture(), true);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_BLOOM);
+ if (channel > -1)
+ {
+ mGlow[1].bindTexture(0, channel);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_GI_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ gi_source->bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_EDGE, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mEdgeMap.bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SUN_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredLight[1].bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_LOCAL_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ if (channel > -1)
+ {
+ mDeferredLight[2].bindTexture(0, channel);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ }
+
+
+ stop_glerror();
+
+ for (U32 i = 0; i < 4; i++)
+ {
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i, LLTexUnit::TT_RECT_TEXTURE);
+ stop_glerror();
+ if (channel > -1)
+ {
+ stop_glerror();
+ gGL.getTexUnit(channel)->bind(&mShadow[i], TRUE);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ gGL.getTexUnit(channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP);
+ stop_glerror();
+
+ glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE_ARB);
+ glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL);
+ stop_glerror();
+ }
+ }
+
+ for (U32 i = 4; i < 6; i++)
+ {
+ channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i);
+ stop_glerror();
+ if (channel > -1)
+ {
+ stop_glerror();
+ gGL.getTexUnit(channel)->bind(&mShadow[i], TRUE);
+ gGL.getTexUnit(channel)->setTextureFilteringOption(LLTexUnit::TFO_BILINEAR);
+ gGL.getTexUnit(channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP);
+ stop_glerror();
+
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE_ARB);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL);
+ stop_glerror();
+ }
+ }
+
+ stop_glerror();
+
+ F32 mat[16*6];
+ for (U32 i = 0; i < 16; i++)
+ {
+ mat[i] = mSunShadowMatrix[0].m[i];
+ mat[i+16] = mSunShadowMatrix[1].m[i];
+ mat[i+32] = mSunShadowMatrix[2].m[i];
+ mat[i+48] = mSunShadowMatrix[3].m[i];
+ mat[i+64] = mSunShadowMatrix[4].m[i];
+ mat[i+80] = mSunShadowMatrix[5].m[i];
+ }
+
+ shader.uniformMatrix4fv("shadow_matrix[0]", 6, FALSE, mat);
+ shader.uniformMatrix4fv("shadow_matrix", 6, FALSE, mat);
+
+ stop_glerror();
+
+ channel = shader.enableTexture(LLViewerShaderMgr::ENVIRONMENT_MAP, LLTexUnit::TT_CUBE_MAP);
+ if (channel > -1)
+ {
+ LLCubeMap* cube_map = gSky.mVOSkyp ? gSky.mVOSkyp->getCubeMap() : NULL;
+ if (cube_map)
+ {
+ cube_map->enable(channel);
+ cube_map->bind();
+ F64* m = gGLModelView;
+
+
+ F32 mat[] = { m[0], m[1], m[2],
+ m[4], m[5], m[6],
+ m[8], m[9], m[10] };
+
+ shader.uniform3fv("env_mat[0]", 3, mat);
+ shader.uniform3fv("env_mat", 3, mat);
+ }
+ }
+
+ shader.uniform4fv("shadow_clip", 1, mSunClipPlanes.mV);
+ shader.uniform1f("sun_wash", gSavedSettings.getF32("RenderDeferredSunWash"));
+ shader.uniform1f("shadow_noise", gSavedSettings.getF32("RenderShadowNoise"));
+ shader.uniform1f("blur_size", gSavedSettings.getF32("RenderShadowBlurSize"));
+
+ shader.uniform1f("ssao_radius", gSavedSettings.getF32("RenderSSAOScale"));
+ shader.uniform1f("ssao_max_radius", gSavedSettings.getU32("RenderSSAOMaxScale"));
+
+ F32 ssao_factor = gSavedSettings.getF32("RenderSSAOFactor");
+ shader.uniform1f("ssao_factor", ssao_factor);
+ shader.uniform1f("ssao_factor_inv", 1.0/ssao_factor);
+
+ LLVector3 ssao_effect = gSavedSettings.getVector3("RenderSSAOEffect");
+ F32 matrix_diag = (ssao_effect[0] + 2.0*ssao_effect[1])/3.0;
+ F32 matrix_nondiag = (ssao_effect[0] - ssao_effect[1])/3.0;
+ // This matrix scales (proj of color onto <1/rt(3),1/rt(3),1/rt(3)>) by
+ // value factor, and scales remainder by saturation factor
+ F32 ssao_effect_mat[] = { matrix_diag, matrix_nondiag, matrix_nondiag,
+ matrix_nondiag, matrix_diag, matrix_nondiag,
+ matrix_nondiag, matrix_nondiag, matrix_diag};
+ shader.uniformMatrix3fv("ssao_effect_mat", 1, GL_FALSE, ssao_effect_mat);
+
+ F32 shadow_offset_error = 1.f + gSavedSettings.getF32("RenderShadowOffsetError") * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2]);
+ F32 shadow_bias_error = 1.f + gSavedSettings.getF32("RenderShadowBiasError") * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2]);
+
+ shader.uniform2f("screen_res", mDeferredScreen.getWidth(), mDeferredScreen.getHeight());
+ shader.uniform1f("near_clip", LLViewerCamera::getInstance()->getNear()*2.f);
+ shader.uniform1f ("shadow_offset", gSavedSettings.getF32("RenderShadowOffset")*shadow_offset_error);
+ shader.uniform1f("shadow_bias", gSavedSettings.getF32("RenderShadowBias")*shadow_bias_error);
+ shader.uniform1f ("spot_shadow_offset", gSavedSettings.getF32("RenderSpotShadowOffset"));
+ shader.uniform1f("spot_shadow_bias", gSavedSettings.getF32("RenderSpotShadowBias"));
+
+ shader.uniform1f("lum_scale", gSavedSettings.getF32("RenderLuminanceScale"));
+ shader.uniform1f("sun_lum_scale", gSavedSettings.getF32("RenderSunLuminanceScale"));
+ shader.uniform1f("sun_lum_offset", gSavedSettings.getF32("RenderSunLuminanceOffset"));
+ shader.uniform1f("lum_lod", gSavedSettings.getF32("RenderLuminanceDetail"));
+ shader.uniform1f("gi_range", gSavedSettings.getF32("RenderGIRange"));
+ shader.uniform1f("gi_brightness", gSavedSettings.getF32("RenderGIBrightness"));
+ shader.uniform1f("gi_luminance", gSavedSettings.getF32("RenderGILuminance"));
+ shader.uniform1f("gi_edge_weight", gSavedSettings.getF32("RenderGIBlurEdgeWeight"));
+ shader.uniform1f("gi_blur_brightness", gSavedSettings.getF32("RenderGIBlurBrightness"));
+ shader.uniform1f("gi_sample_width", mGILightRadius);
+ shader.uniform1f("gi_noise", gSavedSettings.getF32("RenderGINoise"));
+ shader.uniform1f("gi_attenuation", gSavedSettings.getF32("RenderGIAttenuation"));
+ shader.uniform1f("gi_ambiance", gSavedSettings.getF32("RenderGIAmbiance"));
+ shader.uniform2f("shadow_res", mShadow[0].getWidth(), mShadow[0].getHeight());
+ shader.uniform2f("proj_shadow_res", mShadow[4].getWidth(), mShadow[4].getHeight());
+ shader.uniform1f("depth_cutoff", gSavedSettings.getF32("RenderEdgeDepthCutoff"));
+ shader.uniform1f("norm_cutoff", gSavedSettings.getF32("RenderEdgeNormCutoff"));
+
+
+ if (shader.getUniformLocation("norm_mat") >= 0)
+ {
+ glh::matrix4f norm_mat = glh_get_current_modelview().inverse().transpose();
+ shader.uniformMatrix4fv("norm_mat", 1, FALSE, norm_mat.m);
+ }
+}
+
+static LLFastTimer::DeclareTimer FTM_GI_TRACE("Trace");
+static LLFastTimer::DeclareTimer FTM_GI_GATHER("Gather");
+static LLFastTimer::DeclareTimer FTM_SUN_SHADOW("Shadow Map");
+static LLFastTimer::DeclareTimer FTM_SOFTEN_SHADOW("Shadow Soften");
+static LLFastTimer::DeclareTimer FTM_EDGE_DETECTION("Find Edges");
+static LLFastTimer::DeclareTimer FTM_LOCAL_LIGHTS("Local Lights");
+static LLFastTimer::DeclareTimer FTM_ATMOSPHERICS("Atmospherics");
+static LLFastTimer::DeclareTimer FTM_FULLSCREEN_LIGHTS("Fullscreen Lights");
+static LLFastTimer::DeclareTimer FTM_PROJECTORS("Projectors");
+static LLFastTimer::DeclareTimer FTM_POST("Post");
+
+
+void LLPipeline::renderDeferredLighting()
+{
+ if (!sCull)
+ {
+ return;
+ }
+
+ {
+ LLFastTimer ftm(FTM_RENDER_DEFERRED);
+
+ LLViewerCamera* camera = LLViewerCamera::getInstance();
+ {
+ LLGLDepthTest depth(GL_TRUE);
+ mDeferredDepth.copyContents(mDeferredScreen, 0, 0, mDeferredScreen.getWidth(), mDeferredScreen.getHeight(),
+ 0, 0, mDeferredDepth.getWidth(), mDeferredDepth.getHeight(), GL_DEPTH_BUFFER_BIT, GL_NEAREST);
+ }
+
+ LLGLEnable multisample(gSavedSettings.getU32("RenderFSAASamples") > 0 ? GL_MULTISAMPLE_ARB : 0);
+
+ if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD))
+ {
+ gPipeline.toggleRenderType(LLPipeline::RENDER_TYPE_HUD);
+ }
+
+ //ati doesn't seem to love actually using the stencil buffer on FBO's
+ LLGLEnable stencil(GL_STENCIL_TEST);
+ glStencilFunc(GL_EQUAL, 1, 0xFFFFFFFF);
+ glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
+
+ gGL.setColorMask(true, true);
+
+ //draw a cube around every light
+ LLVertexBuffer::unbind();
+
+ LLGLEnable cull(GL_CULL_FACE);
+ LLGLEnable blend(GL_BLEND);
+
+ glh::matrix4f mat = glh_copy_matrix(gGLModelView);
+
+ F32 vert[] =
+ {
+ -1,1,
+ -1,-3,
+ 3,1,
+ };
+ glVertexPointer(2, GL_FLOAT, 0, vert);
+ glColor3f(1,1,1);
+
+ {
+ setupHWLights(NULL); //to set mSunDir;
+ LLVector4 dir(mSunDir, 0.f);
+ glh::vec4f tc(dir.mV);
+ mat.mult_matrix_vec(tc);
+ glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], 0);
+ }
+
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+
+ if (gSavedSettings.getBOOL("RenderDeferredSSAO") || gSavedSettings.getS32("RenderShadowDetail") > 0)
+ {
+ mDeferredLight[0].bindTarget();
+ { //paint shadow/SSAO light map (direct lighting lightmap)
+ LLFastTimer ftm(FTM_SUN_SHADOW);
+ bindDeferredShader(gDeferredSunProgram, 0);
+
+ glClearColor(1,1,1,1);
+ mDeferredLight[0].clear(GL_COLOR_BUFFER_BIT);
+ glClearColor(0,0,0,0);
+
+ glh::matrix4f inv_trans = glh_get_current_modelview().inverse().transpose();
+
+ const U32 slice = 32;
+ F32 offset[slice*3];
+ for (U32 i = 0; i < 4; i++)
+ {
+ for (U32 j = 0; j < 8; j++)
+ {
+ glh::vec3f v;
+ v.set_value(sinf(6.284f/8*j), cosf(6.284f/8*j), -(F32) i);
+ v.normalize();
+ inv_trans.mult_matrix_vec(v);
+ v.normalize();
+ offset[(i*8+j)*3+0] = v.v[0];
+ offset[(i*8+j)*3+1] = v.v[2];
+ offset[(i*8+j)*3+2] = v.v[1];
+ }
+ }
+
+ gDeferredSunProgram.uniform3fv("offset", slice, offset);
+ gDeferredSunProgram.uniform2f("screenRes", mDeferredLight[0].getWidth(), mDeferredLight[0].getHeight());
+
+ {
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS);
+ stop_glerror();
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ stop_glerror();
+ }
+
+ unbindDeferredShader(gDeferredSunProgram);
+ }
+ mDeferredLight[0].flush();
+ }
+
+ { //global illumination specific block (still experimental)
+ if (gSavedSettings.getBOOL("RenderDeferredBlurLight") &&
+ gSavedSettings.getBOOL("RenderDeferredGI"))
+ {
+ LLFastTimer ftm(FTM_EDGE_DETECTION);
+ //generate edge map
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable stencil(GL_STENCIL_TEST);
+
+ {
+ gDeferredEdgeProgram.bind();
+ mEdgeMap.bindTarget();
+ bindDeferredShader(gDeferredEdgeProgram);
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ unbindDeferredShader(gDeferredEdgeProgram);
+ mEdgeMap.flush();
+ }
+ }
+
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2)
+ {
+ { //get luminance map from previous frame's light map
+ LLGLEnable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable stencil(GL_STENCIL_TEST);
+
+ //static F32 fade = 1.f;
+
+ {
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+ gLuminanceGatherProgram.bind();
+ gLuminanceGatherProgram.uniform2f("screen_res", mDeferredLight[0].getWidth(), mDeferredLight[0].getHeight());
+ mLuminanceMap.bindTarget();
+ bindDeferredShader(gLuminanceGatherProgram);
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ unbindDeferredShader(gLuminanceGatherProgram);
+ mLuminanceMap.flush();
+ gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mLuminanceMap.getTexture(), true);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_TRILINEAR);
+ glGenerateMipmap(GL_TEXTURE_2D);
+ }
+ }
+
+ { //paint noisy GI map (bounce lighting lightmap)
+ LLFastTimer ftm(FTM_GI_TRACE);
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable test(GL_ALPHA_TEST);
+
+ mGIMapPost[0].bindTarget();
+
+ bindDeferredShader(gDeferredGIProgram, 0, &mGIMap, 0, mTrueNoiseMap);
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ unbindDeferredShader(gDeferredGIProgram);
+ mGIMapPost[0].flush();
+ }
+
+ U32 pass_count = 0;
+ if (gSavedSettings.getBOOL("RenderDeferredBlurLight"))
+ {
+ pass_count = llclamp(gSavedSettings.getU32("RenderGIBlurPasses"), (U32) 1, (U32) 128);
+ }
+
+ for (U32 i = 0; i < pass_count; ++i)
+ { //gather/soften indirect lighting map
+ LLFastTimer ftm(FTM_GI_GATHER);
+ bindDeferredShader(gDeferredPostGIProgram, 0, &mGIMapPost[0], NULL, mTrueNoiseMap);
+ F32 blur_size = gSavedSettings.getF32("RenderGIBlurSize")/((F32) i * gSavedSettings.getF32("RenderGIBlurIncrement")+1.f);
+ gDeferredPostGIProgram.uniform2f("delta", 1.f, 0.f);
+ gDeferredPostGIProgram.uniform1f("kern_scale", blur_size);
+ gDeferredPostGIProgram.uniform1f("gi_blur_brightness", gSavedSettings.getF32("RenderGIBlurBrightness"));
+
+ mGIMapPost[1].bindTarget();
+ {
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_FALSE);
+ stop_glerror();
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ stop_glerror();
+ }
+
+ mGIMapPost[1].flush();
+ unbindDeferredShader(gDeferredPostGIProgram);
+ bindDeferredShader(gDeferredPostGIProgram, 0, &mGIMapPost[1], NULL, mTrueNoiseMap);
+ mGIMapPost[0].bindTarget();
+
+ gDeferredPostGIProgram.uniform2f("delta", 0.f, 1.f);
+
+ {
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_FALSE);
+ stop_glerror();
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
+ stop_glerror();
+ }
+ mGIMapPost[0].flush();
+ unbindDeferredShader(gDeferredPostGIProgram);
+ }
+ }
+ }
+
+ if (gSavedSettings.getBOOL("RenderDeferredSSAO"))
+ { //soften direct lighting lightmap
+ LLFastTimer ftm(FTM_SOFTEN_SHADOW);
+ //blur lightmap
+ mDeferredLight[1].bindTarget();
+
+ glClearColor(1,1,1,1);
+ mDeferredLight[1].clear(GL_COLOR_BUFFER_BIT);
+ glClearColor(0,0,0,0);
+
+ bindDeferredShader(gDeferredBlurLightProgram);
+
+ LLVector3 go = gSavedSettings.getVector3("RenderShadowGaussian");
+ const U32 kern_length = 4;
+ F32 blur_size = gSavedSettings.getF32("RenderShadowBlurSize");
+ F32 dist_factor = gSavedSettings.getF32("RenderShadowBlurDistFactor");
+
+ // sample symmetrically with the middle sample falling exactly on 0.0
+ F32 x = 0.f;
+
+ LLVector3 gauss[32]; // xweight, yweight, offset
+
+ for (U32 i = 0; i < kern_length; i++)
+ {
+ gauss[i].mV[0] = llgaussian(x, go.mV[0]);
+ gauss[i].mV[1] = llgaussian(x, go.mV[1]);
+ gauss[i].mV[2] = x;
+ x += 1.f;
+ }
+
+ gDeferredBlurLightProgram.uniform2f("delta", 1.f, 0.f);
+ gDeferredBlurLightProgram.uniform1f("dist_factor", dist_factor);
+ gDeferredBlurLightProgram.uniform3fv("kern", kern_length, gauss[0].mV);
+ gDeferredBlurLightProgram.uniform1f("kern_scale", blur_size * (kern_length/2.f - 0.5f));
+
+ {
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS);
+ stop_glerror();
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ stop_glerror();
+ }
+
+ mDeferredLight[1].flush();
+ unbindDeferredShader(gDeferredBlurLightProgram);
+
+ bindDeferredShader(gDeferredBlurLightProgram, 1);
+ mDeferredLight[0].bindTarget();
+
+ gDeferredBlurLightProgram.uniform2f("delta", 0.f, 1.f);
+
+ {
+ LLGLDisable blend(GL_BLEND);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_ALWAYS);
+ stop_glerror();
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ stop_glerror();
+ }
+ mDeferredLight[0].flush();
+ unbindDeferredShader(gDeferredBlurLightProgram);
+ }
+
+ stop_glerror();
+ glPopMatrix();
+ stop_glerror();
+ glMatrixMode(GL_MODELVIEW);
+ stop_glerror();
+ glPopMatrix();
+ stop_glerror();
+
+ //copy depth and stencil from deferred screen
+ //mScreen.copyContents(mDeferredScreen, 0, 0, mDeferredScreen.getWidth(), mDeferredScreen.getHeight(),
+ // 0, 0, mScreen.getWidth(), mScreen.getHeight(), GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT, GL_NEAREST);
+
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2)
+ {
+ mDeferredLight[1].bindTarget();
+ // clear color buffer here (GI) - zeroing alpha (glow) is important or it will accumulate against sky
+ glClearColor(0,0,0,0);
+ mScreen.clear(GL_COLOR_BUFFER_BIT);
+ }
+ else
+ {
+ mScreen.bindTarget();
+ // clear color buffer here - zeroing alpha (glow) is important or it will accumulate against sky
+ glClearColor(0,0,0,0);
+ mScreen.clear(GL_COLOR_BUFFER_BIT);
+ }
+
+ if (gSavedSettings.getBOOL("RenderDeferredAtmospheric"))
+ { //apply sunlight contribution
+ LLFastTimer ftm(FTM_ATMOSPHERICS);
+ bindDeferredShader(gDeferredSoftenProgram, 0, &mGIMapPost[0]);
+ {
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+
+ //full screen blit
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+
+ glVertexPointer(2, GL_FLOAT, 0, vert);
+
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+ }
+
+ unbindDeferredShader(gDeferredSoftenProgram);
+ }
+
+ { //render sky
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable stencil(GL_STENCIL_TEST);
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+
+ gPipeline.pushRenderTypeMask();
+
+ gPipeline.andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_CLOUDS,
+ LLPipeline::RENDER_TYPE_WL_SKY,
+ LLPipeline::END_RENDER_TYPES);
+
+
+ renderGeomPostDeferred(*LLViewerCamera::getInstance());
+ gPipeline.popRenderTypeMask();
+ }
+
+ BOOL render_local = gSavedSettings.getBOOL("RenderLocalLights");
+
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2)
+ {
+ mDeferredLight[1].flush();
+ mDeferredLight[2].bindTarget();
+ mDeferredLight[2].clear(GL_COLOR_BUFFER_BIT);
+ }
+
+ if (render_local)
+ {
+ gGL.setSceneBlendType(LLRender::BT_ADD);
+ std::list<LLVector4> fullscreen_lights;
+ LLDrawable::drawable_list_t spot_lights;
+ LLDrawable::drawable_list_t fullscreen_spot_lights;
+
+ for (U32 i = 0; i < 2; i++)
+ {
+ mTargetShadowSpotLight[i] = NULL;
+ }
+
+ std::list<LLVector4> light_colors;
+
+ LLVertexBuffer::unbind();
+
+ F32 v[24];
+ glVertexPointer(3, GL_FLOAT, 0, v);
+
+ {
+ bindDeferredShader(gDeferredLightProgram);
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE);
+ for (LLDrawable::drawable_set_t::iterator iter = mLights.begin(); iter != mLights.end(); ++iter)
+ {
+ LLDrawable* drawablep = *iter;
+
+ LLVOVolume* volume = drawablep->getVOVolume();
+ if (!volume)
+ {
+ continue;
+ }
+
+ if (volume->isAttachment())
+ {
+ if (!sRenderAttachedLights)
+ {
+ continue;
+ }
+ }
+
+
+ LLVector4a center;
+ center.load3(drawablep->getPositionAgent().mV);
+ const F32* c = center.getF32ptr();
+ F32 s = volume->getLightRadius()*1.5f;
+
+ LLColor3 col = volume->getLightColor();
+ col *= volume->getLightIntensity();
+
+ if (col.magVecSquared() < 0.001f)
+ {
+ continue;
+ }
+
+ if (s <= 0.001f)
+ {
+ continue;
+ }
+
+ LLVector4a sa;
+ sa.splat(s);
+ if (camera->AABBInFrustumNoFarClip(center, sa) == 0)
+ {
+ continue;
+ }
+
+ sVisibleLightCount++;
+
+ glh::vec3f tc(c);
+ mat.mult_matrix_vec(tc);
+
+ //vertex positions are encoded so the 3 bits of their vertex index
+ //correspond to their axis facing, with bit position 3,2,1 matching
+ //axis facing x,y,z, bit set meaning positive facing, bit clear
+ //meaning negative facing
+ v[0] = c[0]-s; v[1] = c[1]-s; v[2] = c[2]-s; // 0 - 0000
+ v[3] = c[0]-s; v[4] = c[1]-s; v[5] = c[2]+s; // 1 - 0001
+ v[6] = c[0]-s; v[7] = c[1]+s; v[8] = c[2]-s; // 2 - 0010
+ v[9] = c[0]-s; v[10] = c[1]+s; v[11] = c[2]+s; // 3 - 0011
+
+ v[12] = c[0]+s; v[13] = c[1]-s; v[14] = c[2]-s; // 4 - 0100
+ v[15] = c[0]+s; v[16] = c[1]-s; v[17] = c[2]+s; // 5 - 0101
+ v[18] = c[0]+s; v[19] = c[1]+s; v[20] = c[2]-s; // 6 - 0110
+ v[21] = c[0]+s; v[22] = c[1]+s; v[23] = c[2]+s; // 7 - 0111
+
+ if (camera->getOrigin().mV[0] > c[0] + s + 0.2f ||
+ camera->getOrigin().mV[0] < c[0] - s - 0.2f ||
+ camera->getOrigin().mV[1] > c[1] + s + 0.2f ||
+ camera->getOrigin().mV[1] < c[1] - s - 0.2f ||
+ camera->getOrigin().mV[2] > c[2] + s + 0.2f ||
+ camera->getOrigin().mV[2] < c[2] - s - 0.2f)
+ { //draw box if camera is outside box
+ if (render_local)
+ {
+ if (volume->isLightSpotlight())
+ {
+ drawablep->getVOVolume()->updateSpotLightPriority();
+ spot_lights.push_back(drawablep);
+ continue;
+ }
+
+ LLFastTimer ftm(FTM_LOCAL_LIGHTS);
+ glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s);
+ glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f);
+ glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8,
+ GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center));
+ stop_glerror();
+ }
+ }
+ else
+ {
+ if (volume->isLightSpotlight())
+ {
+ drawablep->getVOVolume()->updateSpotLightPriority();
+ fullscreen_spot_lights.push_back(drawablep);
+ continue;
+ }
+
+ fullscreen_lights.push_back(LLVector4(tc.v[0], tc.v[1], tc.v[2], s*s));
+ light_colors.push_back(LLVector4(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f));
+ }
+ }
+ unbindDeferredShader(gDeferredLightProgram);
+ }
+
+ if (!spot_lights.empty())
+ {
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE);
+ bindDeferredShader(gDeferredSpotLightProgram);
+
+ gDeferredSpotLightProgram.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
+
+ for (LLDrawable::drawable_list_t::iterator iter = spot_lights.begin(); iter != spot_lights.end(); ++iter)
+ {
+ LLFastTimer ftm(FTM_PROJECTORS);
+ LLDrawable* drawablep = *iter;
+
+ LLVOVolume* volume = drawablep->getVOVolume();
+
+ LLVector4a center;
+ center.load3(drawablep->getPositionAgent().mV);
+ const F32* c = center.getF32ptr();
+ F32 s = volume->getLightRadius()*1.5f;
+
+ sVisibleLightCount++;
+
+ glh::vec3f tc(c);
+ mat.mult_matrix_vec(tc);
+
+ setupSpotLight(gDeferredSpotLightProgram, drawablep);
+
+ LLColor3 col = volume->getLightColor();
+ col *= volume->getLightIntensity();
+
+ //vertex positions are encoded so the 3 bits of their vertex index
+ //correspond to their axis facing, with bit position 3,2,1 matching
+ //axis facing x,y,z, bit set meaning positive facing, bit clear
+ //meaning negative facing
+ v[0] = c[0]-s; v[1] = c[1]-s; v[2] = c[2]-s; // 0 - 0000
+ v[3] = c[0]-s; v[4] = c[1]-s; v[5] = c[2]+s; // 1 - 0001
+ v[6] = c[0]-s; v[7] = c[1]+s; v[8] = c[2]-s; // 2 - 0010
+ v[9] = c[0]-s; v[10] = c[1]+s; v[11] = c[2]+s; // 3 - 0011
+
+ v[12] = c[0]+s; v[13] = c[1]-s; v[14] = c[2]-s; // 4 - 0100
+ v[15] = c[0]+s; v[16] = c[1]-s; v[17] = c[2]+s; // 5 - 0101
+ v[18] = c[0]+s; v[19] = c[1]+s; v[20] = c[2]-s; // 6 - 0110
+ v[21] = c[0]+s; v[22] = c[1]+s; v[23] = c[2]+s; // 7 - 0111
+
+ glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s);
+ glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f);
+ glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8,
+ GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center));
+ }
+ gDeferredSpotLightProgram.disableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
+ unbindDeferredShader(gDeferredSpotLightProgram);
+ }
+
+ {
+ bindDeferredShader(gDeferredMultiLightProgram);
+
+ LLGLDepthTest depth(GL_FALSE);
+
+ //full screen blit
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+
+ U32 count = 0;
+
+ const U32 max_count = 8;
+ LLVector4 light[max_count];
+ LLVector4 col[max_count];
+
+ glVertexPointer(2, GL_FLOAT, 0, vert);
+
+ F32 far_z = 0.f;
+
+ while (!fullscreen_lights.empty())
+ {
+ LLFastTimer ftm(FTM_FULLSCREEN_LIGHTS);
+ light[count] = fullscreen_lights.front();
+ fullscreen_lights.pop_front();
+ col[count] = light_colors.front();
+ light_colors.pop_front();
+
+ far_z = llmin(light[count].mV[2]-sqrtf(light[count].mV[3]), far_z);
+
+ count++;
+ if (count == max_count || fullscreen_lights.empty())
+ {
+ gDeferredMultiLightProgram.uniform1i("light_count", count);
+ gDeferredMultiLightProgram.uniform4fv("light", count, (GLfloat*) light);
+ gDeferredMultiLightProgram.uniform4fv("light_col", count, (GLfloat*) col);
+ gDeferredMultiLightProgram.uniform1f("far_z", far_z);
+ far_z = 0.f;
+ count = 0;
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ }
+ }
+
+ unbindDeferredShader(gDeferredMultiLightProgram);
+
+ bindDeferredShader(gDeferredMultiSpotLightProgram);
+
+ gDeferredMultiSpotLightProgram.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
+
+ for (LLDrawable::drawable_list_t::iterator iter = fullscreen_spot_lights.begin(); iter != fullscreen_spot_lights.end(); ++iter)
+ {
+ LLFastTimer ftm(FTM_PROJECTORS);
+ LLDrawable* drawablep = *iter;
+
+ LLVOVolume* volume = drawablep->getVOVolume();
+
+ LLVector3 center = drawablep->getPositionAgent();
+ F32* c = center.mV;
+ F32 s = volume->getLightRadius()*1.5f;
+
+ sVisibleLightCount++;
+
+ glh::vec3f tc(c);
+ mat.mult_matrix_vec(tc);
+
+ setupSpotLight(gDeferredMultiSpotLightProgram, drawablep);
+
+ LLColor3 col = volume->getLightColor();
+ col *= volume->getLightIntensity();
+
+ glTexCoord4f(tc.v[0], tc.v[1], tc.v[2], s*s);
+ glColor4f(col.mV[0], col.mV[1], col.mV[2], volume->getLightFalloff()*0.5f);
+ glDrawArrays(GL_TRIANGLE_STRIP, 0, 3);
+ }
+
+ gDeferredMultiSpotLightProgram.disableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
+ unbindDeferredShader(gDeferredMultiSpotLightProgram);
+
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+ }
+ }
+
+ gGL.setColorMask(true, true);
+
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) > 2)
+ {
+ mDeferredLight[2].flush();
+
+ mScreen.bindTarget();
+ mScreen.clear(GL_COLOR_BUFFER_BIT);
+
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
+
+ { //mix various light maps (local, sun, gi)
+ LLFastTimer ftm(FTM_POST);
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable test(GL_ALPHA_TEST);
+ LLGLDepthTest depth(GL_FALSE);
+ LLGLDisable stencil(GL_STENCIL_TEST);
+
+ bindDeferredShader(gDeferredPostProgram, 0, &mGIMapPost[0]);
+
+ gDeferredPostProgram.bind();
+
+ LLVertexBuffer::unbind();
+
+ glVertexPointer(2, GL_FLOAT, 0, vert);
+ glColor3f(1,1,1);
+
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+
+ glDrawArrays(GL_TRIANGLES, 0, 3);
+
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+
+ unbindDeferredShader(gDeferredPostProgram);
+ }
+ }
+ }
+
+ { //render non-deferred geometry (alpha, fullbright, glow)
+ LLGLDisable blend(GL_BLEND);
+ LLGLDisable stencil(GL_STENCIL_TEST);
+
+ pushRenderTypeMask();
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_ALPHA,
+ LLPipeline::RENDER_TYPE_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_VOLUME,
+ LLPipeline::RENDER_TYPE_GLOW,
+ LLPipeline::RENDER_TYPE_BUMP,
+ LLPipeline::RENDER_TYPE_PASS_SIMPLE,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA_MASK,
+ LLPipeline::RENDER_TYPE_PASS_BUMP,
+ LLPipeline::RENDER_TYPE_PASS_POST_BUMP,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_ALPHA_MASK,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY,
+ LLPipeline::RENDER_TYPE_PASS_GLOW,
+ LLPipeline::RENDER_TYPE_PASS_GRASS,
+ LLPipeline::RENDER_TYPE_PASS_SHINY,
+ LLPipeline::RENDER_TYPE_PASS_INVISIBLE,
+ LLPipeline::RENDER_TYPE_PASS_INVISI_SHINY,
+ LLPipeline::RENDER_TYPE_AVATAR,
+ END_RENDER_TYPES);
+
+ renderGeomPostDeferred(*LLViewerCamera::getInstance());
+ popRenderTypeMask();
+ }
+
+ {
+ //render highlights, etc.
+ renderHighlights();
+ mHighlightFaces.clear();
+
+ renderDebug();
+
+ LLVertexBuffer::unbind();
+
+ if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI))
+ {
+ // Render debugging beacons.
+ gObjectList.renderObjectBeacons();
+ gObjectList.resetObjectBeacons();
+ }
+ }
+
+ mScreen.flush();
+
+}
+
+void LLPipeline::setupSpotLight(LLGLSLShader& shader, LLDrawable* drawablep)
+{
+ //construct frustum
+ LLVOVolume* volume = drawablep->getVOVolume();
+ LLVector3 params = volume->getSpotLightParams();
+
+ F32 fov = params.mV[0];
+ F32 focus = params.mV[1];
+
+ LLVector3 pos = drawablep->getPositionAgent();
+ LLQuaternion quat = volume->getRenderRotation();
+ LLVector3 scale = volume->getScale();
+
+ //get near clip plane
+ LLVector3 at_axis(0,0,-scale.mV[2]*0.5f);
+ at_axis *= quat;
+
+ LLVector3 np = pos+at_axis;
+ at_axis.normVec();
+
+ //get origin that has given fov for plane np, at_axis, and given scale
+ F32 dist = (scale.mV[1]*0.5f)/tanf(fov*0.5f);
+
+ LLVector3 origin = np - at_axis*dist;
+
+ //matrix from volume space to agent space
+ LLMatrix4 light_mat(quat, LLVector4(origin,1.f));
+
+ glh::matrix4f light_to_agent((F32*) light_mat.mMatrix);
+ glh::matrix4f light_to_screen = glh_get_current_modelview() * light_to_agent;
+
+ glh::matrix4f screen_to_light = light_to_screen.inverse();
+
+ F32 s = volume->getLightRadius()*1.5f;
+ F32 near_clip = dist;
+ F32 width = scale.mV[VX];
+ F32 height = scale.mV[VY];
+ F32 far_clip = s+dist-scale.mV[VZ];
+
+ F32 fovy = fov * RAD_TO_DEG;
+ F32 aspect = width/height;
+
+ glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f,
+ 0.f, 0.5f, 0.f, 0.5f,
+ 0.f, 0.f, 0.5f, 0.5f,
+ 0.f, 0.f, 0.f, 1.f);
+
+ glh::vec3f p1(0, 0, -(near_clip+0.01f));
+ glh::vec3f p2(0, 0, -(near_clip+1.f));
+
+ glh::vec3f screen_origin(0, 0, 0);
+
+ light_to_screen.mult_matrix_vec(p1);
+ light_to_screen.mult_matrix_vec(p2);
+ light_to_screen.mult_matrix_vec(screen_origin);
+
+ glh::vec3f n = p2-p1;
+ n.normalize();
+
+ F32 proj_range = far_clip - near_clip;
+ glh::matrix4f light_proj = gl_perspective(fovy, aspect, near_clip, far_clip);
+ screen_to_light = trans * light_proj * screen_to_light;
+ shader.uniformMatrix4fv("proj_mat", 1, FALSE, screen_to_light.m);
+ shader.uniform1f("proj_near", near_clip);
+ shader.uniform3fv("proj_p", 1, p1.v);
+ shader.uniform3fv("proj_n", 1, n.v);
+ shader.uniform3fv("proj_origin", 1, screen_origin.v);
+ shader.uniform1f("proj_range", proj_range);
+ shader.uniform1f("proj_ambiance", params.mV[2]);
+ S32 s_idx = -1;
+
+ for (U32 i = 0; i < 2; i++)
+ {
+ if (mShadowSpotLight[i] == drawablep)
+ {
+ s_idx = i;
+ }
+ }
+
+ shader.uniform1i("proj_shadow_idx", s_idx);
+
+ if (s_idx >= 0)
+ {
+ shader.uniform1f("shadow_fade", 1.f-mSpotLightFade[s_idx]);
+ }
+ else
+ {
+ shader.uniform1f("shadow_fade", 1.f);
+ }
+
+ {
+ LLDrawable* potential = drawablep;
+ //determine if this is a good light for casting shadows
+ F32 m_pri = volume->getSpotLightPriority();
+
+ for (U32 i = 0; i < 2; i++)
+ {
+ F32 pri = 0.f;
+
+ if (mTargetShadowSpotLight[i].notNull())
+ {
+ pri = mTargetShadowSpotLight[i]->getVOVolume()->getSpotLightPriority();
+ }
+
+ if (m_pri > pri)
+ {
+ LLDrawable* temp = mTargetShadowSpotLight[i];
+ mTargetShadowSpotLight[i] = potential;
+ potential = temp;
+ m_pri = pri;
+ }
+ }
+ }
+
+ LLViewerTexture* img = volume->getLightTexture();
+
+ S32 channel = shader.enableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
+
+ if (channel > -1 && img)
+ {
+ gGL.getTexUnit(channel)->bind(img);
+
+ F32 lod_range = logf(img->getWidth())/logf(2.f);
+
+ shader.uniform1f("proj_focus", focus);
+ shader.uniform1f("proj_lod", lod_range);
+ shader.uniform1f("proj_ambient_lod", llclamp((proj_range-focus)/proj_range*lod_range, 0.f, 1.f));
+ }
+}
+
+void LLPipeline::unbindDeferredShader(LLGLSLShader &shader)
+{
+ stop_glerror();
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_POSITION, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_NORMAL, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_DIFFUSE, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_SPECULAR, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_DEPTH, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_EDGE, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_SUN_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_LOCAL_LIGHT, LLTexUnit::TT_RECT_TEXTURE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_LUMINANCE);
+ shader.disableTexture(LLViewerShaderMgr::DIFFUSE_MAP);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MIP);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_BLOOM);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_NORMAL);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_DIFFUSE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_SPECULAR);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_DEPTH);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MIN_POS);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_MAX_POS);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_NORMAL);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_DIFFUSE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MIN_POS);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_GI_LAST_MAX_POS);
+
+ for (U32 i = 0; i < 4; i++)
+ {
+ if (shader.disableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i, LLTexUnit::TT_RECT_TEXTURE) > -1)
+ {
+ glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE);
+ }
+ }
+
+ for (U32 i = 4; i < 6; i++)
+ {
+ if (shader.disableTexture(LLViewerShaderMgr::DEFERRED_SHADOW0+i) > -1)
+ {
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_MODE_ARB, GL_NONE);
+ }
+ }
+
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_NOISE);
+ shader.disableTexture(LLViewerShaderMgr::DEFERRED_LIGHTFUNC);
+
+ S32 channel = shader.disableTexture(LLViewerShaderMgr::ENVIRONMENT_MAP, LLTexUnit::TT_CUBE_MAP);
+ if (channel > -1)
+ {
+ LLCubeMap* cube_map = gSky.mVOSkyp ? gSky.mVOSkyp->getCubeMap() : NULL;
+ if (cube_map)
+ {
+ cube_map->disable();
+ }
+ }
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ gGL.getTexUnit(0)->activate();
+ shader.unbind();
+
+ LLGLState::checkTextureChannels();
+}
+
+inline float sgn(float a)
+{
+ if (a > 0.0F) return (1.0F);
+ if (a < 0.0F) return (-1.0F);
+ return (0.0F);
+}
+
+void LLPipeline::generateWaterReflection(LLCamera& camera_in)
+{
+ if (LLPipeline::sWaterReflections && assertInitialized() && LLDrawPoolWater::sNeedsReflectionUpdate)
+ {
+ BOOL skip_avatar_update = FALSE;
+ if (!isAgentAvatarValid() || gAgentCamera.getCameraAnimating() || gAgentCamera.getCameraMode() != CAMERA_MODE_MOUSELOOK)
+ {
+ skip_avatar_update = TRUE;
+ }
+
+ if (!skip_avatar_update)
+ {
+ gAgentAvatarp->updateAttachmentVisibility(CAMERA_MODE_THIRD_PERSON);
+ }
+ LLVertexBuffer::unbind();
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+ LLCamera camera = camera_in;
+ camera.setFar(camera.getFar()*0.87654321f);
+ LLPipeline::sReflectionRender = TRUE;
+
+ gPipeline.pushRenderTypeMask();
+
+ glh::matrix4f projection = glh_get_current_projection();
+ glh::matrix4f mat;
+
+ stop_glerror();
+ LLPlane plane;
+
+ F32 height = gAgent.getRegion()->getWaterHeight();
+ F32 to_clip = fabsf(camera.getOrigin().mV[2]-height);
+ F32 pad = -to_clip*0.05f; //amount to "pad" clip plane by
+
+ //plane params
+ LLVector3 pnorm;
+ F32 pd;
+
+ S32 water_clip = 0;
+ if (!LLViewerCamera::getInstance()->cameraUnderWater())
+ { //camera is above water, clip plane points up
+ pnorm.setVec(0,0,1);
+ pd = -height;
+ plane.setVec(pnorm, pd);
+ water_clip = -1;
+ }
+ else
+ { //camera is below water, clip plane points down
+ pnorm = LLVector3(0,0,-1);
+ pd = height;
+ plane.setVec(pnorm, pd);
+ water_clip = 1;
+ }
+
+ if (!LLViewerCamera::getInstance()->cameraUnderWater())
+ { //generate planar reflection map
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ glClearColor(0,0,0,0);
+ mWaterRef.bindTarget();
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WATER0;
+ gGL.setColorMask(true, true);
+ mWaterRef.clear();
+ gGL.setColorMask(true, false);
+
+ mWaterRef.getViewport(gGLViewport);
+
+ stop_glerror();
+
+ glPushMatrix();
+
+ mat.set_scale(glh::vec3f(1,1,-1));
+ mat.set_translate(glh::vec3f(0,0,height*2.f));
+
+ glh::matrix4f current = glh_get_current_modelview();
+
+ mat = current * mat;
+
+ glh_set_current_modelview(mat);
+ glLoadMatrixf(mat.m);
+
+ LLViewerCamera::updateFrustumPlanes(camera, FALSE, TRUE);
+
+ glh::matrix4f inv_mat = mat.inverse();
+
+ glh::vec3f origin(0,0,0);
+ inv_mat.mult_matrix_vec(origin);
+
+ camera.setOrigin(origin.v);
+
+ glCullFace(GL_FRONT);
+
+ static LLCullResult ref_result;
+
+ if (LLDrawPoolWater::sNeedsDistortionUpdate)
+ {
+ //initial sky pass (no user clip plane)
+ { //mask out everything but the sky
+ gPipeline.pushRenderTypeMask();
+ gPipeline.andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_WL_SKY,
+ LLPipeline::END_RENDER_TYPES);
+
+ static LLCullResult result;
+ updateCull(camera, result);
+ stateSort(camera, result);
+
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_CLOUDS,
+ LLPipeline::RENDER_TYPE_WL_SKY,
+ LLPipeline::END_RENDER_TYPES);
+
+ //bad pop here
+ renderGeom(camera, TRUE);
+
+ gPipeline.popRenderTypeMask();
+ }
+
+ gPipeline.pushRenderTypeMask();
+
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_WATER,
+ LLPipeline::RENDER_TYPE_VOIDWATER,
+ LLPipeline::RENDER_TYPE_GROUND,
+ LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_CLOUDS,
+ LLPipeline::END_RENDER_TYPES);
+
+ S32 detail = gSavedSettings.getS32("RenderReflectionDetail");
+ if (detail > 0)
+ { //mask out selected geometry based on reflection detail
+ if (detail < 4)
+ {
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_PARTICLES, END_RENDER_TYPES);
+ if (detail < 3)
+ {
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_AVATAR, END_RENDER_TYPES);
+ if (detail < 2)
+ {
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_VOLUME, END_RENDER_TYPES);
+ }
+ }
+ }
+
+ LLGLUserClipPlane clip_plane(plane, mat, projection);
+ LLGLDisable cull(GL_CULL_FACE);
+ updateCull(camera, ref_result, 1);
+ stateSort(camera, ref_result);
+ }
+
+ if (LLDrawPoolWater::sNeedsDistortionUpdate)
+ {
+ if (gSavedSettings.getS32("RenderReflectionDetail") > 0)
+ {
+ gPipeline.grabReferences(ref_result);
+ LLGLUserClipPlane clip_plane(plane, mat, projection);
+ renderGeom(camera);
+ }
+ }
+
+ gPipeline.popRenderTypeMask();
+ }
+ glCullFace(GL_BACK);
+ glPopMatrix();
+ mWaterRef.flush();
+ glh_set_current_modelview(current);
+ }
+
+ camera.setOrigin(camera_in.getOrigin());
+ //render distortion map
+ static BOOL last_update = TRUE;
+ if (last_update)
+ {
+ camera.setFar(camera_in.getFar());
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_WATER,
+ LLPipeline::RENDER_TYPE_VOIDWATER,
+ LLPipeline::RENDER_TYPE_GROUND,
+ END_RENDER_TYPES);
+ stop_glerror();
+
+ LLPipeline::sUnderWaterRender = LLViewerCamera::getInstance()->cameraUnderWater() ? FALSE : TRUE;
+
+ if (LLPipeline::sUnderWaterRender)
+ {
+ clearRenderTypeMask(LLPipeline::RENDER_TYPE_GROUND,
+ LLPipeline::RENDER_TYPE_SKY,
+ LLPipeline::RENDER_TYPE_CLOUDS,
+ LLPipeline::RENDER_TYPE_WL_SKY,
+ END_RENDER_TYPES);
+ }
+ LLViewerCamera::updateFrustumPlanes(camera);
+
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ LLColor4& col = LLDrawPoolWater::sWaterFogColor;
+ glClearColor(col.mV[0], col.mV[1], col.mV[2], 0.f);
+ mWaterDis.bindTarget();
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WATER1;
+ mWaterDis.getViewport(gGLViewport);
+
+ if (!LLPipeline::sUnderWaterRender || LLDrawPoolWater::sNeedsReflectionUpdate)
+ {
+ //clip out geometry on the same side of water as the camera
+ mat = glh_get_current_modelview();
+ LLGLUserClipPlane clip_plane(LLPlane(-pnorm, -(pd+pad)), mat, projection);
+ static LLCullResult result;
+ updateCull(camera, result, water_clip);
+ stateSort(camera, result);
+
+ gGL.setColorMask(true, true);
+ mWaterDis.clear();
+ gGL.setColorMask(true, false);
+
+ renderGeom(camera);
+ }
+
+ LLPipeline::sUnderWaterRender = FALSE;
+ mWaterDis.flush();
+ }
+ last_update = LLDrawPoolWater::sNeedsReflectionUpdate && LLDrawPoolWater::sNeedsDistortionUpdate;
+
+ LLRenderTarget::unbindTarget();
+
+ LLPipeline::sReflectionRender = FALSE;
+
+ if (!LLRenderTarget::sUseFBO)
+ {
+ glClear(GL_DEPTH_BUFFER_BIT);
+ }
+ glClearColor(0.f, 0.f, 0.f, 0.f);
+ gViewerWindow->setup3DViewport();
+ gPipeline.popRenderTypeMask();
+ LLDrawPoolWater::sNeedsReflectionUpdate = FALSE;
+ LLDrawPoolWater::sNeedsDistortionUpdate = FALSE;
+ LLPlane npnorm(-pnorm, -pd);
+ LLViewerCamera::getInstance()->setUserClipPlane(npnorm);
+
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+ if (!skip_avatar_update)
+ {
+ gAgentAvatarp->updateAttachmentVisibility(gAgentCamera.getCameraMode());
+ }
+
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_WORLD;
+ }
+}
+
+glh::matrix4f look(const LLVector3 pos, const LLVector3 dir, const LLVector3 up)
+{
+ glh::matrix4f ret;
+
+ LLVector3 dirN;
+ LLVector3 upN;
+ LLVector3 lftN;
+
+ lftN = dir % up;
+ lftN.normVec();
+
+ upN = lftN % dir;
+ upN.normVec();
+
+ dirN = dir;
+ dirN.normVec();
+
+ ret.m[ 0] = lftN[0];
+ ret.m[ 1] = upN[0];
+ ret.m[ 2] = -dirN[0];
+ ret.m[ 3] = 0.f;
+
+ ret.m[ 4] = lftN[1];
+ ret.m[ 5] = upN[1];
+ ret.m[ 6] = -dirN[1];
+ ret.m[ 7] = 0.f;
+
+ ret.m[ 8] = lftN[2];
+ ret.m[ 9] = upN[2];
+ ret.m[10] = -dirN[2];
+ ret.m[11] = 0.f;
+
+ ret.m[12] = -(lftN*pos);
+ ret.m[13] = -(upN*pos);
+ ret.m[14] = dirN*pos;
+ ret.m[15] = 1.f;
+
+ return ret;
+}
+
+glh::matrix4f scale_translate_to_fit(const LLVector3 min, const LLVector3 max)
+{
+ glh::matrix4f ret;
+ ret.m[ 0] = 2/(max[0]-min[0]);
+ ret.m[ 4] = 0;
+ ret.m[ 8] = 0;
+ ret.m[12] = -(max[0]+min[0])/(max[0]-min[0]);
+
+ ret.m[ 1] = 0;
+ ret.m[ 5] = 2/(max[1]-min[1]);
+ ret.m[ 9] = 0;
+ ret.m[13] = -(max[1]+min[1])/(max[1]-min[1]);
+
+ ret.m[ 2] = 0;
+ ret.m[ 6] = 0;
+ ret.m[10] = 2/(max[2]-min[2]);
+ ret.m[14] = -(max[2]+min[2])/(max[2]-min[2]);
+
+ ret.m[ 3] = 0;
+ ret.m[ 7] = 0;
+ ret.m[11] = 0;
+ ret.m[15] = 1;
+
+ return ret;
+}
+
+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)
+{
+ LLFastTimer t(FTM_SHADOW_RENDER);
+
+ //clip out geometry on the same side of water as the camera
+ S32 occlude = LLPipeline::sUseOcclusion;
+ if (!use_occlusion)
+ {
+ LLPipeline::sUseOcclusion = 0;
+ }
+ LLPipeline::sShadowRender = TRUE;
+
+ U32 types[] = { LLRenderPass::PASS_SIMPLE, LLRenderPass::PASS_FULLBRIGHT, LLRenderPass::PASS_SHINY, LLRenderPass::PASS_BUMP, LLRenderPass::PASS_FULLBRIGHT_SHINY };
+ LLGLEnable cull(GL_CULL_FACE);
+
+ if (use_shader)
+ {
+ gDeferredShadowProgram.bind();
+ }
+
+ updateCull(shadow_cam, result);
+ stateSort(shadow_cam, result);
+
+ //generate shadow map
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadMatrixf(proj.m);
+ glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
+ glLoadMatrixd(gGLModelView);
+
+ stop_glerror();
+ gGLLastMatrix = NULL;
+
+ {
+ //LLGLDepthTest depth(GL_TRUE);
+ //glClear(GL_DEPTH_BUFFER_BIT);
+ }
+
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+
+ glColor4f(1,1,1,1);
+
+ stop_glerror();
+
+ gGL.setColorMask(false, false);
+
+ //glCullFace(GL_FRONT);
+
+ LLVertexBuffer::unbind();
+
+ {
+ LLFastTimer ftm(FTM_SHADOW_SIMPLE);
+ LLGLDisable test(GL_ALPHA_TEST);
+ gGL.getTexUnit(0)->disable();
+ for (U32 i = 0; i < sizeof(types)/sizeof(U32); ++i)
+ {
+ renderObjects(types[i], LLVertexBuffer::MAP_VERTEX, FALSE);
+ }
+ gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE);
+ }
+
+ if (use_shader)
+ {
+ gDeferredShadowProgram.unbind();
+ renderGeomShadow(shadow_cam);
+ gDeferredShadowProgram.bind();
+ }
+ else
+ {
+ renderGeomShadow(shadow_cam);
+ }
+
+ {
+ LLFastTimer ftm(FTM_SHADOW_ALPHA);
+ LLGLEnable test(GL_ALPHA_TEST);
+ gGL.setAlphaRejectSettings(LLRender::CF_GREATER, 0.6f);
+ renderObjects(LLRenderPass::PASS_ALPHA_SHADOW, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0 | LLVertexBuffer::MAP_COLOR, TRUE);
+ glColor4f(1,1,1,1);
+ renderObjects(LLRenderPass::PASS_GRASS, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0, TRUE);
+ gGL.setAlphaRejectSettings(LLRender::CF_DEFAULT);
+ }
+
+ //glCullFace(GL_BACK);
+
+ gGLLastMatrix = NULL;
+ glLoadMatrixd(gGLModelView);
+ doOcclusion(shadow_cam);
+
+ if (use_shader)
+ {
+ gDeferredShadowProgram.unbind();
+ }
+
+ gGL.setColorMask(true, true);
+
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+ gGLLastMatrix = NULL;
+
+ LLPipeline::sUseOcclusion = occlude;
+ LLPipeline::sShadowRender = FALSE;
+}
+
+static LLFastTimer::DeclareTimer FTM_VISIBLE_CLOUD("Visible Cloud");
+BOOL LLPipeline::getVisiblePointCloud(LLCamera& camera, LLVector3& min, LLVector3& max, std::vector<LLVector3>& fp, LLVector3 light_dir)
+{
+ LLFastTimer t(FTM_VISIBLE_CLOUD);
+ //get point cloud of intersection of frust and min, max
+
+ if (getVisibleExtents(camera, min, max))
+ {
+ return FALSE;
+ }
+
+ //get set of planes on bounding box
+ LLPlane bp[] = {
+ LLPlane(min, LLVector3(-1,0,0)),
+ LLPlane(min, LLVector3(0,-1,0)),
+ LLPlane(min, LLVector3(0,0,-1)),
+ LLPlane(max, LLVector3(1,0,0)),
+ LLPlane(max, LLVector3(0,1,0)),
+ LLPlane(max, LLVector3(0,0,1))};
+
+ //potential points
+ std::vector<LLVector3> pp;
+
+ //add corners of AABB
+ pp.push_back(LLVector3(min.mV[0], min.mV[1], min.mV[2]));
+ pp.push_back(LLVector3(max.mV[0], min.mV[1], min.mV[2]));
+ pp.push_back(LLVector3(min.mV[0], max.mV[1], min.mV[2]));
+ pp.push_back(LLVector3(max.mV[0], max.mV[1], min.mV[2]));
+ pp.push_back(LLVector3(min.mV[0], min.mV[1], max.mV[2]));
+ pp.push_back(LLVector3(max.mV[0], min.mV[1], max.mV[2]));
+ pp.push_back(LLVector3(min.mV[0], max.mV[1], max.mV[2]));
+ pp.push_back(LLVector3(max.mV[0], max.mV[1], max.mV[2]));
+
+ //add corners of camera frustum
+ for (U32 i = 0; i < 8; i++)
+ {
+ pp.push_back(camera.mAgentFrustum[i]);
+ }
+
+
+ //bounding box line segments
+ U32 bs[] =
+ {
+ 0,1,
+ 1,3,
+ 3,2,
+ 2,0,
+
+ 4,5,
+ 5,7,
+ 7,6,
+ 6,4,
+
+ 0,4,
+ 1,5,
+ 3,7,
+ 2,6
+ };
+
+ for (U32 i = 0; i < 12; i++)
+ { //for each line segment in bounding box
+ for (U32 j = 0; j < 6; j++)
+ { //for each plane in camera frustum
+ const LLPlane& cp = camera.getAgentPlane(j);
+ const LLVector3& v1 = pp[bs[i*2+0]];
+ const LLVector3& v2 = pp[bs[i*2+1]];
+ LLVector3 n;
+ cp.getVector3(n);
+
+ LLVector3 line = v1-v2;
+
+ F32 d1 = line*n;
+ F32 d2 = -cp.dist(v2);
+
+ F32 t = d2/d1;
+
+ if (t > 0.f && t < 1.f)
+ {
+ LLVector3 intersect = v2+line*t;
+ pp.push_back(intersect);
+ }
+ }
+ }
+
+ //camera frustum line segments
+ const U32 fs[] =
+ {
+ 0,1,
+ 1,2,
+ 2,3,
+ 3,0,
+
+ 4,5,
+ 5,6,
+ 6,7,
+ 7,4,
+
+ 0,4,
+ 1,5,
+ 2,6,
+ 3,7
+ };
+
+ LLVector3 center = (max+min)*0.5f;
+ LLVector3 size = (max-min)*0.5f;
+
+ for (U32 i = 0; i < 12; i++)
+ {
+ for (U32 j = 0; j < 6; ++j)
+ {
+ const LLVector3& v1 = pp[fs[i*2+0]+8];
+ const LLVector3& v2 = pp[fs[i*2+1]+8];
+ const LLPlane& cp = bp[j];
+ LLVector3 n;
+ cp.getVector3(n);
+
+ LLVector3 line = v1-v2;
+
+ F32 d1 = line*n;
+ F32 d2 = -cp.dist(v2);
+
+ F32 t = d2/d1;
+
+ if (t > 0.f && t < 1.f)
+ {
+ LLVector3 intersect = v2+line*t;
+ pp.push_back(intersect);
+ }
+ }
+ }
+
+ LLVector3 ext[] = { min-LLVector3(0.05f,0.05f,0.05f),
+ max+LLVector3(0.05f,0.05f,0.05f) };
+
+ for (U32 i = 0; i < pp.size(); ++i)
+ {
+ bool found = true;
+
+ const F32* p = pp[i].mV;
+
+ for (U32 j = 0; j < 3; ++j)
+ {
+ if (p[j] < ext[0].mV[j] ||
+ p[j] > ext[1].mV[j])
+ {
+ found = false;
+ break;
+ }
+ }
+
+ for (U32 j = 0; j < 6; ++j)
+ {
+ const LLPlane& cp = camera.getAgentPlane(j);
+ F32 dist = cp.dist(pp[i]);
+ if (dist > 0.05f) //point is above some plane, not contained
+ {
+ found = false;
+ break;
+ }
+ }
+
+ if (found)
+ {
+ fp.push_back(pp[i]);
+ }
+ }
+
+ if (fp.empty())
+ {
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+void LLPipeline::generateGI(LLCamera& camera, LLVector3& lightDir, std::vector<LLVector3>& vpc)
+{
+ if (LLViewerShaderMgr::instance()->getVertexShaderLevel(LLViewerShaderMgr::SHADER_DEFERRED) < 3)
+ {
+ return;
+ }
+
+ LLVector3 up;
+
+ //LLGLEnable depth_clamp(GL_DEPTH_CLAMP_NV);
+
+ if (lightDir.mV[2] > 0.5f)
+ {
+ up = LLVector3(1,0,0);
+ }
+ else
+ {
+ up = LLVector3(0, 0, 1);
+ }
+
+
+ F32 gi_range = gSavedSettings.getF32("RenderGIRange");
+
+ U32 res = mGIMap.getWidth();
+
+ F32 atten = llmax(gSavedSettings.getF32("RenderGIAttenuation"), 0.001f);
+
+ //set radius to range at which distance attenuation of incoming photons is near 0
+
+ F32 lrad = sqrtf(1.f/(atten*0.01f));
+
+ F32 lrange = lrad+gi_range*0.5f;
+
+ LLVector3 pad(lrange,lrange,lrange);
+
+ glh::matrix4f view = look(LLVector3(128.f,128.f,128.f), lightDir, up);
+
+ LLVector3 cp = camera.getOrigin()+camera.getAtAxis()*(gi_range*0.5f);
+
+ glh::vec3f scp(cp.mV);
+ view.mult_matrix_vec(scp);
+ cp.setVec(scp.v);
+
+ F32 pix_width = lrange/(res*0.5f);
+
+ //move cp to the nearest pix_width
+ for (U32 i = 0; i < 3; i++)
+ {
+ cp.mV[i] = llround(cp.mV[i], pix_width);
+ }
+
+ LLVector3 min = cp-pad;
+ LLVector3 max = cp+pad;
+
+ //set mGIRange to range in tc space[0,1] that covers texture block of intersecting lights around a point
+ mGIRange.mV[0] = (max.mV[0]-min.mV[0])/res;
+ mGIRange.mV[1] = (max.mV[1]-min.mV[1])/res;
+ mGILightRadius = lrad/lrange*0.5f;
+
+ glh::matrix4f proj = gl_ortho(min.mV[0], max.mV[0],
+ min.mV[1], max.mV[1],
+ -max.mV[2], -min.mV[2]);
+
+ LLCamera sun_cam = camera;
+
+ glh::matrix4f eye_view = glh_get_current_modelview();
+
+ //get eye space to camera space matrix
+ mGIMatrix = view*eye_view.inverse();
+ mGINormalMatrix = mGIMatrix.inverse().transpose();
+ mGIInvProj = proj.inverse();
+ mGIMatrixProj = proj*mGIMatrix;
+
+ //translate and scale to [0,1]
+ glh::matrix4f trans(.5f, 0.f, 0.f, .5f,
+ 0.f, 0.5f, 0.f, 0.5f,
+ 0.f, 0.f, 0.5f, 0.5f,
+ 0.f, 0.f, 0.f, 1.f);
+
+ mGIMatrixProj = trans*mGIMatrixProj;
+
+ glh_set_current_modelview(view);
+ glh_set_current_projection(proj);
+
+ LLViewerCamera::updateFrustumPlanes(sun_cam, TRUE, FALSE, TRUE);
+
+ sun_cam.ignoreAgentFrustumPlane(LLCamera::AGENT_PLANE_NEAR);
+ static LLCullResult result;
+
+ pushRenderTypeMask();
+
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_SIMPLE,
+ LLPipeline::RENDER_TYPE_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_BUMP,
+ LLPipeline::RENDER_TYPE_VOLUME,
+ LLPipeline::RENDER_TYPE_TREE,
+ LLPipeline::RENDER_TYPE_TERRAIN,
+ LLPipeline::RENDER_TYPE_WATER,
+ LLPipeline::RENDER_TYPE_VOIDWATER,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA_SHADOW,
+ LLPipeline::RENDER_TYPE_AVATAR,
+ LLPipeline::RENDER_TYPE_PASS_SIMPLE,
+ LLPipeline::RENDER_TYPE_PASS_BUMP,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_PASS_SHINY,
+ END_RENDER_TYPES);
+
+
+
+ S32 occlude = LLPipeline::sUseOcclusion;
+ //LLPipeline::sUseOcclusion = 0;
+ LLPipeline::sShadowRender = TRUE;
+
+ //only render large objects into GI map
+ sMinRenderSize = gSavedSettings.getF32("RenderGIMinRenderSize");
+
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_GI_SOURCE;
+ mGIMap.bindTarget();
+
+ F64 last_modelview[16];
+ F64 last_projection[16];
+ for (U32 i = 0; i < 16; i++)
+ {
+ last_modelview[i] = gGLLastModelView[i];
+ last_projection[i] = gGLLastProjection[i];
+ gGLLastModelView[i] = mGIModelview.m[i];
+ gGLLastProjection[i] = mGIProjection.m[i];
+ }
+
+ sun_cam.setOrigin(0.f, 0.f, 0.f);
+ updateCull(sun_cam, result);
+ stateSort(sun_cam, result);
+
+ for (U32 i = 0; i < 16; i++)
+ {
+ gGLLastModelView[i] = last_modelview[i];
+ gGLLastProjection[i] = last_projection[i];
+ }
+
+ mGIProjection = proj;
+ mGIModelview = view;
+
+ LLGLEnable cull(GL_CULL_FACE);
+
+ //generate GI map
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadMatrixf(proj.m);
+ glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
+ glLoadMatrixf(view.m);
+
+ stop_glerror();
+ gGLLastMatrix = NULL;
+
+ mGIMap.clear();
+
+ {
+ //LLGLEnable enable(GL_DEPTH_CLAMP_NV);
+ renderGeomDeferred(camera);
+ }
+
+ mGIMap.flush();
+
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+ gGLLastMatrix = NULL;
+
+ LLPipeline::sUseOcclusion = occlude;
+ LLPipeline::sShadowRender = FALSE;
+ sMinRenderSize = 0.f;
+
+ popRenderTypeMask();
+
+}
+
+void LLPipeline::renderHighlight(const LLViewerObject* obj, F32 fade)
+{
+ if (obj && obj->getVolume())
+ {
+ for (LLViewerObject::child_list_t::const_iterator iter = obj->getChildren().begin(); iter != obj->getChildren().end(); ++iter)
+ {
+ renderHighlight(*iter, fade);
+ }
+
+ LLDrawable* drawable = obj->mDrawable;
+ if (drawable)
+ {
+ for (S32 i = 0; i < drawable->getNumFaces(); ++i)
+ {
+ LLFace* face = drawable->getFace(i);
+ if (face)
+ {
+ face->renderSelected(LLViewerTexture::sNullImagep, LLColor4(1,1,1,fade));
+ }
+ }
+ }
+ }
+}
+
+void LLPipeline::generateHighlight(LLCamera& camera)
+{
+ //render highlighted object as white into offscreen render target
+ if (mHighlightObject.notNull())
+ {
+ mHighlightSet.insert(HighlightItem(mHighlightObject));
+ }
+
+ if (!mHighlightSet.empty())
+ {
+ F32 transition = gFrameIntervalSeconds/gSavedSettings.getF32("RenderHighlightFadeTime");
+
+ LLGLDisable test(GL_ALPHA_TEST);
+ LLGLDepthTest depth(GL_FALSE);
+ mHighlight.bindTarget();
+ disableLights();
+ gGL.setColorMask(true, true);
+ mHighlight.clear();
+
+ gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep);
+ for (std::set<HighlightItem>::iterator iter = mHighlightSet.begin(); iter != mHighlightSet.end(); )
+ {
+ std::set<HighlightItem>::iterator cur_iter = iter++;
+
+ if (cur_iter->mItem.isNull())
+ {
+ mHighlightSet.erase(cur_iter);
+ continue;
+ }
+
+ if (cur_iter->mItem == mHighlightObject)
+ {
+ cur_iter->incrFade(transition);
+ }
+ else
+ {
+ cur_iter->incrFade(-transition);
+ if (cur_iter->mFade <= 0.f)
+ {
+ mHighlightSet.erase(cur_iter);
+ continue;
+ }
+ }
+
+ renderHighlight(cur_iter->mItem->getVObj(), cur_iter->mFade);
+ }
+
+ mHighlight.flush();
+ gGL.setColorMask(true, false);
+ gViewerWindow->setup3DViewport();
+ }
+}
+
+
+void LLPipeline::generateSunShadow(LLCamera& camera)
+{
+ if (!sRenderDeferred || gSavedSettings.getS32("RenderShadowDetail") <= 0)
+ {
+ return;
+ }
+
+ F64 last_modelview[16];
+ F64 last_projection[16];
+ for (U32 i = 0; i < 16; i++)
+ { //store last_modelview of world camera
+ last_modelview[i] = gGLLastModelView[i];
+ last_projection[i] = gGLLastProjection[i];
+ }
+
+ pushRenderTypeMask();
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_SIMPLE,
+ LLPipeline::RENDER_TYPE_ALPHA,
+ LLPipeline::RENDER_TYPE_GRASS,
+ LLPipeline::RENDER_TYPE_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_BUMP,
+ LLPipeline::RENDER_TYPE_VOLUME,
+ LLPipeline::RENDER_TYPE_AVATAR,
+ LLPipeline::RENDER_TYPE_TREE,
+ LLPipeline::RENDER_TYPE_TERRAIN,
+ LLPipeline::RENDER_TYPE_WATER,
+ LLPipeline::RENDER_TYPE_VOIDWATER,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA_SHADOW,
+ LLPipeline::RENDER_TYPE_PASS_SIMPLE,
+ LLPipeline::RENDER_TYPE_PASS_BUMP,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_PASS_SHINY,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY,
+ END_RENDER_TYPES);
+
+ gGL.setColorMask(false, false);
+
+ //get sun view matrix
+
+ //store current projection/modelview matrix
+ glh::matrix4f saved_proj = glh_get_current_projection();
+ glh::matrix4f saved_view = glh_get_current_modelview();
+ glh::matrix4f inv_view = saved_view.inverse();
+
+ glh::matrix4f view[6];
+ glh::matrix4f proj[6];
+
+ //clip contains parallel split distances for 3 splits
+ LLVector3 clip = gSavedSettings.getVector3("RenderShadowClipPlanes");
+
+ //F32 slope_threshold = gSavedSettings.getF32("RenderShadowSlopeThreshold");
+
+ //far clip on last split is minimum of camera view distance and 128
+ mSunClipPlanes = LLVector4(clip, clip.mV[2] * clip.mV[2]/clip.mV[1]);
+
+ clip = gSavedSettings.getVector3("RenderShadowOrthoClipPlanes");
+ mSunOrthoClipPlanes = LLVector4(clip, clip.mV[2]*clip.mV[2]/clip.mV[1]);
+
+ //currently used for amount to extrude frusta corners for constructing shadow frusta
+ LLVector3 n = gSavedSettings.getVector3("RenderShadowNearDist");
+ //F32 nearDist[] = { n.mV[0], n.mV[1], n.mV[2], n.mV[2] };
+
+ //put together a universal "near clip" plane for shadow frusta
+ LLPlane shadow_near_clip;
+ {
+ LLVector3 p = gAgent.getPositionAgent();
+ p += mSunDir * gSavedSettings.getF32("RenderFarClip")*2.f;
+ shadow_near_clip.setVec(p, mSunDir);
+ }
+
+ LLVector3 lightDir = -mSunDir;
+ lightDir.normVec();
+
+ glh::vec3f light_dir(lightDir.mV);
+
+ //create light space camera matrix
+
+ LLVector3 at = lightDir;
+
+ LLVector3 up = camera.getAtAxis();
+
+ if (fabsf(up*lightDir) > 0.75f)
+ {
+ up = camera.getUpAxis();
+ }
+
+ /*LLVector3 left = up%at;
+ up = at%left;*/
+
+ up.normVec();
+ at.normVec();
+
+
+ LLCamera main_camera = camera;
+
+ F32 near_clip = 0.f;
+ {
+ //get visible point cloud
+ std::vector<LLVector3> fp;
+
+ main_camera.calcAgentFrustumPlanes(main_camera.mAgentFrustum);
+
+ LLVector3 min,max;
+ getVisiblePointCloud(main_camera,min,max,fp);
+
+ if (fp.empty())
+ {
+ if (!hasRenderDebugMask(RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowCamera[0] = main_camera;
+ mShadowExtents[0][0] = min;
+ mShadowExtents[0][1] = max;
+
+ mShadowFrustPoints[0].clear();
+ mShadowFrustPoints[1].clear();
+ mShadowFrustPoints[2].clear();
+ mShadowFrustPoints[3].clear();
+ }
+ popRenderTypeMask();
+ return;
+ }
+
+ generateGI(camera, lightDir, fp);
+
+ //get good split distances for frustum
+ for (U32 i = 0; i < fp.size(); ++i)
+ {
+ glh::vec3f v(fp[i].mV);
+ saved_view.mult_matrix_vec(v);
+ fp[i].setVec(v.v);
+ }
+
+ min = fp[0];
+ max = fp[0];
+
+ //get camera space bounding box
+ for (U32 i = 1; i < fp.size(); ++i)
+ {
+ update_min_max(min, max, fp[i]);
+ }
+
+ near_clip = -max.mV[2];
+ F32 far_clip = -min.mV[2]*2.f;
+
+ far_clip = llmin(far_clip, 128.f);
+ far_clip = llmin(far_clip, camera.getFar());
+
+ F32 range = far_clip-near_clip;
+
+ LLVector3 split_exp = gSavedSettings.getVector3("RenderShadowSplitExponent");
+
+ F32 da = 1.f-llmax( fabsf(lightDir*up), fabsf(lightDir*camera.getLeftAxis()) );
+
+ da = powf(da, split_exp.mV[2]);
+
+
+ F32 sxp = split_exp.mV[1] + (split_exp.mV[0]-split_exp.mV[1])*da;
+
+
+ for (U32 i = 0; i < 4; ++i)
+ {
+ F32 x = (F32)(i+1)/4.f;
+ x = powf(x, sxp);
+ mSunClipPlanes.mV[i] = near_clip+range*x;
+ }
+ }
+
+ // convenience array of 4 near clip plane distances
+ F32 dist[] = { near_clip, mSunClipPlanes.mV[0], mSunClipPlanes.mV[1], mSunClipPlanes.mV[2], mSunClipPlanes.mV[3] };
+
+ for (S32 j = 0; j < 4; j++)
+ {
+ if (!hasRenderDebugMask(RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowFrustPoints[j].clear();
+ }
+
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW0+j;
+
+ //restore render matrices
+ glh_set_current_modelview(saved_view);
+ glh_set_current_projection(saved_proj);
+
+ LLVector3 eye = camera.getOrigin();
+
+ //camera used for shadow cull/render
+ LLCamera shadow_cam;
+
+ //create world space camera frustum for this split
+ shadow_cam = camera;
+ shadow_cam.setFar(16.f);
+
+ LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE);
+
+ LLVector3* frust = shadow_cam.mAgentFrustum;
+
+ LLVector3 pn = shadow_cam.getAtAxis();
+
+ LLVector3 min, max;
+
+ //construct 8 corners of split frustum section
+ for (U32 i = 0; i < 4; i++)
+ {
+ LLVector3 delta = frust[i+4]-eye;
+ delta += (frust[i+4]-frust[(i+2)%4+4])*0.05f;
+ delta.normVec();
+ F32 dp = delta*pn;
+ frust[i] = eye + (delta*dist[j]*0.95f)/dp;
+ frust[i+4] = eye + (delta*dist[j+1]*1.05f)/dp;
+ }
+
+ shadow_cam.calcAgentFrustumPlanes(frust);
+ shadow_cam.mFrustumCornerDist = 0.f;
+
+ if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowCamera[j] = shadow_cam;
+ }
+
+ std::vector<LLVector3> fp;
+
+ if (!gPipeline.getVisiblePointCloud(shadow_cam, min, max, fp, lightDir))
+ {
+ //no possible shadow receivers
+ if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowExtents[j][0] = LLVector3();
+ mShadowExtents[j][1] = LLVector3();
+ mShadowCamera[j+4] = shadow_cam;
+ }
+
+ mShadow[j].bindTarget();
+ {
+ LLGLDepthTest depth(GL_TRUE);
+ mShadow[j].clear();
+ }
+ mShadow[j].flush();
+
+ mShadowError.mV[j] = 0.f;
+ mShadowFOV.mV[j] = 0.f;
+
+ continue;
+ }
+
+ if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowExtents[j][0] = min;
+ mShadowExtents[j][1] = max;
+ mShadowFrustPoints[j] = fp;
+ }
+
+
+ //find a good origin for shadow projection
+ LLVector3 origin;
+
+ //get a temporary view projection
+ view[j] = look(camera.getOrigin(), lightDir, -up);
+
+ std::vector<LLVector3> wpf;
+
+ for (U32 i = 0; i < fp.size(); i++)
+ {
+ glh::vec3f p = glh::vec3f(fp[i].mV);
+ view[j].mult_matrix_vec(p);
+ wpf.push_back(LLVector3(p.v));
+ }
+
+ min = wpf[0];
+ max = wpf[0];
+
+ for (U32 i = 0; i < fp.size(); ++i)
+ { //get AABB in camera space
+ update_min_max(min, max, wpf[i]);
+ }
+
+ // Construct a perspective transform with perspective along y-axis that contains
+ // points in wpf
+ //Known:
+ // - far clip plane
+ // - near clip plane
+ // - points in frustum
+ //Find:
+ // - origin
+
+ //get some "interesting" points of reference
+ LLVector3 center = (min+max)*0.5f;
+ LLVector3 size = (max-min)*0.5f;
+ LLVector3 near_center = center;
+ near_center.mV[1] += size.mV[1]*2.f;
+
+
+ //put all points in wpf in quadrant 0, reletive to center of min/max
+ //get the best fit line using least squares
+ F32 bfm = 0.f;
+ F32 bfb = 0.f;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ wpf[i] -= center;
+ wpf[i].mV[0] = fabsf(wpf[i].mV[0]);
+ wpf[i].mV[2] = fabsf(wpf[i].mV[2]);
+ }
+
+ if (!wpf.empty())
+ {
+ F32 sx = 0.f;
+ F32 sx2 = 0.f;
+ F32 sy = 0.f;
+ F32 sxy = 0.f;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ sx += wpf[i].mV[0];
+ sx2 += wpf[i].mV[0]*wpf[i].mV[0];
+ sy += wpf[i].mV[1];
+ sxy += wpf[i].mV[0]*wpf[i].mV[1];
+ }
+
+ bfm = (sy*sx-wpf.size()*sxy)/(sx*sx-wpf.size()*sx2);
+ bfb = (sx*sxy-sy*sx2)/(sx*sx-bfm*sx2);
+ }
+
+ {
+ // best fit line is y=bfm*x+bfb
+
+ //find point that is furthest to the right of line
+ F32 off_x = -1.f;
+ LLVector3 lp;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ //y = bfm*x+bfb
+ //x = (y-bfb)/bfm
+ F32 lx = (wpf[i].mV[1]-bfb)/bfm;
+
+ lx = wpf[i].mV[0]-lx;
+
+ if (off_x < lx)
+ {
+ off_x = lx;
+ lp = wpf[i];
+ }
+ }
+
+ //get line with slope bfm through lp
+ // bfb = y-bfm*x
+ bfb = lp.mV[1]-bfm*lp.mV[0];
+
+ //calculate error
+ mShadowError.mV[j] = 0.f;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ F32 lx = (wpf[i].mV[1]-bfb)/bfm;
+ mShadowError.mV[j] += fabsf(wpf[i].mV[0]-lx);
+ }
+
+ mShadowError.mV[j] /= wpf.size();
+ mShadowError.mV[j] /= size.mV[0];
+
+ if (mShadowError.mV[j] > gSavedSettings.getF32("RenderShadowErrorCutoff"))
+ { //just use ortho projection
+ mShadowFOV.mV[j] = -1.f;
+ origin.clearVec();
+ proj[j] = gl_ortho(min.mV[0], max.mV[0],
+ min.mV[1], max.mV[1],
+ -max.mV[2], -min.mV[2]);
+ }
+ else
+ {
+ //origin is where line x = 0;
+ origin.setVec(0,bfb,0);
+
+ F32 fovz = 1.f;
+ F32 fovx = 1.f;
+
+ LLVector3 zp;
+ LLVector3 xp;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ LLVector3 atz = wpf[i]-origin;
+ atz.mV[0] = 0.f;
+ atz.normVec();
+ if (fovz > -atz.mV[1])
+ {
+ zp = wpf[i];
+ fovz = -atz.mV[1];
+ }
+
+ LLVector3 atx = wpf[i]-origin;
+ atx.mV[2] = 0.f;
+ atx.normVec();
+ if (fovx > -atx.mV[1])
+ {
+ fovx = -atx.mV[1];
+ xp = wpf[i];
+ }
+ }
+
+ fovx = acos(fovx);
+ fovz = acos(fovz);
+
+ F32 cutoff = llmin(gSavedSettings.getF32("RenderShadowFOVCutoff"), 1.4f);
+
+ mShadowFOV.mV[j] = fovx;
+
+ if (fovx < cutoff && fovz > cutoff)
+ {
+ //x is a good fit, but z is too big, move away from zp enough so that fovz matches cutoff
+ F32 d = zp.mV[2]/tan(cutoff);
+ F32 ny = zp.mV[1] + fabsf(d);
+
+ origin.mV[1] = ny;
+
+ fovz = 1.f;
+ fovx = 1.f;
+
+ for (U32 i = 0; i < wpf.size(); ++i)
+ {
+ LLVector3 atz = wpf[i]-origin;
+ atz.mV[0] = 0.f;
+ atz.normVec();
+ fovz = llmin(fovz, -atz.mV[1]);
+
+ LLVector3 atx = wpf[i]-origin;
+ atx.mV[2] = 0.f;
+ atx.normVec();
+ fovx = llmin(fovx, -atx.mV[1]);
+ }
+
+ fovx = acos(fovx);
+ fovz = acos(fovz);
+
+ if (fovx > cutoff || llround(fovz, 0.01f) > cutoff)
+ {
+ // llerrs << "WTF?" << llendl;
+ }
+
+ mShadowFOV.mV[j] = cutoff;
+ }
+
+
+ origin += center;
+
+ F32 ynear = -(max.mV[1]-origin.mV[1]);
+ F32 yfar = -(min.mV[1]-origin.mV[1]);
+
+ if (ynear < 0.1f) //keep a sensible near clip plane
+ {
+ F32 diff = 0.1f-ynear;
+ origin.mV[1] += diff;
+ ynear += diff;
+ yfar += diff;
+ }
+
+ if (fovx > cutoff)
+ { //just use ortho projection
+ origin.clearVec();
+ mShadowError.mV[j] = -1.f;
+ proj[j] = gl_ortho(min.mV[0], max.mV[0],
+ min.mV[1], max.mV[1],
+ -max.mV[2], -min.mV[2]);
+ }
+ else
+ {
+ //get perspective projection
+ view[j] = view[j].inverse();
+
+ glh::vec3f origin_agent(origin.mV);
+
+ //translate view to origin
+ view[j].mult_matrix_vec(origin_agent);
+
+ eye = LLVector3(origin_agent.v);
+
+ if (!hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ mShadowFrustOrigin[j] = eye;
+ }
+
+ view[j] = look(LLVector3(origin_agent.v), lightDir, -up);
+
+ F32 fx = 1.f/tanf(fovx);
+ F32 fz = 1.f/tanf(fovz);
+
+ proj[j] = glh::matrix4f(-fx, 0, 0, 0,
+ 0, (yfar+ynear)/(ynear-yfar), 0, (2.f*yfar*ynear)/(ynear-yfar),
+ 0, 0, -fz, 0,
+ 0, -1.f, 0, 0);
+ }
+ }
+ }
+
+ shadow_cam.setFar(128.f);
+ shadow_cam.setOriginAndLookAt(eye, up, center);
+
+ shadow_cam.setOrigin(0,0,0);
+
+ glh_set_current_modelview(view[j]);
+ glh_set_current_projection(proj[j]);
+
+ LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE);
+
+ //shadow_cam.ignoreAgentFrustumPlane(LLCamera::AGENT_PLANE_NEAR);
+ shadow_cam.getAgentPlane(LLCamera::AGENT_PLANE_NEAR).set(shadow_near_clip);
+
+ //translate and scale to from [-1, 1] to [0, 1]
+ glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f,
+ 0.f, 0.5f, 0.f, 0.5f,
+ 0.f, 0.f, 0.5f, 0.5f,
+ 0.f, 0.f, 0.f, 1.f);
+
+ glh_set_current_modelview(view[j]);
+ glh_set_current_projection(proj[j]);
+
+ for (U32 i = 0; i < 16; i++)
+ {
+ gGLLastModelView[i] = mShadowModelview[j].m[i];
+ gGLLastProjection[i] = mShadowProjection[j].m[i];
+ }
+
+ mShadowModelview[j] = view[j];
+ mShadowProjection[j] = proj[j];
+
+
+ mSunShadowMatrix[j] = trans*proj[j]*view[j]*inv_view;
+
+ stop_glerror();
+
+ mShadow[j].bindTarget();
+ mShadow[j].getViewport(gGLViewport);
+ mShadow[j].clear();
+
+ {
+ static LLCullResult result[4];
+
+ //LLGLEnable enable(GL_DEPTH_CLAMP_NV);
+ renderShadow(view[j], proj[j], shadow_cam, result[j], TRUE);
+ }
+
+ mShadow[j].flush();
+
+ if (!gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
+ {
+ LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE);
+ mShadowCamera[j+4] = shadow_cam;
+ }
+ }
+
+
+ //hack to disable projector shadows
+ bool gen_shadow = gSavedSettings.getS32("RenderShadowDetail") > 1;
+
+ if (gen_shadow)
+ {
+ F32 fade_amt = gFrameIntervalSeconds * llmax(LLViewerCamera::getInstance()->getVelocityStat()->getCurrentPerSec(), 1.f);
+
+ //update shadow targets
+ for (U32 i = 0; i < 2; i++)
+ { //for each current shadow
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW4+i;
+
+ if (mShadowSpotLight[i].notNull() &&
+ (mShadowSpotLight[i] == mTargetShadowSpotLight[0] ||
+ mShadowSpotLight[i] == mTargetShadowSpotLight[1]))
+ { //keep this spotlight
+ mSpotLightFade[i] = llmin(mSpotLightFade[i]+fade_amt, 1.f);
+ }
+ else
+ { //fade out this light
+ mSpotLightFade[i] = llmax(mSpotLightFade[i]-fade_amt, 0.f);
+
+ if (mSpotLightFade[i] == 0.f || mShadowSpotLight[i].isNull())
+ { //faded out, grab one of the pending spots (whichever one isn't already taken)
+ if (mTargetShadowSpotLight[0] != mShadowSpotLight[(i+1)%2])
+ {
+ mShadowSpotLight[i] = mTargetShadowSpotLight[0];
+ }
+ else
+ {
+ mShadowSpotLight[i] = mTargetShadowSpotLight[1];
+ }
+ }
+ }
+ }
+
+ for (S32 i = 0; i < 2; i++)
+ {
+ glh_set_current_modelview(saved_view);
+ glh_set_current_projection(saved_proj);
+
+ if (mShadowSpotLight[i].isNull())
+ {
+ continue;
+ }
+
+ LLVOVolume* volume = mShadowSpotLight[i]->getVOVolume();
+
+ if (!volume)
+ {
+ mShadowSpotLight[i] = NULL;
+ continue;
+ }
+
+ LLDrawable* drawable = mShadowSpotLight[i];
+
+ LLVector3 params = volume->getSpotLightParams();
+ F32 fov = params.mV[0];
+
+ //get agent->light space matrix (modelview)
+ LLVector3 center = drawable->getPositionAgent();
+ LLQuaternion quat = volume->getRenderRotation();
+
+ //get near clip plane
+ LLVector3 scale = volume->getScale();
+ LLVector3 at_axis(0,0,-scale.mV[2]*0.5f);
+ at_axis *= quat;
+
+ LLVector3 np = center+at_axis;
+ at_axis.normVec();
+
+ //get origin that has given fov for plane np, at_axis, and given scale
+ F32 dist = (scale.mV[1]*0.5f)/tanf(fov*0.5f);
+
+ LLVector3 origin = np - at_axis*dist;
+
+ LLMatrix4 mat(quat, LLVector4(origin, 1.f));
+
+ view[i+4] = glh::matrix4f((F32*) mat.mMatrix);
+
+ view[i+4] = view[i+4].inverse();
+
+ //get perspective matrix
+ F32 near_clip = dist+0.01f;
+ F32 width = scale.mV[VX];
+ F32 height = scale.mV[VY];
+ F32 far_clip = dist+volume->getLightRadius()*1.5f;
+
+ F32 fovy = fov * RAD_TO_DEG;
+ F32 aspect = width/height;
+
+ proj[i+4] = gl_perspective(fovy, aspect, near_clip, far_clip);
+
+ //translate and scale to from [-1, 1] to [0, 1]
+ glh::matrix4f trans(0.5f, 0.f, 0.f, 0.5f,
+ 0.f, 0.5f, 0.f, 0.5f,
+ 0.f, 0.f, 0.5f, 0.5f,
+ 0.f, 0.f, 0.f, 1.f);
+
+ glh_set_current_modelview(view[i+4]);
+ glh_set_current_projection(proj[i+4]);
+
+ mSunShadowMatrix[i+4] = trans*proj[i+4]*view[i+4]*inv_view;
+
+ for (U32 j = 0; j < 16; j++)
+ {
+ gGLLastModelView[j] = mShadowModelview[i+4].m[j];
+ gGLLastProjection[j] = mShadowProjection[i+4].m[j];
+ }
+
+ mShadowModelview[i+4] = view[i+4];
+ mShadowProjection[i+4] = proj[i+4];
+
+ LLCamera shadow_cam = camera;
+ shadow_cam.setFar(far_clip);
+ shadow_cam.setOrigin(origin);
+
+ LLViewerCamera::updateFrustumPlanes(shadow_cam, FALSE, FALSE, TRUE);
+
+ stop_glerror();
+
+ mShadow[i+4].bindTarget();
+ mShadow[i+4].getViewport(gGLViewport);
+ mShadow[i+4].clear();
+
+ static LLCullResult result[2];
+
+ LLViewerCamera::sCurCameraID = LLViewerCamera::CAMERA_SHADOW0+i+4;
+
+ renderShadow(view[i+4], proj[i+4], shadow_cam, result[i], FALSE, FALSE);
+
+ mShadow[i+4].flush();
+ }
+ }
+
+ if (!gSavedSettings.getBOOL("CameraOffset"))
+ {
+ glh_set_current_modelview(saved_view);
+ glh_set_current_projection(saved_proj);
+ }
+ else
+ {
+ glh_set_current_modelview(view[1]);
+ glh_set_current_projection(proj[1]);
+ glLoadMatrixf(view[1].m);
+ glMatrixMode(GL_PROJECTION);
+ glLoadMatrixf(proj[1].m);
+ glMatrixMode(GL_MODELVIEW);
+ }
+ gGL.setColorMask(true, false);
+
+ for (U32 i = 0; i < 16; i++)
+ {
+ gGLLastModelView[i] = last_modelview[i];
+ gGLLastProjection[i] = last_projection[i];
+ }
+
+ popRenderTypeMask();
+}
+
+void LLPipeline::renderGroups(LLRenderPass* pass, U32 type, U32 mask, BOOL texture)
+{
+ for (LLCullResult::sg_list_t::iterator i = sCull->beginVisibleGroups(); i != sCull->endVisibleGroups(); ++i)
+ {
+ LLSpatialGroup* group = *i;
+ if (!group->isDead() &&
+ (!sUseOcclusion || !group->isOcclusionState(LLSpatialGroup::OCCLUDED)) &&
+ gPipeline.hasRenderType(group->mSpatialPartition->mDrawableType) &&
+ group->mDrawMap.find(type) != group->mDrawMap.end())
+ {
+ pass->renderGroup(group,type,mask,texture);
+ }
+ }
+}
+
+void LLPipeline::generateImpostor(LLVOAvatar* avatar)
+{
+ LLMemType mt_gi(LLMemType::MTYPE_PIPELINE_GENERATE_IMPOSTOR);
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+
+ static LLCullResult result;
+ result.clear();
+ grabReferences(result);
+
+ if (!avatar || !avatar->mDrawable)
+ {
+ return;
+ }
+
+ assertInitialized();
+
+ BOOL muted = LLMuteList::getInstance()->isMuted(avatar->getID());
+
+ pushRenderTypeMask();
+
+ if (muted)
+ {
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_AVATAR, END_RENDER_TYPES);
+ }
+ else
+ {
+ andRenderTypeMask(LLPipeline::RENDER_TYPE_VOLUME,
+ LLPipeline::RENDER_TYPE_AVATAR,
+ LLPipeline::RENDER_TYPE_BUMP,
+ LLPipeline::RENDER_TYPE_GRASS,
+ LLPipeline::RENDER_TYPE_SIMPLE,
+ LLPipeline::RENDER_TYPE_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_ALPHA,
+ LLPipeline::RENDER_TYPE_INVISIBLE,
+ LLPipeline::RENDER_TYPE_PASS_SIMPLE,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA,
+ LLPipeline::RENDER_TYPE_PASS_ALPHA_MASK,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_ALPHA_MASK,
+ LLPipeline::RENDER_TYPE_PASS_FULLBRIGHT_SHINY,
+ LLPipeline::RENDER_TYPE_PASS_SHINY,
+ LLPipeline::RENDER_TYPE_PASS_INVISIBLE,
+ LLPipeline::RENDER_TYPE_PASS_INVISI_SHINY,
+ END_RENDER_TYPES);
+ }
+
+ S32 occlusion = sUseOcclusion;
+ sUseOcclusion = 0;
+ sReflectionRender = sRenderDeferred ? FALSE : TRUE;
+ sShadowRender = TRUE;
+ sImpostorRender = TRUE;
+
+ LLViewerCamera* viewer_camera = LLViewerCamera::getInstance();
+ markVisible(avatar->mDrawable, *viewer_camera);
+ LLVOAvatar::sUseImpostors = FALSE;
+
+ LLVOAvatar::attachment_map_t::iterator iter;
+ for (iter = avatar->mAttachmentPoints.begin();
+ iter != avatar->mAttachmentPoints.end();
+ ++iter)
+ {
+ LLViewerJointAttachment *attachment = iter->second;
+ for (LLViewerJointAttachment::attachedobjs_vec_t::iterator attachment_iter = attachment->mAttachedObjects.begin();
+ attachment_iter != attachment->mAttachedObjects.end();
+ ++attachment_iter)
+ {
+ if (LLViewerObject* attached_object = (*attachment_iter))
+ {
+ markVisible(attached_object->mDrawable->getSpatialBridge(), *viewer_camera);
+ }
+ }
+ }
+
+ stateSort(*LLViewerCamera::getInstance(), result);
+
+ const LLVector4a* ext = avatar->mDrawable->getSpatialExtents();
+ LLVector3 pos(avatar->getRenderPosition()+avatar->getImpostorOffset());
+
+ LLCamera camera = *viewer_camera;
+
+ camera.lookAt(viewer_camera->getOrigin(), pos, viewer_camera->getUpAxis());
+
+ LLVector2 tdim;
+
+
+ LLVector4a half_height;
+ half_height.setSub(ext[1], ext[0]);
+ half_height.mul(0.5f);
+
+ LLVector4a left;
+ left.load3(camera.getLeftAxis().mV);
+ left.mul(left);
+ left.normalize3fast();
+
+ LLVector4a up;
+ up.load3(camera.getUpAxis().mV);
+ up.mul(up);
+ up.normalize3fast();
+
+ tdim.mV[0] = fabsf(half_height.dot3(left).getF32());
+ tdim.mV[1] = fabsf(half_height.dot3(up).getF32());
+
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+
+ F32 distance = (pos-camera.getOrigin()).length();
+ F32 fov = atanf(tdim.mV[1]/distance)*2.f*RAD_TO_DEG;
+ F32 aspect = tdim.mV[0]/tdim.mV[1];
+ glh::matrix4f persp = gl_perspective(fov, aspect, 1.f, 256.f);
+ glh_set_current_projection(persp);
+ glLoadMatrixf(persp.m);
+
+ glMatrixMode(GL_MODELVIEW);
+ glPushMatrix();
+ glh::matrix4f mat;
+ camera.getOpenGLTransform(mat.m);
+
+ mat = glh::matrix4f((GLfloat*) OGL_TO_CFR_ROTATION) * mat;
+
+ glLoadMatrixf(mat.m);
+ glh_set_current_modelview(mat);
+
+ glClearColor(0.0f,0.0f,0.0f,0.0f);
+ gGL.setColorMask(true, true);
+
+ // get the number of pixels per angle
+ F32 pa = gViewerWindow->getWindowHeightRaw() / (RAD_TO_DEG * viewer_camera->getView());
+
+ //get resolution based on angle width and height of impostor (double desired resolution to prevent aliasing)
+ U32 resY = llmin(nhpo2((U32) (fov*pa)), (U32) 512);
+ U32 resX = llmin(nhpo2((U32) (atanf(tdim.mV[0]/distance)*2.f*RAD_TO_DEG*pa)), (U32) 512);
+
+ if (!avatar->mImpostor.isComplete() || resX != avatar->mImpostor.getWidth() ||
+ resY != avatar->mImpostor.getHeight())
+ {
+ avatar->mImpostor.allocate(resX,resY,GL_RGBA,TRUE,FALSE);
+
+ if (LLPipeline::sRenderDeferred)
+ {
+ addDeferredAttachments(avatar->mImpostor);
+ }
+
+ gGL.getTexUnit(0)->bind(&avatar->mImpostor);
+ gGL.getTexUnit(0)->setTextureFilteringOption(LLTexUnit::TFO_POINT);
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ }
+
+ avatar->mImpostor.bindTarget();
+
+ if (LLPipeline::sRenderDeferred)
+ {
+ avatar->mImpostor.clear();
+ renderGeomDeferred(camera);
+ renderGeomPostDeferred(camera);
+ }
+ else
+ {
+ LLGLEnable scissor(GL_SCISSOR_TEST);
+ glScissor(0, 0, resX, resY);
+ avatar->mImpostor.clear();
+ renderGeom(camera);
+ }
+
+ { //create alpha mask based on depth buffer (grey out if muted)
+ if (LLPipeline::sRenderDeferred)
+ {
+ GLuint buff = GL_COLOR_ATTACHMENT0;
+ glDrawBuffersARB(1, &buff);
+ }
+
+ LLGLDisable blend(GL_BLEND);
+
+ if (muted)
+ {
+ gGL.setColorMask(true, true);
+ }
+ else
+ {
+ gGL.setColorMask(false, true);
+ }
+
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+
+ LLGLDepthTest depth(GL_TRUE, GL_FALSE, GL_GREATER);
+
+ gGL.flush();
+
+ glPushMatrix();
+ glLoadIdentity();
+ glMatrixMode(GL_PROJECTION);
+ glPushMatrix();
+ glLoadIdentity();
+
+ static const F32 clip_plane = 0.99999f;
+
+ gGL.color4ub(64,64,64,255);
+ gGL.begin(LLRender::QUADS);
+ gGL.vertex3f(-1, -1, clip_plane);
+ gGL.vertex3f(1, -1, clip_plane);
+ gGL.vertex3f(1, 1, clip_plane);
+ gGL.vertex3f(-1, 1, clip_plane);
+ gGL.end();
+ gGL.flush();
+
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+ }
+
+ avatar->mImpostor.flush();
+
+ avatar->setImpostorDim(tdim);
+
+ LLVOAvatar::sUseImpostors = TRUE;
+ sUseOcclusion = occlusion;
+ sReflectionRender = FALSE;
+ sImpostorRender = FALSE;
+ sShadowRender = FALSE;
+ popRenderTypeMask();
+
+ glMatrixMode(GL_PROJECTION);
+ glPopMatrix();
+ glMatrixMode(GL_MODELVIEW);
+ glPopMatrix();
+
+ avatar->mNeedsImpostorUpdate = FALSE;
+ avatar->cacheImpostorValues();
+
+ LLVertexBuffer::unbind();
+ LLGLState::checkStates();
+ LLGLState::checkTextureChannels();
+ LLGLState::checkClientArrays();
+}
+
+BOOL LLPipeline::hasRenderBatches(const U32 type) const
+{
+ return sCull->getRenderMapSize(type) > 0;
+}
+
+LLCullResult::drawinfo_list_t::iterator LLPipeline::beginRenderMap(U32 type)
+{
+ return sCull->beginRenderMap(type);
+}
+
+LLCullResult::drawinfo_list_t::iterator LLPipeline::endRenderMap(U32 type)
+{
+ return sCull->endRenderMap(type);
+}
+
+LLCullResult::sg_list_t::iterator LLPipeline::beginAlphaGroups()
+{
+ return sCull->beginAlphaGroups();
+}
+
+LLCullResult::sg_list_t::iterator LLPipeline::endAlphaGroups()
+{
+ return sCull->endAlphaGroups();
+}
+
+BOOL LLPipeline::hasRenderType(const U32 type) const
+{
+ // STORM-365 : LLViewerJointAttachment::setAttachmentVisibility() is setting type to 0 to actually mean "do not render"
+ // We then need to test that value here and return FALSE to prevent attachment to render (in mouselook for instance)
+ // TODO: reintroduce RENDER_TYPE_NONE in LLRenderTypeMask and initialize its mRenderTypeEnabled[RENDER_TYPE_NONE] to FALSE explicitely
+ return (type == 0 ? FALSE : mRenderTypeEnabled[type]);
+}
+
+void LLPipeline::setRenderTypeMask(U32 type, ...)
+{
+ va_list args;
+
+ va_start(args, type);
+ while (type < END_RENDER_TYPES)
+ {
+ mRenderTypeEnabled[type] = TRUE;
+ type = va_arg(args, U32);
+ }
+ va_end(args);
+
+ if (type > END_RENDER_TYPES)
+ {
+ llerrs << "Invalid render type." << llendl;
+ }
+}
+
+BOOL LLPipeline::hasAnyRenderType(U32 type, ...) const
+{
+ va_list args;
+
+ va_start(args, type);
+ while (type < END_RENDER_TYPES)
+ {
+ if (mRenderTypeEnabled[type])
+ {
+ return TRUE;
+ }
+ type = va_arg(args, U32);
+ }
+ va_end(args);
+
+ if (type > END_RENDER_TYPES)
+ {
+ llerrs << "Invalid render type." << llendl;
+ }
+
+ return FALSE;
+}
+
+void LLPipeline::pushRenderTypeMask()
+{
+ std::string cur_mask;
+ cur_mask.assign((const char*) mRenderTypeEnabled, sizeof(mRenderTypeEnabled));
+ mRenderTypeEnableStack.push(cur_mask);
+}
+
+void LLPipeline::popRenderTypeMask()
+{
+ if (mRenderTypeEnableStack.empty())
+ {
+ llerrs << "Depleted render type stack." << llendl;
+ }
+
+ memcpy(mRenderTypeEnabled, mRenderTypeEnableStack.top().data(), sizeof(mRenderTypeEnabled));
+ mRenderTypeEnableStack.pop();
+}
+
+void LLPipeline::andRenderTypeMask(U32 type, ...)
+{
+ va_list args;
+
+ BOOL tmp[NUM_RENDER_TYPES];
+ for (U32 i = 0; i < NUM_RENDER_TYPES; ++i)
+ {
+ tmp[i] = FALSE;
+ }
+
+ va_start(args, type);
+ while (type < END_RENDER_TYPES)
+ {
+ if (mRenderTypeEnabled[type])
+ {
+ tmp[type] = TRUE;
+ }
+
+ type = va_arg(args, U32);
+ }
+ va_end(args);
+
+ if (type > END_RENDER_TYPES)
+ {
+ llerrs << "Invalid render type." << llendl;
+ }
+
+ for (U32 i = 0; i < LLPipeline::NUM_RENDER_TYPES; ++i)
+ {
+ mRenderTypeEnabled[i] = tmp[i];
+ }
+
+}
+
+void LLPipeline::clearRenderTypeMask(U32 type, ...)
+{
+ va_list args;
+
+ va_start(args, type);
+ while (type < END_RENDER_TYPES)
+ {
+ mRenderTypeEnabled[type] = FALSE;
+
+ type = va_arg(args, U32);
+ }
+ va_end(args);
+
+ if (type > END_RENDER_TYPES)
+ {
+ llerrs << "Invalid render type." << llendl;
+ }
+}
+
+
diff --git a/indra/newview/skins/default/xui/en/main_view.xml b/indra/newview/skins/default/xui/en/main_view.xml index d9991fcae9..e5ae0b950a 100644 --- a/indra/newview/skins/default/xui/en/main_view.xml +++ b/indra/newview/skins/default/xui/en/main_view.xml @@ -80,6 +80,13 @@ user_resize="false" name="hud container" width="500"> + <view top="0" + follows="all" + height="500" + left="0" + mouse_opaque="false" + name="floater_snap_region" + width="500"/> <panel follows="left|top" height="19" left="0" diff --git a/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml b/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml index 50ad3f834e..5e7b16ed4a 100644 --- a/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml +++ b/indra/newview/skins/default/xui/en/menu_inspect_self_gear.xml @@ -1,63 +1,249 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> <toggleable_menu - create_jump_keys="true" - layout="topleft" - mouse_opaque="false" - visible="false" - name="Gear Menu"> + layout="topleft" + name="Self Pie"> <menu_item_call label="Sit Down" - enabled="true" - name="sit_down_here"> + layout="topleft" + name="Sit Down Here"> <menu_item_call.on_click function="Self.SitDown" parameter="" /> - <menu_item_call.on_visible + <menu_item_call.on_enable function="Self.EnableSitDown" /> </menu_item_call> <menu_item_call label="Stand Up" - enabled="true" - name="stand_up"> + layout="topleft" + name="Stand Up"> <menu_item_call.on_click function="Self.StandUp" parameter="" /> - <menu_item_call.on_visible + <menu_item_call.on_enable function="Self.EnableStandUp" /> </menu_item_call> + <context_menu + label="Take Off" + layout="topleft" + name="Take Off >"> + <context_menu + label="Clothes" + layout="topleft" + name="Clothes >"> + <menu_item_call + enabled="false" + label="Shirt" + layout="topleft" + name="Shirt"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="shirt" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="shirt" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Pants" + layout="topleft" + name="Pants"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="pants" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="pants" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Skirt" + layout="topleft" + name="Skirt"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="skirt" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="skirt" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Shoes" + layout="topleft" + name="Shoes"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="shoes" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="shoes" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Socks" + layout="topleft" + name="Socks"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="socks" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="socks" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Jacket" + layout="topleft" + name="Jacket"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="jacket" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="jacket" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Gloves" + layout="topleft" + name="Gloves"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="gloves" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="gloves" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Undershirt" + layout="topleft" + name="Self Undershirt"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="undershirt" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="undershirt" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Underpants" + layout="topleft" + name="Self Underpants"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="underpants" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="underpants" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Tattoo" + layout="topleft" + name="Self Tattoo"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="tattoo" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="tattoo" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Alpha" + layout="topleft" + name="Self Alpha"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="alpha" /> + <menu_item_call.on_enable + function="Edit.EnableTakeOff" + parameter="alpha" /> + </menu_item_call> + <menu_item_separator + layout="topleft" /> + <menu_item_call + label="All Clothes" + layout="topleft" + name="All Clothes"> + <menu_item_call.on_click + function="Edit.TakeOff" + parameter="all" /> + </menu_item_call> + </context_menu> + <context_menu + label="HUD" + layout="topleft" + name="Object Detach HUD" /> + <context_menu + label="Detach" + layout="topleft" + name="Object Detach" /> + <menu_item_call + label="Detach All" + layout="topleft" + name="Detach All"> + <menu_item_call.on_click + function="Self.RemoveAllAttachments" + parameter="" /> + <menu_item_call.on_enable + function="Self.EnableRemoveAllAttachments" /> + </menu_item_call> + </context_menu> <menu_item_call - label="Change Outfit" - name="change_outfit"> + label="Change Outfit" + layout="topleft" + name="Chenge Outfit"> <menu_item_call.on_click function="CustomizeAvatar" /> <menu_item_call.on_enable function="Edit.EnableCustomizeAvatar" /> </menu_item_call> - <menu_item_call - label="My Profile" - enabled="true" - name="my_profile"> + <menu_item_call label="Edit My Outfit" + layout="topleft" + name="Edit Outfit"> <menu_item_call.on_click - function="ShowAgentProfile" - parameter="agent" /> + function="EditOutfit" /> + <menu_item_call.on_enable + function="Edit.EnableCustomizeAvatar" /> + </menu_item_call> + <menu_item_call label="Edit My Shape" + layout="topleft" + name="Edit My Shape"> + <menu_item_call.on_click + function="EditShape" /> + <menu_item_call.on_enable + function="Edit.EnableEditShape" /> </menu_item_call> <menu_item_call - label="My Friends" - name="my_friends"> + label="My Friends" + layout="topleft" + name="Friends..."> <menu_item_call.on_click - function="SideTray.PanelPeopleTab" - parameter="friends_panel" /> + function="SideTray.PanelPeopleTab" + parameter="friends_panel" /> </menu_item_call> <menu_item_call label="My Groups" - name="my_groups"> + layout="topleft" + name="Groups..."> <menu_item_call.on_click function="SideTray.PanelPeopleTab" parameter="groups_panel" /> </menu_item_call> <menu_item_call - label="Debug Textures" - name="Debug..."> + label="My Profile" + layout="topleft" + name="Profile..."> + <menu_item_call.on_click + function="ShowAgentProfile" + parameter="agent" /> + </menu_item_call> + <menu_item_call + label="Debug Textures" + name="Debug..."> <menu_item_call.on_click function="Avatar.Debug" /> <menu_item_call.on_visible diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml index de13379099..f703acaa66 100644 --- a/indra/newview/skins/default/xui/en/notifications.xml +++ b/indra/newview/skins/default/xui/en/notifications.xml @@ -104,6 +104,7 @@ Your version of [APP_NAME] does not know how to display the notification it just received. Please verify that you have the latest Viewer installed. Error details: The notification called '[_NAME]' was not found in notifications.xml. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -116,6 +117,7 @@ Error details: The notification called '[_NAME]' was not found in noti Floater error: Could not find the following controls: [CONTROLS] + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -126,6 +128,7 @@ Floater error: Could not find the following controls: name="TutorialNotFound" type="alertmodal"> No tutorial is currently available. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -154,6 +157,7 @@ No tutorial is currently available. name="BadInstallation" type="alertmodal"> An error occurred while updating [APP_NAME]. Please [http://get.secondlife.com download the latest version] of the Viewer. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -163,8 +167,9 @@ No tutorial is currently available. icon="alertmodal.tga" name="LoginFailedNoNetwork" type="alertmodal"> -Could not connect to the [SECOND_LIFE_GRID]. -'[DIAGNOSTIC]' + <tag>fail</tag> + Could not connect to the [SECOND_LIFE_GRID]. + '[DIAGNOSTIC]' Make sure your Internet connection is working properly. <usetemplate name="okbutton" @@ -176,6 +181,7 @@ Make sure your Internet connection is working properly. name="MessageTemplateNotFound" type="alertmodal"> Message Template [PATH] not found. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -198,6 +204,7 @@ Save changes to current clothing/body part? name="CompileQueueSaveText" type="alertmodal"> There was a problem uploading the text for a script due to the following reason: [REASON]. Please try again later. + <tag>fail</tag> </notification> <notification @@ -205,6 +212,7 @@ There was a problem uploading the text for a script due to the following reason: name="CompileQueueSaveBytecode" type="alertmodal"> There was a problem uploading the compiled script due to the following reason: [REASON]. Please try again later. + <tag>fail</tag> </notification> <notification @@ -212,6 +220,7 @@ There was a problem uploading the compiled script due to the following reason: [ name="WriteAnimationFail" type="alertmodal"> There was a problem writing animation data. Please try again later. + <tag>fail</tag> </notification> <notification @@ -219,6 +228,7 @@ There was a problem writing animation data. Please try again later. name="UploadAuctionSnapshotFail" type="alertmodal"> There was a problem uploading the auction snapshot due to the following reason: [REASON] + <tag>fail</tag> </notification> <notification @@ -227,6 +237,7 @@ There was a problem uploading the auction snapshot due to the following reason: type="alertmodal"> Unable to view the contents of more than one item at a time. Please select only one object and try again. + <tag>fail</tag> </notification> <notification @@ -234,7 +245,8 @@ Please select only one object and try again. name="SaveClothingBodyChanges" type="alertmodal"> Save all changes to clothing/body parts? - <usetemplate +<tag>confirm</tag> +<usetemplate canceltext="Cancel" name="yesnocancelbuttons" notext="Don't Save" @@ -267,6 +279,7 @@ Save all changes to clothing/body parts? type="alertmodal"> Granting modify rights to another Resident allows them to change, delete or take ANY objects you may have in-world. Be VERY careful when handing out this permission. Do you want to grant modify rights for [NAME]? +<tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -279,6 +292,7 @@ Do you want to grant modify rights for [NAME]? type="alertmodal"> Granting modify rights to another Resident allows them to change ANY objects you may have in-world. Be VERY careful when handing out this permission. Do you want to grant modify rights for the selected Residents? +<tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -290,6 +304,7 @@ Do you want to grant modify rights for the selected Residents? name="RevokeModifyRights" type="alertmodal"> Do you want to revoke modify rights for [NAME]? +<tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -301,6 +316,7 @@ Do you want to revoke modify rights for [NAME]? name="RevokeModifyRightsMultiple" type="alertmodal"> Do you want to revoke modify rights for the selected Residents? +<tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -313,7 +329,9 @@ Do you want to revoke modify rights for the selected Residents? type="alertmodal"> Unable to create group. [MESSAGE] - <usetemplate + <tag>group</tag> + <tag>fail</tag> + <usetemplate name="okbutton" yestext="OK"/> </notification> @@ -324,7 +342,9 @@ Unable to create group. type="alertmodal"> [NEEDS_APPLY_MESSAGE] [WANT_APPLY_MESSAGE] - <usetemplate + <tag>confirm</tag> + <tag>group</tag> + <usetemplate canceltext="Cancel" name="yesnocancelbuttons" notext="Ignore Changes" @@ -336,7 +356,9 @@ Unable to create group. name="MustSpecifyGroupNoticeSubject" type="alertmodal"> You must specify a subject to send a group notice. - <usetemplate + <tag>group</tag> + <tag>fail</tag> + <usetemplate name="okbutton" yestext="OK"/> </notification> @@ -349,6 +371,8 @@ You are about to add group members to the role of [ROLE_NAME]. Members cannot be removed from that role. The members must resign from the role themselves. Are you sure you want to continue? + <tag>group</tag> + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I add a new group Owner" name="okcancelignore" @@ -394,6 +418,7 @@ Add this Ability to '[ROLE_NAME]'? type="alertmodal"> You are about to drop your attachment. Are you sure you want to continue? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before dropping attachments" name="okcancelignore" @@ -406,6 +431,9 @@ Add this Ability to '[ROLE_NAME]'? type="alertmodal"> Joining this group costs L$[COST]. Do you wish to proceed? + <tag>confirm</tag> + <tag>funds</tag> + <tag>group</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -418,6 +446,8 @@ Do you wish to proceed? type="alertmodal"> You are joining group [NAME]. Do you wish to proceed? + <tag>group</tag> + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -431,6 +461,9 @@ Do you wish to proceed? type="alertmodal"> Joining this group costs L$[COST]. You do not have enough L$ to join this group. + <tag>group</tag> + <tag>fail</tag> + <tag>funds</tag> </notification> <notification @@ -440,6 +473,8 @@ You do not have enough L$ to join this group. Creating this group will cost L$100. Groups need more than one member, or they are deleted forever. Please invite members within 48 hours. + <tag>group</tag> + <tag>funds</tag> <usetemplate canceltext="Cancel" name="okcancelbuttons" @@ -453,6 +488,8 @@ Please invite members within 48 hours. type="alertmodal"> <tag>fail</tag> For L$[COST] you can enter this land ('[PARCEL_NAME]') for [TIME] hours. Buy a pass? + <tag>funds</tag> + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -465,6 +502,7 @@ For L$[COST] you can enter this land ('[PARCEL_NAME]') for [TIME] hour type="alertmodal"> Sale price must be set to more than L$0 if selling to anyone. Please select an individual to sell to if selling for L$0. + <tag>fail</tag> </notification> <notification @@ -474,6 +512,7 @@ Please select an individual to sell to if selling for L$0. type="alertmodal"> The selected [LAND_SIZE] m² land is being set for sale. Your selling price will be L$[SALE_PRICE] and will be authorized for sale to [NAME]. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -488,6 +527,7 @@ ATTENTION: Clicking 'sell to anyone' makes your land available to the The selected [LAND_SIZE] m² land is being set for sale. Your selling price will be L$[SALE_PRICE] and will be authorized for sale to [NAME]. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -503,6 +543,8 @@ Are you sure you want to return all objects shared with the group '[NAME]&a *WARNING* This will delete the non-transferable objects deeded to the group! Objects: [N] + <tag>confirm</tag> + <tag>group</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -516,6 +558,7 @@ Objects: [N] Are you sure you want to return all objects owned by the Resident '[NAME]' on this parcel of land back to their inventory? Objects: [N] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -529,6 +572,7 @@ Objects: [N] Are you sure you want to return all objects owned by you on this parcel of land back to your inventory? Objects: [N] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -545,6 +589,7 @@ Transferable objects deeded to a group will be returned to their previous owners *WARNING* This will delete the non-transferable objects deeded to the group! Objects: [N] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -561,6 +606,7 @@ Transferable objects deeded to a group will be returned to their previous owners *WARNING* This will delete the non-transferable objects deeded to the group! Objects: [N] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -572,6 +618,7 @@ Objects: [N] name="ReturnAllTopObjects" type="alertmodal"> Are you sure you want to return all listed objects back to their owner's inventory? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -583,6 +630,7 @@ Are you sure you want to return all listed objects back to their owner's in name="DisableAllTopObjects" type="alertmodal"> Are you sure you want to disable all objects in this region? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -596,6 +644,8 @@ Are you sure you want to disable all objects in this region? Return the objects on this parcel of land that are NOT shared with the group [NAME] back to their owners? Objects: [N] + <tag>confirm</tag> + <tag>group</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -609,6 +659,7 @@ Objects: [N] Can not disable scripts. This entire region is damage enabled. Scripts must be allowed to run for weapons to work. + <tag>fail</tag> </notification> <notification @@ -618,6 +669,7 @@ Scripts must be allowed to run for weapons to work. Multiple faces are currently selected. If you continue this action, separate instances of media will be set on multiple faces of the object. To place the media on only one face, choose Select Face and click on the desired face of that object then click Add. + <tag>confirm</tag> <usetemplate ignoretext="Media will be set on multiple selected faces" name="okcancelignore" @@ -630,6 +682,7 @@ To place the media on only one face, choose Select Face and click on the desired name="MustBeInParcel" type="alertmodal"> You must be standing inside the land parcel to set its Landing Point. + <tag>fail</tag> </notification> <notification @@ -637,6 +690,7 @@ You must be standing inside the land parcel to set its Landing Point. name="PromptRecipientEmail" type="alertmodal"> Please enter a valid email address for the recipient(s). + <tag>fail</tag> </notification> <notification @@ -644,6 +698,7 @@ Please enter a valid email address for the recipient(s). name="PromptSelfEmail" type="alertmodal"> Please enter your email address. + <tag>fail</tag> </notification> <notification @@ -651,6 +706,7 @@ Please enter your email address. name="PromptMissingSubjMsg" type="alertmodal"> Email snapshot with the default subject or message? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -662,6 +718,7 @@ Email snapshot with the default subject or message? name="ErrorProcessingSnapshot" type="alertmodal"> Error processing snapshot data + <tag>fail</tag> </notification> <notification @@ -669,6 +726,7 @@ Error processing snapshot data name="ErrorEncodingSnapshot" type="alertmodal"> Error encoding snapshot. + <tag>fail</tag> </notification> <notification @@ -676,6 +734,7 @@ Error encoding snapshot. name="ErrorUploadingPostcard" type="alertmodal"> There was a problem sending a snapshot due to the following reason: [REASON] + <tag>fail</tag> </notification> <notification @@ -683,12 +742,14 @@ There was a problem sending a snapshot due to the following reason: [REASON] name="ErrorUploadingReportScreenshot" type="alertmodal"> There was a problem uploading a report screenshot due to the following reason: [REASON] + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" name="MustAgreeToLogIn" type="alertmodal"> + <tag>fail</tag> You must agree to the Terms of Service to continue logging into [SECOND_LIFE]. </notification> @@ -698,6 +759,7 @@ You must agree to the Terms of Service to continue logging into [SECOND_LIFE]. type="alertmodal"> Could not put on outfit. The outfit folder contains no clothing, body parts, or attachments. + <tag>fail</tag> </notification> <notification @@ -705,6 +767,7 @@ The outfit folder contains no clothing, body parts, or attachments. name="CannotWearTrash" type="alertmodal"> You can not wear clothes or body parts that are in the trash + <tag>fail</tag> </notification> <notification @@ -713,6 +776,7 @@ You can not wear clothes or body parts that are in the trash type="alertmodal"> Could not attach object. Exceeds the attachments limit of [MAX_ATTACHMENTS] objects. Please detach another object first. + <tag>fail</tag> </notification> <notification @@ -720,16 +784,19 @@ Exceeds the attachments limit of [MAX_ATTACHMENTS] objects. Please detach anothe name="CannotWearInfoNotComplete" type="alertmodal"> You can not wear that item because it has not yet loaded. Please try again in a minute. + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" name="MustHaveAccountToLogIn" type="alertmodal"> + <tag>fail</tag> Oops! Something was left blank. You need to enter the Username name of your avatar. You need an account to enter [SECOND_LIFE]. Would you like to create one now? + <tag>confirm</tag> <url option="0" name="url" @@ -747,6 +814,7 @@ You need an account to enter [SECOND_LIFE]. Would you like to create one now? icon="alertmodal.tga" name="InvalidCredentialFormat" type="alertmodal"> + <tag>fail</tag> You need to enter either the Username or both the First and Last name of your avatar into the Username field, then login again. </notification> @@ -759,6 +827,7 @@ Classified ads appear in the 'Classified' section of the Search direct Fill out your ad, then click 'Publish...' to add it to the directory. You'll be asked for a price to pay when clicking Publish. Paying more makes your ad appear higher in the list, and also appear higher when people search for keywords. + <tag>confirm</tag> <usetemplate ignoretext="How to create a new Classified ad" name="okcancelignore" @@ -772,6 +841,7 @@ Paying more makes your ad appear higher in the list, and also appear higher when type="alertmodal"> Delete classified '[NAME]'? There is no reimbursement for fees paid. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -785,6 +855,7 @@ There is no reimbursement for fees paid. type="alertmodal"> You have selected to delete the media associated with this face. Are you sure you want to continue? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I delete media from an object" name="okcancelignore" @@ -797,6 +868,7 @@ Are you sure you want to continue? name="ClassifiedSave" type="alertmodal"> Save changes to classified [NAME]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -809,6 +881,7 @@ Save changes to classified [NAME]? name="ClassifiedInsufficientFunds" type="alertmodal"> Insufficient funds to create classified. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -819,6 +892,7 @@ Insufficient funds to create classified. name="DeleteAvatarPick" type="alertmodal"> Delete pick <nolink>[PICK]</nolink>? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -830,6 +904,7 @@ Delete pick <nolink>[PICK]</nolink>? name="DeleteOutfits" type="alertmodal"> Delete the selected outfit? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -841,6 +916,7 @@ Delete pick <nolink>[PICK]</nolink>? name="PromptGoToEventsPage" type="alertmodal"> Go to the [SECOND_LIFE] events web page? + <tag>confirm</tag> <url option="0" name="url"> http://secondlife.com/events/ @@ -856,6 +932,7 @@ Go to the [SECOND_LIFE] events web page? name="SelectProposalToView" type="alertmodal"> Please select a proposal to view. + <tag>fail</tag> </notification> <notification @@ -863,6 +940,7 @@ Please select a proposal to view. name="SelectHistoryItemToView" type="alertmodal"> Please select a history item to view. + <tag>fail</tag> </notification> <!-- @@ -929,9 +1007,9 @@ Changing language will take effect after you restart [APP_NAME]. icon="alertmodal.tga" name="GoToAuctionPage" type="alertmodal"> -Go to the [SECOND_LIFE] web page to see auction details or make a bid? + Go to the [SECOND_LIFE] web page to see auction details or make a bid? + <tag>confirm</tag> <url option="0" name="url"> - http://secondlife.com/auctions/auction-detail.php?id=[AUCTION_ID] </url> <usetemplate @@ -945,6 +1023,7 @@ Go to the [SECOND_LIFE] web page to see auction details or make a bid? name="SaveChanges" type="alertmodal"> Save Changes? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -959,6 +1038,7 @@ Save Changes? Gesture save failed. This gesture has too many steps. Try removing some steps, then save again. +<tag>fail</tag> </notification> <notification @@ -966,6 +1046,7 @@ Try removing some steps, then save again. name="GestureSaveFailedTryAgain" type="alertmodal"> Gesture save failed. Please try again in a minute. +<tag>fail</tag> </notification> <notification @@ -974,6 +1055,7 @@ Gesture save failed. Please try again in a minute. type="alertmodal"> Could not save gesture because the object or the associated object inventory could not be found. The object may be out of range or may have been deleted. +<tag>fail</tag> </notification> <notification @@ -981,6 +1063,7 @@ The object may be out of range or may have been deleted. name="GestureSaveFailedReason" type="alertmodal"> There was a problem saving a gesture due to the following reason: [REASON]. Please try resaving the gesture later. +<tag>fail</tag> </notification> <notification @@ -989,6 +1072,7 @@ There was a problem saving a gesture due to the following reason: [REASON]. Ple type="alertmodal"> Could not save notecard because the object or the associated object inventory could not be found. The object may be out of range or may have been deleted. +<tag>fail</tag> </notification> <notification @@ -996,6 +1080,7 @@ The object may be out of range or may have been deleted. name="SaveNotecardFailReason" type="alertmodal"> There was a problem saving a notecard due to the following reason: [REASON]. Please try re-saving the notecard later. +<tag>fail</tag> </notification> <notification @@ -1005,6 +1090,7 @@ There was a problem saving a notecard due to the following reason: [REASON]. Pl Could not undo all changes in your version of the script. Would you like to load the server's last saved version? (**Warning** This operation cannot be undone.) + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1016,6 +1102,7 @@ Would you like to load the server's last saved version? name="SaveScriptFailReason" type="alertmodal"> There was a problem saving a script due to the following reason: [REASON]. Please try re-saving the script later. +<tag>fail</tag> </notification> <notification @@ -1024,6 +1111,7 @@ There was a problem saving a script due to the following reason: [REASON]. Plea type="alertmodal"> Could not save the script because the object it is in could not be found. The object may be out of range or may have been deleted. +<tag>fail</tag> </notification> <notification @@ -1031,6 +1119,7 @@ The object may be out of range or may have been deleted. name="SaveBytecodeFailReason" type="alertmodal"> There was a problem saving a compiled script due to the following reason: [REASON]. Please try re-saving the script later. +<tag>fail</tag> </notification> <notification @@ -1039,6 +1128,7 @@ There was a problem saving a compiled script due to the following reason: [REASO type="alertmodal"> Oops, Your Start Region is not defined. Please type the Region name in Start Location box or choose My Last Location or My Home as your Start Location. +<tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -1050,6 +1140,7 @@ Please type the Region name in Start Location box or choose My Last Location or type="alertmodal"> Could not start or stop the script because the object it is on could not be found. The object may be out of range or may have been deleted. + <tag>fail</tag> </notification> <notification @@ -1057,6 +1148,7 @@ The object may be out of range or may have been deleted. name="CannotDownloadFile" type="alertmodal"> Unable to download file + <tag>fail</tag> </notification> <notification @@ -1064,6 +1156,7 @@ Unable to download file name="CannotWriteFile" type="alertmodal"> Unable to write file [[FILE]] + <tag>fail</tag> </notification> <notification @@ -1073,6 +1166,7 @@ Unable to write file [[FILE]] Just so you know, your computer does not meet [APP_NAME]'s minimum system requirements. You may experience poor performance. Unfortunately, the [SUPPORT_SITE] can't provide technical support for unsupported system configurations. Visit [_URL] for more information? + <tag>confirm</tag> <url option="0" name="url"> http://www.secondlife.com/corporate/sysreqs.php @@ -1082,6 +1176,7 @@ Visit [_URL] for more information? name="okcancelignore" notext="No" yestext="Yes"/> + <tag>fail</tag> </notification> <notification @@ -1095,6 +1190,7 @@ This is often the case with new hardware that hasn't been tested yet with [ <ignore name="ignore" text="My graphics card could not be identified"/> </form> + <tag>fail</tag> </notification> <notification @@ -1105,6 +1201,7 @@ This is often the case with new hardware that hasn't been tested yet with [ Graphics Quality will be set to Low to avoid some common driver errors. This will disable some graphics features. We recommend updating your graphics card drivers. Graphics Quality can be raised in Preferences > Graphics. + <tag>fail</tag> </notification> <notification @@ -1112,6 +1209,7 @@ Graphics Quality can be raised in Preferences > Graphics. name="RegionNoTerraforming" type="alertmodal"> The region [REGION] does not allow terraforming. + <tag>fail</tag> </notification> <notification @@ -1121,10 +1219,12 @@ The region [REGION] does not allow terraforming. You do not have permission to copy the following items: [ITEMS] and will lose it from your inventory if you give it away. Do you really want to offer these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" yestext="Yes"/> + <tag>fail</tag> </notification> <notification @@ -1132,6 +1232,7 @@ and will lose it from your inventory if you give it away. Do you really want to name="CannotGiveItem" type="alertmodal"> Unable to give inventory item. + <tag>fail</tag> </notification> <notification @@ -1146,6 +1247,7 @@ Transaction cancelled. name="TooManyItems" type="alertmodal"> Cannot give more than 42 items in a single inventory transfer. + <tag>fail</tag> </notification> <notification @@ -1153,6 +1255,7 @@ Cannot give more than 42 items in a single inventory transfer. name="NoItems" type="alertmodal"> You do not have permission to transfer the selected items. + <tag>fail</tag> </notification> <notification @@ -1161,6 +1264,8 @@ You do not have permission to transfer the selected items. type="alertmodal"> You do not have permission to copy [COUNT] of the selected items. You will lose these items from your inventory. Do you really want to give these items? + <tag>confirm</tag> + <tag>fail</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -1172,6 +1277,7 @@ Do you really want to give these items? name="CannotGiveCategory" type="alertmodal"> You do not have permission to transfer the selected folder. + <tag>fail</tag> </notification> <notification @@ -1180,6 +1286,7 @@ You do not have permission to transfer the selected folder. type="alertmodal"> Freeze this avatar? He or she will temporarily be unable to move, chat, or interact with the world. + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -1193,6 +1300,7 @@ He or she will temporarily be unable to move, chat, or interact with the world. type="alertmodal"> Freeze [AVATAR_NAME]? He or she will temporarily be unable to move, chat, or interact with the world. + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -1205,6 +1313,7 @@ He or she will temporarily be unable to move, chat, or interact with the world. name="EjectAvatarFullname" type="alertmodal"> Eject [AVATAR_NAME] from your land? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -1217,6 +1326,7 @@ Eject [AVATAR_NAME] from your land? name="EjectAvatarNoBan" type="alertmodal"> Eject this avatar from your land? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1228,6 +1338,7 @@ Eject this avatar from your land? name="EjectAvatarFullnameNoBan" type="alertmodal"> Eject [AVATAR_NAME] from your land? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1240,6 +1351,7 @@ Eject [AVATAR_NAME] from your land? persist="true" type="notify"> You ejected [AVATAR_NAME] from group [GROUP_NAME] + <tag>group</tag> </notification> <notification @@ -1247,6 +1359,7 @@ You ejected [AVATAR_NAME] from group [GROUP_NAME] name="AcquireErrorTooManyObjects" type="alertmodal"> ACQUIRE ERROR: Too many objects selected. + <tag>fail</tag> </notification> <notification @@ -1255,6 +1368,7 @@ ACQUIRE ERROR: Too many objects selected. type="alertmodal"> ACQUIRE ERROR: Objects span more than one region. Please move all objects to be acquired onto the same region. + <tag>fail</tag> </notification> <notification @@ -1264,6 +1378,7 @@ Please move all objects to be acquired onto the same region. [EXTRA] Go to [_URL] for information on purchasing L$? + <tag>confirm</tag> <url option="0" name="url"> http://secondlife.com/app/currency/ @@ -1280,6 +1395,7 @@ Go to [_URL] for information on purchasing L$? type="alertmodal"> Unable to link these [COUNT] objects. You can link a maximum of [MAX] objects. + <tag>fail</tag> </notification> <notification @@ -1287,6 +1403,7 @@ You can link a maximum of [MAX] objects. name="CannotLinkIncompleteSet" type="alertmodal"> You can only link complete sets of objects, and must select more than one object. + <tag>fail</tag> </notification> <notification @@ -1296,6 +1413,7 @@ You can only link complete sets of objects, and must select more than one object Unable to link because you don't have modify permission on all the objects. Please make sure none are locked, and that you own all of them. + <tag>fail</tag> </notification> <notification @@ -1305,6 +1423,7 @@ Please make sure none are locked, and that you own all of them. Unable to link because not all of the objects have the same owner. Please make sure you own all of the selected objects. + <tag>fail</tag> </notification> <notification @@ -1314,6 +1433,7 @@ Please make sure you own all of the selected objects. No file extension for the file: '[FILE]' Please make sure the file has a correct file extension. + <tag>fail</tag> </notification> <notification @@ -1325,6 +1445,7 @@ Expected [VALIDS] <usetemplate name="okbutton" yestext="OK"/> + <tag>fail</tag> </notification> <notification @@ -1333,6 +1454,7 @@ Expected [VALIDS] type="alertmodal"> Couldn't open uploaded sound file for reading: [FILE] + <tag>fail</tag> </notification> <notification @@ -1341,6 +1463,7 @@ Couldn't open uploaded sound file for reading: type="alertmodal"> File does not appear to be a RIFF WAVE file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1349,6 +1472,7 @@ File does not appear to be a RIFF WAVE file: type="alertmodal"> File does not appear to be a PCM WAVE audio file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1357,6 +1481,7 @@ File does not appear to be a PCM WAVE audio file: type="alertmodal"> File has invalid number of channels (must be mono or stereo): [FILE] + <tag>fail</tag> </notification> <notification @@ -1365,6 +1490,7 @@ File has invalid number of channels (must be mono or stereo): type="alertmodal"> File does not appear to be a supported sample rate (must be 44.1k): [FILE] + <tag>fail</tag> </notification> <notification @@ -1373,6 +1499,7 @@ File does not appear to be a supported sample rate (must be 44.1k): type="alertmodal"> File does not appear to be a supported word size (must be 8 or 16 bit): [FILE] + <tag>fail</tag> </notification> <notification @@ -1381,6 +1508,7 @@ File does not appear to be a supported word size (must be 8 or 16 bit): type="alertmodal"> Could not find 'data' chunk in WAV header: [FILE] + <tag>fail</tag> </notification> <notification @@ -1389,6 +1517,7 @@ Could not find 'data' chunk in WAV header: type="alertmodal"> Wrong chunk size in WAV file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1397,6 +1526,7 @@ Wrong chunk size in WAV file: type="alertmodal"> Audio file is too long (10 second maximum): [FILE] + <tag>fail</tag> </notification> <notification @@ -1406,6 +1536,7 @@ Audio file is too long (10 second maximum): Problem with file [FILE]: [ERROR] + <tag>fail</tag> </notification> <notification @@ -1413,6 +1544,7 @@ Problem with file [FILE]: name="CannotOpenTemporarySoundFile" type="alertmodal"> Couldn't open temporary compressed sound file for writing: [FILE] + <tag>fail</tag> </notification> <notification @@ -1420,6 +1552,7 @@ Couldn't open temporary compressed sound file for writing: [FILE] name="UnknownVorbisEncodeFailure" type="alertmodal"> Unknown Vorbis encode failure on: [FILE] + <tag>fail</tag> </notification> <notification @@ -1427,6 +1560,7 @@ Unknown Vorbis encode failure on: [FILE] name="CannotEncodeFile" type="alertmodal"> Unable to encode file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1435,6 +1569,7 @@ Unable to encode file: [FILE] type="alertmodal"> We can't fill in your username and password. This may happen when you change network setup + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -1445,6 +1580,7 @@ Unable to encode file: [FILE] name="CorruptResourceFile" type="alertmodal"> Corrupt resource file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1452,6 +1588,7 @@ Corrupt resource file: [FILE] name="UnknownResourceFileVersion" type="alertmodal"> Unknown Linden resource file version in file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1459,6 +1596,7 @@ Unknown Linden resource file version in file: [FILE] name="UnableToCreateOutputFile" type="alertmodal"> Unable to create output file: [FILE] + <tag>fail</tag> </notification> <notification @@ -1466,6 +1604,7 @@ Unable to create output file: [FILE] name="DoNotSupportBulkAnimationUpload" type="alertmodal"> [APP_NAME] does not currently support bulk upload of animation files. + <tag>fail</tag> </notification> <notification @@ -1474,6 +1613,7 @@ Unable to create output file: [FILE] type="alertmodal"> Unable to upload [FILE] due to the following reason: [REASON] Please try again later. + <tag>fail</tag> </notification> <notification @@ -1491,6 +1631,7 @@ You already have a landmark for this location. <usetemplate name="okbutton" yestext="OK"/> + <tag>fail</tag> </notification> <notification @@ -1498,6 +1639,7 @@ You already have a landmark for this location. name="CannotCreateLandmarkNotOwner" type="alertmodal"> You cannot create a landmark here because the owner of the land doesn't allow it. + <tag>fail</tag> </notification> <notification @@ -1506,6 +1648,7 @@ You cannot create a landmark here because the owner of the land doesn't all type="alertmodal"> Not able to perform 'recompilation'. Select an object with a script. + <tag>fail</tag> </notification> <notification @@ -1515,6 +1658,7 @@ Select an object with a script. Not able to perform 'recompilation'. Select objects with scripts that you have permission to modify. + <tag>fail</tag> </notification> <notification @@ -1524,6 +1668,7 @@ Select objects with scripts that you have permission to modify. Not able to perform 'reset'. Select objects with scripts. + <tag>fail</tag> </notification> <notification @@ -1533,6 +1678,7 @@ Select objects with scripts. Not able to perform 'reset'. Select objects with scripts that you have permission to modify. + <tag>fail</tag> </notification> <notification @@ -1540,6 +1686,7 @@ Select objects with scripts that you have permission to modify. name="CannotOpenScriptObjectNoMod" type="alertmodal"> Unable to open script in object without modify permissions. + <tag>fail</tag> </notification> <notification @@ -1549,6 +1696,7 @@ Select objects with scripts that you have permission to modify. Not able to set any scripts to 'running'. Select objects with scripts. + <tag>fail</tag> </notification> <notification @@ -1558,6 +1706,7 @@ Select objects with scripts. Unable to set any scripts to 'not running'. Select objects with scripts. + <tag>fail</tag> </notification> <notification @@ -1565,6 +1714,7 @@ Select objects with scripts. name="NoFrontmostFloater" type="alertmodal"> No frontmost floater to save. + <tag>fail</tag> </notification> <notification @@ -1581,6 +1731,7 @@ Searched for: [FINALQUERY] name="SeachFilteredOnShortWordsEmpty" type="alertmodal"> Your search terms were too short so no search was performed. + <tag>fail</tag> </notification> <!-- Generic Teleport failure modes - strings will be inserted from @@ -1591,6 +1742,7 @@ Your search terms were too short so no search was performed. type="alertmodal"> Teleport failed. [REASON] + <tag>fail</tag> </notification> <!-- Teleport failure modes not delivered via the generic mechanism @@ -1603,6 +1755,7 @@ Teleport failed. type="alertmodal"> Problem encountered processing your teleport request. You may need to log back in before you can teleport. If you continue to get this message, please check the [SUPPORT_SITE]. + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" @@ -1610,19 +1763,21 @@ If you continue to get this message, please check the [SUPPORT_SITE]. type="alertmodal"> Problem encountered processing your region crossing. You may need to log back in before you can cross regions. If you continue to get this message, please check the [SUPPORT_SITE]. + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" name="blocked_tport" type="alertmodal"> - <tag>fail</tag> Sorry, teleport is currently blocked. Try again in a moment. If you still cannot teleport, please log out and log back in to resolve the problem. + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" name="nolandmark_tport" type="alertmodal"> Sorry, but system was unable to locate landmark destination. + <tag>fail</tag> </notification> <notification icon="alertmodal.tga" @@ -1678,6 +1833,7 @@ Unable to find teleport destination. The destination may be temporarily unavaila name="no_inventory_host" type="alertmodal"> The inventory system is currently unavailable. + <tag>fail</tag> </notification> <notification @@ -1686,6 +1842,7 @@ The inventory system is currently unavailable. type="alertmodal"> Unable to set land owner: No parcel selected. + <tag>fail</tag> </notification> <notification @@ -1693,6 +1850,7 @@ No parcel selected. name="CannotSetLandOwnerMultipleRegions" type="alertmodal"> Unable to force land ownership because selection spans multiple regions. Please select a smaller area and try again. + <tag>fail</tag> </notification> <notification @@ -1701,6 +1859,7 @@ Unable to force land ownership because selection spans multiple regions. Please type="alertmodal"> This parcel is up for auction. Forcing ownership will cancel the auction and potentially make some Residents unhappy if bidding has begun. Force ownership? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1713,6 +1872,7 @@ Force ownership? type="alertmodal"> Unable to contentify: No parcel selected. + <tag>fail</tag> </notification> <notification @@ -1721,6 +1881,7 @@ No parcel selected. type="alertmodal"> Unable to contentify: No region selected. + <tag>fail</tag> </notification> <notification @@ -1729,6 +1890,7 @@ No region selected. type="alertmodal"> Unable to abandon land: No parcel selected. + <tag>fail</tag> </notification> <notification @@ -1737,6 +1899,7 @@ No parcel selected. type="alertmodal"> Unable to abandon land: Cannot find region. + <tag>fail</tag> </notification> <notification @@ -1745,6 +1908,7 @@ Cannot find region. type="alertmodal"> Unable to buy land: No parcel selected. + <tag>fail</tag> </notification> <notification @@ -1753,6 +1917,7 @@ No parcel selected. type="alertmodal"> Unable to buy land: Cannot find the region this land is in. + <tag>fail</tag> </notification> <notification @@ -1760,6 +1925,7 @@ Cannot find the region this land is in. name="CannotCloseFloaterBuyLand" type="alertmodal"> You cannot close the Buy Land window until [APP_NAME] estimates the price of this transaction. + <tag>fail</tag> </notification> <notification @@ -1768,6 +1934,7 @@ You cannot close the Buy Land window until [APP_NAME] estimates the price of thi type="alertmodal"> Unable to deed land: No parcel selected. + <tag>fail</tag> </notification> <notification @@ -1776,6 +1943,8 @@ No parcel selected. type="alertmodal"> Unable to deed land: No Group selected. + <tag>group</tag> + <tag>fail</tag> </notification> <notification @@ -1784,6 +1953,7 @@ No Group selected. type="alertmodal"> Unable to deed land: Cannot find the region this land is in. + <tag>fail</tag> </notification> <notification @@ -1794,6 +1964,7 @@ Unable to deed land: Multiple parcels selected. Try selecting a single parcel. + <tag>fail</tag> </notification> <notification @@ -1804,6 +1975,7 @@ Unable to deed land: Waiting for server to report ownership. Please try again. + <tag>fail</tag> </notification> <notification @@ -1812,6 +1984,7 @@ Please try again. type="alertmodal"> Unable to deed land: The region [REGION] does not allow transfer of land. + <tag>fail</tag> </notification> <notification @@ -1822,6 +1995,7 @@ Unable to abandon land: Waiting for server to update parcel information. Try again in a few seconds. + <tag>fail</tag> </notification> <notification @@ -1832,6 +2006,7 @@ Unable to abandon land: You do not own all the parcels selected. Please select a single parcel. + <tag>fail</tag> </notification> <notification @@ -1841,6 +2016,7 @@ Please select a single parcel. Unable to abandon land: You don't have permission to release this parcel. Parcels you own appear in green. + <tag>fail</tag> </notification> <notification @@ -1849,6 +2025,7 @@ Parcels you own appear in green. type="alertmodal"> Unable to abandon land: Cannot find the region this land is in. + <tag>fail</tag> </notification> <notification @@ -1857,6 +2034,7 @@ Cannot find the region this land is in. type="alertmodal"> Unable to abandon land: The region [REGION] does not allow transfer of land. + <tag>fail</tag> </notification> <notification @@ -1867,6 +2045,7 @@ Unable to abandon land: You must select an entire parcel to release it. Select an entire parcel, or divide your parcel first. + <tag>fail</tag> </notification> <notification @@ -1877,6 +2056,7 @@ You are about to release [AREA] m² of land. Releasing this parcel will remove it from your land holdings, but will not grant any L$. Release this land? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1890,6 +2070,7 @@ Release this land? Unable to divide land: No parcels selected. + <tag>fail</tag> </notification> <notification @@ -1900,6 +2081,7 @@ Unable to divide land: You have an entire parcel selected. Try selecting a part of the parcel. + <tag>fail</tag> </notification> <notification @@ -1909,6 +2091,7 @@ Try selecting a part of the parcel. Dividing this land will split this parcel into two and each parcel can have its own settings. Some settings will be reset to defaults after the operation. Divide land? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1921,6 +2104,7 @@ Divide land? type="alertmodal"> Unable to divide land: Cannot find the region this land is in. + <tag>fail</tag> </notification> <notification @@ -1929,6 +2113,7 @@ Cannot find the region this land is in. type="alertmodal"> Unable to join land: Cannot find the region this land is in. + <tag>fail</tag> </notification> <notification @@ -1937,6 +2122,7 @@ Cannot find the region this land is in. type="alertmodal"> Unable to join land: No parcels selected. + <tag>fail</tag> </notification> <notification @@ -1947,6 +2133,7 @@ Unable to join land: You only have one parcel selected. Select land across both parcels. + <tag>fail</tag> </notification> <notification @@ -1957,6 +2144,7 @@ Unable to join land: You must select more than one parcel. Select land across both parcels. + <tag>fail</tag> </notification> <notification @@ -1967,6 +2155,7 @@ Joining this land will create one large parcel out of all parcels intersecting t You will need to reset the name and options of the new parcel. Join land? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1978,6 +2167,7 @@ Join land? name="ConfirmNotecardSave" type="alertmodal"> This notecard needs to be saved before the item can be copied or viewed. Save notecard? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -1989,6 +2179,7 @@ This notecard needs to be saved before the item can be copied or viewed. Save no name="ConfirmItemCopy" type="alertmodal"> Copy this item to your inventory? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2000,6 +2191,7 @@ Copy this item to your inventory? name="ResolutionSwitchFail" type="alertmodal"> Failed to switch resolution to [RESX] by [RESY] + <tag>fail</tag> </notification> <notification @@ -2007,6 +2199,7 @@ Failed to switch resolution to [RESX] by [RESY] name="ErrorUndefinedGrasses" type="alertmodal"> Error: Undefined grasses: [SPECIES] + <tag>fail</tag> </notification> <notification @@ -2014,6 +2207,7 @@ Error: Undefined grasses: [SPECIES] name="ErrorUndefinedTrees" type="alertmodal"> Error: Undefined trees: [SPECIES] + <tag>fail</tag> </notification> <notification @@ -2021,6 +2215,7 @@ Error: Undefined trees: [SPECIES] name="CannotSaveWearableOutOfSpace" type="alertmodal"> Unable to save '[NAME]' to wearable file. You will need to free up some space on your computer and save the wearable again. + <tag>fail</tag> </notification> <notification @@ -2029,6 +2224,7 @@ Unable to save '[NAME]' to wearable file. You will need to free up so type="alertmodal"> Unable to save [NAME] to central asset store. This is usually a temporary failure. Please customize and save the wearable again in a few minutes. + <tag>fail</tag> </notification> <notification @@ -2049,6 +2245,8 @@ Darn. You have been logged out of [SECOND_LIFE] type="alertmodal"> Unable to buy land for the group: You do not have permission to buy land for your active group. + <tag>group</tag> + <tag>fail</tag> </notification> <notification @@ -2056,9 +2254,11 @@ You do not have permission to buy land for your active group. label="Add Friend" name="AddFriendWithMessage" type="alertmodal"> + <tag>friendship</tag> Friends can give permissions to track each other on the map and receive online status updates. Offer friendship to [NAME]? + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> Would you be my friend? @@ -2082,6 +2282,7 @@ Would you be my friend? type="alertmodal" unique="true"> Save what I'm wearing as a new Outfit: + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> [DESC] (new) @@ -2104,6 +2305,7 @@ Would you be my friend? name="SaveWearableAs" type="alertmodal"> Save item to my inventory as: + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> [DESC] (new) @@ -2127,6 +2329,7 @@ Would you be my friend? name="RenameOutfit" type="alertmodal"> New outfit name: + <tag>confirm</tag> <form name="form"> <input name="new_name" type="text" width="300"> [NAME] @@ -2147,7 +2350,9 @@ Would you be my friend? icon="alertmodal.tga" name="RemoveFromFriends" type="alertmodal"> + <tag>friendship</tag> Do you want to remove [NAME] from your Friends List? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2158,7 +2363,9 @@ Do you want to remove [NAME] from your Friends List? icon="alertmodal.tga" name="RemoveMultipleFromFriends" type="alertmodal"> + <tag>friendship</tag> Do you want to remove multiple friends from your Friends list? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2172,6 +2379,7 @@ Do you want to remove multiple friends from your Friends list? Are you sure you want to delete all scripted objects owned by ** [AVATAR_NAME] ** on all others land in this sim? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2185,6 +2393,7 @@ on all others land in this sim? Are you sure you want to DELETE ALL scripted objects owned by ** [AVATAR_NAME] ** on ALL LAND in this sim? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2198,6 +2407,7 @@ on ALL LAND in this sim? Are you sure you want to DELETE ALL objects (scripted or not) owned by ** [AVATAR_NAME] ** on ALL LAND in this sim? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2209,6 +2419,7 @@ on ALL LAND in this sim? name="BlankClassifiedName" type="alertmodal"> You must specify a name for your classified. + <tag>fail</tag> </notification> <notification @@ -2218,6 +2429,7 @@ You must specify a name for your classified. Price to pay for listing must be at least L$[MIN_PRICE]. Please enter a higher price. + <tag>fail</tag> </notification> <notification @@ -2227,6 +2439,7 @@ Please enter a higher price. At least one of the items you has link items that point to it. If you delete this item, its links will permanently stop working. It is strongly advised to delete the links first. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2240,6 +2453,7 @@ Are you sure you want to delete these items? At least one of the items you have selected is locked. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2253,6 +2467,7 @@ Are you sure you want to delete these items? At least one of the items you have selected is not copyable. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2266,6 +2481,7 @@ Are you sure you want to delete these items? You do not own least one of the items you have selected. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2280,6 +2496,7 @@ At least one object is locked. At least one object is not copyable. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2294,6 +2511,7 @@ At least one object is locked. You do not own least one object. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2308,6 +2526,7 @@ At least one object is not copyable. You do not own least one object. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2323,6 +2542,7 @@ At least one object is not copyable. You do not own least one object. Are you sure you want to delete these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="cancel" @@ -2336,6 +2556,7 @@ Are you sure you want to delete these items? At least one object is locked. Are you sure you want to take these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2350,6 +2571,7 @@ You do not own all of the objects you are taking. If you continue, next owner permissions will be applied and possibly restrict your ability to modify or copy them. Are you sure you want to take these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2366,6 +2588,7 @@ If you continue, next owner permissions will be applied and possibly restrict yo However, you can take the current selection. Are you sure you want to take these items? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2379,6 +2602,7 @@ Are you sure you want to take these items? Unable to buy land because selection spans multiple regions. Please select a smaller area and try again. + <tag>fail</tag> </notification> <notification @@ -2389,6 +2613,8 @@ By deeding this parcel, the group will be required to have and maintain sufficie The purchase price of the land is not refunded to the owner. If a deeded parcel is sold, the sale price will be divided evenly among group members. Deed this [AREA] m² of land to the group '[GROUP_NAME]'? + <tag>group</tag> + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2404,6 +2630,8 @@ The deed will include a simultaneous land contribution to the group from '[ The purchase price of the land is not refunded to the owner. If a deeded parcel is sold, the sale price will be divided evenly among group members. Deed this [AREA] m² of land to the group '[GROUP_NAME]'? + <tag>group</tag> + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2429,6 +2657,7 @@ Display settings have been set to recommended levels based on your system config name="ErrorMessage" type="alertmodal"> [ERROR_MESSAGE] + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -2484,6 +2713,7 @@ You can use [SECOND_LIFE] normally and other people will see you correctly. If this is your first time using [SECOND_LIFE], you will need to create an account before you can log in. Return to [http://join.secondlife.com secondlife.com] to create a new account? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2537,6 +2767,7 @@ Please choose the male or female avatar. You can change your mind later. name="CantTeleportToGrid" type="alertmodal"> Could not teleport to [SLURL] as it's on a different grid ([GRID]) than the current grid ([CURRENT_GRID]). Please close your viewer and try again. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -2557,6 +2788,7 @@ SHA1 Fingerprint: [MD5_DIGEST] Key Usage: [KEYUSAGE] Extended Key Usage: [EXTENDEDKEYUSAGE] Subject Key Identifier: [SUBJECTKEYIDENTIFIER] + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -2579,6 +2811,7 @@ Extended Key Usage: [EXTENDEDKEYUSAGE] Subject Key Identifier: [SUBJECTKEYIDENTIFIER] Would you like to trust this authority? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2590,6 +2823,8 @@ Would you like to trust this authority? name="NotEnoughCurrency" type="alertmodal"> [NAME] L$ [PRICE] You don't have enough L$ to do that. + <tag>fail</tag> + <tag>funds</tag> </notification> <notification @@ -2626,6 +2861,7 @@ This is really only useful for debugging. name="BuyOneObjectOnly" type="alertmodal"> Unable to buy more than one object at a time. Please select only one object and try again. + <tag>fail</tag> </notification> <notification @@ -2634,6 +2870,7 @@ Unable to buy more than one object at a time. Please select only one object and type="alertmodal"> Unable to copy the contents of more than one item at a time. Please select only one object and try again. + <tag>fail</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2645,6 +2882,7 @@ Please select only one object and try again. name="KickUsersFromRegion" type="alertmodal"> Teleport all Residents in this region home? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2656,6 +2894,7 @@ Teleport all Residents in this region home? name="EstateObjectReturn" type="alertmodal"> Are you sure you want to return objects owned by [USER_NAME]? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2670,6 +2909,7 @@ Couldn't set region textures: Terrain texture [TEXTURE_NUM] has an invalid bit depth of [TEXTURE_BIT_DEPTH]. Replace texture [TEXTURE_NUM] with a 24-bit 512x512 or smaller image then click "Apply" again. + <tag>fail</tag> </notification> <notification @@ -2694,6 +2934,7 @@ Upload started. It may take up to two minutes, depending on your connection spee name="ConfirmBakeTerrain" type="alertmodal"> Do you really want to bake the current terrain, make it the center for terrain raise/lower limits and the default for the 'Revert' tool? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2727,6 +2968,7 @@ Exceeds the [MAX_AGENTS] [LIST_TYPE] limit by [NUM_EXCESS]. name="MaxAllowedGroupsOnRegion" type="alertmodal"> You can only have [MAX_GROUPS] Allowed Groups. + <tag>group</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -2784,6 +3026,7 @@ Finished download of raw terrain file to: A new version of [APP_NAME] is available. [MESSAGE] You must download this update to use [APP_NAME]. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Quit" @@ -2797,6 +3040,7 @@ You must download this update to use [APP_NAME]. An updated version of [APP_NAME] is available. [MESSAGE] This update is not required, but we suggest you install it to improve performance and stability. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2810,6 +3054,7 @@ This update is not required, but we suggest you install it to improve performanc An updated version of [APP_NAME] is available. [MESSAGE] This update is not required, but we suggest you install it to improve performance and stability. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2823,6 +3068,7 @@ This update is not required, but we suggest you install it to improve performanc A new version of [APP_NAME] is available. [MESSAGE] You must download this update to use [APP_NAME]. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Quit" @@ -2836,6 +3082,7 @@ You must download this update to use [APP_NAME]. An updated version of [APP_NAME] is available. [MESSAGE] This update is not required, but we suggest you install it to improve performance and stability. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2849,6 +3096,7 @@ This update is not required, but we suggest you install it to improve performanc An updated version of [APP_NAME] is available. [MESSAGE] This update is not required, but we suggest you install it to improve performance and stability. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2864,6 +3112,7 @@ A new version of [APP_NAME] is available. You must download this update to use [APP_NAME]. Download to your Applications folder? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Quit" @@ -2879,6 +3128,7 @@ An updated version of [APP_NAME] is available. This update is not required, but we suggest you install it to improve performance and stability. Download to your Applications folder? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2894,6 +3144,7 @@ An updated version of [APP_NAME] is available. This update is not required, but we suggest you install it to improve performance and stability. Download to your Applications folder? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Continue" @@ -2921,6 +3172,7 @@ You will be unable to log in until [APP_NAME] has been updated. Please download and install the latest viewer from http://secondlife.com/download. + <tag>fail</tag> <usetemplate name="okbutton" yestext="Quit"/> @@ -2934,6 +3186,7 @@ There is a required update for your Second Life Installation. You may download this update from http://www.secondlife.com/downloads or you can install it now. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Quit Second Life" @@ -2946,6 +3199,7 @@ or you can install it now. type="notify"> We have downloaded an update to your [APP_NAME] installation. Version [VERSION] [[RELEASE_NOTES_FULL_URL] Information about this update] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Later..." @@ -2958,6 +3212,7 @@ Version [VERSION] [[RELEASE_NOTES_FULL_URL] Information about this update] type="alertmodal"> We have downloaded an update to your [APP_NAME] installation. Version [VERSION] [[RELEASE_NOTES_FULL_URL] Information about this update] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Later..." @@ -2972,6 +3227,7 @@ We have downloaded a required software update. Version [VERSION] We must restart [APP_NAME] to install the update. + <tag>confirm</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -2982,6 +3238,7 @@ We must restart [APP_NAME] to install the update. name="RequiredUpdateDownloadedDialog" type="alertmodal"> We must restart [APP_NAME] to install the update. + <tag>confirm</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -2993,6 +3250,8 @@ We must restart [APP_NAME] to install the update. type="alertmodal"> Deeding this object will cause the group to: * Receive L$ paid into the object + <tag>group</tag> + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I deed an object to a group" name="okcancelignore" @@ -3005,6 +3264,7 @@ Deeding this object will cause the group to: name="WebLaunchExternalTarget" type="alertmodal"> Do you want to open your Web browser to view this content? + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to view a web page" name="okcancelignore" @@ -3017,6 +3277,7 @@ Do you want to open your Web browser to view this content? name="WebLaunchJoinNow" type="alertmodal"> Go to your [http://secondlife.com/account/ Dashboard] to manage your account? + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to manage my account" name="okcancelignore" @@ -3029,6 +3290,7 @@ Go to your [http://secondlife.com/account/ Dashboard] to manage your account? name="WebLaunchSecurityIssues" type="alertmodal"> Visit the [SECOND_LIFE] Wiki for details of how to report a security issue. + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to learn how to report a Security Issue" name="okcancelignore" @@ -3041,6 +3303,7 @@ Visit the [SECOND_LIFE] Wiki for details of how to report a security issue. name="WebLaunchQAWiki" type="alertmodal"> Visit the [SECOND_LIFE] QA Wiki. + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to view the QA Wiki" name="okcancelignore" @@ -3053,6 +3316,7 @@ Visit the [SECOND_LIFE] QA Wiki. name="WebLaunchPublicIssue" type="alertmodal"> Visit the [SECOND_LIFE] Public Issue Tracker, where you can report bugs and other issues. + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to use the Public Issue Tracker" name="okcancelignore" @@ -3065,6 +3329,7 @@ Visit the [SECOND_LIFE] Public Issue Tracker, where you can report bugs and othe name="WebLaunchSupportWiki" type="alertmodal"> Go to the Official Linden Blog, for the latest news and information. + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to view the blog" name="okcancelignore" @@ -3077,6 +3342,7 @@ Go to the Official Linden Blog, for the latest news and information. name="WebLaunchLSLGuide" type="alertmodal"> Do you want to open the Scripting Guide for help with scripting? + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to view the Scripting Guide" name="okcancelignore" @@ -3089,6 +3355,7 @@ Do you want to open the Scripting Guide for help with scripting? name="WebLaunchLSLWiki" type="alertmodal"> Do you want to visit the LSL Portal for help with scripting? + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to view the LSL Portal" name="okcancelignore" @@ -3103,6 +3370,7 @@ Do you want to visit the LSL Portal for help with scripting? Are you sure you want to return the selected objects to their owners? Transferable deeded objects will be returned to their previous owners. *WARNING* No-transfer deeded objects will be deleted! + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I return objects to their owners" name="okcancelignore" @@ -3116,6 +3384,8 @@ Are you sure you want to return the selected objects to their owners? Transferab type="alert"> You are currently a member of the group [GROUP]. Leave Group? + <tag>group</tag> + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3127,6 +3397,7 @@ Leave Group? name="ConfirmKick" type="alert"> Do you REALLY want to kick all Residents off the grid? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3138,6 +3409,7 @@ Do you REALLY want to kick all Residents off the grid? name="MuteLinden" type="alertmodal"> Sorry, you cannot block a Linden. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3147,7 +3419,8 @@ Sorry, you cannot block a Linden. icon="alertmodal.tga" name="CannotStartAuctionAlreadyForSale" type="alertmodal"> -You cannot start an auction on a parcel which is already set for sale. Disable the land sale if you are sure you want to start an auction. + You cannot start an auction on a parcel which is already set for sale. Disable the land sale if you are sure you want to start an auction. + <tag>fail</tag> </notification> <notification @@ -3156,6 +3429,7 @@ You cannot start an auction on a parcel which is already set for sale. Disable name="MuteByNameFailed" type="alertmodal"> You already have blocked this name. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3166,6 +3440,7 @@ You already have blocked this name. name="RemoveItemWarn" type="alert"> Though permitted, deleting contents may damage the object. Do you want to delete that item? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3177,6 +3452,7 @@ Though permitted, deleting contents may damage the object. Do you want to delete name="CantOfferCallingCard" type="alert"> Cannot offer a calling card at this time. Please try again in a moment. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3186,6 +3462,8 @@ Cannot offer a calling card at this time. Please try again in a moment. icon="alert.tga" name="CantOfferFriendship" type="alert"> + <tag>friendship</tag> + <tag>fail</tag> Cannot offer friendship at this time. Please try again in a moment. <usetemplate name="okbutton" @@ -3210,6 +3488,8 @@ Chat and instant messages will be hidden. Instant messages will get your Busy mo type="alert"> You have reached your maximum number of groups. Please leave another group before joining this one, or decline the offer. [NAME] has invited you to join a group as a member. + <tag>group</tag> + <tag>fail</tag> <usetemplate name="okcancelbuttons" notext="Decline" @@ -3221,6 +3501,8 @@ You have reached your maximum number of groups. Please leave another group befor name="JoinedTooManyGroups" type="alert"> You have reached your maximum number of groups. Please leave some group before joining or creating a new one. + <tag>group</tag> + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3232,6 +3514,7 @@ You have reached your maximum number of groups. Please leave some group before j type="alert"> <tag>win</tag> Kick this Resident with what message? + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> An administrator has logged you off. @@ -3254,6 +3537,7 @@ An administrator has logged you off. type="alert"> <tag>win</tag> Kick everyone currently on the grid with what message? + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> An administrator has logged you off. @@ -3274,7 +3558,8 @@ An administrator has logged you off. icon="alert.tga" name="FreezeUser" type="alert"> - <tag>win</tag> + <tag>win</tag> + <tag>confirm</tag> Freeze this Resident with what message? <form name="form"> <input name="message" type="text"> @@ -3297,6 +3582,7 @@ You have been frozen. You cannot move or chat. An administrator will contact you name="UnFreezeUser" type="alert"> <tag>win</tag> + <tag>confirm</tag> Unfreeze this Resident with what message? <form name="form"> <input name="message" type="text"> @@ -3328,6 +3614,7 @@ Just like in real life, it takes a while for everyone to learn about a new name. name="SetDisplayNameBlocked" type="alert"> Sorry, you cannot change your display name. If you feel this is in error, please contact support. + <tag>fail</tag> </notification> <notification @@ -3337,6 +3624,7 @@ Sorry, you cannot change your display name. If you feel this is in error, please Sorry, that name is too long. Display names can have a maximum of [LENGTH] characters. Please try a shorter name. + <tag>fail</tag> </notification> <notification @@ -3344,6 +3632,7 @@ Please try a shorter name. name="SetDisplayNameFailedGeneric" type="alertmodal"> Sorry, we could not set your display name. Please try again later. + <tag>fail</tag> </notification> <notification @@ -3351,6 +3640,7 @@ Please try a shorter name. name="SetDisplayNameMismatch" type="alertmodal"> The display names you entered do not match. Please re-enter. + <tag>fail</tag> </notification> <!-- *NOTE: This should never happen --> @@ -3363,6 +3653,7 @@ Sorry, you have to wait longer before you can change your display name. See http://wiki.secondlife.com/wiki/Setting_your_display_name Please try again later. + <tag>fail</tag> </notification> <notification @@ -3372,6 +3663,7 @@ Please try again later. Sorry, we could not set your requested name because it contains a banned word. Please try a different name. + <tag>fail</tag> </notification> <notification @@ -3379,6 +3671,7 @@ Please try again later. name="AgentDisplayNameSetInvalidUnicode" type="alertmodal"> The display name you wish to set contains invalid characters. + <tag>fail</tag> </notification> <notification @@ -3386,6 +3679,7 @@ Please try again later. name="AgentDisplayNameSetOnlyPunctuation" type="alertmodal"> Your display name must contain letters other than punctuation. + <tag>fail</tag> </notification> @@ -3401,6 +3695,7 @@ Please try again later. name="OfferTeleport" type="alertmodal"> Offer a teleport to your location with the following message? + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> Join me in [REGION] @@ -3422,6 +3717,7 @@ Join me in [REGION] name="OfferTeleportFromGod" type="alertmodal"> God summon Resident to your location? + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> Join me in [REGION] @@ -3443,6 +3739,7 @@ Join me in [REGION] name="TeleportFromLandmark" type="alertmodal"> Are you sure you want to teleport to <nolink>[LOCATION]</nolink>? + <tag>confirm</tag> <usetemplate ignoretext="Confirm that I want to teleport to a landmark" name="okcancelignore" @@ -3454,7 +3751,8 @@ Are you sure you want to teleport to <nolink>[LOCATION]</nolink>? icon="alertmodal.tga" name="TeleportToPick" type="alertmodal"> -Teleport to [PICK]? + Teleport to [PICK]? + <tag>confirm</tag> <usetemplate ignoretext="Confirm that I want to teleport to a location in Picks" name="okcancelignore" @@ -3467,6 +3765,7 @@ Teleport to [PICK]? name="TeleportToClassified" type="alertmodal"> Teleport to [CLASSIFIED]? + <tag>confirm</tag> <usetemplate ignoretext="Confirm that I want to teleport to a location in Classifieds" name="okcancelignore" @@ -3479,6 +3778,7 @@ Teleport to [PICK]? name="TeleportToHistoryEntry" type="alertmodal"> Teleport to [HISTORY_ENTRY]? + <tag>confirm</tag> <usetemplate ignoretext="Confirm that I want to teleport to a history location" name="okcancelignore" @@ -3492,6 +3792,7 @@ Teleport to [HISTORY_ENTRY]? name="MessageEstate" type="alert"> Type a short announcement which will be sent to everyone currently in your estate. + <tag>confirm</tag> <form name="form"> <input name="message" type="text"/> <button @@ -3516,6 +3817,7 @@ You are about to change a Linden owned estate (mainland, teen grid, orientation, This is EXTREMELY DANGEROUS because it can fundamentally affect the Resident experience. On the mainland, it will change thousands of regions and make the spaceserver hiccup. Proceed? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3531,6 +3833,7 @@ You are about to change the access list for a Linden owned estate (mainland, tee This is DANGEROUS and should only be done to invoke the hack allowing objects/L$ to be transfered in/out of a grid. It will change thousands of regions and make the spaceserver hiccup. + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3543,6 +3846,7 @@ It will change thousands of regions and make the spaceserver hiccup. name="EstateAllowedAgentAdd" type="alert"> Add to allowed list for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3556,6 +3860,7 @@ Add to allowed list for this estate only or for [ALL_ESTATES]? name="EstateAllowedAgentRemove" type="alert"> Remove from allowed list for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3569,6 +3874,8 @@ Remove from allowed list for this estate only or for [ALL_ESTATES]? name="EstateAllowedGroupAdd" type="alert"> Add to group allowed list for this estate only or for [ALL_ESTATES]? + <tag>group</tag> + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3582,6 +3889,8 @@ Add to group allowed list for this estate only or for [ALL_ESTATES]? name="EstateAllowedGroupRemove" type="alert"> Remove from group allowed list for this estate only or [ALL_ESTATES]? + <tag>group</tag> + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3595,6 +3904,7 @@ Remove from group allowed list for this estate only or [ALL_ESTATES]? name="EstateBannedAgentAdd" type="alert"> Deny access for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3608,6 +3918,7 @@ Deny access for this estate only or for [ALL_ESTATES]? name="EstateBannedAgentRemove" type="alert"> Remove this Resident from the ban list for access for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3621,6 +3932,7 @@ Remove this Resident from the ban list for access for this estate only or for [ name="EstateManagerAdd" type="alert"> Add estate manager for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3634,6 +3946,7 @@ Add estate manager for this estate only or for [ALL_ESTATES]? name="EstateManagerRemove" type="alert"> Remove estate manager for this estate only or for [ALL_ESTATES]? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3647,6 +3960,7 @@ Remove estate manager for this estate only or for [ALL_ESTATES]? name="EstateKickUser" type="alert"> Kick [EVIL_USER] from this estate? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3658,6 +3972,7 @@ Kick [EVIL_USER] from this estate? name="EstateChangeCovenant" type="alertmodal"> Are you sure you want to change the Estate Covenant? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3682,6 +3997,7 @@ Please verify you have the latest Viewer installed, and go to the Knowledge Base name="RegionEntryAccessBlocked_KB" type="alertmodal"> <tag>fail</tag> + <tag>confirm</tag> You are not allowed in that region due to your maturity Rating. Go to the Knowledge Base for more information about maturity Ratings? @@ -3708,6 +4024,7 @@ You are not allowed in that region due to your maturity Rating. name="RegionEntryAccessBlocked_Change" type="alertmodal"> <tag>fail</tag> + <tag>confirm</tag> You are not allowed in that Region due to your maturity Rating preference. To enter the desired region, please change your maturity Rating preference. This will allow you to search for and access [REGIONMATURITY] content. To undo any changes, go to Me > Preferences > General. @@ -3739,6 +4056,7 @@ Your maturity Rating preference is now [RATING]. You cannot claim this land due to your maturity Rating. This may be a result of a lack of information validating your age. Please verify you have the latest Viewer installed, and go to the Knowledge Base for details on accessing areas with this maturity rating. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3751,6 +4069,8 @@ Please verify you have the latest Viewer installed, and go to the Knowledge Base You cannot claim this land due to your maturity Rating. Go to the Knowledge Base for more information about maturity Ratings? + <tag>fail</tag> + <tag>confirm</tag> <url option="0" name="url"> http://wiki.secondlife.com/wiki/Linden_Lab_Official:Maturity_ratings:_an_overview </url> @@ -3766,6 +4086,7 @@ Go to the Knowledge Base for more information about maturity Ratings? name="LandClaimAccessBlocked_Notify" type="notifytip"> You cannot claim this land due to your maturity Rating. + <tag>fail</tag> </notification> <notification @@ -3775,6 +4096,8 @@ You cannot claim this land due to your maturity Rating. You cannot claim this land due to your maturity Rating preference. You can click 'Change Preference' to raise your maturity Rating preference now and allow you to enter. You will be able to search and access [REGIONMATURITY] content from now on. If you later want to change this setting back, go to Me > Preferences > General. + <tag>fail</tag> + <tag>confirm</tag> <usetemplate name="okcancelignore" yestext="Change Preference" @@ -3789,6 +4112,7 @@ You can click 'Change Preference' to raise your maturity Rating prefer You cannot buy this land due to your maturity Rating. This may be a result of a lack of information validating your age. Please verify you have the latest Viewer installed, and go to the Knowledge Base for details on accessing areas with this maturity rating. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3801,6 +4125,8 @@ Please verify you have the latest Viewer installed, and go to the Knowledge Base You cannot buy this land due to your maturity Rating. Go to the Knowledge Base for more information about maturity Ratings? + <tag>confirm</tag> + <tag>fail</tag> <url option="0" name="url"> http://wiki.secondlife.com/wiki/Linden_Lab_Official:Maturity_ratings:_an_overview </url> @@ -3816,6 +4142,7 @@ Go to the Knowledge Base for more information about maturity Ratings? name="LandBuyAccessBlocked_Notify" type="notifytip"> You cannot buy this land due to your maturity Rating. + <tag>fail</tag> </notification> <notification @@ -3825,6 +4152,8 @@ You cannot buy this land due to your maturity Rating. You cannot buy this land due to your maturity Rating preference. You can click 'Change Preference' to raise your maturity Rating preference now and allow you to enter. You will be able to search and access [REGIONMATURITY] content from now on. If you later want to change this setting back, go to Me > Preferences > General. + <tag>confirm</tag> + <tag>fail</tag> <usetemplate name="okcancelignore" yestext="Change Preference" @@ -3837,6 +4166,7 @@ You can click 'Change Preference' to raise your maturity Rating prefer name="TooManyPrimsSelected" type="alertmodal"> There are too many prims selected. Please select [MAX_PRIM_COUNT] or fewer prims and try again + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3847,6 +4177,7 @@ There are too many prims selected. Please select [MAX_PRIM_COUNT] or fewer prim name="ProblemImportingEstateCovenant" type="alertmodal"> Problem importing estate covenant. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3857,6 +4188,7 @@ Problem importing estate covenant. name="ProblemAddingEstateManager" type="alertmodal"> Problems adding a new estate manager. One or more estates may have a full manager list. + <tag>fail</tag> </notification> <notification @@ -3864,6 +4196,7 @@ Problems adding a new estate manager. One or more estates may have a full manag name="ProblemAddingEstateGeneric" type="alertmodal"> Problems adding to this estate list. One or more estates may have a full list. + <tag>fail</tag> </notification> <notification @@ -3874,6 +4207,7 @@ Unable to load notecard's asset at this time. <usetemplate name="okbutton" yestext="OK"/> + <tag>fail</tag> </notification> <notification @@ -3884,6 +4218,7 @@ Insufficient permissions to view notecard associated with asset ID requested. <usetemplate name="okbutton" yestext="OK"/> + <tag>fail</tag> </notification> <notification @@ -3891,6 +4226,7 @@ Insufficient permissions to view notecard associated with asset ID requested. name="MissingNotecardAssetID" type="alertmodal"> Asset ID for notecard is missing from database. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -3903,6 +4239,8 @@ Asset ID for notecard is missing from database. Remember: Classified ad fees are non-refundable. Publish this classified now for L$[AMOUNT]? + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3914,6 +4252,7 @@ Publish this classified now for L$[AMOUNT]? name="SetClassifiedMature" type="alertmodal"> Does this classified contain Moderate content? + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3926,6 +4265,8 @@ Does this classified contain Moderate content? name="SetGroupMature" type="alertmodal"> Does this group contain Moderate content? + <tag>group</tag> + <tag>confirm</tag> <usetemplate canceltext="Cancel" name="yesnocancelbuttons" @@ -3939,6 +4280,7 @@ Does this group contain Moderate content? name="ConfirmRestart" type="alert"> Do you really want to restart this region in 2 minutes? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -3951,6 +4293,7 @@ Do you really want to restart this region in 2 minutes? name="MessageRegion" type="alert"> Type a short announcement which will be sent to everyone in this region. + <tag>confirm</tag> <form name="form"> <input name="message" type="text"/> <button @@ -3982,6 +4325,8 @@ To enter Adult regions, Residents must be Account Verified, either by age-verifi name="VoiceVersionMismatch" type="alertmodal"> This version of [APP_NAME] is not compatible with the Voice Chat feature in this region. In order for Voice Chat to function correctly you will need to update [APP_NAME]. + <tag>fail</tag> + <tag>voice</tag> </notification> <notification @@ -3991,6 +4336,7 @@ This version of [APP_NAME] is not compatible with the Voice Chat feature in this type="alertmodal"> Cannot buy objects from different owners at the same time. Please select only one object and try again. + <tag>fail</tag> </notification> <notification @@ -4000,6 +4346,7 @@ Please select only one object and try again. type="alertmodal"> Unable to buy the contents of more than one object at a time. Please select only one object and try again. + <tag>fail</tag> </notification> <notification @@ -4009,6 +4356,7 @@ Please select only one object and try again. type="alertmodal"> Cannot buy objects from different owners at the same time. Please select only one object and try again. + <tag>fail</tag> </notification> <notification @@ -4021,6 +4369,8 @@ You will be able to: Modify: [MODIFYPERM] Copy: [COPYPERM] Resell or Give Away: [RESELLPERM] + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4037,6 +4387,8 @@ You will be able to: Modify: [MODIFYPERM] Copy: [COPYPERM] Resell or Give Away: [RESELLPERM] + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4053,6 +4405,8 @@ You will be able to: Modify: [MODIFYPERM] Copy: [COPYPERM] Resell or Give Away: [RESELLPERM] + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4069,6 +4423,8 @@ You will be able to: Modify: [MODIFYPERM] Copy: [COPYPERM] Resell or Give Away: [RESELLPERM] + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4081,6 +4437,8 @@ You will be able to: type="alertmodal"> Buy contents from [OWNER] for L$[PRICE]? They will be copied to your inventory. + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4093,6 +4451,8 @@ They will be copied to your inventory. type="alertmodal"> Buy contents for L$[PRICE]? They will be copied to your inventory. + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4107,6 +4467,8 @@ This transaction will: [ACTION] Are you sure you want to proceed with this purchase? + <tag>confirm</tag> + <tag>funds</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4122,6 +4484,8 @@ This transaction will: Are you sure you want to proceed with this purchase? Please re-enter your password and click OK. + <tag>funds</tag> + <tag>confirm</tag> <form name="form"> <input name="message" @@ -4157,6 +4521,7 @@ You have selected 'no copy' inventory items. These items will be moved to your inventory, not copied. Move the inventory item(s)? + <tag>confirm</tag> <usetemplate ignoretext="Warn me before I move 'no-copy' items from an object" name="okcancelignore" @@ -4171,7 +4536,8 @@ Move the inventory item(s)? You have selected 'no copy' inventory items. These items will be moved to your inventory, not copied. Because this object is scripted, moving these items to your inventory may cause the script to malfunction. -Move the inventory item(s)? +Move the inventory item(s)? + <tag>confirm</tag> <usetemplate ignoretext="Warn me before I move 'no-copy' items which might break a scripted object" name="okcancelignore" @@ -4195,6 +4561,7 @@ Warning: The 'Pay object' click action has been set, but it will only name="OpenObjectCannotCopy" type="alertmodal"> There are no items in this object that you are allowed to copy. + <tag>fail</tag> </notification> <notification @@ -4202,6 +4569,7 @@ There are no items in this object that you are allowed to copy. name="WebLaunchAccountHistory" type="alertmodal"> Go to your [http://secondlife.com/account/ Dashboard] to see your account history? + <tag>confirm</tag> <usetemplate ignoretext="Launch my browser to see my account history" name="okcancelignore" @@ -4215,6 +4583,7 @@ Go to your [http://secondlife.com/account/ Dashboard] to see your account histor type="alertmodal" unique="true"> Are you sure you want to quit? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I quit" name="okcancelignore" @@ -4228,6 +4597,7 @@ Are you sure you want to quit? type="alertmodal" unique="true"> [QUESTION] + <tag>confirm</tag> <usetemplate ignoretext="Confirm before deleting items" name="okcancelignore" @@ -4251,6 +4621,7 @@ All reported abuses are investigated and resolved. type="alertmodal"> Please select a category for this abuse report. Selecting a category helps us file and process abuse reports. + <tag>fail</tag> </notification> <notification @@ -4259,6 +4630,7 @@ Selecting a category helps us file and process abuse reports. type="alertmodal"> Please enter the name of the abuser. Entering an accurate value helps us file and process abuse reports. + <tag>fail</tag> </notification> <notification @@ -4267,6 +4639,7 @@ Entering an accurate value helps us file and process abuse reports. type="alertmodal"> Please enter the location where the abuse took place. Entering an accurate value helps us file and process abuse reports. + <tag>fail</tag> </notification> <notification @@ -4275,6 +4648,7 @@ Entering an accurate value helps us file and process abuse reports. type="alertmodal"> Please enter a summary of the abuse that took place. Entering an accurate summary helps us file and process abuse reports. + <tag>fail</tag> </notification> <notification @@ -4284,6 +4658,7 @@ Entering an accurate summary helps us file and process abuse reports. Please enter a detailed description of the abuse that took place. Be as specific as you can, including names and the details of the incident you are reporting. Entering an accurate description helps us file and process abuse reports. + <tag>fail</tag> </notification> <notification @@ -4311,6 +4686,7 @@ Linden Lab type="alertmodal"> The following required components are missing from [FLOATER]: [COMPONENTS] + <tag>fail</tag> </notification> <notification @@ -4320,6 +4696,7 @@ The following required components are missing from [FLOATER]: type="alert"> There is already an object attached to this point on your body. Do you want to replace it with the selected object? + <tag>confirm</tag> <form name="form"> <ignore name="ignore" save_option="true" @@ -4346,6 +4723,7 @@ Do you want to replace it with the selected object? You are in Busy Mode, which means you will not receive any items offered in exchange for this payment. Would you like to leave Busy Mode before completing this transaction? + <tag>confirm</tag> <form name="form"> <ignore name="ignore" save_option="true" @@ -4369,6 +4747,7 @@ Would you like to leave Busy Mode before completing this transaction? name="ConfirmDeleteProtectedCategory" type="alertmodal"> The folder '[FOLDERNAME]' is a system folder. Deleting system folders can cause instability. Are you sure you want to delete it? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I delete a system folder" name="okcancelignore" @@ -4381,6 +4760,7 @@ The folder '[FOLDERNAME]' is a system folder. Deleting system folders name="ConfirmEmptyTrash" type="alertmodal"> Are you sure you want to permanently delete the contents of your Trash? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I empty the inventory Trash folder" name="okcancelignore" @@ -4393,6 +4773,7 @@ Are you sure you want to permanently delete the contents of your Trash? name="ConfirmClearBrowserCache" type="alertmodal"> Are you sure you want to delete your travel, web, and search history? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4404,6 +4785,7 @@ Are you sure you want to delete your travel, web, and search history? name="ConfirmClearCookies" type="alertmodal"> Are you sure you want to clear your cookies? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4415,6 +4797,7 @@ Are you sure you want to clear your cookies? name="ConfirmClearMediaUrlList" type="alertmodal"> Are you sure you want to clear your list of saved URLs? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -4426,6 +4809,7 @@ Are you sure you want to clear your list of saved URLs? name="ConfirmEmptyLostAndFound" type="alertmodal"> Are you sure you want to permanently delete the contents of your Lost And Found? + <tag>confirm</tag> <usetemplate ignoretext="Confirm before I empty the inventory Lost And Found folder" name="okcancelignore" @@ -4452,6 +4836,7 @@ Link to this from a web page to give others easy access to this location, or try name="WLSavePresetAlert" type="alertmodal"> Do you wish to overwrite the saved preset? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -4463,6 +4848,7 @@ Do you wish to overwrite the saved preset? name="WLDeletePresetAlert" type="alertmodal"> Do you wish to delete [SKY]? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="No" @@ -4474,6 +4860,7 @@ Do you wish to delete [SKY]? name="WLNoEditDefault" type="alertmodal"> You cannot edit or delete a default preset. + <tag>fail</tag> </notification> <notification @@ -4481,6 +4868,7 @@ You cannot edit or delete a default preset. name="WLMissingSky" type="alertmodal"> This day cycle file references a missing sky file: [SKY]. + <tag>fail</tag> </notification> <notification @@ -4499,6 +4887,7 @@ PostProcess Effect exists. Do you still wish overwrite it? name="NewSkyPreset" type="alert"> Give me a name for the new sky. + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> New Preset @@ -4520,6 +4909,7 @@ New Preset name="ExistsSkyPresetAlert" type="alertmodal"> Preset already exists! + <tag>fail</tag> </notification> <notification @@ -4527,6 +4917,7 @@ Preset already exists! name="NewWaterPreset" type="alert"> Give me a name for the new water preset. + <tag>confirm</tag> <form name="form"> <input name="message" type="text"> New Preset @@ -4548,6 +4939,7 @@ New Preset name="ExistsWaterPresetAlert" type="alertmodal"> Preset already exists! + <tag>fail</tag> </notification> <notification @@ -4555,6 +4947,7 @@ Preset already exists! name="WaterNoEditDefault" type="alertmodal"> You cannot edit or delete a default preset. + <tag>fail</tag> </notification> <notification @@ -4563,6 +4956,7 @@ You cannot edit or delete a default preset. type="alertmodal"> Unable to start a new chat session with [RECIPIENT]. [REASON] + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -4574,6 +4968,7 @@ Unable to start a new chat session with [RECIPIENT]. type="alertmodal"> [EVENT] [REASON] + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -4595,6 +4990,7 @@ Your chat session with [NAME] must close. name="Cannot_Purchase_an_Attachment" type="alertmodal"> You can't buy an object while it is attached. + <tag>fail</tag> </notification> <notification @@ -4613,6 +5009,7 @@ Granting this request gives a script ongoing permission to take Linden dollars ( name="AutoWearNewClothing" type="alertmodal"> Would you like to automatically wear the clothing you are about to create? + <tag>confirm</tag> <usetemplate ignoretext="Wear the clothing I create while editing My Appearance" name="okcancelignore" @@ -4628,6 +5025,7 @@ Would you like to automatically wear the clothing you are about to create? You must be age-verified to visit this area. Do you want to go to the [SECOND_LIFE] website and verify your age? [_URL] + <tag>confirm</tag> <url option="0" name="url"> https://secondlife.com/account/verification.php @@ -4646,6 +5044,7 @@ You must be age-verified to visit this area. Do you want to go to the [SECOND_L You must have payment information on file to visit this area. Do you want to go to the [SECOND_LIFE] website and set this up? [_URL] + <tag>confirm</tag> <url option="0" name="url"> https://secondlife.com/account/ @@ -4662,6 +5061,7 @@ You must have payment information on file to visit this area. Do you want to go name="MissingString" type="alertmodal"> The string [STRING_NAME] is missing from strings.xml + <tag>fail</tag> </notification> <notification @@ -4712,12 +5112,14 @@ Replaced missing clothing/body part with default. persist="true" type="groupnotify"> Topic: [SUBJECT], Message: [MESSAGE] + <tag>group</tag> </notification> <notification icon="notifytip.tga" name="FriendOnline" type="notifytip"> + <tag>friendship</tag> [NAME] is Online </notification> @@ -4725,6 +5127,7 @@ Topic: [SUBJECT], Message: [MESSAGE] icon="notifytip.tga" name="FriendOffline" type="notifytip"> + <tag>friendship</tag> [NAME] is Offline </notification> @@ -4732,6 +5135,7 @@ Topic: [SUBJECT], Message: [MESSAGE] icon="notifytip.tga" name="AddSelfFriend" type="notifytip"> + <tag>friendship</tag> Although you're very nice, you can't add yourself as a friend. </notification> @@ -4749,6 +5153,7 @@ Uploading in-world and web site snapshots... persist="true" type="notify"> You paid L$[AMOUNT] to upload. +<tag>funds</tag> </notification> <notification @@ -4777,6 +5182,7 @@ Terrain.raw downloaded name="GestureMissing" type="notifytip"> Hmm. Gesture [NAME] is missing from the database. + <tag>fail</tag> </notification> <notification @@ -4784,6 +5190,7 @@ Hmm. Gesture [NAME] is missing from the database. name="UnableToLoadGesture" type="notifytip"> Unable to load gesture [NAME]. + <tag>fail</tag> </notification> <notification @@ -4791,6 +5198,7 @@ Unable to load gesture [NAME]. name="LandmarkMissing" type="notifytip"> Landmark is missing from database. + <tag>fail</tag> </notification> <notification @@ -4798,6 +5206,7 @@ Landmark is missing from database. name="UnableToLoadLandmark" type="notifytip"> Unable to load landmark. Please try again. + <tag>fail</tag> </notification> <notification @@ -4813,6 +5222,7 @@ This might affect your password. name="NotecardMissing" type="notifytip"> Notecard is missing from database. + <tag>fail</tag> </notification> <notification @@ -4820,6 +5230,7 @@ Notecard is missing from database. name="NotecardNoPermissions" type="notifytip"> You don't have permission to view this notecard. + <tag>fail</tag> </notification> <notification @@ -4827,6 +5238,7 @@ You don't have permission to view this notecard. name="RezItemNoPermissions" type="notifytip"> Insufficient permissions to rez object. + <tag>fail</tag> </notification> <notification @@ -4835,6 +5247,7 @@ Insufficient permissions to rez object. type="notifytip"> Unable to load notecard. Please try again. + <tag>fail</tag> </notification> <notification @@ -4842,6 +5255,7 @@ Please try again. name="ScriptMissing" type="notifytip"> Script is missing from database. + <tag>fail</tag> </notification> <notification @@ -4849,6 +5263,7 @@ Script is missing from database. name="ScriptNoPermissions" type="notifytip"> Insufficient permissions to view script. + <tag>fail</tag> </notification> <notification @@ -4856,6 +5271,7 @@ Insufficient permissions to view script. name="UnableToLoadScript" type="notifytip"> Unable to load script. Please try again. + <tag>fail</tag> </notification> <notification @@ -4863,6 +5279,7 @@ Unable to load script. Please try again. name="IncompleteInventory" type="notifytip"> The complete contents you are offering are not yet locally available. Please try offering those items again in a minute. + <tag>fail</tag> </notification> <notification @@ -4870,6 +5287,7 @@ The complete contents you are offering are not yet locally available. Please try name="CannotModifyProtectedCategories" type="notifytip"> You cannot modify protected categories. + <tag>fail</tag> </notification> <notification @@ -4877,6 +5295,7 @@ You cannot modify protected categories. name="CannotRemoveProtectedCategories" type="notifytip"> You cannot remove protected categories. + <tag>fail</tag> </notification> <notification @@ -4885,6 +5304,7 @@ You cannot remove protected categories. type="notifytip"> Unable to buy while downloading object data. Please try again. + <tag>fail</tag> </notification> <notification @@ -4893,6 +5313,7 @@ Please try again. type="notifytip"> Unable to link while downloading object data. Please try again. + <tag>fail</tag> </notification> <notification @@ -4901,6 +5322,7 @@ Please try again. type="notifytip"> You can only buy objects from one owner at a time. Please select a single object. + <tag>fail</tag> </notification> <notification @@ -4908,6 +5330,7 @@ Please select a single object. name="ObjectNotForSale" type="notifytip"> This object is not for sale. + <tag>fail</tag> </notification> <notification @@ -4929,6 +5352,7 @@ Now leaving god mode, level [LEVEL] name="CopyFailed" type="notifytip"> You don't have permission to copy this. + <tag>fail</tag> </notification> <notification @@ -4990,6 +5414,7 @@ Select the Resident from the list, then click 'IM' at the bottom of th type="notifytip"> Can't select land across server boundaries. Try selecting a smaller piece of land. + <tag>fail</tag> </notification> <notification @@ -4997,6 +5422,7 @@ Try selecting a smaller piece of land. name="SearchWordBanned" type="notifytip"> Some terms in your search query were excluded due to content restrictions as clarified in the Community Standards. + <tag>fail</tag> </notification> <notification @@ -5004,6 +5430,7 @@ Some terms in your search query were excluded due to content restrictions as cla name="NoContentToSearch" type="notifytip"> Please select at least one type of content to search (General, Moderate, or Adult). + <tag>fail</tag> </notification> <notification @@ -5019,6 +5446,7 @@ Please select at least one type of content to search (General, Moderate, or Adul name="PaymentReceived" persist="true" type="notify"> + <tag>funds</tag> [MESSAGE] </notification> @@ -5027,6 +5455,7 @@ Please select at least one type of content to search (General, Moderate, or Adul name="PaymentSent" persist="true" type="notify"> + <tag>funds</tag> [MESSAGE] </notification> @@ -5084,13 +5513,16 @@ Deactivated gestures with same trigger: type="notify"> Apple's QuickTime software does not appear to be installed on your system. If you want to view streaming media on parcels that support it you should go to the [http://www.apple.com/quicktime QuickTime site] and install the QuickTime Player. + <tag>fail</tag> </notification> + <notification icon="notify.tga" name="NoPlugin" persist="true" type="notify"> No Media Plugin was found to handle the "[MIME_TYPE]" mime type. Media of this type will be unavailable. + <tag>fail</tag> <unique> <context>MIME_TYPE</context> </unique> @@ -5104,6 +5536,7 @@ The following Media Plugin has failed: [PLUGIN] Please re-install the plugin or contact the vendor if you continue to experience problems. + <tag>fail</tag> <form name="form"> <ignore name="ignore" text="A Media Plugin fails to run"/> @@ -5141,6 +5574,7 @@ The objects on the selected parcel of land owned by the Resident '[NAME]&ap The objects on the selected parcel of land shared with the group [GROUPNAME] have been returned back to their owner's inventory. Transferable deeded objects have been returned to their previous owners. Non-transferable objects that are deeded to the group have been deleted. + <tag>group</tag> </notification> <notification @@ -5197,6 +5631,7 @@ This area does not allow pushing. You can't push others here unless you own type="notify" unique="true"> This area has voice chat disabled. You won't be able to hear anyone talking. + <tag>voice</tag> </notification> <notification @@ -5241,6 +5676,7 @@ No scripts will work here except those belonging to the land owner. persist="true" type="notify"> You can only claim public land in the Region you're in. + <tag>fail</tag> </notification> <notification @@ -5529,6 +5965,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU name="JoinGroup" persist="true" type="notify"> + <tag>group</tag> [MESSAGE] <form name="form"> <button @@ -5553,6 +5990,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU [NAME_SLURL] has offered to teleport you to their location: [MESSAGE] - [MATURITY_STR] <icon>[MATURITY_ICON]</icon> + <tag>confirm</tag> <form name="form"> <button index="0" @@ -5596,6 +6034,8 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU icon="notify.tga" name="OfferFriendship" type="offer"> + <tag>friendship</tag> + <tag>confirm</tag> [NAME_SLURL] is offering friendship. [MESSAGE] @@ -5617,6 +6057,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU icon="notify.tga" name="FriendshipOffered" type="offer"> + <tag>friendship</tag> You have offered friendship to [TO_NAME] </notification> @@ -5625,6 +6066,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU name="OfferFriendshipNoMessage" persist="true" type="notify"> + <tag>friendship</tag> [NAME_SLURL] is offering friendship. (By default, you will be able to see each other's online status.) @@ -5644,6 +6086,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU icon="notify.tga" name="FriendshipAccepted" type="offer"> + <tag>friendship</tag> [NAME] accepted your friendship offer. </notification> @@ -5652,6 +6095,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU name="FriendshipDeclined" persist="true" type="notify"> + <tag>friendship</tag> [NAME] declined your friendship offer. </notification> @@ -5659,6 +6103,7 @@ An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLU icon="notify.tga" name="FriendshipAcceptedByMe" type="offer"> + <tag>friendship</tag> Friendship offer accepted. </notification> @@ -5666,6 +6111,7 @@ Friendship offer accepted. icon="notify.tga" name="FriendshipDeclinedByMe" type="offer"> + <tag>friendship</tag> Friendship offer declined. </notification> @@ -5719,6 +6165,7 @@ Load web page [URL]? [MESSAGE] From object: <nolink>[OBJECTNAME]</nolink>, owner: [NAME]? + <tag>confirm</tag> <form name="form"> <button index="0" @@ -5737,6 +6184,7 @@ From object: <nolink>[OBJECTNAME]</nolink>, owner: [NAME]? persist="true" type="notify"> Failed to find [TYPE] in database. + <tag>fail</tag> </notification> <notification @@ -5745,6 +6193,7 @@ Failed to find [TYPE] in database. persist="true" type="notify"> Failed to find [TYPE] named [DESC] in database. + <tag>fail</tag> </notification> <notification @@ -5753,6 +6202,7 @@ Failed to find [TYPE] named [DESC] in database. persist="true" type="notify"> The item you are trying to wear uses a feature that your Viewer can't read. Please upgrade your version of [APP_NAME] to wear this item. + <tag>fail</tag> </notification> <notification @@ -5764,6 +6214,7 @@ The item you are trying to wear uses a feature that your Viewer can't read. [QUESTIONS] Is this OK? + <tag>confirm</tag> <form name="form"> <button index="0" @@ -5792,6 +6243,7 @@ An object named '<nolink>[OBJECTNAME]</nolink>', owned by If you do not trust this object and its creator, you should deny the request. Grant this request? + <tag>confirm</tag> <form name="form"> <button index="0" @@ -5827,6 +6279,7 @@ Grant this request? icon="notify.tga" name="ScriptDialogGroup" type="notify"> + <tag>group</tag> [GROUPNAME]'s '<nolink>[TITLE]</nolink>' [MESSAGE] <form name="form"> @@ -5863,6 +6316,7 @@ Your L$ balance is shown in the upper-right. name="BuyLindenDollarSuccess" persist="true" type="notify"> + <tag>funds</tag> Thank you for your payment! Your L$ balance will be updated when processing completes. If processing takes more than 20 mins, your transaction may be cancelled. In that case, the purchase amount will be credited to your US$ balance. @@ -5870,57 +6324,6 @@ Your L$ balance will be updated when processing completes. If processing takes m The status of your payment can be checked on your Transaction History page on your [http://secondlife.com/account/ Dashboard] </notification> -<!-- - <notification - icon="notify.tga" - name="FirstSit" - persist="true" - type="notify"> -You are sitting. -Use your arrow keys (or AWSD) to look around. -Click the 'Stand Up' button to stand. - </notification> - - <notification - icon="notify.tga" - name="FirstMap" - persist="true" - type="notify"> -Click and drag the map to look around. -Double-click to teleport. -Use the controls on the right to find things and display different backgrounds. - </notification> - - <notification - icon="notify.tga" - name="FirstBuild" - persist="true" - type="notify"> -You have opened the Build Tools. Every object you see around you was created using these tools. - </notification> ---> - -<!-- - <notification - icon="notify.tga" - name="FirstLeftClickNoHit" - persist="true" - type="notify"> - Left-clicking interacts with special objects. - If the mouse pointer changes to a hand, you can interact with the object. - Right-click always shows a menu of things you can do. - </notification> - - <notification - icon="notify.tga" - name="FirstTeleport" - persist="true" - type="notify"> -You can only teleport to certain areas in this region. The arrow points to your specific destination. Click the arrow to dismiss it. - </notification> - ---> - <notification icon="notify.tga" name="FirstOverrideKeys" @@ -5932,30 +6335,6 @@ Some objects (like guns) require you to go into mouselook to use them. Press 'M' to do this. </notification> -<!-- - <notification - icon="notify.tga" - name="FirstAppearance" - persist="true" - type="notify"> -You are editing your Appearance. -Use the arrow keys to look around. -When you are done, press 'Save All'. - </notification> - - <notification - icon="notify.tga" - name="FirstInventory" - persist="true" - type="notify"> -This is your Inventory, which contains items you own. - -* To wear something, drag it onto yourself. -* To rez something inworld, drag it onto the ground. -* To read a notecard, double-click it. - </notification> ---> - <notification icon="notify.tga" name="FirstSandbox" @@ -5966,47 +6345,6 @@ This is a sandbox area, and is meant to help Residents learn how to build. Things you build here will be deleted after you leave, so don't forget to right-click and choose 'Take' to move your creation to your Inventory. </notification> -<!-- - <notification - icon="notify.tga" - name="FirstFlexible" - persist="true" - type="notify"> -This object is flexible. Flexis must be phantom and not physical. - </notification> - - <notification - icon="notify.tga" - name="FirstDebugMenus" - persist="true" - type="notify"> -You opened the Advanced menu. - -To toggle this menu, - Windows: Ctrl+Alt+D - Mac: ⌥⌘D - - </notification> - - <notification - icon="notify.tga" - name="FirstSculptedPrim" - persist="true" - type="notify"> -You are editing a Sculpted prim. Sculpties require a special texture to define their shape. - </notification> ---> - - <!-- - <notification - icon="notify.tga" - name="FirstMedia" - persist="true" - type="notify"> - You have begun playing media. Media can set to play automatically in the preferences window under Audio / Video. Note that this can be a security risk for media sites you do not trust. - </notification> - --> - <notification icon="notifytip.tga" name="MaxListSelectMessage" @@ -6020,6 +6358,8 @@ You may only select up to [MAX_SELECT] items from this list. type="notify"> [NAME] is inviting you to a Voice Chat call. Click Accept to join the call or Decline to decline the invitation. Click Block to block this caller. + <tag>confirm</tag> + <tag>voice</tag> <unique> <context>NAME</context> </unique> @@ -6069,6 +6409,9 @@ Click Accept to join the call or Decline to decline the invitation. Click Block type="notify"> [NAME] has joined a Voice Chat call with the group [GROUP]. Click Accept to join the call or Decline to decline the invitation. Click Block to block this caller. + <tag>group</tag> + <tag>confirm</tag> + <tag>voice</tag> <unique> <context>NAME</context> <context>GROUP</context> @@ -6095,6 +6438,8 @@ Click Accept to join the call or Decline to decline the invitation. Click Block type="notify"> [NAME] has joined a voice chat call with a conference chat. Click Accept to join the call or Decline to decline the invitation. Click Block to block this caller. + <tag>confirm</tag> + <tag>voice</tag> <unique> <context>NAME</context> </unique> @@ -6120,6 +6465,8 @@ Click Accept to join the call or Decline to decline the invitation. Click Block type="notify"> [NAME] is inviting you to a conference chat. Click Accept to join the chat or Decline to decline the invitation. Click Block to block this caller. + <tag>confirm</tag> + <tag>voice</tag> <unique> <context>NAME</context> </unique> @@ -6144,6 +6491,8 @@ Click Accept to join the chat or Decline to decline the invitation. Click Block name="VoiceChannelFull" type="notifytip"> The voice call you are trying to join, [VOICE_CHANNEL_NAME], has reached maximum capacity. Please try again later. + <tag>fail</tag> + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6154,7 +6503,9 @@ The voice call you are trying to join, [VOICE_CHANNEL_NAME], has reached maximum name="ProximalVoiceChannelFull" type="notifytip" unique="true"> -We're sorry. This area has reached maximum capacity for voice conversations. Please try to use voice in another area. + We're sorry. This area has reached maximum capacity for voice conversations. Please try to use voice in another area. + <tag>fail</tag> + <tag>voice</tag> </notification> <notification @@ -6162,6 +6513,7 @@ We're sorry. This area has reached maximum capacity for voice conversation name="VoiceChannelDisconnected" type="notifytip"> You have been disconnected from [VOICE_CHANNEL_NAME]. You will now be reconnected to Nearby Voice Chat. + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6172,6 +6524,7 @@ You have been disconnected from [VOICE_CHANNEL_NAME]. You will now be reconnect name="VoiceChannelDisconnectedP2P" type="notifytip"> [VOICE_CHANNEL_NAME] has ended the call. You will now be reconnected to Nearby Voice Chat. + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6182,6 +6535,8 @@ You have been disconnected from [VOICE_CHANNEL_NAME]. You will now be reconnect name="P2PCallDeclined" type="notifytip"> [VOICE_CHANNEL_NAME] has declined your call. You will now be reconnected to Nearby Voice Chat. + <tag>voice</tag> + <tag>fail</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6192,6 +6547,8 @@ You have been disconnected from [VOICE_CHANNEL_NAME]. You will now be reconnect name="P2PCallNoAnswer" type="notifytip"> [VOICE_CHANNEL_NAME] is not available to take your call. You will now be reconnected to Nearby Voice Chat. + <tag>fail</tag> + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6202,6 +6559,8 @@ You have been disconnected from [VOICE_CHANNEL_NAME]. You will now be reconnect name="VoiceChannelJoinFailed" type="notifytip"> Failed to connect to [VOICE_CHANNEL_NAME], please try again later. You will now be reconnected to Nearby Voice Chat. + <tag>fail</tag> + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6214,6 +6573,8 @@ Failed to connect to [VOICE_CHANNEL_NAME], please try again later. You will now type="notifytip" unique="true"> We are creating a voice channel for you. This may take up to one minute. + <tag>status</tag> + <tag>voice</tag> </notification> <notification @@ -6225,6 +6586,8 @@ We are creating a voice channel for you. This may take up to one minute. unique="true"> One or more of your subscribed Voice Morphs has expired. [[URL] Click here] to renew your subscription. + <tag>fail</tag> + <tag>voice</tag> </notification> <notification @@ -6236,6 +6599,8 @@ One or more of your subscribed Voice Morphs has expired. unique="true"> The active Voice Morph has expired, your normal voice settings have been applied. [[URL] Click here] to renew your subscription. + <tag>fail</tag> + <tag>voice</tag> </notification> <notification @@ -6247,6 +6612,8 @@ The active Voice Morph has expired, your normal voice settings have been applied unique="true"> One or more of your Voice Morphs will expire in less than [INTERVAL] days. [[URL] Click here] to renew your subscription. + <tag>fail</tag> + <tag>voice</tag> </notification> <notification @@ -6257,6 +6624,7 @@ One or more of your Voice Morphs will expire in less than [INTERVAL] days. type="notify" unique="true"> New Voice Morphs are available! + <tag>voice</tag> </notification> <notification @@ -6264,6 +6632,7 @@ New Voice Morphs are available! name="Cannot enter parcel: not a group member" type="notifytip"> <tag>fail</tag> + <tag>group</tag> Only members of a certain group can visit this area. </notification> @@ -6288,6 +6657,8 @@ Cannot enter parcel, you are not on the access list. name="VoiceNotAllowed" type="notifytip"> You do not have permission to connect to voice chat for [VOICE_CHANNEL_NAME]. + <tag>fail</tag> + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6298,6 +6669,8 @@ You do not have permission to connect to voice chat for [VOICE_CHANNEL_NAME]. name="VoiceCallGenericError" type="notifytip"> An error has occurred while trying to connect to voice chat for [VOICE_CHANNEL_NAME]. Please try again later. + <tag>fail</tag> + <tag>voice</tag> <unique> <context>VOICE_CHANNEL_NAME</context> </unique> @@ -6309,6 +6682,7 @@ An error has occurred while trying to connect to voice chat for [VOICE_CHANNEL_N priority="high" type="notifytip"> The SLurl you clicked on is not supported. + <tag>fail</tag> </notification> <notification @@ -6316,7 +6690,7 @@ The SLurl you clicked on is not supported. name="BlockedSLURL" priority="high" type="notifytip"> - <tag>win</tag> + <tag>security</tag> A SLurl was received from an untrusted browser and has been blocked for your security. </notification> @@ -6325,6 +6699,7 @@ A SLurl was received from an untrusted browser and has been blocked for your sec name="ThrottledSLURL" priority="high" type="notifytip"> + <tag>security</tag> Multiple SLurls were received from an untrusted browser within a short period. They will be blocked for a few seconds for your security. </notification> @@ -6341,6 +6716,7 @@ They will be blocked for a few seconds for your security. name="ConfirmCloseAll" type="alertmodal"> Are you sure you want to close all IMs? + <tag>confirm</tag> <usetemplate name="okcancelignore" notext="Cancel" @@ -6358,6 +6734,7 @@ Attachment has been saved. name="UnableToFindHelpTopic" type="alertmodal"> Unable to find the help topic for this element. + <tag>fail</tag> </notification> <notification @@ -6366,6 +6743,7 @@ Unable to find the help topic for this element. type="alertmodal"> Server Error: Media update or get failed. '[ERROR]' + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -6386,6 +6764,7 @@ Your text chat has been muted by moderator. name="VoiceIsMutedByModerator" type="alertmodal"> Your voice has been muted by moderator. + <tag>voice</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -6407,6 +6786,7 @@ This upload will cost L$[PRICE], do you wish to continue with the upload? name="ConfirmClearTeleportHistory" type="alertmodal"> Are you sure you want to delete your teleport history? + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" @@ -6419,6 +6799,7 @@ Are you sure you want to delete your teleport history? type="alert"> Selected button can not be shown right now. The button will be shown when there is enough space for it. + <tag>fail</tag> </notification> <notification @@ -6446,22 +6827,27 @@ Are you sure you want to share the following items: With the following Residents: [RESIDENTS] + <tag>confirm</tag> <usetemplate name="okcancelbuttons" notext="Cancel" yestext="Ok"/> </notification> + <notification icon="notifytip.tga" name="ItemsShared" type="notifytip"> Items successfully shared. </notification> + <notification icon="notifytip.tga" name="DeedToGroupFail" type="notifytip"> Deed to group failed. + <tag>group</tag> + <tag>fail</tag> </notification> <notification @@ -6535,6 +6921,7 @@ Avatar '[NAME]' left appearance mode. type="alertmodal"> We're having trouble connecting using [PROTOCOL] [HOSTID]. Please check your network and firewall setup. + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -6550,6 +6937,8 @@ We're having trouble connecting to your voice server: Voice communications will not be available. Please check your network and firewall setup. + <tag>voice</tag> + <tag>fail</tag> <usetemplate name="okbutton" yestext="OK"/> @@ -6584,6 +6973,8 @@ You locally updated a [RESOLUTION] baked texture for '[BODYREGION]' after [TIME] name="ConfirmLeaveCall" type="alert"> Are you sure you want to leave this call? + <tag>confirm</tag> + <tag>voice</tag> <usetemplate ignoretext="Confirm before I leave call" name="okcancelignore" @@ -6601,6 +6992,9 @@ This will also cause all residents that later join the call to be muted, even after you have left the call. Mute everyone? + <tag>group</tag> + <tag>confirm</tag> + <tag>voice</tag> <usetemplate ignoretext="Confirm before I mute all participants in a group call" name="okcancelignore" @@ -6618,6 +7012,7 @@ Mute everyone? <notification name="HintSit" + label="Stand" type="hint" unique="true"> @@ -6633,14 +7028,6 @@ Mute everyone? </notification> <notification - name="HintAvatarPicker" - label="Change your Look" - type="hint" - unique="true"> - Would you like to try a new look? Click the button below to see more Avatars. - </notification> - - <notification name="HintSidePanel" label="Side Panel" type="hint" @@ -6696,6 +7083,7 @@ Mute everyone? type="hint" unique="true"> Here's your current balance of L$. Click Buy L$ to purchase more Linden Dollars. + <tag>funds</tag> </notification> <notification @@ -6719,6 +7107,7 @@ Mute everyone? name="AuthRequest" type="browser"> The site at '<nolink>[HOST_NAME]</nolink>' in realm '[REALM]' requires a user name and password. + <tag>confirm</tag> <form name="form"> <input name="username" type="text" text="User Name"/> <input name="password" type="password" text="Password "/> @@ -6732,15 +7121,116 @@ The site at '<nolink>[HOST_NAME]</nolink>' in realm ' </form> </notification> - - <global name="UnsupportedCPU"> -- Your CPU speed does not meet the minimum requirements. - </global> + <notification + name="ModeChange" + label="" + type="alertmodal" + unique="true"> + Changing modes requires you to quit and restart. + <tag>confirm</tag> + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> - <global name="UnsupportedCPUSSE2"> -Your CPU does not seem to have the required support for SSE2 operations. + <notification + name="NoClassifieds" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Creation and editing of Classifieds is only available in Advanced mode. Would you like to quit and change modes? The mode selector can be found on the login screen. + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> + + <notification + name="NoGroupInfo" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Creation and editing of Groups is only available in Advanced mode. Would you like to quit and change modes? The mode selector can be found on the login screen. + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> + + <notification + name="NoPicks" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Creation and editing of Picks is only available in Advanced mode. Would you like to quit and change modes? The mode selector can be found on the login screen. + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> + + <notification + name="NoWorldMap" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Viewing of the world map is only available in Advanced mode. Would you like to quit and change modes? The mode selector can be found on the login screen. + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> -Please see http://www.secondlife.com/corporate/sysreqs.php for information about system requirements. + <notification + name="NoVoiceCall" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Voice calls are only available in Advanced mode. Would you like to logout and change modes? + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> + + <notification + name="NoAvatarShare" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Sharing is only available in Advanced mode. Would you like to logout and change modes? + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> + + <notification + name="NoAvatarPay" + label="" + type="alertmodal" + unique="true"> + <tag>fail</tag> + <tag>confirm</tag> + Paying other residents is only available in Advanced mode. Would you like to logout and change modes? + <usetemplate + name="okcancelbuttons" + yestext="Quit" + notext="Don't Quit"/> + </notification> </global> <global name="UnsupportedGLRequirements"> diff --git a/indra/newview/skins/default/xui/en/panel_login.xml b/indra/newview/skins/default/xui/en/panel_login.xml index 806182bcb4..4c2faddfe4 100644 --- a/indra/newview/skins/default/xui/en/panel_login.xml +++ b/indra/newview/skins/default/xui/en/panel_login.xml @@ -47,8 +47,8 @@ auto_resize="false" follows="left|bottom" name="login" layout="topleft" -width="695" -min_width="695" +width="705" +min_width="705" user_resize="false" height="80"> <text @@ -67,8 +67,7 @@ follows="left|bottom" height="22" left_delta="0" max_chars="128" -prevalidate_callback="ascii" -select_on_focus="true" +combo_editor.prevalidate_callback="ascii" tool_tip="The username you chose when you registered, like bobsmith12 or Steller Sunshine" top_pad="0" name="username_combo" @@ -118,13 +117,41 @@ label="Remember password" name="connect_btn" top="35" width="90" /> + <text + follows="left|bottom" + font="SansSerifSmall" + height="15" + left_pad="10" + name="mode_selection_text" + top="20" + width="130"> + Mode: + </text> +<combo_box + follows="left|bottom" + height="23" + max_chars="128" + tool_tip="Select your mode. Choose Basic for fast, easy exploration and chat. Choose Advanced to access more features." + top_pad="0" + control_name="SessionSettingsFile" + name="mode_combo" + width="110"> +<combo_box.item + label="Basic" + name="Basic" + value="settings_minimal.xml" /> +<combo_box.item + label="Advanced" + name="Advanced" + value="" /> +</combo_box> <text follows="left|bottom" font="SansSerifSmall" height="15" - left_pad="18" + left_pad="8" name="start_location_text" -top="20" + top="20" width="130"> Start at: </text> @@ -136,7 +163,7 @@ control_name="NextLoginLocation" max_chars="128" top_pad="0" name="start_location_combo" - width="170"> + width="165"> <combo_box.item label="My last location" name="MyLastLocation" diff --git a/indra/newview/skins/minimal/colors.xml b/indra/newview/skins/minimal/colors.xml new file mode 100644 index 0000000000..097a298ce5 --- /dev/null +++ b/indra/newview/skins/minimal/colors.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<colors> + <color + name="MenuBarBgColor" + value="0 0 0 0" /> +</colors> diff --git a/indra/newview/skins/minimal/textures/arrow_keys.png b/indra/newview/skins/minimal/textures/arrow_keys.png Binary files differnew file mode 100644 index 0000000000..f19af59251 --- /dev/null +++ b/indra/newview/skins/minimal/textures/arrow_keys.png diff --git a/indra/newview/skins/minimal/textures/bottomtray/button_separator.png b/indra/newview/skins/minimal/textures/bottomtray/button_separator.png Binary files differnew file mode 100644 index 0000000000..71ed25f931 --- /dev/null +++ b/indra/newview/skins/minimal/textures/bottomtray/button_separator.png diff --git a/indra/newview/skins/minimal/textures/bottomtray/close_off.png b/indra/newview/skins/minimal/textures/bottomtray/close_off.png Binary files differnew file mode 100644 index 0000000000..241a24bde9 --- /dev/null +++ b/indra/newview/skins/minimal/textures/bottomtray/close_off.png diff --git a/indra/newview/skins/minimal/textures/bottomtray/close_over.png b/indra/newview/skins/minimal/textures/bottomtray/close_over.png Binary files differnew file mode 100644 index 0000000000..4630cb6dd6 --- /dev/null +++ b/indra/newview/skins/minimal/textures/bottomtray/close_over.png diff --git a/indra/newview/skins/minimal/textures/bottomtray/close_press.png b/indra/newview/skins/minimal/textures/bottomtray/close_press.png Binary files differnew file mode 100644 index 0000000000..3ed9c99a26 --- /dev/null +++ b/indra/newview/skins/minimal/textures/bottomtray/close_press.png diff --git a/indra/newview/skins/minimal/textures/textures.xml b/indra/newview/skins/minimal/textures/textures.xml new file mode 100644 index 0000000000..3e2f5cd397 --- /dev/null +++ b/indra/newview/skins/minimal/textures/textures.xml @@ -0,0 +1,8 @@ + +<textures version="101"> + <texture name="Button_Separator" file_name="bottomtray/button_separator.png" preload="true" /> + <texture name="arrow_keys.png"/> + <texture name="bottomtray_close_off" file_name="bottomtray/close_off.png" preload="true" /> + <texture name="bottomtray_close_over" file_name="bottomtray/close_over.png" preload="true" /> + <texture name="bottomtray_close_press" file_name="bottomtray/close_press.png" preload="true" /> +</textures> diff --git a/indra/newview/skins/minimal/xui/de/floater_camera.xml b/indra/newview/skins/minimal/xui/de/floater_camera.xml new file mode 100644 index 0000000000..d49c207f98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/floater_camera.xml @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="camera_floater"> + <floater.string name="rotate_tooltip"> + Kamera um Fokus drehen + </floater.string> + <floater.string name="zoom_tooltip"> + Kamera auf Fokus zoomen + </floater.string> + <floater.string name="move_tooltip"> + Kamera nach oben, unten, links und rechts bewegen + </floater.string> + <floater.string name="camera_modes_title"> + Kameramodi + </floater.string> + <floater.string name="pan_mode_title"> + Kreisen - Zoomen - Schwenken + </floater.string> + <floater.string name="presets_mode_title"> + Ansichten + </floater.string> + <floater.string name="free_mode_title"> + Objekt ansehen + </floater.string> + <panel name="controls"> + <panel name="preset_views_list"> + <panel_camera_item name="front_view"> + <panel_camera_item.text name="front_view_text"> + Vorderansicht + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="group_view"> + <panel_camera_item.text name="side_view_text"> + Seitenansicht + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="rear_view"> + <panel_camera_item.text name="rear_view_text"> + Hinteransicht + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="camera_modes_list"> + <panel_camera_item name="object_view"> + <panel_camera_item.text name="object_view_text"> + Objektansicht + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="mouselook_view"> + <panel_camera_item.text name="mouselook_view_text"> + Mouselook + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="zoom" tool_tip="Kamera auf Fokus zoomen"> + <joystick_rotate name="cam_rotate_stick" tool_tip="Kamera um Fokus kreisen"/> + <slider_bar name="zoom_slider" tool_tip="Kamera auf Fokus zoomen"/> + <joystick_track name="cam_track_stick" tool_tip="Kamera nach oben, unten, links und rechts bewegen"/> + </panel> + </panel> + <panel name="buttons"> + <button label="" name="presets_btn" tool_tip="Ansichten"/> + <button label="" name="pan_btn" tool_tip="Kreisen - Zoomen - Schwenken"/> + <button label="" name="avatarview_btn" tool_tip="Kameramodi"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/de/floater_help_browser.xml b/indra/newview/skins/minimal/xui/de/floater_help_browser.xml new file mode 100644 index 0000000000..459dfb66c0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/floater_help_browser.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="floater_help_browser" title="ANWEISUNGEN"> + <floater.string name="loading_text"> + Wird geladen... + </floater.string> + <layout_stack name="stack1"> + <layout_panel name="external_controls"/> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/de/floater_nearby_chat.xml b/indra/newview/skins/minimal/xui/de/floater_nearby_chat.xml new file mode 100644 index 0000000000..bbb4114200 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/floater_nearby_chat.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="nearby_chat" title="CHAT IN DER NÄHE"> + <check_box label="Chat übersetzen (Service von Google)" name="translate_chat_checkbox"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/de/inspect_avatar.xml b/indra/newview/skins/minimal/xui/de/inspect_avatar.xml new file mode 100644 index 0000000000..4b8fd8a0ad --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/inspect_avatar.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_avatar"> + <string name="Subtitle"> + [AGE] + </string> + <string name="Details"> + [SL_PROFILE] + </string> + <text name="user_subtitle" value="11 Monate und 3 Tage alt"/> + <text name="user_details"> + Dies ist meine Second Life-Beschreibung und ich finde sie wirklich gut! Meine Beschreibung ist deshalb so lang, weil ich gerne rede. + </text> + <slider name="volume_slider" tool_tip="Lautstärke" value="0.5"/> + <button label="Freund hinzufügen" name="add_friend_btn" width="110"/> + <button label="IM" name="im_btn"/> + <button label="Profil" left_delta="120" name="view_profile_btn" width="44"/> + <panel name="moderator_panel"> + <button label="Voice deaktivieren" name="disable_voice"/> + <button label="Voice aktivieren" name="enable_voice"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/de/inspect_object.xml b/indra/newview/skins/minimal/xui/de/inspect_object.xml new file mode 100644 index 0000000000..72b8235828 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/inspect_object.xml @@ -0,0 +1,48 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_object"> + <string name="Creator"> + Von [CREATOR] + </string> + <string name="CreatorAndOwner"> + Von [CREATOR] +Besitzer [OWNER] + </string> + <string name="Price"> + [AMOUNT] L$ + </string> + <string name="PriceFree"> + Kostenlos! + </string> + <string name="Touch"> + Berühren + </string> + <string name="Sit"> + Sitzen + </string> + <text name="object_name" value="Test für ein Objektname der sehr lange ist und über zwei Zeilen geht."/> + <text name="object_creator"> + von secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about +Besitzer secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about + </text> + <text name="price_text"> + 30.000 L$ + </text> + <text name="object_description"> + Dies ist eine wirklich lange Beschreibung für ein Objekt, mindestens 80 Zeichen lang oder jetzt schon mindestens 120 Zeichen lang und länger als der englische Originaltext. Niemand weiß es genau. + </text> + <text name="object_media_url"> + http://www.superdupertest.com + </text> + <button label="Kaufen" name="buy_btn"/> + <button label="Bezahlen" name="pay_btn"/> + <button label="Kopie nehmen" name="take_free_copy_btn" width="100"/> + <button label="Berühren" name="touch_btn"/> + <button label="Sitzen" name="sit_btn"/> + <button label="Öffnen" name="open_btn"/> + <icon name="secure_browsing" tool_tip="Sicheres Browsen"/> + <button label="Mehr" name="more_info_btn"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/de/menu_add_wearable_gear.xml b/indra/newview/skins/minimal/xui/de/menu_add_wearable_gear.xml new file mode 100644 index 0000000000..f3775a05ec --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_add_wearable_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Add Wearable Gear Menu"> + <menu_item_check label="Nach aktuellesten Objekten sortieren" name="sort_by_most_recent"/> + <menu_item_check label="Nach Name sortieren" name="sort_by_name"/> + <menu_item_check label="Nach Typ sortieren" name="sort_by_type"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_attachment_other.xml b/indra/newview/skins/minimal/xui/de/menu_attachment_other.xml new file mode 100644 index 0000000000..237c92f7d2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_attachment_other.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_avatar_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Profil anzeigen" name="Profile..."/> + <menu_item_call label="Freund hinzufügen" name="Add Friend"/> + <menu_item_call label="IM" name="Send IM..."/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="In Gruppe einladen" name="Invite..."/> + <menu_item_call label="Ignorieren" name="Avatar Mute"/> + <menu_item_call label="Melden" name="abuse"/> + <menu_item_call label="Einfrieren" name="Freeze..."/> + <menu_item_call label="Hinauswerfen" name="Eject..."/> + <menu_item_call label="Fehler in Texturen beseitigen" name="Debug..."/> + <menu_item_call label="Hineinzoomen" name="Zoom In"/> + <menu_item_call label="Bezahlen" name="Pay..."/> + <menu_item_call label="Objektprofil" name="Object Inspect"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_attachment_self.xml b/indra/newview/skins/minimal/xui/de/menu_attachment_self.xml new file mode 100644 index 0000000000..644fc68ba4 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_attachment_self.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Attachment Pie"> + <menu_item_call label="Berühren" name="Attachment Object Touch"/> + <menu_item_call label="Bearbeiten" name="Edit..."/> + <menu_item_call label="Abnehmen" name="Detach"/> + <menu_item_call label="Hinsetzen" name="Sit Down Here"/> + <menu_item_call label="Aufstehen" name="Stand Up"/> + <menu_item_call label="Outfit ändern" name="Change Outfit"/> + <menu_item_call label="Mein Outfit bearbeiten" name="Edit Outfit"/> + <menu_item_call label="Meine Form bearbeiten" name="Edit My Shape"/> + <menu_item_call label="Meine Freunde" name="Friends..."/> + <menu_item_call label="Meine Gruppen" name="Groups..."/> + <menu_item_call label="Mein Profil" name="Profile..."/> + <menu_item_call label="Fehler in Texturen beseitigen" name="Debug..."/> + <menu_item_call label="Fallen lassen" name="Drop"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_avatar_icon.xml b/indra/newview/skins/minimal/xui/de/menu_avatar_icon.xml new file mode 100644 index 0000000000..c036cf5515 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_avatar_icon.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Avatar Icon Menu"> + <menu_item_call label="Profil anzeigen" name="Show Profile"/> + <menu_item_call label="IM senden..." name="Send IM"/> + <menu_item_call label="Freund hinzufügen..." name="Add Friend"/> + <menu_item_call label="Freund entfernen..." name="Remove Friend"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_avatar_other.xml b/indra/newview/skins/minimal/xui/de/menu_avatar_other.xml new file mode 100644 index 0000000000..8aee0be3d2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_avatar_other.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_attachment_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Profil anzeigen" name="Profile..."/> + <menu_item_call label="Freund hinzufügen" name="Add Friend"/> + <menu_item_call label="IM" name="Send IM..."/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="In Gruppe einladen" name="Invite..."/> + <menu_item_call label="Ignorieren" name="Avatar Mute"/> + <menu_item_call label="Melden" name="abuse"/> + <menu_item_call label="Einfrieren" name="Freeze..."/> + <menu_item_call label="Hinauswerfen" name="Eject..."/> + <menu_item_call label="Fehler in Texturen beseitigen" name="Debug..."/> + <menu_item_call label="Hineinzoomen" name="Zoom In"/> + <menu_item_call label="Bezahlen" name="Pay..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_avatar_self.xml b/indra/newview/skins/minimal/xui/de/menu_avatar_self.xml new file mode 100644 index 0000000000..582c76ac94 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_avatar_self.xml @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Self Pie"> + <menu_item_call label="Hinsetzen" name="Sit Down Here"/> + <menu_item_call label="Aufstehen" name="Stand Up"/> + <context_menu label="Ausziehen" name="Take Off >"> + <context_menu label="Kleidung" name="Clothes >"> + <menu_item_call label="Hemd" name="Shirt"/> + <menu_item_call label="Hose" name="Pants"/> + <menu_item_call label="Rock" name="Skirt"/> + <menu_item_call label="Schuhe" name="Shoes"/> + <menu_item_call label="Strümpfe" name="Socks"/> + <menu_item_call label="Jacke" name="Jacket"/> + <menu_item_call label="Handschuhe" name="Gloves"/> + <menu_item_call label="Unterhemd" name="Self Undershirt"/> + <menu_item_call label="Unterhose" name="Self Underpants"/> + <menu_item_call label="Tätowierung" name="Self Tattoo"/> + <menu_item_call label="Alpha" name="Self Alpha"/> + <menu_item_call label="Alle Kleider" name="All Clothes"/> + </context_menu> + <context_menu label="HUD" name="Object Detach HUD"/> + <context_menu label="Abnehmen" name="Object Detach"/> + <menu_item_call label="Alles abnehmen" name="Detach All"/> + </context_menu> + <menu_item_call label="Outfit ändern" name="Chenge Outfit"/> + <menu_item_call label="Mein Outfit bearbeiten" name="Edit Outfit"/> + <menu_item_call label="Meine Form bearbeiten" name="Edit My Shape"/> + <menu_item_call label="Meine Freunde" name="Friends..."/> + <menu_item_call label="Meine Gruppen" name="Groups..."/> + <menu_item_call label="Mein Profil" name="Profile..."/> + <menu_item_call label="Fehler in Texturen beseitigen" name="Debug..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_bottomtray.xml b/indra/newview/skins/minimal/xui/de/menu_bottomtray.xml new file mode 100644 index 0000000000..6c4308286a --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_bottomtray.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_camera_move_controls_menu"> + <menu_item_check label="Schaltfläche Gesten" name="ShowGestureButton"/> + <menu_item_check label="Schaltfläche Bewegungssteuerung" name="ShowMoveButton"/> + <menu_item_check label="Schaltfläche Ansicht" name="ShowCameraButton"/> + <menu_item_check label="Schaltfläche Foto" name="ShowSnapshotButton"/> + <menu_item_check label="Schaltfläche „Seitenleiste“" name="ShowSidebarButton"/> + <menu_item_check label="Schaltfläche „Bauen“" name="ShowBuildButton"/> + <menu_item_check label="Schaltfläche „Suchen“" name="ShowSearchButton"/> + <menu_item_check label="Schaltfläche „Karte“" name="ShowWorldMapButton"/> + <menu_item_check label="Schaltfläche „Minikarte“" name="ShowMiniMapButton"/> + <menu_item_call label="Ausschneiden" name="NearbyChatBar_Cut"/> + <menu_item_call label="Kopieren" name="NearbyChatBar_Copy"/> + <menu_item_call label="Einfügen" name="NearbyChatBar_Paste"/> + <menu_item_call label="Löschen" name="NearbyChatBar_Delete"/> + <menu_item_call label="Alle auswählen" name="NearbyChatBar_Select_All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_cof_attachment.xml b/indra/newview/skins/minimal/xui/de/menu_cof_attachment.xml new file mode 100644 index 0000000000..05d3dfca9d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_cof_attachment.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Attachment"> + <menu_item_call label="Abnehmen" name="detach"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_cof_body_part.xml b/indra/newview/skins/minimal/xui/de/menu_cof_body_part.xml new file mode 100644 index 0000000000..07960a525c --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_cof_body_part.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Body"> + <menu_item_call label="Ersetzen" name="replace"/> + <menu_item_call label="Bearbeiten" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_cof_clothing.xml b/indra/newview/skins/minimal/xui/de/menu_cof_clothing.xml new file mode 100644 index 0000000000..7fced273a7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_cof_clothing.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Clothing"> + <menu_item_call label="Ausziehen" name="take_off"/> + <menu_item_call label="Ersetzen" name="replace"/> + <menu_item_call label="Eine Kategorie nach oben" name="move_up"/> + <menu_item_call label="Eine Kategorie nach unten" name="move_down"/> + <menu_item_call label="Bearbeiten" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_cof_gear.xml b/indra/newview/skins/minimal/xui/de/menu_cof_gear.xml new file mode 100644 index 0000000000..54b218d22f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_cof_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear COF"> + <menu label="Neue Kleider" name="COF.Gear.New_Clothes"/> + <menu label="Neue Körperteile" name="COF.Geear.New_Body_Parts"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_edit.xml b/indra/newview/skins/minimal/xui/de/menu_edit.xml new file mode 100644 index 0000000000..37f68d68d5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_edit.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu label="Bearbeiten" name="Edit"> + <menu_item_call label="Rückgängig" name="Undo"/> + <menu_item_call label="Wiederherstellen" name="Redo"/> + <menu_item_call label="Ausschneiden" name="Cut"/> + <menu_item_call label="Kopieren" name="Copy"/> + <menu_item_call label="Einfügen" name="Paste"/> + <menu_item_call label="Löschen" name="Delete"/> + <menu_item_call label="Duplizieren" name="Duplicate"/> + <menu_item_call label="Alle auswählen" name="Select All"/> + <menu_item_call label="Auswahl aufheben" name="Deselect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_favorites.xml b/indra/newview/skins/minimal/xui/de/menu_favorites.xml new file mode 100644 index 0000000000..0d0491d2eb --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_favorites.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Teleportieren" name="Teleport To Landmark"/> + <menu_item_call label="Landmarken anzeigen/bearbeiten" name="Landmark Open"/> + <menu_item_call label="SLurl kopieren" name="Copy slurl"/> + <menu_item_call label="Auf Karte zeigen" name="Show On Map"/> + <menu_item_call label="Kopieren" name="Landmark Copy"/> + <menu_item_call label="Einfügen" name="Landmark Paste"/> + <menu_item_call label="Löschen" name="Delete"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_gesture_gear.xml b/indra/newview/skins/minimal/xui/de/menu_gesture_gear.xml new file mode 100644 index 0000000000..953c0eeed5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_gesture_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_gesture_gear"> + <menu_item_call label="Zu Favoriten hinzufügen/daraus entfernen" name="activate"/> + <menu_item_call label="Kopieren" name="copy_gesture"/> + <menu_item_call label="Einfügen" name="paste"/> + <menu_item_call label="UUID kopieren" name="copy_uuid"/> + <menu_item_call label="Aktuelles Outfit speichern" name="save_to_outfit"/> + <menu_item_call label="Bearbeiten" name="edit_gesture"/> + <menu_item_call label="Untersuchen" name="inspect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_group_plus.xml b/indra/newview/skins/minimal/xui/de/menu_group_plus.xml new file mode 100644 index 0000000000..583ee793be --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_group_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Werden Sie Mitglied..." name="item_join"/> + <menu_item_call label="Neue Gruppe..." name="item_new"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_hide_navbar.xml b/indra/newview/skins/minimal/xui/de/menu_hide_navbar.xml new file mode 100644 index 0000000000..9acf96dc6d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_hide_navbar.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_navbar_menu"> + <menu_item_check label="Navigationsleiste anzeigen" name="ShowNavbarNavigationPanel"/> + <menu_item_check label="Favoritenleiste anzeigen" name="ShowNavbarFavoritesPanel"/> + <menu_item_check label="Mini-Standortleiste anzeigen" name="ShowMiniLocationPanel"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_im_well_button.xml b/indra/newview/skins/minimal/xui/de/menu_im_well_button.xml new file mode 100644 index 0000000000..f464b71f4a --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_im_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="IM Well Button Context Menu"> + <menu_item_call label="Alle schließen" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_imchiclet_adhoc.xml b/indra/newview/skins/minimal/xui/de/menu_imchiclet_adhoc.xml new file mode 100644 index 0000000000..11f93f47b4 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_imchiclet_adhoc.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet AdHoc Menu"> + <menu_item_call label="Sitzung beenden" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_imchiclet_group.xml b/indra/newview/skins/minimal/xui/de/menu_imchiclet_group.xml new file mode 100644 index 0000000000..81ef3b6569 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_imchiclet_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet Group Menu"> + <menu_item_call label="Gruppeninfo" name="Show Profile"/> + <menu_item_call label="Sitzung anzeigen" name="Chat"/> + <menu_item_call label="Sitzung beenden" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_imchiclet_p2p.xml b/indra/newview/skins/minimal/xui/de/menu_imchiclet_p2p.xml new file mode 100644 index 0000000000..d123238246 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_imchiclet_p2p.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet P2P Menu"> + <menu_item_call label="Profil anzeigen" name="Show Profile"/> + <menu_item_call label="Freund hinzufügen" name="Add Friend"/> + <menu_item_call label="Sitzung anzeigen" name="Send IM"/> + <menu_item_call label="Sitzung beenden" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inspect_avatar_gear.xml b/indra/newview/skins/minimal/xui/de/menu_inspect_avatar_gear.xml new file mode 100644 index 0000000000..fbc119c483 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inspect_avatar_gear.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu name="Gear Menu"> + <menu_item_call label="Profil anzeigen" name="view_profile"/> + <menu_item_call label="Freund hinzufügen" name="add_friend"/> + <menu_item_call label="IM" name="im"/> + <menu_item_call label="Teleportieren" name="teleport"/> + <menu_item_call label="Ignorieren" name="block"/> + <menu_item_call label="Freischalten" name="unblock"/> + <menu_item_call label="Melden" name="report"/> + <menu_item_call label="Einfrieren" name="freeze"/> + <menu_item_call label="Hinauswerfen" name="eject"/> + <menu_item_call label="Hinauswerfen" name="kick"/> + <menu_item_call label="CSR" name="csr"/> + <menu_item_call label="Fehler in Texturen beseitigen" name="debug"/> + <menu_item_call label="Auf Karte anzeigen" name="find_on_map"/> + <menu_item_call label="Hineinzoomen" name="zoom_in"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inspect_object_gear.xml b/indra/newview/skins/minimal/xui/de/menu_inspect_object_gear.xml new file mode 100644 index 0000000000..7c47913e30 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inspect_object_gear.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Berühren" name="touch"/> + <menu_item_call label="Sitzen" name="sit"/> + <menu_item_call label="Bezahlen" name="pay"/> + <menu_item_call label="Kaufen" name="buy"/> + <menu_item_call label="Nehmen" name="take"/> + <menu_item_call label="Kopie nehmen" name="take_copy"/> + <menu_item_call label="Öffnen" name="open"/> + <menu_item_call label="Bearbeiten" name="edit"/> + <menu_item_call label="Anziehen" name="wear"/> + <menu_item_call label="Hinzufügen" name="add"/> + <menu_item_call label="Melden" name="report"/> + <menu_item_call label="Ignorieren" name="block"/> + <menu_item_call label="Hineinzoomen" name="zoom_in"/> + <menu_item_call label="Entfernen" name="remove"/> + <menu_item_call label="Weitere Infos" name="more_info"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inspect_self_gear.xml b/indra/newview/skins/minimal/xui/de/menu_inspect_self_gear.xml new file mode 100644 index 0000000000..851a96cc09 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inspect_self_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Hinsetzen" name="sit_down_here"/> + <menu_item_call label="Aufstehen" name="stand_up"/> + <menu_item_call label="Outfit ändern" name="change_outfit"/> + <menu_item_call label="Mein Profil" name="my_profile"/> + <menu_item_call label="Meine Freunde" name="my_friends"/> + <menu_item_call label="Meine Gruppen" name="my_groups"/> + <menu_item_call label="Fehler in Texturen beseitigen" name="Debug..."/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inv_offer_chiclet.xml b/indra/newview/skins/minimal/xui/de/menu_inv_offer_chiclet.xml new file mode 100644 index 0000000000..71cff7136b --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inv_offer_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="InvOfferChiclet Menu"> + <menu_item_call label="Schließen" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inventory.xml b/indra/newview/skins/minimal/xui/de/menu_inventory.xml new file mode 100644 index 0000000000..43722e0dcf --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inventory.xml @@ -0,0 +1,86 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Teilen" name="Share"/> + <menu_item_call label="Kaufen" name="Task Buy"/> + <menu_item_call label="Öffnen" name="Task Open"/> + <menu_item_call label="Abspielen" name="Task Play"/> + <menu_item_call label="Eigenschaften" name="Task Properties"/> + <menu_item_call label="Umbenennen" name="Task Rename"/> + <menu_item_call label="Löschen" name="Task Remove"/> + <menu_item_call label="Papierkorb ausleeren" name="Empty Trash"/> + <menu_item_call label="Fundstücke ausleeren" name="Empty Lost And Found"/> + <menu_item_call label="Neuer Ordner" name="New Folder"/> + <menu_item_call label="Neues Skript" name="New Script"/> + <menu_item_call label="Neue Notizkarte" name="New Note"/> + <menu_item_call label="Neue Geste" name="New Gesture"/> + <menu label="Neue Kleider" name="New Clothes"> + <menu_item_call label="Neues Hemd" name="New Shirt"/> + <menu_item_call label="Neue Hose" name="New Pants"/> + <menu_item_call label="Neue Schuhe" name="New Shoes"/> + <menu_item_call label="Neue Socken" name="New Socks"/> + <menu_item_call label="Neue Jacke" name="New Jacket"/> + <menu_item_call label="Neuer Rock" name="New Skirt"/> + <menu_item_call label="Neue Handschuhe" name="New Gloves"/> + <menu_item_call label="Neues Unterhemd" name="New Undershirt"/> + <menu_item_call label="Neue Unterhose" name="New Underpants"/> + <menu_item_call label="Neue Alpha-Maske" name="New Alpha Mask"/> + <menu_item_call label="Neue Tätowierung" name="New Tattoo"/> + </menu> + <menu label="Neue Körperteile" name="New Body Parts"> + <menu_item_call label="Neue Form/Gestalt" name="New Shape"/> + <menu_item_call label="Neue Haut" name="New Skin"/> + <menu_item_call label="Neues Haar" name="New Hair"/> + <menu_item_call label="Neue Augen" name="New Eyes"/> + </menu> + <menu label="Typ ändern" name="Change Type"> + <menu_item_call label="Standard" name="Default"/> + <menu_item_call label="Handschuhe" name="Gloves"/> + <menu_item_call label="Jacke" name="Jacket"/> + <menu_item_call label="Hose" name="Pants"/> + <menu_item_call label="Form" name="Shape"/> + <menu_item_call label="Schuhe" name="Shoes"/> + <menu_item_call label="Hemd" name="Shirt"/> + <menu_item_call label="Rock" name="Skirt"/> + <menu_item_call label="Unterhose" name="Underpants"/> + <menu_item_call label="Unterhemd" name="Undershirt"/> + </menu> + <menu_item_call label="Teleportieren" name="Landmark Open"/> + <menu_item_call label="Öffnen" name="Animation Open"/> + <menu_item_call label="Öffnen" name="Sound Open"/> + <menu_item_call label="Aktuelles Outfit ersetzen" name="Replace Outfit"/> + <menu_item_call label="Zum aktuellen Outfit hinzufügen" name="Add To Outfit"/> + <menu_item_call label="Vom aktuellen Outfit entfernen" name="Remove From Outfit"/> + <menu_item_call label="Original suchen" name="Find Original"/> + <menu_item_call label="Objekt löschen" name="Purge Item"/> + <menu_item_call label="Objekt wiederherstellen" name="Restore Item"/> + <menu_item_call label="Öffnen" name="Open"/> + <menu_item_call label="Original öffnen" name="Open Original"/> + <menu_item_call label="Eigenschaften" name="Properties"/> + <menu_item_call label="Umbenennen" name="Rename"/> + <menu_item_call label="Asset-UUID kopieren" name="Copy Asset UUID"/> + <menu_item_call label="Kopieren" name="Copy"/> + <menu_item_call label="Einfügen" name="Paste"/> + <menu_item_call label="Als Link einfügen" name="Paste As Link"/> + <menu_item_call label="Löschen" name="Remove Link"/> + <menu_item_call label="Löschen" name="Delete"/> + <menu_item_call label="Systemordner löschen" name="Delete System Folder"/> + <menu_item_call label="Konferenz-Chat starten" name="Conference Chat Folder"/> + <menu_item_call label="Wiedergeben/Abspielen" name="Sound Play"/> + <menu_item_call label="Landmarken-Info" name="About Landmark"/> + <menu_item_call label="Inworld abspielen" name="Animation Play"/> + <menu_item_call label="Lokal abspielen" name="Animation Audition"/> + <menu_item_call label="Instant Message senden" name="Send Instant Message"/> + <menu_item_call label="Teleport anbieten..." name="Offer Teleport..."/> + <menu_item_call label="Konferenz-Chat starten" name="Conference Chat"/> + <menu_item_call label="Aktivieren" name="Activate"/> + <menu_item_call label="Deaktivieren" name="Deactivate"/> + <menu_item_call label="Speichern unter" name="Save As"/> + <menu_item_call label="Von Körper abnehmen" name="Detach From Yourself"/> + <menu_item_call label="Anziehen" name="Wearable And Object Wear"/> + <menu label="Anhängen an" name="Attach To"/> + <menu label="An HUD hängen" name="Attach To HUD"/> + <menu_item_call label="Bearbeiten" name="Wearable Edit"/> + <menu_item_call label="Hinzufügen" name="Wearable Add"/> + <menu_item_call label="Ausziehen" name="Take Off"/> + <menu_item_call label="--keine Optionen--" name="--no options--"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inventory_add.xml b/indra/newview/skins/minimal/xui/de/menu_inventory_add.xml new file mode 100644 index 0000000000..dccee6712d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inventory_add.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_inventory_add"> + <menu label="Hochladen" name="upload"> + <menu_item_call label="Bild ([COST] L$)..." name="Upload Image"/> + <menu_item_call label="Sound ([COST] L$)..." name="Upload Sound"/> + <menu_item_call label="Animation ([COST] L$)..." name="Upload Animation"/> + <menu_item_call label="Mehrfach-Upload ([COST] L$ pro Datei)..." name="Bulk Upload"/> + <menu_item_call label="Hochlade-Berechtigungen (Standard) festlegen" name="perm prefs"/> + </menu> + <menu_item_call label="Neuer Ordner" name="New Folder"/> + <menu_item_call label="Neues Skript" name="New Script"/> + <menu_item_call label="Neue Notizkarte" name="New Note"/> + <menu_item_call label="Neue Geste" name="New Gesture"/> + <menu label="Neue Kleider" name="New Clothes"> + <menu_item_call label="Neues Hemd" name="New Shirt"/> + <menu_item_call label="Neue Hose" name="New Pants"/> + <menu_item_call label="Neue Schuhe" name="New Shoes"/> + <menu_item_call label="Neue Socken" name="New Socks"/> + <menu_item_call label="Neue Jacke" name="New Jacket"/> + <menu_item_call label="Neuer Rock" name="New Skirt"/> + <menu_item_call label="Neue Handschuhe" name="New Gloves"/> + <menu_item_call label="Neues Unterhemd" name="New Undershirt"/> + <menu_item_call label="Neue Unterhose" name="New Underpants"/> + <menu_item_call label="Neues Alpha" name="New Alpha"/> + <menu_item_call label="Neue Tätowierung" name="New Tattoo"/> + </menu> + <menu label="Neue Körperteile" name="New Body Parts"> + <menu_item_call label="Neue Form/Gestalt" name="New Shape"/> + <menu_item_call label="Neue Haut" name="New Skin"/> + <menu_item_call label="Neues Haar" name="New Hair"/> + <menu_item_call label="Neue Augen" name="New Eyes"/> + </menu> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_inventory_gear_default.xml b/indra/newview/skins/minimal/xui/de/menu_inventory_gear_default.xml new file mode 100644 index 0000000000..df86a5cf71 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_inventory_gear_default.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="menu_gear_default"> + <menu_item_call label="Neues Inventar-Fenster" name="new_window"/> + <menu_item_check label="Nach Name sortieren" name="sort_by_name"/> + <menu_item_check label="Nach aktuellesten Objekten sortieren" name="sort_by_recent"/> + <menu_item_check label="Systemordner nach oben" name="sort_system_folders_to_top"/> + <menu_item_call label="Filter anzeigen" name="show_filters"/> + <menu_item_call label="Filter zurücksetzen" name="reset_filters"/> + <menu_item_call label="Alle Ordner schließen" name="close_folders"/> + <menu_item_call label="Fundbüro ausleeren" name="empty_lostnfound"/> + <menu_item_call label="Textur speichern als" name="Save Texture As"/> + <menu_item_call label="Teilen" name="Share"/> + <menu_item_call label="Original suchen" name="Find Original"/> + <menu_item_call label="Alle Links suchen" name="Find All Links"/> + <menu_item_call label="Papierkorb ausleeren" name="empty_trash"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_land.xml b/indra/newview/skins/minimal/xui/de/menu_land.xml new file mode 100644 index 0000000000..de679da3d8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_land.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Land Pie"> + <menu_item_call label="Land-Info" name="Place Information..."/> + <menu_item_call label="Hier sitzen" name="Sit Here"/> + <menu_item_call label="Dieses Land kaufen" name="Land Buy"/> + <menu_item_call label="Pass kaufen" name="Land Buy Pass"/> + <menu_item_call label="Bauen" name="Create"/> + <menu_item_call label="Land bearbeiten" name="Edit Terrain"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_landmark.xml b/indra/newview/skins/minimal/xui/de/menu_landmark.xml new file mode 100644 index 0000000000..2aff0eec95 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_landmark.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="landmark_overflow_menu"> + <menu_item_call label="SLurl kopieren" name="copy"/> + <menu_item_call label="Löschen" name="delete"/> + <menu_item_call label="Auswahl erstellen" name="pick"/> + <menu_item_call label="Zu Favoritenleiste hinzufügen" name="add_to_favbar"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_login.xml b/indra/newview/skins/minimal/xui/de/menu_login.xml new file mode 100644 index 0000000000..a373e15338 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_login.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Login Menu"> + <menu label="Ich" name="File"> + <menu_item_call label="Einstellungen" name="Preferences..."/> + <menu_item_call label="[APP_NAME] schließen" name="Quit"/> + </menu> + <menu label="Hilfe" name="Help"> + <menu_item_call label="[SECOND_LIFE]-Hilfe" name="Second Life Help"/> + <menu_item_call label="INFO ÜBER [APP_NAME]" name="About Second Life"/> + </menu> + <menu_item_check label="Debug-Menü anzeigen" name="Show Debug Menu"/> + <menu label="Debug" name="Debug"> + <menu_item_call label="Debug-Einstellungen anzeigen" name="Debug Settings"/> + <menu_item_call label="UI/Farb-Einstellungen" name="UI/Color Settings"/> + <menu_item_call label="XUI-Editor" name="UI Preview Tool"/> + <menu label="UI-Tests" name="UI Tests"/> + <menu_item_call label="Fenstergröße einstellen..." name="Set Window Size..."/> + <menu_item_call label="Servicebedingungen anzeigen" name="TOS"/> + <menu_item_call label="Wichtige Meldung anzeigen" name="Critical"/> + <menu_item_call label="Test Medienbrowser" name="Web Browser Test"/> + <menu_item_call label="Test Webinhalt-Floater" name="Web Content Floater Test"/> + <menu_item_check label="Grid-Auswahl anzeigen" name="Show Grid Picker"/> + <menu_item_call label="Benachrichtigungs-Konsole anzeigen" name="Show Notifications Console"/> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/de/menu_mini_map.xml b/indra/newview/skins/minimal/xui/de/menu_mini_map.xml new file mode 100644 index 0000000000..2e0d72c40c --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_mini_map.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Zoom Nah" name="Zoom Close"/> + <menu_item_call label="Zoom Mittel" name="Zoom Medium"/> + <menu_item_call label="Zoom Weit" name="Zoom Far"/> + <menu_item_call label="Zoom-Standard" name="Zoom Default"/> + <menu_item_check label="Karte drehen" name="Rotate Map"/> + <menu_item_check label="Automatisch zentrieren" name="Auto Center"/> + <menu_item_call label="Verfolgung abschalten" name="Stop Tracking"/> + <menu_item_call label="Weltkarte" name="World Map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_navbar.xml b/indra/newview/skins/minimal/xui/de/menu_navbar.xml new file mode 100644 index 0000000000..5175f34b41 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_navbar.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Navbar Menu"> + <menu_item_check label="Koordinaten anzeigen" name="Show Coordinates"/> + <menu_item_check label="Parzelleneigenschaften anzeigen" name="Show Parcel Properties"/> + <menu_item_call label="Landmarke" name="Landmark"/> + <menu_item_call label="Ausschneiden" name="Cut"/> + <menu_item_call label="Kopieren" name="Copy"/> + <menu_item_call label="Einfügen" name="Paste"/> + <menu_item_call label="Löschen" name="Delete"/> + <menu_item_call label="Alle auswählen" name="Select All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_nearby_chat.xml b/indra/newview/skins/minimal/xui/de/menu_nearby_chat.xml new file mode 100644 index 0000000000..99d6428c3f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_nearby_chat.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="NearBy Chat Menu"> + <menu_item_call label="Leute in der Nähe anzeigen..." name="nearby_people"/> + <menu_item_check label="Ignorierten Text anzeigen" name="muted_text"/> + <menu_item_check label="Bilder von Freunden anzeigen" name="show_buddy_icons"/> + <menu_item_check label="Namen anzeigen" name="show_names"/> + <menu_item_check label="Namen und Symbole anzeigen" name="show_icons_and_names"/> + <menu_item_call label="Schriftgröße" name="font_size"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_notification_well_button.xml b/indra/newview/skins/minimal/xui/de/menu_notification_well_button.xml new file mode 100644 index 0000000000..0f2784f160 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_notification_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Notification Well Button Context Menu"> + <menu_item_call label="Alle schließen" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_object.xml b/indra/newview/skins/minimal/xui/de/menu_object.xml new file mode 100644 index 0000000000..19057d4228 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_object.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Object Pie"> + <menu_item_call label="Berühren" name="Object Touch"> + <menu_item_call.on_enable name="EnableTouch" parameter="Berühren"/> + </menu_item_call> + <menu_item_call label="Bearbeiten" name="Edit..."/> + <menu_item_call label="Bauen" name="Build"/> + <menu_item_call label="Öffnen" name="Open"/> + <menu_item_call label="Hier sitzen" name="Object Sit"/> + <menu_item_call label="Aufstehen" name="Object Stand Up"/> + <menu_item_call label="Objektprofil" name="Object Inspect"/> + <menu_item_call label="Hineinzoomen" name="Zoom In"/> + <context_menu label="Anziehen" name="Put On"> + <menu_item_call label="Anziehen" name="Wear"/> + <menu_item_call label="Hinzufügen" name="Add"/> + <context_menu label="Anhängen" name="Object Attach"/> + <context_menu label="HUD anhängen" name="Object Attach HUD"/> + </context_menu> + <context_menu label="Entfernen" name="Remove"> + <menu_item_call label="Missbrauch melden" name="Report Abuse..."/> + <menu_item_call label="Ignorieren" name="Object Mute"/> + <menu_item_call label="Zurückgeben" name="Return..."/> + <menu_item_call label="Löschen" name="Delete"/> + </context_menu> + <menu_item_call label="Nehmen" name="Pie Object Take"/> + <menu_item_call label="Kopie nehmen" name="Take Copy"/> + <menu_item_call label="Bezahlen" name="Pay..."/> + <menu_item_call label="Kaufen" name="Buy..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_object_icon.xml b/indra/newview/skins/minimal/xui/de/menu_object_icon.xml new file mode 100644 index 0000000000..8b6c558416 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_object_icon.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Object Icon Menu"> + <menu_item_call label="Objektprofil..." name="Object Profile"/> + <menu_item_call label="Ignorieren..." name="Block"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_outfit_gear.xml b/indra/newview/skins/minimal/xui/de/menu_outfit_gear.xml new file mode 100644 index 0000000000..897154ec56 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_outfit_gear.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Outfit"> + <menu_item_call label="Anziehen - Aktuelles Outfit ersetzen" name="wear"/> + <menu_item_call label="Anziehen - Aktuelles Outfit hinzufügen" name="wear_add"/> + <menu_item_call label="Ausziehen - Aus aktuellem Outfit entfernen" name="take_off"/> + <menu label="Neue Kleider" name="New Clothes"> + <menu_item_call label="Neues Hemd" name="New Shirt"/> + <menu_item_call label="Neue Hose" name="New Pants"/> + <menu_item_call label="Neue Schuhe" name="New Shoes"/> + <menu_item_call label="Neue Socken" name="New Socks"/> + <menu_item_call label="Neue Jacke" name="New Jacket"/> + <menu_item_call label="Neuer Rock" name="New Skirt"/> + <menu_item_call label="Neue Handschuhe" name="New Gloves"/> + <menu_item_call label="Neues Unterhemd" name="New Undershirt"/> + <menu_item_call label="Neue Unterhose" name="New Underpants"/> + <menu_item_call label="Neues Alpha" name="New Alpha"/> + <menu_item_call label="Neue Tätowierung" name="New Tattoo"/> + </menu> + <menu label="Neue Körperteile" name="New Body Parts"> + <menu_item_call label="Neue Form" name="New Shape"/> + <menu_item_call label="Neue Haut" name="New Skin"/> + <menu_item_call label="Neues Haar" name="New Hair"/> + <menu_item_call label="Neue Augen" name="New Eyes"/> + </menu> + <menu_item_call label="Outfit neu benennen" name="rename"/> + <menu_item_call label="Outfit löschen" name="delete_outfit"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_outfit_tab.xml b/indra/newview/skins/minimal/xui/de/menu_outfit_tab.xml new file mode 100644 index 0000000000..32a65c96fc --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_outfit_tab.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit"> + <menu_item_call label="Anziehen - Aktuelles Outfit ersetzen" name="wear_replace"/> + <menu_item_call label="Anziehen - Aktuelles Outfit hinzufügen" name="wear_add"/> + <menu_item_call label="Ausziehen - Aus aktuellem Outfit entfernen" name="take_off"/> + <menu_item_call label="Outfit bearbeiten" name="edit"/> + <menu_item_call label="Outfit neu benennen" name="rename"/> + <menu_item_call label="Outfit löschen" name="delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_participant_list.xml b/indra/newview/skins/minimal/xui/de/menu_participant_list.xml new file mode 100644 index 0000000000..160f2f97be --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_participant_list.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Participant List Context Menu"> + <menu_item_check label="Nach Name sortieren" name="SortByName"/> + <menu_item_check label="Nach letzten Sprechern sortieren" name="SortByRecentSpeakers"/> + <menu_item_call label="Profil anzeigen" name="View Profile"/> + <menu_item_call label="Freund hinzufügen" name="Add Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="Teilen" name="Share"/> + <menu_item_call label="Bezahlen" name="Pay"/> + <menu_item_check label="Symbole für Personen anzeigen" name="View Icons"/> + <menu_item_check label="Voice ignorieren" name="Block/Unblock"/> + <menu_item_check label="Text ignorieren" name="MuteText"/> + <context_menu label="Moderator-Optionen" name="Moderator Options"> + <menu_item_check label="Text-Chat zulassen" name="AllowTextChat"/> + <menu_item_call label="Diesen Teilnehmer stummschalten" name="ModerateVoiceMuteSelected"/> + <menu_item_call label="Stummschaltung für diesen Teilnehmer aufheben" name="ModerateVoiceUnMuteSelected"/> + <menu_item_call label="Alle stummschalten" name="ModerateVoiceMute"/> + <menu_item_call label="Alle freischalten" name="ModerateVoiceUnmute"/> + </context_menu> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_friends_view_sort.xml b/indra/newview/skins/minimal/xui/de/menu_people_friends_view_sort.xml new file mode 100644 index 0000000000..84d9d8938c --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_friends_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Nach Name sortieren" name="sort_name"/> + <menu_item_check label="Nach Status sortieren" name="sort_status"/> + <menu_item_check label="Symbole für Personen anzeigen" name="view_icons"/> + <menu_item_check label="Erteilte Genehmigungen anzeigen" name="view_permissions"/> + <menu_item_call label="Ignorierte Einwohner & Objekte anzeigen" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_groups.xml b/indra/newview/skins/minimal/xui/de/menu_people_groups.xml new file mode 100644 index 0000000000..76225ba241 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_groups.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Info anzeigen" name="View Info"/> + <menu_item_call label="Chat" name="Chat"/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="Aktivieren" name="Activate"/> + <menu_item_call label="Verlassen" name="Leave"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_groups_view_sort.xml b/indra/newview/skins/minimal/xui/de/menu_people_groups_view_sort.xml new file mode 100644 index 0000000000..b68597d8aa --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_groups_view_sort.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Gruppensymbole anzeigen" name="Display Group Icons"/> + <menu_item_call label="Ausgewählte Gruppe verlassen" name="Leave Selected Group"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_nearby.xml b/indra/newview/skins/minimal/xui/de/menu_people_nearby.xml new file mode 100644 index 0000000000..1db964357f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_nearby.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Avatar Context Menu"> + <menu_item_call label="Profil anzeigen" name="View Profile"/> + <menu_item_call label="Freund hinzufügen" name="Add Friend"/> + <menu_item_call label="Freund entfernen" name="Remove Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="Karte" name="Map"/> + <menu_item_call label="Teilen" name="Share"/> + <menu_item_call label="Bezahlen" name="Pay"/> + <menu_item_check label="Ignorieren/Freischalten" name="Block/Unblock"/> + <menu_item_call label="Teleport anbieten" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_nearby_multiselect.xml b/indra/newview/skins/minimal/xui/de/menu_people_nearby_multiselect.xml new file mode 100644 index 0000000000..b6e99edfe1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_nearby_multiselect.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Multi-Selected People Context Menu"> + <menu_item_call label="Freunde hinzufügen" name="Add Friends"/> + <menu_item_call label="Freunde entfernen" name="Remove Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Anrufen" name="Call"/> + <menu_item_call label="Teilen" name="Share"/> + <menu_item_call label="Bezahlen" name="Pay"/> + <menu_item_call label="Teleport anbieten" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_nearby_view_sort.xml b/indra/newview/skins/minimal/xui/de/menu_people_nearby_view_sort.xml new file mode 100644 index 0000000000..0f252ab46d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_nearby_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Nach letzten Sprechern sortieren" name="sort_by_recent_speakers"/> + <menu_item_check label="Nach Name sortieren" name="sort_name"/> + <menu_item_check label="Nach Entfernung sortieren" name="sort_distance"/> + <menu_item_check label="Symbole für Personen anzeigen" name="view_icons"/> + <menu_item_call label="Ignorierte Einwohner & Objekte anzeigen" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_people_recent_view_sort.xml b/indra/newview/skins/minimal/xui/de/menu_people_recent_view_sort.xml new file mode 100644 index 0000000000..1ef020f5e1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_people_recent_view_sort.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Nach aktuellesten Sprechern sortieren" name="sort_most"/> + <menu_item_check label="Nach Name sortieren" name="sort_name"/> + <menu_item_check label="Symbole für Personen anzeigen" name="view_icons"/> + <menu_item_call label="Ignorierte Einwohner & Objekte anzeigen" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_picks.xml b/indra/newview/skins/minimal/xui/de/menu_picks.xml new file mode 100644 index 0000000000..9aec4c83b0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_picks.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Picks"> + <menu_item_call label="Info" name="pick_info"/> + <menu_item_call label="Bearbeiten" name="pick_edit"/> + <menu_item_call label="Teleportieren" name="pick_teleport"/> + <menu_item_call label="Karte" name="pick_map"/> + <menu_item_call label="Löschen" name="pick_delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_picks_plus.xml b/indra/newview/skins/minimal/xui/de/menu_picks_plus.xml new file mode 100644 index 0000000000..385ff25b95 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_picks_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="picks_plus_menu"> + <menu_item_call label="Neue Auswahl" name="create_pick"/> + <menu_item_call label="Neue Anzeige" name="create_classified"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_place.xml b/indra/newview/skins/minimal/xui/de/menu_place.xml new file mode 100644 index 0000000000..d9c85f5b92 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_place.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="place_overflow_menu"> + <menu_item_call label="Eine Landmarke setzen" name="landmark"/> + <menu_item_call label="Auswahl erstellen" name="pick"/> + <menu_item_call label="Pass kaufen" name="pass"/> + <menu_item_call label="Bearbeiten" name="edit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_place_add_button.xml b/indra/newview/skins/minimal/xui/de/menu_place_add_button.xml new file mode 100644 index 0000000000..7c0ff4a46a --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_place_add_button.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Ordner hinzufügen" name="add_folder"/> + <menu_item_call label="Landmarke hinzufügen" name="add_landmark"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_places_gear_folder.xml b/indra/newview/skins/minimal/xui/de/menu_places_gear_folder.xml new file mode 100644 index 0000000000..132d3f6466 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_places_gear_folder.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Landmarke hinzufügen" name="add_landmark"/> + <menu_item_call label="Ordner hinzufügen" name="add_folder"/> + <menu_item_call label="Ausschneiden" name="cut"/> + <menu_item_call label="Kopieren" name="copy_folder"/> + <menu_item_call label="Einfügen" name="paste"/> + <menu_item_call label="Umbenennen" name="rename"/> + <menu_item_call label="Löschen" name="delete"/> + <menu_item_call label="Erweitern Sie sich" name="expand"/> + <menu_item_call label="Zuklappen" name="collapse"/> + <menu_item_call label="Alle Ordner aufklappen" name="expand_all"/> + <menu_item_call label="Alle Ordner schließen" name="collapse_all"/> + <menu_item_check label="Nach Datum sortieren" name="sort_by_date"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_places_gear_landmark.xml b/indra/newview/skins/minimal/xui/de/menu_places_gear_landmark.xml new file mode 100644 index 0000000000..6af4d644af --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_places_gear_landmark.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_ladmark_gear"> + <menu_item_call label="Teleportieren" name="teleport"/> + <menu_item_call label="Weitere Informationen" name="more_info"/> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="Landmarke hinzufügen" name="add_landmark"/> + <menu_item_call label="Ordner hinzufügen" name="add_folder"/> + <menu_item_call label="Ausschneiden" name="cut"/> + <menu_item_call label="Landmarke kopieren" name="copy_landmark"/> + <menu_item_call label="SLurl kopieren" name="copy_slurl"/> + <menu_item_call label="Einfügen" name="paste"/> + <menu_item_call label="Umbenennen" name="rename"/> + <menu_item_call label="Löschen" name="delete"/> + <menu_item_call label="Alle Ordner aufklappen" name="expand_all"/> + <menu_item_call label="Alle Ordner schließen" name="collapse_all"/> + <menu_item_check label="Nach Datum sortieren" name="sort_by_date"/> + <menu_item_call label="Auswahl erstellen" name="create_pick"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_profile_overflow.xml b/indra/newview/skins/minimal/xui/de/menu_profile_overflow.xml new file mode 100644 index 0000000000..9f3fcbca1d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_profile_overflow.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="profile_overflow_menu"> + <menu_item_call label="Karte" name="show_on_map"/> + <menu_item_call label="Bezahlen" name="pay"/> + <menu_item_call label="Teilen" name="share"/> + <menu_item_call label="Ignorieren" name="block"/> + <menu_item_call label="Freischalten" name="unblock"/> + <menu_item_call label="Hinauswerfen" name="kick"/> + <menu_item_call label="Einfrieren" name="freeze"/> + <menu_item_call label="Auftauen" name="unfreeze"/> + <menu_item_call label="CSR" name="csr"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_save_outfit.xml b/indra/newview/skins/minimal/xui/de/menu_save_outfit.xml new file mode 100644 index 0000000000..986c78b318 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_save_outfit.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="save_outfit_menu"> + <menu_item_call label="Speichern" name="save_outfit"/> + <menu_item_call label="Speichern unter" name="save_as_new_outfit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_script_chiclet.xml b/indra/newview/skins/minimal/xui/de/menu_script_chiclet.xml new file mode 100644 index 0000000000..3256aa1a87 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_script_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="ScriptChiclet Menu"> + <menu_item_call label="Schließen" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_slurl.xml b/indra/newview/skins/minimal/xui/de/menu_slurl.xml new file mode 100644 index 0000000000..b2ec017f9f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_slurl.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="URL-Info" name="about_url"/> + <menu_item_call label="Zu URL teleportieren" name="teleport_to_url"/> + <menu_item_call label="Karte" name="show_on_map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_teleport_history_gear.xml b/indra/newview/skins/minimal/xui/de/menu_teleport_history_gear.xml new file mode 100644 index 0000000000..68b8e21802 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_teleport_history_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Teleport History Gear Context Menu"> + <menu_item_call label="Alle Ordner aufklappen" name="Expand all folders"/> + <menu_item_call label="Alle Ordner schließen" name="Collapse all folders"/> + <menu_item_call label="Teleport-Liste löschen" name="Clear Teleport History"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_teleport_history_item.xml b/indra/newview/skins/minimal/xui/de/menu_teleport_history_item.xml new file mode 100644 index 0000000000..ff8fb0b181 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_teleport_history_item.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Teleportieren" name="Teleport"/> + <menu_item_call label="Weitere Informationen" name="More Information"/> + <menu_item_call label="In Zwischenablage kopieren" name="CopyToClipboard"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_teleport_history_tab.xml b/indra/newview/skins/minimal/xui/de/menu_teleport_history_tab.xml new file mode 100644 index 0000000000..194dd16fd1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_teleport_history_tab.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Öffnen" name="TabOpen"/> + <menu_item_call label="Schließen" name="TabClose"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_text_editor.xml b/indra/newview/skins/minimal/xui/de/menu_text_editor.xml new file mode 100644 index 0000000000..c00186c13e --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_text_editor.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Text editor context menu"> + <menu_item_call label="Ausschneiden" name="Cut"/> + <menu_item_call label="Kopieren" name="Copy"/> + <menu_item_call label="Einfügen" name="Paste"/> + <menu_item_call label="Löschen" name="Delete"/> + <menu_item_call label="Alle auswählen" name="Select All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_topinfobar.xml b/indra/newview/skins/minimal/xui/de/menu_topinfobar.xml new file mode 100644 index 0000000000..5b0a724244 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_topinfobar.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_topinfobar"> + <menu_item_check label="Koordinaten anzeigen" name="Show Coordinates"/> + <menu_item_check label="Parzellen-Eigenschaften anzeigen" name="Show Parcel Properties"/> + <menu_item_call label="Landmarke" name="Landmark"/> + <menu_item_call label="Kopieren" name="Copy"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_agent.xml b/indra/newview/skins/minimal/xui/de/menu_url_agent.xml new file mode 100644 index 0000000000..9a808088fb --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_agent.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Einwohnerprofil anzeigen" name="show_agent"/> + <menu_item_call label="Name in Zwischenablage kopieren" name="url_copy_label"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_group.xml b/indra/newview/skins/minimal/xui/de/menu_url_group.xml new file mode 100644 index 0000000000..6bd86414bc --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Gruppeninformation anzeigen" name="show_group"/> + <menu_item_call label="Gruppe in Zwischenablage kopieren" name="url_copy_label"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_http.xml b/indra/newview/skins/minimal/xui/de/menu_url_http.xml new file mode 100644 index 0000000000..30eb1668a5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_http.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Webseite öffnen" name="url_open"/> + <menu_item_call label="Im internen Browser öffnen" name="url_open_internal"/> + <menu_item_call label="Im externen Browser öffnen" name="url_open_external"/> + <menu_item_call label="URL in Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_inventory.xml b/indra/newview/skins/minimal/xui/de/menu_url_inventory.xml new file mode 100644 index 0000000000..dc069df02b --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_inventory.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Inventarobjekte anzeigen" name="show_item"/> + <menu_item_call label="Name in Zwischenablage kopieren" name="url_copy_label"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_map.xml b/indra/newview/skins/minimal/xui/de/menu_url_map.xml new file mode 100644 index 0000000000..2f6ffcd450 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_map.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="Zu Position teleportieren" name="teleport_to_location"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_objectim.xml b/indra/newview/skins/minimal/xui/de/menu_url_objectim.xml new file mode 100644 index 0000000000..90d3763d9c --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_objectim.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Objektinformationen anzeigen" name="show_object"/> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="Zu Objekt-Position teleportieren" name="teleport_to_object"/> + <menu_item_call label="Objektname in Zwischenablage kopieren" name="url_copy_label"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_parcel.xml b/indra/newview/skins/minimal/xui/de/menu_url_parcel.xml new file mode 100644 index 0000000000..9169bca24f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_parcel.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Parzelleninformationen anzeigen" name="show_parcel"/> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_slapp.xml b/indra/newview/skins/minimal/xui/de/menu_url_slapp.xml new file mode 100644 index 0000000000..72e916b902 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_slapp.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Diesen Befehl ausführen" name="run_slapp"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_slurl.xml b/indra/newview/skins/minimal/xui/de/menu_url_slurl.xml new file mode 100644 index 0000000000..5d48230ebf --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_slurl.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Ortsinformationen anzeigen" name="show_place"/> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="Zu Position teleportieren" name="teleport_to_location"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_url_teleport.xml b/indra/newview/skins/minimal/xui/de/menu_url_teleport.xml new file mode 100644 index 0000000000..4cc1ecc70e --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_url_teleport.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="An diesen Standort teleportieren" name="teleport"/> + <menu_item_call label="Auf Karte zeigen" name="show_on_map"/> + <menu_item_call label="SLurl in die Zwischenablage kopieren" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_viewer.xml b/indra/newview/skins/minimal/xui/de/menu_viewer.xml new file mode 100644 index 0000000000..67dc618eb0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_viewer.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Main Menu"> + <menu label="Hilfe" name="Help"> + <menu_item_call label="[SECOND_LIFE]-Hilfe" name="Second Life Help"/> + </menu> + <menu label="Erweitert" name="Advanced"> + <menu label="Tastaturkürzel" name="Shortcuts"> + <menu_item_check label="Fliegen" name="Fly"/> + <menu_item_call label="Fenster schließen" name="Close Window"/> + <menu_item_call label="Alle Fenster schließen" name="Close All Windows"/> + <menu_item_call label="Ansicht zurücksetzen" name="Reset View"/> + </menu> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/de/menu_wearable_list_item.xml b/indra/newview/skins/minimal/xui/de/menu_wearable_list_item.xml new file mode 100644 index 0000000000..283e454a06 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_wearable_list_item.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit Wearable Context Menu"> + <menu_item_call label="Ersetzen" name="wear_replace"/> + <menu_item_call label="Anziehen" name="wear_wear"/> + <menu_item_call label="Hinzufügen" name="wear_add"/> + <menu_item_call label="Ausziehen / Abnehmen" name="take_off_or_detach"/> + <menu_item_call label="Abnehmen" name="detach"/> + <context_menu label="Anhängen an" name="wearable_attach_to"/> + <context_menu label="An HUD hängen" name="wearable_attach_to_hud"/> + <menu_item_call label="Ausziehen" name="take_off"/> + <menu_item_call label="Bearbeiten" name="edit"/> + <menu_item_call label="Objektprofil" name="object_profile"/> + <menu_item_call label="Original anzeigen" name="show_original"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_wearing_gear.xml b/indra/newview/skins/minimal/xui/de/menu_wearing_gear.xml new file mode 100644 index 0000000000..80d4ff4d9f --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_wearing_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Wearing"> + <menu_item_call label="Outfit bearbeiten" name="edit"/> + <menu_item_call label="Ausziehen" name="takeoff"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/de/menu_wearing_tab.xml b/indra/newview/skins/minimal/xui/de/menu_wearing_tab.xml new file mode 100644 index 0000000000..695451a105 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/menu_wearing_tab.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Wearing"> + <menu_item_call label="Ausziehen" name="take_off"/> + <menu_item_call label="Abnehmen" name="detach"/> + <menu_item_call label="Outfit bearbeiten" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/de/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/de/panel_bottomtray.xml new file mode 100644 index 0000000000..ea7cccbdf8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_bottomtray.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="bottom_tray"> + <string name="DragIndicationImageName" value="Accordion_ArrowOpened_Off"/> + <string name="SpeakBtnToolTip" value="Schaltet Mikrofon ein/aus"/> + <string name="VoiceControlBtnToolTip" value="Voice-Chat-Steuerung anzeigen/ausblenden"/> + <layout_stack name="toolbar_stack"> + <layout_panel name="gesture_panel"> + <gesture_combo_list label="Gesten" name="Gesture" tool_tip="Gesten anzeigen/ausblenden"/> + </layout_panel> + <layout_panel name="cam_panel"> + <bottomtray_button label="Ansicht" name="camera_btn" tool_tip="Kamerasteuerung anzeigen/ausblenden"/> + </layout_panel> + <layout_panel name="avatar_and_destinations_panel"> + <radio_group name="avatar_and_destination_btns"> + <radio_item name="destination_btn" value="0"/> + <radio_item name="avatar_btn" value="1"/> + </radio_group> + </layout_panel> + <layout_panel name="people_panel"> + <bottomtray_button label="Leute" name="show_people_button" tool_tip="Zeigt Leutefenster an"/> + </layout_panel> + <layout_panel name="profile_panel"> + <bottomtray_button label="Profil" name="show_profile_btn" tool_tip="Zeigt Profilfenster an"/> + </layout_panel> + <layout_panel name="howto_panel"> + <bottomtray_button label="Anweisungen" name="show_help_btn" tool_tip="Second Life-Anweisungsthemen öffnen"/> + </layout_panel> + <layout_panel name="im_well_panel"> + <chiclet_im_well name="im_well"> + <button name="Unread IM messages" tool_tip="IMs"/> + </chiclet_im_well> + </layout_panel> + <layout_panel name="notification_well_panel"> + <chiclet_notification name="notification_well"> + <button name="Unread" tool_tip="Benachrichtigungen"/> + </chiclet_notification> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_im_control_panel.xml b/indra/newview/skins/minimal/xui/de/panel_im_control_panel.xml new file mode 100644 index 0000000000..abf8011d9d --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_im_control_panel.xml @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_im_control_panel"> + <text name="avatar_name" value="Unbekannt"/> + <layout_stack name="button_stack"> + <layout_panel name="view_profile_btn_panel"> + <button label="Profil" name="view_profile_btn"/> + </layout_panel> + <layout_panel name="add_friend_btn_panel"> + <button label="Freund hinzufügen" name="add_friend_btn"/> + </layout_panel> + <layout_panel name="teleport_btn_panel"> + <button label="Teleportieren" name="teleport_btn" tool_tip="Dieser Person einen Teleport anbieten."/> + </layout_panel> + <layout_panel name="share_btn_panel"> + <button label="Teilen" name="share_btn"/> + </layout_panel> + <layout_panel name="pay_btn_panel"> + <button label="Bezahlen" name="pay_btn"/> + </layout_panel> + <layout_panel name="call_btn_panel"> + <button label="Anrufen" name="call_btn"/> + </layout_panel> + <layout_panel name="end_call_btn_panel"> + <button label="Anruf beenden" name="end_call_btn"/> + </layout_panel> + <layout_panel name="voice_ctrls_btn_panel"> + <button label="Voice-Steuerung" name="voice_ctrls_btn"/> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_login.xml b/indra/newview/skins/minimal/xui/de/panel_login.xml new file mode 100644 index 0000000000..dff70d6994 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_login.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_login"> + <panel.string name="create_account_url"> + http://de.secondlife.com/registration/ + </panel.string> + <panel.string name="forgot_password_url"> + http://secondlife.com/account/request.php?lang=de + </panel.string> + <layout_stack name="login_widgets"> + <layout_panel name="login"> + <text name="username_text"> + Benutzername: + </text> + <combo_box name="username_combo" tool_tip="Bei der Registrierung gewählter Benutzername wie „berndschmidt12“ oder „Liebe Sonne“"/> + <text name="password_text"> + Kennwort: + </text> + <check_box label="Kennwort merken" name="remember_check"/> + <button label="Anmelden" name="connect_btn"/> + <text name="mode_selection_text"> + Modus: + </text> + <combo_box name="mode_combo"> + <combo_box.item label="Einfach (Standard)" name="Basic"/> + <combo_box.item label="Erweitert" name="Advanced"/> + </combo_box> + </layout_panel> + <layout_panel name="links"> + <text name="create_new_account_text"> + Registrieren + </text> + <text name="forgot_password_text"> + Benutzernamen oder Kennwort vergessen? + </text> + <text name="login_help"> + Sie brauchen Hilfe? + </text> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_navigation_bar.xml b/indra/newview/skins/minimal/xui/de/panel_navigation_bar.xml new file mode 100644 index 0000000000..ee1a543aac --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_navigation_bar.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="navigation_bar"> + <panel name="navigation_panel"> + <pull_button name="back_btn" tool_tip="Zurück zum vorherigen Standort teleportieren"/> + <pull_button name="forward_btn" tool_tip="Um einen Standort weiter teleportieren"/> + <button name="home_btn" tool_tip="Zu meinem Zuhause teleportieren"/> + <location_input label="Standort" name="location_combo"/> + <search_combo_box label="Suche" name="search_combo_box" tool_tip="Suche"> + <combo_editor label="[SECOND_LIFE] durchsuchen" name="search_combo_editor"/> + </search_combo_box> + </panel> + <favorites_bar name="favorite" tool_tip="Ziehen Sie Landmarken hier hin, damit Sie schnell zu Ihren Lieblingsplätzen in Second Life gelangen können!"> + <label name="favorites_bar_label" tool_tip="Ziehen Sie Landmarken hier hin, damit Sie schnell zu Ihren Lieblingsplätzen in Second Life gelangen können!"> + Favoritenleiste + </label> + <chevron_button name=">>" tool_tip="Mehr meiner Favoriten anzeigen"/> + </favorites_bar> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_people.xml b/indra/newview/skins/minimal/xui/de/panel_people.xml new file mode 100644 index 0000000000..c6253e17de --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_people.xml @@ -0,0 +1,70 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- Side tray panel --> +<panel label="Leute" name="people_panel"> + <string name="no_recent_people" value="Sie haben in letzter Zeit mit niemandem interagiert. Suchen Sie nach Leuten, mit denen Sie sich unterhalten können? Klicken Sie unten auf die Schaltfläche „Ziele“."/> + <string name="no_filtered_recent_people" value="Es gibt keine Leute mit diesem Namen, mit denen Sie in letzter Zeit interagiert haben."/> + <string name="no_one_near" value="Es ist niemand in der Nähe. Suchen Sie nach Leuten, mit denen Sie sich unterhalten können? Klicken Sie unten auf die Schaltfläche „Ziele“."/> + <string name="no_one_filtered_near" value="Es ist niemand mit diesem Namen in der Nähe."/> + <string name="no_friends_online" value="Keine Freunde online"/> + <string name="no_friends" value="Keine Freunde"/> + <string name="no_friends_msg"> + Klicken Sie mit der rechten Maustaste auf einen Einwohner, um ihn als Freund hinzuzufügen. Suchen Sie nach Leuten, mit denen Sie sich unterhalten können? Klicken Sie unten auf die Schaltfläche „Ziele“. + </string> + <string name="no_filtered_friends_msg"> + Sie haben nicht das Richtige gefunden? Klicken Sie unten auf die Schaltfläche „Ziele“. + </string> + <string name="people_filter_label" value="Nach Leuten filtern"/> + <string name="groups_filter_label" value="Nach Gruppen filtern"/> + <string name="no_filtered_groups_msg" value="Sie haben nicht das Richtige gefunden? Versuchen Sie es mit der [secondlife:///app/search/groups/[SEARCH_TERM] Suche]."/> + <string name="no_groups_msg" value="Suchen Sie nach Gruppen? Versuchen Sie es mit der [secondlife:///app/search/groups Suche]."/> + <string name="MiniMapToolTipMsg" value="[REGION](Doppelklicken, um Karte zu öffnen; Umschalttaste gedrückt halten und ziehen, um zu schwenken)"/> + <string name="AltMiniMapToolTipMsg" value="[REGION](Doppelklicken, um zu teleportieren; Umschalttaste gedrückt halten und ziehen, um zu schwenken)"/> + <filter_editor label="Filter" name="filter_input"/> + <tab_container name="tabs"> + <panel label="IN DER NÄHE" name="nearby_panel"> + <panel label="bottom_panel" name="bottom_panel"/> + </panel> + <panel label="MEINE FREUNDE" name="friends_panel"> + <accordion name="friends_accordion"> + <accordion_tab name="tab_online" title="Online"/> + <accordion_tab name="tab_all" title="Alle"/> + </accordion> + <panel label="bottom_panel" name="bottom_panel"> + <layout_stack name="bottom_panel"> + <layout_panel name="trash_btn_panel"> + <dnd_button name="del_btn" tool_tip="Ausgewählte Person aus Ihrer Freundesliste entfernen"/> + </layout_panel> + </layout_stack> + </panel> + </panel> + <panel label="AKTUELL" name="recent_panel"> + <panel label="bottom_panel" name="bottom_panel"> + <button name="add_friend_btn" tool_tip="Ausgewählten Einwohner zur Freundeliste hinzufügen"/> + </panel> + </panel> + </tab_container> + <panel name="button_bar"> + <layout_stack name="bottom_bar_ls"> + <layout_panel name="view_profile_btn_lp"> + <button label="Profil" name="view_profile_btn" tool_tip="Bilder, Gruppen und andere Einwohner-Informationen anzeigen"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="IM" name="im_btn" tool_tip="Instant Messenger öffnen"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Teleportieren" name="teleport_btn" tool_tip="Teleport anbieten"/> + </layout_panel> + </layout_stack> + <layout_stack name="bottom_bar_ls1"> + <layout_panel name="group_info_btn_lp"> + <button label="Gruppenprofil" name="group_info_btn" tool_tip="Gruppeninformationen anzeigen"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Gruppen-Chat" name="chat_btn" tool_tip="Chat öffnen"/> + </layout_panel> + <layout_panel name="group_call_btn_lp"> + <button label="Gruppe anrufen" name="group_call_btn" tool_tip="Diese Gruppe anrufen"/> + </layout_panel> + </layout_stack> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_side_tray_tab_caption.xml b/indra/newview/skins/minimal/xui/de/panel_side_tray_tab_caption.xml new file mode 100644 index 0000000000..652fb7c836 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_side_tray_tab_caption.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="sidetray_tab_panel"> + <text name="sidetray_tab_title" value="Klappmenü??"/> + <button name="undock" tool_tip="Abkoppeln"/> + <button name="dock" tool_tip="Andocken"/> + <button name="show_help" tool_tip="Hilfe anzeigen"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/de/panel_status_bar.xml b/indra/newview/skins/minimal/xui/de/panel_status_bar.xml new file mode 100644 index 0000000000..04ed58f944 --- /dev/null +++ b/indra/newview/skins/minimal/xui/de/panel_status_bar.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="status"> + <panel.string name="StatBarDaysOfWeek"> + Sonntag:Montag:Dienstag:Mittwoch:Donnerstag:Freitag:Samstag + </panel.string> + <panel.string name="StatBarMonthsOfYear"> + Januar:Februar:März:April:Mai:Juni:Juli:August:September:Oktober:November:Dezember + </panel.string> + <panel.string name="packet_loss_tooltip"> + Paketverlust + </panel.string> + <panel.string name="bandwidth_tooltip"> + Bandbreite + </panel.string> + <panel.string name="time"> + [hour12, datetime, slt]:[min, datetime, slt] [ampm, datetime, slt] [timezone,datetime, slt] + </panel.string> + <panel.string name="timeTooltip"> + [weekday, datetime, slt], [day, datetime, slt] [month, datetime, slt] [year, datetime, slt] + </panel.string> + <panel.string name="buycurrencylabel"> + [AMT] L$ + </panel.string> + <panel name="balance_bg"> + <text name="balance" tool_tip="Klicken, um L$-Guthaben zu aktualisieren" value="20 L$"/> + <button label="L$ kaufen" name="buyL" tool_tip="Hier klicken, um mehr L$ zu kaufen"/> + </panel> + <text name="TimeText" tool_tip="Aktuelle Zeit (Pazifik)"> + 24:00 H PST + </text> + <button name="media_toggle_btn" tool_tip="Alle Medien starten/stoppen (Musik, Video, Webseiten)"/> + <button name="volume_btn" tool_tip="Steuerung der Gesamtlautstärke"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/floater_camera.xml b/indra/newview/skins/minimal/xui/en/floater_camera.xml new file mode 100644 index 0000000000..4cf792444f --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_camera.xml @@ -0,0 +1,284 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<floater + legacy_header_height="18" + can_dock="true" + can_minimize="true" + can_close="false" + follows="bottom" + height="164" + layout="topleft" + name="camera_floater" + save_rect="true" + save_visibility="true" + save_dock_state="true" + single_instance="true" + width="228"> + <floater.string + name="rotate_tooltip"> + Rotate Camera Around Focus + </floater.string> + <floater.string + name="zoom_tooltip"> + Zoom Camera Towards Focus + </floater.string> + <floater.string + name="move_tooltip"> + Move Camera Up and Down, Left and Right + </floater.string> + <floater.string + name="camera_modes_title"> + Camera modes + </floater.string> + <floater.string + name="pan_mode_title"> + Orbit Zoom Pan + </floater.string> + <floater.string + name="presets_mode_title"> + Preset Views + </floater.string> + <floater.string + name="free_mode_title"> + View Object + </floater.string> + <panel + border="false" + height="123" + layout="topleft" + left="2" + top="0" + mouse_opaque="false" + name="controls" + width="226"> + <panel + color="Transparent" + follows="all" + height="102" + layout="topleft" + left="8" + name="preset_views_list" + opaque="true" + top="24" + width="212" + visible="false"> + <panel_camera_item + name="front_view"> + <panel_camera_item.mousedown_callback + function="CameraPresets.ChangeView" + parameter="front_view" /> + <panel_camera_item.picture + image_name="Cam_Preset_Front_Off" /> + <panel_camera_item.selected_picture + image_name="Cam_Preset_Front_On" /> + <panel_camera_item.text + name="front_view_text"> + Front View + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item + name="group_view" + top_pad="4"> + <panel_camera_item.mousedown_callback + function="CameraPresets.ChangeView" + parameter="group_view" /> + <panel_camera_item.picture + image_name="Cam_Preset_Side_Off" /> + <panel_camera_item.selected_picture + image_name="Cam_Preset_Side_On" /> + <panel_camera_item.text + name="side_view_text"> + Side View + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item + name="rear_view" + layout="topleft" + top_pad="4"> + <panel_camera_item.mousedown_callback + function="CameraPresets.ChangeView" + parameter="rear_view" /> + <panel_camera_item.picture + image_name="Cam_Preset_Back_Off" /> + <panel_camera_item.selected_picture + image_name="Cam_Preset_Back_On" /> + <panel_camera_item.text + name="rear_view_text"> + Rear View + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel + color="Transparent" + follows="all" + height="68" + item_pad="4" + layout="topleft" + left="8" + name="camera_modes_list" + opaque="true" + top="24" + width="212" + visible="false"> + <panel_camera_item + name="object_view"> + <panel_camera_item.mousedown_callback + function="CameraPresets.ChangeView" + parameter="object_view" /> + <panel_camera_item.text + name="object_view_text"> + Object View + </panel_camera_item.text> + <panel_camera_item.picture + image_name="Object_View_Off" /> + <panel_camera_item.selected_picture + image_name="Object_View_On" /> + </panel_camera_item> + <panel_camera_item + name="mouselook_view" + layout="topleft"> + <panel_camera_item.mousedown_callback + function="CameraPresets.ChangeView" + parameter="mouselook_view" /> + <panel_camera_item.text + name="mouselook_view_text"> + Mouselook View + </panel_camera_item.text> + <panel_camera_item.picture + image_name="MouseLook_View_Off" /> + <panel_camera_item.selected_picture + image_name="MouseLook_View_On" /> + </panel_camera_item> + </panel> + <!--TODO: replace + - images --> + <panel + border="false" + class="camera_zoom_panel" + height="114" + layout="topleft" + left="0" + mouse_opaque="false" + name="zoom" + top="20" + width="226"> + <joystick_rotate + follows="top|left" + height="78" + image_selected="Cam_Rotate_In" + image_unselected="Cam_Rotate_Out" + layout="topleft" + left="7" + mouse_opaque="false" + name="cam_rotate_stick" + quadrant="left" + scale_image="false" + sound_flags="3" + visible="true" + tool_tip="Orbit camera around focus" + top="20" + width="78"> + <commit_callback + function="Camera.rotate" /> + <mouse_held_callback + function="Camera.rotate" /> + </joystick_rotate> + <button + follows="top|left" + height="18" + image_disabled="AddItem_Disabled" + image_selected="AddItem_Press" + image_unselected="AddItem_Off" + layout="topleft" + left_pad="14" + name="zoom_plus_btn" + width="18" + top="18"> + <commit_callback + function="Zoom.plus" /> + <mouse_held_callback + function="Zoom.plus" /> + </button> + <slider_bar + height="50" + layout="topleft" + name="zoom_slider" + orientation="vertical" + tool_tip="Zoom camera toward focus" + top_pad="0" + min_val="0" + max_val="1" + width="18"> + <commit_callback function="Slider.value_changed"/> + </slider_bar> + <button + follows="top|left" + height="18" + image_disabled="MinusItem_Disabled" + image_selected="MinusItem_Press" + image_unselected="MinusItem_Off" + layout="topleft" + name="zoom_minus_btn" + top_pad="0" + width="18"> + <commit_callback + function="Zoom.minus" /> + <mouse_held_callback + function="Zoom.minus" /> + </button> + <joystick_track + follows="top|left" + height="78" + image_selected="Cam_Tracking_In" + image_unselected="Cam_Tracking_Out" + layout="topleft" + left="133" + name="cam_track_stick" + quadrant="left" + scale_image="false" + sound_flags="3" + tool_tip="Move camera up and down, left and right" + top="20" + width="78"> + <commit_callback + function="Camera.track" /> + <mouse_held_callback + function="Camera.track" /> + </joystick_track> + </panel> + </panel> + <panel + border="false" + height="42" + layout="topleft" + left="2" + top_pad="0" + name="buttons" + width="226"> + <button + height="23" + label="" + layout="topleft" + left="83" + is_toggle="true" + image_overlay="Cam_Avatar_Off" + image_selected="PushButton_Selected_Press" + name="presets_btn" + tab_stop="false" + tool_tip="Preset Views" + top="13" + width="25"> + </button> + <button + height="23" + label="" + layout="topleft" + left_pad="1" + is_toggle="true" + image_overlay="PanOrbit_Off" + image_selected="PushButton_Selected_Press" + name="pan_btn" + tab_stop="false" + tool_tip="Orbit Zoom Pan" + width="25"> + </button> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/floater_help_browser.xml b/indra/newview/skins/minimal/xui/en/floater_help_browser.xml new file mode 100644 index 0000000000..eddfe41c25 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_help_browser.xml @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<floater + legacy_header_height="18" + can_resize="true" + can_minimize="false" + height="360" + layout="topleft" + min_height="360" + left="645" + top="10" + min_width="300" + name="floater_help_browser" + save_rect="true" + single_instance="true" + title="HOW TO" + width="300"> + <floater.string + name="loading_text"> + Loading... + </floater.string> + <floater.string + name="done_text"> + </floater.string> + <layout_stack + bottom="360" + follows="left|right|top|bottom" + layout="topleft" + left="5" + orientation="vertical" + name="stack1" + top="20" + width="290"> + <layout_panel + layout="topleft" + left_delta="0" + top_delta="0" + name="external_controls" + user_resize="false" + width="280"> + <web_browser + trusted_content="true" + bottom="-5" + follows="left|right|top|bottom" + layout="topleft" + left="0" + name="browser" + top="0" + height="300" + width="280" /> + </layout_panel> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/floater_media_browser.xml b/indra/newview/skins/minimal/xui/en/floater_media_browser.xml new file mode 100644 index 0000000000..4862146c94 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_media_browser.xml @@ -0,0 +1,242 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<floater + legacy_header_height="18" + can_resize="true" + height="440" + layout="topleft" + min_height="140" + min_width="467" + name="floater_about" + save_rect="true" + auto_tile="true" + title="MEDIA BROWSER" + width="820"> + <floater.string + name="home_page_url"> + http://www.secondlife.com + </floater.string> + <floater.string + name="support_page_url"> + http://support.secondlife.com + </floater.string> + <layout_stack + bottom="440" + follows="left|right|top|bottom" + layout="topleft" + left="10" + name="stack1" + orientation="vertical" + top="20" + width="800"> + <layout_panel + auto_resize="false" + default_tab_group="1" + height="20" + layout="topleft" + left="0" + min_height="20" + name="nav_controls" + top="400" + user_resize="false" + width="800"> + <button + follows="left|top" + height="20" + label="Back" + layout="topleft" + left="0" + name="back" + top="0" + width="55"> + <button.commit_callback + function="MediaBrowser.Back" /> + </button> + <button + follows="left|top" + height="20" + label="Forward" + layout="topleft" + left_pad="3" + name="forward" + top_delta="0" + width="68"> + <button.commit_callback + function="MediaBrowser.Forward" /> + </button> + <button + enabled="false" + follows="left|top" + height="20" + label="Reload" + layout="topleft" + left_pad="2" + name="reload" + top_delta="0" + width="70"> + <button.commit_callback + function="MediaBrowser.Refresh" /> + </button> + <combo_box + allow_text_entry="true" + follows="left|top|right" + tab_group="1" + height="20" + layout="topleft" + left_pad="5" + max_chars="1024" + name="address" + combo_editor.select_on_focus="true" + top_delta="0" + width="540"> + <combo_box.commit_callback + function="MediaBrowser.EnterAddress" /> + </combo_box> + <button + enabled="false" + follows="right|top" + height="20" + label="Go" + layout="topleft" + left_pad="5" + name="go" + top_delta="0" + width="50"> + <button.commit_callback + function="MediaBrowser.Go" /> + </button> + </layout_panel> + <layout_panel + auto_resize="false" + height="20" + layout="topleft" + left_delta="0" + min_height="20" + name="time_controls" + top_delta="0" + user_resize="false" + width="800"> + <button + follows="left|top" + height="20" + label="rewind" + layout="topleft" + left="0" + name="rewind" + top="0" + width="55" /> + <button + follows="left|top" + height="20" + image_selected="button_anim_play_selected.tga" + image_unselected="button_anim_play.tga" + layout="topleft" + left_delta="55" + name="play" + top_delta="0" + width="55" /> + <button + follows="left|top" + height="20" + image_selected="button_anim_pause_selected.tga" + image_unselected="button_anim_pause.tga" + layout="topleft" + left_delta="0" + name="pause" + top_delta="0" + width="55" /> + <button + follows="left|top" + height="20" + label="stop" + layout="topleft" + left_pad="10" + name="stop" + top_delta="0" + width="55" /> + <button + follows="left|top" + height="20" + label="forward" + layout="topleft" + left_pad="20" + name="seek" + top_delta="0" + width="55" /> + </layout_panel> + <layout_panel + auto_resize="false" + height="20" + layout="topleft" + left_delta="0" + min_height="20" + name="parcel_owner_controls" + top_delta="0" + user_resize="false" + width="540"> + <button + enabled="false" + follows="left|top" + height="20" + label="Send Current Page to Parcel" + layout="topleft" + left="0" + name="assign" + top="0" + width="200"> + <button.commit_callback + function="MediaBrowser.Assign" /> + </button> + </layout_panel> + <layout_panel + height="40" + layout="topleft" + left_delta="0" + name="external_controls" + top_delta="0" + user_resize="false" + width="540"> + <web_browser + bottom="-30" + follows="all" + layout="topleft" + left="0" + name="browser" + top="0" + width="540" /> + <button + follows="bottom|left" + height="20" + label="Open in My Web Browser" + layout="topleft" + left_delta="0" + name="open_browser" + top_pad="5" + width="185"> + <button.commit_callback + function="MediaBrowser.OpenWebBrowser" /> + </button> + <check_box + control_name="UseExternalBrowser" + follows="bottom|left" + height="20" + label="Always open in my web browser" + layout="topleft" + left_pad="5" + name="open_always" + top_delta="0" + width="200" /> + <button + follows="bottom|right" + height="20" + label="Close" + layout="topleft" + left_pad="80" + name="close" + top_delta="0" + width="70"> + <button.commit_callback + function="MediaBrowser.Close" /> + </button> + </layout_panel> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/floater_nearby_chat.xml b/indra/newview/skins/minimal/xui/en/floater_nearby_chat.xml new file mode 100644 index 0000000000..74ac885202 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_nearby_chat.xml @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater + border_visible="false" + border="false" + bg_opaque_image="Window_Foreground" + bg_alpha_image="Window_Background" + bg_alpha_image_overlay="DkGray_66" + legacy_header_height="18" + can_minimize="true" + can_tear_off="false" + can_resize="true" + can_drag_on_left="false" + can_close="false" + can_dock="true" + bevel_style="in" + height="300" + min_width="235" + layout="topleft" + name="nearby_chat" + save_rect="true" + title="NEARBY CHAT" + save_dock_state="true" + save_visibility="true" + single_instance="true" + width="320"> + <check_box + bottom_delta="36" + control_name="TranslateChat" + enabled="true" + height="16" + label="Translate chat (powered by Google)" + layout="topleft" + left="5" + name="translate_chat_checkbox" + width="230" /> + <chat_history + parse_urls="true" + bg_readonly_color="ChatHistoryBgColor" + bg_writeable_color="ChatHistoryBgColor" + follows="all" + left="5" + top_delta="17" + layout="topleft" + height="260" + name="chat_history" + parse_highlights="true" + text_color="ChatHistoryTextColor" + text_readonly_color="ChatHistoryTextColor" + right_widget_pad="5" + left_widget_pad="0" + width="315" /> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/floater_side_bar_tab.xml b/indra/newview/skins/minimal/xui/en/floater_side_bar_tab.xml new file mode 100644 index 0000000000..83b1260620 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_side_bar_tab.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<floater + can_close="true" + can_resize="true" + min_width="333" + min_height="440" + save_rect="true" + save_visibility="true" + > +</floater> diff --git a/indra/newview/skins/minimal/xui/en/floater_web_content.xml b/indra/newview/skins/minimal/xui/en/floater_web_content.xml new file mode 100644 index 0000000000..50cb5b14ce --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/floater_web_content.xml @@ -0,0 +1,189 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<floater + legacy_header_height="18" + can_resize="true" + height="775" + layout="topleft" + min_height="400" + min_width="500" + name="floater_web_content" + save_rect="true" + auto_tile="true" + title="" + initial_mime_type="text/html" + width="780"> + <layout_stack + bottom="775" + follows="left|right|top|bottom" + layout="topleft" + left="5" + name="stack1" + orientation="vertical" + top="20" + width="770"> + <layout_panel + auto_resize="false" + default_tab_group="1" + height="22" + layout="topleft" + left="0" + min_height="20" + name="nav_controls" + top="400" + user_resize="false" + width="770"> + <button + image_overlay="Arrow_Left_Off" + image_disabled="PushButton_Disabled" + image_disabled_selected="PushButton_Disabled" + image_selected="PushButton_Selected" + image_unselected="PushButton_Off" + hover_glow_amount="0.15" + tool_tip="Navigate back" + follows="left|top" + height="22" + layout="topleft" + left="1" + name="back" + top="0" + width="22"> + <button.commit_callback + function="WebContent.Back" /> + </button> + <button + image_overlay="Arrow_Right_Off" + image_disabled="PushButton_Disabled" + image_disabled_selected="PushButton_Disabled" + image_selected="PushButton_Selected" + image_unselected="PushButton_Off" + tool_tip="Navigate forward" + follows="left|top" + height="22" + layout="topleft" + left="27" + name="forward" + top_delta="0" + width="22"> + <button.commit_callback + function="WebContent.Forward" /> + </button> + <button + image_overlay="Stop_Off" + image_disabled="PushButton_Disabled" + image_disabled_selected="PushButton_Disabled" + image_selected="PushButton_Selected" + image_unselected="PushButton_Off" + tool_tip="Stop navigation" + enabled="true" + follows="left|top" + height="22" + layout="topleft" + left="51" + name="stop" + top_delta="0" + width="22"> + <button.commit_callback + function="WebContent.Stop" /> + </button> + <button + image_overlay="Refresh_Off" + image_disabled="PushButton_Disabled" + image_disabled_selected="PushButton_Disabled" + image_selected="PushButton_Selected" + image_unselected="PushButton_Off" + tool_tip="Reload page" + follows="left|top" + height="22" + layout="topleft" + left="51" + name="reload" + top_delta="0" + width="22"> + <button.commit_callback + function="WebContent.Reload" /> + </button> + <combo_box + allow_text_entry="true" + follows="left|top|right" + tab_group="1" + height="22" + layout="topleft" + left_pad="4" + max_chars="1024" + name="address" + combo_editor.select_on_focus="true" + tool_tip="Enter URL here" + top_delta="0" + width="672"> + <combo_box.commit_callback + function="WebContent.EnterAddress" /> + </combo_box> + <icon + name="media_secure_lock_flag" + height="16" + follows="top|right" + image_name="Lock2" + layout="topleft" + left_delta="620" + top_delta="2" + visible="false" + tool_tip="Secured Browsing" + width="16" /> + <button + image_overlay="ExternalBrowser_Off" + image_disabled="PushButton_Disabled" + image_disabled_selected="PushButton_Disabled" + image_selected="PushButton_Selected" + image_unselected="PushButton_Off" + tool_tip="Open current URL in your desktop browser" + follows="right|top" + enabled="true" + height="22" + layout="topleft" + name="popexternal" + right="770" + top_delta="-2" + width="22"> + <button.commit_callback + function="WebContent.PopExternal" /> + </button> + </layout_panel> + <layout_panel + height="40" + layout="topleft" + left_delta="0" + name="external_controls" + top_delta="0" + user_resize="false" + width="585"> + <web_browser + bottom="-22" + follows="all" + layout="topleft" + left="0" + name="webbrowser" + top="0"/> + <text + type="string" + length="200" + follows="bottom|left" + height="20" + layout="topleft" + left_delta="0" + name="statusbartext" + parse_urls="false" + text_color="0.4 0.4 0.4 1" + top_pad="5" + width="495"/> + <progress_bar + color_bar="0.3 1.0 0.3 1" + follows="bottom|right" + height="16" + top_delta="-1" + left_pad="24" + layout="topleft" + name="statusbarprogress" + width="64"/> + </layout_panel> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/inspect_avatar.xml b/indra/newview/skins/minimal/xui/en/inspect_avatar.xml new file mode 100644 index 0000000000..853d5f8735 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/inspect_avatar.xml @@ -0,0 +1,206 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater + legacy_header_height="25" + bevel_style="in" + bg_opaque_image="Inspector_Background" + can_close="false" + can_minimize="false" + height="164" + layout="topleft" + name="inspect_avatar" + single_instance="true" + sound_flags="0" + visible="true" + width="245"> + <!-- Allowed fields include: + [BORN_ON] ("12/3/2008") + [SL_PROFILE] (Second Life profile), + [RW_PROFILE] (real world profile), + [ACCTTYPE] ("Resident"), + [PAYMENTINFO] ("Payment Info on File"), + [AGE] ("1 year 2 months") + --> + <string + name="Subtitle"> +[AGE] + </string> + <string + name="Details"> +[SL_PROFILE] + </string> + <text + follows="top|left" + font="SansSerif" + height="20" + left="8" + name="user_name_small" + top="7" + text_color="White" + use_ellipses="true" + word_wrap="true" + visible="false" + value="Grumpity ProductEngine with a long name" + width="185" /> + <text + follows="top|left" + font="SansSerifBigLarge" + height="21" + left="8" + name="user_name" + top="10" + text_color="White" + use_ellipses="true" + value="Grumpity ProductEngine" + width="190" /> + <text + follows="top|left" + height="16" + left="8" + name="user_slid" + font="SansSerifSmallBold" + text_color="EmphasisColor" + value="james.linden" + width="185" + use_ellipses="true" /> + <text + follows="top|left" + height="16" + left="8" + name="user_subtitle" + font="SansSerifSmall" + text_color="White" + top_pad="0" + value="11 Months, 3 days old" + width="175" + use_ellipses="true" /> + <text + follows="left|top|right" + height="35" + left="8" + name="user_details" + right="-10" + word_wrap="true" + top_pad="4" + use_ellipses="true" + width="220">This is my second life description and I really think it is great. But for some reason my description is super extra long because I like to talk a whole lot + </text> + <slider + follows="top|left" + height="23" + increment="0.01" + left="1" + max_val="0.95" + min_val="0.05" + name="volume_slider" + show_text="false" + tool_tip="Voice volume" + top_pad="0" + value="0.5" + width="200" /> + <button + follows="top|left" + height="16" + image_disabled="Audio_Off" + image_disabled_selected="AudioMute_Off" + image_hover_selected="AudioMute_Over" + image_selected="AudioMute_Off" + image_unselected="Audio_Off" + is_toggle="true" + left_pad="0" + top_delta="4" + name="mute_btn" + width="16" /> + <avatar_icon + follows="top|left" + height="38" + right="-10" + bevel_style="in" + border_style="line" + mouse_opaque="true" + name="avatar_icon" + top="10" + width="38" /> +<!-- Overlapping buttons for default actions + llinspectavatar.cpp makes visible the most likely default action +--> + <button + follows="top|left" + height="20" + label="Add Friend" + left="8" + top="135" + name="add_friend_btn" + width="90" /> + <button + follows="top|left" + height="20" + label="IM" + left_delta="0" + top_delta="0" + name="im_btn" + width="80" + commit_callback.function="InspectAvatar.IM"/> + <button + follows="top|left" + height="20" + label="Profile" + layout="topleft" + name="view_profile_btn" + left_delta="96" + top_delta="0" + tab_stop="false" + width="80" /> + <!-- gear buttons here --> + <menu_button + follows="top|left" + height="20" + layout="topleft" + image_overlay="OptionsMenu_Off" + menu_filename="menu_inspect_avatar_gear.xml" + name="gear_btn" + right="-5" + top_delta="0" + width="35" /> + <menu_button + follows="top|left" + height="20" + image_overlay="OptionsMenu_Off" + menu_filename="menu_inspect_self_gear.xml" + name="gear_self_btn" + right="-5" + top_delta="0" + width="35" /> + <panel + follows="top|left" + top="164" + left="0" + height="60" + width="228" + visible="false" + background_visible="true" + name="moderator_panel" + background_opaque="true" + bg_opaque_color="MouseGray"> + <button + name="disable_voice" + label="Disable Voice" + top="20" + width="95" + height="20" + left="10" + commit_callback.function="InspectAvatar.DisableVoice"/> + <button + name="enable_voice" + label="Enable Voice" + top="20" + width="95" + height="20" + left="10" + visible="false" + commit_callback.function="InspectAvatar.EnableVoice"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/inspect_object.xml b/indra/newview/skins/minimal/xui/en/inspect_object.xml new file mode 100644 index 0000000000..f424069ec6 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/inspect_object.xml @@ -0,0 +1,144 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater + legacy_header_height="25" + bevel_style="in" + bg_opaque_image="Inspector_Background" + can_close="false" + can_minimize="false" + height="150" + layout="topleft" + name="inspect_object" + single_instance="true" + sound_flags="0" + visible="true" + width="228"> + <string name="Creator">By [CREATOR]</string> + <string name="CreatorAndOwner"> +By [CREATOR] +Owner [OWNER] + </string> + <string name="Price">L$[AMOUNT]</string> + <string name="PriceFree">Free!</string> + <string name="Touch">Touch</string> + <string name="Sit">Sit</string> + <text + parse_urls="false" + follows="all" + font="SansSerifLarge" + height="30" + left="8" + name="object_name" + text_color="White" + top="6" + use_ellipses="true" + word_wrap="true" + width="220" /> + <text + follows="all" + height="50" + left="8" + name="object_creator" + top_pad="6" + use_ellipses="true" + width="220"> + by secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about +owner secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about + </text> + <text + follows="all" + font="SansSerifSmall" + font.style="BOLD" + height="14" + halign="right" + right="-5" + name="price_text" + text_color="white" + top="60" + font_shadow="none" + width="60"> +L$30,000 + </text> + <text + clip_partial="true" + follows="all" + font="SansSerifSmall" + height="25" + left="8" + name="object_description" + top="76" + use_ellipses="true" + width="220" + word_wrap="true"> + </text> + <!-- Overlapping buttons for all default actions. Show "Buy" if + for sale, "Sit" if can sit, etc. --> + <icon + name="secure_browsing" + image_name="Lock" + left="0" + visible="false" + width="18" + height="18" + top="103" + tool_tip="Secure Browsing" + follows="left|top" /> + <text + follows="all" + font="SansSerifSmall" + height="13" + name="object_media_url" + width="207" + left_pad="2" + top_delta="0" + max_length = "50" + use_ellipses="true"> + http://www.superdupertest.com +</text> + <button + follows="top|left" + height="20" + label="Take Copy" + left_delta="0" + name="take_free_copy_btn" + top_delta="0" + width="80" /> + <button + follows="top|left" + height="20" + label="Touch" + left_delta="0" + name="touch_btn" + top_delta="0" + width="80" /> + <button + follows="top|left" + height="20" + label="Sit" + left_delta="0" + name="sit_btn" + top_delta="0" + width="80" /> + <button + follows="top|left" + height="20" + label="Open" + left_delta="0" + name="open_btn" + top_delta="0" + width="80" /> + + <!-- non-overlapping buttons here --> + <menu_button + follows="top|left" + height="20" + image_overlay="OptionsMenu_Off" + menu_filename="menu_inspect_object_gear.xml" + name="gear_btn" + right="-5" + top_delta="0" + width="35" /> +</floater> diff --git a/indra/newview/skins/minimal/xui/en/main_view.xml b/indra/newview/skins/minimal/xui/en/main_view.xml new file mode 100644 index 0000000000..45ba785c1f --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/main_view.xml @@ -0,0 +1,268 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + follows="left|right|top|bottom" + height="768" + layout="topleft" + left="0" + mouse_opaque="false" + tab_stop="false" + name="main_view" + width="1024"> + <panel top="0" + follows="all" + height="768" + mouse_opaque="false" + name="login_panel_holder" + width="1024"/> + + <layout_stack border_size="0" + follows="all" + mouse_opaque="false" + height="768" + name="menu_stack" + orientation="vertical" + top="0"> + <layout_panel auto_resize="false" + height="30" + mouse_opaque="false" + name="nav_bar_container" + tab_stop="false" + min_height="0" + width="1024" + user_resize="false" + visible="true"> + </layout_panel> + <layout_panel auto_resize="true" + follows="all" + height="500" + layout="topleft" + mouse_opaque="false" + tab_stop="false" + name="hud" + width="1024"> + <panel auto_resize="false" + follows="all" + height="500" + top="0" + layout="topleft" + mouse_opaque="false" + tab_stop="false" + name="non_side_tray_view" + user_resize="false" + width="1024"> + + <layout_stack border_size="0" + bottom="500" + follows="all" + height="500" + left="0" + top="0" + mouse_opaque="false" + name="world_stack" + open_time_constant="0.03" + close_time_constant="0.03" + orientation="vertical"> + <layout_panel auto_resize="true" + follows="all" + height="500" + layout="topleft" + tab_stop="false" + mouse_opaque="false" + user_resize="false" + name="hud container" + width="500"> + <view top="0" + follows="all" + height="500" + left="0" + mouse_opaque="false" + name="floater_snap_region" + width="500"/> + <panel follows="left|top" + height="0" + left="0" + mouse_opaque="false" + name="topinfo_bar_container" + tab_stop="false" + top="0" + visible="false" + width="1024"/> + <panel bottom="500" + follows="left|right|bottom" + height="25" + left="0" + mouse_opaque="false" + tab_stop="false" + name="stand_stop_flying_container" + visible="false" + width="500"/> + <panel follows="all" + height="500" + left="0" + mouse_opaque="false" + name="floater_view_holder" + tab_group="-1" + tab_stop="false" + top="0" + width="500"> + <floater_view follows="all" + height="500" + left="0" + mouse_opaque="false" + name="Floater View" + tab_group="-1" + tab_stop="false" + top="0" + width="500"/> + </panel> + <panel bottom="500" + follows="all" + height="500" + left="0" + mouse_opaque="false" + name="world_view_rect" + top="0" + width="500"/> + </layout_panel> + <layout_panel auto_resize="false" + min_height="33" + height="33" + mouse_opaque="false" + name="bottom_tray_container" + visible="false"/> + <layout_panel auto_resize="false" + height="215" + mouse_opaque="false" + user_resize="false" + name="avatar_picker_and_destination_guide_container" + visible="false"> + <panel top="0" + height="215" + left="0" + background_visible="true" + width="500" + follows="all"> + <web_browser + top="0" + height="200" + follows="all" + name="destination_guide_contents" + trusted_content="true" + visible="false"/> + <web_browser + top="0" + height="200" + follows="all" + name="avatar_picker_contents" + visible="false" + trusted_content="true"/> + <button + name="close" + width="22" + height="23" + right="-10" + top="2" + follows="top|right" + chrome="true" + tab_stop="false" + image_unselected="bottomtray_close_off" + image_selected="bottomtray_close_press" + /> + </panel> + </layout_panel> + </layout_stack> + </panel> + <debug_view follows="all" + left="0" + top="0" + mouse_opaque="false" + height="500" + name="DebugView" + width="1024"/> + </layout_panel> + </layout_stack> + <panel mouse_opaque="false" + follows="right|top" + name="status_bar_container" + tab_stop="false" + height="30" + left="-70" + top="0" + width="70" + visible="false"/> + <panel follows="top|bottom" + height="500" + mouse_opaque="false" + tab_stop="false" + name="hidden_side_tray" + visible="false" + width="333"> + <panel + name="side_tray_container" + width="333" + height="500"/> + </panel> + + <panel top="0" + follows="all" + mouse_opaque="false" + left="0" + name="snapshot_floater_view_holder" + width="1024" + height="798"> + <snapshot_floater_view enabled="false" + follows="all" + height="768" + left="0" + mouse_opaque="false" + name="Snapshot Floater View" + tab_stop="false" + top="0" + visible="false" + width="1024"/> + </panel> + <panel top="0" + follows="all" + height="768" + mouse_opaque="false" + name="popup_holder" + class="popup_holder" + width="1024"> + <icon follows="right|bottom" + image_name="Resize_Corner" + right="-1" + name="resize_corner" + width="11" + bottom="-1" + height="11" /> + </panel> + <view top="0" + left="0" + width="1024" + height="768" + name="hint_holder" + mouse_opaque="false" + follows="all"/> + <panel top="0" + follows="all" + height="768" + mouse_opaque="true" + name="progress_view" + filename="panel_progress.xml" + class="progress_view" + width="1024" + visible="false"/> + <menu_holder top="0" + follows="all" + height="768" + mouse_opaque="false" + name="Menu Holder" + width="1024"/> + <tooltip_view top="0" + follows="all" + height="768" + mouse_opaque="false" + name="tooltip view" + tab_group="-2" + width="1024"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/menu_add_wearable_gear.xml b/indra/newview/skins/minimal/xui/en/menu_add_wearable_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_add_wearable_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_attachment_other.xml b/indra/newview/skins/minimal/xui/en/menu_attachment_other.xml new file mode 100644 index 0000000000..b55e677276 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_attachment_other.xml @@ -0,0 +1,76 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- *NOTE: See also menu_avatar_other.xml --> +<context_menu + layout="topleft" + name="Avatar Pie"> + <menu_item_call + label="View Profile" + name="Profile..."> + <menu_item_call.on_click + function="ShowAgentProfile" + parameter="hit object" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Add Friend" + name="Add Friend"> + <menu_item_call.on_click + function="Avatar.AddFriend" /> + <menu_item_call.on_enable + function="Avatar.EnableAddFriend" /> + </menu_item_call> + <menu_item_call + label="IM" + name="Send IM..."> + <menu_item_call.on_click + function="Avatar.SendIM" /> + </menu_item_call> + <menu_item_separator /> + <menu_item_call + enabled="false" + label="Block" + name="Avatar Mute"> + <menu_item_call.on_click + function="Avatar.Mute" /> + <menu_item_call.on_enable + function="Avatar.EnableMute" /> + </menu_item_call> + <menu_item_call + label="Report" + name="abuse"> + <menu_item_call.on_click + function="Avatar.ReportAbuse" /> + </menu_item_call> + <menu_item_call + label="Freeze" + name="Freeze..."> + <menu_item_call.on_click + function="Avatar.Freeze" /> + <menu_item_call.on_visible + function="Avatar.EnableFreezeEject"/> + </menu_item_call> + <menu_item_call + label="Eject" + name="Eject..."> + <menu_item_call.on_click + function="Avatar.Eject" /> + <menu_item_call.on_visible + function="Avatar.EnableFreezeEject"/> + </menu_item_call> + <menu_item_call + label="Debug Textures" + name="Debug..."> + <menu_item_call.on_click + function="Avatar.Debug" /> + <menu_item_call.on_visible + function="IsGodCustomerService"/> + </menu_item_call> + <menu_item_call + label="Zoom In" + name="Zoom In"> + <menu_item_call.on_click + function="Tools.LookAtSelection" + parameter="zoom" /> + </menu_item_call> + <menu_item_separator /> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_attachment_self.xml b/indra/newview/skins/minimal/xui/en/menu_attachment_self.xml new file mode 100644 index 0000000000..542a7dc7dc --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_attachment_self.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu + layout="topleft" + name="Attachment Pie"> + <menu_item_call + enabled="false" + label="Touch" + layout="topleft" + name="Attachment Object Touch"> + <menu_item_call.on_click + function="Object.Touch" /> + <menu_item_call.on_enable + function="Object.EnableTouch" + name="EnableTouch"/> + </menu_item_call> + <menu_item_call + enabled="false" + label="Detach" + layout="topleft" + name="Detach"> + <menu_item_call.on_click + function="Attachment.Detach" /> + <menu_item_call.on_enable + function="Attachment.EnableDetach" /> + </menu_item_call> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_avatar_icon.xml b/indra/newview/skins/minimal/xui/en/menu_avatar_icon.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_avatar_icon.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_avatar_other.xml b/indra/newview/skins/minimal/xui/en/menu_avatar_other.xml new file mode 100644 index 0000000000..b76629f401 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_avatar_other.xml @@ -0,0 +1,75 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- *NOTE: See also menu_attachment_other.xml --> +<context_menu + layout="topleft" + name="Avatar Pie"> + <menu_item_call + label="View Profile" + name="Profile..."> + <menu_item_call.on_click + function="ShowAgentProfile" + parameter="hit object" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Add Friend" + name="Add Friend"> + <menu_item_call.on_click + function="Avatar.AddFriend" /> + <menu_item_call.on_enable + function="Avatar.EnableAddFriend" /> + </menu_item_call> + <menu_item_call + label="IM" + name="Send IM..."> + <menu_item_call.on_click + function="Avatar.SendIM" /> + </menu_item_call> + <menu_item_separator /> + <menu_item_call + enabled="false" + label="Block" + name="Avatar Mute"> + <menu_item_call.on_click + function="Avatar.Mute" /> + <menu_item_call.on_enable + function="Avatar.EnableMute" /> + </menu_item_call> + <menu_item_call + label="Report" + name="abuse"> + <menu_item_call.on_click + function="Avatar.ReportAbuse" /> + </menu_item_call> + <menu_item_call + label="Freeze" + name="Freeze..."> + <menu_item_call.on_click + function="Avatar.Freeze" /> + <menu_item_call.on_visible + function="Avatar.EnableFreezeEject"/> + </menu_item_call> + <menu_item_call + label="Eject" + name="Eject..."> + <menu_item_call.on_click + function="Avatar.Eject" /> + <menu_item_call.on_visible + function="Avatar.EnableFreezeEject"/> + </menu_item_call> + <menu_item_call + label="Debug Textures" + name="Debug..."> + <menu_item_call.on_click + function="Avatar.Debug" /> + <menu_item_call.on_visible + function="IsGodCustomerService"/> + </menu_item_call> + <menu_item_call + label="Zoom In" + name="Zoom In"> + <menu_item_call.on_click + function="Tools.LookAtSelection" + parameter="zoom" /> + </menu_item_call> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_avatar_self.xml b/indra/newview/skins/minimal/xui/en/menu_avatar_self.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_avatar_self.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_bottomtray.xml b/indra/newview/skins/minimal/xui/en/menu_bottomtray.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_bottomtray.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_cof_attachment.xml b/indra/newview/skins/minimal/xui/en/menu_cof_attachment.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_cof_attachment.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_cof_body_part.xml b/indra/newview/skins/minimal/xui/en/menu_cof_body_part.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_cof_body_part.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_cof_clothing.xml b/indra/newview/skins/minimal/xui/en/menu_cof_clothing.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_cof_clothing.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_cof_gear.xml b/indra/newview/skins/minimal/xui/en/menu_cof_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_cof_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_edit.xml b/indra/newview/skins/minimal/xui/en/menu_edit.xml new file mode 100644 index 0000000000..747eb3fc6a --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_edit.xml @@ -0,0 +1,90 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu create_jump_keys="true" + label="Edit" + name="Edit" + visible="false"> + <menu_item_call + label="Undo" + name="Undo" + shortcut="control|Z"> + <menu_item_call.on_click + function="Edit.Undo" /> + <menu_item_call.on_enable + function="Edit.EnableUndo" /> + </menu_item_call> + <menu_item_call + label="Redo" + name="Redo" + shortcut="control|Y"> + <menu_item_call.on_click + function="Edit.Redo" /> + <menu_item_call.on_enable + function="Edit.EnableRedo" /> + </menu_item_call> + <menu_item_separator/> + <menu_item_call + label="Cut" + name="Cut" + shortcut="control|X"> + <menu_item_call.on_click + function="Edit.Cut" /> + <menu_item_call.on_enable + function="Edit.EnableCut" /> + </menu_item_call> + <menu_item_call + label="Copy" + name="Copy" + shortcut="control|C"> + <menu_item_call.on_click + function="Edit.Copy" /> + <menu_item_call.on_enable + function="Edit.EnableCopy" /> + </menu_item_call> + <menu_item_call + label="Paste" + name="Paste" + shortcut="control|V"> + <menu_item_call.on_click + function="Edit.Paste" /> + <menu_item_call.on_enable + function="Edit.EnablePaste" /> + </menu_item_call> + <menu_item_call + label="Delete" + name="Delete" + allow_key_repeat="true" + shortcut="Del"> + <menu_item_call.on_click + function="Edit.Delete" /> + <menu_item_call.on_enable + function="Edit.EnableDelete" /> + </menu_item_call> + <menu_item_call + label="Duplicate" + name="Duplicate" + shortcut="control|D"> + <menu_item_call.on_click + function="Edit.Duplicate" /> + <menu_item_call.on_enable + function="Edit.EnableDuplicate" /> + </menu_item_call> + <menu_item_separator/> + <menu_item_call + label="Select All" + name="Select All" + shortcut="control|A"> + <menu_item_call.on_click + function="Edit.SelectAll" /> + <menu_item_call.on_enable + function="Edit.EnableSelectAll" /> + </menu_item_call> + <menu_item_call + label="Deselect" + name="Deselect" + shortcut="control|E"> + <menu_item_call.on_click + function="Edit.Deselect" /> + <menu_item_call.on_enable + function="Edit.EnableDeselect" /> + </menu_item_call> +</menu>
\ No newline at end of file diff --git a/indra/newview/skins/minimal/xui/en/menu_favorites.xml b/indra/newview/skins/minimal/xui/en/menu_favorites.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_favorites.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_gesture_gear.xml b/indra/newview/skins/minimal/xui/en/menu_gesture_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_gesture_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_group_plus.xml b/indra/newview/skins/minimal/xui/en/menu_group_plus.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_group_plus.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_hide_navbar.xml b/indra/newview/skins/minimal/xui/en/menu_hide_navbar.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_hide_navbar.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_im_well_button.xml b/indra/newview/skins/minimal/xui/en/menu_im_well_button.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_im_well_button.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_imchiclet_adhoc.xml b/indra/newview/skins/minimal/xui/en/menu_imchiclet_adhoc.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_imchiclet_adhoc.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_imchiclet_group.xml b/indra/newview/skins/minimal/xui/en/menu_imchiclet_group.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_imchiclet_group.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_imchiclet_p2p.xml b/indra/newview/skins/minimal/xui/en/menu_imchiclet_p2p.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_imchiclet_p2p.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_inspect_avatar_gear.xml b/indra/newview/skins/minimal/xui/en/menu_inspect_avatar_gear.xml new file mode 100644 index 0000000000..5a4a059781 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inspect_avatar_gear.xml @@ -0,0 +1,116 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu + create_jump_keys="true" + layout="topleft" + mouse_opaque="false" + visible="false" + name="Gear Menu"> + <menu_item_call + label="View Profile" + enabled="true" + name="view_profile"> + <menu_item_call.on_click + function="InspectAvatar.ViewProfile"/> + </menu_item_call> + <menu_item_call + label="Add Friend" + name="add_friend"> + <menu_item_call.on_click + function="InspectAvatar.AddFriend"/> + <menu_item_call.on_enable + function="InspectAvatar.Gear.Enable"/> + </menu_item_call> + <menu_item_call + label="IM" + name="im"> + <menu_item_call.on_click + function="InspectAvatar.IM"/> + </menu_item_call> + <menu_item_call + label="Teleport" + name="teleport"> + <menu_item_call.on_click + function="InspectAvatar.Teleport"/> + <menu_item_call.on_enable + function="InspectAvatar.Gear.EnableTeleportOffer"/> + </menu_item_call> + <menu_item_separator /> + <menu_item_call + label="Block" + name="block"> + <menu_item_call.on_click + function="InspectAvatar.ToggleMute"/> + <menu_item_call.on_visible + function="InspectAvatar.EnableMute" /> + </menu_item_call> + <menu_item_call + label="Unblock" + name="unblock"> + <menu_item_call.on_click + function="InspectAvatar.ToggleMute"/> + <menu_item_call.on_visible + function="InspectAvatar.EnableUnmute" /> + </menu_item_call> + <menu_item_call + label="Report" + name="report"> + <menu_item_call.on_click + function="InspectAvatar.Report"/> + </menu_item_call> + <menu_item_call + label="Freeze" + name="freeze"> + <menu_item_call.on_click + function="InspectAvatar.Freeze"/> + <menu_item_call.on_visible + function="InspectAvatar.VisibleFreeze"/> + </menu_item_call> + <menu_item_call + label="Eject" + name="eject"> + <menu_item_call.on_click + function="InspectAvatar.Eject"/> + <menu_item_call.on_visible + function="InspectAvatar.VisibleEject"/> + </menu_item_call> + <menu_item_call + label="Kick" + name="kick"> + <menu_item_call.on_click + function="InspectAvatar.Kick"/> + <menu_item_call.on_visible + function="InspectAvatar.EnableGod"/> + </menu_item_call> + <menu_item_call + label="CSR" + name="csr"> + <menu_item_call.on_click + function="InspectAvatar.CSR" /> + <menu_item_call.on_visible + function="InspectAvatar.EnableGod" /> + </menu_item_call> + <menu_item_call + label="Debug Textures" + name="debug"> + <menu_item_call.on_click + function="Avatar.Debug"/> + <menu_item_call.on_visible + function="IsGodCustomerService"/> + </menu_item_call> + <menu_item_call + label="Find On Map" + name="find_on_map"> + <menu_item_call.on_click + function="InspectAvatar.FindOnMap"/> + <menu_item_call.on_visible + function="InspectAvatar.VisibleFindOnMap"/> + </menu_item_call> + <menu_item_call + label="Zoom In" + name="zoom_in"> + <menu_item_call.on_click + function="InspectAvatar.ZoomIn"/> + <menu_item_call.on_visible + function="InspectAvatar.VisibleZoomIn"/> + </menu_item_call> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_inspect_object_gear.xml b/indra/newview/skins/minimal/xui/en/menu_inspect_object_gear.xml new file mode 100644 index 0000000000..8ec360a604 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inspect_object_gear.xml @@ -0,0 +1,50 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu + create_jump_keys="true" + layout="topleft" + mouse_opaque="false" + visible="false" + name="Gear Menu"> + <menu_item_call + label="Touch" + layout="topleft" + enabled="true" + name="touch"> + <menu_item_call.on_click + function="InspectObject.Touch"/> + <menu_item_call.on_visible + function="Object.EnableTouch" /> + </menu_item_call> + <menu_item_call + label="Sit" + layout="topleft" + name="sit"> + <menu_item_call.on_click + function="InspectObject.Sit"/> + <menu_item_call.on_visible + function="Object.EnableSit"/> + </menu_item_call> + <menu_item_call + label="Report" + layout="topleft" + name="report"> + <menu_item_call.on_click + function="Object.ReportAbuse" /> + </menu_item_call> + <menu_item_call + label="Block" + layout="topleft" + name="block"> + <menu_item_call.on_click + function="Object.Mute" /> + <menu_item_call.on_visible + function="Object.EnableMute" /> + </menu_item_call> + <menu_item_call + label="Zoom In" + layout="topleft" + name="zoom_in"> + <menu_item_call.on_click + function="InspectObject.ZoomIn" /> + </menu_item_call> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_inspect_self_gear.xml b/indra/newview/skins/minimal/xui/en/menu_inspect_self_gear.xml new file mode 100644 index 0000000000..ae8b640d26 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inspect_self_gear.xml @@ -0,0 +1,49 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu + layout="topleft" + name="Self Pie"> + <menu_item_call + label="Sit Down" + layout="topleft" + name="Sit Down Here"> + <menu_item_call.on_click + function="Self.SitDown" + parameter="" /> + <menu_item_call.on_enable + function="Self.EnableSitDown" /> + </menu_item_call> + <menu_item_call + label="Stand Up" + layout="topleft" + name="Stand Up"> + <menu_item_call.on_click + function="Self.StandUp" + parameter="" /> + <menu_item_call.on_enable + function="Self.EnableStandUp" /> + </menu_item_call> + <menu_item_call + label="My Friends" + layout="topleft" + name="Friends..."> + <menu_item_call.on_click + function="SideTray.PanelPeopleTab" + parameter="friends_panel" /> + </menu_item_call> + <menu_item_call + label="My Profile" + layout="topleft" + name="Profile..."> + <menu_item_call.on_click + function="ShowAgentProfile" + parameter="agent" /> + </menu_item_call> + <menu_item_call + label="Debug Textures" + name="Debug..."> + <menu_item_call.on_click + function="Avatar.Debug" /> + <menu_item_call.on_visible + function="IsGodCustomerService"/> + </menu_item_call> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_inv_offer_chiclet.xml b/indra/newview/skins/minimal/xui/en/menu_inv_offer_chiclet.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inv_offer_chiclet.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_inventory.xml b/indra/newview/skins/minimal/xui/en/menu_inventory.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inventory.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_inventory_add.xml b/indra/newview/skins/minimal/xui/en/menu_inventory_add.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inventory_add.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_inventory_gear_default.xml b/indra/newview/skins/minimal/xui/en/menu_inventory_gear_default.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_inventory_gear_default.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_land.xml b/indra/newview/skins/minimal/xui/en/menu_land.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_land.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_landmark.xml b/indra/newview/skins/minimal/xui/en/menu_landmark.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_landmark.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_login.xml b/indra/newview/skins/minimal/xui/en/menu_login.xml new file mode 100644 index 0000000000..62dbce3f56 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_login.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu_bar/> diff --git a/indra/newview/skins/minimal/xui/en/menu_mini_map.xml b/indra/newview/skins/minimal/xui/en/menu_mini_map.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_mini_map.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_navbar.xml b/indra/newview/skins/minimal/xui/en/menu_navbar.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_navbar.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_nearby_chat.xml b/indra/newview/skins/minimal/xui/en/menu_nearby_chat.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_nearby_chat.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_notification_well_button.xml b/indra/newview/skins/minimal/xui/en/menu_notification_well_button.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_notification_well_button.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_object.xml b/indra/newview/skins/minimal/xui/en/menu_object.xml new file mode 100644 index 0000000000..888ce42cf1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_object.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu + layout="topleft" + name="Object Pie"> + <menu_item_call + enabled="false" + label="Sit Here" + name="Object Sit"> + <menu_item_call.on_click + function="Object.SitOrStand" /> + <menu_item_call.on_enable + function="Object.EnableSit" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Stand Up" + name="Object Stand Up"> + <menu_item_call.on_click + function="Object.SitOrStand" /> + <menu_item_call.on_enable + function="Object.EnableStandUp" /> + </menu_item_call> + <menu_item_call + label="Zoom In" + name="Zoom In"> + <menu_item_call.on_click + function="Object.ZoomIn" /> + </menu_item_call> + <menu_item_call + enabled="false" + label="Touch" + name="Object Touch"> + <menu_item_call.on_click + function="Object.Touch" /> + <menu_item_call.on_enable + function="Object.EnableTouch" + name="EnableTouch" + parameter="Touch" /> + </menu_item_call> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_object_icon.xml b/indra/newview/skins/minimal/xui/en/menu_object_icon.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_object_icon.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_outfit_gear.xml b/indra/newview/skins/minimal/xui/en/menu_outfit_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_outfit_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_outfit_tab.xml b/indra/newview/skins/minimal/xui/en/menu_outfit_tab.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_outfit_tab.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_participant_list.xml b/indra/newview/skins/minimal/xui/en/menu_participant_list.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_participant_list.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_friends_view_sort.xml b/indra/newview/skins/minimal/xui/en/menu_people_friends_view_sort.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_friends_view_sort.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_groups.xml b/indra/newview/skins/minimal/xui/en/menu_people_groups.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_groups.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_groups_view_sort.xml b/indra/newview/skins/minimal/xui/en/menu_people_groups_view_sort.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_groups_view_sort.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_nearby.xml b/indra/newview/skins/minimal/xui/en/menu_people_nearby.xml new file mode 100644 index 0000000000..3d64133f54 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_nearby.xml @@ -0,0 +1,61 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu + layout="topleft" + name="Avatar Context Menu"> + <menu_item_call + label="View Profile" + layout="topleft" + name="View Profile"> + <menu_item_call.on_click + function="Avatar.Profile" /> + </menu_item_call> + <menu_item_call + label="Add Friend" + layout="topleft" + name="Add Friend"> + <menu_item_call.on_click + function="Avatar.AddFriend" /> + <menu_item_call.on_enable + function="Avatar.EnableItem" + parameter="can_add" /> + </menu_item_call> + <menu_item_call + label="Remove Friend" + layout="topleft" + name="Remove Friend"> + <menu_item_call.on_click + function="Avatar.RemoveFriend" /> + <menu_item_call.on_enable + function="Avatar.EnableItem" + parameter="can_delete" /> + </menu_item_call> + <menu_item_call + label="IM" + layout="topleft" + name="IM"> + <menu_item_call.on_click + function="Avatar.IM" /> + </menu_item_call> + <menu_item_check + label="Block/Unblock" + layout="topleft" + name="Block/Unblock"> + <menu_item_check.on_click + function="Avatar.BlockUnblock" /> + <menu_item_check.on_check + function="Avatar.CheckItem" + parameter="is_blocked" /> + <menu_item_check.on_enable + function="Avatar.EnableItem" + parameter="can_block" /> + </menu_item_check> + <menu_item_call + label="Offer Teleport" + name="teleport"> + <menu_item_call.on_click + function="Avatar.OfferTeleport"/> + <menu_item_call.on_enable + function="Avatar.EnableItem" + parameter="can_offer_teleport"/> + </menu_item_call> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_nearby_multiselect.xml b/indra/newview/skins/minimal/xui/en/menu_people_nearby_multiselect.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_nearby_multiselect.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_nearby_view_sort.xml b/indra/newview/skins/minimal/xui/en/menu_people_nearby_view_sort.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_nearby_view_sort.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_people_recent_view_sort.xml b/indra/newview/skins/minimal/xui/en/menu_people_recent_view_sort.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_people_recent_view_sort.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_picks.xml b/indra/newview/skins/minimal/xui/en/menu_picks.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_picks.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_picks_plus.xml b/indra/newview/skins/minimal/xui/en/menu_picks_plus.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_picks_plus.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_place.xml b/indra/newview/skins/minimal/xui/en/menu_place.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_place.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_place_add_button.xml b/indra/newview/skins/minimal/xui/en/menu_place_add_button.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_place_add_button.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_places_gear_folder.xml b/indra/newview/skins/minimal/xui/en/menu_places_gear_folder.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_places_gear_folder.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_places_gear_landmark.xml b/indra/newview/skins/minimal/xui/en/menu_places_gear_landmark.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_places_gear_landmark.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_profile_overflow.xml b/indra/newview/skins/minimal/xui/en/menu_profile_overflow.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_profile_overflow.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_save_outfit.xml b/indra/newview/skins/minimal/xui/en/menu_save_outfit.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_save_outfit.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_script_chiclet.xml b/indra/newview/skins/minimal/xui/en/menu_script_chiclet.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_script_chiclet.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_slurl.xml b/indra/newview/skins/minimal/xui/en/menu_slurl.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_slurl.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_teleport_history_gear.xml b/indra/newview/skins/minimal/xui/en/menu_teleport_history_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_teleport_history_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_teleport_history_item.xml b/indra/newview/skins/minimal/xui/en/menu_teleport_history_item.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_teleport_history_item.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_teleport_history_tab.xml b/indra/newview/skins/minimal/xui/en/menu_teleport_history_tab.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_teleport_history_tab.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_text_editor.xml b/indra/newview/skins/minimal/xui/en/menu_text_editor.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_text_editor.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_topinfobar.xml b/indra/newview/skins/minimal/xui/en/menu_topinfobar.xml new file mode 100644 index 0000000000..9ebab9ef98 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_topinfobar.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_agent.xml b/indra/newview/skins/minimal/xui/en/menu_url_agent.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_agent.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_group.xml b/indra/newview/skins/minimal/xui/en/menu_url_group.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_group.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_http.xml b/indra/newview/skins/minimal/xui/en/menu_url_http.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_http.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_inventory.xml b/indra/newview/skins/minimal/xui/en/menu_url_inventory.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_inventory.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_map.xml b/indra/newview/skins/minimal/xui/en/menu_url_map.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_map.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_objectim.xml b/indra/newview/skins/minimal/xui/en/menu_url_objectim.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_objectim.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_parcel.xml b/indra/newview/skins/minimal/xui/en/menu_url_parcel.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_parcel.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_slapp.xml b/indra/newview/skins/minimal/xui/en/menu_url_slapp.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_slapp.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_slurl.xml b/indra/newview/skins/minimal/xui/en/menu_url_slurl.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_slurl.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_url_teleport.xml b/indra/newview/skins/minimal/xui/en/menu_url_teleport.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_url_teleport.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_viewer.xml b/indra/newview/skins/minimal/xui/en/menu_viewer.xml new file mode 100644 index 0000000000..cd83ea4e99 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_viewer.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<menu_bar + bg_visible="false" + follows="left|top|right" + name="Main Menu"> + <menu + create_jump_keys="true" + label="Help" + name="Help" + tear_off="true"> + <menu_item_call + label="[SECOND_LIFE] Help" + name="Second Life Help" + shortcut="F1"> + <menu_item_call.on_click + function="ShowHelp" + parameter="f1_help" /> + </menu_item_call> + </menu> + <menu + create_jump_keys="true" + label="Advanced" + name="Advanced" + tear_off="true" + visible="false"> + <menu + create_jump_keys="true" + label="Shortcuts" + name="Shortcuts" + tear_off="true" + visible="false"> + <menu_item_check + label="Fly" + name="Fly" + shortcut="Home"> + <menu_item_check.on_check + function="Agent.getFlying" /> + <menu_item_check.on_click + function="Agent.toggleFlying" /> + <menu_item_check.on_enable + function="Agent.enableFlying" /> + </menu_item_check> + <menu_item_call + label="Close Window" + name="Close Window" + shortcut="control|W"> + <menu_item_call.on_click + function="File.CloseWindow" /> + <menu_item_call.on_enable + function="File.EnableCloseWindow" /> + </menu_item_call> + <menu_item_call + label="Close All Windows" + name="Close All Windows" + shortcut="control|shift|W"> + <menu_item_call.on_click + function="File.CloseAllWindows" /> + <menu_item_call.on_enable + function="File.EnableCloseAllWindows" /> + </menu_item_call> + + <menu_item_call + label="Reset View" + name="Reset View" + shortcut="Esc"> + <menu_item_call.on_click + function="View.ResetView" /> + </menu_item_call> + </menu> <!--Shortcuts--> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/en/menu_wearable_list_item.xml b/indra/newview/skins/minimal/xui/en/menu_wearable_list_item.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_wearable_list_item.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_wearing_gear.xml b/indra/newview/skins/minimal/xui/en/menu_wearing_gear.xml new file mode 100644 index 0000000000..28c4762eaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_wearing_gear.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu/> diff --git a/indra/newview/skins/minimal/xui/en/menu_wearing_tab.xml b/indra/newview/skins/minimal/xui/en/menu_wearing_tab.xml new file mode 100644 index 0000000000..fb19c5eb2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/menu_wearing_tab.xml @@ -0,0 +1,2 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu/> diff --git a/indra/newview/skins/minimal/xui/en/notification_visibility.xml b/indra/newview/skins/minimal/xui/en/notification_visibility.xml new file mode 100644 index 0000000000..616b544847 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/notification_visibility.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" ?> +<notification_visibility> + <respond name="VoiceInviteP2P" response="Decline"/> + <respond name="VoiceInviteAdHoc" response="Decline"/> + <respond name="VoiceInviteGroup" response="Decline"/> + + <!-- group and voice are disabled features --> + <hide tag="group"/> + <hide tag="voice"/> + + <!-- no spammy scripts --> + <!-- <hide name="ScriptDialog"/> --> + + <!-- hints pertaining to UI we don't show --> + <hide name="FirstBalanceIncrease"/> + <hide name="FirstInventory"/> + <hide name="HintSidePanel"/> + <hide name="HintMove"/> + <hide name="HintDisplayName"/> + <hide name="HintInventory"/> + <hide name="HintLindenDollar"/> + + <!-- spam from servers, such as "Autopilot cancelled" --> + <hide name="SystemMessageTip"/> + + <!-- show everything else --> + <show/> +</notification_visibility> + diff --git a/indra/newview/skins/minimal/xui/en/notifications.xml b/indra/newview/skins/minimal/xui/en/notifications.xml new file mode 100644 index 0000000000..84da9472cc --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/notifications.xml @@ -0,0 +1,44 @@ +<?xml version="1.0" ?> +<notifications> + <notification + icon="notify.tga" + name="UserGiveItem" + type="offer"> + [NAME_SLURL] is offering you [ITEM_SLURL]. Using this item requires you to switch to Advanced mode where you will find the item in your Inventory. To switch to Advanced mode, quit and restart this application and change the mode setting on the login screen. + <form name="form"> + <button + index="4" + name="Show" + text="Keep Item"/> + <button + index="1" + name="Discard" + text="Reject Item"/> + <button + index="2" + name="Mute" + text="Block User"/> + </form> + </notification> + <notification + icon="notify.tga" + name="ObjectGiveItem" + type="offer"> + An object named <nolink>[OBJECTFROMNAME]</nolink> owned by [NAME_SLURL] is offering you [ITEM_SLURL]. Using this item requires you to switch to Advanced mode where you will find the item in your Inventory. To switch to Advanced mode, quit and restart this application and change the mode setting on the login screen. + <form name="form"> + <button + index="0" + name="Keep" + text="Keep Item"/> + <button + index="1" + name="Discard" + text="Reject Item"/> + <button + index="2" + name="Mute" + text="Block Object"/> + </form> + </notification> + +</notifications> diff --git a/indra/newview/skins/minimal/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/minimal/xui/en/panel_adhoc_control_panel.xml new file mode 100644 index 0000000000..5730adab8a --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_adhoc_control_panel.xml @@ -0,0 +1,46 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + border="false" + follows="all" + height="215" + name="panel_im_control_panel" + width="150"> + <layout_stack + mouse_opaque="false" + border_size="0" + clip="false" + follows="all" + height="215" + layout="topleft" + left="3" + name="vertical_stack" + orientation="vertical" + top="0" + width="147"> + <layout_panel + auto_resize="true" + follows="top|left" + height="130" + layout="topleft" + left="0" + min_height="0" + mouse_opaque="false" + width="147" + top="0" + name="speakers_list_panel" + user_resize="false"> + <avatar_list + color="DkGray2" + follows="all" + height="130" + ignore_online_status="true" + layout="topleft" + name="speakers_list" + opaque="false" + show_info_btn="true" + show_profile_btn="false" + show_speaking_indicator="false" + width="147" /> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml new file mode 100644 index 0000000000..0145de8be9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml @@ -0,0 +1,483 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + background_visible="true" + bg_alpha_color="DkGray" + bg_opaque_color="DkGray" + chrome="true" + follows="left|bottom|right" + height="33" + layout="topleft" + left="0" + name="bottom_tray" + focus_root="true" + top="28" + width="1310"> + <string + name="DragIndicationImageName" + value="Accordion_ArrowOpened_Off" /> + <string + name="SpeakBtnToolTip" + value="Turns microphone on/off" /> + <string + name="VoiceControlBtnToolTip" + value="Shows/hides voice control panel" /> + <layout_stack + border_size="0" + clip="false" + follows="all" + height="28" + layout="topleft" + left="0" + mouse_opaque="false" + name="toolbar_stack" + orientation="horizontal" + top="0" + width="1310"> + <layout_panel + auto_resize="false" + user_resize="false" + min_width="2" + width="2" /> + <layout_panel + auto_resize="false" + layout="topleft" + max_width="320" + min_width="214" + height="28" + mouse_opaque="false" + name="chat_bar_layout_panel" + user_resize="true" + width="308" > + <panel + name="chat_bar" + filename="panel_nearby_chat_bar.xml" + left="0" + height="28" + width="306" + top="0" + mouse_opaque="false" + follows="left|right" + /> + </layout_panel> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="65" + mouse_opaque="false" + name="gesture_panel" + top_delta="0" + user_resize="false" + width="85"> + <gesture_combo_list + follows="left|right" + height="23" + label="Gesture" + layout="topleft" + get_more="false" + view_all="false" + left="0" + name="Gesture" + tool_tip="Shows/hides gestures" + top="5" + width="82"> + <combo_button + pad_right="10" + can_drag="false" + use_ellipses="true" /> + <combo_list + page_lines="17" /> + </gesture_combo_list> + </layout_panel> + <layout_panel + auto_resize="false" + follows="left|right" + height="28" + layout="topleft" + min_height="28" + min_width="52" + mouse_opaque="false" + name="cam_panel" + user_resize="false" + width="83"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + is_toggle="true" + label="View" + layout="topleft" + left="0" + name="camera_btn" + tool_tip="Shows/hides camera controls" + top="5" + use_ellipses="true" + width="80"> + <init_callback + function="Button.SetDockableFloaterToggle" + parameter="camera" /> + </bottomtray_button> + </layout_panel> + <layout_panel + auto_resize="false" + follows="left|right" + height="28" + layout="topleft" + min_width="17" + name="splitter_panel" + user_resize="false" + width="17"> + <icon + follows="left|bottom" + height="18" + width="2" + left="6" + image_name="Button_Separator" + name="separator" + top="7"/> + </layout_panel> + <layout_panel + auto_resize="false" + follows="left|right" + height="28" + layout="topleft" + min_height="28" + min_width="83" + mouse_opaque="false" + name="avatar_and_destinations_panel" + user_resize="false" + width="103"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + label="Destinations" + layout="topleft" + left="0" + name="destination_btn" + tool_tip="Shows people window" + top="5" + is_toggle="true" + use_ellipses="true" + width="100"> + <bottomtray_button.commit_callback + function="Destination.show" /> + </bottomtray_button> + </layout_panel> + <layout_panel + auto_resize="false" + follows="left|right" + height="28" + layout="topleft" + min_height="28" + min_width="73" + mouse_opaque="false" + name="avatar_and_destinations_panel" + user_resize="false" + width="103"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + label="My Avatar" + layout="topleft" + left="0" + name="avatar_btn" + top="5" + is_toggle="true" + use_ellipses="true" + width="100"> + <bottomtray_button.commit_callback + function="Avatar.show" /> + </bottomtray_button> + </layout_panel> + <layout_panel + auto_resize="false" + follows="left|right" + height="28" + layout="topleft" + min_width="17" + name="splitter_panel" + user_resize="false" + width="17"> + <icon + follows="left|bottom" + height="18" + width="2" + left="6" + image_name="Button_Separator" + name="separator" + top="7"/> + </layout_panel> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="65" + mouse_opaque="false" + name="people_panel" + top_delta="0" + user_resize="false" + width="105"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + label="People" + layout="topleft" + left="0" + name="show_people_button" + tool_tip="Shows people window" + top="5" + is_toggle="true" + use_ellipses="true" + width="100"> + <bottomtray_button.commit_callback + function="ShowSidetrayPanel" + parameter="panel_people" /> + </bottomtray_button> + </layout_panel> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="65" + mouse_opaque="false" + name="profile_panel" + top_delta="0" + user_resize="false" + width="105"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + label="Profile" + layout="topleft" + left="0" + name="show_profile_btn" + tool_tip="Shows profile window" + is_toggle="true" + top="5" + use_ellipses="true" + width="100"> + <bottomtray_button.commit_callback + function="ToggleAgentProfile" + parameter="agent"/> + </bottomtray_button> + </layout_panel> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="65" + mouse_opaque="false" + name="howto_panel" + top_delta="0" + user_resize="false" + width="105"> + <bottomtray_button + can_drag="false" + follows="left|right" + height="23" + image_pressed="PushButton_Press" + image_pressed_selected="PushButton_Selected_Press" + image_selected="PushButton_Selected_Press" + label="How To" + layout="topleft" + left="0" + name="show_help_btn" + tool_tip="Open Second Life How To topics" + is_toggle="true" + top="5" + use_ellipses="true" + width="100"> + <bottomtray_button.commit_callback + function="ToggleHelp" + parameter="f1_help" /> + </bottomtray_button> + </layout_panel> + <layout_panel + follows="left|right" + height="30" + layout="topleft" + min_width="95" + mouse_opaque="false" + name="chiclet_list_panel" + top="0" + user_resize="false" + width="189"> + <!--*NOTE: min_width of the chiclet_panel (chiclet_list) must be the same +as for parent layout_panel (chiclet_list_panel) to resize bottom tray properly. EXT-991--> + <chiclet_panel + chiclet_padding="4" + follows="left|right" + height="24" + layout="topleft" + left="1" + min_width="95" + mouse_opaque="false" + name="chiclet_list" + top="7" + width="189"> + <button + auto_resize="true" + follows="right" + height="29" + image_hover_selected="SegmentedBtn_Left_Over" + image_hover_unselected="SegmentedBtn_Left_Over" + image_overlay="Arrow_Small_Left" + image_pressed="SegmentedBtn_Left_Press" + image_pressed_selected="SegmentedBtn_Left_Press" + image_selected="SegmentedBtn_Left_Off" + image_unselected="SegmentedBtn_Left_Off" + layout="topleft" + name="chicklet_left_scroll_button" + tab_stop="false" + top="-28" + visible="false" + width="7" /> + <button + auto_resize="true" + follows="right" + height="29" + image_hover_selected="SegmentedBtn_Right_Over" + image_hover_unselected="SegmentedBtn_Right_Over" + image_overlay="Arrow_Small_Right" + image_pressed="SegmentedBtn_Right_Press" + image_pressed_selected="SegmentedBtn_Right_Press" + image_selected="SegmentedBtn_Right_Off" + image_unselected="SegmentedBtn_Right_Off" + layout="topleft" + name="chicklet_right_scroll_button" + tab_stop="false" + top="-28" + visible="false" + width="7" /> + </chiclet_panel> + </layout_panel> + <layout_panel auto_resize="false" + user_resize="false" + width="4" + min_width="4"/> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="37" + name="im_well_panel" + top="0" + user_resize="false" + width="37"> + <chiclet_im_well + follows="right" + height="28" + layout="topleft" + left="0" + max_displayed_count="99" + name="im_well" + top="0" + width="35"> + <!-- +Emulate 4 states of button by background images, see details in EXT-3147. The same should be for notification_well button +xml attribute Description +image_unselected "Unlit" - there are no new messages +image_selected "Unlit" + "Selected" - there are no new messages and the Well is open +image_pressed "Lit" - there are new messages +image_pressed_selected "Lit" + "Selected" - there are new messages and the Well is open + --> + <button + auto_resize="true" + follows="right" + halign="center" + height="23" + image_overlay="Unread_IM" + image_overlay_alignment="center" + image_pressed="WellButton_Lit" + image_pressed_selected="WellButton_Lit_Selected" + image_selected="PushButton_Press" + label_color="Black" + left="0" + name="Unread IM messages" + tool_tip="Conversations" + width="34"> + <init_callback + function="Button.SetDockableFloaterToggle" + parameter="im_well_window" /> + </button> + </chiclet_im_well> + </layout_panel> + <layout_panel + auto_resize="false" + follows="right" + height="28" + layout="topleft" + min_height="28" + min_width="37" + name="notification_well_panel" + top="0" + user_resize="false" + width="37"> + <chiclet_notification + follows="right" + height="23" + layout="topleft" + left="0" + max_displayed_count="99" + name="notification_well" + top="5" + width="35"> + <button + auto_resize="true" + bottom_pad="3" + follows="right" + halign="center" + height="23" + image_overlay="Notices_Unread" + image_overlay_alignment="center" + image_pressed="WellButton_Lit" + image_pressed_selected="WellButton_Lit_Selected" + image_selected="PushButton_Press" + label_color="Black" + left="0" + name="Unread" + tool_tip="Notifications" + width="34"> + <init_callback + function="Button.SetDockableFloaterToggle" + parameter="notification_well_window" /> + </button> + </chiclet_notification> + </layout_panel> + <layout_panel + auto_resize="false" + user_resize="false" + min_width="4" + name="DUMMY2" + width="8" /> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_group_control_panel.xml b/indra/newview/skins/minimal/xui/en/panel_group_control_panel.xml new file mode 100644 index 0000000000..abddc59296 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_group_control_panel.xml @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + border="false" + follows="all" + height="238" + name="panel_im_control_panel" + width="150"> + <layout_stack + mouse_opaque="false" + border_size="0" + clip="false" + follows="all" + height="238" + layout="topleft" + left="5" + name="vertical_stack" + orientation="vertical" + top="0" + width="145"> + <layout_panel + auto_resize="true" + follows="top|left" + height="100" + layout="topleft" + min_height="0" + mouse_opaque="false" + width="145" + top="0" + name="speakers_list_panel" + user_resize="false"> + <avatar_list + color="DkGray2" + follows="all" + height="100" + ignore_online_status="true" + layout="topleft" + name="speakers_list" + opaque="false" + show_info_btn="true" + show_profile_btn="false" + show_speaking_indicator="false" + width="145" /> + </layout_panel> + <layout_panel + auto_resize="false" + follows="top|left|right" + height="28" + layout="topleft" + min_height="28" + width="130" + name="end_call_btn_panel" + user_resize="false" + visible="false"> + <button + follows="all" + height="23" + label="Leave Call" + name="end_call_btn" + use_ellipses="true" /> + </layout_panel> + <layout_panel + auto_resize="false" + follows="top|left|right" + height="28" + layout="topleft" + min_height="28" + width="130" + name="voice_ctrls_btn_panel" + user_resize="false" + visible="false"> + <button + follows="all" + height="23" + label="Open Voice Controls" + name="voice_ctrls_btn" + use_ellipses="true" /> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_im_control_panel.xml b/indra/newview/skins/minimal/xui/en/panel_im_control_panel.xml new file mode 100644 index 0000000000..53def54aca --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_im_control_panel.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + border="false" + height="300" + name="panel_im_control_panel" + width="150"> + <avatar_icon + follows="left|top" + height="105" + left_delta="20" + name="avatar_icon" + top="-5" + width="114"/> + <layout_stack + mouse_opaque="false" + border_size="0" + clip="false" + follows="all" + height="183" + layout="topleft" + left="5" + name="button_stack" + orientation="vertical" + top_pad="5" + width="145"> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_login.xml b/indra/newview/skins/minimal/xui/en/panel_login.xml new file mode 100644 index 0000000000..ef058e5567 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_login.xml @@ -0,0 +1,206 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel +follows="all" +height="600" +layout="topleft" +left="0" +name="panel_login" +focus_root="true" +top="600" + width="996"> +<panel.string + name="create_account_url"> + http://join.secondlife.com/ +</panel.string> +<string name="reg_in_client_url" translate="false"> + http://secondlife.eniac15.lindenlab.com/reg-in-client/ +</string> +<panel.string + name="forgot_password_url"> + http://secondlife.com/account/request.php +</panel.string> +<!-- *NOTE: Custom resize logic for login_html in llpanellogin.cpp --> +<web_browser + tab_stop="false" +trusted_content="true" +bg_opaque_color="Black" +border_visible="false" +bottom="600" +follows="all" +hide_loading="true" +left="0" +name="login_html" +start_url="" +top="0" +height="600" + width="980" /> +<layout_stack +follows="left|bottom|right" +name="login_widgets" +layout="topleft" +orientation="horizontal" +top="519" +width="996" +height="80"> +<layout_panel +auto_resize="false" +follows="left|bottom" +name="login" +layout="topleft" +width="570" +min_width="570" +user_resize="false" +height="80"> +<text +follows="left|bottom" +font="SansSerifSmall" +height="16" +name="username_text" +top="20" +left="20" +width="150"> +Username: +</text> + <combo_box + allow_text_entry="true" + follows="left|bottom" + height="22" + left_delta="0" + max_chars="128" + combo_editor.prevalidate_callback="ascii" + tool_tip="The username you chose when you registered, like bobsmith12 or Steller Sunshine" + top_pad="0" + name="username_combo" + width="178"> + <combo_box.combo_button + visible ="false"/> + <combo_box.drop_down_button + visible ="false"/> + </combo_box> +<text +follows="left|bottom" +font="SansSerifSmall" +height="15" +left_pad="-19" +name="password_text" +top="20" + width="150"> + Password: +</text> +<line_editor +follows="left|bottom" + height="22" +left_delta="0" + max_length_bytes="16" +name="password_edit" +is_password="true" +select_on_focus="true" + top_pad="0" + width="135" /> + <check_box +control_name="RememberPassword" +follows="left|bottom" +font="SansSerifSmall" +height="16" +label="Remember password" + top_pad="3" + name="remember_check" + width="135" /> +<button + follows="left|bottom" + height="23" + image_unselected="PushButton_On" + image_selected="PushButton_On_Selected" + label="Log In" + label_color="White" + layout="topleft" + left_pad="10" + name="connect_btn" + top="35" + width="90" /> + <text + follows="left|bottom" + font="SansSerifSmall" + height="15" + left_pad="10" + name="mode_selection_text" +top="20" + width="130"> + Mode: + </text> +<combo_box + follows="left|bottom" + height="23" + max_chars="128" + top_pad="0" + tool_tip="Select your mode. Choose Basic for fast, easy exploration and chat. Choose Advanced to access more features." + control_name="SessionSettingsFile" + name="mode_combo" + width="120"> +<combo_box.item + label="Basic" + name="Basic" + value="settings_minimal.xml" /> +<combo_box.item + label="Advanced" + name="Advanced" + value="" /> +</combo_box> +</layout_panel> +<layout_panel +tab_stop="false" +follows="right|bottom" +name="links" +width="205" +min_width="205" +user_resize="false" +height="80"> + <text +follows="right|bottom" +font="SansSerifSmall" +text_color="EmphasisColor" +halign="right" +height="16" +top="12" +right="-10" +name="create_new_account_text" + width="200"> + Sign up + </text> +<text +follows="right|bottom" +font="SansSerifSmall" +text_color="EmphasisColor" +halign="right" +height="16" +name="forgot_password_text" +top_pad="12" +right="-10" + width="200"> + Forgot your username or password? +</text> +<text +follows="right|bottom" +font="SansSerifSmall" +text_color="EmphasisColor" +halign="right" +height="16" +name="login_help" +top_pad="2" +right="-10" + width="200"> + Need help logging in? </text> +<!-- <text + follows="right|bottom" + font="SansSerifSmall" + halign="right" + height="28" + top_pad="2" + name="channel_text" + width="180" + word_wrap="true"> + [VERSION] + </text>--> + </layout_panel> +</layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_navigation_bar.xml b/indra/newview/skins/minimal/xui/en/panel_navigation_bar.xml new file mode 100644 index 0000000000..6dc1a1c9b0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_navigation_bar.xml @@ -0,0 +1,76 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + background_opaque="true" + background_visible="true" + bg_opaque_color="MouseGray" + follows="left|top|right" + height="26" + layout="topleft" + name="navigation_bar" + chrome="true" + width="600"> + <icon + follows="all" + image_name="NavBar_BG_NoFav_Bevel" + mouse_opaque="false" + name="bg_icon_no_fav_bevel" + scale_image="true" + visible="true" + left="0" + top="0" + height="26" + width="600"/> + <panel + background_visible="false" + follows="left|top|right" + top="3" + height="26" + layout="topleft" + name="navigation_panel" + width="600"> + <pull_button +follows="left|top" +direction="down" +height="23" +image_overlay="Arrow_Left_Off" +image_bottom_pad="1" +layout="topleft" +left="10" +name="back_btn" +tool_tip="Go back to previous location" +top="2" +width="31" /> + <pull_button + follows="left|top" + direction="down" + height="23" + image_overlay="Arrow_Right_Off" + image_bottom_pad="1" + layout="topleft" + left_pad="0" + name="forward_btn" + tool_tip="Go forward one location" + top_delta="0" + width="31" /> + <location_input + follows="left|right|top" + halign="right" + height="23" + label="Location" + layout="topleft" + left_pad="7" + max_chars="254" + mouse_opaque="false" + name="location_combo" + top_delta="0" + width="440"> + </location_input> + <icon follows="right" + height="20" + width="2" + left_pad="2" + image_name="Button_Separator" + name="separator" + top="2"/> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_people.xml b/indra/newview/skins/minimal/xui/en/panel_people.xml new file mode 100644 index 0000000000..4a72653d76 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_people.xml @@ -0,0 +1,550 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- Side tray panel --> +<panel + default_tab_group="1" + follows="all" + height="449" + label="People" + layout="topleft" + left="0" + min_height="350" + name="people_panel" + top="0" + width="333"> + <string + name="no_recent_people" + value="No recent people. Looking for people to hang out with? Try the Destinations button below." /> + <string + name="no_filtered_recent_people" + value="No recent people with that name." /> + <string + name="no_one_near" + value="No one nearby. Looking for people to hang out with? Try the Destinations button below." /> + <string + name="no_one_filtered_near" + value="No one nearby with that name." /> + <string + name="no_friends_online" + value="No friends online" /> + <string + name="no_friends" + value="No friends" /> + <string + name="no_friends_msg"> + Right-click on a Resident to add them as a friend. +Looking for people to hang out with? Try the Destinations button below. + </string> + <string + name="no_filtered_friends_msg"> + Didn't find what you're looking for? Try the Destinations button below.. + </string> + <string + name="people_filter_label" + value="Filter People" /> + <string + name="groups_filter_label" + value="Filter Groups" /> + <!-- + *WORKAROUND: for group_list.no_items_msg & group_list.no_filtered_items_msg attributes. + They are not defined as translatable in VLT. See EXT-5931 + --> + <string + name="no_filtered_groups_msg" + value="Didn't find what you're looking for? Try [secondlife:///app/search/groups/[SEARCH_TERM] Search]." /> + <string + name="no_groups_msg" + value="Looking for Groups to join? Try [secondlife:///app/search/groups Search]." /> + <string + name="MiniMapToolTipMsg" + value="[REGION](Double-click to open Map, shift-drag to pan)"/> + <string + name="AltMiniMapToolTipMsg" + value="[REGION](Double-click to teleport, shift-drag to pan)"/> + <filter_editor + follows="left|top|right" + height="23" + layout="topleft" + left="10" + label="Filter" + max_length="300" + name="filter_input" + text_color="Black" + text_pad_left="10" + top="3" + width="303" /> + <tab_container + follows="all" + height="383" + layout="topleft" + left="5" + name="tabs" + tab_group="1" + tab_min_width="70" + tab_height="30" + tab_position="top" + top_pad="10" + halign="center" + width="317"> + <panel + background_opaque="true" + background_visible="true" + bg_alpha_color="DkGray" + bg_opaque_color="DkGray" + follows="all" + height="383" + label="NEARBY" + layout="topleft" + left="0" + help_topic="people_nearby_tab" + name="nearby_panel" + top="0" + width="313"> + <net_map + bg_color="NetMapBackgroundColor" + follows="top|left|right" + layout="topleft" + left="3" + mouse_opaque="false" + name="Net Map" + width="307" + height="140" + top="0"/> + <avatar_list + allow_select="true" + follows="top|left|bottom|right" + height="216" + ignore_online_status="true" + layout="topleft" + left="3" + multi_select="true" + name="avatar_list" + top="145" + width="307" /> + <panel + background_visible="true" + follows="left|right|bottom" + height="27" + label="bottom_panel" + layout="topleft" + left="3" + name="bottom_panel" + top_pad="0" + width="313"> + <icon + follows="bottom|left|right" + height="25" + image_name="Toolbar_Right_Off" + layout="topleft" + left_pad="1" + name="dummy_icon" + width="241" + /> + </panel> + </panel> + <panel + background_opaque="true" + background_visible="true" + bg_alpha_color="DkGray" + bg_opaque_color="DkGray" + follows="all" + height="383" + label="MY FRIENDS" + layout="topleft" + left="0" + help_topic="people_friends_tab" + name="friends_panel" + top="0" + width="313"> + <accordion + background_visible="true" + bg_alpha_color="DkGray2" + bg_opaque_color="DkGray2" + follows="all" + height="356" + layout="topleft" + left="3" + name="friends_accordion" + top="0" + width="307"> + <accordion_tab + layout="topleft" + height="172" + min_height="150" + name="tab_online" + title="Online"> + <avatar_list + allow_select="true" + follows="all" + height="172" + layout="topleft" + left="0" + multi_select="true" + name="avatars_online" + show_permissions_granted="true" + top="0" + width="307" /> + </accordion_tab> + <accordion_tab + layout="topleft" + height="173" + name="tab_all" + title="All"> + <avatar_list + allow_select="true" + follows="all" + height="173" + layout="topleft" + left="0" + multi_select="true" + name="avatars_all" + show_permissions_granted="true" + top="0" + width="307" /> + </accordion_tab> + </accordion> + <panel + background_visible="true" + follows="left|right|bottom" + height="27" + label="bottom_panel" + layout="topleft" + left="3" + name="bottom_panel" + top_pad="0" + width="313"> + + <layout_stack + animate="false" + border_size="0" + follows="left|right|bottom" + height="25" + layout="topleft" + orientation="horizontal" + top_pad="1" + left="0" + name="bottom_panel" + width="305"> + <layout_panel + auto_resize="true" + height="25" + layout="topleft" + name="dummy_panel" + user_resize="false" + width="212"> + <icon + follows="bottom|left|right" + height="25" + image_name="Toolbar_Middle_Off" + layout="topleft" + left="0" + top="0" + name="dummy_icon" + width="211" /> + </layout_panel> + <layout_panel + auto_resize="false" + height="25" + layout="topleft" + name="trash_btn_panel" + user_resize="false" + width="31"> + <dnd_button + follows="bottom|left" + height="25" + image_hover_unselected="Toolbar_Right_Over" + image_overlay="TrashItem_Off" + image_selected="Toolbar_Right_Selected" + image_unselected="Toolbar_Right_Off" + left="0" + layout="topleft" + name="del_btn" + tool_tip="Remove selected person from your Friends list" + top="0" + width="31"/> + </layout_panel> + </layout_stack><!-- + + <button + follows="bottom|left" + tool_tip="Options" + height="25" + image_hover_unselected="Toolbar_Left_Over" + image_overlay="OptionsMenu_Off" + image_selected="Toolbar_Left_Selected" + image_unselected="Toolbar_Left_Off" + layout="topleft" + left="0" + name="friends_viewsort_btn" + top="1" + width="31" /> + <button + follows="bottom|left" + height="25" + image_hover_unselected="Toolbar_Middle_Over" + image_overlay="AddItem_Off" + image_selected="Toolbar_Middle_Selected" + image_unselected="Toolbar_Middle_Off" + layout="topleft" + left_pad="1" + name="add_btn" + tool_tip="Offer friendship to a Resident" + width="31" /> + <icon + follows="bottom|left|right" + height="25" + image_name="Toolbar_Middle_Off" + layout="topleft" + left_pad="1" + name="dummy_icon" + width="209" + /> + <button + follows="bottom|left" + height="25" + image_hover_unselected="Toolbar_Right_Over" + image_overlay="TrashItem_Off" + image_selected="Toolbar_Right_Selected" + image_unselected="Toolbar_Right_Off" + layout="topleft" + left_pad="1" + name="del_btn" + tool_tip="Remove selected person from your Friends list" + width="31" /> + --></panel> + <text + follows="all" + height="450" + left="13" + name="no_friends_help_text" + top="10" + width="293" + wrap="true" /> + </panel> + <panel + background_opaque="true" + background_visible="true" + bg_alpha_color="DkGray" + bg_opaque_color="DkGray" + follows="all" + height="383" + label="RECENT" + layout="topleft" + left="0" + help_topic="people_recent_tab" + name="recent_panel" + top="0" + width="313"> + <avatar_list + allow_select="true" + follows="all" + height="356" + layout="topleft" + left="3" + multi_select="true" + name="avatar_list" + show_last_interaction_time="true" + top="0" + width="307" /> + <panel + background_visible="true" + follows="left|right|bottom" + height="27" + label="bottom_panel" + layout="topleft" + left="0" + name="bottom_panel" + top_pad="0" + width="313"> + <button + follows="bottom|left" + height="25" + image_hover_unselected="Toolbar_Middle_Over" + image_overlay="AddItem_Off" + image_selected="Toolbar_Middle_Selected" + image_unselected="Toolbar_Middle_Off" + layout="topleft" + left_pad="1" + name="add_friend_btn" + tool_tip="Add selected Resident to your friends List" + width="31"> + <commit_callback + function="People.addFriend" /> + </button> + <icon + follows="bottom|left|right" + height="25" + image_name="Toolbar_Right_Off" + layout="topleft" + left_pad="1" + name="dummy_icon" + width="241" + /> + </panel> + </panel> + </tab_container> + <panel + follows="bottom|left|right" + height="23" + layout="topleft" + left="8" + top_pad="4" + name="button_bar" + width="313"> + +<!--********************************Profile; IM; Call, Share, Teleport********************************--> + <layout_stack + follows="bottom|left|right" + height="23" + layout="topleft" + name="bottom_bar_ls" + left="0" + orientation="horizontal" + top_pad="0" + width="313"> + + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left="0" + name="view_profile_btn_lp" + user_resize="false" + auto_resize="true" + width="68"> + <button + follows="bottom|left|right" + height="23" + label="Profile" + layout="topleft" + left="1" + name="view_profile_btn" + tool_tip="Show picture, groups, and other Residents information" + top="0" + width="67" /> + </layout_panel> + + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left_pad="3" + name="chat_btn_lp" + user_resize="false" + auto_resize="true" + width="41"> + <button + follows="bottom|left|right" + left="1" + height="23" + label="IM" + layout="topleft" + name="im_btn" + tool_tip="Open instant message session" + top="0" + width="40" /> + </layout_panel> + + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left_pad="3" + name="chat_btn_lp" + user_resize="false" + auto_resize="true" + width="77"> + <button + follows="bottom|left|right" + left="1" + height="23" + label="Teleport" + layout="topleft" + name="teleport_btn" + tool_tip="Offer teleport" + top="0" + width="76" /> + </layout_panel> + </layout_stack> + +<!--********************************Group Profile; Group Chat; Group Call buttons************************--> + <layout_stack + follows="bottom|left|right" + height="23" + layout="topleft" + mouse_opaque="false" + name="bottom_bar_ls1" + left="0" + orientation="horizontal" + top="0" + width="313"> + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left="0" + mouse_opaque="false" + name="group_info_btn_lp" + user_resize="false" + auto_resize="true" + width="108"> + <button + follows="bottom|left|right" + left="1" + height="23" + label="Group Profile" + layout="topleft" + mouse_opaque="false" + name="group_info_btn" + tool_tip="Show group information" + top="0" + width="107" /> + </layout_panel> + + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left_pad="3" + mouse_opaque="false" + name="chat_btn_lp" + user_resize="false" + auto_resize="true" + width="101"> + <button + follows="bottom|left|right" + left="1" + height="23" + label="Group Chat" + layout="topleft" + mouse_opaque="false" + name="chat_btn" + tool_tip="Open chat session" + top="0" + width="100" /> + </layout_panel> + + <layout_panel + follows="bottom|left|right" + height="23" + layout="bottomleft" + left_pad="3" + mouse_opaque="false" + name="group_call_btn_lp" + user_resize="false" + auto_resize="true" + width="96"> + <button + follows="bottom|left|right" + left="1" + height="23" + label="Group Call" + layout="topleft" + mouse_opaque="false" + name="group_call_btn" + tool_tip="Call this group" + top="0" + width="95" /> + </layout_panel> + </layout_stack> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_side_tray_tab_caption.xml b/indra/newview/skins/minimal/xui/en/panel_side_tray_tab_caption.xml new file mode 100644 index 0000000000..9f2f41ba31 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_side_tray_tab_caption.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + background_visible="true" + bottom="0" + follows="left|top|right" + height="5" + width="333" + layout="topleft" + left="0" + name="sidetray_tab_panel"> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_status_bar.xml b/indra/newview/skins/minimal/xui/en/panel_status_bar.xml new file mode 100644 index 0000000000..6ccd0e938d --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_status_bar.xml @@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + background_opaque="true" + background_visible="true" + bg_opaque_color="MouseGray" + chrome="true" + follows="top|right" + height="30" + layout="topleft" + left="0" + mouse_opaque="false" + name="status" + top="19" + tab_stop="false" + width="70"> + <panel.string + name="packet_loss_tooltip"> + Packet Loss + </panel.string> + <panel.string + name="bandwidth_tooltip"> + Bandwidth + </panel.string> + <panel.string + name="time"> + [hour12, datetime, slt]:[min, datetime, slt] [ampm, datetime, slt] [timezone,datetime, slt] + </panel.string> + <panel.string + name="timeTooltip"> + [weekday, datetime, slt], [day, datetime, slt] [month, datetime, slt] [year, datetime, slt] + </panel.string> + <panel.string + name="buycurrencylabel"> + L$ [AMT] + </panel.string> + <button + follows="right|top" + height="16" + image_selected="Play_Off" + image_unselected="Pause_Off" + image_pressed="Pause_Press" + image_pressed_selected="Play_Press" + is_toggle="true" + left="15" + top="7" + name="media_toggle_btn" + tool_tip="Start/Stop All Media (Music, Video, Web pages)" + width="16" > + </button> + <button + follows="right|top" + height="16" + image_selected="AudioMute_Off" + image_pressed="Audio_Press" + image_unselected="Audio_Off" + is_toggle="true" + left_pad="5" + top="8" + name="volume_btn" + tool_tip="Global Volume Control" + width="16" /> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/panel_volume_pulldown.xml b/indra/newview/skins/minimal/xui/en/panel_volume_pulldown.xml new file mode 100644 index 0000000000..36ad39abe8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/panel_volume_pulldown.xml @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<panel + background_opaque="true" + background_visible="true" + bg_opaque_image="Volume_Background" + bg_alpha_image="Volume_Background" + border_visible="false" + border="false" + chrome="true" + follows="bottom" + height="150" + layout="topleft" + name="volumepulldown_floater" + width="32"> + <slider + control_name="AudioLevelMaster" + follows="left|top" + left="0" + top="1" + orientation="vertical" + height="140" + increment="0.05" + initial_value="0.5" + layout="topleft" + name="mastervolume" + show_text="false" + slider_label.halign="right" + top_pad="2" + volume="true"> + <slider.commit_callback + function="Vol.setControlFalse" + parameter="MuteAudio" /> + </slider> +</panel> diff --git a/indra/newview/skins/minimal/xui/en/widgets/location_input.xml b/indra/newview/skins/minimal/xui/en/widgets/location_input.xml new file mode 100644 index 0000000000..fe06a2d816 --- /dev/null +++ b/indra/newview/skins/minimal/xui/en/widgets/location_input.xml @@ -0,0 +1,131 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<!-- +*TODO: Replace hardcoded buttons width/height with getting this info from the button images. + Currently that doesn't work because LLUIImage::getWidth/getHeight() return 1 for the images. +--> +<location_input font="SansSerifSmall" + maturity_help_topic="maturity_rating" + add_landmark_hpad="0" + icon_hpad="2" + allow_text_entry="true" + list_position="below" + show_text_as_tentative="false" + max_chars="20" + follows="left|top" + allow_new_values="true" + > + <!-- *NOTE: Tooltips are in strings.xml so they can be localized. + See LocationCtrlAddLandmarkTooltip etc. --> + <info_button + name="Place Information" + width="0" + height="0" + visible="false" + left="6" + top="20" + follows="left|top" + hover_glow_amount="0.15" /> + <add_landmark_button name="Add Landmark" + hover_glow_amount="0.15" + width="0" + height="0" + visible="false" + follows="right|top" + scale_image="false" + top="19" + left="-3" /> + <maturity_button + name="maturity_icon" + width="0" + height="0" + visible="false" + top="20" + follows="left|top" + /> + <for_sale_button + name="for_sale_btn" + width="0" + height="0" + visible="false" + follows="right|top" + scale_image="false" + top="21" + /> + <voice_icon + enabled="true" + name="voice_icon" + width="0" + height="0" + visible="false" + top="21" + follows="right|top" + /> + <fly_icon + name="fly_icon" + width="0" + height="0" + visible="false" + top="21" + follows="right|top" + /> + <push_icon + name="push_icon" + width="0" + height="0" + visible="false" + top="21" + follows="right|top" + /> + <build_icon + name="build_icon" + width="0" + height="0" + visible="false" + top="21" + follows="right|top" + /> + <scripts_icon + name="scripts_icon" + width="0" + height="0" + visible="false" + top="21" + follows="right|top" + /> + <damage_icon + name="damage_icon" + width="0" + height="0" + visible="false" + top="19" + left="2" + follows="right|top" + /> + <!-- Default text color is invisible on top of nav bar background --> + <damage_text + name="damage_text" + width="0" + height="0" + max_length="0" + top="17" + follows="right|top" + halign="right" + font="SansSerifSmall" + text_color="TextFgColor" + /> + <combo_button + name="Location History" + label="" + pad_right="0"/> + <combo_list + bg_writeable_color="MenuDefaultBgColor" + page_lines="10" + scroll_bar_bg_visible="true" /> + <combo_editor name="Combo Text Entry" + text_pad_left="4" + select_on_focus="false" + font="SansSerifSmall" + bevel_style="none" + border_style="line" + border.border_thickness="0" /> +</location_input> diff --git a/indra/newview/skins/minimal/xui/es/floater_camera.xml b/indra/newview/skins/minimal/xui/es/floater_camera.xml new file mode 100644 index 0000000000..ccf3d4bf91 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/floater_camera.xml @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="camera_floater" title=""> + <floater.string name="rotate_tooltip"> + Girar la cámara alrededor de lo enfocado + </floater.string> + <floater.string name="zoom_tooltip"> + Hacer zoom con la cámara en lo enfocado + </floater.string> + <floater.string name="move_tooltip"> + Mover la cámara arriba y abajo, izquierda y derecha + </floater.string> + <floater.string name="camera_modes_title"> + Modos de cámara + </floater.string> + <floater.string name="pan_mode_title"> + Orbital - Zoom - Panóramica + </floater.string> + <floater.string name="presets_mode_title"> + Vistas predefinidas + </floater.string> + <floater.string name="free_mode_title"> + Centrar el objeto + </floater.string> + <panel name="controls"> + <panel name="preset_views_list"> + <panel_camera_item name="front_view"> + <panel_camera_item.text name="front_view_text"> + De frente + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="group_view"> + <panel_camera_item.text name="side_view_text"> + Vista lateral + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="rear_view"> + <panel_camera_item.text name="rear_view_text"> + Desde detrás + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="camera_modes_list"> + <panel_camera_item name="object_view"> + <panel_camera_item.text name="object_view_text"> + Vista de objeto + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="mouselook_view"> + <panel_camera_item.text name="mouselook_view_text"> + Vista subjetiva + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="zoom" tool_tip="Hacer zoom con la cámara en lo enfocado"> + <joystick_rotate name="cam_rotate_stick" tool_tip="La cámara gira alrededor del punto de vista"/> + <slider_bar name="zoom_slider" tool_tip="Hacer zoom en lo enfocado"/> + <joystick_track name="cam_track_stick" tool_tip="Mueve la cámara arriba y abajo, a izquierda y derecha"/> + </panel> + </panel> + <panel name="buttons"> + <button label="" name="presets_btn" tool_tip="Vistas predefinidas"/> + <button label="" name="pan_btn" tool_tip="Orbital - Zoom - Panóramica"/> + <button label="" name="avatarview_btn" tool_tip="Modos de cámara"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/es/floater_help_browser.xml b/indra/newview/skins/minimal/xui/es/floater_help_browser.xml new file mode 100644 index 0000000000..67590ebfbb --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/floater_help_browser.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="floater_help_browser" title="INDICACIONES"> + <floater.string name="loading_text"> + Cargando... + </floater.string> + <layout_stack name="stack1"> + <layout_panel name="external_controls"/> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/es/floater_nearby_chat.xml b/indra/newview/skins/minimal/xui/es/floater_nearby_chat.xml new file mode 100644 index 0000000000..1fee9ab056 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/floater_nearby_chat.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="nearby_chat" title="CHAT"> + <check_box label="Traducir chat (mediante Google)" name="translate_chat_checkbox"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/es/inspect_avatar.xml b/indra/newview/skins/minimal/xui/es/inspect_avatar.xml new file mode 100644 index 0000000000..1d70fa6a90 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/inspect_avatar.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_avatar"> + <string name="Subtitle"> + [AGE] + </string> + <string name="Details"> + [SL_PROFILE] + </string> + <text name="user_details"> + Ésta es mi descripción de Second Life que, por cierto, me encanta. Pero, por lo que sea, me he enrollado más de la cuenta y la descripción es larguísima. + </text> + <slider name="volume_slider" tool_tip="Volumen de la voz" value="0.5"/> + <button label="Añadir como amigo" name="add_friend_btn"/> + <button label="MI" name="im_btn"/> + <button label="Perfil" name="view_profile_btn"/> + <panel name="moderator_panel"> + <button label="Desactivar la voz" name="disable_voice"/> + <button label="Activar la voz" name="enable_voice"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/es/inspect_object.xml b/indra/newview/skins/minimal/xui/es/inspect_object.xml new file mode 100644 index 0000000000..d608b4a0f7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/inspect_object.xml @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_object"> + <string name="Creator"> + Por [CREATOR] + </string> + <string name="CreatorAndOwner"> + Por [CREATOR] +Propietario [OWNER] + </string> + <string name="Price"> + [AMOUNT] L$ + </string> + <string name="PriceFree"> + ¡Gratis! + </string> + <string name="Touch"> + Tocar + </string> + <string name="Sit"> + Sentarme + </string> + <text name="object_name" value="Test Object Name That Is actually two lines and Really Long"/> + <text name="price_text"> + 30.000 L$ + </text> + <text name="object_description"> + This is a really long description for an object being as how it is at least 80 characters in length and so but maybe more like 120 at this point. Who knows, really? + </text> + <button label="Comprar" name="buy_btn"/> + <button label="Pagar" name="pay_btn"/> + <button label="Coger una copia" name="take_free_copy_btn"/> + <button label="Tocar" name="touch_btn"/> + <button label="Sentarme" name="sit_btn"/> + <button label="Abrir" name="open_btn"/> + <icon name="secure_browsing" tool_tip="Navegación segura"/> + <button label="Más" name="more_info_btn"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/es/menu_add_wearable_gear.xml b/indra/newview/skins/minimal/xui/es/menu_add_wearable_gear.xml new file mode 100644 index 0000000000..f2367c72a3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_add_wearable_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Add Wearable Gear Menu"> + <menu_item_check label="Ordenar por los más recientes" name="sort_by_most_recent"/> + <menu_item_check label="Ordenar alfabéticamente" name="sort_by_name"/> + <menu_item_check label="Ordenar por tipo" name="sort_by_type"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_attachment_other.xml b/indra/newview/skins/minimal/xui/es/menu_attachment_other.xml new file mode 100644 index 0000000000..00bdb74881 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_attachment_other.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_avatar_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Ver el perfil" name="Profile..."/> + <menu_item_call label="Añadir como amigo" name="Add Friend"/> + <menu_item_call label="MI" name="Send IM..."/> + <menu_item_call label="Llamada" name="Call"/> + <menu_item_call label="Invitar al grupo" name="Invite..."/> + <menu_item_call label="Ignorar" name="Avatar Mute"/> + <menu_item_call label="Denunciar" name="abuse"/> + <menu_item_call label="Congelar" name="Freeze..."/> + <menu_item_call label="Expulsar" name="Eject..."/> + <menu_item_call label="Depurar las texturas" name="Debug..."/> + <menu_item_call label="Acercar el zoom" name="Zoom In"/> + <menu_item_call label="Pagar" name="Pay..."/> + <menu_item_call label="Perfil del objeto" name="Object Inspect"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_attachment_self.xml b/indra/newview/skins/minimal/xui/es/menu_attachment_self.xml new file mode 100644 index 0000000000..ab76c92d65 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_attachment_self.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Attachment Pie"> + <menu_item_call label="Tocar" name="Attachment Object Touch"/> + <menu_item_call label="Editar" name="Edit..."/> + <menu_item_call label="Quitar" name="Detach"/> + <menu_item_call label="Sentarte" name="Sit Down Here"/> + <menu_item_call label="Levantarme" name="Stand Up"/> + <menu_item_call label="Cambiar vestuario" name="Change Outfit"/> + <menu_item_call label="Editar mi vestuario" name="Edit Outfit"/> + <menu_item_call label="Editar mi anatomía" name="Edit My Shape"/> + <menu_item_call label="Mis amigos" name="Friends..."/> + <menu_item_call label="Mis grupos" name="Groups..."/> + <menu_item_call label="Mi perfil" name="Profile..."/> + <menu_item_call label="Depurar las texturas" name="Debug..."/> + <menu_item_call label="Soltar" name="Drop"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_avatar_icon.xml b/indra/newview/skins/minimal/xui/es/menu_avatar_icon.xml new file mode 100644 index 0000000000..fe7331a108 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_avatar_icon.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Avatar Icon Menu"> + <menu_item_call label="Ver el perfil" name="Show Profile"/> + <menu_item_call label="Enviar un MI..." name="Send IM"/> + <menu_item_call label="Añadir como amigo..." name="Add Friend"/> + <menu_item_call label="Quitar de los amigos..." name="Remove Friend"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_avatar_other.xml b/indra/newview/skins/minimal/xui/es/menu_avatar_other.xml new file mode 100644 index 0000000000..7df2d7c4e0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_avatar_other.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_attachment_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Ver el perfil" name="Profile..."/> + <menu_item_call label="Añadir como amigo" name="Add Friend"/> + <menu_item_call label="MI" name="Send IM..."/> + <menu_item_call label="Llamada" name="Call"/> + <menu_item_call label="Invitar al grupo" name="Invite..."/> + <menu_item_call label="Ignorar" name="Avatar Mute"/> + <menu_item_call label="Denunciar" name="abuse"/> + <menu_item_call label="Congelar" name="Freeze..."/> + <menu_item_call label="Expulsar" name="Eject..."/> + <menu_item_call label="Depurar las texturas" name="Debug..."/> + <menu_item_call label="Acercar el zoom" name="Zoom In"/> + <menu_item_call label="Pagar" name="Pay..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_avatar_self.xml b/indra/newview/skins/minimal/xui/es/menu_avatar_self.xml new file mode 100644 index 0000000000..50f8384b0f --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_avatar_self.xml @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Self Pie"> + <menu_item_call label="Sentarte" name="Sit Down Here"/> + <menu_item_call label="Levantarme" name="Stand Up"/> + <context_menu label="Quitarme" name="Take Off >"> + <context_menu label="Ropas" name="Clothes >"> + <menu_item_call label="Camisa" name="Shirt"/> + <menu_item_call label="Pantalón" name="Pants"/> + <menu_item_call label="Falda" name="Skirt"/> + <menu_item_call label="Zapatos" name="Shoes"/> + <menu_item_call label="Calcetines" name="Socks"/> + <menu_item_call label="Chaqueta" name="Jacket"/> + <menu_item_call label="Guantes" name="Gloves"/> + <menu_item_call label="Camiseta" name="Self Undershirt"/> + <menu_item_call label="Ropa interior" name="Self Underpants"/> + <menu_item_call label="Tatuaje" name="Self Tattoo"/> + <menu_item_call label="Alfa" name="Self Alpha"/> + <menu_item_call label="Toda la ropa" name="All Clothes"/> + </context_menu> + <context_menu label="HUD" name="Object Detach HUD"/> + <context_menu label="Quitar" name="Object Detach"/> + <menu_item_call label="Quitarse todo" name="Detach All"/> + </context_menu> + <menu_item_call label="Cambiar vestuario" name="Chenge Outfit"/> + <menu_item_call label="Editar mi vestuario" name="Edit Outfit"/> + <menu_item_call label="Editar mi anatomía" name="Edit My Shape"/> + <menu_item_call label="Mis amigos" name="Friends..."/> + <menu_item_call label="Mis grupos" name="Groups..."/> + <menu_item_call label="Mi perfil" name="Profile..."/> + <menu_item_call label="Depurar las texturas" name="Debug..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_bottomtray.xml b/indra/newview/skins/minimal/xui/es/menu_bottomtray.xml new file mode 100644 index 0000000000..62683f3076 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_bottomtray.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_camera_move_controls_menu"> + <menu_item_check label="Botón Gestos" name="ShowGestureButton"/> + <menu_item_check label="Botón Moverse" name="ShowMoveButton"/> + <menu_item_check label="Botón Vista" name="ShowCameraButton"/> + <menu_item_check label="Botón Foto" name="ShowSnapshotButton"/> + <menu_item_check label="Botón Barra lateral" name="ShowSidebarButton"/> + <menu_item_check label="Botón Construir" name="ShowBuildButton"/> + <menu_item_check label="Botón Buscar" name="ShowSearchButton"/> + <menu_item_check label="Botón Mapa" name="ShowWorldMapButton"/> + <menu_item_check label="Botón Minimapa" name="ShowMiniMapButton"/> + <menu_item_call label="Cortar" name="NearbyChatBar_Cut"/> + <menu_item_call label="Copiar" name="NearbyChatBar_Copy"/> + <menu_item_call label="Pegar" name="NearbyChatBar_Paste"/> + <menu_item_call label="Borrar" name="NearbyChatBar_Delete"/> + <menu_item_call label="Seleccionar todo" name="NearbyChatBar_Select_All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_cof_attachment.xml b/indra/newview/skins/minimal/xui/es/menu_cof_attachment.xml new file mode 100644 index 0000000000..7541530601 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_cof_attachment.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Attachment"> + <menu_item_call label="Quitar" name="detach"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_cof_body_part.xml b/indra/newview/skins/minimal/xui/es/menu_cof_body_part.xml new file mode 100644 index 0000000000..56b95bdc3b --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_cof_body_part.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Body"> + <menu_item_call label="Reemplazar" name="replace"/> + <menu_item_call label="Editar" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_cof_clothing.xml b/indra/newview/skins/minimal/xui/es/menu_cof_clothing.xml new file mode 100644 index 0000000000..3c0c588284 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_cof_clothing.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Clothing"> + <menu_item_call label="Quitarme" name="take_off"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Reemplazar" name="replace"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_cof_gear.xml b/indra/newview/skins/minimal/xui/es/menu_cof_gear.xml new file mode 100644 index 0000000000..ff8ad0977a --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_cof_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear COF"> + <menu label="Ropas nuevas" name="COF.Gear.New_Clothes"/> + <menu label="Nuevas partes del cuerpo" name="COF.Geear.New_Body_Parts"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_edit.xml b/indra/newview/skins/minimal/xui/es/menu_edit.xml new file mode 100644 index 0000000000..96fc9d8881 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_edit.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu label="Editar" name="Edit"> + <menu_item_call label="Deshacer" name="Undo"/> + <menu_item_call label="Rehacer" name="Redo"/> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Pegar" name="Paste"/> + <menu_item_call label="Borrar" name="Delete"/> + <menu_item_call label="Duplicar" name="Duplicate"/> + <menu_item_call label="Seleccionar todo" name="Select All"/> + <menu_item_call label="Deseleccionar" name="Deselect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_favorites.xml b/indra/newview/skins/minimal/xui/es/menu_favorites.xml new file mode 100644 index 0000000000..c8a7858ddb --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_favorites.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Teleportarse" name="Teleport To Landmark"/> + <menu_item_call label="Ver/Editar el hito" name="Landmark Open"/> + <menu_item_call label="Copiar la SLurl" name="Copy slurl"/> + <menu_item_call label="Mostrar en el mapa" name="Show On Map"/> + <menu_item_call label="Copiar" name="Landmark Copy"/> + <menu_item_call label="Pegar" name="Landmark Paste"/> + <menu_item_call label="Borrar" name="Delete"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_gesture_gear.xml b/indra/newview/skins/minimal/xui/es/menu_gesture_gear.xml new file mode 100644 index 0000000000..24706eb2c8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_gesture_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_gesture_gear"> + <menu_item_call label="Añadir a / Quitar de los favoritos" name="activate"/> + <menu_item_call label="Copiar" name="copy_gesture"/> + <menu_item_call label="Pegar" name="paste"/> + <menu_item_call label="Copiar la UUID" name="copy_uuid"/> + <menu_item_call label="Añadir al vestuario actual" name="save_to_outfit"/> + <menu_item_call label="Editar" name="edit_gesture"/> + <menu_item_call label="Inspeccionar" name="inspect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_group_plus.xml b/indra/newview/skins/minimal/xui/es/menu_group_plus.xml new file mode 100644 index 0000000000..6b26ba42c4 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_group_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Entrar al grupo..." name="item_join"/> + <menu_item_call label="Grupo nuevo..." name="item_new"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_hide_navbar.xml b/indra/newview/skins/minimal/xui/es/menu_hide_navbar.xml new file mode 100644 index 0000000000..22a1873234 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_hide_navbar.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_navbar_menu"> + <menu_item_check label="Mostrar la barra de navegación" name="ShowNavbarNavigationPanel"/> + <menu_item_check label="Mostrar la barra de favoritos" name="ShowNavbarFavoritesPanel"/> + <menu_item_check label="Mostrar mini-barra de ubicación" name="ShowMiniLocationPanel"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_im_well_button.xml b/indra/newview/skins/minimal/xui/es/menu_im_well_button.xml new file mode 100644 index 0000000000..c8f6c217cc --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_im_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="IM Well Button Context Menu"> + <menu_item_call label="Cerrar todo" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_imchiclet_adhoc.xml b/indra/newview/skins/minimal/xui/es/menu_imchiclet_adhoc.xml new file mode 100644 index 0000000000..e11e9bdc58 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_imchiclet_adhoc.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet AdHoc Menu"> + <menu_item_call label="Acabar la sesión" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_imchiclet_group.xml b/indra/newview/skins/minimal/xui/es/menu_imchiclet_group.xml new file mode 100644 index 0000000000..a5e60ea40b --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_imchiclet_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet Group Menu"> + <menu_item_call label="Información del grupo" name="Show Profile"/> + <menu_item_call label="Mostrar la sesión" name="Chat"/> + <menu_item_call label="Acabar la sesión" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_imchiclet_p2p.xml b/indra/newview/skins/minimal/xui/es/menu_imchiclet_p2p.xml new file mode 100644 index 0000000000..492801026c --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_imchiclet_p2p.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet P2P Menu"> + <menu_item_call label="Ver el perfil" name="Show Profile"/> + <menu_item_call label="Añadir como amigo" name="Add Friend"/> + <menu_item_call label="Mostrar la sesión" name="Send IM"/> + <menu_item_call label="Acabar la sesión" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inspect_avatar_gear.xml b/indra/newview/skins/minimal/xui/es/menu_inspect_avatar_gear.xml new file mode 100644 index 0000000000..ebe33cea11 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inspect_avatar_gear.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu name="Gear Menu"> + <menu_item_call label="Ver el perfil" name="view_profile"/> + <menu_item_call label="Añadir como amigo" name="add_friend"/> + <menu_item_call label="MI" name="im"/> + <menu_item_call label="Teleportarse" name="teleport"/> + <menu_item_call label="Ignorar" name="block"/> + <menu_item_call label="Designorar" name="unblock"/> + <menu_item_call label="Denunciar" name="report"/> + <menu_item_call label="Congelar" name="freeze"/> + <menu_item_call label="Expulsar" name="eject"/> + <menu_item_call label="Expulsar" name="kick"/> + <menu_item_call label="CSR" name="csr"/> + <menu_item_call label="Depurar las texturas" name="debug"/> + <menu_item_call label="Encontrar en el mapa" name="find_on_map"/> + <menu_item_call label="Acercar el zoom" name="zoom_in"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inspect_object_gear.xml b/indra/newview/skins/minimal/xui/es/menu_inspect_object_gear.xml new file mode 100644 index 0000000000..bcdc25894f --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inspect_object_gear.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Tocar" name="touch"/> + <menu_item_call label="Sentarse" name="sit"/> + <menu_item_call label="Pagar" name="pay"/> + <menu_item_call label="Comprar" name="buy"/> + <menu_item_call label="Tomar" name="take"/> + <menu_item_call label="Coger una copia" name="take_copy"/> + <menu_item_call label="Abrir" name="open"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Ponerse" name="wear"/> + <menu_item_call label="Añadir" name="add"/> + <menu_item_call label="Denunciar" name="report"/> + <menu_item_call label="Ignorar" name="block"/> + <menu_item_call label="Acercar el zoom" name="zoom_in"/> + <menu_item_call label="Quitar" name="remove"/> + <menu_item_call label="Más información" name="more_info"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inspect_self_gear.xml b/indra/newview/skins/minimal/xui/es/menu_inspect_self_gear.xml new file mode 100644 index 0000000000..c8a1e9d9da --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inspect_self_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Sentarte" name="sit_down_here"/> + <menu_item_call label="Levantarme" name="stand_up"/> + <menu_item_call label="Cambiar vestuario" name="change_outfit"/> + <menu_item_call label="Mi perfil" name="my_profile"/> + <menu_item_call label="Mis amigos" name="my_friends"/> + <menu_item_call label="Mis grupos" name="my_groups"/> + <menu_item_call label="Depurar las texturas" name="Debug..."/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inv_offer_chiclet.xml b/indra/newview/skins/minimal/xui/es/menu_inv_offer_chiclet.xml new file mode 100644 index 0000000000..20d99afde1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inv_offer_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="InvOfferChiclet Menu"> + <menu_item_call label="Cerrar" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inventory.xml b/indra/newview/skins/minimal/xui/es/menu_inventory.xml new file mode 100644 index 0000000000..94ee162bbc --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inventory.xml @@ -0,0 +1,86 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Compartir" name="Share"/> + <menu_item_call label="Comprar" name="Task Buy"/> + <menu_item_call label="Abrir" name="Task Open"/> + <menu_item_call label="Ejecutar" name="Task Play"/> + <menu_item_call label="Propiedades" name="Task Properties"/> + <menu_item_call label="Renombrar" name="Task Rename"/> + <menu_item_call label="Borrar" name="Task Remove"/> + <menu_item_call label="Vaciar la papelera" name="Empty Trash"/> + <menu_item_call label="Vaciar Objetos Perdidos" name="Empty Lost And Found"/> + <menu_item_call label="Carpeta nueva" name="New Folder"/> + <menu_item_call label="Script nuevo" name="New Script"/> + <menu_item_call label="Nota nueva" name="New Note"/> + <menu_item_call label="Gesto nuevo" name="New Gesture"/> + <menu label="Ropas nuevas" name="New Clothes"> + <menu_item_call label="Camisa nueva" name="New Shirt"/> + <menu_item_call label="Pantalones nuevos" name="New Pants"/> + <menu_item_call label="Zapatos nuevos" name="New Shoes"/> + <menu_item_call label="Calcetines nuevos" name="New Socks"/> + <menu_item_call label="Chaqueta nueva" name="New Jacket"/> + <menu_item_call label="Falda nueva" name="New Skirt"/> + <menu_item_call label="Guantes nuevos" name="New Gloves"/> + <menu_item_call label="Camiseta nueva" name="New Undershirt"/> + <menu_item_call label="Ropa interior nueva" name="New Underpants"/> + <menu_item_call label="Nueva capa Alpha" name="New Alpha Mask"/> + <menu_item_call label="Tatuaje nuevo" name="New Tattoo"/> + </menu> + <menu label="Nuevas partes del cuerpo" name="New Body Parts"> + <menu_item_call label="Forma nueva" name="New Shape"/> + <menu_item_call label="Piel nueva" name="New Skin"/> + <menu_item_call label="Pelo nuevo" name="New Hair"/> + <menu_item_call label="Ojos nuevos" name="New Eyes"/> + </menu> + <menu label="Change Type" name="Change Type"> + <menu_item_call label="Por defecto" name="Default"/> + <menu_item_call label="Guantes" name="Gloves"/> + <menu_item_call label="Chaqueta" name="Jacket"/> + <menu_item_call label="Pantalón" name="Pants"/> + <menu_item_call label="Forma" name="Shape"/> + <menu_item_call label="Zapatos" name="Shoes"/> + <menu_item_call label="Camisa" name="Shirt"/> + <menu_item_call label="Falda" name="Skirt"/> + <menu_item_call label="Ropa interior" name="Underpants"/> + <menu_item_call label="Camiseta" name="Undershirt"/> + </menu> + <menu_item_call label="Teleportar" name="Landmark Open"/> + <menu_item_call label="Abrir" name="Animation Open"/> + <menu_item_call label="Abrir" name="Sound Open"/> + <menu_item_call label="Reemplazar el vestuario" name="Replace Outfit"/> + <menu_item_call label="Añadir al vestuario" name="Add To Outfit"/> + <menu_item_call label="Quitar del vestuario actual" name="Remove From Outfit"/> + <menu_item_call label="Encontrar el original" name="Find Original"/> + <menu_item_call label="Eliminar el ítem" name="Purge Item"/> + <menu_item_call label="Restaurar el ítem" name="Restore Item"/> + <menu_item_call label="Abrir" name="Open"/> + <menu_item_call label="Abrir original" name="Open Original"/> + <menu_item_call label="Propiedades" name="Properties"/> + <menu_item_call label="Renombrar" name="Rename"/> + <menu_item_call label="Copiar la UUID" name="Copy Asset UUID"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Pegar" name="Paste"/> + <menu_item_call label="Pegar como enlace" name="Paste As Link"/> + <menu_item_call label="Borrar" name="Remove Link"/> + <menu_item_call label="Borrar" name="Delete"/> + <menu_item_call label="Borrar carpeta del sistema" name="Delete System Folder"/> + <menu_item_call label="Empezar multiconferencia" name="Conference Chat Folder"/> + <menu_item_call label="Escuchar" name="Sound Play"/> + <menu_item_call label="Acerca del hito" name="About Landmark"/> + <menu_item_call label="Escuchar en el mundo" name="Animation Play"/> + <menu_item_call label="Ejecutarla para usted" name="Animation Audition"/> + <menu_item_call label="Enviar un mensaje instantáneo" name="Send Instant Message"/> + <menu_item_call label="Ofrecer teleporte..." name="Offer Teleport..."/> + <menu_item_call label="Empezar multiconferencia" name="Conference Chat"/> + <menu_item_call label="Activar" name="Activate"/> + <menu_item_call label="Desactivar" name="Deactivate"/> + <menu_item_call label="Guardar como" name="Save As"/> + <menu_item_call label="Quitarse" name="Detach From Yourself"/> + <menu_item_call label="Ponerme" name="Wearable And Object Wear"/> + <menu label="Anexar a" name="Attach To"/> + <menu label="Anexar como HUD" name="Attach To HUD"/> + <menu_item_call label="Editar" name="Wearable Edit"/> + <menu_item_call label="Añadir" name="Wearable Add"/> + <menu_item_call label="Quitarse" name="Take Off"/> + <menu_item_call label="--sin opciones--" name="--no options--"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inventory_add.xml b/indra/newview/skins/minimal/xui/es/menu_inventory_add.xml new file mode 100644 index 0000000000..ba106e8335 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inventory_add.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_inventory_add"> + <menu label="Subir" name="upload"> + <menu_item_call label="Imagen ([COST] L$)..." name="Upload Image"/> + <menu_item_call label="Sonido ([COST] L$)..." name="Upload Sound"/> + <menu_item_call label="Animación ([COST] L$)..." name="Upload Animation"/> + <menu_item_call label="Masivo ([COST] L$ por archivo)..." name="Bulk Upload"/> + <menu_item_call label="Configurar los permisos por defecto de subida" name="perm prefs"/> + </menu> + <menu_item_call label="Carpeta nueva" name="New Folder"/> + <menu_item_call label="Script nuevo" name="New Script"/> + <menu_item_call label="Nota nueva" name="New Note"/> + <menu_item_call label="Gesto nuevo" name="New Gesture"/> + <menu label="Ropas nuevas" name="New Clothes"> + <menu_item_call label="Camisa nueva" name="New Shirt"/> + <menu_item_call label="Pantalón nuevo" name="New Pants"/> + <menu_item_call label="Zapatos nuevos" name="New Shoes"/> + <menu_item_call label="Calcetines nuevos" name="New Socks"/> + <menu_item_call label="Chaqueta nueva" name="New Jacket"/> + <menu_item_call label="Falda nueva" name="New Skirt"/> + <menu_item_call label="Guantes nuevos" name="New Gloves"/> + <menu_item_call label="Camiseta nueva" name="New Undershirt"/> + <menu_item_call label="Ropa interior nueva" name="New Underpants"/> + <menu_item_call label="Nueva Alfa" name="New Alpha"/> + <menu_item_call label="Tatuaje nuevo" name="New Tattoo"/> + </menu> + <menu label="Nuevas partes del cuerpo" name="New Body Parts"> + <menu_item_call label="Forma nueva" name="New Shape"/> + <menu_item_call label="Piel nueva" name="New Skin"/> + <menu_item_call label="Pelo nuevo" name="New Hair"/> + <menu_item_call label="Ojos nuevos" name="New Eyes"/> + </menu> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_inventory_gear_default.xml b/indra/newview/skins/minimal/xui/es/menu_inventory_gear_default.xml new file mode 100644 index 0000000000..8e498fefba --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_inventory_gear_default.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="menu_gear_default"> + <menu_item_call label="Nueva ventana del inventario" name="new_window"/> + <menu_item_check label="Ordenar alfabéticamente" name="sort_by_name"/> + <menu_item_check label="Ordenar por los más recientes" name="sort_by_recent"/> + <menu_item_check label="Las carpetas del sistema, arriba" name="sort_system_folders_to_top"/> + <menu_item_call label="Ver los filtros" name="show_filters"/> + <menu_item_call label="Restablecer los filtros" name="reset_filters"/> + <menu_item_call label="Cerrar todas las carpetas" name="close_folders"/> + <menu_item_call label="Vaciar Objetos Perdidos" name="empty_lostnfound"/> + <menu_item_call label="Guardar la textura como" name="Save Texture As"/> + <menu_item_call label="Compartir" name="Share"/> + <menu_item_call label="Encontrar el original" name="Find Original"/> + <menu_item_call label="Encontrar todos los enlazados" name="Find All Links"/> + <menu_item_call label="Vaciar la Papelera" name="empty_trash"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_land.xml b/indra/newview/skins/minimal/xui/es/menu_land.xml new file mode 100644 index 0000000000..b0f15be1b6 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_land.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Land Pie"> + <menu_item_call label="Acerca del terreno" name="Place Information..."/> + <menu_item_call label="Sentarme aquí" name="Sit Here"/> + <menu_item_call label="Comprar este terreno" name="Land Buy"/> + <menu_item_call label="Comprar un pase" name="Land Buy Pass"/> + <menu_item_call label="Construir" name="Create"/> + <menu_item_call label="Modificar el terreno" name="Edit Terrain"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_landmark.xml b/indra/newview/skins/minimal/xui/es/menu_landmark.xml new file mode 100644 index 0000000000..f69b1539b8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_landmark.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="landmark_overflow_menu"> + <menu_item_call label="Copiar la SLurl" name="copy"/> + <menu_item_call label="Borrar" name="delete"/> + <menu_item_call label="Crear un Destacado" name="pick"/> + <menu_item_call label="Añadir a la barra de favoritos" name="add_to_favbar"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_login.xml b/indra/newview/skins/minimal/xui/es/menu_login.xml new file mode 100644 index 0000000000..c27d624732 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_login.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Login Menu"> + <menu label="Yo" name="File"> + <menu_item_call label="Preferencias" name="Preferences..."/> + <menu_item_call label="Salir de [APP_NAME]" name="Quit"/> + </menu> + <menu label="Ayuda" name="Help"> + <menu_item_call label="Ayuda de [SECOND_LIFE]" name="Second Life Help"/> + <menu_item_call label="Acerca de [APP_NAME]" name="About Second Life"/> + </menu> + <menu_item_check label="Mostrar el menú 'Debug'" name="Show Debug Menu"/> + <menu label="Depurar" name="Debug"> + <menu_item_call label="Mostrar las configuraciones del depurador" name="Debug Settings"/> + <menu_item_call label="Configuraciones del Visor/Color" name="UI/Color Settings"/> + <menu label="Pruebas de la interfaz" name="UI Tests"/> + <menu_item_call label="Definir el tamaño de la ventana..." name="Set Window Size..."/> + <menu_item_call label="Mostrar los 'TOS'" name="TOS"/> + <menu_item_call label="Mostrar mensaje crítico" name="Critical"/> + <menu_item_call label="Prueba de navegadores de medios" name="Web Browser Test"/> + <menu_item_call label="Prueba de ventanas de contenidos web" name="Web Content Floater Test"/> + <menu_item_check label="Mostrar el selector de Grid" name="Show Grid Picker"/> + <menu_item_call label="Mostrar la consola de notificaciones" name="Show Notifications Console"/> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/es/menu_mini_map.xml b/indra/newview/skins/minimal/xui/es/menu_mini_map.xml new file mode 100644 index 0000000000..07d1b08572 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_mini_map.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Zoom cerca" name="Zoom Close"/> + <menu_item_call label="Zoom medio" name="Zoom Medium"/> + <menu_item_call label="Zoom lejos" name="Zoom Far"/> + <menu_item_call label="Zoom por defecto" name="Zoom Default"/> + <menu_item_check label="Girar el mapa" name="Rotate Map"/> + <menu_item_check label="Centrar automáticamente" name="Auto Center"/> + <menu_item_call label="Parar la búsqueda" name="Stop Tracking"/> + <menu_item_call label="Mapa del mundo" name="World Map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_navbar.xml b/indra/newview/skins/minimal/xui/es/menu_navbar.xml new file mode 100644 index 0000000000..63e5468020 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_navbar.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Navbar Menu"> + <menu_item_check label="Mostrar las coordenadas" name="Show Coordinates"/> + <menu_item_check label="Mostrar las propiedades de la parcela" name="Show Parcel Properties"/> + <menu_item_call label="Hito" name="Landmark"/> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Pegar" name="Paste"/> + <menu_item_call label="Borrar" name="Delete"/> + <menu_item_call label="Seleccionar todo" name="Select All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_nearby_chat.xml b/indra/newview/skins/minimal/xui/es/menu_nearby_chat.xml new file mode 100644 index 0000000000..94b281b6c7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_nearby_chat.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="NearBy Chat Menu"> + <menu_item_call label="Mostrar la gente que está cerca..." name="nearby_people"/> + <menu_item_check label="Ver el texto ignorado" name="muted_text"/> + <menu_item_check label="Mostrar los iconos del amigo" name="show_buddy_icons"/> + <menu_item_check label="Mostrar los nombres" name="show_names"/> + <menu_item_check label="Mostrar los iconos y los nombres" name="show_icons_and_names"/> + <menu_item_call label="Tamaño de la fuente" name="font_size"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_notification_well_button.xml b/indra/newview/skins/minimal/xui/es/menu_notification_well_button.xml new file mode 100644 index 0000000000..0562d35be7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_notification_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Notification Well Button Context Menu"> + <menu_item_call label="Cerrar todo" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_object.xml b/indra/newview/skins/minimal/xui/es/menu_object.xml new file mode 100644 index 0000000000..06121e0c09 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_object.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Object Pie"> + <menu_item_call label="Tocar" name="Object Touch"> + <menu_item_call.on_enable name="EnableTouch" parameter="Tocar"/> + </menu_item_call> + <menu_item_call label="Editar" name="Edit..."/> + <menu_item_call label="Construir" name="Build"/> + <menu_item_call label="Abrir" name="Open"/> + <menu_item_call label="Sentarme aquí" name="Object Sit"/> + <menu_item_call label="Levantarme" name="Object Stand Up"/> + <menu_item_call label="Perfil del objeto" name="Object Inspect"/> + <menu_item_call label="Acercar el zoom" name="Zoom In"/> + <context_menu label="Ponerme" name="Put On"> + <menu_item_call label="Ponerme" name="Wear"/> + <menu_item_call label="Añadir" name="Add"/> + <context_menu label="Anexar" name="Object Attach"/> + <context_menu label="Anexar el HUD" name="Object Attach HUD"/> + </context_menu> + <context_menu label="Quitar" name="Remove"> + <menu_item_call label="Denunciar una infracción" name="Report Abuse..."/> + <menu_item_call label="Ignorar" name="Object Mute"/> + <menu_item_call label="Devolver" name="Return..."/> + <menu_item_call label="Eliminar" name="Delete"/> + </context_menu> + <menu_item_call label="Tomar" name="Pie Object Take"/> + <menu_item_call label="Coger una copia" name="Take Copy"/> + <menu_item_call label="Pagar" name="Pay..."/> + <menu_item_call label="Comprar" name="Buy..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_object_icon.xml b/indra/newview/skins/minimal/xui/es/menu_object_icon.xml new file mode 100644 index 0000000000..7e4578b950 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_object_icon.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Object Icon Menu"> + <menu_item_call label="Perfil del objeto..." name="Object Profile"/> + <menu_item_call label="Ignorar..." name="Block"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_outfit_gear.xml b/indra/newview/skins/minimal/xui/es/menu_outfit_gear.xml new file mode 100644 index 0000000000..3b11bceecf --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_outfit_gear.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Outfit"> + <menu_item_call label="Ponerme - Reemplazar el vestuario actual" name="wear"/> + <menu_item_call label="Ponerme - Añadir al vestuario actual" name="wear_add"/> + <menu_item_call label="Quitarme - Quitar del vestuario actual" name="take_off"/> + <menu label="Ropas nuevas" name="New Clothes"> + <menu_item_call label="Camisa nueva" name="New Shirt"/> + <menu_item_call label="Pantalón nuevo" name="New Pants"/> + <menu_item_call label="Zapatos nuevos" name="New Shoes"/> + <menu_item_call label="Calcetines nuevos" name="New Socks"/> + <menu_item_call label="Chaqueta nueva" name="New Jacket"/> + <menu_item_call label="Falda nueva" name="New Skirt"/> + <menu_item_call label="Guantes nuevos" name="New Gloves"/> + <menu_item_call label="Camiseta nueva" name="New Undershirt"/> + <menu_item_call label="Ropa interior nueva" name="New Underpants"/> + <menu_item_call label="Nueva Alfa" name="New Alpha"/> + <menu_item_call label="Tatuaje nuevo" name="New Tattoo"/> + </menu> + <menu label="Nuevas partes del cuerpo" name="New Body Parts"> + <menu_item_call label="Anatomía nueva" name="New Shape"/> + <menu_item_call label="Piel nueva" name="New Skin"/> + <menu_item_call label="Pelo nuevo" name="New Hair"/> + <menu_item_call label="Ojos nuevos" name="New Eyes"/> + </menu> + <menu_item_call label="Renombrar el vestuario" name="rename"/> + <menu_item_call label="Borrar el vestuario" name="delete_outfit"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_outfit_tab.xml b/indra/newview/skins/minimal/xui/es/menu_outfit_tab.xml new file mode 100644 index 0000000000..4136082a62 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_outfit_tab.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit"> + <menu_item_call label="Ponerme - Reemplazar el vestuario actual" name="wear_replace"/> + <menu_item_call label="Ponerme - Añadir al vestuario actual" name="wear_add"/> + <menu_item_call label="Quitarme - Quitar del vestuario actual" name="take_off"/> + <menu_item_call label="Editar el vestuario" name="edit"/> + <menu_item_call label="Renombrar el vestuario" name="rename"/> + <menu_item_call label="Borrar el vestuario" name="delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_participant_list.xml b/indra/newview/skins/minimal/xui/es/menu_participant_list.xml new file mode 100644 index 0000000000..f6eedd1170 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_participant_list.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Participant List Context Menu"> + <menu_item_check label="Ordenar alfabéticamente" name="SortByName"/> + <menu_item_check label="Ordenar según las intervenciones recientes" name="SortByRecentSpeakers"/> + <menu_item_call label="Ver el perfil" name="View Profile"/> + <menu_item_call label="Añadir como amigo" name="Add Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Llamar" name="Call"/> + <menu_item_call label="Compartir" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_check label="Ver los iconos de la gente" name="View Icons"/> + <menu_item_check label="Ignorar la voz" name="Block/Unblock"/> + <menu_item_check label="Ignorar el texto" name="MuteText"/> + <context_menu label="Opciones del moderador" name="Moderator Options"> + <menu_item_check label="Permitir el chat de texto" name="AllowTextChat"/> + <menu_item_call label="Ignorar a este participante" name="ModerateVoiceMuteSelected"/> + <menu_item_call label="Quitar el silencio a este participante" name="ModerateVoiceUnMuteSelected"/> + <menu_item_call label="Silenciar a todos" name="ModerateVoiceMute"/> + <menu_item_call label="Quitar el silencio a todos" name="ModerateVoiceUnmute"/> + </context_menu> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_friends_view_sort.xml b/indra/newview/skins/minimal/xui/es/menu_people_friends_view_sort.xml new file mode 100644 index 0000000000..3899ad9e96 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_friends_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar alfabéticamente" name="sort_name"/> + <menu_item_check label="Ordenar por estatus" name="sort_status"/> + <menu_item_check label="Ver los iconos de la gente" name="view_icons"/> + <menu_item_check label="Ver permisos concedidos" name="view_permissions"/> + <menu_item_call label="Ver la lista de Residentes y Objetos ignorados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_groups.xml b/indra/newview/skins/minimal/xui/es/menu_people_groups.xml new file mode 100644 index 0000000000..51bd2c7208 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_groups.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Ver la información" name="View Info"/> + <menu_item_call label="Chat" name="Chat"/> + <menu_item_call label="Llamar" name="Call"/> + <menu_item_call label="Activar" name="Activate"/> + <menu_item_call label="Dejar" name="Leave"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_groups_view_sort.xml b/indra/newview/skins/minimal/xui/es/menu_people_groups_view_sort.xml new file mode 100644 index 0000000000..1bd3efb611 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_groups_view_sort.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Mostrar los iconos de grupo" name="Display Group Icons"/> + <menu_item_call label="Dejar el grupo seleccionado" name="Leave Selected Group"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_nearby.xml b/indra/newview/skins/minimal/xui/es/menu_people_nearby.xml new file mode 100644 index 0000000000..dc1486d879 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_nearby.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Avatar Context Menu"> + <menu_item_call label="Ver el perfil" name="View Profile"/> + <menu_item_call label="Añadir como amigo" name="Add Friend"/> + <menu_item_call label="Quitarle como amigo" name="Remove Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Llamar" name="Call"/> + <menu_item_call label="Mapa" name="Map"/> + <menu_item_call label="Compartir" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_check label="Ignorar / No ignorar" name="Block/Unblock"/> + <menu_item_call label="Ofrecer teleporte" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_nearby_multiselect.xml b/indra/newview/skins/minimal/xui/es/menu_people_nearby_multiselect.xml new file mode 100644 index 0000000000..227c5ebe58 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_nearby_multiselect.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Multi-Selected People Context Menu"> + <menu_item_call label="Añadir como amigos" name="Add Friends"/> + <menu_item_call label="Quitar amigos" name="Remove Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Llamar" name="Call"/> + <menu_item_call label="Compartir" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_call label="Ofrecer teleporte" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_nearby_view_sort.xml b/indra/newview/skins/minimal/xui/es/menu_people_nearby_view_sort.xml new file mode 100644 index 0000000000..f0fe383c0c --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_nearby_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar según las intervenciones recientes" name="sort_by_recent_speakers"/> + <menu_item_check label="Ordenar alfabéticamente" name="sort_name"/> + <menu_item_check label="Ordenar según distancia" name="sort_distance"/> + <menu_item_check label="Ver los iconos de la gente" name="view_icons"/> + <menu_item_call label="Ver la lista de Residentes y Objetos ignorados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_people_recent_view_sort.xml b/indra/newview/skins/minimal/xui/es/menu_people_recent_view_sort.xml new file mode 100644 index 0000000000..e4aaa89110 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_people_recent_view_sort.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar por los más recientes" name="sort_most"/> + <menu_item_check label="Ordenar alfabéticamente" name="sort_name"/> + <menu_item_check label="Ver los iconos de la gente" name="view_icons"/> + <menu_item_call label="Ver la lista de Residentes y Objetos ignorados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_picks.xml b/indra/newview/skins/minimal/xui/es/menu_picks.xml new file mode 100644 index 0000000000..9da68d7c9b --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_picks.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Picks"> + <menu_item_call label="Información" name="pick_info"/> + <menu_item_call label="Editar" name="pick_edit"/> + <menu_item_call label="Teleportar" name="pick_teleport"/> + <menu_item_call label="Mapa" name="pick_map"/> + <menu_item_call label="Eliminar" name="pick_delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_picks_plus.xml b/indra/newview/skins/minimal/xui/es/menu_picks_plus.xml new file mode 100644 index 0000000000..cc59bf1d29 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_picks_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="picks_plus_menu"> + <menu_item_call label="Destacado nuevo" name="create_pick"/> + <menu_item_call label="Clasificado nuevo" name="create_classified"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_place.xml b/indra/newview/skins/minimal/xui/es/menu_place.xml new file mode 100644 index 0000000000..675f0699e9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_place.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="place_overflow_menu"> + <menu_item_call label="Crear un hito" name="landmark"/> + <menu_item_call label="Crear un destacado" name="pick"/> + <menu_item_call label="Comprar un pase" name="pass"/> + <menu_item_call label="Editar" name="edit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_place_add_button.xml b/indra/newview/skins/minimal/xui/es/menu_place_add_button.xml new file mode 100644 index 0000000000..4b2f908a06 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_place_add_button.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Añadir una carpeta" name="add_folder"/> + <menu_item_call label="Añadir este hito" name="add_landmark"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_places_gear_folder.xml b/indra/newview/skins/minimal/xui/es/menu_places_gear_folder.xml new file mode 100644 index 0000000000..bf46eb58e3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_places_gear_folder.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Añadir este hito" name="add_landmark"/> + <menu_item_call label="Añadir una carpeta" name="add_folder"/> + <menu_item_call label="Cortar" name="cut"/> + <menu_item_call label="Copiar" name="copy_folder"/> + <menu_item_call label="Pegar" name="paste"/> + <menu_item_call label="Renombrar" name="rename"/> + <menu_item_call label="Borrar" name="delete"/> + <menu_item_call label="Abrir" name="expand"/> + <menu_item_call label="Cerrar" name="collapse"/> + <menu_item_call label="Abrir todas las carpetas" name="expand_all"/> + <menu_item_call label="Cerrar todas las carpetas" name="collapse_all"/> + <menu_item_check label="Ordenar por fecha" name="sort_by_date"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_places_gear_landmark.xml b/indra/newview/skins/minimal/xui/es/menu_places_gear_landmark.xml new file mode 100644 index 0000000000..eac85de846 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_places_gear_landmark.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_ladmark_gear"> + <menu_item_call label="Teleportar" name="teleport"/> + <menu_item_call label="Más información" name="more_info"/> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Añadir un hito" name="add_landmark"/> + <menu_item_call label="Añadir una carpeta" name="add_folder"/> + <menu_item_call label="Cortar" name="cut"/> + <menu_item_call label="Copiar el hito" name="copy_landmark"/> + <menu_item_call label="Copiar la SLurl" name="copy_slurl"/> + <menu_item_call label="Pegar" name="paste"/> + <menu_item_call label="Renombrar" name="rename"/> + <menu_item_call label="Eliminar" name="delete"/> + <menu_item_call label="Abrir todas las carpetas" name="expand_all"/> + <menu_item_call label="Cerrar todas las carpetas" name="collapse_all"/> + <menu_item_check label="Ordenar por fecha" name="sort_by_date"/> + <menu_item_call label="Crear un Destacado" name="create_pick"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_profile_overflow.xml b/indra/newview/skins/minimal/xui/es/menu_profile_overflow.xml new file mode 100644 index 0000000000..5ee8c50949 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_profile_overflow.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="profile_overflow_menu"> + <menu_item_call label="Mapa" name="show_on_map"/> + <menu_item_call label="Pagar" name="pay"/> + <menu_item_call label="Compartir" name="share"/> + <menu_item_call label="Ignorar" name="block"/> + <menu_item_call label="Designorar" name="unblock"/> + <menu_item_call label="Expulsar" name="kick"/> + <menu_item_call label="Congelar" name="freeze"/> + <menu_item_call label="Descongelar" name="unfreeze"/> + <menu_item_call label="CSR" name="csr"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_save_outfit.xml b/indra/newview/skins/minimal/xui/es/menu_save_outfit.xml new file mode 100644 index 0000000000..a04ec75b60 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_save_outfit.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="save_outfit_menu"> + <menu_item_call label="Guardar" name="save_outfit"/> + <menu_item_call label="Guardar como" name="save_as_new_outfit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_script_chiclet.xml b/indra/newview/skins/minimal/xui/es/menu_script_chiclet.xml new file mode 100644 index 0000000000..f517baf566 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_script_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="ScriptChiclet Menu"> + <menu_item_call label="Cerrar" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_slurl.xml b/indra/newview/skins/minimal/xui/es/menu_slurl.xml new file mode 100644 index 0000000000..ca19acec6e --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_slurl.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Acerca de la URL" name="about_url"/> + <menu_item_call label="Teleportar a la URL" name="teleport_to_url"/> + <menu_item_call label="Mapa" name="show_on_map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_teleport_history_gear.xml b/indra/newview/skins/minimal/xui/es/menu_teleport_history_gear.xml new file mode 100644 index 0000000000..b708f3bc20 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_teleport_history_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Teleport History Gear Context Menu"> + <menu_item_call label="Abrir todas las carpetas" name="Expand all folders"/> + <menu_item_call label="Cerrar todas las carpetas" name="Collapse all folders"/> + <menu_item_call label="Limpiar el historial de teleportes" name="Clear Teleport History"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_teleport_history_item.xml b/indra/newview/skins/minimal/xui/es/menu_teleport_history_item.xml new file mode 100644 index 0000000000..ed33c55aca --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_teleport_history_item.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Teleportarse" name="Teleport"/> + <menu_item_call label="Más información" name="More Information"/> + <menu_item_call label="Copiar al portapapeles" name="CopyToClipboard"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_teleport_history_tab.xml b/indra/newview/skins/minimal/xui/es/menu_teleport_history_tab.xml new file mode 100644 index 0000000000..17e90422a5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_teleport_history_tab.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Abrir" name="TabOpen"/> + <menu_item_call label="Cerrar" name="TabClose"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_text_editor.xml b/indra/newview/skins/minimal/xui/es/menu_text_editor.xml new file mode 100644 index 0000000000..095e461734 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_text_editor.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Text editor context menu"> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Pegar" name="Paste"/> + <menu_item_call label="Borrar" name="Delete"/> + <menu_item_call label="Seleccionar todo" name="Select All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_topinfobar.xml b/indra/newview/skins/minimal/xui/es/menu_topinfobar.xml new file mode 100644 index 0000000000..2125fd51b2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_topinfobar.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_topinfobar"> + <menu_item_check label="Mostrar las coordenadas" name="Show Coordinates"/> + <menu_item_check label="Mostrar las propiedades de la parcela" name="Show Parcel Properties"/> + <menu_item_call label="Hito" name="Landmark"/> + <menu_item_call label="Copiar" name="Copy"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_agent.xml b/indra/newview/skins/minimal/xui/es/menu_url_agent.xml new file mode 100644 index 0000000000..a089c8f68e --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_agent.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar el perfil del Residente" name="show_agent"/> + <menu_item_call label="Copiar el nombre al portapapeles" name="url_copy_label"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_group.xml b/indra/newview/skins/minimal/xui/es/menu_url_group.xml new file mode 100644 index 0000000000..79374b9739 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar la información del grupo" name="show_group"/> + <menu_item_call label="Copiar el grupo al portapapeles" name="url_copy_label"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_http.xml b/indra/newview/skins/minimal/xui/es/menu_url_http.xml new file mode 100644 index 0000000000..585c059ff3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_http.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Abrir la página web" name="url_open"/> + <menu_item_call label="Abrir en el navegador incorporado" name="url_open_internal"/> + <menu_item_call label="Abrir en mi navegador" name="url_open_external"/> + <menu_item_call label="Copiar la URL al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_inventory.xml b/indra/newview/skins/minimal/xui/es/menu_url_inventory.xml new file mode 100644 index 0000000000..13a8711c76 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_inventory.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar ítem del inventario" name="show_item"/> + <menu_item_call label="Copiar el nombre al portapapeles" name="url_copy_label"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_map.xml b/indra/newview/skins/minimal/xui/es/menu_url_map.xml new file mode 100644 index 0000000000..f96a0c7170 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_map.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Teleportarse a la localización" name="teleport_to_location"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_objectim.xml b/indra/newview/skins/minimal/xui/es/menu_url_objectim.xml new file mode 100644 index 0000000000..8791a290af --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_objectim.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar la información del objeto" name="show_object"/> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Teleportarse a la posición del objeto" name="teleport_to_object"/> + <menu_item_call label="Copiar el nombre del objeto al portapapeles" name="url_copy_label"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_parcel.xml b/indra/newview/skins/minimal/xui/es/menu_url_parcel.xml new file mode 100644 index 0000000000..9e789ef8ee --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_parcel.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar la información de la parcela" name="show_parcel"/> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_slapp.xml b/indra/newview/skins/minimal/xui/es/menu_url_slapp.xml new file mode 100644 index 0000000000..7147dcd3cf --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_slapp.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Ejecutar este comando" name="run_slapp"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_slurl.xml b/indra/newview/skins/minimal/xui/es/menu_url_slurl.xml new file mode 100644 index 0000000000..4ab47c2f61 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_slurl.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar la información del lugar" name="show_place"/> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Teleportarse a este lugar" name="teleport_to_location"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_url_teleport.xml b/indra/newview/skins/minimal/xui/es/menu_url_teleport.xml new file mode 100644 index 0000000000..8f86a91be3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_url_teleport.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Teleportarse a este lugar" name="teleport"/> + <menu_item_call label="Mostrar en el mapa" name="show_on_map"/> + <menu_item_call label="Copiar la SLurl al portapapeles" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_viewer.xml b/indra/newview/skins/minimal/xui/es/menu_viewer.xml new file mode 100644 index 0000000000..776ccfe21b --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_viewer.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Main Menu"> + <menu label="Ayuda" name="Help"> + <menu_item_call label="Ayuda de [SECOND_LIFE]" name="Second Life Help"/> + </menu> + <menu label="Avanzado" name="Advanced"> + <menu label="Atajos de teclado" name="Shortcuts"> + <menu_item_check label="Volar" name="Fly"/> + <menu_item_call label="Cerrar la ventana" name="Close Window"/> + <menu_item_call label="Cerrar todas las ventanas" name="Close All Windows"/> + <menu_item_call label="Volver a la vista por defecto" name="Reset View"/> + </menu> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/es/menu_wearable_list_item.xml b/indra/newview/skins/minimal/xui/es/menu_wearable_list_item.xml new file mode 100644 index 0000000000..4bffa689e7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_wearable_list_item.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit Wearable Context Menu"> + <menu_item_call label="Reemplazar" name="wear_replace"/> + <menu_item_call label="Ponerme" name="wear_wear"/> + <menu_item_call label="Añadir" name="wear_add"/> + <menu_item_call label="Quitarme / Quitar" name="take_off_or_detach"/> + <menu_item_call label="Quitar" name="detach"/> + <context_menu label="Anexar a" name="wearable_attach_to"/> + <context_menu label="Anexar al HUD" name="wearable_attach_to_hud"/> + <menu_item_call label="Quitarme" name="take_off"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Perfil del elemento" name="object_profile"/> + <menu_item_call label="Mostrar original" name="show_original"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_wearing_gear.xml b/indra/newview/skins/minimal/xui/es/menu_wearing_gear.xml new file mode 100644 index 0000000000..9d9ce75e53 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_wearing_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Wearing"> + <menu_item_call label="Editar el vestuario" name="edit"/> + <menu_item_call label="Quitarme" name="takeoff"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/es/menu_wearing_tab.xml b/indra/newview/skins/minimal/xui/es/menu_wearing_tab.xml new file mode 100644 index 0000000000..64fd7ce4cf --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/menu_wearing_tab.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Wearing"> + <menu_item_call label="Quitarme" name="take_off"/> + <menu_item_call label="Quitar" name="detach"/> + <menu_item_call label="Editar el vestuario" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/es/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/es/panel_bottomtray.xml new file mode 100644 index 0000000000..9ab30b5613 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_bottomtray.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="bottom_tray"> + <string name="DragIndicationImageName" value="Accordion_ArrowOpened_Off"/> + <string name="SpeakBtnToolTip" value="Activa/Desactiva el micrófono"/> + <string name="VoiceControlBtnToolTip" value="Muestra/Oculta el panel del control de voz"/> + <layout_stack name="toolbar_stack"> + <layout_panel name="gesture_panel"> + <gesture_combo_list label="Gestos" name="Gesture" tool_tip="Muestra/Oculta los gestos"/> + </layout_panel> + <layout_panel name="cam_panel"> + <bottomtray_button label="Visión" name="camera_btn" tool_tip="Muestra/Oculta los controles de la cámara"/> + </layout_panel> + <layout_panel name="avatar_and_destinations_panel"> + <radio_group name="avatar_and_destination_btns"> + <radio_item name="destination_btn" value="0"/> + <radio_item name="avatar_btn" value="1"/> + </radio_group> + </layout_panel> + <layout_panel name="people_panel"> + <bottomtray_button label="Gente" name="show_people_button" tool_tip="Muestra la ventana de gente"/> + </layout_panel> + <layout_panel name="profile_panel"> + <bottomtray_button label="Perfil" name="show_profile_btn" tool_tip="Muestra la ventana del perfil"/> + </layout_panel> + <layout_panel name="howto_panel"> + <bottomtray_button label="Indicaciones" name="show_help_btn" tool_tip="Abrir los temas sobre indicaciones de Second Life"/> + </layout_panel> + <layout_panel name="im_well_panel"> + <chiclet_im_well name="im_well"> + <button name="Unread IM messages" tool_tip="Conversaciones"/> + </chiclet_im_well> + </layout_panel> + <layout_panel name="notification_well_panel"> + <chiclet_notification name="notification_well"> + <button name="Unread" tool_tip="Notificaciones"/> + </chiclet_notification> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_im_control_panel.xml b/indra/newview/skins/minimal/xui/es/panel_im_control_panel.xml new file mode 100644 index 0000000000..7d4db6a630 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_im_control_panel.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_im_control_panel"> + <layout_stack name="button_stack"> + <layout_panel name="view_profile_btn_panel"> + <button label="Perfil" name="view_profile_btn"/> + </layout_panel> + <layout_panel name="add_friend_btn_panel"> + <button label="Añadir como amigo" name="add_friend_btn"/> + </layout_panel> + <layout_panel name="teleport_btn_panel"> + <button label="Teleportarme" name="teleport_btn" tool_tip="Ofrecer teleporte a esta persona"/> + </layout_panel> + <layout_panel name="share_btn_panel"> + <button label="Compartir" name="share_btn"/> + </layout_panel> + <layout_panel name="pay_btn_panel"> + <button label="Pagar" name="pay_btn"/> + </layout_panel> + <layout_panel name="call_btn_panel"> + <button label="Llamar" name="call_btn"/> + </layout_panel> + <layout_panel name="end_call_btn_panel"> + <button label="Colgar" name="end_call_btn"/> + </layout_panel> + <layout_panel name="voice_ctrls_btn_panel"> + <button label="Controles de la voz" name="voice_ctrls_btn"/> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_login.xml b/indra/newview/skins/minimal/xui/es/panel_login.xml new file mode 100644 index 0000000000..161ea19b0e --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_login.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_login"> + <panel.string name="create_account_url"> + http://join.secondlife.com/index.php?lang=es-ES + </panel.string> + <panel.string name="forgot_password_url"> + http://secondlife.com/account/request.php?lang=es + </panel.string> + <layout_stack name="login_widgets"> + <layout_panel name="login"> + <text name="username_text"> + Nombre de usuario: + </text> + <combo_box name="username_combo" tool_tip="El nombre de usuario que elegiste al registrarte, como bobsmith12 o Steller Sunshine"/> + <text name="password_text"> + Contraseña: + </text> + <check_box label="Recordar la contraseña" name="remember_check"/> + <button label="Iniciar sesión" name="connect_btn"/> + <text name="mode_selection_text"> + Modo: + </text> + <combo_box name="mode_combo"> + <combo_box.item label="Básico (Predeterminado)" name="Basic"/> + <combo_box.item label="Avanzado" name="Advanced"/> + </combo_box> + </layout_panel> + <layout_panel name="links"> + <text name="create_new_account_text"> + Registrarme + </text> + <text name="forgot_password_text"> + ¿Olvidaste el nombre de usuario o la contraseña? + </text> + <text name="login_help"> + ¿Necesitas ayuda para conectarte? + </text> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_navigation_bar.xml b/indra/newview/skins/minimal/xui/es/panel_navigation_bar.xml new file mode 100644 index 0000000000..e8e95c3bac --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_navigation_bar.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="navigation_bar"> + <panel name="navigation_panel"> + <pull_button name="back_btn" tool_tip="Volver a lo localización anterior"/> + <pull_button name="forward_btn" tool_tip="Ir una localización adelante"/> + <button name="home_btn" tool_tip="Teleportar a mi Base"/> + <location_input label="Localización" name="location_combo"/> + <search_combo_box label="Buscar" name="search_combo_box" tool_tip="Buscar"> + <combo_editor label="Buscar en [SECOND_LIFE]" name="search_combo_editor"/> + </search_combo_box> + </panel> + <favorites_bar name="favorite" tool_tip="¡Accede rápidamente a tus lugares favoritos de Second Life arrastrando hitos hasta aquí!"> + <label name="favorites_bar_label" tool_tip="¡Accede rápidamente a tus lugares favoritos de Second Life arrastrando hitos hasta aquí!"> + Barra de Favoritos + </label> + <chevron_button name=">>" tool_tip="Ver más de Mis favoritos"/> + </favorites_bar> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_people.xml b/indra/newview/skins/minimal/xui/es/panel_people.xml new file mode 100644 index 0000000000..7d3157ef45 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_people.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- Side tray panel --> +<panel label="Gente" name="people_panel"> + <string name="no_recent_people" value="No hay gente reciente. ¿Estás buscando gente con la que juntarte? Prueba con el botón Destinos que aparece a continuación."/> + <string name="no_filtered_recent_people" value="No hay gente reciente con ese nombre."/> + <string name="no_one_near" value="No hay nadie cerca. ¿Estás buscando gente con la que juntarte? Prueba con el botón Destinos que aparece a continuación."/> + <string name="no_one_filtered_near" value="No hay nadie cerca con ese nombre."/> + <string name="no_friends_online" value="No hay amigos conectados"/> + <string name="no_friends" value="No hay amigos"/> + <string name="no_friends_msg"> + Haz clic con el botón derecho del ratón en un residente para agregarlo como amigo. +¿Estás buscando gente con la que juntarte? Prueba con el botón Destinos que aparece a continuación. + </string> + <string name="no_filtered_friends_msg"> + ¿No encuentras lo que buscas? Prueba con el botón Destinos que aparece a continuación. + </string> + <string name="people_filter_label" value="Filtrar a la gente"/> + <string name="groups_filter_label" value="Filtrar a los grupos"/> + <string name="no_filtered_groups_msg" value="¿No encuentras lo que buscas? Prueba con [secondlife:///app/search/groups/[SEARCH_TERM] Buscar]."/> + <string name="no_groups_msg" value="¿Buscas grupos en que participar? Prueba la [secondlife:///app/search/groups Búsqueda]."/> + <string name="MiniMapToolTipMsg" value="[REGIÓN](Haz doble clic para abrir el mapa y pulsa la tecla Mayús y arrastra para obtener una vista panorámica)"/> + <string name="AltMiniMapToolTipMsg" value="[REGIÓN](Haz doble clic para teleportarte y pulsa la tecla Mayús y arrastra para obtener una vista panorámica)"/> + <filter_editor label="Filtrar" name="filter_input"/> + <tab_container name="tabs"> + <panel label="CERCANA" name="nearby_panel"> + <panel label="bottom_panel" name="bottom_panel"/> + </panel> + <panel label="MIS AMIGOS" name="friends_panel"> + <accordion name="friends_accordion"> + <accordion_tab name="tab_online" title="Conectado"/> + <accordion_tab name="tab_all" title="Todos"/> + </accordion> + <panel label="bottom_panel" name="bottom_panel"> + <layout_stack name="bottom_panel"> + <layout_panel name="trash_btn_panel"> + <dnd_button name="del_btn" tool_tip="Quitar a la persona seleccionada de tu lista de amigos"/> + </layout_panel> + </layout_stack> + </panel> + </panel> + <panel label="RECIENTE" name="recent_panel"> + <panel label="bottom_panel" name="bottom_panel"> + <button name="add_friend_btn" tool_tip="Añadir al Residente seleccionado a la lista de tus amigos"/> + </panel> + </panel> + </tab_container> + <panel name="button_bar"> + <layout_stack name="bottom_bar_ls"> + <layout_panel name="view_profile_btn_lp"> + <button label="Perfil" name="view_profile_btn" tool_tip="Mostrar imágenes, grupos y otra información del Residente"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="MI" name="im_btn" tool_tip="Abrir una sesión de mensajes instantáneos"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Teleporte" name="teleport_btn" tool_tip="Ofrecer teleporte"/> + </layout_panel> + </layout_stack> + <layout_stack name="bottom_bar_ls1"> + <layout_panel name="group_info_btn_lp"> + <button label="Perfil del grupo" name="group_info_btn" tool_tip="Ver la información del grupo"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Chat de grupo" name="chat_btn" tool_tip="Abrir el chat"/> + </layout_panel> + <layout_panel name="group_call_btn_lp"> + <button label="Llamar al grupo" name="group_call_btn" tool_tip="Llama a este grupo"/> + </layout_panel> + </layout_stack> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_side_tray_tab_caption.xml b/indra/newview/skins/minimal/xui/es/panel_side_tray_tab_caption.xml new file mode 100644 index 0000000000..775e343dc9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_side_tray_tab_caption.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="sidetray_tab_panel"> + <text name="sidetray_tab_title" value="Panel lateral"/> + <button name="undock" tool_tip="Soltar"/> + <button name="dock" tool_tip="Fijar"/> + <button name="show_help" tool_tip="Ver ayuda"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/es/panel_status_bar.xml b/indra/newview/skins/minimal/xui/es/panel_status_bar.xml new file mode 100644 index 0000000000..ab76d3f994 --- /dev/null +++ b/indra/newview/skins/minimal/xui/es/panel_status_bar.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="status"> + <panel.string name="StatBarDaysOfWeek"> + Domingo:Lunes:Martes:Miércoles:Jueves:Viernes:Sábado + </panel.string> + <panel.string name="StatBarMonthsOfYear"> + Enero:Febrero:Marzo:Abril:Mayo:Junio:Julio:Agosto:Septiembre:Octubre:Noviembre:Diciembre + </panel.string> + <panel.string name="packet_loss_tooltip"> + Pérdida de paquetes + </panel.string> + <panel.string name="bandwidth_tooltip"> + Ancho de banda + </panel.string> + <panel.string name="time"> + [hour12, datetime, slt]:[min, datetime, slt] [ampm, datetime, slt] [timezone,datetime, slt] + </panel.string> + <panel.string name="timeTooltip"> + [weekday, datetime, slt], [day, datetime, slt] [month, datetime, slt] [year, datetime, slt] + </panel.string> + <panel.string name="buycurrencylabel"> + [AMT] L$ + </panel.string> + <panel name="balance_bg"> + <text name="balance" tool_tip="Haz clic para actualizar tu saldo en L$" value="20 L$"/> + <button label="COMPRAR L$" name="buyL" tool_tip="Pulsa para comprar más L$"/> + </panel> + <text name="TimeText" tool_tip="Hora actual (Pacífico)"> + 24:00 AM PST + </text> + <button name="media_toggle_btn" tool_tip="Iniciar/Parar todos los media (música, vídeo, páginas web)"/> + <button name="volume_btn" tool_tip="Control general del volumen"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/floater_camera.xml b/indra/newview/skins/minimal/xui/fr/floater_camera.xml new file mode 100644 index 0000000000..1d62a89ff2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/floater_camera.xml @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="camera_floater"> + <floater.string name="rotate_tooltip"> + Faire tourner la caméra autour du point central + </floater.string> + <floater.string name="zoom_tooltip"> + Zoomer en direction du point central + </floater.string> + <floater.string name="move_tooltip"> + Déplacer la caméra vers le haut et le bas, la gauche et la droite + </floater.string> + <floater.string name="camera_modes_title"> + Modes + </floater.string> + <floater.string name="pan_mode_title"> + Rotation - Zoom - Panoramique + </floater.string> + <floater.string name="presets_mode_title"> + Préréglages + </floater.string> + <floater.string name="free_mode_title"> + Voir l'objet + </floater.string> + <panel name="controls"> + <panel name="preset_views_list"> + <panel_camera_item name="front_view"> + <panel_camera_item.text name="front_view_text"> + Vue frontale + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="group_view"> + <panel_camera_item.text name="side_view_text"> + Vue latérale + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="rear_view"> + <panel_camera_item.text name="rear_view_text"> + Vue arrière + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="camera_modes_list"> + <panel_camera_item name="object_view"> + <panel_camera_item.text name="object_view_text"> + Vue de l'objet + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="mouselook_view"> + <panel_camera_item.text name="mouselook_view_text"> + Vue subjective + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="zoom" tool_tip="Zoomer en direction du point central"> + <joystick_rotate name="cam_rotate_stick" tool_tip="Faire tourner la caméra autour du point central"/> + <slider_bar name="zoom_slider" tool_tip="Zoomer en direction du point central"/> + <joystick_track name="cam_track_stick" tool_tip="Déplacer la caméra vers le haut et le bas, la gauche et la droite"/> + </panel> + </panel> + <panel name="buttons"> + <button label="" name="presets_btn" tool_tip="Préréglages"/> + <button label="" name="pan_btn" tool_tip="Rotation - Zoom - Panoramique"/> + <button label="" name="avatarview_btn" tool_tip="Modes"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/fr/floater_help_browser.xml b/indra/newview/skins/minimal/xui/fr/floater_help_browser.xml new file mode 100644 index 0000000000..09d763b809 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/floater_help_browser.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="floater_help_browser" title="AIDE RAPIDE"> + <floater.string name="loading_text"> + Chargement… + </floater.string> + <layout_stack name="stack1"> + <layout_panel name="external_controls"/> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/fr/floater_nearby_chat.xml b/indra/newview/skins/minimal/xui/fr/floater_nearby_chat.xml new file mode 100644 index 0000000000..9b1b21c434 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/floater_nearby_chat.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="nearby_chat" title="CHAT PRÈS DE MOI"> + <check_box label="Traduction du chat (fournie par Google)" name="translate_chat_checkbox"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/fr/inspect_avatar.xml b/indra/newview/skins/minimal/xui/fr/inspect_avatar.xml new file mode 100644 index 0000000000..553646f8e9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/inspect_avatar.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_avatar"> + <string name="Subtitle"> + [AGE] + </string> + <string name="Details"> + [SL_PROFILE] + </string> + <text name="user_subtitle" value="11 mois, 3 jours"/> + <text name="user_details"> + This is my second life description and I really think it is great. But for some reason my description is super extra long because I like to talk a whole lot + </text> + <slider name="volume_slider" tool_tip="Volume de la voix" value="0.5"/> + <button label="Devenir amis" name="add_friend_btn"/> + <button label="IM" name="im_btn"/> + <button label="Profil" name="view_profile_btn"/> + <panel name="moderator_panel"> + <button label="Désactiver le chat vocal" name="disable_voice"/> + <button label="Activer le chat vocal" name="enable_voice"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/fr/inspect_object.xml b/indra/newview/skins/minimal/xui/fr/inspect_object.xml new file mode 100644 index 0000000000..b66af7a2bf --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/inspect_object.xml @@ -0,0 +1,48 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_object"> + <string name="Creator"> + Par [CREATOR] + </string> + <string name="CreatorAndOwner"> + De [CREATOR] +Propriétaire [OWNER] + </string> + <string name="Price"> + [AMOUNT] L$ + </string> + <string name="PriceFree"> + Gratuit ! + </string> + <string name="Touch"> + Toucher + </string> + <string name="Sit"> + M'asseoir + </string> + <text name="object_name" value="Test Object Name That Is actually two lines and Really Long"/> + <text name="object_creator"> + par secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about +owner secondlife:///app/agent/0e346d8b-4433-4d66-a6b0-fd37083abc4c/about + </text> + <text name="price_text"> + 30 000 L$ + </text> + <text name="object_description"> + This is a really long description for an object being as how it is at least 80 characters in length and so but maybe more like 120 at this point. Who knows, really? + </text> + <text name="object_media_url"> + http://www.superdupertest.com + </text> + <button label="Acheter" name="buy_btn"/> + <button label="Payer" name="pay_btn"/> + <button label="Prendre une copie" name="take_free_copy_btn"/> + <button label="Toucher" name="touch_btn"/> + <button label="M'asseoir" name="sit_btn"/> + <button label="Ouvert" name="open_btn"/> + <icon name="secure_browsing" tool_tip="Navigation sécurisée"/> + <button label="Plus" name="more_info_btn"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/fr/menu_add_wearable_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_add_wearable_gear.xml new file mode 100644 index 0000000000..7e7993175e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_add_wearable_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Add Wearable Gear Menu"> + <menu_item_check label="Trier en commençant par le plus récent" name="sort_by_most_recent"/> + <menu_item_check label="Trier par nom" name="sort_by_name"/> + <menu_item_check label="Trier par type" name="sort_by_type"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_attachment_other.xml b/indra/newview/skins/minimal/xui/fr/menu_attachment_other.xml new file mode 100644 index 0000000000..f48513eb2b --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_attachment_other.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_avatar_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Voir le profil" name="Profile..."/> + <menu_item_call label="Devenir amis" name="Add Friend"/> + <menu_item_call label="IM" name="Send IM..."/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Inviter dans le groupe" name="Invite..."/> + <menu_item_call label="Ignorer" name="Avatar Mute"/> + <menu_item_call label="Signaler" name="abuse"/> + <menu_item_call label="Figer" name="Freeze..."/> + <menu_item_call label="Expulser" name="Eject..."/> + <menu_item_call label="Déboguer les textures" name="Debug..."/> + <menu_item_call label="Zoomer en avant" name="Zoom In"/> + <menu_item_call label="Payer" name="Pay..."/> + <menu_item_call label="Profil de l'objet" name="Object Inspect"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_attachment_self.xml b/indra/newview/skins/minimal/xui/fr/menu_attachment_self.xml new file mode 100644 index 0000000000..78198fb5a8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_attachment_self.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Attachment Pie"> + <menu_item_call label="Toucher" name="Attachment Object Touch"/> + <menu_item_call label="Modifier" name="Edit..."/> + <menu_item_call label="Détacher" name="Detach"/> + <menu_item_call label="M'asseoir" name="Sit Down Here"/> + <menu_item_call label="Me lever" name="Stand Up"/> + <menu_item_call label="Changer de tenue" name="Change Outfit"/> + <menu_item_call label="Modifier ma tenue" name="Edit Outfit"/> + <menu_item_call label="Modifier ma silhouette" name="Edit My Shape"/> + <menu_item_call label="Mes amis" name="Friends..."/> + <menu_item_call label="Mes groupes" name="Groups..."/> + <menu_item_call label="Mon profil" name="Profile..."/> + <menu_item_call label="Déboguer les textures" name="Debug..."/> + <menu_item_call label="Lâcher" name="Drop"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_avatar_icon.xml b/indra/newview/skins/minimal/xui/fr/menu_avatar_icon.xml new file mode 100644 index 0000000000..3bac25c79b --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_avatar_icon.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Avatar Icon Menu"> + <menu_item_call label="Voir le profil" name="Show Profile"/> + <menu_item_call label="Envoyer IM..." name="Send IM"/> + <menu_item_call label="Devenir amis..." name="Add Friend"/> + <menu_item_call label="Supprimer cet ami..." name="Remove Friend"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_avatar_other.xml b/indra/newview/skins/minimal/xui/fr/menu_avatar_other.xml new file mode 100644 index 0000000000..08d1a20361 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_avatar_other.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_attachment_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Voir le profil" name="Profile..."/> + <menu_item_call label="Devenir amis" name="Add Friend"/> + <menu_item_call label="IM" name="Send IM..."/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Inviter dans le groupe" name="Invite..."/> + <menu_item_call label="Ignorer" name="Avatar Mute"/> + <menu_item_call label="Signaler" name="abuse"/> + <menu_item_call label="Figer" name="Freeze..."/> + <menu_item_call label="Expulser" name="Eject..."/> + <menu_item_call label="Déboguer les textures" name="Debug..."/> + <menu_item_call label="Zoomer en avant" name="Zoom In"/> + <menu_item_call label="Payer" name="Pay..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_avatar_self.xml b/indra/newview/skins/minimal/xui/fr/menu_avatar_self.xml new file mode 100644 index 0000000000..c7ee2e9f88 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_avatar_self.xml @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Self Pie"> + <menu_item_call label="M'asseoir" name="Sit Down Here"/> + <menu_item_call label="Me lever" name="Stand Up"/> + <context_menu label="Enlever" name="Take Off >"> + <context_menu label="Habits" name="Clothes >"> + <menu_item_call label="Chemise" name="Shirt"/> + <menu_item_call label="Pantalon" name="Pants"/> + <menu_item_call label="Jupe" name="Skirt"/> + <menu_item_call label="Chaussures" name="Shoes"/> + <menu_item_call label="Chaussettes" name="Socks"/> + <menu_item_call label="Veste" name="Jacket"/> + <menu_item_call label="Gants" name="Gloves"/> + <menu_item_call label="Débardeur" name="Self Undershirt"/> + <menu_item_call label="Caleçon" name="Self Underpants"/> + <menu_item_call label="Tatouage" name="Self Tattoo"/> + <menu_item_call label="Alpha" name="Self Alpha"/> + <menu_item_call label="Tous les habits" name="All Clothes"/> + </context_menu> + <context_menu label="HUD" name="Object Detach HUD"/> + <context_menu label="Détacher" name="Object Detach"/> + <menu_item_call label="Tout détacher" name="Detach All"/> + </context_menu> + <menu_item_call label="Changer de tenue" name="Chenge Outfit"/> + <menu_item_call label="Modifier ma tenue" name="Edit Outfit"/> + <menu_item_call label="Modifier ma silhouette" name="Edit My Shape"/> + <menu_item_call label="Mes amis" name="Friends..."/> + <menu_item_call label="Mes groupes" name="Groups..."/> + <menu_item_call label="Mon profil" name="Profile..."/> + <menu_item_call label="Déboguer les textures" name="Debug..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_bottomtray.xml b/indra/newview/skins/minimal/xui/fr/menu_bottomtray.xml new file mode 100644 index 0000000000..bfdc89c5bb --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_bottomtray.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_camera_move_controls_menu"> + <menu_item_check label="Bouton Geste" name="ShowGestureButton"/> + <menu_item_check label="Bouton Bouger" name="ShowMoveButton"/> + <menu_item_check label="Bouton Affichage" name="ShowCameraButton"/> + <menu_item_check label="Bouton Photo" name="ShowSnapshotButton"/> + <menu_item_check label="Bouton Panneau latéral" name="ShowSidebarButton"/> + <menu_item_check label="Bouton Construire" name="ShowBuildButton"/> + <menu_item_check label="Bouton Rechercher" name="ShowSearchButton"/> + <menu_item_check label="Bouton Carte" name="ShowWorldMapButton"/> + <menu_item_check label="Bouton Mini-carte" name="ShowMiniMapButton"/> + <menu_item_call label="Couper" name="NearbyChatBar_Cut"/> + <menu_item_call label="Copier" name="NearbyChatBar_Copy"/> + <menu_item_call label="Coller" name="NearbyChatBar_Paste"/> + <menu_item_call label="Supprimer" name="NearbyChatBar_Delete"/> + <menu_item_call label="Tout sélectionner" name="NearbyChatBar_Select_All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_cof_attachment.xml b/indra/newview/skins/minimal/xui/fr/menu_cof_attachment.xml new file mode 100644 index 0000000000..a4ead48b6b --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_cof_attachment.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Attachment"> + <menu_item_call label="Détacher" name="detach"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_cof_body_part.xml b/indra/newview/skins/minimal/xui/fr/menu_cof_body_part.xml new file mode 100644 index 0000000000..4b6907fcc6 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_cof_body_part.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Body"> + <menu_item_call label="Remplacer" name="replace"/> + <menu_item_call label="Modifier" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_cof_clothing.xml b/indra/newview/skins/minimal/xui/fr/menu_cof_clothing.xml new file mode 100644 index 0000000000..03cc569704 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_cof_clothing.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Clothing"> + <menu_item_call label="Enlever" name="take_off"/> + <menu_item_call label="Modifier" name="edit"/> + <menu_item_call label="Remplacer" name="replace"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_cof_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_cof_gear.xml new file mode 100644 index 0000000000..8276d57025 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_cof_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear COF"> + <menu label="Nouveaux habits" name="COF.Gear.New_Clothes"/> + <menu label="Nouvelles parties du corps" name="COF.Geear.New_Body_Parts"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_edit.xml b/indra/newview/skins/minimal/xui/fr/menu_edit.xml new file mode 100644 index 0000000000..56669f31e1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_edit.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu label="Modifier" name="Edit"> + <menu_item_call label="Annuler" name="Undo"/> + <menu_item_call label="Refaire" name="Redo"/> + <menu_item_call label="Couper" name="Cut"/> + <menu_item_call label="Copier" name="Copy"/> + <menu_item_call label="Coller" name="Paste"/> + <menu_item_call label="Supprimer" name="Delete"/> + <menu_item_call label="Dupliquer" name="Duplicate"/> + <menu_item_call label="Tout sélectionner" name="Select All"/> + <menu_item_call label="Désélectionner" name="Deselect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_favorites.xml b/indra/newview/skins/minimal/xui/fr/menu_favorites.xml new file mode 100644 index 0000000000..5f1545fde7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_favorites.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Téléporter" name="Teleport To Landmark"/> + <menu_item_call label="Voir/Modifier le repère" name="Landmark Open"/> + <menu_item_call label="Copier la SLurl" name="Copy slurl"/> + <menu_item_call label="Voir sur la carte" name="Show On Map"/> + <menu_item_call label="Copier" name="Landmark Copy"/> + <menu_item_call label="Coller" name="Landmark Paste"/> + <menu_item_call label="Supprimer" name="Delete"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_gesture_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_gesture_gear.xml new file mode 100644 index 0000000000..062dd0f005 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_gesture_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_gesture_gear"> + <menu_item_call label="Ajouter/Supprimer des favoris" name="activate"/> + <menu_item_call label="Copier" name="copy_gesture"/> + <menu_item_call label="Coller" name="paste"/> + <menu_item_call label="Copier l'UUID" name="copy_uuid"/> + <menu_item_call label="Enregistrer dans la tenue actuelle" name="save_to_outfit"/> + <menu_item_call label="Modifier" name="edit_gesture"/> + <menu_item_call label="Inspecter" name="inspect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_group_plus.xml b/indra/newview/skins/minimal/xui/fr/menu_group_plus.xml new file mode 100644 index 0000000000..0db5afedc7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_group_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Rejoindre des groupes..." name="item_join"/> + <menu_item_call label="Nouveau groupe..." name="item_new"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_hide_navbar.xml b/indra/newview/skins/minimal/xui/fr/menu_hide_navbar.xml new file mode 100644 index 0000000000..20af901ddc --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_hide_navbar.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_navbar_menu"> + <menu_item_check label="Afficher la barre de navigation" name="ShowNavbarNavigationPanel"/> + <menu_item_check label="Afficher la barre des favoris" name="ShowNavbarFavoritesPanel"/> + <menu_item_check label="Afficher la mini-barre d'emplacement" name="ShowMiniLocationPanel"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_im_well_button.xml b/indra/newview/skins/minimal/xui/fr/menu_im_well_button.xml new file mode 100644 index 0000000000..8ef1529e6b --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_im_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="IM Well Button Context Menu"> + <menu_item_call label="Tout fermer" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_imchiclet_adhoc.xml b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_adhoc.xml new file mode 100644 index 0000000000..4d9a103058 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_adhoc.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet AdHoc Menu"> + <menu_item_call label="Mettre fin à la session" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_imchiclet_group.xml b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_group.xml new file mode 100644 index 0000000000..59f97d8b48 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet Group Menu"> + <menu_item_call label="Profil du groupe" name="Show Profile"/> + <menu_item_call label="Afficher la session" name="Chat"/> + <menu_item_call label="Mettre fin à la session" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_imchiclet_p2p.xml b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_p2p.xml new file mode 100644 index 0000000000..ecc8cee413 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_imchiclet_p2p.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet P2P Menu"> + <menu_item_call label="Voir le profil" name="Show Profile"/> + <menu_item_call label="Devenir amis" name="Add Friend"/> + <menu_item_call label="Afficher la session" name="Send IM"/> + <menu_item_call label="Mettre fin à la session" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inspect_avatar_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_inspect_avatar_gear.xml new file mode 100644 index 0000000000..231a175ee5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inspect_avatar_gear.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu name="Gear Menu"> + <menu_item_call label="Voir le profil" name="view_profile"/> + <menu_item_call label="Devenir amis" name="add_friend"/> + <menu_item_call label="IM" name="im"/> + <menu_item_call label="Téléporter" name="teleport"/> + <menu_item_call label="Ignorer" name="block"/> + <menu_item_call label="Ne plus ignorer" name="unblock"/> + <menu_item_call label="Signaler" name="report"/> + <menu_item_call label="Figer" name="freeze"/> + <menu_item_call label="Expulser" name="eject"/> + <menu_item_call label="Éjecter" name="kick"/> + <menu_item_call label="Représentant de l'Assistance client" name="csr"/> + <menu_item_call label="Déboguer les textures" name="debug"/> + <menu_item_call label="Situer sur la carte" name="find_on_map"/> + <menu_item_call label="Zoomer en avant" name="zoom_in"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inspect_object_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_inspect_object_gear.xml new file mode 100644 index 0000000000..074bb54cdc --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inspect_object_gear.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Toucher" name="touch"/> + <menu_item_call label="M'asseoir" name="sit"/> + <menu_item_call label="Payer" name="pay"/> + <menu_item_call label="Acheter" name="buy"/> + <menu_item_call label="Prendre" name="take"/> + <menu_item_call label="Prendre une copie" name="take_copy"/> + <menu_item_call label="Ouvrir" name="open"/> + <menu_item_call label="Modifier" name="edit"/> + <menu_item_call label="Porter" name="wear"/> + <menu_item_call label="Ajouter" name="add"/> + <menu_item_call label="Signaler" name="report"/> + <menu_item_call label="Ignorer" name="block"/> + <menu_item_call label="Zoomer en avant" name="zoom_in"/> + <menu_item_call label="Supprimer" name="remove"/> + <menu_item_call label="En savoir plus" name="more_info"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inspect_self_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_inspect_self_gear.xml new file mode 100644 index 0000000000..3bc164788a --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inspect_self_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="M'asseoir" name="sit_down_here"/> + <menu_item_call label="Me lever" name="stand_up"/> + <menu_item_call label="Changer de tenue" name="change_outfit"/> + <menu_item_call label="Mon profil" name="my_profile"/> + <menu_item_call label="Mes amis" name="my_friends"/> + <menu_item_call label="Mes groupes" name="my_groups"/> + <menu_item_call label="Déboguer les textures" name="Debug..."/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inv_offer_chiclet.xml b/indra/newview/skins/minimal/xui/fr/menu_inv_offer_chiclet.xml new file mode 100644 index 0000000000..a9b2883cca --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inv_offer_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="InvOfferChiclet Menu"> + <menu_item_call label="Fermer" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inventory.xml b/indra/newview/skins/minimal/xui/fr/menu_inventory.xml new file mode 100644 index 0000000000..a2279cf0ac --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inventory.xml @@ -0,0 +1,86 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Partager" name="Share"/> + <menu_item_call label="Acheter" name="Task Buy"/> + <menu_item_call label="Ouvrir" name="Task Open"/> + <menu_item_call label="Jouer" name="Task Play"/> + <menu_item_call label="Propriétés" name="Task Properties"/> + <menu_item_call label="Renommer" name="Task Rename"/> + <menu_item_call label="Supprimer" name="Task Remove"/> + <menu_item_call label="Vider la corbeille" name="Empty Trash"/> + <menu_item_call label="Vider les objets trouvés" name="Empty Lost And Found"/> + <menu_item_call label="Nouveau dossier" name="New Folder"/> + <menu_item_call label="Nouveau script" name="New Script"/> + <menu_item_call label="Nouvelle note" name="New Note"/> + <menu_item_call label="Nouveau geste" name="New Gesture"/> + <menu label="Nouveaux habits" name="New Clothes"> + <menu_item_call label="Nouvelle chemise" name="New Shirt"/> + <menu_item_call label="Nouveau pantalon" name="New Pants"/> + <menu_item_call label="Nouvelles chaussures" name="New Shoes"/> + <menu_item_call label="Nouvelles chaussettes" name="New Socks"/> + <menu_item_call label="Nouvelle veste" name="New Jacket"/> + <menu_item_call label="Nouvelle jupe" name="New Skirt"/> + <menu_item_call label="Nouveaux gants" name="New Gloves"/> + <menu_item_call label="Nouveau débardeur" name="New Undershirt"/> + <menu_item_call label="Nouveau caleçon" name="New Underpants"/> + <menu_item_call label="Nouveau masque alpha" name="New Alpha Mask"/> + <menu_item_call label="Nouveau tatouage" name="New Tattoo"/> + </menu> + <menu label="Nouvelles parties du corps" name="New Body Parts"> + <menu_item_call label="Nouvelle silhouette" name="New Shape"/> + <menu_item_call label="Nouvelle peau" name="New Skin"/> + <menu_item_call label="Nouveaux cheveux" name="New Hair"/> + <menu_item_call label="Nouveaux yeux" name="New Eyes"/> + </menu> + <menu label="Changer de type" name="Change Type"> + <menu_item_call label="Défaut" name="Default"/> + <menu_item_call label="Gants" name="Gloves"/> + <menu_item_call label="Veste" name="Jacket"/> + <menu_item_call label="Pantalon" name="Pants"/> + <menu_item_call label="Silhouette" name="Shape"/> + <menu_item_call label="Chaussures" name="Shoes"/> + <menu_item_call label="Chemise" name="Shirt"/> + <menu_item_call label="Jupe" name="Skirt"/> + <menu_item_call label="Caleçon" name="Underpants"/> + <menu_item_call label="Débardeur" name="Undershirt"/> + </menu> + <menu_item_call label="Téléporter" name="Landmark Open"/> + <menu_item_call label="Ouvrir" name="Animation Open"/> + <menu_item_call label="Ouvrir" name="Sound Open"/> + <menu_item_call label="Remplacer la tenue actuelle" name="Replace Outfit"/> + <menu_item_call label="Ajouter à la tenue actuelle" name="Add To Outfit"/> + <menu_item_call label="Enlever de la tenue actuelle" name="Remove From Outfit"/> + <menu_item_call label="Trouver l'original" name="Find Original"/> + <menu_item_call label="Purger l'objet" name="Purge Item"/> + <menu_item_call label="Restaurer l'objet" name="Restore Item"/> + <menu_item_call label="Ouvrir" name="Open"/> + <menu_item_call label="Ouvrir l'original" name="Open Original"/> + <menu_item_call label="Propriétés" name="Properties"/> + <menu_item_call label="Renommer" name="Rename"/> + <menu_item_call label="Copier l'UUID (identifiant universel unique)" name="Copy Asset UUID"/> + <menu_item_call label="Copier" name="Copy"/> + <menu_item_call label="Coller" name="Paste"/> + <menu_item_call label="Coller comme lien" name="Paste As Link"/> + <menu_item_call label="Supprimer" name="Remove Link"/> + <menu_item_call label="Supprimer" name="Delete"/> + <menu_item_call label="Supprimer le dossier système" name="Delete System Folder"/> + <menu_item_call label="Démarrer le chat conférence" name="Conference Chat Folder"/> + <menu_item_call label="Jouer" name="Sound Play"/> + <menu_item_call label="À propos du repère" name="About Landmark"/> + <menu_item_call label="Jouer dans Second Life" name="Animation Play"/> + <menu_item_call label="Jouer localement" name="Animation Audition"/> + <menu_item_call label="Envoyer un message instantané" name="Send Instant Message"/> + <menu_item_call label="Offrir de téléporter..." name="Offer Teleport..."/> + <menu_item_call label="Démarrer le chat conférence" name="Conference Chat"/> + <menu_item_call label="Activer" name="Activate"/> + <menu_item_call label="Désactiver" name="Deactivate"/> + <menu_item_call label="Enregistrer sous" name="Save As"/> + <menu_item_call label="Détacher de vous" name="Detach From Yourself"/> + <menu_item_call label="Porter" name="Wearable And Object Wear"/> + <menu label="Attacher à" name="Attach To"/> + <menu label="Attacher au HUD " name="Attach To HUD"/> + <menu_item_call label="Modifier" name="Wearable Edit"/> + <menu_item_call label="Ajouter" name="Wearable Add"/> + <menu_item_call label="Enlever" name="Take Off"/> + <menu_item_call label="--aucune option--" name="--no options--"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inventory_add.xml b/indra/newview/skins/minimal/xui/fr/menu_inventory_add.xml new file mode 100644 index 0000000000..fe096b4a7e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inventory_add.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_inventory_add"> + <menu label="Importer" name="upload"> + <menu_item_call label="Image ([COST] L$)..." name="Upload Image"/> + <menu_item_call label="Son ([COST] L$)..." name="Upload Sound"/> + <menu_item_call label="Animation ([COST] L$)..." name="Upload Animation"/> + <menu_item_call label="Lot ([COST] L$ par fichier)..." name="Bulk Upload"/> + <menu_item_call label="Définir les droits de chargement par défaut" name="perm prefs"/> + </menu> + <menu_item_call label="Nouveau dossier" name="New Folder"/> + <menu_item_call label="Nouveau script" name="New Script"/> + <menu_item_call label="Nouvelle note" name="New Note"/> + <menu_item_call label="Nouveau geste" name="New Gesture"/> + <menu label="Nouveaux habits" name="New Clothes"> + <menu_item_call label="Nouvelle chemise" name="New Shirt"/> + <menu_item_call label="Nouveau pantalon" name="New Pants"/> + <menu_item_call label="Nouvelles chaussures" name="New Shoes"/> + <menu_item_call label="Nouvelles chaussettes" name="New Socks"/> + <menu_item_call label="Nouvelle veste" name="New Jacket"/> + <menu_item_call label="Nouvelle jupe" name="New Skirt"/> + <menu_item_call label="Nouveaux gants" name="New Gloves"/> + <menu_item_call label="Nouveau débardeur" name="New Undershirt"/> + <menu_item_call label="Nouveau caleçon" name="New Underpants"/> + <menu_item_call label="Nouvel alpha" name="New Alpha"/> + <menu_item_call label="Nouveau tatouage" name="New Tattoo"/> + </menu> + <menu label="Nouvelles parties du corps" name="New Body Parts"> + <menu_item_call label="Nouvelle silhouette" name="New Shape"/> + <menu_item_call label="Nouvelle peau" name="New Skin"/> + <menu_item_call label="Nouveaux cheveux" name="New Hair"/> + <menu_item_call label="Nouveaux yeux" name="New Eyes"/> + </menu> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_inventory_gear_default.xml b/indra/newview/skins/minimal/xui/fr/menu_inventory_gear_default.xml new file mode 100644 index 0000000000..f28918ae14 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_inventory_gear_default.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="menu_gear_default"> + <menu_item_call label="Nouvelle fenêtre d'inventaire" name="new_window"/> + <menu_item_check label="Trier par nom" name="sort_by_name"/> + <menu_item_check label="Trier en commençant par le plus récent" name="sort_by_recent"/> + <menu_item_check label="Dossiers système en premier" name="sort_system_folders_to_top"/> + <menu_item_call label="Afficher les filtres" name="show_filters"/> + <menu_item_call label="Réinitialiser les filtres" name="reset_filters"/> + <menu_item_call label="Fermer tous les dossiers" name="close_folders"/> + <menu_item_call label="Vider les objets trouvés" name="empty_lostnfound"/> + <menu_item_call label="Enregistrer la texture sous" name="Save Texture As"/> + <menu_item_call label="Partager" name="Share"/> + <menu_item_call label="Trouver l'original" name="Find Original"/> + <menu_item_call label="Trouver tous les liens" name="Find All Links"/> + <menu_item_call label="Vider la corbeille" name="empty_trash"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_land.xml b/indra/newview/skins/minimal/xui/fr/menu_land.xml new file mode 100644 index 0000000000..b84daee3ae --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_land.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Land Pie"> + <menu_item_call label="À propos du terrain" name="Place Information..."/> + <menu_item_call label="M'asseoir ici" name="Sit Here"/> + <menu_item_call label="Acheter ce terrain" name="Land Buy"/> + <menu_item_call label="Acheter un pass" name="Land Buy Pass"/> + <menu_item_call label="Construire" name="Create"/> + <menu_item_call label="Modifier le terrain" name="Edit Terrain"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_landmark.xml b/indra/newview/skins/minimal/xui/fr/menu_landmark.xml new file mode 100644 index 0000000000..73eaa4af7e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_landmark.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="landmark_overflow_menu"> + <menu_item_call label="Copier la SLurl" name="copy"/> + <menu_item_call label="Supprimer" name="delete"/> + <menu_item_call label="Créer un favori" name="pick"/> + <menu_item_call label="Ajouter à la barre des favoris" name="add_to_favbar"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_login.xml b/indra/newview/skins/minimal/xui/fr/menu_login.xml new file mode 100644 index 0000000000..400c77e51a --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_login.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Login Menu"> + <menu label="Moi" name="File"> + <menu_item_call label="Préférences" name="Preferences..."/> + <menu_item_call label="Quitter [APP_NAME]" name="Quit"/> + </menu> + <menu label="Aide" name="Help"> + <menu_item_call label="Aide de [SECOND_LIFE]" name="Second Life Help"/> + <menu_item_call label="À propos de [APP_NAME]" name="About Second Life"/> + </menu> + <menu_item_check label="Afficher le menu de débogage" name="Show Debug Menu"/> + <menu label="Débogage" name="Debug"> + <menu_item_call label="Afficher les paramètres de débogage" name="Debug Settings"/> + <menu_item_call label="Paramètres de couleurs/interface" name="UI/Color Settings"/> + <menu_item_call label="Outil d'aperçu XUI" name="UI Preview Tool"/> + <menu label="Tests de l'interface" name="UI Tests"/> + <menu_item_call label="Définir la taille de la fenêtre..." name="Set Window Size..."/> + <menu_item_call label="Afficher les conditions d'utilisation" name="TOS"/> + <menu_item_call label="Afficher le message critique" name="Critical"/> + <menu_item_call label="Test du navigateur de médias" name="Web Browser Test"/> + <menu_item_call label="Test de la fenêtre flottante du contenu Web" name="Web Content Floater Test"/> + <menu_item_check label="Afficher le sélecteur de grille" name="Show Grid Picker"/> + <menu_item_call label="Afficher la console des notifications" name="Show Notifications Console"/> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/fr/menu_mini_map.xml b/indra/newview/skins/minimal/xui/fr/menu_mini_map.xml new file mode 100644 index 0000000000..b9d0a70383 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_mini_map.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Zoom rapproché" name="Zoom Close"/> + <menu_item_call label="Zoom moyen" name="Zoom Medium"/> + <menu_item_call label="Zoom éloigné" name="Zoom Far"/> + <menu_item_call label="Zoom par défaut" name="Zoom Default"/> + <menu_item_check label="Faire pivoter la carte" name="Rotate Map"/> + <menu_item_check label="Centrage auto" name="Auto Center"/> + <menu_item_call label="Arrêter de suivre" name="Stop Tracking"/> + <menu_item_call label="Carte du monde" name="World Map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_navbar.xml b/indra/newview/skins/minimal/xui/fr/menu_navbar.xml new file mode 100644 index 0000000000..08d810b653 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_navbar.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Navbar Menu"> + <menu_item_check label="Voir les coordonnées" name="Show Coordinates"/> + <menu_item_check label="Afficher les propriétés de la parcelle" name="Show Parcel Properties"/> + <menu_item_call label="Repère" name="Landmark"/> + <menu_item_call label="Couper" name="Cut"/> + <menu_item_call label="Copier" name="Copy"/> + <menu_item_call label="Coller" name="Paste"/> + <menu_item_call label="Supprimer" name="Delete"/> + <menu_item_call label="Tout sélectionner" name="Select All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_nearby_chat.xml b/indra/newview/skins/minimal/xui/fr/menu_nearby_chat.xml new file mode 100644 index 0000000000..99e22aeff7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_nearby_chat.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="NearBy Chat Menu"> + <menu_item_call label="Afficher les personnes près de vous..." name="nearby_people"/> + <menu_item_check label="Afficher le texte ignoré" name="muted_text"/> + <menu_item_check label="Afficher les icônes des Buddy" name="show_buddy_icons"/> + <menu_item_check label="Afficher les noms" name="show_names"/> + <menu_item_check label="Afficher les icônes et les noms" name="show_icons_and_names"/> + <menu_item_call label="Taille de la police" name="font_size"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_notification_well_button.xml b/indra/newview/skins/minimal/xui/fr/menu_notification_well_button.xml new file mode 100644 index 0000000000..323bfdbf16 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_notification_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Notification Well Button Context Menu"> + <menu_item_call label="Tout fermer" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_object.xml b/indra/newview/skins/minimal/xui/fr/menu_object.xml new file mode 100644 index 0000000000..a50a9df4b1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_object.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Object Pie"> + <menu_item_call label="Toucher" name="Object Touch"> + <menu_item_call.on_enable name="EnableTouch" parameter="Toucher"/> + </menu_item_call> + <menu_item_call label="Modifier" name="Edit..."/> + <menu_item_call label="Construire" name="Build"/> + <menu_item_call label="Ouvrir" name="Open"/> + <menu_item_call label="M'asseoir ici" name="Object Sit"/> + <menu_item_call label="Me lever" name="Object Stand Up"/> + <menu_item_call label="Profil de l'objet" name="Object Inspect"/> + <menu_item_call label="Zoomer en avant" name="Zoom In"/> + <context_menu label="Porter" name="Put On"> + <menu_item_call label="Porter" name="Wear"/> + <menu_item_call label="Ajouter" name="Add"/> + <context_menu label="Attacher" name="Object Attach"/> + <context_menu label="Attacher HUD" name="Object Attach HUD"/> + </context_menu> + <context_menu label="Supprimer" name="Remove"> + <menu_item_call label="Signaler une infraction" name="Report Abuse..."/> + <menu_item_call label="Ignorer" name="Object Mute"/> + <menu_item_call label="Retour" name="Return..."/> + <menu_item_call label="Supprimer" name="Delete"/> + </context_menu> + <menu_item_call label="Prendre" name="Pie Object Take"/> + <menu_item_call label="Prendre une copie" name="Take Copy"/> + <menu_item_call label="Payer" name="Pay..."/> + <menu_item_call label="Acheter" name="Buy..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_object_icon.xml b/indra/newview/skins/minimal/xui/fr/menu_object_icon.xml new file mode 100644 index 0000000000..69f8e88a0d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_object_icon.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Object Icon Menu"> + <menu_item_call label="Profil de l'objet..." name="Object Profile"/> + <menu_item_call label="Ignorer..." name="Block"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_outfit_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_outfit_gear.xml new file mode 100644 index 0000000000..5db7f176b5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_outfit_gear.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Outfit"> + <menu_item_call label="Porter - Remplacer la tenue actuelle" name="wear"/> + <menu_item_call label="Porter - Ajouter à la tenue actuelle" name="wear_add"/> + <menu_item_call label="Enlever - Supprimer de la tenue actuelle" name="take_off"/> + <menu label="Nouveaux habits" name="New Clothes"> + <menu_item_call label="Nouvelle chemise" name="New Shirt"/> + <menu_item_call label="Nouveau pantalon" name="New Pants"/> + <menu_item_call label="Nouvelles chaussures" name="New Shoes"/> + <menu_item_call label="Nouvelles chaussettes" name="New Socks"/> + <menu_item_call label="Nouvelle veste" name="New Jacket"/> + <menu_item_call label="Nouvelle jupe" name="New Skirt"/> + <menu_item_call label="Nouveaux gants" name="New Gloves"/> + <menu_item_call label="Nouveau débardeur" name="New Undershirt"/> + <menu_item_call label="Nouveau caleçon" name="New Underpants"/> + <menu_item_call label="Nouvel alpha" name="New Alpha"/> + <menu_item_call label="Nouveau tatouage" name="New Tattoo"/> + </menu> + <menu label="Nouvelles parties du corps" name="New Body Parts"> + <menu_item_call label="Nouvelle silhouette" name="New Shape"/> + <menu_item_call label="Nouvelle peau" name="New Skin"/> + <menu_item_call label="Nouveaux cheveux" name="New Hair"/> + <menu_item_call label="Nouveaux yeux" name="New Eyes"/> + </menu> + <menu_item_call label="Renommer la tenue" name="rename"/> + <menu_item_call label="Supprimer la tenue" name="delete_outfit"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_outfit_tab.xml b/indra/newview/skins/minimal/xui/fr/menu_outfit_tab.xml new file mode 100644 index 0000000000..2a7f618e07 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_outfit_tab.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit"> + <menu_item_call label="Porter - Remplacer la tenue actuelle" name="wear_replace"/> + <menu_item_call label="Porter - Ajouter à la tenue actuelle" name="wear_add"/> + <menu_item_call label="Enlever - Supprimer de la tenue actuelle" name="take_off"/> + <menu_item_call label="Modifier la tenue" name="edit"/> + <menu_item_call label="Renommer la tenue" name="rename"/> + <menu_item_call label="Supprimer la tenue" name="delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_participant_list.xml b/indra/newview/skins/minimal/xui/fr/menu_participant_list.xml new file mode 100644 index 0000000000..f91a30f6bb --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_participant_list.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Participant List Context Menu"> + <menu_item_check label="Trier par nom" name="SortByName"/> + <menu_item_check label="Trier par intervenants récents" name="SortByRecentSpeakers"/> + <menu_item_call label="Voir le profil" name="View Profile"/> + <menu_item_call label="Devenir amis" name="Add Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Partager" name="Share"/> + <menu_item_call label="Payer" name="Pay"/> + <menu_item_check label="Afficher les icônes des résidents" name="View Icons"/> + <menu_item_check label="Bloquer le chat vocal" name="Block/Unblock"/> + <menu_item_check label="Ignorer le texte" name="MuteText"/> + <context_menu label="Options du modérateur" name="Moderator Options"> + <menu_item_check label="Autoriser les chats écrits" name="AllowTextChat"/> + <menu_item_call label="Ignorer ce participant" name="ModerateVoiceMuteSelected"/> + <menu_item_call label="Ne plus ignorer ce participant" name="ModerateVoiceUnMuteSelected"/> + <menu_item_call label="Ignorer les autres" name="ModerateVoiceMute"/> + <menu_item_call label="Ne plus ignorer les autres" name="ModerateVoiceUnmute"/> + </context_menu> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_friends_view_sort.xml b/indra/newview/skins/minimal/xui/fr/menu_people_friends_view_sort.xml new file mode 100644 index 0000000000..a6170a6c16 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_friends_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Trier par nom" name="sort_name"/> + <menu_item_check label="Trier par statut" name="sort_status"/> + <menu_item_check label="Afficher les icônes des résidents" name="view_icons"/> + <menu_item_check label="Afficher les droits octroyés" name="view_permissions"/> + <menu_item_call label="Afficher les résidents et les objets ignorés" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_groups.xml b/indra/newview/skins/minimal/xui/fr/menu_people_groups.xml new file mode 100644 index 0000000000..eb51b4cf7e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_groups.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Afficher les infos" name="View Info"/> + <menu_item_call label="Chat" name="Chat"/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Activer" name="Activate"/> + <menu_item_call label="Quitter" name="Leave"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_groups_view_sort.xml b/indra/newview/skins/minimal/xui/fr/menu_people_groups_view_sort.xml new file mode 100644 index 0000000000..34f949cf2c --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_groups_view_sort.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Afficher les icônes des groupes" name="Display Group Icons"/> + <menu_item_call label="Quitter le groupe sélectionné" name="Leave Selected Group"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_nearby.xml b/indra/newview/skins/minimal/xui/fr/menu_people_nearby.xml new file mode 100644 index 0000000000..26bd3978a9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_nearby.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Avatar Context Menu"> + <menu_item_call label="Voir le profil" name="View Profile"/> + <menu_item_call label="Devenir amis" name="Add Friend"/> + <menu_item_call label="Supprimer cet ami" name="Remove Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Carte" name="Map"/> + <menu_item_call label="Partager" name="Share"/> + <menu_item_call label="Payer" name="Pay"/> + <menu_item_check label="Ignorer/Ne plus ignorer" name="Block/Unblock"/> + <menu_item_call label="Proposer une téléportation" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_nearby_multiselect.xml b/indra/newview/skins/minimal/xui/fr/menu_people_nearby_multiselect.xml new file mode 100644 index 0000000000..8400ec0a14 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_nearby_multiselect.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Multi-Selected People Context Menu"> + <menu_item_call label="Devenir amis" name="Add Friends"/> + <menu_item_call label="Supprimer des amis" name="Remove Friend"/> + <menu_item_call label="IM" name="IM"/> + <menu_item_call label="Appeler" name="Call"/> + <menu_item_call label="Partager" name="Share"/> + <menu_item_call label="Payer" name="Pay"/> + <menu_item_call label="Proposer une téléportation" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_nearby_view_sort.xml b/indra/newview/skins/minimal/xui/fr/menu_people_nearby_view_sort.xml new file mode 100644 index 0000000000..45f97e062e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_nearby_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Trier par intervenants récents" name="sort_by_recent_speakers"/> + <menu_item_check label="Trier par nom" name="sort_name"/> + <menu_item_check label="Trier par distance" name="sort_distance"/> + <menu_item_check label="Afficher les icônes des résidents" name="view_icons"/> + <menu_item_call label="Afficher les résidents et les objets interdits" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_people_recent_view_sort.xml b/indra/newview/skins/minimal/xui/fr/menu_people_recent_view_sort.xml new file mode 100644 index 0000000000..93b90ae61c --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_people_recent_view_sort.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Trier en commençant par le plus récent" name="sort_most"/> + <menu_item_check label="Trier par nom" name="sort_name"/> + <menu_item_check label="Afficher les icônes des résidents" name="view_icons"/> + <menu_item_call label="Afficher les résidents et les objets ignorés" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_picks.xml b/indra/newview/skins/minimal/xui/fr/menu_picks.xml new file mode 100644 index 0000000000..7d7174d43c --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_picks.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Picks"> + <menu_item_call label="Infos" name="pick_info"/> + <menu_item_call label="Modifier" name="pick_edit"/> + <menu_item_call label="Téléporter" name="pick_teleport"/> + <menu_item_call label="Carte" name="pick_map"/> + <menu_item_call label="Supprimer" name="pick_delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_picks_plus.xml b/indra/newview/skins/minimal/xui/fr/menu_picks_plus.xml new file mode 100644 index 0000000000..b6cde6d6e2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_picks_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="picks_plus_menu"> + <menu_item_call label="Nouveau favori" name="create_pick"/> + <menu_item_call label="Nouvelle petite annonce" name="create_classified"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_place.xml b/indra/newview/skins/minimal/xui/fr/menu_place.xml new file mode 100644 index 0000000000..6b0f4db752 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_place.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="place_overflow_menu"> + <menu_item_call label="Enregistrer comme repère" name="landmark"/> + <menu_item_call label="Créer un favori" name="pick"/> + <menu_item_call label="Acheter un pass" name="pass"/> + <menu_item_call label="Modifier" name="edit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_place_add_button.xml b/indra/newview/skins/minimal/xui/fr/menu_place_add_button.xml new file mode 100644 index 0000000000..92f9e7719d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_place_add_button.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Ajouter un dossier" name="add_folder"/> + <menu_item_call label="Ajouter un repère" name="add_landmark"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_places_gear_folder.xml b/indra/newview/skins/minimal/xui/fr/menu_places_gear_folder.xml new file mode 100644 index 0000000000..3570bdec7f --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_places_gear_folder.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Ajouter un repère" name="add_landmark"/> + <menu_item_call label="Ajouter un dossier" name="add_folder"/> + <menu_item_call label="Couper" name="cut"/> + <menu_item_call label="Copier" name="copy_folder"/> + <menu_item_call label="Coller" name="paste"/> + <menu_item_call label="Renommer" name="rename"/> + <menu_item_call label="Supprimer" name="delete"/> + <menu_item_call label="Agrandir" name="expand"/> + <menu_item_call label="Réduire" name="collapse"/> + <menu_item_call label="Développer tous les dossiers" name="expand_all"/> + <menu_item_call label="Réduire tous les dossiers" name="collapse_all"/> + <menu_item_check label="Trier par date" name="sort_by_date"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_places_gear_landmark.xml b/indra/newview/skins/minimal/xui/fr/menu_places_gear_landmark.xml new file mode 100644 index 0000000000..5491c1b3fc --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_places_gear_landmark.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_ladmark_gear"> + <menu_item_call label="Téléporter" name="teleport"/> + <menu_item_call label="Plus d'informations" name="more_info"/> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Ajouter un repère" name="add_landmark"/> + <menu_item_call label="Ajouter un dossier" name="add_folder"/> + <menu_item_call label="Couper" name="cut"/> + <menu_item_call label="Copier le repère" name="copy_landmark"/> + <menu_item_call label="Copier la SLurl" name="copy_slurl"/> + <menu_item_call label="Coller" name="paste"/> + <menu_item_call label="Renommer" name="rename"/> + <menu_item_call label="Supprimer" name="delete"/> + <menu_item_call label="Développer tous les dossiers" name="expand_all"/> + <menu_item_call label="Réduire tous les dossiers" name="collapse_all"/> + <menu_item_check label="Trier par date" name="sort_by_date"/> + <menu_item_call label="Créer un favori" name="create_pick"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_profile_overflow.xml b/indra/newview/skins/minimal/xui/fr/menu_profile_overflow.xml new file mode 100644 index 0000000000..ddf898b791 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_profile_overflow.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="profile_overflow_menu"> + <menu_item_call label="Carte" name="show_on_map"/> + <menu_item_call label="Payer" name="pay"/> + <menu_item_call label="Partager" name="share"/> + <menu_item_call label="Ignorer" name="block"/> + <menu_item_call label="Ne plus ignorer" name="unblock"/> + <menu_item_call label="Éjecter" name="kick"/> + <menu_item_call label="Figer" name="freeze"/> + <menu_item_call label="Libérer" name="unfreeze"/> + <menu_item_call label="Représentant du service consommateur" name="csr"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_save_outfit.xml b/indra/newview/skins/minimal/xui/fr/menu_save_outfit.xml new file mode 100644 index 0000000000..f78db411b3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_save_outfit.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="save_outfit_menu"> + <menu_item_call label="Enregistrer" name="save_outfit"/> + <menu_item_call label="Enregistrer sous" name="save_as_new_outfit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_script_chiclet.xml b/indra/newview/skins/minimal/xui/fr/menu_script_chiclet.xml new file mode 100644 index 0000000000..46efa30bd6 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_script_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="ScriptChiclet Menu"> + <menu_item_call label="Fermer" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_slurl.xml b/indra/newview/skins/minimal/xui/fr/menu_slurl.xml new file mode 100644 index 0000000000..ddfa5c0849 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_slurl.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="À propos de l'URL" name="about_url"/> + <menu_item_call label="Téléporter vers l'URL" name="teleport_to_url"/> + <menu_item_call label="Carte" name="show_on_map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_teleport_history_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_gear.xml new file mode 100644 index 0000000000..3dea662cc2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Teleport History Gear Context Menu"> + <menu_item_call label="Développer tous les dossiers" name="Expand all folders"/> + <menu_item_call label="Réduire tous les dossiers" name="Collapse all folders"/> + <menu_item_call label="Effacer l'historique des téléportations" name="Clear Teleport History"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_teleport_history_item.xml b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_item.xml new file mode 100644 index 0000000000..fb4582dbce --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_item.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Téléporter" name="Teleport"/> + <menu_item_call label="Plus d'informations" name="More Information"/> + <menu_item_call label="Copier dans le presse-papiers" name="CopyToClipboard"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_teleport_history_tab.xml b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_tab.xml new file mode 100644 index 0000000000..369680985d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_teleport_history_tab.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Ouvrir" name="TabOpen"/> + <menu_item_call label="Fermer" name="TabClose"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_text_editor.xml b/indra/newview/skins/minimal/xui/fr/menu_text_editor.xml new file mode 100644 index 0000000000..b6f429aec9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_text_editor.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Text editor context menu"> + <menu_item_call label="Couper" name="Cut"/> + <menu_item_call label="Copier" name="Copy"/> + <menu_item_call label="Coller" name="Paste"/> + <menu_item_call label="Supprimer" name="Delete"/> + <menu_item_call label="Tout sélectionner" name="Select All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_topinfobar.xml b/indra/newview/skins/minimal/xui/fr/menu_topinfobar.xml new file mode 100644 index 0000000000..dc68f40fe7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_topinfobar.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_topinfobar"> + <menu_item_check label="Afficher les coordonnées" name="Show Coordinates"/> + <menu_item_check label="Afficher les propriétés de la parcelle" name="Show Parcel Properties"/> + <menu_item_call label="Repère" name="Landmark"/> + <menu_item_call label="Copier" name="Copy"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_agent.xml b/indra/newview/skins/minimal/xui/fr/menu_url_agent.xml new file mode 100644 index 0000000000..5ed627fbc3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_agent.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Voir le profil du résident" name="show_agent"/> + <menu_item_call label="Copier le nom dans le presse-papiers" name="url_copy_label"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_group.xml b/indra/newview/skins/minimal/xui/fr/menu_url_group.xml new file mode 100644 index 0000000000..de90c3ff7e --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Voir le profil du groupe" name="show_group"/> + <menu_item_call label="Copier le groupe dans le presse-papiers" name="url_copy_label"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_http.xml b/indra/newview/skins/minimal/xui/fr/menu_url_http.xml new file mode 100644 index 0000000000..5e96352999 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_http.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Ouvrir la page Web" name="url_open"/> + <menu_item_call label="Ouvrir dans un navigateur interne" name="url_open_internal"/> + <menu_item_call label="Ouvrir dans un navigateur externe" name="url_open_external"/> + <menu_item_call label="Copier l'URL dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_inventory.xml b/indra/newview/skins/minimal/xui/fr/menu_url_inventory.xml new file mode 100644 index 0000000000..8ab88b4be7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_inventory.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Afficher l'article d'inventaire" name="show_item"/> + <menu_item_call label="Copier le nom dans le presse-papiers" name="url_copy_label"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_map.xml b/indra/newview/skins/minimal/xui/fr/menu_url_map.xml new file mode 100644 index 0000000000..67e6986f5d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_map.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Me téléporter à cet endroit" name="teleport_to_location"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_objectim.xml b/indra/newview/skins/minimal/xui/fr/menu_url_objectim.xml new file mode 100644 index 0000000000..f581c3ef9d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_objectim.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Afficher les informations sur l'objet" name="show_object"/> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Me téléporter à l'emplacement de l'objet" name="teleport_to_object"/> + <menu_item_call label="Copier le nom de l'objet dans le presse-papiers" name="url_copy_label"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_parcel.xml b/indra/newview/skins/minimal/xui/fr/menu_url_parcel.xml new file mode 100644 index 0000000000..07b0eeca49 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_parcel.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Afficher les informations sur la parcelle" name="show_parcel"/> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_slapp.xml b/indra/newview/skins/minimal/xui/fr/menu_url_slapp.xml new file mode 100644 index 0000000000..f4b7e212ca --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_slapp.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Exécuter cette commande" name="run_slapp"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_slurl.xml b/indra/newview/skins/minimal/xui/fr/menu_url_slurl.xml new file mode 100644 index 0000000000..e44943cf15 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_slurl.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Afficher les informations sur ce lieu" name="show_place"/> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Me téléporter à cet endroit" name="teleport_to_location"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_url_teleport.xml b/indra/newview/skins/minimal/xui/fr/menu_url_teleport.xml new file mode 100644 index 0000000000..a5075a2740 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_url_teleport.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Me téléporter à cet endroit." name="teleport"/> + <menu_item_call label="Voir sur la carte" name="show_on_map"/> + <menu_item_call label="Copier la SLurl dans le presse-papiers" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_viewer.xml b/indra/newview/skins/minimal/xui/fr/menu_viewer.xml new file mode 100644 index 0000000000..bd1c077f52 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_viewer.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Main Menu"> + <menu label="Aide" name="Help"> + <menu_item_call label="Aide de [SECOND_LIFE]" name="Second Life Help"/> + </menu> + <menu label="Avancé" name="Advanced"> + <menu label="Raccourcis" name="Shortcuts"> + <menu_item_check label="Voler" name="Fly"/> + <menu_item_call label="Fermer la fenêtre" name="Close Window"/> + <menu_item_call label="Fermer toutes les fenêtres" name="Close All Windows"/> + <menu_item_call label="Réinitialiser la vue" name="Reset View"/> + </menu> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/fr/menu_wearable_list_item.xml b/indra/newview/skins/minimal/xui/fr/menu_wearable_list_item.xml new file mode 100644 index 0000000000..187cb4bcd2 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_wearable_list_item.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit Wearable Context Menu"> + <menu_item_call label="Remplacer" name="wear_replace"/> + <menu_item_call label="Porter" name="wear_wear"/> + <menu_item_call label="Ajouter" name="wear_add"/> + <menu_item_call label="Enlever / Détacher" name="take_off_or_detach"/> + <menu_item_call label="Détacher" name="detach"/> + <context_menu label="Attacher à" name="wearable_attach_to"/> + <context_menu label="Attacher au HUD" name="wearable_attach_to_hud"/> + <menu_item_call label="Enlever" name="take_off"/> + <menu_item_call label="Modifier" name="edit"/> + <menu_item_call label="Profil de l'article" name="object_profile"/> + <menu_item_call label="Afficher l'original" name="show_original"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_wearing_gear.xml b/indra/newview/skins/minimal/xui/fr/menu_wearing_gear.xml new file mode 100644 index 0000000000..0ca9fe1879 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_wearing_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Wearing"> + <menu_item_call label="Modifier la tenue" name="edit"/> + <menu_item_call label="Enlever" name="takeoff"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/fr/menu_wearing_tab.xml b/indra/newview/skins/minimal/xui/fr/menu_wearing_tab.xml new file mode 100644 index 0000000000..4d88445506 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/menu_wearing_tab.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Wearing"> + <menu_item_call label="Enlever" name="take_off"/> + <menu_item_call label="Détacher" name="detach"/> + <menu_item_call label="Modifier la tenue" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/fr/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/fr/panel_bottomtray.xml new file mode 100644 index 0000000000..3a01571f54 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_bottomtray.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="bottom_tray"> + <string name="DragIndicationImageName" value="Accordion_ArrowOpened_Off"/> + <string name="SpeakBtnToolTip" value="Active/Désactive le micro"/> + <string name="VoiceControlBtnToolTip" value="Affiche/Masque le panneau de contrôle de la voix"/> + <layout_stack name="toolbar_stack"> + <layout_panel name="gesture_panel"> + <gesture_combo_list label="Geste" name="Gesture" tool_tip="Affiche/Masque les gestes"/> + </layout_panel> + <layout_panel name="cam_panel"> + <bottomtray_button label="Affichage" name="camera_btn" tool_tip="Affiche/Masque le contrôle de la caméra"/> + </layout_panel> + <layout_panel name="avatar_and_destinations_panel"> + <radio_group name="avatar_and_destination_btns"> + <radio_item name="destination_btn" value="0"/> + <radio_item name="avatar_btn" value="1"/> + </radio_group> + </layout_panel> + <layout_panel name="people_panel"> + <bottomtray_button label="Personnes" name="show_people_button" tool_tip="Afficher la fenêtre des personnes."/> + </layout_panel> + <layout_panel name="profile_panel"> + <bottomtray_button label="Profil" name="show_profile_btn" tool_tip="Afficher la fenêtre de profil."/> + </layout_panel> + <layout_panel name="howto_panel"> + <bottomtray_button label="Aide rapide" name="show_help_btn" tool_tip="Ouvrir les rubriques d'aide rapide Second Life."/> + </layout_panel> + <layout_panel name="im_well_panel"> + <chiclet_im_well name="im_well"> + <button name="Unread IM messages" tool_tip="Conversations"/> + </chiclet_im_well> + </layout_panel> + <layout_panel name="notification_well_panel"> + <chiclet_notification name="notification_well"> + <button name="Unread" tool_tip="Notifications"/> + </chiclet_notification> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_im_control_panel.xml b/indra/newview/skins/minimal/xui/fr/panel_im_control_panel.xml new file mode 100644 index 0000000000..1f2169e22c --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_im_control_panel.xml @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_im_control_panel"> + <text name="avatar_name" value="Inconnu"/> + <layout_stack name="button_stack"> + <layout_panel name="view_profile_btn_panel"> + <button label="Profil" name="view_profile_btn"/> + </layout_panel> + <layout_panel name="add_friend_btn_panel"> + <button label="Devenir amis" name="add_friend_btn"/> + </layout_panel> + <layout_panel name="teleport_btn_panel"> + <button label="Téléporter" name="teleport_btn" tool_tip="Proposer de téléporter cette personne"/> + </layout_panel> + <layout_panel name="share_btn_panel"> + <button label="Partager" name="share_btn"/> + </layout_panel> + <layout_panel name="pay_btn_panel"> + <button label="Payer" name="pay_btn"/> + </layout_panel> + <layout_panel name="call_btn_panel"> + <button label="Appeler" name="call_btn"/> + </layout_panel> + <layout_panel name="end_call_btn_panel"> + <button label="Quitter l'appel" name="end_call_btn"/> + </layout_panel> + <layout_panel name="voice_ctrls_btn_panel"> + <button label="Contrôles vocaux" name="voice_ctrls_btn"/> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_login.xml b/indra/newview/skins/minimal/xui/fr/panel_login.xml new file mode 100644 index 0000000000..cb4822e96b --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_login.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_login"> + <panel.string name="create_account_url"> + http://fr.secondlife.com/registration/ + </panel.string> + <panel.string name="forgot_password_url"> + http://secondlife.com/account/request.php?lang=fr + </panel.string> + <layout_stack name="login_widgets"> + <layout_panel name="login"> + <text name="username_text"> + Nom d'utilisateur : + </text> + <combo_box name="username_combo" tool_tip="Nom d'utilisateur que vous avez choisi lors de votre inscription (par exemple, bobsmith12 ou Steller Sunshine)."/> + <text name="password_text"> + Mot de passe : + </text> + <check_box label="Enregistrer" name="remember_check"/> + <button label="Connexion" name="connect_btn"/> + <text name="mode_selection_text"> + Mode : + </text> + <combo_box name="mode_combo"> + <combo_box.item label="Basique (par défaut)" name="Basic"/> + <combo_box.item label="Avancé" name="Advanced"/> + </combo_box> + </layout_panel> + <layout_panel name="links"> + <text name="create_new_account_text"> + S'inscrire + </text> + <text name="forgot_password_text"> + Nom d'utilisateur ou mot de passe oublié ? + </text> + <text name="login_help"> + Besoin d'aide ? + </text> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_navigation_bar.xml b/indra/newview/skins/minimal/xui/fr/panel_navigation_bar.xml new file mode 100644 index 0000000000..45caf2323d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_navigation_bar.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="navigation_bar"> + <panel name="navigation_panel"> + <pull_button name="back_btn" tool_tip="Revenir à l'emplacement précédent"/> + <pull_button name="forward_btn" tool_tip="Avancer d'un emplacement"/> + <button name="home_btn" tool_tip="Me téléporter jusqu'à mon domicile"/> + <location_input label="Emplacement" name="location_combo"/> + <search_combo_box label="Rechercher" name="search_combo_box" tool_tip="Rechercher"> + <combo_editor label="Rechercher dans [SECOND_LIFE]" name="search_combo_editor"/> + </search_combo_box> + </panel> + <favorites_bar name="favorite" tool_tip="Faites glisser des repères ici pour un accès rapide à vos lieux favoris dans Second Life."> + <label name="favorites_bar_label" tool_tip="Faites glisser des repères ici pour un accès rapide à vos lieux favoris dans Second Life."> + Favoris + </label> + <chevron_button name=">>" tool_tip="Afficher d'avantage de Favoris"/> + </favorites_bar> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_people.xml b/indra/newview/skins/minimal/xui/fr/panel_people.xml new file mode 100644 index 0000000000..88409a2a86 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_people.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- Side tray panel --> +<panel label="Résidents" name="people_panel"> + <string name="no_recent_people" value="Personne de récent. Vous recherchez des résidents avec qui passer du temps ? Essayez avec le bouton Destinations ci-dessous."/> + <string name="no_filtered_recent_people" value="Personne de récent portant ce nom."/> + <string name="no_one_near" value="Personne près de vous. Vous recherchez des résidents avec qui passer du temps ? Essayez avec le bouton Destinations ci-dessous."/> + <string name="no_one_filtered_near" value="Personne près de vous portant ce nom."/> + <string name="no_friends_online" value="Pas d'amis connectés"/> + <string name="no_friends" value="Pas d'amis"/> + <string name="no_friends_msg"> + Pour ajouter un résident à votre liste d'amis, cliquez-droit dessus. +Vous recherchez des résidents avec qui passer du temps ? Essayez avec le bouton Destinations ci-dessous. + </string> + <string name="no_filtered_friends_msg"> + Vous n'avez pas trouvé ce que vous cherchiez ? Essayez avec le bouton Destinations ci-dessous. + </string> + <string name="people_filter_label" value="Filtrer les personnes"/> + <string name="groups_filter_label" value="Filtrer les groupes"/> + <string name="no_filtered_groups_msg" value="Vous n'avez pas trouvé ce que vous cherchiez ? Essayez [secondlife:///app/search/groups/[SEARCH_TERM] Rechercher]."/> + <string name="no_groups_msg" value="Vous souhaitez trouver des groupes à rejoindre ? Utilisez [secondlife:///app/search/groups Rechercher]."/> + <string name="MiniMapToolTipMsg" value="[REGION](Carte : double-clic ; Panoramique : Maj + faire glisser)"/> + <string name="AltMiniMapToolTipMsg" value="[REGION](Téléportation : double-clic ; Panoramique : Maj + faire glisser)"/> + <filter_editor label="Filtre" name="filter_input"/> + <tab_container name="tabs"> + <panel label="PRÈS DE VOUS" name="nearby_panel"> + <panel label="bottom_panel" name="bottom_panel"/> + </panel> + <panel label="MES AMIS" name="friends_panel"> + <accordion name="friends_accordion"> + <accordion_tab name="tab_online" title="En ligne"/> + <accordion_tab name="tab_all" title="Tout"/> + </accordion> + <panel label="bottom_panel" name="bottom_panel"> + <layout_stack name="bottom_panel"> + <layout_panel name="trash_btn_panel"> + <dnd_button name="del_btn" tool_tip="Supprimer le résident sélectionné de votre liste d'amis."/> + </layout_panel> + </layout_stack> + </panel> + </panel> + <panel label="RÉCENT" name="recent_panel"> + <panel label="bottom_panel" name="bottom_panel"> + <button name="add_friend_btn" tool_tip="Ajouter le résident sélectionné à votre liste d'amis"/> + </panel> + </panel> + </tab_container> + <panel name="button_bar"> + <layout_stack name="bottom_bar_ls"> + <layout_panel name="view_profile_btn_lp"> + <button label="Profil" name="view_profile_btn" tool_tip="Afficher la photo, les groupes et autres infos des résidents"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="IM" name="im_btn" tool_tip="Ouvrir une session IM"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Téléporter" name="teleport_btn" tool_tip="Proposer une téléportation"/> + </layout_panel> + </layout_stack> + <layout_stack name="bottom_bar_ls1"> + <layout_panel name="group_info_btn_lp"> + <button label="Profil du groupe" name="group_info_btn" tool_tip="Afficher les informations sur le groupe"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Chat de groupe" name="chat_btn" tool_tip="Ouvrir une session de chat"/> + </layout_panel> + <layout_panel name="group_call_btn_lp"> + <button label="Appel de groupe" name="group_call_btn" tool_tip="Appeler ce groupe"/> + </layout_panel> + </layout_stack> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_side_tray_tab_caption.xml b/indra/newview/skins/minimal/xui/fr/panel_side_tray_tab_caption.xml new file mode 100644 index 0000000000..45efbdc980 --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_side_tray_tab_caption.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="sidetray_tab_panel"> + <text name="sidetray_tab_title" value="Panneau latéral"/> + <button name="undock" tool_tip="Détacher"/> + <button name="dock" tool_tip="Attacher"/> + <button name="show_help" tool_tip="Afficher l'aide"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/fr/panel_status_bar.xml b/indra/newview/skins/minimal/xui/fr/panel_status_bar.xml new file mode 100644 index 0000000000..69aec99e1d --- /dev/null +++ b/indra/newview/skins/minimal/xui/fr/panel_status_bar.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="status"> + <panel.string name="StatBarDaysOfWeek"> + Sunday:Monday:Tuesday:Wednesday:Thursday:Friday:Saturday + </panel.string> + <panel.string name="StatBarMonthsOfYear"> + January:February:March:April:May:June:July:August:September:October:November:December + </panel.string> + <panel.string name="packet_loss_tooltip"> + Perte de paquets + </panel.string> + <panel.string name="bandwidth_tooltip"> + Bande passante + </panel.string> + <panel.string name="time"> + [hour12, datetime, slt]:[min, datetime, slt] [ampm, datetime, slt] [timezone,datetime, slt] + </panel.string> + <panel.string name="timeTooltip"> + [weekday, datetime, slt] [sday, datetime, slt] [month, datetime, slt] [year, datetime, slt] + </panel.string> + <panel.string name="buycurrencylabel"> + [AMT] L$ + </panel.string> + <panel name="balance_bg"> + <text name="balance" tool_tip="Cliquer sur ce bouton pour actualiser votre solde en L$." value="20 L$"/> + <button label="ACHETER L$" name="buyL" tool_tip="Cliquer pour acheter plus de L$"/> + </panel> + <text name="TimeText" tool_tip="Heure actuelle (Pacifique)"> + 00h00 PST + </text> + <button name="media_toggle_btn" tool_tip="Arrêter tous les médias (musique, vidéo, pages web)"/> + <button name="volume_btn" tool_tip="Contrôle du volume global"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/floater_camera.xml b/indra/newview/skins/minimal/xui/pt/floater_camera.xml new file mode 100644 index 0000000000..4f3729c623 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/floater_camera.xml @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="camera_floater" title=""> + <floater.string name="rotate_tooltip"> + Girar a Câmera ao redor do Foco + </floater.string> + <floater.string name="zoom_tooltip"> + Aproximar a Câmera in direção ao Foco + </floater.string> + <floater.string name="move_tooltip"> + Mover a Câmera para Cima e para Baixo, para a Esquerda e para a Direita + </floater.string> + <floater.string name="camera_modes_title"> + Modos de câmera + </floater.string> + <floater.string name="pan_mode_title"> + Pan zoom orbital + </floater.string> + <floater.string name="presets_mode_title"> + Ângulos predefinidos + </floater.string> + <floater.string name="free_mode_title"> + Visualizar objeto + </floater.string> + <panel name="controls"> + <panel name="preset_views_list"> + <panel_camera_item name="front_view"> + <panel_camera_item.text name="front_view_text"> + Vista frontal + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="group_view"> + <panel_camera_item.text name="side_view_text"> + Vista lateral + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="rear_view"> + <panel_camera_item.text name="rear_view_text"> + Vista de trás + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="camera_modes_list"> + <panel_camera_item name="object_view"> + <panel_camera_item.text name="object_view_text"> + Vista de objetos + </panel_camera_item.text> + </panel_camera_item> + <panel_camera_item name="mouselook_view"> + <panel_camera_item.text name="mouselook_view_text"> + Vista do mouse + </panel_camera_item.text> + </panel_camera_item> + </panel> + <panel name="zoom" tool_tip="Aproximar a Câmera in direção ao Foco"> + <joystick_rotate name="cam_rotate_stick" tool_tip="Girar câmera ao redor do foco"/> + <slider_bar name="zoom_slider" tool_tip="Zoom de câmera para focalizar"/> + <joystick_track name="cam_track_stick" tool_tip="Move a câmera para cima e para baixo, direita e esquerda"/> + </panel> + </panel> + <panel name="buttons"> + <button label="" name="presets_btn" tool_tip="Ângulos predefinidos"/> + <button label="" name="pan_btn" tool_tip="Pan zoom orbital"/> + <button label="" name="avatarview_btn" tool_tip="Modos de câmera"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/pt/floater_help_browser.xml b/indra/newview/skins/minimal/xui/pt/floater_help_browser.xml new file mode 100644 index 0000000000..11428ff651 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/floater_help_browser.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="floater_help_browser" title="COMO"> + <floater.string name="loading_text"> + Carregando... + </floater.string> + <layout_stack name="stack1"> + <layout_panel name="external_controls"/> + </layout_stack> +</floater> diff --git a/indra/newview/skins/minimal/xui/pt/floater_nearby_chat.xml b/indra/newview/skins/minimal/xui/pt/floater_nearby_chat.xml new file mode 100644 index 0000000000..60edfa505f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/floater_nearby_chat.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<floater name="nearby_chat" title="Bate-papo local"> + <check_box label="Traduzir bate-papo (via Google)" name="translate_chat_checkbox"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/pt/inspect_avatar.xml b/indra/newview/skins/minimal/xui/pt/inspect_avatar.xml new file mode 100644 index 0000000000..a199c58c15 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/inspect_avatar.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_avatar"> + <string name="Subtitle"> + [IDADE] + </string> + <string name="Details"> + [PERFIL_SL] + </string> + <text name="user_details"> + This is my second life description and I really think it is great. But for some reason my description is super extra long because I like to talk a whole lot + </text> + <slider name="volume_slider" tool_tip="Volume de Voz" value="0.5"/> + <button label="Adicionar amigo" name="add_friend_btn"/> + <button label="MI" name="im_btn"/> + <button label="Perfil" name="view_profile_btn"/> + <panel name="moderator_panel"> + <button label="Disabilitar Voz" name="disable_voice"/> + <button label="Habilitar Voz" name="enable_voice"/> + </panel> +</floater> diff --git a/indra/newview/skins/minimal/xui/pt/inspect_object.xml b/indra/newview/skins/minimal/xui/pt/inspect_object.xml new file mode 100644 index 0000000000..b72de7038d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/inspect_object.xml @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- + Not can_close / no title to avoid window chrome + Single instance - only have one at a time, recycle it each spawn +--> +<floater name="inspect_object"> + <string name="Creator"> + Autor: [CREATOR] + </string> + <string name="CreatorAndOwner"> + Autor [CREATOR] +Proprietário [OWNER] + </string> + <string name="Price"> + L$[AMOUNT] + </string> + <string name="PriceFree"> + Grátis! + </string> + <string name="Touch"> + Tocar + </string> + <string name="Sit"> + Sentar + </string> + <text name="object_name" value="Test Object Name That Is actually two lines and Really Long"/> + <text name="price_text"> + L$30.000 + </text> + <text name="object_description"> + This is a really long description for an object being as how it is at least 80 characters in length and so but maybe more like 120 at this point. Who knows, really? + </text> + <button label="Comprar" name="buy_btn"/> + <button label="Pagar" name="pay_btn"/> + <button label="Pegar uma cópia" name="take_free_copy_btn"/> + <button label="Tocar" name="touch_btn"/> + <button label="Sentar" name="sit_btn"/> + <button label="Abrir" name="open_btn"/> + <icon name="secure_browsing" tool_tip="Navegação segura"/> + <button label="Mais" name="more_info_btn"/> +</floater> diff --git a/indra/newview/skins/minimal/xui/pt/menu_add_wearable_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_add_wearable_gear.xml new file mode 100644 index 0000000000..4b81276ab3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_add_wearable_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Add Wearable Gear Menu"> + <menu_item_check label="Ordenar por mais recente" name="sort_by_most_recent"/> + <menu_item_check label="Ordenar por nome" name="sort_by_name"/> + <menu_item_check label="Ordenar por tipo" name="sort_by_type"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_attachment_other.xml b/indra/newview/skins/minimal/xui/pt/menu_attachment_other.xml new file mode 100644 index 0000000000..cfd69158bc --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_attachment_other.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_avatar_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Ver perfil" name="Profile..."/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="MI" name="Send IM..."/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Convidar para entrar no grupo" name="Invite..."/> + <menu_item_call label="Bloquear" name="Avatar Mute"/> + <menu_item_call label="Denunciar" name="abuse"/> + <menu_item_call label="Congelar" name="Freeze..."/> + <menu_item_call label="Ejetar" name="Eject..."/> + <menu_item_call label="Depurar texturas" name="Debug..."/> + <menu_item_call label="Mais zoom" name="Zoom In"/> + <menu_item_call label="Pagar" name="Pay..."/> + <menu_item_call label="Perfil do objeto" name="Object Inspect"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_attachment_self.xml b/indra/newview/skins/minimal/xui/pt/menu_attachment_self.xml new file mode 100644 index 0000000000..09060cf3ae --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_attachment_self.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Attachment Pie"> + <menu_item_call label="Tocar" name="Attachment Object Touch"/> + <menu_item_call label="Editar" name="Edit..."/> + <menu_item_call label="Tirar" name="Detach"/> + <menu_item_call label="Sentar" name="Sit Down Here"/> + <menu_item_call label="Ficar de pé" name="Stand Up"/> + <menu_item_call label="Trocar de look" name="Change Outfit"/> + <menu_item_call label="Editar meu look" name="Edit Outfit"/> + <menu_item_call label="Editar meu corpo" name="Edit My Shape"/> + <menu_item_call label="Meus amigos" name="Friends..."/> + <menu_item_call label="Meus grupos" name="Groups..."/> + <menu_item_call label="Meu perfil" name="Profile..."/> + <menu_item_call label="Depurar texturas" name="Debug..."/> + <menu_item_call label="Largar" name="Drop"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_avatar_icon.xml b/indra/newview/skins/minimal/xui/pt/menu_avatar_icon.xml new file mode 100644 index 0000000000..beba969b7e --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_avatar_icon.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Avatar Icon Menu"> + <menu_item_call label="Ver perfil" name="Show Profile"/> + <menu_item_call label="Enviar MI..." name="Send IM"/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="Remover amigo..." name="Remove Friend"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_avatar_other.xml b/indra/newview/skins/minimal/xui/pt/menu_avatar_other.xml new file mode 100644 index 0000000000..a4a26144c7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_avatar_other.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- *NOTE: See also menu_attachment_other.xml --> +<context_menu name="Avatar Pie"> + <menu_item_call label="Ver perfil" name="Profile..."/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="MI" name="Send IM..."/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Convidar para entrar no grupo" name="Invite..."/> + <menu_item_call label="Bloquear" name="Avatar Mute"/> + <menu_item_call label="Denunciar" name="abuse"/> + <menu_item_call label="Congelar" name="Freeze..."/> + <menu_item_call label="Ejetar" name="Eject..."/> + <menu_item_call label="Depurar texturas" name="Debug..."/> + <menu_item_call label="Mais zoom" name="Zoom In"/> + <menu_item_call label="Pagar" name="Pay..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_avatar_self.xml b/indra/newview/skins/minimal/xui/pt/menu_avatar_self.xml new file mode 100644 index 0000000000..6e203d5a25 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_avatar_self.xml @@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Self Pie"> + <menu_item_call label="Sentar" name="Sit Down Here"/> + <menu_item_call label="Ficar de pé" name="Stand Up"/> + <context_menu label="Tirar" name="Take Off >"> + <context_menu label="Roupa" name="Clothes >"> + <menu_item_call label="Camisa" name="Shirt"/> + <menu_item_call label="Calças" name="Pants"/> + <menu_item_call label="Saia" name="Skirt"/> + <menu_item_call label="Sapatos" name="Shoes"/> + <menu_item_call label="Meias" name="Socks"/> + <menu_item_call label="Jaqueta" name="Jacket"/> + <menu_item_call label="Luvas" name="Gloves"/> + <menu_item_call label="Camiseta" name="Self Undershirt"/> + <menu_item_call label="Roupa de baixo" name="Self Underpants"/> + <menu_item_call label="Tatuagem" name="Self Tattoo"/> + <menu_item_call label="Alpha" name="Self Alpha"/> + <menu_item_call label="Todas as roupas" name="All Clothes"/> + </context_menu> + <context_menu label="HUD" name="Object Detach HUD"/> + <context_menu label="Tirar" name="Object Detach"/> + <menu_item_call label="Tirar tudo" name="Detach All"/> + </context_menu> + <menu_item_call label="Trocar de look" name="Chenge Outfit"/> + <menu_item_call label="Editar meu look" name="Edit Outfit"/> + <menu_item_call label="Editar meu corpo" name="Edit My Shape"/> + <menu_item_call label="Meus amigos" name="Friends..."/> + <menu_item_call label="Meus grupos" name="Groups..."/> + <menu_item_call label="Meu perfil" name="Profile..."/> + <menu_item_call label="Depurar texturas" name="Debug..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_bottomtray.xml b/indra/newview/skins/minimal/xui/pt/menu_bottomtray.xml new file mode 100644 index 0000000000..479d02512f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_bottomtray.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_camera_move_controls_menu"> + <menu_item_check label="Botão de gestos" name="ShowGestureButton"/> + <menu_item_check label="Botão de movimento" name="ShowMoveButton"/> + <menu_item_check label="Botão de ver" name="ShowCameraButton"/> + <menu_item_check label="Botão de fotos" name="ShowSnapshotButton"/> + <menu_item_check label="Botão da Barra lateral" name="ShowSidebarButton"/> + <menu_item_check label="Botão Construir" name="ShowBuildButton"/> + <menu_item_check label="Botão Buscar" name="ShowSearchButton"/> + <menu_item_check label="Botão Mapa" name="ShowWorldMapButton"/> + <menu_item_check label="Botão do Mini Mapa" name="ShowMiniMapButton"/> + <menu_item_call label="Cortar" name="NearbyChatBar_Cut"/> + <menu_item_call label="Copiar" name="NearbyChatBar_Copy"/> + <menu_item_call label="Colar" name="NearbyChatBar_Paste"/> + <menu_item_call label="Excluir" name="NearbyChatBar_Delete"/> + <menu_item_call label="Selecionar tudo" name="NearbyChatBar_Select_All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_cof_attachment.xml b/indra/newview/skins/minimal/xui/pt/menu_cof_attachment.xml new file mode 100644 index 0000000000..527e3af3c9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_cof_attachment.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Attachment"> + <menu_item_call label="Separar" name="detach"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_cof_body_part.xml b/indra/newview/skins/minimal/xui/pt/menu_cof_body_part.xml new file mode 100644 index 0000000000..704fd226eb --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_cof_body_part.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Body"> + <menu_item_call label="Trocar" name="replace"/> + <menu_item_call label="Editar" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_cof_clothing.xml b/indra/newview/skins/minimal/xui/pt/menu_cof_clothing.xml new file mode 100644 index 0000000000..051323ae6a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_cof_clothing.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="COF Clothing"> + <menu_item_call label="Tirar" name="take_off"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Trocar" name="replace"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_cof_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_cof_gear.xml new file mode 100644 index 0000000000..8716992a5e --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_cof_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear COF"> + <menu label="Roupas novas" name="COF.Gear.New_Clothes"/> + <menu label="Nova parte do corpo" name="COF.Geear.New_Body_Parts"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_edit.xml b/indra/newview/skins/minimal/xui/pt/menu_edit.xml new file mode 100644 index 0000000000..ff431c9a21 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_edit.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu label="Editar" name="Edit"> + <menu_item_call label="Desfazer" name="Undo"/> + <menu_item_call label="Repetir" name="Redo"/> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Colar" name="Paste"/> + <menu_item_call label="Excluir" name="Delete"/> + <menu_item_call label="Replicar" name="Duplicate"/> + <menu_item_call label="Selecionar tudo" name="Select All"/> + <menu_item_call label="Desfazer seleção" name="Deselect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_favorites.xml b/indra/newview/skins/minimal/xui/pt/menu_favorites.xml new file mode 100644 index 0000000000..062820fbca --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_favorites.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Teletransportar" name="Teleport To Landmark"/> + <menu_item_call label="Ver/Editar marco" name="Landmark Open"/> + <menu_item_call label="Copiar SLurl" name="Copy slurl"/> + <menu_item_call label="Mostrar no mapa" name="Show On Map"/> + <menu_item_call label="Copiar" name="Landmark Copy"/> + <menu_item_call label="Colar" name="Landmark Paste"/> + <menu_item_call label="Excluir" name="Delete"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_gesture_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_gesture_gear.xml new file mode 100644 index 0000000000..70d8ae7a8e --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_gesture_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_gesture_gear"> + <menu_item_call label="Adicionar/remover de favoritos" name="activate"/> + <menu_item_call label="Copiar" name="copy_gesture"/> + <menu_item_call label="Colar" name="paste"/> + <menu_item_call label="Copiar UUID" name="copy_uuid"/> + <menu_item_call label="Salvar para look atual" name="save_to_outfit"/> + <menu_item_call label="Editar" name="edit_gesture"/> + <menu_item_call label="Verificar" name="inspect"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_group_plus.xml b/indra/newview/skins/minimal/xui/pt/menu_group_plus.xml new file mode 100644 index 0000000000..1083845d68 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_group_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Entrar no grupo..." name="item_join"/> + <menu_item_call label="Novo grupo..." name="item_new"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_hide_navbar.xml b/indra/newview/skins/minimal/xui/pt/menu_hide_navbar.xml new file mode 100644 index 0000000000..c2b063193e --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_hide_navbar.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="hide_navbar_menu"> + <menu_item_check label="Mostrar barra de navegação" name="ShowNavbarNavigationPanel"/> + <menu_item_check label="Mostrar barra de favoritos" name="ShowNavbarFavoritesPanel"/> + <menu_item_check label="Mostrar minibarra de localização" name="ShowMiniLocationPanel"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_im_well_button.xml b/indra/newview/skins/minimal/xui/pt/menu_im_well_button.xml new file mode 100644 index 0000000000..2d37cefd6f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_im_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="IM Well Button Context Menu"> + <menu_item_call label="Fechar tudo" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_imchiclet_adhoc.xml b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_adhoc.xml new file mode 100644 index 0000000000..ead949ba13 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_adhoc.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet AdHoc Menu"> + <menu_item_call label="Encerrar esta sessão" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_imchiclet_group.xml b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_group.xml new file mode 100644 index 0000000000..dd177d1b8d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet Group Menu"> + <menu_item_call label="Sobre o grupo" name="Show Profile"/> + <menu_item_call label="Mostrar sessão" name="Chat"/> + <menu_item_call label="Encerrar esta sessão" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_imchiclet_p2p.xml b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_p2p.xml new file mode 100644 index 0000000000..d821b3ded0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_imchiclet_p2p.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="IMChiclet P2P Menu"> + <menu_item_call label="Ver perfil" name="Show Profile"/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="Mostrar sessão" name="Send IM"/> + <menu_item_call label="Encerrar esta sessão" name="End Session"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inspect_avatar_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_inspect_avatar_gear.xml new file mode 100644 index 0000000000..f7fe5640ef --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inspect_avatar_gear.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8"?> +<toggleable_menu name="Gear Menu"> + <menu_item_call label="Ver perfil" name="view_profile"/> + <menu_item_call label="Adicionar amigo..." name="add_friend"/> + <menu_item_call label="MI" name="im"/> + <menu_item_call label="Teletransportar" name="teleport"/> + <menu_item_call label="Bloquear" name="block"/> + <menu_item_call label="Desbloquear" name="unblock"/> + <menu_item_call label="Denunciar" name="report"/> + <menu_item_call label="Congelar" name="freeze"/> + <menu_item_call label="Ejetar" name="eject"/> + <menu_item_call label="Chutar" name="kick"/> + <menu_item_call label="CSR" name="csr"/> + <menu_item_call label="Depurar texturas" name="debug"/> + <menu_item_call label="Localizar no mapa" name="find_on_map"/> + <menu_item_call label="Mais zoom" name="zoom_in"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inspect_object_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_inspect_object_gear.xml new file mode 100644 index 0000000000..184db26538 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inspect_object_gear.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Tocar" name="touch"/> + <menu_item_call label="Sentar" name="sit"/> + <menu_item_call label="Pagar" name="pay"/> + <menu_item_call label="Comprar" name="buy"/> + <menu_item_call label="Pegar" name="take"/> + <menu_item_call label="Pegar uma cópia" name="take_copy"/> + <menu_item_call label="Abrir" name="open"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Vestir" name="wear"/> + <menu_item_call label="Adicionar" name="add"/> + <menu_item_call label="Denunciar" name="report"/> + <menu_item_call label="Bloquear" name="block"/> + <menu_item_call label="Mais zoom" name="zoom_in"/> + <menu_item_call label="Tirar" name="remove"/> + <menu_item_call label="Mais informações" name="more_info"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inspect_self_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_inspect_self_gear.xml new file mode 100644 index 0000000000..7e67f4cfd4 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inspect_self_gear.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<menu name="Gear Menu"> + <menu_item_call label="Sentar" name="sit_down_here"/> + <menu_item_call label="Ficar de pé" name="stand_up"/> + <menu_item_call label="Trocar de look" name="change_outfit"/> + <menu_item_call label="Meu perfil" name="my_profile"/> + <menu_item_call label="Meus amigos" name="my_friends"/> + <menu_item_call label="Meus grupos" name="my_groups"/> + <menu_item_call label="Depurar texturas" name="Debug..."/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inv_offer_chiclet.xml b/indra/newview/skins/minimal/xui/pt/menu_inv_offer_chiclet.xml new file mode 100644 index 0000000000..c404719c95 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inv_offer_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="InvOfferChiclet Menu"> + <menu_item_call label="Fechar" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inventory.xml b/indra/newview/skins/minimal/xui/pt/menu_inventory.xml new file mode 100644 index 0000000000..1b1efd3270 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inventory.xml @@ -0,0 +1,86 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Compartilhar" name="Share"/> + <menu_item_call label="Comprar" name="Task Buy"/> + <menu_item_call label="Abrir" name="Task Open"/> + <menu_item_call label="Executar" name="Task Play"/> + <menu_item_call label="Propriedades" name="Task Properties"/> + <menu_item_call label="Renomear" name="Task Rename"/> + <menu_item_call label="Apagar" name="Task Remove"/> + <menu_item_call label="Limpar lixeira" name="Empty Trash"/> + <menu_item_call label="Limpar Achados & perdidos" name="Empty Lost And Found"/> + <menu_item_call label="Nova pasta" name="New Folder"/> + <menu_item_call label="Novo script" name="New Script"/> + <menu_item_call label="Nova anotação" name="New Note"/> + <menu_item_call label="Novo gesto" name="New Gesture"/> + <menu label="Novas roupas" name="New Clothes"> + <menu_item_call label="Nova camisa" name="New Shirt"/> + <menu_item_call label="Nova calça" name="New Pants"/> + <menu_item_call label="Novos sapatos" name="New Shoes"/> + <menu_item_call label="Novas meias" name="New Socks"/> + <menu_item_call label="Nova jaqueta" name="New Jacket"/> + <menu_item_call label="Nova saia" name="New Skirt"/> + <menu_item_call label="Novas luvas" name="New Gloves"/> + <menu_item_call label="Nova anágua" name="New Undershirt"/> + <menu_item_call label="Nova roupa de baixo" name="New Underpants"/> + <menu_item_call label="Nova máscara alfa" name="New Alpha Mask"/> + <menu_item_call label="Nova tatuagem" name="New Tattoo"/> + </menu> + <menu label="Nova parte do corpo" name="New Body Parts"> + <menu_item_call label="Nova forma" name="New Shape"/> + <menu_item_call label="Nova pele" name="New Skin"/> + <menu_item_call label="Novo cabelo" name="New Hair"/> + <menu_item_call label="Novos olhos" name="New Eyes"/> + </menu> + <menu label="Alterar fonte" name="Change Type"> + <menu_item_call label="Padrão" name="Default"/> + <menu_item_call label="Luvas" name="Gloves"/> + <menu_item_call label="Jaqueta" name="Jacket"/> + <menu_item_call label="Calças" name="Pants"/> + <menu_item_call label="Silhueta" name="Shape"/> + <menu_item_call label="Sapatos" name="Shoes"/> + <menu_item_call label="Camisa" name="Shirt"/> + <menu_item_call label="Saia" name="Skirt"/> + <menu_item_call label="Roupa de baixo" name="Underpants"/> + <menu_item_call label="Camiseta" name="Undershirt"/> + </menu> + <menu_item_call label="Teletransporte" name="Landmark Open"/> + <menu_item_call label="Abrir" name="Animation Open"/> + <menu_item_call label="Abrir" name="Sound Open"/> + <menu_item_call label="Substituir look" name="Replace Outfit"/> + <menu_item_call label="Adicionar a look" name="Add To Outfit"/> + <menu_item_call label="Tirar do look atual" name="Remove From Outfit"/> + <menu_item_call label="Encontrar original" name="Find Original"/> + <menu_item_call label="Remover item" name="Purge Item"/> + <menu_item_call label="Restaurar item" name="Restore Item"/> + <menu_item_call label="Abrir" name="Open"/> + <menu_item_call label="Abrir original" name="Open Original"/> + <menu_item_call label="Propriedades" name="Properties"/> + <menu_item_call label="Renomear" name="Rename"/> + <menu_item_call label="Copiar item UUID" name="Copy Asset UUID"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Colar" name="Paste"/> + <menu_item_call label="Colar como link" name="Paste As Link"/> + <menu_item_call label="Excluir" name="Remove Link"/> + <menu_item_call label="Apagar" name="Delete"/> + <menu_item_call label="Excluir pasta do sistema" name="Delete System Folder"/> + <menu_item_call label="Pasta conversa em conferência" name="Conference Chat Folder"/> + <menu_item_call label="Executar som" name="Sound Play"/> + <menu_item_call label="Sobre o marco" name="About Landmark"/> + <menu_item_call label="Executar animação" name="Animation Play"/> + <menu_item_call label="Executar áudio" name="Animation Audition"/> + <menu_item_call label="Mandar MI" name="Send Instant Message"/> + <menu_item_call label="Oferecer teletransporte..." name="Offer Teleport..."/> + <menu_item_call label="Bate-papo em conferência" name="Conference Chat"/> + <menu_item_call label="Ativar" name="Activate"/> + <menu_item_call label="Desativar" name="Deactivate"/> + <menu_item_call label="Salvar como" name="Save As"/> + <menu_item_call label="Tirar de si mesmo" name="Detach From Yourself"/> + <menu_item_call label="Vestir" name="Wearable And Object Wear"/> + <menu label="Anexar a" name="Attach To"/> + <menu label="Anexar ao HUD" name="Attach To HUD"/> + <menu_item_call label="Editar" name="Wearable Edit"/> + <menu_item_call label="Adicionar" name="Wearable Add"/> + <menu_item_call label="Tirar" name="Take Off"/> + <menu_item_call label="--Sem opções--" name="--no options--"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inventory_add.xml b/indra/newview/skins/minimal/xui/pt/menu_inventory_add.xml new file mode 100644 index 0000000000..2723f39287 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inventory_add.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_inventory_add"> + <menu label="Upload" name="upload"> + <menu_item_call label="Imagem (L$[COST])..." name="Upload Image"/> + <menu_item_call label="Som (L$[COST])..." name="Upload Sound"/> + <menu_item_call label="Animação (L$[COST])..." name="Upload Animation"/> + <menu_item_call label="Volume (L$[COST] per file)..." name="Bulk Upload"/> + <menu_item_call label="Autorizações de upload padrão" name="perm prefs"/> + </menu> + <menu_item_call label="Nova pasta" name="New Folder"/> + <menu_item_call label="Novo script" name="New Script"/> + <menu_item_call label="Nova anotação" name="New Note"/> + <menu_item_call label="Novo gesto" name="New Gesture"/> + <menu label="Novas roupas" name="New Clothes"> + <menu_item_call label="Nova camisa" name="New Shirt"/> + <menu_item_call label="Novas calças" name="New Pants"/> + <menu_item_call label="Novos sapatos" name="New Shoes"/> + <menu_item_call label="Novas meias" name="New Socks"/> + <menu_item_call label="Nova blusa" name="New Jacket"/> + <menu_item_call label="Nova saia" name="New Skirt"/> + <menu_item_call label="Novas luvas" name="New Gloves"/> + <menu_item_call label="Nova camiseta" name="New Undershirt"/> + <menu_item_call label="Novas roupa de baixo" name="New Underpants"/> + <menu_item_call label="Novo alpha" name="New Alpha"/> + <menu_item_call label="Nova tatuagem" name="New Tattoo"/> + </menu> + <menu label="Nova parte do corpo" name="New Body Parts"> + <menu_item_call label="Nova forma" name="New Shape"/> + <menu_item_call label="Nova pele" name="New Skin"/> + <menu_item_call label="Novo cabelo" name="New Hair"/> + <menu_item_call label="Novos olhos" name="New Eyes"/> + </menu> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_inventory_gear_default.xml b/indra/newview/skins/minimal/xui/pt/menu_inventory_gear_default.xml new file mode 100644 index 0000000000..3400578d9a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_inventory_gear_default.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="menu_gear_default"> + <menu_item_call label="Nova janela de inventário" name="new_window"/> + <menu_item_check label="Ordenar por nome" name="sort_by_name"/> + <menu_item_check label="Ordenar por mais recente" name="sort_by_recent"/> + <menu_item_check label="Pastas do sistema no topo" name="sort_system_folders_to_top"/> + <menu_item_call label="Mostrar filtros" name="show_filters"/> + <menu_item_call label="Restabelecer filtros" name="reset_filters"/> + <menu_item_call label="Fechar todas as pastas" name="close_folders"/> + <menu_item_call label="Esvaziar achados e perdidos" name="empty_lostnfound"/> + <menu_item_call label="Salvar textura como" name="Save Texture As"/> + <menu_item_call label="Compartilhar" name="Share"/> + <menu_item_call label="Encontrar original" name="Find Original"/> + <menu_item_call label="Encontrar todos os links" name="Find All Links"/> + <menu_item_call label="Esvaziar lixeira" name="empty_trash"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_land.xml b/indra/newview/skins/minimal/xui/pt/menu_land.xml new file mode 100644 index 0000000000..9182ce321a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_land.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Land Pie"> + <menu_item_call label="Sobre terrenos" name="Place Information..."/> + <menu_item_call label="Sentar aqui" name="Sit Here"/> + <menu_item_call label="Comprar este terreno" name="Land Buy"/> + <menu_item_call label="Comprar passe" name="Land Buy Pass"/> + <menu_item_call label="Construir" name="Create"/> + <menu_item_call label="Editar a topografia" name="Edit Terrain"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_landmark.xml b/indra/newview/skins/minimal/xui/pt/menu_landmark.xml new file mode 100644 index 0000000000..6accfebee7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_landmark.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="landmark_overflow_menu"> + <menu_item_call label="Copiar SLurl" name="copy"/> + <menu_item_call label="Excluir" name="delete"/> + <menu_item_call label="Criar destaque" name="pick"/> + <menu_item_call label="Adicionar à barra de favoritos" name="add_to_favbar"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_login.xml b/indra/newview/skins/minimal/xui/pt/menu_login.xml new file mode 100644 index 0000000000..3dff3d7c8a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_login.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Login Menu"> + <menu label="Eu" name="File"> + <menu_item_call label="Preferências" name="Preferences..."/> + <menu_item_call label="Sair do [APP_NAME]" name="Quit"/> + </menu> + <menu label="Ajuda" name="Help"> + <menu_item_call label="Ajuda do [SECOND_LIFE]" name="Second Life Help"/> + <menu_item_call label="Sobre [APP_NAME]" name="About Second Life"/> + </menu> + <menu_item_check label="Exibir menu de depuração" name="Show Debug Menu"/> + <menu label="Depurar" name="Debug"> + <menu_item_call label="Mostrar configurações" name="Debug Settings"/> + <menu_item_call label="Configurações da interface e cor" name="UI/Color Settings"/> + <menu label="Testes de UI" name="UI Tests"/> + <menu_item_call label="Definir tamanho da janela:" name="Set Window Size..."/> + <menu_item_call label="Mostrar TOS" name="TOS"/> + <menu_item_call label="Mostrar mensagem crítica" name="Critical"/> + <menu_item_call label="Teste de mídia do navegador" name="Web Browser Test"/> + <menu_item_call label="Teste de conteúdo web" name="Web Content Floater Test"/> + <menu_item_check label="Exibir seletor da grade" name="Show Grid Picker"/> + <menu_item_call label="Exibir painel de notificações" name="Show Notifications Console"/> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/pt/menu_mini_map.xml b/indra/newview/skins/minimal/xui/pt/menu_mini_map.xml new file mode 100644 index 0000000000..6a3fe55de5 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_mini_map.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Zoom Perto" name="Zoom Close"/> + <menu_item_call label="Zoom Médio" name="Zoom Medium"/> + <menu_item_call label="Zoom Longe" name="Zoom Far"/> + <menu_item_call label="Zoom padrão" name="Zoom Default"/> + <menu_item_check label="Girar mapa" name="Rotate Map"/> + <menu_item_check label="Auto Center" name="Auto Center"/> + <menu_item_call label="Parar Acompanhamento" name="Stop Tracking"/> + <menu_item_call label="Mapa-múndi" name="World Map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_navbar.xml b/indra/newview/skins/minimal/xui/pt/menu_navbar.xml new file mode 100644 index 0000000000..57c1471de3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_navbar.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Navbar Menu"> + <menu_item_check label="Mostrar coordenadas" name="Show Coordinates"/> + <menu_item_check label="Mostrar as propriedades do terreno" name="Show Parcel Properties"/> + <menu_item_call label="Marco" name="Landmark"/> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Colar" name="Paste"/> + <menu_item_call label="Excluir" name="Delete"/> + <menu_item_call label="Selecionar tudo" name="Select All"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_nearby_chat.xml b/indra/newview/skins/minimal/xui/pt/menu_nearby_chat.xml new file mode 100644 index 0000000000..f1ea83c837 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_nearby_chat.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="NearBy Chat Menu"> + <menu_item_call label="Mostrar quem está aqui..." name="nearby_people"/> + <menu_item_check label="Mostrar texto bloqueado" name="muted_text"/> + <menu_item_check label="Mostrar ícones de amigos" name="show_buddy_icons"/> + <menu_item_check label="Mostrar nomes" name="show_names"/> + <menu_item_check label="Mostrar ícones e nomes" name="show_icons_and_names"/> + <menu_item_call label="Tamanho da fonte" name="font_size"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_notification_well_button.xml b/indra/newview/skins/minimal/xui/pt/menu_notification_well_button.xml new file mode 100644 index 0000000000..43ad4134ec --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_notification_well_button.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Notification Well Button Context Menu"> + <menu_item_call label="Fechar tudo" name="Close All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_object.xml b/indra/newview/skins/minimal/xui/pt/menu_object.xml new file mode 100644 index 0000000000..bf94859699 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_object.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Object Pie"> + <menu_item_call label="Tocar" name="Object Touch"> + <menu_item_call.on_enable name="EnableTouch" parameter="Tocar"/> + </menu_item_call> + <menu_item_call label="Editar" name="Edit..."/> + <menu_item_call label="Construir" name="Build"/> + <menu_item_call label="Abrir" name="Open"/> + <menu_item_call label="Sentar aqui" name="Object Sit"/> + <menu_item_call label="Ficar de pé" name="Object Stand Up"/> + <menu_item_call label="Perfil do objeto" name="Object Inspect"/> + <menu_item_call label="Mais zoom" name="Zoom In"/> + <context_menu label="Colocar no(a)" name="Put On"> + <menu_item_call label="Vestir" name="Wear"/> + <menu_item_call label="Adicionar" name="Add"/> + <context_menu label="Anexar" name="Object Attach"/> + <context_menu label="Anexar o HUD" name="Object Attach HUD"/> + </context_menu> + <context_menu label="Tirar" name="Remove"> + <menu_item_call label="Denunciar abuso" name="Report Abuse..."/> + <menu_item_call label="Bloquear" name="Object Mute"/> + <menu_item_call label="Devolver" name="Return..."/> + <menu_item_call label="Excluir" name="Delete"/> + </context_menu> + <menu_item_call label="Pegar" name="Pie Object Take"/> + <menu_item_call label="Pegar uma cópia" name="Take Copy"/> + <menu_item_call label="Pagar" name="Pay..."/> + <menu_item_call label="Comprar" name="Buy..."/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_object_icon.xml b/indra/newview/skins/minimal/xui/pt/menu_object_icon.xml new file mode 100644 index 0000000000..7af760a6ee --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_object_icon.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Object Icon Menu"> + <menu_item_call label="Perfil do objeto..." name="Object Profile"/> + <menu_item_call label="Bloquear..." name="Block"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_outfit_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_outfit_gear.xml new file mode 100644 index 0000000000..11b3e653c6 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_outfit_gear.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Outfit"> + <menu_item_call label="Vestir - Substituir look atual" name="wear"/> + <menu_item_call label="Vestir - Adicionar ao look atual" name="wear_add"/> + <menu_item_call label="Tirar - Tirar do look atual" name="take_off"/> + <menu label="Roupas novas" name="New Clothes"> + <menu_item_call label="Nova camisa" name="New Shirt"/> + <menu_item_call label="Novas calças" name="New Pants"/> + <menu_item_call label="Novos sapatos" name="New Shoes"/> + <menu_item_call label="Novas meias" name="New Socks"/> + <menu_item_call label="Nova blusa" name="New Jacket"/> + <menu_item_call label="Nova saia" name="New Skirt"/> + <menu_item_call label="Novas luvas" name="New Gloves"/> + <menu_item_call label="Nova camiseta" name="New Undershirt"/> + <menu_item_call label="Novas roupa de baixo" name="New Underpants"/> + <menu_item_call label="Novo alpha" name="New Alpha"/> + <menu_item_call label="Nova tatuagem" name="New Tattoo"/> + </menu> + <menu label="Nova parte do corpo" name="New Body Parts"> + <menu_item_call label="Nova silhueta" name="New Shape"/> + <menu_item_call label="Nova pele" name="New Skin"/> + <menu_item_call label="Novo cabelo" name="New Hair"/> + <menu_item_call label="Novos olhos" name="New Eyes"/> + </menu> + <menu_item_call label="Renomear look" name="rename"/> + <menu_item_call label="Excluir visual" name="delete_outfit"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_outfit_tab.xml b/indra/newview/skins/minimal/xui/pt/menu_outfit_tab.xml new file mode 100644 index 0000000000..8db5e405b3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_outfit_tab.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit"> + <menu_item_call label="Vestir - Substituir look atual" name="wear_replace"/> + <menu_item_call label="Vestir - Sem tirar look atual" name="wear_add"/> + <menu_item_call label="Tirar - Tirar do look atual" name="take_off"/> + <menu_item_call label="Editar look" name="edit"/> + <menu_item_call label="Renomear look" name="rename"/> + <menu_item_call label="Excluir visual" name="delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_participant_list.xml b/indra/newview/skins/minimal/xui/pt/menu_participant_list.xml new file mode 100644 index 0000000000..01f1d4ef80 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_participant_list.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Participant List Context Menu"> + <menu_item_check label="Ordenar por nome" name="SortByName"/> + <menu_item_check label="Ordenar por conversas mais recentes" name="SortByRecentSpeakers"/> + <menu_item_call label="Ver perfil" name="View Profile"/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Compartilhar" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_check label="Ver ícones de pessoas" name="View Icons"/> + <menu_item_check label="Bloquear voz" name="Block/Unblock"/> + <menu_item_check label="Bloquear texto" name="MuteText"/> + <context_menu label="Opções do moderador >" name="Moderator Options"> + <menu_item_check label="Pode bater papo por escrito" name="AllowTextChat"/> + <menu_item_call label="Silenciar este participante" name="ModerateVoiceMuteSelected"/> + <menu_item_call label="Desfazer silenciar deste participante" name="ModerateVoiceUnMuteSelected"/> + <menu_item_call label="Silenciar todos" name="ModerateVoiceMute"/> + <menu_item_call label="Desfazer silenciar para todos" name="ModerateVoiceUnmute"/> + </context_menu> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_friends_view_sort.xml b/indra/newview/skins/minimal/xui/pt/menu_people_friends_view_sort.xml new file mode 100644 index 0000000000..e7c325010f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_friends_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar por nome" name="sort_name"/> + <menu_item_check label="Ordenar por status" name="sort_status"/> + <menu_item_check label="Ver ícones de pessoas" name="view_icons"/> + <menu_item_check label="Autorizações de visualização dadas" name="view_permissions"/> + <menu_item_call label="Ver residentes e objetos bloqueados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_groups.xml b/indra/newview/skins/minimal/xui/pt/menu_people_groups.xml new file mode 100644 index 0000000000..9a924ad7b9 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_groups.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_call label="Ver dados" name="View Info"/> + <menu_item_call label="Bate-papo" name="Chat"/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Ativar" name="Activate"/> + <menu_item_call label="Sair" name="Leave"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_groups_view_sort.xml b/indra/newview/skins/minimal/xui/pt/menu_people_groups_view_sort.xml new file mode 100644 index 0000000000..86a9d2263f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_groups_view_sort.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Mostrar ícones de grupos" name="Display Group Icons"/> + <menu_item_call label="Sair do grupo selecionado" name="Leave Selected Group"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_nearby.xml b/indra/newview/skins/minimal/xui/pt/menu_people_nearby.xml new file mode 100644 index 0000000000..7c720f262b --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_nearby.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Avatar Context Menu"> + <menu_item_call label="Ver perfil" name="View Profile"/> + <menu_item_call label="Adicionar amigo..." name="Add Friend"/> + <menu_item_call label="Remover amigo..." name="Remove Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Mapa" name="Map"/> + <menu_item_call label="Compartilhar" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_check label="Bloquear/desbloquear" name="Block/Unblock"/> + <menu_item_call label="Teletransportar?" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_nearby_multiselect.xml b/indra/newview/skins/minimal/xui/pt/menu_people_nearby_multiselect.xml new file mode 100644 index 0000000000..79edb96b1c --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_nearby_multiselect.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Multi-Selected People Context Menu"> + <menu_item_call label="Adicionar amigo..." name="Add Friends"/> + <menu_item_call label="Remover amigo..." name="Remove Friend"/> + <menu_item_call label="MI" name="IM"/> + <menu_item_call label="Ligar" name="Call"/> + <menu_item_call label="Compartilhar" name="Share"/> + <menu_item_call label="Pagar" name="Pay"/> + <menu_item_call label="Teletransportar?" name="teleport"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_nearby_view_sort.xml b/indra/newview/skins/minimal/xui/pt/menu_people_nearby_view_sort.xml new file mode 100644 index 0000000000..228ce46a31 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_nearby_view_sort.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar por conversas mais recentes" name="sort_by_recent_speakers"/> + <menu_item_check label="Ordenar por nome" name="sort_name"/> + <menu_item_check label="Ordenar por distância" name="sort_distance"/> + <menu_item_check label="Ver ícones de pessoas" name="view_icons"/> + <menu_item_call label="Ver residentes e objetos bloqueados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_people_recent_view_sort.xml b/indra/newview/skins/minimal/xui/pt/menu_people_recent_view_sort.xml new file mode 100644 index 0000000000..f3b89e01cd --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_people_recent_view_sort.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_group_plus"> + <menu_item_check label="Ordenar por mais recente" name="sort_most"/> + <menu_item_check label="Ordenar por nome" name="sort_name"/> + <menu_item_check label="Ver ícones de pessoas" name="view_icons"/> + <menu_item_call label="Ver residentes e objetos bloqueados" name="show_blocked_list"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_picks.xml b/indra/newview/skins/minimal/xui/pt/menu_picks.xml new file mode 100644 index 0000000000..8b9e10fc02 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_picks.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Picks"> + <menu_item_call label="Info" name="pick_info"/> + <menu_item_call label="Editar" name="pick_edit"/> + <menu_item_call label="Teletransportar" name="pick_teleport"/> + <menu_item_call label="Mapa" name="pick_map"/> + <menu_item_call label="Excluir" name="pick_delete"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_picks_plus.xml b/indra/newview/skins/minimal/xui/pt/menu_picks_plus.xml new file mode 100644 index 0000000000..95a7c05262 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_picks_plus.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="picks_plus_menu"> + <menu_item_call label="Adicionar" name="create_pick"/> + <menu_item_call label="Novo anúncio" name="create_classified"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_place.xml b/indra/newview/skins/minimal/xui/pt/menu_place.xml new file mode 100644 index 0000000000..282ea20a7a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_place.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="place_overflow_menu"> + <menu_item_call label="Criar marco" name="landmark"/> + <menu_item_call label="Criar destaque" name="pick"/> + <menu_item_call label="Comprar passe" name="pass"/> + <menu_item_call label="Editar" name="edit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_place_add_button.xml b/indra/newview/skins/minimal/xui/pt/menu_place_add_button.xml new file mode 100644 index 0000000000..d099d04f8d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_place_add_button.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Adicionar pasta" name="add_folder"/> + <menu_item_call label="Adicionar marco" name="add_landmark"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_places_gear_folder.xml b/indra/newview/skins/minimal/xui/pt/menu_places_gear_folder.xml new file mode 100644 index 0000000000..2059a9ed2d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_places_gear_folder.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_folder_gear"> + <menu_item_call label="Adicionar marco" name="add_landmark"/> + <menu_item_call label="Adicionar pasta" name="add_folder"/> + <menu_item_call label="Cortar" name="cut"/> + <menu_item_call label="Copiar" name="copy_folder"/> + <menu_item_call label="Colar" name="paste"/> + <menu_item_call label="Renomear" name="rename"/> + <menu_item_call label="Excluir" name="delete"/> + <menu_item_call label="Expanda" name="expand"/> + <menu_item_call label="Recolher" name="collapse"/> + <menu_item_call label="Expandir todas as pastas" name="expand_all"/> + <menu_item_call label="Recolher todas as pastas" name="collapse_all"/> + <menu_item_check label="Ordenar por data" name="sort_by_date"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_places_gear_landmark.xml b/indra/newview/skins/minimal/xui/pt/menu_places_gear_landmark.xml new file mode 100644 index 0000000000..52a9d13735 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_places_gear_landmark.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_ladmark_gear"> + <menu_item_call label="Teletransportar" name="teleport"/> + <menu_item_call label="Mais informações" name="more_info"/> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Adicionar marco" name="add_landmark"/> + <menu_item_call label="Adicionar pasta" name="add_folder"/> + <menu_item_call label="Cortar" name="cut"/> + <menu_item_call label="Copiar marco" name="copy_landmark"/> + <menu_item_call label="Copiar SLurl" name="copy_slurl"/> + <menu_item_call label="Colar" name="paste"/> + <menu_item_call label="Renomear" name="rename"/> + <menu_item_call label="Excluir" name="delete"/> + <menu_item_call label="Expandir todas as pastas" name="expand_all"/> + <menu_item_call label="Recolher todas as pastas" name="collapse_all"/> + <menu_item_check label="Ordenar por data" name="sort_by_date"/> + <menu_item_call label="Criar destaque" name="create_pick"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_profile_overflow.xml b/indra/newview/skins/minimal/xui/pt/menu_profile_overflow.xml new file mode 100644 index 0000000000..d41ecbd755 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_profile_overflow.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="profile_overflow_menu"> + <menu_item_call label="Mapa" name="show_on_map"/> + <menu_item_call label="Pagar" name="pay"/> + <menu_item_call label="Compartilhar" name="share"/> + <menu_item_call label="Bloquear" name="block"/> + <menu_item_call label="Desbloquear" name="unblock"/> + <menu_item_call label="Chutar" name="kick"/> + <menu_item_call label="Congelar" name="freeze"/> + <menu_item_call label="Descongelar" name="unfreeze"/> + <menu_item_call label="CSR" name="csr"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_save_outfit.xml b/indra/newview/skins/minimal/xui/pt/menu_save_outfit.xml new file mode 100644 index 0000000000..61c6b9202f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_save_outfit.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<toggleable_menu name="save_outfit_menu"> + <menu_item_call label="Salvar" name="save_outfit"/> + <menu_item_call label="Salvar como" name="save_as_new_outfit"/> +</toggleable_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_script_chiclet.xml b/indra/newview/skins/minimal/xui/pt/menu_script_chiclet.xml new file mode 100644 index 0000000000..ccf3878e14 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_script_chiclet.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="ScriptChiclet Menu"> + <menu_item_call label="Fechar" name="Close"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_slurl.xml b/indra/newview/skins/minimal/xui/pt/menu_slurl.xml new file mode 100644 index 0000000000..6d4c84fc3c --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_slurl.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Popup"> + <menu_item_call label="Sobre a URL" name="about_url"/> + <menu_item_call label="Teletransporte para a URL" name="teleport_to_url"/> + <menu_item_call label="Mapa" name="show_on_map"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_teleport_history_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_gear.xml new file mode 100644 index 0000000000..f034509be8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_gear.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Teleport History Gear Context Menu"> + <menu_item_call label="Expandir todas as pastas" name="Expand all folders"/> + <menu_item_call label="Recolher todas as pastas" name="Collapse all folders"/> + <menu_item_call label="Limpar histórico de teletransporte" name="Clear Teleport History"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_teleport_history_item.xml b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_item.xml new file mode 100644 index 0000000000..ec1e7a0950 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_item.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Teletransportar" name="Teleport"/> + <menu_item_call label="Mais informações" name="More Information"/> + <menu_item_call label="Copiar" name="CopyToClipboard"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_teleport_history_tab.xml b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_tab.xml new file mode 100644 index 0000000000..6a633cf74c --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_teleport_history_tab.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Teleport History Item Context Menu"> + <menu_item_call label="Abrir" name="TabOpen"/> + <menu_item_call label="Fechar" name="TabClose"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_text_editor.xml b/indra/newview/skins/minimal/xui/pt/menu_text_editor.xml new file mode 100644 index 0000000000..31c284c6ed --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_text_editor.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Text editor context menu"> + <menu_item_call label="Cortar" name="Cut"/> + <menu_item_call label="Copiar" name="Copy"/> + <menu_item_call label="Colar" name="Paste"/> + <menu_item_call label="Excluir" name="Delete"/> + <menu_item_call label="Selecionar tudo" name="Select All"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_topinfobar.xml b/indra/newview/skins/minimal/xui/pt/menu_topinfobar.xml new file mode 100644 index 0000000000..d9347950b1 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_topinfobar.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="menu_topinfobar"> + <menu_item_check label="Mostrar coordenadas" name="Show Coordinates"/> + <menu_item_check label="Mostrar as propriedades do terreno" name="Show Parcel Properties"/> + <menu_item_call label="Marco" name="Landmark"/> + <menu_item_call label="Copiar" name="Copy"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_agent.xml b/indra/newview/skins/minimal/xui/pt/menu_url_agent.xml new file mode 100644 index 0000000000..ba5e055124 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_agent.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar perfil de residente" name="show_agent"/> + <menu_item_call label="Copiar nome para área de transferência" name="url_copy_label"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_group.xml b/indra/newview/skins/minimal/xui/pt/menu_url_group.xml new file mode 100644 index 0000000000..5b67a69c9a --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_group.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar informações do grupo" name="show_group"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy_label"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_http.xml b/indra/newview/skins/minimal/xui/pt/menu_url_http.xml new file mode 100644 index 0000000000..e53a2572b8 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_http.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Abrir página da web" name="url_open"/> + <menu_item_call label="Abrir no navegador do SL" name="url_open_internal"/> + <menu_item_call label="Abrir no navegador externo" name="url_open_external"/> + <menu_item_call label="Copiar URL para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_inventory.xml b/indra/newview/skins/minimal/xui/pt/menu_url_inventory.xml new file mode 100644 index 0000000000..45c14355d0 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_inventory.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar item de inventário" name="show_item"/> + <menu_item_call label="Copiar nome para área de transferência" name="url_copy_label"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_map.xml b/indra/newview/skins/minimal/xui/pt/menu_url_map.xml new file mode 100644 index 0000000000..ba114cccaa --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_map.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Teletransportar para este lugar" name="teleport_to_location"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_objectim.xml b/indra/newview/skins/minimal/xui/pt/menu_url_objectim.xml new file mode 100644 index 0000000000..c197444181 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_objectim.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar informações sobre o objeto" name="show_object"/> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Teletransportar para lugar do objeto" name="teleport_to_object"/> + <menu_item_call label="Copiar nome do objeto para área de transferência" name="url_copy_label"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_parcel.xml b/indra/newview/skins/minimal/xui/pt/menu_url_parcel.xml new file mode 100644 index 0000000000..6cc668bfd3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_parcel.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar informações sobre este lote" name="show_parcel"/> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_slapp.xml b/indra/newview/skins/minimal/xui/pt/menu_url_slapp.xml new file mode 100644 index 0000000000..d0784149ac --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_slapp.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Executar este comando" name="run_slapp"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_slurl.xml b/indra/newview/skins/minimal/xui/pt/menu_url_slurl.xml new file mode 100644 index 0000000000..7216ccf0b3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_slurl.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Mostrar informações sobre este lugar" name="show_place"/> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Teletransportar para este lugar" name="teleport_to_location"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_url_teleport.xml b/indra/newview/skins/minimal/xui/pt/menu_url_teleport.xml new file mode 100644 index 0000000000..f007425646 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_url_teleport.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Url Popup"> + <menu_item_call label="Teletransportar para este lugar" name="teleport"/> + <menu_item_call label="Mostrar no mapa" name="show_on_map"/> + <menu_item_call label="Copiar SLurl para área de transferência" name="url_copy"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_viewer.xml b/indra/newview/skins/minimal/xui/pt/menu_viewer.xml new file mode 100644 index 0000000000..2bd1e88279 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_viewer.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu_bar name="Main Menu"> + <menu label="Ajuda" name="Help"> + <menu_item_call label="[SECOND_LIFE] Ajuda" name="Second Life Help"/> + </menu> + <menu label="Avançado" name="Advanced"> + <menu label="Atalhos" name="Shortcuts"> + <menu_item_check label="Voar" name="Fly"/> + <menu_item_call label="Fechar janela" name="Close Window"/> + <menu_item_call label="Fechar todas as janelas" name="Close All Windows"/> + <menu_item_call label="Visão padrão" name="Reset View"/> + </menu> + </menu> +</menu_bar> diff --git a/indra/newview/skins/minimal/xui/pt/menu_wearable_list_item.xml b/indra/newview/skins/minimal/xui/pt/menu_wearable_list_item.xml new file mode 100644 index 0000000000..2487f6779f --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_wearable_list_item.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Outfit Wearable Context Menu"> + <menu_item_call label="Trocar" name="wear_replace"/> + <menu_item_call label="Vestir" name="wear_wear"/> + <menu_item_call label="Adicionar" name="wear_add"/> + <menu_item_call label="Tirar / Separar" name="take_off_or_detach"/> + <menu_item_call label="Separar" name="detach"/> + <context_menu label="Colocar em" name="wearable_attach_to"/> + <context_menu label="Anexar ao HUD" name="wearable_attach_to_hud"/> + <menu_item_call label="Tirar" name="take_off"/> + <menu_item_call label="Editar" name="edit"/> + <menu_item_call label="Perfil do item" name="object_profile"/> + <menu_item_call label="Mostrar original" name="show_original"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_wearing_gear.xml b/indra/newview/skins/minimal/xui/pt/menu_wearing_gear.xml new file mode 100644 index 0000000000..7b6ce4d87e --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_wearing_gear.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<menu name="Gear Wearing"> + <menu_item_call label="Editar look" name="edit"/> + <menu_item_call label="Tirar" name="takeoff"/> +</menu> diff --git a/indra/newview/skins/minimal/xui/pt/menu_wearing_tab.xml b/indra/newview/skins/minimal/xui/pt/menu_wearing_tab.xml new file mode 100644 index 0000000000..4e6e52ebc7 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/menu_wearing_tab.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<context_menu name="Wearing"> + <menu_item_call label="Tirar" name="take_off"/> + <menu_item_call label="Tirar" name="detach"/> + <menu_item_call label="Editar look" name="edit"/> +</context_menu> diff --git a/indra/newview/skins/minimal/xui/pt/panel_adhoc_control_panel.xml b/indra/newview/skins/minimal/xui/pt/panel_adhoc_control_panel.xml new file mode 100644 index 0000000000..bd50d4953d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_adhoc_control_panel.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_im_control_panel"> + <layout_stack name="vertical_stack"> + <layout_panel name="call_btn_panel"> + <button label="Ligar" name="call_btn"/> + </layout_panel> + <layout_panel name="end_call_btn_panel"> + <button label="Desligar" name="end_call_btn"/> + </layout_panel> + <layout_panel name="voice_ctrls_btn_panel"> + <button label="Controles de voz" name="voice_ctrls_btn"/> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/pt/panel_bottomtray.xml new file mode 100644 index 0000000000..243f323f09 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_bottomtray.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="bottom_tray"> + <string name="DragIndicationImageName" value="Accordion_ArrowOpened_Off"/> + <string name="SpeakBtnToolTip" value="Liga e desliga o microfone"/> + <string name="VoiceControlBtnToolTip" value="Mostra/oculta os controles de voz"/> + <layout_stack name="toolbar_stack"> + <layout_panel name="gesture_panel"> + <gesture_combo_list label="Gesto" name="Gesture" tool_tip="Mostra/oculta os gestos"/> + </layout_panel> + <layout_panel name="cam_panel"> + <bottomtray_button label="Exibir" name="camera_btn" tool_tip="Mostra/oculta os controles da câmera"/> + </layout_panel> + <layout_panel name="avatar_and_destinations_panel"> + <radio_group name="avatar_and_destination_btns"> + <radio_item name="destination_btn" value="0"/> + <radio_item name="avatar_btn" value="1"/> + </radio_group> + </layout_panel> + <layout_panel name="people_panel"> + <bottomtray_button label="Pessoas" name="show_people_button" tool_tip="Exibe as pessoas"/> + </layout_panel> + <layout_panel name="profile_panel"> + <bottomtray_button label="Perfil" name="show_profile_btn" tool_tip="Exibe o perfil"/> + </layout_panel> + <layout_panel name="howto_panel"> + <bottomtray_button label="Como..." name="show_help_btn" tool_tip="Abrir "Como..." do Second Life"/> + </layout_panel> + <layout_panel name="im_well_panel"> + <chiclet_im_well name="im_well"> + <button name="Unread IM messages" tool_tip="Conversas"/> + </chiclet_im_well> + </layout_panel> + <layout_panel name="notification_well_panel"> + <chiclet_notification name="notification_well"> + <button name="Unread" tool_tip="Notificações"/> + </chiclet_notification> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_im_control_panel.xml b/indra/newview/skins/minimal/xui/pt/panel_im_control_panel.xml new file mode 100644 index 0000000000..91b7d1b7cd --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_im_control_panel.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_im_control_panel"> + <layout_stack name="button_stack"> + <layout_panel name="view_profile_btn_panel"> + <button label="Perfil" name="view_profile_btn"/> + </layout_panel> + <layout_panel name="add_friend_btn_panel"> + <button label="Adicionar amigo" name="add_friend_btn"/> + </layout_panel> + <layout_panel name="teleport_btn_panel"> + <button label="Teletransportar" name="teleport_btn" tool_tip="Oferecer teletransporte"/> + </layout_panel> + <layout_panel name="share_btn_panel"> + <button label="Compartilhar" name="share_btn"/> + </layout_panel> + <layout_panel name="pay_btn_panel"> + <button label="Pagar" name="pay_btn"/> + </layout_panel> + <layout_panel name="call_btn_panel"> + <button label="Ligar" name="call_btn"/> + </layout_panel> + <layout_panel name="end_call_btn_panel"> + <button label="Encerrar ligação" name="end_call_btn"/> + </layout_panel> + <layout_panel name="voice_ctrls_btn_panel"> + <button label="Controles de voz" name="voice_ctrls_btn"/> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_login.xml b/indra/newview/skins/minimal/xui/pt/panel_login.xml new file mode 100644 index 0000000000..cd529b0b06 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_login.xml @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="panel_login"> + <panel.string name="create_account_url"> + http://join.secondlife.com/ + </panel.string> + <panel.string name="forgot_password_url"> + http://secondlife.com/account/request.php?lang=pt + </panel.string> + <layout_stack name="login_widgets"> + <layout_panel name="login"> + <text name="username_text"> + Nome de usuário: + </text> + <combo_box name="username_combo" tool_tip="O nome de usuário que você escolheu ao fazer seu cadastro, como zecazc12 or Magia Solar"/> + <text name="password_text"> + Senha: + </text> + <check_box label="Lembrar senha" name="remember_check"/> + <button label="conectar" name="connect_btn"/> + <text name="mode_selection_text"> + Modo: + </text> + <combo_box name="mode_combo"> + <combo_box.item label="Básico (padrão)" name="Basic"/> + <combo_box.item label="Avançado" name="Advanced"/> + </combo_box> + </layout_panel> + <layout_panel name="links"> + <text name="create_new_account_text"> + Cadastre-se + </text> + <text name="forgot_password_text"> + Esqueceu seu nome ou senha? + </text> + <text name="login_help"> + Precisa de ajuda ao conectar? + </text> + </layout_panel> + </layout_stack> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_navigation_bar.xml b/indra/newview/skins/minimal/xui/pt/panel_navigation_bar.xml new file mode 100644 index 0000000000..01930bf3b3 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_navigation_bar.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="navigation_bar"> + <panel name="navigation_panel"> + <pull_button name="back_btn" tool_tip="Voltar para região anterior"/> + <pull_button name="forward_btn" tool_tip="Avançar uma região"/> + <button name="home_btn" tool_tip="Teletransportar para meu início"/> + <location_input label="Onde" name="location_combo"/> + <search_combo_box label="Busca" name="search_combo_box" tool_tip="Busca"> + <combo_editor label="Buscar no [SECOND_LIFE]" name="search_combo_editor"/> + </search_combo_box> + </panel> + <favorites_bar name="favorite" tool_tip="Arraste marcos para cá para acessar seus lugares preferidos do Second Life!"> + <label name="favorites_bar_label" tool_tip="Arraste marcos para cá para acessar seus lugares preferidos do Second Life!"> + Barra Destaques + </label> + <chevron_button name=">>" tool_tip="Mostrar mais favoritos"/> + </favorites_bar> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_people.xml b/indra/newview/skins/minimal/xui/pt/panel_people.xml new file mode 100644 index 0000000000..935ade2177 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_people.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<!-- Side tray panel --> +<panel label="Pessoas" name="people_panel"> + <string name="no_recent_people" value="Ninguém, recentemente. Em busca de alguém para conversar? Confira o botão Destinos abaixo."/> + <string name="no_filtered_recent_people" value="Não há ninguém com esse nome ultimamente."/> + <string name="no_one_near" value="Ninguém por perto Em busca de alguém para conversar? Confira o botão Destinos abaixo."/> + <string name="no_one_filtered_near" value="Não há ninguém com esse nome por perto."/> + <string name="no_friends_online" value="Nenhum amigo online"/> + <string name="no_friends" value="Nenhum amigo"/> + <string name="no_friends_msg"> + Clique em um residente com o botão direito to mouse para adicioná-lo como amigo. +Em busca de alguém para conversar? Confira o botão Destinos abaixo. + </string> + <string name="no_filtered_friends_msg"> + Não encontrou o que procura? Confira o botão Destinos abaixo. + </string> + <string name="people_filter_label" value="Filtro de pessoas"/> + <string name="groups_filter_label" value="Filtro de grupos"/> + <string name="no_filtered_groups_msg" value="Não encontrou o que procura? Tente buscar no [secondlife:///app/search/groups/[SEARCH_TERM] Search]."/> + <string name="no_groups_msg" value="À procura de grupos interessantes? Tente fazer uma [secondlife:///app/search/groups Busca]."/> + <string name="MiniMapToolTipMsg" value="[REGION](Clique duplo para abrir o Mapa, botão Shift e arrastar para ver mais)"/> + <string name="AltMiniMapToolTipMsg" value="[REGION](Clique duplo para se teletransportar, botão Shift e arrastar para ver mais)"/> + <filter_editor label="Filtro" name="filter_input"/> + <tab_container name="tabs"> + <panel label="PROXIMIDADE" name="nearby_panel"> + <panel label="bottom_panel" name="bottom_panel"/> + </panel> + <panel label="MEUS AMIGOS" name="friends_panel"> + <accordion name="friends_accordion"> + <accordion_tab name="tab_online" title="Online"/> + <accordion_tab name="tab_all" title="Todos"/> + </accordion> + <panel label="bottom_panel" name="bottom_panel"> + <layout_stack name="bottom_panel"> + <layout_panel name="trash_btn_panel"> + <dnd_button name="del_btn" tool_tip="Remover a pessoa selecionada da sua lista de amigos"/> + </layout_panel> + </layout_stack> + </panel> + </panel> + <panel label="RECENTE" name="recent_panel"> + <panel label="bottom_panel" name="bottom_panel"> + <button name="add_friend_btn" tool_tip="Adicionar o residente selecionado para sua lista de amigos"/> + </panel> + </panel> + </tab_container> + <panel name="button_bar"> + <layout_stack name="bottom_bar_ls"> + <layout_panel name="view_profile_btn_lp"> + <button label="Perfil" name="view_profile_btn" tool_tip="Exibir fotografia, grupos e outras informações dos residentes"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="MI" name="im_btn" tool_tip="Abrir sessão de mensagem instantânea"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Teletransportar" name="teleport_btn" tool_tip="Oferecer teletransporte"/> + </layout_panel> + </layout_stack> + <layout_stack name="bottom_bar_ls1"> + <layout_panel name="group_info_btn_lp"> + <button label="Perfil do grupo" name="group_info_btn" tool_tip="Exibir dados do grupo"/> + </layout_panel> + <layout_panel name="chat_btn_lp"> + <button label="Bate-papo de grupo" name="chat_btn" tool_tip="Nova sessão de bate-papo"/> + </layout_panel> + <layout_panel name="group_call_btn_lp"> + <button label="Ligar para o grupo" name="group_call_btn" tool_tip="Ligar para este grupo"/> + </layout_panel> + </layout_stack> + </panel> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_side_tray_tab_caption.xml b/indra/newview/skins/minimal/xui/pt/panel_side_tray_tab_caption.xml new file mode 100644 index 0000000000..09444a5535 --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_side_tray_tab_caption.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="sidetray_tab_panel"> + <text name="sidetray_tab_title" value="Bandeja lateral"/> + <button name="undock" tool_tip="Soltar janela"/> + <button name="dock" tool_tip="Ancorar janela"/> + <button name="show_help" tool_tip="Mostrar ajuda"/> +</panel> diff --git a/indra/newview/skins/minimal/xui/pt/panel_status_bar.xml b/indra/newview/skins/minimal/xui/pt/panel_status_bar.xml new file mode 100644 index 0000000000..f7890ae57d --- /dev/null +++ b/indra/newview/skins/minimal/xui/pt/panel_status_bar.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes"?> +<panel name="status"> + <panel.string name="StatBarDaysOfWeek"> + Domingo:Segunda-feira:Terça-feira:Quarta-feira:Quinta-feira:Sexta-feira:Sábado + </panel.string> + <panel.string name="StatBarMonthsOfYear"> + Janeiro:Fevereiro:Março:Abril:Maio:Junho:Julho:Agosto:Setembro:Outubro:Novembro:Dezembro + </panel.string> + <panel.string name="packet_loss_tooltip"> + Perda de pacote + </panel.string> + <panel.string name="bandwidth_tooltip"> + Banda + </panel.string> + <panel.string name="time"> + [hour12, datetime, slt]:[min, datetime, slt] [ampm, datetime, slt] [timezone,datetime, slt] + </panel.string> + <panel.string name="timeTooltip"> + [weekday, datetime, slt], [day, datetime, slt] [month, datetime, slt] [year, datetime, slt] + </panel.string> + <panel.string name="buycurrencylabel"> + L$ [AMT] + </panel.string> + <panel name="balance_bg"> + <text name="balance" tool_tip="Atualizar saldo de L$" value="L$20"/> + <button label="Comprar L$" name="buyL" tool_tip="Comprar mais L$"/> + </panel> + <text name="TimeText" tool_tip="Hora atual (Pacífico)"> + 24:00 AM PST + </text> + <button name="media_toggle_btn" tool_tip="Tocar/Pausar todas mídias (música, vídeo, páginas web)"/> + <button name="volume_btn" tool_tip="Volume geral"/> +</panel> diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py index 1a4551d069..2d7a6f7a67 100644 --- a/indra/newview/viewer_manifest.py +++ b/indra/newview/viewer_manifest.py @@ -345,7 +345,7 @@ class WindowsManifest(ViewerManifest): self.end_prefix() # winmm.dll shim - if self.prefix(src='../media_plugins/winmmshim/%s' % self.args['configuration'], dst="llplugin"): + if self.prefix(src='../media_plugins/winmmshim/%s' % self.args['configuration'], dst=""): self.path("winmm.dll") self.end_prefix() |