From 8fae5d49bf211fbbd58511442f91e09e8c4c0458 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Fri, 7 Jan 2011 18:24:35 -0500 Subject: testing: adding glFlush() each frame for performance testing --- indra/llwindow/llwindowmacosx.cpp | 1 + indra/llwindow/llwindowsdl.cpp | 3 +++ indra/llwindow/llwindowwin32.cpp | 1 + 3 files changed, 5 insertions(+) diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp index affd7276cc..fa8ba7bafa 100644 --- a/indra/llwindow/llwindowmacosx.cpp +++ b/indra/llwindow/llwindowmacosx.cpp @@ -1273,6 +1273,7 @@ BOOL LLWindowMacOSX::setSize(const LLCoordScreen size) void LLWindowMacOSX::swapBuffers() { + glFlush(); aglSwapBuffers(mContext); } diff --git a/indra/llwindow/llwindowsdl.cpp b/indra/llwindow/llwindowsdl.cpp index b65287715c..80566b40c0 100644 --- a/indra/llwindow/llwindowsdl.cpp +++ b/indra/llwindow/llwindowsdl.cpp @@ -984,7 +984,10 @@ BOOL LLWindowSDL::setSize(const LLCoordScreen size) void LLWindowSDL::swapBuffers() { if (mWindow) + { + glFlush(); SDL_GL_SwapBuffers(); + } } U32 LLWindowSDL::getFSAASamples() diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp index ab089081e6..e457e76f55 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -2858,6 +2858,7 @@ BOOL LLWindowWin32::resetDisplayResolution() void LLWindowWin32::swapBuffers() { + glFlush(); SwapBuffers(mhDC); } -- cgit v1.2.3 From d1683bd65ae2797de9d92658d720b81c3be80fff Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Thu, 13 Jan 2011 13:46:00 -0500 Subject: glFlush != glFinish. doh. --- indra/llwindow/llwindowmacosx.cpp | 2 +- indra/llwindow/llwindowsdl.cpp | 2 +- indra/llwindow/llwindowwin32.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp index fa8ba7bafa..db90aaf52a 100644 --- a/indra/llwindow/llwindowmacosx.cpp +++ b/indra/llwindow/llwindowmacosx.cpp @@ -1273,7 +1273,7 @@ BOOL LLWindowMacOSX::setSize(const LLCoordScreen size) void LLWindowMacOSX::swapBuffers() { - glFlush(); + glFinish(); aglSwapBuffers(mContext); } diff --git a/indra/llwindow/llwindowsdl.cpp b/indra/llwindow/llwindowsdl.cpp index 80566b40c0..e41aa9820f 100644 --- a/indra/llwindow/llwindowsdl.cpp +++ b/indra/llwindow/llwindowsdl.cpp @@ -985,7 +985,7 @@ void LLWindowSDL::swapBuffers() { if (mWindow) { - glFlush(); + glFinish(); SDL_GL_SwapBuffers(); } } diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp index e457e76f55..aba0dc43eb 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -2858,7 +2858,7 @@ BOOL LLWindowWin32::resetDisplayResolution() void LLWindowWin32::swapBuffers() { - glFlush(); + glFinish(); SwapBuffers(mhDC); } -- cgit v1.2.3 From 01d219ed4c140fbc54069cdcb6d1b671f91e9923 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Tue, 1 Feb 2011 17:26:23 -0500 Subject: removing particle disabling from performance testing so that I can test performance of particles --- indra/newview/llviewercontrol.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 444d5cb902..bc34c369da 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -141,7 +141,6 @@ static bool handleRenderPerfTestChanged(const LLSD& newvalue) LLPipeline::RENDER_TYPE_WATER, LLPipeline::RENDER_TYPE_PASS_GRASS, LLPipeline::RENDER_TYPE_HUD, - LLPipeline::RENDER_TYPE_PARTICLES, LLPipeline::RENDER_TYPE_CLOUDS, LLPipeline::RENDER_TYPE_HUD_PARTICLES, LLPipeline::END_RENDER_TYPES); @@ -157,7 +156,6 @@ static bool handleRenderPerfTestChanged(const LLSD& newvalue) LLPipeline::RENDER_TYPE_WATER, LLPipeline::RENDER_TYPE_PASS_GRASS, LLPipeline::RENDER_TYPE_HUD, - LLPipeline::RENDER_TYPE_PARTICLES, LLPipeline::RENDER_TYPE_CLOUDS, LLPipeline::RENDER_TYPE_HUD_PARTICLES, LLPipeline::END_RENDER_TYPES); -- cgit v1.2.3 From e3816f4577a74bba42ae9091461125ec9698b583 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Tue, 8 Feb 2011 17:00:36 -0500 Subject: adding pausing on startup for windows to help debug application not starting. --- indra/newview/llappviewerwin32.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp index d328567a0e..b0bf36f688 100644 --- a/indra/newview/llappviewerwin32.cpp +++ b/indra/newview/llappviewerwin32.cpp @@ -57,7 +57,7 @@ #include "llcommandlineparser.h" #include "lltrans.h" - +#include "runtimediagnostics.h" #ifndef LL_RELEASE_FOR_DOWNLOAD #include "llwindebug.h" #endif @@ -110,6 +110,7 @@ int APIENTRY WINMAIN(HINSTANCE hInstance, LPSTR lpCmdLine, int nCmdShow) { + RuntimeDiagnostics::CheckPauseOnStartupOption(); LLMemType mt1(LLMemType::MTYPE_STARTUP); const S32 MAX_HEAPS = 255; -- cgit v1.2.3 From 9ef62ba2cecbed3db3eff74a294eb252f018399c Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 9 Feb 2011 14:01:36 -0500 Subject: forgot to add runtimediagnostics.h. whoops. --- indra/newview/CMakeLists.txt | 1 + indra/newview/runtimediagnostics.h | 256 +++++++++++++++++++++++++++++++++++++ 2 files changed, 257 insertions(+) create mode 100644 indra/newview/runtimediagnostics.h diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 8ea0dd1089..ca408d032a 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -1136,6 +1136,7 @@ set(viewer_HEADER_FILES macmain.h noise.h pipeline.h + runtimediagnostics.h VertexCache.h VorbisFramework.h ) diff --git a/indra/newview/runtimediagnostics.h b/indra/newview/runtimediagnostics.h new file mode 100644 index 0000000000..b1c2662958 --- /dev/null +++ b/indra/newview/runtimediagnostics.h @@ -0,0 +1,256 @@ + once + + + +#include + + + +/* static*/ class RuntimeDiagnostics + +{ + +public: + + static void CheckPauseOnStartupOption( + + ) + + { + + DWORD dwPause; + + if (GetExecutionOption(TEXT("PauseOnStartup"), &dwPause) == S_OK && dwPause != 0) + + { + + while (true) + + { + + if (IsDebuggerPresent()) + + { + + __debugbreak(); + + break; + + } + + + + Sleep(1000); + + } + + } + + } + + + +private: + + static HRESULT GetExecutionOption( + + LPCTSTR szOptionName, + + DWORD *pValue + + ) + + { + + HRESULT hr; + + DWORD nChar; + + + + *pValue = 0; + + + + CRegKey rkeyExecutionOptions; + + hr = WIN32_ERROR_CALL( rkeyExecutionOptions.Open( + + HKEY_LOCAL_MACHINE, + + TEXT("SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options"), + + KEY_READ + + ) ); + + + + if (hr == S_OK) + + { + + TCHAR szModPath[MAX_PATH + 1]; + + nChar = GetModuleFileName(NULL, szModPath, ARRAYSIZE(szModPath)); + + hr = WIN32_BOOL_CALL(nChar > 0 && nChar < ARRAYSIZE(szModPath)); + + + + if (hr == S_OK) + + { + + nChar = GetFileNameCharOffset(szModPath); + + + + if (nChar != MAXDWORD) + + { + + CRegKey rkeyExe; + + hr = WIN32_ERROR_CALL( rkeyExe.Open(rkeyExecutionOptions, szModPath + nChar, KEY_QUERY_VALUE) ); + + if (hr == S_OK) + + { + + hr = WIN32_ERROR_CALL( rkeyExe.QueryDWORDValue(szOptionName, *pValue) ); + + } + + } + + else + + { + + hr = E_FAIL; + + } + + } + + } + + + + return hr; + + } + + + + static DWORD GetFileNameCharOffset(LPCTSTR szPath) + + { + + if (!szPath) + + { + + return MAXDWORD; + + } + + + + // Find the last slash + + DWORD dwReturn = 0; + + for (DWORD c = 0; szPath[c] != 0; c++) + + { + + if (c >= INT_MAX) + + { + + return MAXDWORD; // string did not terminate + + } + + + + if (szPath[c] == '\\' || szPath[c] == '/' || (szPath[c] == ':' && c == 1)) + + { + + dwReturn = c + 1; + + } + + } + + + + // Make sure that the string doesn't end at the slash + + if (szPath[dwReturn] == 0) + + { + + dwReturn = MAXDWORD; + + } + + + + return dwReturn; + + } + + + + static inline HRESULT WIN32_ERROR(LONG lError) + + { + + return HRESULT_FROM_WIN32(lError); + + } + + + + static inline HRESULT WIN32_LAST_ERROR() + + { + + return WIN32_ERROR(GetLastError()); + + } + + + + static inline HRESULT WIN32_BOOL_CALL(BOOL rc) + + { + + if (!rc) + + return WIN32_LAST_ERROR(); + + return S_OK; + + } + + + + static inline HRESULT WIN32_ERROR_CALL(LONG lError) + + { + + if (lError != ERROR_SUCCESS) + + return WIN32_ERROR(lError); + + return S_OK; + + } + +}; + -- cgit v1.2.3 From 86a2c4912c72a735f713dfc40a053335a21f3350 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 9 Feb 2011 16:10:01 -0500 Subject: header got cut off. ugh. --- indra/newview/runtimediagnostics.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/indra/newview/runtimediagnostics.h b/indra/newview/runtimediagnostics.h index b1c2662958..bf385a6361 100644 --- a/indra/newview/runtimediagnostics.h +++ b/indra/newview/runtimediagnostics.h @@ -1,7 +1,4 @@ - once - - - +#pragma once #include -- cgit v1.2.3 From 344ddaf9f5945c63c39774f9619069629430e70b Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Fri, 11 Feb 2011 17:30:09 -0500 Subject: reverting windows debugging commits. --- indra/newview/CMakeLists.txt | 1 - indra/newview/llappviewerwin32.cpp | 3 +- indra/newview/runtimediagnostics.h | 253 ------------------------------------- 3 files changed, 1 insertion(+), 256 deletions(-) delete mode 100644 indra/newview/runtimediagnostics.h diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index ca408d032a..8ea0dd1089 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -1136,7 +1136,6 @@ set(viewer_HEADER_FILES macmain.h noise.h pipeline.h - runtimediagnostics.h VertexCache.h VorbisFramework.h ) diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp index b0bf36f688..d328567a0e 100644 --- a/indra/newview/llappviewerwin32.cpp +++ b/indra/newview/llappviewerwin32.cpp @@ -57,7 +57,7 @@ #include "llcommandlineparser.h" #include "lltrans.h" -#include "runtimediagnostics.h" + #ifndef LL_RELEASE_FOR_DOWNLOAD #include "llwindebug.h" #endif @@ -110,7 +110,6 @@ int APIENTRY WINMAIN(HINSTANCE hInstance, LPSTR lpCmdLine, int nCmdShow) { - RuntimeDiagnostics::CheckPauseOnStartupOption(); LLMemType mt1(LLMemType::MTYPE_STARTUP); const S32 MAX_HEAPS = 255; diff --git a/indra/newview/runtimediagnostics.h b/indra/newview/runtimediagnostics.h deleted file mode 100644 index bf385a6361..0000000000 --- a/indra/newview/runtimediagnostics.h +++ /dev/null @@ -1,253 +0,0 @@ -#pragma once -#include - - - -/* static*/ class RuntimeDiagnostics - -{ - -public: - - static void CheckPauseOnStartupOption( - - ) - - { - - DWORD dwPause; - - if (GetExecutionOption(TEXT("PauseOnStartup"), &dwPause) == S_OK && dwPause != 0) - - { - - while (true) - - { - - if (IsDebuggerPresent()) - - { - - __debugbreak(); - - break; - - } - - - - Sleep(1000); - - } - - } - - } - - - -private: - - static HRESULT GetExecutionOption( - - LPCTSTR szOptionName, - - DWORD *pValue - - ) - - { - - HRESULT hr; - - DWORD nChar; - - - - *pValue = 0; - - - - CRegKey rkeyExecutionOptions; - - hr = WIN32_ERROR_CALL( rkeyExecutionOptions.Open( - - HKEY_LOCAL_MACHINE, - - TEXT("SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options"), - - KEY_READ - - ) ); - - - - if (hr == S_OK) - - { - - TCHAR szModPath[MAX_PATH + 1]; - - nChar = GetModuleFileName(NULL, szModPath, ARRAYSIZE(szModPath)); - - hr = WIN32_BOOL_CALL(nChar > 0 && nChar < ARRAYSIZE(szModPath)); - - - - if (hr == S_OK) - - { - - nChar = GetFileNameCharOffset(szModPath); - - - - if (nChar != MAXDWORD) - - { - - CRegKey rkeyExe; - - hr = WIN32_ERROR_CALL( rkeyExe.Open(rkeyExecutionOptions, szModPath + nChar, KEY_QUERY_VALUE) ); - - if (hr == S_OK) - - { - - hr = WIN32_ERROR_CALL( rkeyExe.QueryDWORDValue(szOptionName, *pValue) ); - - } - - } - - else - - { - - hr = E_FAIL; - - } - - } - - } - - - - return hr; - - } - - - - static DWORD GetFileNameCharOffset(LPCTSTR szPath) - - { - - if (!szPath) - - { - - return MAXDWORD; - - } - - - - // Find the last slash - - DWORD dwReturn = 0; - - for (DWORD c = 0; szPath[c] != 0; c++) - - { - - if (c >= INT_MAX) - - { - - return MAXDWORD; // string did not terminate - - } - - - - if (szPath[c] == '\\' || szPath[c] == '/' || (szPath[c] == ':' && c == 1)) - - { - - dwReturn = c + 1; - - } - - } - - - - // Make sure that the string doesn't end at the slash - - if (szPath[dwReturn] == 0) - - { - - dwReturn = MAXDWORD; - - } - - - - return dwReturn; - - } - - - - static inline HRESULT WIN32_ERROR(LONG lError) - - { - - return HRESULT_FROM_WIN32(lError); - - } - - - - static inline HRESULT WIN32_LAST_ERROR() - - { - - return WIN32_ERROR(GetLastError()); - - } - - - - static inline HRESULT WIN32_BOOL_CALL(BOOL rc) - - { - - if (!rc) - - return WIN32_LAST_ERROR(); - - return S_OK; - - } - - - - static inline HRESULT WIN32_ERROR_CALL(LONG lError) - - { - - if (lError != ERROR_SUCCESS) - - return WIN32_ERROR(lError); - - return S_OK; - - } - -}; - -- cgit v1.2.3 From 4046a9082d793e71cac26a31d44c127decd6821f Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Fri, 11 Feb 2011 17:37:07 -0500 Subject: re-applying render cost changes for experimentations --- indra/newview/llfloatertools.cpp | 32 +----- indra/newview/llfloatertools.h | 1 - indra/newview/llselectmgr.cpp | 4 +- indra/newview/llvoavatar.cpp | 16 ++- indra/newview/llvovolume.cpp | 237 ++++++++++++++++++++++++++++++--------- indra/newview/llvovolume.h | 5 +- 6 files changed, 198 insertions(+), 97 deletions(-) diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index bef830a93e..ceaf3c1449 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -476,7 +476,8 @@ void LLFloaterTools::refresh() if (sShowObjectCost) { std::string prim_cost_string; - LLResMgr::getInstance()->getIntegerString(prim_cost_string, calcRenderCost()); + S32 cost = LLSelectMgr::getInstance()->getSelection()->getSelectedObjectRenderCost(); + LLResMgr::getInstance()->getIntegerString(prim_cost_string, cost); getChild("RenderingCost")->setTextArg("[COUNT]", prim_cost_string); } @@ -1037,35 +1038,6 @@ void LLFloaterTools::onClickGridOptions() //floaterp->addDependentFloater(LLFloaterBuildOptions::getInstance(), FALSE); } -S32 LLFloaterTools::calcRenderCost() -{ - S32 cost = 0; - std::set textures; - - for (LLObjectSelection::iterator selection_iter = LLSelectMgr::getInstance()->getSelection()->begin(); - selection_iter != LLSelectMgr::getInstance()->getSelection()->end(); - ++selection_iter) - { - LLSelectNode *select_node = *selection_iter; - if (select_node) - { - LLViewerObject *vobj = select_node->getObject(); - if (vobj->getVolume()) - { - LLVOVolume* volume = (LLVOVolume*) vobj; - - cost += volume->getRenderCost(textures); - cost += textures.size() * LLVOVolume::ARC_TEXTURE_COST; - textures.clear(); - } - } - } - - - return cost; -} - - // static void LLFloaterTools::setEditTool(void* tool_pointer) { diff --git a/indra/newview/llfloatertools.h b/indra/newview/llfloatertools.h index 87c3d2ab47..d5595445e0 100644 --- a/indra/newview/llfloatertools.h +++ b/indra/newview/llfloatertools.h @@ -114,7 +114,6 @@ private: static bool multipleFacesSelectedConfirm(const LLSD& notification, const LLSD& response); static void setObjectType( LLPCode pcode ); void onClickGridOptions(); - S32 calcRenderCost(); public: LLButton *mBtnFocus; diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index 93c9131424..90c2cf1eb4 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -6391,7 +6391,7 @@ U32 LLObjectSelection::getSelectedObjectTriangleCount() return count; } -/*S32 LLObjectSelection::getSelectedObjectRenderCost() +S32 LLObjectSelection::getSelectedObjectRenderCost() { S32 cost = 0; LLVOVolume::texture_cost_t textures; @@ -6415,7 +6415,7 @@ U32 LLObjectSelection::getSelectedObjectTriangleCount() return cost; -}*/ +} //----------------------------------------------------------------------------- diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index a257703b24..950d050f26 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -8241,7 +8241,7 @@ void LLVOAvatar::getImpostorValues(LLVector4a* extents, LLVector3& angle, F32& d void LLVOAvatar::idleUpdateRenderCost() { - static const U32 ARC_BODY_PART_COST = 20; + static const U32 ARC_BODY_PART_COST = 200; static const U32 ARC_LIMIT = 2048; static std::set all_textures; @@ -8252,7 +8252,7 @@ void LLVOAvatar::idleUpdateRenderCost() } U32 cost = 0; - std::set textures; + LLVOVolume::texture_cost_t textures; for (U8 baked_index = 0; baked_index < BAKED_NUM_INDICES; baked_index++) { @@ -8293,15 +8293,21 @@ void LLVOAvatar::idleUpdateRenderCost() } + for (LLVOVolume::texture_cost_t::iterator iter = textures.begin(); iter != textures.end(); ++iter) + { + // add the cost of each individual texture in the linkset + cost += iter->second; + } + // Diagnostic output to identify all avatar-related textures. // Does not affect rendering cost calculation. // Could be wrapped in a debug option if output becomes problematic. if (isSelf()) { // print any attachment textures we didn't already know about. - for (std::set::iterator it = textures.begin(); it != textures.end(); ++it) + for (LLVOVolume::texture_cost_t::iterator it = textures.begin(); it != textures.end(); ++it) { - LLUUID image_id = *it; + LLUUID image_id = it->first; if( image_id.isNull() || image_id == IMG_DEFAULT || image_id == IMG_DEFAULT_AVATAR) continue; if (all_textures.find(image_id) == all_textures.end()) @@ -8333,8 +8339,6 @@ void LLVOAvatar::idleUpdateRenderCost() } } - cost += textures.size() * LLVOVolume::ARC_TEXTURE_COST; - setDebugText(llformat("%d", cost)); F32 green = 1.f-llclamp(((F32) cost-(F32)ARC_LIMIT)/(F32)ARC_LIMIT, 0.f, 1.f); F32 red = llmin((F32) cost/(F32)ARC_LIMIT, 1.f); diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index be987a2310..01027e6a11 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -2931,24 +2931,35 @@ const LLMatrix4 LLVOVolume::getRenderMatrix() const // total cost is returned value + 5 * size of the resulting set. // Cannot include cost of textures, as they may be re-used in linked // children, and cost should only be increased for unique textures -Nyx -U32 LLVOVolume::getRenderCost(std::set &textures) const +U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const { - // base cost of each prim should be 10 points - static const U32 ARC_PRIM_COST = 10; + // Get access to params we'll need at various points. + // Skip if this is object doesn't have a volume (e.g. is an avatar). + BOOL has_volume = (getVolume() != NULL); + LLVolumeParams volume_params; + LLPathParams path_params; + LLProfileParams profile_params; + + U32 num_triangles = 0; + // per-prim costs - static const U32 ARC_INVISI_COST = 1; - static const U32 ARC_SHINY_COST = 1; - static const U32 ARC_GLOW_COST = 1; - static const U32 ARC_FLEXI_COST = 8; - static const U32 ARC_PARTICLE_COST = 16; - static const U32 ARC_BUMP_COST = 4; + static const U32 ARC_PARTICLE_COST = 1; + static const U32 ARC_PARTICLE_MAX = 2048; + static const U32 ARC_TEXTURE_COST = 5; - // per-face costs - static const U32 ARC_PLANAR_COST = 1; - static const U32 ARC_ANIM_TEX_COST = 4; - static const U32 ARC_ALPHA_COST = 4; + // per-prim multipliers + static const F32 ARC_GLOW_MULT = 1.5f; // tested based on performance + static const F32 ARC_BUMP_MULT = 1.25f; // tested based on performance + static const F32 ARC_FLEXI_MULT = 4; + static const F32 ARC_SHINY_MULT = 1.6f; // tested based on performance + static const F32 ARC_INVISI_COST = 1.2f; // tested based on performance + static const F32 ARC_WEIGHTED_MESH = 1.2f; - U32 shame = ARC_PRIM_COST; + static const F32 ARC_PLANAR_COST = 1.2f; // 1.2x max + static const F32 ARC_ANIM_TEX_COST = 1.4f; // 1.4x max + static const F32 ARC_ALPHA_COST = 4.f; // 4x max + + F32 shame = 0; U32 invisi = 0; U32 shiny = 0; @@ -2957,9 +2968,87 @@ U32 LLVOVolume::getRenderCost(std::set &textures) const U32 flexi = 0; U32 animtex = 0; U32 particles = 0; - U32 scale = 0; U32 bump = 0; U32 planar = 0; + U32 weighted_mesh = 0; + + // these multipliers are variable and can be floating point + F32 scale = 0.f; + + const LLDrawable* drawablep = mDrawable; + U32 num_faces = drawablep->getNumFaces(); + + if (has_volume) + { + volume_params = getVolume()->getParams(); + path_params = volume_params.getPathParams(); + profile_params = volume_params.getProfileParams(); + + F32 radius = getVolume()->mLODScaleBias.scaledVec(getScale()).length(); + S32 default_detail = llclamp((S32) (sqrtf(radius)*LLVOVolume::sLODFactor*4.f), 0, 3); + if (default_detail == getLOD()) + { + num_triangles = getTriangleCount(); + } + else + { + LLVolume* default_volume = LLPrimitive::getVolumeManager()->refVolume(volume_params, default_detail); + if(default_volume != NULL) + { + num_triangles = default_volume->getNumTriangles(); + LLPrimitive::getVolumeManager()->unrefVolume(default_volume); + default_volume = NULL; + } + else + { + has_volume = false; + } + } + } + + if (isSculpted()) + { + if (isMesh()) + { + // base cost is dependent on mesh complexity + // note that 3 is the highest LOD as of the time of this coding. + S32 size = gMeshRepo.getMeshSize(volume_params.getSculptID(),3); + if ( size > 0) + { + num_triangles = (U32)(size / 10.f); // avg 1 triangle per 10 bytes + if (gMeshRepo.getSkinInfo(volume_params.getSculptID())) + { + // weighted attachment - 1 point for every 3 bytes + weighted_mesh = 1; + } + + if (num_triangles == 0) + { + // someone made a really tiny mesh. Approximate with a tetrahedron. + num_triangles = 4; + } + } + else + { + // something went wrong - user should know their content isn't render-free + return 0; + } + } + else + { + const LLSculptParams *sculpt_params = (LLSculptParams *) getParameterEntry(LLNetworkData::PARAMS_SCULPT); + LLUUID sculpt_id = sculpt_params->getSculptTexture(); + if (textures.find(sculpt_id) == textures.end()) + { + LLViewerFetchedTexture *texture = LLViewerTextureManager::getFetchedTexture(sculpt_id); + if (texture) + { + S32 texture_cost = (S32)(ARC_TEXTURE_COST * (texture->getFullHeight() / 128.f + texture->getFullWidth() / 128.f + 1)); + textures.insert(texture_cost_t::value_type(sculpt_id, texture_cost)); + } + } + } + } if (isFlexible()) { @@ -2971,18 +3060,12 @@ U32 LLVOVolume::getRenderCost(std::set &textures) const } const LLVector3& sc = getScale(); - scale += (U32) sc.mV[0] + (U32) sc.mV[1] + (U32) sc.mV[2]; - - const LLDrawable* drawablep = mDrawable; + scale += (sc.mV[0] + sc.mV[1] + sc.mV[2]) / 4.f; // scale to 1/4 the sum of the size + // enforce scale multiplier to be in the range [1,7] (7 was determined to experimentally be a reasonable max) + scale = scale > 7.f ? 7.f : scale; + scale = scale < 1.f ? 1.f : scale; - if (isSculpted()) - { - const LLSculptParams *sculpt_params = (LLSculptParams *) getParameterEntry(LLNetworkData::PARAMS_SCULPT); - LLUUID sculpt_id = sculpt_params->getSculptTexture(); - textures.insert(sculpt_id); - } - - for (S32 i = 0; i < drawablep->getNumFaces(); ++i) + for (S32 i = 0; i < num_faces; ++i) { const LLFace* face = drawablep->getFace(i); const LLTextureEntry* te = face->getTextureEntry(); @@ -2990,12 +3073,16 @@ U32 LLVOVolume::getRenderCost(std::set &textures) const if (img) { - textures.insert(img->getID()); + if (textures.find(img->getID()) == textures.end()) + { + S32 texture_cost = (S32)(ARC_TEXTURE_COST * (img->getFullHeight() / 128.f + img->getFullWidth() / 128.f + 1)); + textures.insert(texture_cost_t::value_type(img->getID(), texture_cost)); + } } if (face->getPoolType() == LLDrawPool::POOL_ALPHA) { - alpha++; + alpha = 1; } else if (img && img->getPrimaryFormat() == GL_ALPHA) { @@ -3006,58 +3093,98 @@ U32 LLVOVolume::getRenderCost(std::set &textures) const { if (te->getBumpmap()) { + // bump is a multiplier, don't add per-face bump = 1; } if (te->getShiny()) { + // shiny is a multiplier, don't add per-face shiny = 1; } if (te->getGlow() > 0.f) { + // glow is a multiplier, don't add per-face glow = 1; } if (face->mTextureMatrix != NULL) { - animtex++; + animtex = 1; } if (te->getTexGen()) { - planar++; + planar = 1; } } } + // shame currently has the "base" cost of 1 point per 50 triangles, min 2. + shame = num_triangles / 50.f; + shame = shame < 2.f ? 2.f : shame; - shame += invisi * ARC_INVISI_COST; - shame += shiny * ARC_SHINY_COST; - shame += glow * ARC_GLOW_COST; - shame += alpha * ARC_ALPHA_COST; - shame += flexi * ARC_FLEXI_COST; - shame += animtex * ARC_ANIM_TEX_COST; - shame += particles * ARC_PARTICLE_COST; - shame += bump * ARC_BUMP_COST; - shame += planar * ARC_PLANAR_COST; - shame += scale; + // factor in scale + shame *= scale; - LLViewerObject::const_child_list_t& child_list = getChildren(); - for (LLViewerObject::child_list_t::const_iterator iter = child_list.begin(); - iter != child_list.end(); - ++iter) + // multiply by per-face modifiers + if (planar) { - const LLViewerObject* child_objectp = *iter; - const LLDrawable* child_drawablep = child_objectp->mDrawable; - if (child_drawablep) - { - const LLVOVolume* child_volumep = child_drawablep->getVOVolume(); - if (child_volumep) - { - shame += child_volumep->getRenderCost(textures); - } - } + shame *= planar * ARC_PLANAR_COST; + } + + if (animtex) + { + shame *= animtex * ARC_ANIM_TEX_COST; + } + + if (alpha) + { + shame *= alpha * ARC_ALPHA_COST; + } + + if(invisi) + { + shame *= invisi * ARC_INVISI_COST; + } + + if (glow) + { + shame *= glow * ARC_GLOW_MULT; + } + + if (bump) + { + shame *= bump * ARC_BUMP_MULT; + } + + if (shiny) + { + shame *= shiny * ARC_SHINY_MULT; } - return shame; + // multiply shame by multipliers + if (weighted_mesh) + { + shame *= weighted_mesh * ARC_WEIGHTED_MESH; + } + + if (flexi) + { + shame *= flexi * ARC_FLEXI_MULT; + } + + + // add additional costs + if (particles) + { + const LLPartSysData *part_sys_data = &(mPartSourcep->mPartSysData); + const LLPartData *part_data = &(part_sys_data->mPartData); + U32 num_particles = (U32)(part_sys_data->mBurstPartCount * llceil( part_data->mMaxAge / part_sys_data->mBurstRate)); + num_particles = num_particles > ARC_PARTICLE_MAX ? ARC_PARTICLE_MAX : num_particles; + F32 part_size = (llmax(part_data->mStartScale[0], part_data->mEndScale[0]) + llmax(part_data->mStartScale[1], part_data->mEndScale[1])) / 2.f; + shame += num_particles * part_size * ARC_PARTICLE_COST; + } + + return (U32)shame; } F32 LLVOVolume::getStreamingCost() diff --git a/indra/newview/llvovolume.h b/indra/newview/llvovolume.h index 0c12f14832..e02a5d5675 100644 --- a/indra/newview/llvovolume.h +++ b/indra/newview/llvovolume.h @@ -129,7 +129,8 @@ public: const LLMatrix4& getRelativeXform() const { return mRelativeXform; } const LLMatrix3& getRelativeXformInvTrans() const { return mRelativeXformInvTrans; } /*virtual*/ const LLMatrix4 getRenderMatrix() const; - U32 getRenderCost(std::set &textures) const; + typedef std::map texture_cost_t; + U32 getRenderCost(texture_cost_t &textures) const; /*virtual*/ F32 getStreamingCost(); /*virtual*/ U32 getTriangleCount() const; /*virtual*/ BOOL lineSegmentIntersect(const LLVector3& start, const LLVector3& end, @@ -358,8 +359,6 @@ public: static LLPointer sObjectMediaClient; static LLPointer sObjectMediaNavigateClient; - static const U32 ARC_TEXTURE_COST = 5; - protected: static S32 sNumLODChanges; -- cgit v1.2.3 From c10494e370f6399deea835964760628b14f7e299 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 16 Feb 2011 15:32:48 -0500 Subject: SH-997 FIX verify texture performance stats Got some better, reproducible numbers, which puts 32x32 textures at 538 points and 1024x1024 textures at 1024 points. --- indra/newview/llfloatertools.cpp | 3 ++- indra/newview/llvovolume.cpp | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index ceaf3c1449..1410facb53 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -427,7 +427,8 @@ void LLFloaterTools::refresh() if (sShowObjectCost) { std::string prim_cost_string; - LLResMgr::getInstance()->getIntegerString(prim_cost_string, calcRenderCost()); + S32 cost = LLSelectMgr::getInstance()->getSelection()->getSelectedObjectRenderCost(); + LLResMgr::getInstance()->getIntegerString(prim_cost_string, cost); getChild("RenderingCost")->setTextArg("[COUNT]", prim_cost_string); } diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 01027e6a11..7703019f99 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -2945,7 +2945,7 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const // per-prim costs static const U32 ARC_PARTICLE_COST = 1; static const U32 ARC_PARTICLE_MAX = 2048; - static const U32 ARC_TEXTURE_COST = 5; + static const U32 ARC_TEXTURE_COST = 32; // per-prim multipliers static const F32 ARC_GLOW_MULT = 1.5f; // tested based on performance @@ -3043,7 +3043,7 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const LLViewerFetchedTexture *texture = LLViewerTextureManager::getFetchedTexture(sculpt_id); if (texture) { - S32 texture_cost = (S32)(ARC_TEXTURE_COST * (texture->getFullHeight() / 128.f + texture->getFullWidth() / 128.f + 1)); + S32 texture_cost = 512 + (S32)(ARC_TEXTURE_COST * (texture->getFullHeight() / 128.f + texture->getFullWidth() / 128.f)); textures.insert(texture_cost_t::value_type(sculpt_id, texture_cost)); } } @@ -3075,7 +3075,7 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const { if (textures.find(img->getID()) == textures.end()) { - S32 texture_cost = (S32)(ARC_TEXTURE_COST * (img->getFullHeight() / 128.f + img->getFullWidth() / 128.f + 1)); + S32 texture_cost = 512 + (S32)(ARC_TEXTURE_COST * (img->getFullHeight() / 128.f + img->getFullWidth() / 128.f)); textures.insert(texture_cost_t::value_type(img->getID(), texture_cost)); } } -- cgit v1.2.3 From 24c353a1ad00366b9f4ce57492059ce8caf84ba0 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Tue, 22 Feb 2011 17:29:38 -0500 Subject: first pass at clouding avatars that are too complex --- indra/newview/llviewercontrol.cpp | 6 ++++++ indra/newview/llvoavatar.cpp | 16 ++++++++++++++++ indra/newview/llvoavatar.h | 2 ++ indra/newview/llvovolume.cpp | 10 +++++----- 4 files changed, 29 insertions(+), 5 deletions(-) diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index e319eba0ee..d99f3b6c88 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -165,6 +165,11 @@ static bool handleRenderPerfTestChanged(const LLSD& newvalue) return true; } +bool handleRenderAvatarComplexityLimitChanged(const LLSD& newvalue) +{ + return true; +} + bool handleRenderTransparentWaterChanged(const LLSD& newvalue) { LLWorld::getInstance()->updateWaterObjects(); @@ -586,6 +591,7 @@ void settings_setup_listeners() gSavedSettings.getControl("WindLightUseAtmosShaders")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _2)); gSavedSettings.getControl("RenderGammaFull")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _2)); gSavedSettings.getControl("RenderAvatarMaxVisible")->getSignal()->connect(boost::bind(&handleAvatarMaxVisibleChanged, _2)); + gSavedSettings.getControl("RenderAvatarComplexityLimit")->getSignal()->connect(boost::bind(&handleRenderAvatarComplexityLimitChanged, _2)); gSavedSettings.getControl("RenderVolumeLODFactor")->getSignal()->connect(boost::bind(&handleVolumeLODChanged, _2)); gSavedSettings.getControl("RenderAvatarLODFactor")->getSignal()->connect(boost::bind(&handleAvatarLODChanged, _2)); gSavedSettings.getControl("RenderTerrainLODFactor")->getSignal()->connect(boost::bind(&handleTerrainLODChanged, _2)); diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 856c068a44..be65af1e71 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -6307,6 +6307,11 @@ BOOL LLVOAvatar::getIsCloud() { return TRUE; } + + if (isTooComplex()) + { + return TRUE; + } return FALSE; } @@ -6401,6 +6406,16 @@ BOOL LLVOAvatar::isFullyLoaded() const return mFullyLoaded; } +bool LLVOAvatar::isTooComplex() const +{ + if (gSavedSettings.getS32("RenderAvatarComplexityLimit") > 0 && mVisualComplexity >= gSavedSettings.getS32("RenderAvatarComplexityLimit")) + { + return true; + } + + return false; +} + //----------------------------------------------------------------------------- // findMotion() @@ -8338,6 +8353,7 @@ void LLVOAvatar::idleUpdateRenderCost() } setDebugText(llformat("%d", cost)); + mVisualComplexity = cost; F32 green = 1.f-llclamp(((F32) cost-(F32)ARC_LIMIT)/(F32)ARC_LIMIT, 0.f, 1.f); F32 red = llmin((F32) cost/(F32)ARC_LIMIT, 1.f); mText->setColor(LLColor4(red,green,0,1)); diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h index 1152475383..f41c385894 100644 --- a/indra/newview/llvoavatar.h +++ b/indra/newview/llvoavatar.h @@ -263,6 +263,7 @@ public: //-------------------------------------------------------------------- public: BOOL isFullyLoaded() const; + bool isTooComplex() const; bool visualParamWeightsAreDefault(); protected: virtual BOOL getIsCloud(); @@ -275,6 +276,7 @@ private: BOOL mPreviousFullyLoaded; BOOL mFullyLoadedInitialized; S32 mFullyLoadedFrameCounter; + S32 mVisualComplexity; LLFrameTimer mFullyLoadedTimer; LLFrameTimer mRuthTimer; protected: diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index e3dea5c788..f5b31d25ac 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -2943,9 +2943,9 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const U32 num_triangles = 0; // per-prim costs - static const U32 ARC_PARTICLE_COST = 1; - static const U32 ARC_PARTICLE_MAX = 2048; - static const U32 ARC_TEXTURE_COST = 32; + static const U32 ARC_PARTICLE_COST = 1; // determined experimentally + static const U32 ARC_PARTICLE_MAX = 2048; // default values + static const U32 ARC_TEXTURE_COST = 32; // multiplier for texture resolution - performance tested // per-prim multipliers static const F32 ARC_GLOW_MULT = 1.5f; // tested based on performance @@ -2955,9 +2955,9 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const static const F32 ARC_INVISI_COST = 1.2f; // tested based on performance static const F32 ARC_WEIGHTED_MESH = 1.2f; - static const F32 ARC_PLANAR_COST = 1.2f; // 1.2x max + static const F32 ARC_PLANAR_COST = 1.0f; // tested based on performance to have negligible impact static const F32 ARC_ANIM_TEX_COST = 1.4f; // 1.4x max - static const F32 ARC_ALPHA_COST = 4.f; // 4x max + static const F32 ARC_ALPHA_COST = 4.f; // 4x max - based on performance F32 shame = 0; -- cgit v1.2.3 From d06cab548d7e4daa7a120692f64c10c05927143f Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 23 Feb 2011 12:56:05 -0500 Subject: forgot to add the new setting to settings.xml --- indra/newview/app_settings/settings.xml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index d71b84739c..1bae39d5d7 100755 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -7046,7 +7046,18 @@ Value 1 - RenderAvatarLODFactor + RenderAvatarComplexityLimit + + Comment + Max visual complexity of avatars in a scens + Persist + 1 + Type + S32 + Value + -1 + + RenderAvatarLODFactor Comment Controls level of detail of avatars (multiplier for current screen area when calculated level of detail) -- cgit v1.2.3 From 77fff26431671ffef8cf482044b1fcd98262d3e0 Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Wed, 23 Feb 2011 17:21:54 -0500 Subject: suppressing particles in overly complex avatars when clouding - they should appear as white spheres. --- indra/newview/llvoavatar.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index be65af1e71..7dadf34a2a 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -2716,7 +2716,10 @@ void LLVOAvatar::idleUpdateLoadingEffect() LLPartData::LL_PART_EMISSIVE_MASK | // LLPartData::LL_PART_FOLLOW_SRC_MASK | LLPartData::LL_PART_TARGET_POS_MASK ); - setParticleSource(particle_parameters, getID()); + if (!isTooComplex()) // do not generate particles for overly-complex avatars + { + setParticleSource(particle_parameters, getID()); + } } } } -- cgit v1.2.3 From 29dc641fbe7ab77f77fe19e2e7976980f0649b5b Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Tue, 22 Mar 2011 20:39:31 -0400 Subject: initial effort to enable a debug display to show render complexity. Using for internal demo, will get it code reviewed if it merges in. --- indra/newview/llspatialpartition.cpp | 38 ++++++++++++++++++++++ indra/newview/llviewermenu.cpp | 4 +++ indra/newview/llviewerobjectlist.cpp | 4 +++ indra/newview/llvovolume.cpp | 18 ++++++++-- indra/newview/llvovolume.h | 10 +++++- indra/newview/pipeline.h | 1 + indra/newview/skins/default/xui/en/menu_viewer.xml | 10 ++++++ .../skins/default/xui/en/panel_region_terrain.xml | 34 +++++++++++++++++++ 8 files changed, 116 insertions(+), 3 deletions(-) diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 5e7af6bbb3..b604908474 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -2792,6 +2792,40 @@ void renderUpdateType(LLDrawable* drawablep) } } +void renderComplexityDisplay(LLDrawable* drawablep) +{ + LLViewerObject* vobj = drawablep->getVObj(); + if (!vobj) + { + return; + } + + LLVOVolume *voVol = dynamic_cast(vobj); + + if (!voVol) + { + return; + } + + LLVOVolume::texture_cost_t textures; + F32 cost = (F32) voVol->getRenderCost(textures) / (F32) LLVOVolume::getRenderComplexityMax(); + + LLGLEnable blend(GL_BLEND); + + F32 red = cost; + F32 green = 1.0f - cost; + + glColor4f(red,green,0,0.5f); + + S32 num_faces = drawablep->getNumFaces(); + if (num_faces) + { + for (S32 i = 0; i < num_faces; ++i) + { + pushVerts(drawablep->getFace(i), LLVertexBuffer::MAP_VERTEX); + } + } +} void renderBoundingBox(LLDrawable* drawable, BOOL set_color = TRUE) { @@ -3906,6 +3940,10 @@ public: { renderUpdateType(drawable); } + if(gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_RENDER_COMPLEXITY)) + { + renderComplexityDisplay(drawable); + } LLVOAvatar* avatar = dynamic_cast(drawable->getVObj().get()); diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index f5b0857425..30be2fb8e0 100755 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -993,6 +993,10 @@ U32 info_display_from_string(std::string info_display) { return LLPipeline::RENDER_DEBUG_AGENT_TARGET; } + else if ("" == info_display) + { + return LLPipeline::RENDER_DEBUG_RENDER_COMPLEXITY; + } else { return 0; diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp index 0071753831..2e8eb9f4a8 100644 --- a/indra/newview/llviewerobjectlist.cpp +++ b/indra/newview/llviewerobjectlist.cpp @@ -58,6 +58,7 @@ #include "llviewerregion.h" #include "llviewerstats.h" #include "llviewerstatsrecorder.h" +#include "llvovolume.h" #include "llvoavatarself.h" #include "lltoolmgr.h" #include "lltoolpie.h" @@ -997,6 +998,9 @@ void LLViewerObjectList::update(LLAgent &agent, LLWorld &world) mNumSizeCulled = 0; mNumVisCulled = 0; + // update max computed render cost + LLVOVolume::updateRenderComplexity(); + // compute all sorts of time-based stats // don't factor frames that were paused into the stats if (! mWasPaused) diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index e2d1850e58..7c772ce835 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -87,6 +87,8 @@ F32 LLVOVolume::sLODFactor = 1.f; F32 LLVOVolume::sLODSlopDistanceFactor = 0.5f; //Changing this to zero, effectively disables the LOD transition slop F32 LLVOVolume::sDistanceFactor = 1.0f; S32 LLVOVolume::sNumLODChanges = 0; +S32 LLVOVolume::mRenderComplexity_last = 0; +S32 LLVOVolume::mRenderComplexity_current = 0; LLPointer LLVOVolume::sObjectMediaClient = NULL; LLPointer LLVOVolume::sObjectMediaNavigateClient = NULL; @@ -3206,6 +3208,11 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const shame += num_particles * part_size * ARC_PARTICLE_COST; } + if (shame > mRenderComplexity_current) + { + mRenderComplexity_current = (S32)shame; + } + return (U32)shame; } @@ -3223,7 +3230,14 @@ F32 LLVOVolume::getStreamingCost() return 0.f; } -U32 LLVOVolume::getTriangleCount() +//static +void LLVOVolume::updateRenderComplexity() +{ + mRenderComplexity_last = mRenderComplexity_current; + mRenderComplexity_current = 0; +} + +U32 LLVOVolume::getTriangleCount() const { U32 count = 0; LLVolume* volume = getVolume(); @@ -4068,7 +4082,7 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group) if ( bindCnt > 0 ) { const int jointCnt = pSkinData->mJointNames.size(); - const int pelvisZOffset = pSkinData->mPelvisOffset; + const int pelvisZOffset = (int)pSkinData->mPelvisOffset; bool fullRig = (jointCnt>=20) ? true : false; if ( fullRig ) { diff --git a/indra/newview/llvovolume.h b/indra/newview/llvovolume.h index 5af88c6cbd..57faee556f 100644 --- a/indra/newview/llvovolume.h +++ b/indra/newview/llvovolume.h @@ -132,7 +132,7 @@ public: typedef std::map texture_cost_t; U32 getRenderCost(texture_cost_t &textures) const; /*virtual*/ F32 getStreamingCost(); - /*virtual*/ U32 getTriangleCount(); + /*virtual*/ U32 getTriangleCount() const; /*virtual*/ BOOL lineSegmentIntersect(const LLVector3& start, const LLVector3& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, @@ -320,11 +320,19 @@ protected: LLFace* addFace(S32 face_index); void updateTEData(); + // stats tracking for render complexity + static S32 mRenderComplexity_last; + static S32 mRenderComplexity_current; + void requestMediaDataUpdate(bool isNew); void cleanUpMediaImpls(); void addMediaImpl(LLViewerMediaImpl* media_impl, S32 texture_index) ; void removeMediaImpl(S32 texture_index) ; public: + + static S32 getRenderComplexityMax() {return mRenderComplexity_last;} + static void updateRenderComplexity(); + LLViewerTextureAnim *mTextureAnimp; U8 mTexAnimMode; private: diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h index be58af947c..02bb6d618e 100644 --- a/indra/newview/pipeline.h +++ b/indra/newview/pipeline.h @@ -448,6 +448,7 @@ public: RENDER_DEBUG_PHYSICS_SHAPES = 0x1000000, RENDER_DEBUG_NORMALS = 0x2000000, RENDER_DEBUG_LOD_INFO = 0x4000000, + RENDER_DEBUG_RENDER_COMPLEXITY = 0x8000000 }; public: diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml index ea40a08c95..7a227fb5f9 100644 --- a/indra/newview/skins/default/xui/en/menu_viewer.xml +++ b/indra/newview/skins/default/xui/en/menu_viewer.xml @@ -2338,6 +2338,16 @@ function="Advanced.ToggleInfoDisplay" parameter="raycast" /> + + + + + + + diff --git a/indra/newview/skins/default/xui/en/panel_region_terrain.xml b/indra/newview/skins/default/xui/en/panel_region_terrain.xml index bbb8b40594..5d060c0a0d 100644 --- a/indra/newview/skins/default/xui/en/panel_region_terrain.xml +++ b/indra/newview/skins/default/xui/en/panel_region_terrain.xml @@ -193,7 +193,7 @@ + -- cgit v1.2.3 From 02658d9725435ee14b21183365388deacb5e88e5 Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Thu, 1 Sep 2011 16:12:39 -0700 Subject: EXP-1001 FIX -- Newness is removed on next login if you log out or crash before opening inventory panel EXP-1148 FIX -- New Tags can show in incorrect locations when opening folder with drop down arrow in Received Items panel EXP-1163 FIX -- When ordering a Direct Delivery item in Basic Mode, item is not shown as new on login to Advanced mode EXP-1172 FIX -- New tags not displayed for items delivered while not logged in on next login to viewer EXP-1173 FIX -- New tags are removed for all new items when Inventory side panel is opened * New tag now set when an item folder is added to the inbox. * Update to new tag only happens when a valid date exists. * Inbox collapsed time now only set when inbox panel is in a visible chain. --- indra/newview/llpanelmarketplaceinbox.cpp | 2 +- indra/newview/llpanelmarketplaceinboxinventory.cpp | 40 +++++++++++++--------- indra/newview/llpanelmarketplaceinboxinventory.h | 4 +-- indra/newview/llsidepanelinventory.cpp | 6 ++-- indra/newview/llsidetray.cpp | 2 +- 5 files changed, 31 insertions(+), 23 deletions(-) diff --git a/indra/newview/llpanelmarketplaceinbox.cpp b/indra/newview/llpanelmarketplaceinbox.cpp index 5a835eadf1..a73742b68f 100644 --- a/indra/newview/llpanelmarketplaceinbox.cpp +++ b/indra/newview/llpanelmarketplaceinbox.cpp @@ -53,7 +53,7 @@ LLPanelMarketplaceInbox::LLPanelMarketplaceInbox(const Params& p) LLPanelMarketplaceInbox::~LLPanelMarketplaceInbox() { - if (getVisible() && getChild("inbox_btn")->getToggleState()) + if (isInVisibleChain() && getChild("inbox_btn")->getToggleState()) { gSavedPerAccountSettings.setString("LastInventoryInboxCollapse", LLDate::now().asString()); } diff --git a/indra/newview/llpanelmarketplaceinboxinventory.cpp b/indra/newview/llpanelmarketplaceinboxinventory.cpp index e2f8af1280..f6a4b6e26b 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceinboxinventory.cpp @@ -173,19 +173,6 @@ LLInboxFolderViewFolder::~LLInboxFolderViewFolder() { } -// virtual -time_t LLInboxFolderViewFolder::getCreationDate() const -{ - time_t ret_val = LLFolderViewFolder::getCreationDate(); - - if (!mCreationDate) - { - updateFlag(); - } - - return ret_val; -} - // virtual void LLInboxFolderViewFolder::draw() { @@ -201,32 +188,53 @@ void LLInboxFolderViewFolder::draw() LLFolderViewFolder::draw(); } +BOOL LLInboxFolderViewFolder::addToFolder(LLFolderViewFolder* folder, LLFolderView* root) +{ + BOOL retval = LLFolderViewFolder::addToFolder(folder, root); + + // Only mark top-level inbox folders as fresh + mFresh = (mParentFolder == mRoot); + + return retval; +} + void LLInboxFolderViewFolder::updateFlag() const { const std::string& last_collapse = gSavedPerAccountSettings.getString("LastInventoryInboxCollapse"); + if (!last_collapse.empty()) { LLDate saved_freshness_date = LLDate(last_collapse); + //llinfos << "Saved freshness: " << saved_freshness_date.secondsSinceEpoch() << llendl; + mFresh = (mCreationDate > saved_freshness_date.secondsSinceEpoch()); + + //llinfos << " Creation date: " << mCreationDate << " -- fresh -- " << mFresh << " -- this -- " << (void*)&*(this) << llendl; } } void LLInboxFolderViewFolder::selectItem() { - mFresh = false; LLFolderViewFolder::selectItem(); + + mFresh = false; } void LLInboxFolderViewFolder::toggleOpen() { - mFresh = false; LLFolderViewFolder::toggleOpen(); + + mFresh = false; } void LLInboxFolderViewFolder::setCreationDate(time_t creation_date_utc) const { mCreationDate = creation_date_utc; - updateFlag(); + + if (mFresh) + { + updateFlag(); + } } // diff --git a/indra/newview/llpanelmarketplaceinboxinventory.h b/indra/newview/llpanelmarketplaceinboxinventory.h index 6cb243dbd5..06706539a0 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.h +++ b/indra/newview/llpanelmarketplaceinboxinventory.h @@ -73,10 +73,10 @@ public: LLInboxFolderViewFolder(const Params& p); ~LLInboxFolderViewFolder(); - time_t getCreationDate() const; - void draw(); + BOOL addToFolder(LLFolderViewFolder* folder, LLFolderView* root); + void updateFlag() const; void selectItem(); void toggleOpen(); diff --git a/indra/newview/llsidepanelinventory.cpp b/indra/newview/llsidepanelinventory.cpp index 9290b7ebef..a8a9f4948b 100644 --- a/indra/newview/llsidepanelinventory.cpp +++ b/indra/newview/llsidepanelinventory.cpp @@ -500,7 +500,7 @@ bool LLSidepanelInventory::manageInboxOutboxPanels(LLButton * pressedButton, LLL else { // NOTE: This is an attempt to reshape the inventory panel to the proper size but it doesn't seem to propagate - // propery to the child panels. + // properly to the child panels. S32 new_height = inout_panel->getRect().getHeight(); @@ -527,7 +527,7 @@ void LLSidepanelInventory::onToggleInboxBtn() bool inbox_expanded = manageInboxOutboxPanels(inboxButton, inboxPanel, outboxButton, outboxPanel); - if (!inbox_expanded && inboxPanel->getVisible()) + if (!inbox_expanded && inboxPanel->isInVisibleChain()) { gSavedPerAccountSettings.setString("LastInventoryInboxCollapse", LLDate::now().asString()); } @@ -543,7 +543,7 @@ void LLSidepanelInventory::onToggleOutboxBtn() bool inbox_was_expanded = inboxButton->getToggleState(); manageInboxOutboxPanels(outboxButton, outboxPanel, inboxButton, inboxPanel); - if (inbox_was_expanded && inboxPanel->getVisible()) + if (inbox_was_expanded && inboxPanel->isInVisibleChain()) { gSavedPerAccountSettings.setString("LastInventoryInboxCollapse", LLDate::now().asString()); } diff --git a/indra/newview/llsidetray.cpp b/indra/newview/llsidetray.cpp index 651897a217..363c8543ed 100644 --- a/indra/newview/llsidetray.cpp +++ b/indra/newview/llsidetray.cpp @@ -1442,7 +1442,7 @@ void LLSideTray::updateSidetrayVisibility() parent->setVisible(new_visibility); // Signal change of visible width. - llinfos << "Visible: " << new_visibility << llendl; + //llinfos << "Visible: " << new_visibility << llendl; mVisibleWidthChangeSignal(this, new_visibility); } } -- cgit v1.2.3 From 16b34829993c1d59aaeeeafaea68c9aa8e0a5035 Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Thu, 1 Sep 2011 16:47:14 -0700 Subject: * Changing inbox item "new" tag to off by default rather than on to eliminate false positives. --- indra/newview/llpanelmarketplaceinboxinventory.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/llpanelmarketplaceinboxinventory.cpp b/indra/newview/llpanelmarketplaceinboxinventory.cpp index f6a4b6e26b..e5fe2d0504 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceinboxinventory.cpp @@ -162,7 +162,7 @@ LLFolderViewItem * LLInboxInventoryPanel::createFolderViewItem(LLInvFVBridge * b LLInboxFolderViewFolder::LLInboxFolderViewFolder(const Params& p) : LLFolderViewFolder(p) , LLBadgeOwner(getHandle()) - , mFresh(true) + , mFresh(false) { #if SUPPORTING_FRESH_ITEM_COUNT initBadgeParams(p.new_badge()); -- cgit v1.2.3 From 5da2d4c85370ebe1a14ecbebd8e5df7965e9d02e Mon Sep 17 00:00:00 2001 From: Paul ProductEngine Date: Fri, 2 Sep 2011 17:14:07 +0300 Subject: SH-2309 WIP Priority modifications to mesh uploader UI - Changed representation of Retain% control values - Added "Choose one..." item to the LOD combo_box --- indra/newview/llfloatermodelpreview.cpp | 24 ++++++++++++++++------ .../skins/default/xui/en/floater_model_preview.xml | 2 ++ 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index 362a40632a..2d18c2bb24 100755 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -119,6 +119,7 @@ const S32 PREVIEW_RESIZE_HANDLE_SIZE = S32(RESIZE_HANDLE_WIDTH * OO_SQRT2) + PRE const S32 PREVIEW_HPAD = PREVIEW_RESIZE_HANDLE_SIZE; const S32 PREF_BUTTON_HEIGHT = 16 + 7 + 16; const S32 PREVIEW_TEXTURE_HEIGHT = 300; +const double RETAIN_COEFFICIENT = 100; void drawBoxOutline(const LLVector3& pos, const LLVector3& size); @@ -907,7 +908,15 @@ void LLFloaterModelPreview::onPhysicsParamCommit(LLUICtrl* ctrl, void* data) { LLCDParam* param = (LLCDParam*) data; std::string name(param->mName); - sInstance->mDecompParams[name] = ctrl->getValue(); + + LLSD value = ctrl->getValue(); + + if("Retain%" == name) + { + value = ctrl->getValue().asReal() / RETAIN_COEFFICIENT; + } + + sInstance->mDecompParams[name] = value; if (name == "Simplify Method") { @@ -980,7 +989,7 @@ void LLFloaterModelPreview::onPhysicsBrowse(LLUICtrl* ctrl, void* userdata) //static void LLFloaterModelPreview::onPhysicsUseLOD(LLUICtrl* ctrl, void* userdata) { - S32 num_modes = 3; + S32 num_modes = 4; S32 which_mode = 3; static S32 previous_mode = which_mode; @@ -1115,10 +1124,13 @@ void LLFloaterModelPreview::initDecompControls() } else if (LLSpinCtrl* spinner = dynamic_cast(ctrl)) { - spinner->setMinValue(param[i].mDetails.mRange.mLow.mFloat); - spinner->setMaxValue(param[i].mDetails.mRange.mHigh.mFloat); - spinner->setIncrement(param[i].mDetails.mRange.mDelta.mFloat); - spinner->setValue(param[i].mDefault.mFloat); + bool is_retain_ctrl = "Retain%" == name; + double coefficient = is_retain_ctrl ? RETAIN_COEFFICIENT : 1.f; + + spinner->setMinValue(param[i].mDetails.mRange.mLow.mFloat * coefficient); + spinner->setMaxValue(param[i].mDetails.mRange.mHigh.mFloat * coefficient); + spinner->setIncrement(param[i].mDetails.mRange.mDelta.mFloat * coefficient); + spinner->setValue(param[i].mDefault.mFloat * coefficient); spinner->setCommitCallback(onPhysicsParamCommit, (void*) ¶m[i]); } else if (LLComboBox* combo_box = dynamic_cast(ctrl)) diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml index d613e42786..39ef844824 100755 --- a/indra/newview/skins/default/xui/en/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml @@ -305,6 +305,7 @@ name="physics_lod_combo" width="130" tool_tip="LOD to use for physics shape"> + Choose one... High Medium Low @@ -521,6 +522,7 @@ width="60"/> Date: Fri, 2 Sep 2011 17:36:54 +0300 Subject: SH-2309 Model preview floater LoD tab updated. - Combo boxes for LoD source added for each level - New option "Use LoD above" added for copying the model from higher LoDs. - Various LoD settings and related controls removed. --- indra/newview/llfloatermodelpreview.cpp | 389 ++++------ indra/newview/llfloatermodelpreview.h | 17 +- .../skins/default/xui/en/floater_model_preview.xml | 790 ++++++++++++++++----- 3 files changed, 780 insertions(+), 416 deletions(-) diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index 2d18c2bb24..e687b1954c 100755 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -396,21 +396,23 @@ BOOL LLFloaterModelPreview::postBuild() return FALSE; } - childSetAction("lod_browse", onBrowseLOD, this); - childSetCommitCallback("cancel_btn", onCancel, this); childSetCommitCallback("crease_angle", onGenerateNormalsCommit, this); - childSetCommitCallback("generate_normals", onGenerateNormalsCommit, this); + getChild("gen_normals")->setCommitCallback(boost::bind(&LLFloaterModelPreview::toggleGenarateNormals, this)); childSetCommitCallback("lod_generate", onAutoFillCommit, this); - childSetCommitCallback("lod_mode", onLODParamCommit, this); - childSetCommitCallback("lod_error_threshold", onLODParamCommit, this); - childSetCommitCallback("lod_triangle_limit", onLODParamCommitTriangleLimit, this); - childSetCommitCallback("build_operator", onLODParamCommit, this); - childSetCommitCallback("queue_mode", onLODParamCommit, this); - childSetCommitCallback("border_mode", onLODParamCommit, this); - childSetCommitCallback("share_tolerance", onLODParamCommit, this); + for (S32 lod = 0; lod <= LLModel::LOD_HIGH; ++lod) + { + LLComboBox* lod_source_combo = getChild("lod_source_" + lod_name[lod]); + lod_source_combo->setCommitCallback(boost::bind(&LLFloaterModelPreview::onLoDSourceCommit, this, lod)); + lod_source_combo->setCurrentByIndex(mLODMode[lod]); + + getChild("lod_browse_" + lod_name[lod])->setCommitCallback(boost::bind(&LLFloaterModelPreview::onBrowseLOD, this, lod)); + getChild("lod_mode_" + lod_name[lod])->setCommitCallback(boost::bind(&LLFloaterModelPreview::onLODParamCommit, this, lod, false)); + getChild("lod_error_threshold_" + lod_name[lod])->setCommitCallback(boost::bind(&LLFloaterModelPreview::onLODParamCommit, this, lod, false)); + getChild("lod_triangle_limit_" + lod_name[lod])->setCommitCallback(boost::bind(&LLFloaterModelPreview::onLODParamCommit, this, lod, true)); + } childSetCommitCallback("upload_skin", boost::bind(&LLFloaterModelPreview::toggleCalculateButton, this), NULL); childSetCommitCallback("upload_joints", boost::bind(&LLFloaterModelPreview::toggleCalculateButton, this), NULL); @@ -431,10 +433,6 @@ BOOL LLFloaterModelPreview::postBuild() childSetCommitCallback("import_scale", onImportScaleCommit, this); childSetCommitCallback("pelvis_offset", onPelvisOffsetCommit, this); - childSetCommitCallback("lod_file_or_limit", refresh, this); - //childSetCommitCallback("physics_optimize", refresh, this); - //childSetCommitCallback("physics_use_hull", refresh, this); - getChild("show_edges")->setCommitCallback(boost::bind(&LLFloaterModelPreview::onViewOptionChecked, this, _1)); getChild("show_physics")->setCommitCallback(boost::bind(&LLFloaterModelPreview::onViewOptionChecked, this, _1)); getChild("show_textures")->setCommitCallback(boost::bind(&LLFloaterModelPreview::onViewOptionChecked, this, _1)); @@ -694,6 +692,12 @@ void LLFloaterModelPreview::onGenerateNormalsCommit(LLUICtrl* ctrl, void* userda fp->mModelPreview->generateNormals(); } +void LLFloaterModelPreview::toggleGenarateNormals() +{ + bool enabled = childGetValue("gen_normals").asBoolean(); + childSetEnabled("crease_angle", enabled); +} + //static void LLFloaterModelPreview::onExplodeCommit(LLUICtrl* ctrl, void* userdata) { @@ -710,19 +714,9 @@ void LLFloaterModelPreview::onAutoFillCommit(LLUICtrl* ctrl, void* userdata) fp->mModelPreview->genLODs(); } -//static -void LLFloaterModelPreview::onLODParamCommit(LLUICtrl* ctrl, void* userdata) -{ - LLFloaterModelPreview* fp = (LLFloaterModelPreview*) userdata; - - fp->mModelPreview->onLODParamCommit(false); -} - -//static -void LLFloaterModelPreview::onLODParamCommitTriangleLimit(LLUICtrl* ctrl, void* userdata) +void LLFloaterModelPreview::onLODParamCommit(S32 lod, bool enforce_tri_limit) { - LLFloaterModelPreview* fp = (LLFloaterModelPreview*) userdata; - fp->mModelPreview->onLODParamCommit(true); + mModelPreview->onLODParamCommit(lod, enforce_tri_limit); } @@ -3484,7 +3478,7 @@ void LLModelPreview::loadModel(std::string filename, S32 lod, bool force_disable if (lod == mPreviewLOD) { - mFMP->childSetText("lod_file", mLODFile[mPreviewLOD]); + mFMP->childSetText("lod_file_" + lod_name[lod], mLODFile[lod]); } else if (lod == LLModel::LOD_PHYSICS) { @@ -3782,21 +3776,21 @@ void LLModelPreview::genLODs(S32 which_lod, U32 decimation, bool enforce_tri_lim U32 lod_mode = 0; - LLCtrlSelectionInterface* iface = mFMP->childGetSelectionInterface("lod_mode"); + LLCtrlSelectionInterface* iface = mFMP->childGetSelectionInterface("lod_mode_" + lod_name[which_lod]); if (iface) { lod_mode = iface->getFirstSelectedIndex(); } mRequestedLoDMode[mPreviewLOD] = lod_mode; - F32 lod_error_threshold = mFMP->childGetValue("lod_error_threshold").asReal(); + F32 lod_error_threshold = mFMP->childGetValue("lod_error_threshold_" + lod_name[which_lod]).asReal(); if (lod_mode == 0) { lod_mode = GLOD_TRIANGLE_BUDGET; if (which_lod != -1) { - limit = mFMP->childGetValue("lod_triangle_limit").asInteger(); + limit = mFMP->childGetValue("lod_triangle_limit_" + lod_name[which_lod]).asInteger(); } } else @@ -3804,89 +3798,7 @@ void LLModelPreview::genLODs(S32 which_lod, U32 decimation, bool enforce_tri_lim lod_mode = GLOD_ERROR_THRESHOLD; } - U32 build_operator = 0; - - iface = mFMP->childGetSelectionInterface("build_operator"); - if (iface) - { - build_operator = iface->getFirstSelectedIndex(); - } - mRequestedBuildOperator[mPreviewLOD] = build_operator; - - if (build_operator == 0) - { - build_operator = GLOD_OPERATOR_EDGE_COLLAPSE; - } - else - { - build_operator = GLOD_OPERATOR_HALF_EDGE_COLLAPSE; - } - - U32 queue_mode=0; - iface = mFMP->childGetSelectionInterface("queue_mode"); - if (iface) - { - queue_mode = iface->getFirstSelectedIndex(); - } - mRequestedQueueMode[mPreviewLOD] = queue_mode; - - if (queue_mode == 0) - { - queue_mode = GLOD_QUEUE_GREEDY; - } - else if (queue_mode == 1) - { - queue_mode = GLOD_QUEUE_LAZY; - } - else - { - queue_mode = GLOD_QUEUE_INDEPENDENT; - } - - U32 border_mode = 0; - - iface = mFMP->childGetSelectionInterface("border_mode"); - if (iface) - { - border_mode = iface->getFirstSelectedIndex(); - } - mRequestedBorderMode[mPreviewLOD] = border_mode; - - if (border_mode == 0) - { - border_mode = GLOD_BORDER_UNLOCK; - } - else - { - border_mode = GLOD_BORDER_LOCK; - } - bool object_dirty = false; - if (border_mode != mBuildBorderMode) - { - mBuildBorderMode = border_mode; - object_dirty = true; - } - - if (queue_mode != mBuildQueueMode) - { - mBuildQueueMode = queue_mode; - object_dirty = true; - } - - if (build_operator != mBuildOperator) - { - mBuildOperator = build_operator; - object_dirty = true; - } - - F32 share_tolerance = mFMP->childGetValue("share_tolerance").asReal(); - if (share_tolerance != mBuildShareTolerance) - { - mBuildShareTolerance = share_tolerance; - object_dirty = true; - } - mRequestedShareTolerance[mPreviewLOD] = share_tolerance; if (mGroup == 0) { @@ -3936,18 +3848,6 @@ void LLModelPreview::genLODs(S32 which_lod, U32 decimation, bool enforce_tri_lim stop_gloderror(); } - glodObjectParameteri(mObject[mdl], GLOD_BUILD_OPERATOR, build_operator); - stop_gloderror(); - - glodObjectParameteri(mObject[mdl], GLOD_BUILD_QUEUE_MODE, queue_mode); - stop_gloderror(); - - glodObjectParameteri(mObject[mdl], GLOD_BUILD_BORDER_MODE, border_mode); - stop_gloderror(); - - glodObjectParameterf(mObject[mdl], GLOD_BUILD_SHARE_TOLERANCE, share_tolerance); - stop_gloderror(); - glodBuildObject(mObject[mdl]); stop_gloderror(); } @@ -4489,147 +4389,140 @@ void LLModelPreview::updateStatusMessages() } } + if (mFMP->childGetValue("physics_lod_combo").asString() == "From file") + { + mFMP->childEnable("physics_file"); + mFMP->childEnable("physics_browse"); + } + else + { + mFMP->childDisable("physics_file"); + mFMP->childDisable("physics_browse"); + } + + LLSpinCtrl* crease = mFMP->getChild("crease_angle"); + + if (mRequestedCreaseAngle[mPreviewLOD] == -1.f) + { + mFMP->childSetColor("crease_label", LLColor4::grey); + crease->forceSetValue(75.f); + } + else + { + mFMP->childSetColor("crease_label", LLColor4::white); + crease->forceSetValue(mRequestedCreaseAngle[mPreviewLOD]); + } + + mModelUpdatedSignal(true); + +} + +void LLModelPreview::updateLodControls(S32 lod) +{ const char* lod_controls[] = { - "lod_mode", - "lod_triangle_limit", - "lod_error_tolerance", - "build_operator_text", - "queue_mode_text", - "border_mode_text", - "share_tolerance_text", - "build_operator", - "queue_mode", - "border_mode", - "share_tolerance" + "lod_mode_", + "lod_triangle_limit_", }; const U32 num_lod_controls = sizeof(lod_controls)/sizeof(char*); const char* file_controls[] = { - "lod_browse", - "lod_file" + "lod_browse_", + "lod_file_", }; const U32 num_file_controls = sizeof(file_controls)/sizeof(char*); - if (fmp) + LLFloaterModelPreview* fmp = LLFloaterModelPreview::sInstance; + if (!fmp) return; + + LLComboBox* lod_combo = mFMP->findChild("lod_source_" + lod_name[lod]); + if (!lod_combo) return; + + S32 lod_mode = lod_combo->getCurrentIndex(); + if (lod_mode == 0) // LoD from file { - //enable/disable controls based on radio groups - if (mFMP->childGetValue("lod_from_file").asBoolean()) - { - fmp->mLODMode[mPreviewLOD] = 0; - for (U32 i = 0; i < num_file_controls; ++i) - { - mFMP->childEnable(file_controls[i]); - } + fmp->mLODMode[lod] = 0; + for (U32 i = 0; i < num_file_controls; ++i) + { + mFMP->childShow(file_controls[i] + lod_name[lod]); + } - for (U32 i = 0; i < num_lod_controls; ++i) - { - mFMP->childDisable(lod_controls[i]); - } + for (U32 i = 0; i < num_lod_controls; ++i) + { + mFMP->childHide(lod_controls[i] + lod_name[lod]); + } + } + else if (lod_mode == 2) // use LoD above + { + fmp->mLODMode[lod] = 2; + for (U32 i = 0; i < num_file_controls; ++i) + { + mFMP->childHide(file_controls[i] + lod_name[lod]); } - else if (mFMP->childGetValue("lod_none").asBoolean()) + + for (U32 i = 0; i < num_lod_controls; ++i) { - fmp->mLODMode[mPreviewLOD] = 2; - for (U32 i = 0; i < num_file_controls; ++i) - { - mFMP->childDisable(file_controls[i]); - } + mFMP->childHide(lod_controls[i] + lod_name[lod]); + } - for (U32 i = 0; i < num_lod_controls; ++i) - { - mFMP->childDisable(lod_controls[i]); - } + if (lod < LLModel::LOD_HIGH) + { + mModel[lod] = mModel[lod + 1]; + mScene[lod] = mScene[lod + 1]; + mVertexBuffer[lod].clear(); - if (!mModel[mPreviewLOD].empty()) + // Also update lower LoD + if (lod > LLModel::LOD_IMPOSTOR) { - mModel[mPreviewLOD].clear(); - mScene[mPreviewLOD].clear(); - mVertexBuffer[mPreviewLOD].clear(); - - //this can cause phasing issues with the UI, so reenter this function and return - updateStatusMessages(); - return; + updateLodControls(lod - 1); } } - else - { // auto generate, also the default case for wizard which has no radio selection - fmp->mLODMode[mPreviewLOD] = 1; + } + else // auto generate, the default case for all LoDs except High + { + fmp->mLODMode[lod] = 1; - //don't actually regenerate lod when refreshing UI - mLODFrozen = true; + //don't actually regenerate lod when refreshing UI + mLODFrozen = true; - for (U32 i = 0; i < num_file_controls; ++i) - { - mFMP->childDisable(file_controls[i]); - } + for (U32 i = 0; i < num_file_controls; ++i) + { + mFMP->childHide(file_controls[i] + lod_name[lod]); + } - for (U32 i = 0; i < num_lod_controls; ++i) - { - mFMP->childEnable(lod_controls[i]); - } + for (U32 i = 0; i < num_lod_controls; ++i) + { + mFMP->childShow(lod_controls[i] + lod_name[lod]); + } - //if (threshold) - { - LLSpinCtrl* threshold = mFMP->getChild("lod_error_threshold"); - LLSpinCtrl* limit = mFMP->getChild("lod_triangle_limit"); - limit->setMaxValue(mMaxTriangleLimit); - limit->forceSetValue(mRequestedTriangleCount[mPreviewLOD]); + LLSpinCtrl* threshold = mFMP->getChild("lod_error_threshold_" + lod_name[lod]); + LLSpinCtrl* limit = mFMP->getChild("lod_triangle_limit_" + lod_name[lod]); - threshold->forceSetValue(mRequestedErrorThreshold[mPreviewLOD]); + limit->setMaxValue(mMaxTriangleLimit); + limit->forceSetValue(mRequestedTriangleCount[lod]); - mFMP->getChild("lod_mode")->selectNthItem(mRequestedLoDMode[mPreviewLOD]); - mFMP->getChild("build_operator")->selectNthItem(mRequestedBuildOperator[mPreviewLOD]); - mFMP->getChild("queue_mode")->selectNthItem(mRequestedQueueMode[mPreviewLOD]); - mFMP->getChild("border_mode")->selectNthItem(mRequestedBorderMode[mPreviewLOD]); - mFMP->getChild("share_tolerance")->setValue(mRequestedShareTolerance[mPreviewLOD]); + threshold->forceSetValue(mRequestedErrorThreshold[lod]); - if (mRequestedLoDMode[mPreviewLOD] == 0) - { - limit->setVisible(true); - threshold->setVisible(false); + mFMP->getChild("lod_mode_" + lod_name[lod])->selectNthItem(mRequestedLoDMode[lod]); - limit->setMaxValue(mMaxTriangleLimit); - limit->setIncrement(mMaxTriangleLimit/32); - } - else - { - limit->setVisible(false); - threshold->setVisible(true); - } - } + if (mRequestedLoDMode[lod] == 0) + { + limit->setVisible(true); + threshold->setVisible(false); - mLODFrozen = false; + limit->setMaxValue(mMaxTriangleLimit); + limit->setIncrement(mMaxTriangleLimit/32); + } + else + { + limit->setVisible(false); + threshold->setVisible(true); } - } - - if (mFMP->childGetValue("physics_lod_combo").asString() == "From file") - { - mFMP->childEnable("physics_file"); - mFMP->childEnable("physics_browse"); - } - else - { - mFMP->childDisable("physics_file"); - mFMP->childDisable("physics_browse"); - } - LLSpinCtrl* crease = mFMP->getChild("crease_angle"); - - if (mRequestedCreaseAngle[mPreviewLOD] == -1.f) - { - mFMP->childSetColor("crease_label", LLColor4::grey); - crease->forceSetValue(75.f); - } - else - { - mFMP->childSetColor("crease_label", LLColor4::white); - crease->forceSetValue(mRequestedCreaseAngle[mPreviewLOD]); + mLODFrozen = false; } - - mModelUpdatedSignal(true); - } void LLModelPreview::setPreviewTarget(F32 distance) @@ -5484,8 +5377,7 @@ void LLModelPreview::setPreviewLOD(S32 lod) LLComboBox* combo_box = mFMP->getChild("preview_lod_combo"); combo_box->setCurrentByIndex((NUM_LOD-1)-mPreviewLOD); // combo box list of lods is in reverse order - mFMP->childSetTextArg("lod_table_footer", "[DETAIL]", mFMP->getString(lod_name[mPreviewLOD])); - mFMP->childSetText("lod_file", mLODFile[mPreviewLOD]); + mFMP->childSetText("lod_file_" + lod_name[mPreviewLOD], mLODFile[mPreviewLOD]); // the wizard has three lod drop downs LLComboBox* combo_box2 = mFMP->getChild("preview_lod_combo2"); @@ -5506,25 +5398,16 @@ void LLModelPreview::setPreviewLOD(S32 lod) mFMP->childSetColor(lod_triangles_name[i], color); mFMP->childSetColor(lod_vertices_name[i], color); } - - LLFloaterModelPreview* fmp = LLFloaterModelPreview::sInstance; - if (fmp) - { - LLRadioGroup* radio = fmp->getChild("lod_file_or_limit"); - radio->selectNthItem(fmp->mLODMode[mPreviewLOD]); - } } refresh(); updateStatusMessages(); } -//static -void LLFloaterModelPreview::onBrowseLOD(void* data) +void LLFloaterModelPreview::onBrowseLOD(S32 lod) { assert_main_thread(); - LLFloaterModelPreview* mp = (LLFloaterModelPreview*) data; - mp->loadModel(mp->mModelPreview->mPreviewLOD); + loadModel(lod); } //static @@ -5566,8 +5449,7 @@ void LLFloaterModelPreview::onUpload(void* user_data) } -//static -void LLFloaterModelPreview::refresh(LLUICtrl* ctrl, void* user_data) +void LLFloaterModelPreview::refresh() { sInstance->toggleCalculateButton(true); sInstance->mModelPreview->mDirty = true; @@ -5588,11 +5470,12 @@ void LLModelPreview::textureLoadedCallback( BOOL success, LLViewerFetchedTexture } } -void LLModelPreview::onLODParamCommit(bool enforce_tri_limit) +void LLModelPreview::onLODParamCommit(S32 lod, bool enforce_tri_limit) { if (!mLODFrozen) { - genLODs(mPreviewLOD, 3, enforce_tri_limit); + genLODs(lod, 3, enforce_tri_limit); + updateLodControls(lod); updateStatusMessages(); refresh(); } @@ -5655,6 +5538,12 @@ void LLFloaterModelPreview::toggleCalculateButton(bool visible) } } +void LLFloaterModelPreview::onLoDSourceCommit(S32 lod) +{ + mModelPreview->updateLodControls(lod); + refresh(); +} + void LLFloaterModelPreview::resetDisplayOptions() { std::map::iterator option_it = mModelPreview->mViewOption.begin(); diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h index f93d3b9482..d93940efc2 100644 --- a/indra/newview/llfloatermodelpreview.h +++ b/indra/newview/llfloatermodelpreview.h @@ -176,13 +176,13 @@ public: void setDetails(F32 x, F32 y, F32 z, F32 streaming_cost, F32 physics_cost); - static void onBrowseLOD(void* data); + void onBrowseLOD(S32 lod); static void onReset(void* data); static void onUpload(void* data); - static void refresh(LLUICtrl* ctrl, void* data); + void refresh(); void loadModel(S32 lod); void loadModel(S32 lod, const std::string& file_name, bool force_disable_slm = false); @@ -222,10 +222,12 @@ protected: static void onGenerateNormalsCommit(LLUICtrl*,void*); + void toggleGenarateNormals(); + static void onAutoFillCommit(LLUICtrl*,void*); - static void onLODParamCommit(LLUICtrl*,void*); - static void onLODParamCommitTriangleLimit(LLUICtrl*,void*); + void onLODParamCommit(S32 lod, bool enforce_tri_limit); + static void onExplodeCommit(LLUICtrl*, void*); static void onPhysicsParamCommit(LLUICtrl* ctrl, void* userdata); @@ -264,7 +266,7 @@ protected: //store which lod mode each LOD is using // 0 - load from file // 1 - auto generate - // 2 - None + // 2 - use LoD above S32 mLODMode[4]; LLMutex* mStatusLock; @@ -275,6 +277,8 @@ private: void onClickCalculateBtn(); void toggleCalculateButton(); + void onLoDSourceCommit(S32 lod); + // Toggles between "Calculate weights & fee" and "Upload" buttons. void toggleCalculateButton(bool visible); @@ -335,8 +339,9 @@ public: void saveUploadData(const std::string& filename, bool save_skinweights, bool save_joint_poisitions); void clearIncompatible(S32 lod); void updateStatusMessages(); + void updateLodControls(S32 lod); void clearGLODGroup(); - void onLODParamCommit(bool enforce_tri_limit); + void onLODParamCommit(S32 lod, bool enforce_tri_limit); const bool getModelPivot( void ) const { return mHasPivot; } void setHasPivot( bool val ) { mHasPivot = val; } diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml index 39ef844824..21feb9908e 100755 --- a/indra/newview/skins/default/xui/en/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml @@ -100,166 +100,636 @@ name="import_tab" tab_position="top"> - - LOD TABLE - - - - Select Level of Detail: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Level of Detail: [DETAIL] - - - - - - - LOD MESH - - - - Mesh - - - - - - - - - - diff --git a/indra/newview/skins/default/xui/en/widgets/color_swatch.xml b/indra/newview/skins/default/xui/en/widgets/color_swatch.xml index 48b987d7e8..ab3de1eaab 100644 --- a/indra/newview/skins/default/xui/en/widgets/color_swatch.xml +++ b/indra/newview/skins/default/xui/en/widgets/color_swatch.xml @@ -1,7 +1,7 @@ + name="colorswatch"> diff --git a/indra/newview/skins/default/xui/en/widgets/layout_stack.xml b/indra/newview/skins/default/xui/en/widgets/layout_stack.xml new file mode 100644 index 0000000000..48bcb46533 --- /dev/null +++ b/indra/newview/skins/default/xui/en/widgets/layout_stack.xml @@ -0,0 +1,4 @@ + + + + diff --git a/indra/newview/skins/default/xui/en/widgets/menu_bar.xml b/indra/newview/skins/default/xui/en/widgets/menu_bar.xml new file mode 100644 index 0000000000..ee3ef0cd7a --- /dev/null +++ b/indra/newview/skins/default/xui/en/widgets/menu_bar.xml @@ -0,0 +1,7 @@ + + diff --git a/indra/newview/skins/default/xui/en/widgets/menu_item_separator.xml b/indra/newview/skins/default/xui/en/widgets/menu_item_separator.xml index e5cea476da..7452d685eb 100644 --- a/indra/newview/skins/default/xui/en/widgets/menu_item_separator.xml +++ b/indra/newview/skins/default/xui/en/widgets/menu_item_separator.xml @@ -1,6 +1,8 @@ + name="separator" + disabled_color="MenuItemDisabledColor" + highlight_bg_color="MenuItemHighlightBgColor" + highlight_fg_color="MenuItemHighlightFgColor" + label="-----------"> diff --git a/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml b/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml index 185ed6ee3e..72af3924c1 100644 --- a/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml +++ b/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml @@ -1,7 +1,8 @@  - + name="tear_off" + label = "~~~~~~~~~~~" + disabled_color="MenuItemDisabledColor" + highlight_bg_color="MenuItemHighlightBgColor" + highlight_fg_color="MenuItemHighlightFgColor"/> diff --git a/indra/newview/skins/default/xui/en/widgets/multi_slider.xml b/indra/newview/skins/default/xui/en/widgets/multi_slider.xml index e0900b48f3..90b0625982 100644 --- a/indra/newview/skins/default/xui/en/widgets/multi_slider.xml +++ b/indra/newview/skins/default/xui/en/widgets/multi_slider.xml @@ -1,6 +1,7 @@ + mouse_opaque="true" + text_disabled_color="LabelDisabledColor" + draw_track="true" + use_triangle="false" + font="SansSerifSmall"/> diff --git a/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml b/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml index 04a2cd635c..bbcb008df4 100644 --- a/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml +++ b/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml @@ -1,5 +1,6 @@ - + thumb_width="8" + mouse_opaque="true" + follows="left|top"/> diff --git a/indra/newview/skins/default/xui/en/widgets/name_list.xml b/indra/newview/skins/default/xui/en/widgets/name_list.xml new file mode 100644 index 0000000000..3ae0f68227 --- /dev/null +++ b/indra/newview/skins/default/xui/en/widgets/name_list.xml @@ -0,0 +1,3 @@ + + diff --git a/indra/newview/skins/default/xui/en/widgets/panel.xml b/indra/newview/skins/default/xui/en/widgets/panel.xml index 47a210d9b7..b36f723831 100644 --- a/indra/newview/skins/default/xui/en/widgets/panel.xml +++ b/indra/newview/skins/default/xui/en/widgets/panel.xml @@ -4,7 +4,8 @@ bg_opaque_image - image name for "in-front" panel look bg_alpha_image - image name for "in-back" or transparent panel look --> - + thickness="15" + tab_stop="false"> - diff --git a/indra/newview/skins/default/xui/en/widgets/scroll_container.xml b/indra/newview/skins/default/xui/en/widgets/scroll_container.xml index 86356ff563..70f2e88d13 100644 --- a/indra/newview/skins/default/xui/en/widgets/scroll_container.xml +++ b/indra/newview/skins/default/xui/en/widgets/scroll_container.xml @@ -1,5 +1,8 @@ - diff --git a/indra/newview/skins/default/xui/en/widgets/scroll_list.xml b/indra/newview/skins/default/xui/en/widgets/scroll_list.xml index dd93675807..e43989c6c7 100644 --- a/indra/newview/skins/default/xui/en/widgets/scroll_list.xml +++ b/indra/newview/skins/default/xui/en/widgets/scroll_list.xml @@ -1,5 +1,6 @@ - + \ No newline at end of file diff --git a/indra/newview/skins/default/xui/en/widgets/search_editor.xml b/indra/newview/skins/default/xui/en/widgets/search_editor.xml index 32e443a058..faa0404b35 100644 --- a/indra/newview/skins/default/xui/en/widgets/search_editor.xml +++ b/indra/newview/skins/default/xui/en/widgets/search_editor.xml @@ -1,5 +1,6 @@ - - diff --git a/indra/newview/skins/default/xui/en/widgets/texture_picker.xml b/indra/newview/skins/default/xui/en/widgets/texture_picker.xml index 757f0f49d1..ba2fdf4f1f 100644 --- a/indra/newview/skins/default/xui/en/widgets/texture_picker.xml +++ b/indra/newview/skins/default/xui/en/widgets/texture_picker.xml @@ -1,5 +1,9 @@ - + - \ No newline at end of file + bevel_style="out" + mouse_opaque="false" + follows="all"/> \ No newline at end of file diff --git a/indra/newview/skins/default/xui/en/widgets/web_browser.xml b/indra/newview/skins/default/xui/en/widgets/web_browser.xml index 118d63bbf0..676fafd828 100644 --- a/indra/newview/skins/default/xui/en/widgets/web_browser.xml +++ b/indra/newview/skins/default/xui/en/widgets/web_browser.xml @@ -1,2 +1,4 @@ - + -- cgit v1.2.3 From 12832768e122ba76a12b3b673526f7d36f896618 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Tue, 6 Sep 2011 14:45:37 -0700 Subject: EXP-1196 FIX Fix param block template ordering forgot to set menu name in menu.xml reviewed by Leslie --- indra/newview/skins/default/xui/en/widgets/menu.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/indra/newview/skins/default/xui/en/widgets/menu.xml b/indra/newview/skins/default/xui/en/widgets/menu.xml index 58543338f6..13ac84beb2 100644 --- a/indra/newview/skins/default/xui/en/widgets/menu.xml +++ b/indra/newview/skins/default/xui/en/widgets/menu.xml @@ -1,5 +1,6 @@ - Date: Tue, 6 Sep 2011 16:05:03 -0700 Subject: build fix --- indra/llui/llview.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/llui/llview.cpp b/indra/llui/llview.cpp index 6a9384367d..0616c2a0c0 100644 --- a/indra/llui/llview.cpp +++ b/indra/llui/llview.cpp @@ -2549,7 +2549,7 @@ void LLView::applyXUILayout(LLView::Params& p, LLView* parent) if (p.left_pad.isProvided()) { // left_pad is based on prior widget's right edge - p.left_delta.set(p.left_pad + last_rect.getWidth(), false); + p.left_delta.set(p.left_pad + default_rect.getWidth(), false); } default_rect.translate(p.left_delta, p.bottom_delta); -- cgit v1.2.3 From 0e4586a42f754775e27405d0a572ff5962d5a951 Mon Sep 17 00:00:00 2001 From: Paul ProductEngine Date: Wed, 7 Sep 2011 20:53:44 +0300 Subject: SH-2371 FIXED "Not allowed to upload message" flashes when uploader dialog comes up - This is a regression bug caused by changeset:20407 --- indra/newview/skins/default/xui/en/floater_model_preview.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml index df4c66c5b6..cae6445b02 100755 --- a/indra/newview/skins/default/xui/en/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml @@ -1296,7 +1296,7 @@ name="warning_title" top_pad="10" text_color="DrYellow" - visible="true" + visible="false" width="40"> NOTE: @@ -1310,7 +1310,7 @@ top_delta="2" wrap="true" width="462" - visible="true"> + visible="false"> You dont have rights to upload mesh models. [[VURL] Find out how] to get certified. -- cgit v1.2.3 From 535710ae25a7f161d2aacf6e12d94a8dfe599d08 Mon Sep 17 00:00:00 2001 From: Vadim ProductEngine Date: Wed, 7 Sep 2011 22:13:05 +0300 Subject: STORM-1587 FIXED Alert notifications were shown in English, no matter what viewer language was. --- indra/newview/llappviewer.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 7e597fe5dc..4e1ef59765 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -786,6 +786,12 @@ bool LLAppViewer::init() &LLUI::sGLScaleFactor); LL_INFOS("InitInfo") << "UI initialized." << LL_ENDL ; + // Setup paths and LLTrans after LLUI::initClass has been called. + LLUI::setupPaths(); + LLTransUtil::parseStrings("strings.xml", default_trans_args); + LLTransUtil::parseLanguageStrings("language_settings.xml"); + + // Setup notifications after LLUI::setupPaths() has been called. LLNotifications::instance(); LL_INFOS("InitInfo") << "Notifications initialized." << LL_ENDL ; @@ -831,12 +837,6 @@ bool LLAppViewer::init() LLError::setPrintLocation(true); } - - // Setup paths and LLTrans after LLUI::initClass has been called - LLUI::setupPaths(); - LLTransUtil::parseStrings("strings.xml", default_trans_args); - LLTransUtil::parseLanguageStrings("language_settings.xml"); - // LLKeyboard relies on LLUI to know what some accelerator keys are called. LLKeyboard::setStringTranslatorFunc( LLTrans::getKeyboardString ); -- cgit v1.2.3 From 7a47afc89cd0aec9eeb5eeaaa256ecf890036432 Mon Sep 17 00:00:00 2001 From: "Andrew A. de Laix" Date: Wed, 7 Sep 2011 14:36:39 -0500 Subject: add getInfo command to get state information about a ui element --- indra/newview/llwindowlistener.cpp | 30 ++++++++++++++++++++++++++++++ indra/newview/llwindowlistener.h | 1 + 2 files changed, 31 insertions(+) diff --git a/indra/newview/llwindowlistener.cpp b/indra/newview/llwindowlistener.cpp index 05cb798732..eb44a702a4 100644 --- a/indra/newview/llwindowlistener.cpp +++ b/indra/newview/llwindowlistener.cpp @@ -82,6 +82,7 @@ LLWindowListener::LLWindowListener(LLViewerWindow *window, const KeyboardGetter& "Optional [\"reply\"] requests a reply event on the named LLEventPump.\n" "reply[\"error\"] isUndefined (None) on success, else an explanatory message.\n"; + add("getInfo", "Get information about the ui element specified by [\"path\"]", &LLWindowListener::getInfo); add("keyDown", keySomething + "keypress event.\n" + keyExplain + mask, &LLWindowListener::keyDown); @@ -246,6 +247,35 @@ KEY getKEY(const LLSD& event) } // namespace +void LLWindowListener::getInfo(LLSD const & evt) +{ + Response response(LLSD(), evt); + + if (evt.has("path")) + { + std::string path(evt["path"]); + LLView * target_view = + LLUI::resolvePath(gViewerWindow->getRootView(), path); + if (target_view != 0) + { + insertViewInformation(response, target_view); + LLRect rect(target_view->calcScreenRect()); + response["rect"] = LLSDMap("left", rect.mLeft)("top", rect.mTop) + ("right", rect.mRight)("bottom", rect.mBottom); + } + else + { + response.error(STRINGIZE(evt["op"].asString() << " request " + "specified invalid \"path\": '" << path << "'")); + } + } + else + { + response.error( + STRINGIZE(evt["op"].asString() << "request did not provide a path" )); + } +} + void LLWindowListener::keyDown(LLSD const & evt) { Response response(LLSD(), evt); diff --git a/indra/newview/llwindowlistener.h b/indra/newview/llwindowlistener.h index 26adff35ff..29c3575258 100644 --- a/indra/newview/llwindowlistener.h +++ b/indra/newview/llwindowlistener.h @@ -39,6 +39,7 @@ public: typedef boost::function KeyboardGetter; LLWindowListener(LLViewerWindow * window, const KeyboardGetter& kbgetter); + void getInfo(LLSD const & evt); void keyDown(LLSD const & evt); void keyUp(LLSD const & evt); void mouseDown(LLSD const & evt); -- cgit v1.2.3 From 6bb2b2cb99740a00498f5441b8a48b0bf5a04985 Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Wed, 7 Sep 2011 12:45:50 -0700 Subject: EXP-1194 FIX -- Update New tag behavior to update Newness timestamp when Received Items panel is open and do not auto open Received Items panel * Updated inbox freshness time setting name to "LastInventoryInboxActivity" * New time stamp reflects time of last activity performed on the inbox by the user * Selection and opening items in the inbox both count as activity on the inbox * Focus going to the inbox panel counts as activity on the inbox * Creation date of folders now computed based on date of items being added to them * Creation date of folders no longer relies on queries for creation date, as is done during sorting * Folders are assumed to be "new" if no inbox freshness time setting is saved --- .../newview/app_settings/settings_per_account.xml | 4 +- indra/newview/llfolderviewitem.cpp | 62 ++++++++-------------- indra/newview/llfolderviewitem.h | 4 +- indra/newview/llinventorypanel.cpp | 5 +- indra/newview/llinventorypanel.h | 2 + indra/newview/llpanelmarketplaceinbox.cpp | 6 ++- indra/newview/llpanelmarketplaceinboxinventory.cpp | 44 +++++++++------ indra/newview/llpanelmarketplaceinboxinventory.h | 8 +-- .../newview/llpanelmarketplaceoutboxinventory.cpp | 5 -- indra/newview/llpanelmarketplaceoutboxinventory.h | 2 - indra/newview/llsidepanelinventory.cpp | 4 +- 11 files changed, 71 insertions(+), 75 deletions(-) diff --git a/indra/newview/app_settings/settings_per_account.xml b/indra/newview/app_settings/settings_per_account.xml index 49f8a11e3e..c7140283f1 100644 --- a/indra/newview/app_settings/settings_per_account.xml +++ b/indra/newview/app_settings/settings_per_account.xml @@ -33,10 +33,10 @@ Value - LastInventoryInboxExpansion + LastInventoryInboxActivity Comment - The last time the received items inbox was expanded for view. + The last time the received items inbox was poked by the user. Persist 1 Type diff --git a/indra/newview/llfolderviewitem.cpp b/indra/newview/llfolderviewitem.cpp index 72e2294196..00bc63326b 100644 --- a/indra/newview/llfolderviewitem.cpp +++ b/indra/newview/llfolderviewitem.cpp @@ -2057,23 +2057,42 @@ BOOL LLFolderViewFolder::isRemovable() BOOL LLFolderViewFolder::addItem(LLFolderViewItem* item) { mItems.push_back(item); + if (item->isSelected()) { recursiveIncrementNumDescendantsSelected(1); } + item->setRect(LLRect(0, 0, getRect().getWidth(), 0)); item->setVisible(FALSE); - addChild( item ); + + addChild(item); + item->dirtyFilter(); + + // Update the folder creation date if the child is newer than our current date + setCreationDate(llmax(mCreationDate, item->getCreationDate())); + + // Handle sorting requestArrange(); requestSort(); + + // Traverse parent folders and update creation date and resort, if necessary LLFolderViewFolder* parentp = getParentFolder(); - while (parentp && parentp->mSortFunction.isByDate()) + while (parentp) { - // parent folder doesn't have a time stamp yet, so get it from us - parentp->requestSort(); + // Update the folder creation date if the child is newer than our current date + parentp->setCreationDate(llmax(parentp->mCreationDate, item->getCreationDate())); + + if (parentp->mSortFunction.isByDate()) + { + // parent folder doesn't have a time stamp yet, so get it from us + parentp->requestSort(); + } + parentp = parentp->getParentFolder(); } + return TRUE; } @@ -2437,41 +2456,6 @@ void LLFolderViewFolder::draw() time_t LLFolderViewFolder::getCreationDate() const { - // folders have no creation date try to create one from an item somewhere in our folder hierarchy - if (!mCreationDate) - { - for (items_t::const_iterator iit = mItems.begin(); - iit != mItems.end(); ++iit) - { - LLFolderViewItem* itemp = (*iit); - - const time_t item_creation_date = itemp->getCreationDate(); - - if (item_creation_date) - { - setCreationDate(item_creation_date); - break; - } - } - - if (!mCreationDate) - { - for (folders_t::const_iterator fit = mFolders.begin(); - fit != mFolders.end(); ++fit) - { - LLFolderViewFolder* folderp = (*fit); - - const time_t folder_creation_date = folderp->getCreationDate(); - - if (folder_creation_date) - { - setCreationDate(folder_creation_date); - break; - } - } - } - } - return llmax(mCreationDate, mSubtreeCreationDate); } diff --git a/indra/newview/llfolderviewitem.h b/indra/newview/llfolderviewitem.h index ce936b4991..676eaf825d 100644 --- a/indra/newview/llfolderviewitem.h +++ b/indra/newview/llfolderviewitem.h @@ -136,7 +136,7 @@ protected: std::string mSearchableLabel; S32 mLabelWidth; bool mLabelWidthDirty; - mutable time_t mCreationDate; + time_t mCreationDate; LLFolderViewFolder* mParentFolder; LLFolderViewEventListener* mListener; BOOL mIsCurSelection; @@ -174,7 +174,7 @@ protected: static LLFontGL* getLabelFontForStyle(U8 style); - virtual void setCreationDate(time_t creation_date_utc) const { mCreationDate = creation_date_utc; } + virtual void setCreationDate(time_t creation_date_utc) { mCreationDate = creation_date_utc; } public: BOOL postBuild(); diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 5f033cf517..173e5c6ae6 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -234,7 +234,6 @@ void LLInventoryPanel::initFromParams(const LLInventoryPanel::Params& params) { setSortOrder(gSavedSettings.getU32(DEFAULT_SORT_ORDER)); } - mFolderRoot->setSortOrder(getFilter()->getSortOrder()); // hide inbox getFilter()->setFilterCategoryTypes(getFilter()->getFilterCategoryTypes() & ~(1ULL << LLFolderType::FT_INBOX)); @@ -347,6 +346,10 @@ U32 LLInventoryPanel::getSortOrder() const return mFolderRoot->getSortOrder(); } +void LLInventoryPanel::requestSort() +{ + mFolderRoot->requestSort(); +} void LLInventoryPanel::setSinceLogoff(BOOL sl) { diff --git a/indra/newview/llinventorypanel.h b/indra/newview/llinventorypanel.h index 7676bbb6d7..cfb84bf4b7 100644 --- a/indra/newview/llinventorypanel.h +++ b/indra/newview/llinventorypanel.h @@ -208,6 +208,8 @@ public: void setSortOrder(U32 order); U32 getSortOrder() const; + void requestSort(); + private: std::string mSortOrderSetting; diff --git a/indra/newview/llpanelmarketplaceinbox.cpp b/indra/newview/llpanelmarketplaceinbox.cpp index 9f17c34dfb..8d0712a328 100644 --- a/indra/newview/llpanelmarketplaceinbox.cpp +++ b/indra/newview/llpanelmarketplaceinbox.cpp @@ -95,8 +95,10 @@ LLInventoryPanel * LLPanelMarketplaceInbox::setupInventoryPanel() LLRect inventory_placeholder_rect = inbox_inventory_placeholder->getRect(); mInventoryPanel->setShape(inventory_placeholder_rect); - // Set the sort order newest to oldest, and a selection change callback + // Set the sort order newest to oldest mInventoryPanel->setSortOrder(LLInventoryFilter::SO_DATE); + + // Set selection callback for proper update of inventory status buttons mInventoryPanel->setSelectCallback(boost::bind(&LLPanelMarketplaceInbox::onSelectionChange, this)); // Set up the note to display when the inbox is empty @@ -113,6 +115,8 @@ void LLPanelMarketplaceInbox::onFocusReceived() LLSidepanelInventory * sidepanel_inventory = LLSideTray::getInstance()->getPanel("sidepanel_inventory"); sidepanel_inventory->clearSelections(true, false, true); + + gSavedPerAccountSettings.setString("LastInventoryInboxActivity", LLDate::now().asString()); } BOOL LLPanelMarketplaceInbox::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop, EDragAndDropType cargo_type, void *cargo_data, EAcceptance *accept, std::string& tooltip_msg) diff --git a/indra/newview/llpanelmarketplaceinboxinventory.cpp b/indra/newview/llpanelmarketplaceinboxinventory.cpp index e5b0db92f3..47f34434db 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceinboxinventory.cpp @@ -37,6 +37,8 @@ #include "llviewerfoldertype.h" +#define DEBUGGING_FRESHNESS 0 + // // statics // @@ -188,49 +190,57 @@ void LLInboxFolderViewFolder::draw() LLFolderViewFolder::draw(); } -BOOL LLInboxFolderViewFolder::addToFolder(LLFolderViewFolder* folder, LLFolderView* root) -{ - BOOL retval = LLFolderViewFolder::addToFolder(folder, root); - - // Only mark top-level inbox folders as fresh - mFresh = (mParentFolder == mRoot); - - return retval; -} - -void LLInboxFolderViewFolder::updateFlag() const +void LLInboxFolderViewFolder::computeFreshness() { - const std::string& last_expansion = gSavedPerAccountSettings.getString("LastInventoryInboxExpansion"); + const std::string& last_expansion = gSavedPerAccountSettings.getString("LastInventoryInboxActivity"); if (!last_expansion.empty()) { LLDate saved_freshness_date = LLDate(last_expansion); mFresh = (mCreationDate > saved_freshness_date.secondsSinceEpoch()); + +#if DEBUGGING_FRESHNESS + if (mFresh) + { + llinfos << "Item is fresh! -- creation " << mCreationDate << ", saved_freshness_date " << saved_freshness_date.secondsSinceEpoch() << llendl; + } +#endif + } + else + { + mFresh = true; } } +void LLInboxFolderViewFolder::deFreshify() +{ + mFresh = false; + + gSavedPerAccountSettings.setString("LastInventoryInboxActivity", LLDate::now().asString()); +} + void LLInboxFolderViewFolder::selectItem() { LLFolderViewFolder::selectItem(); - mFresh = false; + deFreshify(); } void LLInboxFolderViewFolder::toggleOpen() { LLFolderViewFolder::toggleOpen(); - mFresh = false; + deFreshify(); } -void LLInboxFolderViewFolder::setCreationDate(time_t creation_date_utc) const +void LLInboxFolderViewFolder::setCreationDate(time_t creation_date_utc) { mCreationDate = creation_date_utc; - if (mFresh) + if (mParentFolder == mRoot) { - updateFlag(); + computeFreshness(); } } diff --git a/indra/newview/llpanelmarketplaceinboxinventory.h b/indra/newview/llpanelmarketplaceinboxinventory.h index 06706539a0..089facf80c 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.h +++ b/indra/newview/llpanelmarketplaceinboxinventory.h @@ -75,18 +75,18 @@ public: void draw(); - BOOL addToFolder(LLFolderViewFolder* folder, LLFolderView* root); + void computeFreshness(); + void deFreshify(); - void updateFlag() const; void selectItem(); void toggleOpen(); bool isFresh() const { return mFresh; } protected: - void setCreationDate(time_t creation_date_utc) const; + void setCreationDate(time_t creation_date_utc); - mutable bool mFresh; + bool mFresh; }; diff --git a/indra/newview/llpanelmarketplaceoutboxinventory.cpp b/indra/newview/llpanelmarketplaceoutboxinventory.cpp index 14b6ee9e0a..ed1206aec8 100644 --- a/indra/newview/llpanelmarketplaceoutboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceoutboxinventory.cpp @@ -259,11 +259,6 @@ void LLOutboxFolderViewFolder::setError(S32 errorCode) } } -void LLOutboxFolderViewFolder::setCreationDate(time_t creation_date_utc) const -{ - mCreationDate = creation_date_utc; -} - // // LLOutboxFolderViewItem Implementation // diff --git a/indra/newview/llpanelmarketplaceoutboxinventory.h b/indra/newview/llpanelmarketplaceoutboxinventory.h index ec55b7eb2e..346680a79d 100644 --- a/indra/newview/llpanelmarketplaceoutboxinventory.h +++ b/indra/newview/llpanelmarketplaceoutboxinventory.h @@ -77,8 +77,6 @@ public: bool hasError() const { return (mError != 0); } protected: - void setCreationDate(time_t creation_date_utc) const; - S32 mError; }; diff --git a/indra/newview/llsidepanelinventory.cpp b/indra/newview/llsidepanelinventory.cpp index 522de30467..858639215c 100644 --- a/indra/newview/llsidepanelinventory.cpp +++ b/indra/newview/llsidepanelinventory.cpp @@ -539,7 +539,7 @@ void LLSidepanelInventory::onToggleInboxBtn() if (inbox_expanded && inboxPanel->isInVisibleChain()) { - gSavedPerAccountSettings.setString("LastInventoryInboxExpansion", LLDate::now().asString()); + gSavedPerAccountSettings.setString("LastInventoryInboxActivity", LLDate::now().asString()); } } @@ -568,7 +568,7 @@ void LLSidepanelInventory::onOpen(const LLSD& key) #else if (mInboxEnabled && getChild(INBOX_BUTTON_NAME)->getToggleState()) { - gSavedPerAccountSettings.setString("LastInventoryInboxExpansion", LLDate::now().asString()); + gSavedPerAccountSettings.setString("LastInventoryInboxActivity", LLDate::now().asString()); } #endif -- cgit v1.2.3 From c64bd7d5cb28fc221716e866ff9c9a28c22e69ce Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Wed, 7 Sep 2011 12:46:37 -0700 Subject: Reduced text spam on exit by not trying to set all objects to a NULL region. Reviewed by Richard. --- indra/newview/llviewerobjectlist.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp index db5684665b..153a91e7d8 100644 --- a/indra/newview/llviewerobjectlist.cpp +++ b/indra/newview/llviewerobjectlist.cpp @@ -1254,7 +1254,8 @@ void LLViewerObjectList::removeDrawable(LLDrawable* drawablep) BOOL LLViewerObjectList::killObject(LLViewerObject *objectp) { // Don't ever kill gAgentAvatarp, just force it to the agent's region - if (objectp == gAgentAvatarp) + // unless region is NULL which is assumed to mean you are logging out. + if ((objectp == gAgentAvatarp) && gAgent.getRegion()) { objectp->setRegion(gAgent.getRegion()); return FALSE; @@ -1277,6 +1278,7 @@ BOOL LLViewerObjectList::killObject(LLViewerObject *objectp) return TRUE; } + return FALSE; } -- cgit v1.2.3 From 222908e6d56da661fbb6e2153845b62c983f3bd9 Mon Sep 17 00:00:00 2001 From: eli Date: Wed, 7 Sep 2011 17:07:50 -0700 Subject: sync with viewer-development --- .../skins/default/xui/en/menu_media_ctrl.xml | 12 ++++++++ indra/newview/skins/default/xui/en/panel_login.xml | 34 +++++++++++++++------ .../skins/default/xui/en/panel_navigation_bar.xml | 4 +-- .../skins/default/xui/en/panel_status_bar.xml | 35 +++++++++++++--------- .../skins/default/xui/en/widgets/combo_box.xml | 3 ++ 5 files changed, 63 insertions(+), 25 deletions(-) diff --git a/indra/newview/skins/default/xui/en/menu_media_ctrl.xml b/indra/newview/skins/default/xui/en/menu_media_ctrl.xml index c39c26f25f..960da4bd7a 100644 --- a/indra/newview/skins/default/xui/en/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/en/menu_media_ctrl.xml @@ -28,4 +28,16 @@ + + + + diff --git a/indra/newview/skins/default/xui/en/panel_login.xml b/indra/newview/skins/default/xui/en/panel_login.xml index 83f1bff91f..983f93cb03 100644 --- a/indra/newview/skins/default/xui/en/panel_login.xml +++ b/indra/newview/skins/default/xui/en/panel_login.xml @@ -117,17 +117,33 @@ label="Remember password" name="connect_btn" top="35" width="90" /> - - + Mode: + + + top_pad="0" + name="mode_combo" + width="110"> + + + + width="226"> - + > + + + + width="75"> 24:00 AM PST diff --git a/indra/newview/skins/default/xui/en/widgets/color_swatch.xml b/indra/newview/skins/default/xui/en/widgets/color_swatch.xml index 48b987d7e8..ab3de1eaab 100644 --- a/indra/newview/skins/default/xui/en/widgets/color_swatch.xml +++ b/indra/newview/skins/default/xui/en/widgets/color_swatch.xml @@ -1,7 +1,7 @@ + name="colorswatch"> diff --git a/indra/newview/skins/default/xui/en/widgets/inbox_folder_view_folder.xml b/indra/newview/skins/default/xui/en/widgets/inbox_folder_view_folder.xml index 95f5cf2ecd..77d8024cb2 100644 --- a/indra/newview/skins/default/xui/en/widgets/inbox_folder_view_folder.xml +++ b/indra/newview/skins/default/xui/en/widgets/inbox_folder_view_folder.xml @@ -10,10 +10,12 @@ label="New" label_offset_horiz="-1" location="right" - padding_horiz="4" - padding_vert="1" - location_percent_hcenter="70" - border_image="" - image="Badge_Background_New" + padding_horiz="12.5" + padding_vert="2" + location_offset_hcenter="-23" + border_image="New_Tag_Border" + border_color="DkGray2" + image="New_Tag_Background" + image_color="Black" /> diff --git a/indra/newview/skins/default/xui/en/widgets/menu.xml b/indra/newview/skins/default/xui/en/widgets/menu.xml index 58543338f6..13ac84beb2 100644 --- a/indra/newview/skins/default/xui/en/widgets/menu.xml +++ b/indra/newview/skins/default/xui/en/widgets/menu.xml @@ -1,5 +1,6 @@ - + name="separator" + disabled_color="MenuItemDisabledColor" + highlight_bg_color="MenuItemHighlightBgColor" + highlight_fg_color="MenuItemHighlightFgColor" + label="-----------"> diff --git a/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml b/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml index 185ed6ee3e..72af3924c1 100644 --- a/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml +++ b/indra/newview/skins/default/xui/en/widgets/menu_item_tear_off.xml @@ -1,7 +1,8 @@  - + name="tear_off" + label = "~~~~~~~~~~~" + disabled_color="MenuItemDisabledColor" + highlight_bg_color="MenuItemHighlightBgColor" + highlight_fg_color="MenuItemHighlightFgColor"/> diff --git a/indra/newview/skins/default/xui/en/widgets/multi_slider.xml b/indra/newview/skins/default/xui/en/widgets/multi_slider.xml index e0900b48f3..90b0625982 100644 --- a/indra/newview/skins/default/xui/en/widgets/multi_slider.xml +++ b/indra/newview/skins/default/xui/en/widgets/multi_slider.xml @@ -1,6 +1,7 @@ + mouse_opaque="true" + text_disabled_color="LabelDisabledColor" + draw_track="true" + use_triangle="false" + font="SansSerifSmall"/> diff --git a/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml b/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml index 04a2cd635c..bbcb008df4 100644 --- a/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml +++ b/indra/newview/skins/default/xui/en/widgets/multi_slider_bar.xml @@ -1,5 +1,6 @@ - + thumb_width="8" + mouse_opaque="true" + follows="left|top"/> diff --git a/indra/newview/skins/default/xui/en/widgets/panel.xml b/indra/newview/skins/default/xui/en/widgets/panel.xml index 47a210d9b7..b36f723831 100644 --- a/indra/newview/skins/default/xui/en/widgets/panel.xml +++ b/indra/newview/skins/default/xui/en/widgets/panel.xml @@ -4,7 +4,8 @@ bg_opaque_image - image name for "in-front" panel look bg_alpha_image - image name for "in-back" or transparent panel look --> - - diff --git a/indra/newview/skins/default/xui/en/widgets/scroll_bar.xml b/indra/newview/skins/default/xui/en/widgets/scroll_bar.xml index e6d4bff8b5..682dcf40d8 100644 --- a/indra/newview/skins/default/xui/en/widgets/scroll_bar.xml +++ b/indra/newview/skins/default/xui/en/widgets/scroll_bar.xml @@ -5,7 +5,8 @@ track_image_horizontal ="ScrollTrack_Horiz" track_color="ScrollbarTrackColor" thumb_color="ScrollbarThumbColor" - thickness="15"> + thickness="15" + tab_stop="false"> - diff --git a/indra/newview/skins/default/xui/en/widgets/scroll_container.xml b/indra/newview/skins/default/xui/en/widgets/scroll_container.xml index 86356ff563..a6d096a964 100644 --- a/indra/newview/skins/default/xui/en/widgets/scroll_container.xml +++ b/indra/newview/skins/default/xui/en/widgets/scroll_container.xml @@ -1,5 +1,8 @@ - + max_auto_scroll_rate="500" + tab_stop="false" + mouse_opaque="true" /> diff --git a/indra/newview/skins/default/xui/en/widgets/scroll_list.xml b/indra/newview/skins/default/xui/en/widgets/scroll_list.xml index dd93675807..e43989c6c7 100644 --- a/indra/newview/skins/default/xui/en/widgets/scroll_list.xml +++ b/indra/newview/skins/default/xui/en/widgets/scroll_list.xml @@ -1,5 +1,6 @@ - - - diff --git a/indra/newview/skins/default/xui/en/widgets/texture_picker.xml b/indra/newview/skins/default/xui/en/widgets/texture_picker.xml index 757f0f49d1..ba2fdf4f1f 100644 --- a/indra/newview/skins/default/xui/en/widgets/texture_picker.xml +++ b/indra/newview/skins/default/xui/en/widgets/texture_picker.xml @@ -1,5 +1,9 @@ - + - \ No newline at end of file + bevel_style="out" + mouse_opaque="false" + follows="all"/> \ No newline at end of file diff --git a/indra/newview/skins/default/xui/en/widgets/web_browser.xml b/indra/newview/skins/default/xui/en/widgets/web_browser.xml index 118d63bbf0..676fafd828 100644 --- a/indra/newview/skins/default/xui/en/widgets/web_browser.xml +++ b/indra/newview/skins/default/xui/en/widgets/web_browser.xml @@ -1,2 +1,4 @@ - + diff --git a/indra/newview/skins/minimal/xui/en/main_view.xml b/indra/newview/skins/minimal/xui/en/main_view.xml index ec2683880a..0ce6cbc984 100644 --- a/indra/newview/skins/minimal/xui/en/main_view.xml +++ b/indra/newview/skins/minimal/xui/en/main_view.xml @@ -187,9 +187,9 @@ name="status_bar_container" tab_stop="false" height="30" - left="-120" + left="-160" top="0" - width="120" + width="160" visible="false"/> - + + Mode: + + + + + mouse_opaque="false" name="location_combo" top_delta="0" - width="390"> + width="325"> + width="185"> Packet Loss @@ -33,18 +33,27 @@ name="buycurrencylabel"> L$ [AMT] - + + + + - + Geometry preview - + High detail - + Medium detail - + Low detail - + Lowest detail @@ -502,7 +497,7 @@ Higher prim weight height="50" font="SansSerifSmall" layout="topleft" - name="physics_hint" + name="description" word_wrap="true" left_delta="5"> We will create a shape for the outer hull of the model. Adjust the shape's detail level as needed for the intended purpose of your model. @@ -536,16 +531,16 @@ Higher prim weight left="15" height="270" width="505" - name="physics_content_panel" + name="content" bg_opaque_color="DkGray2" background_visible="true" background_opaque="true"> - Performance - Faster rendering + Performance + Faster rendering Less detail Lower prim weight - Accuracy - Slower rendering + Accuracy + Slower rendering More detail Higher prim weight @@ -563,15 +558,15 @@ Higher prim weight show_text="false" top="25" width="22" /> - Examples: + Examples: Moving objects Flying objects Vehicles - Examples: + Examples: Small static objects Less detailed objects Simple furniture - Examples: + Examples: Static objects Detailed objects Buildings @@ -597,7 +592,7 @@ Buildings visible="false" width="150"> - + Physics preview - + High detail - + Medium detail - + Low detail - + Lowest detail @@ -640,7 +635,7 @@ Buildings left="15" height="310" width="505" - name="review_content_panel" + name="content" bg_opaque_color="DkGray2" background_visible="true" background_opaque="true"> @@ -711,7 +706,7 @@ Buildings + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml index 8901583799..9b02f7d273 100644 --- a/indra/newview/skins/default/xui/en/floater_tools.xml +++ b/indra/newview/skins/default/xui/en/floater_tools.xml @@ -48,11 +48,11 @@ - [OBJ_COUNT] objects ( [PRIM_COUNT] prims[PE_STRING] ) selected + [OBJ_COUNT] objects selected, land impact [LAND_IMPACT] - , [SEL_WEIGHT] prim equivs + name="status_remaining_capacity"> + Remaining capacity [LAND_CAPACITY]. diff --git a/indra/newview/skins/default/xui/de/menu_media_ctrl.xml b/indra/newview/skins/default/xui/de/menu_media_ctrl.xml index 781796670a..59c1c2ee86 100644 --- a/indra/newview/skins/default/xui/de/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/de/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/de/menu_mode_change.xml b/indra/newview/skins/default/xui/de/menu_mode_change.xml new file mode 100644 index 0000000000..b8090018b7 --- /dev/null +++ b/indra/newview/skins/default/xui/de/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/de/menu_viewer.xml b/indra/newview/skins/default/xui/de/menu_viewer.xml index e010844206..7c6918a4ee 100644 --- a/indra/newview/skins/default/xui/de/menu_viewer.xml +++ b/indra/newview/skins/default/xui/de/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -253,6 +252,7 @@ + diff --git a/indra/newview/skins/default/xui/de/notifications.xml b/indra/newview/skins/default/xui/de/notifications.xml index 1971061096..4c53c40d86 100644 --- a/indra/newview/skins/default/xui/de/notifications.xml +++ b/indra/newview/skins/default/xui/de/notifications.xml @@ -85,6 +85,19 @@ Stellen Sie sicher, dass Ihre Internetverbindung funktioniert. Änderung an aktueller Kleidung/Körperteil speichern? + + Ihnen fehlt die Berechtigung zum Kopieren dieses Artikels in die Händler-Outbox. Möchten Sie wirklich den folgenden Artikel verschieben? + [ITEM_NAME] + + + + Marktplatz-Upload abgeschlossen. + + + + Marktplatz-Upload mit Fehlern abgeschlossen. Korrigieren Sie die Fehler in Ihrer Outbox und versuchen Sie es erneut. Vielen Dank! + + Der Text für ein Skript konnte aus folgendem Grund nicht hochgeladen werden: [REASON]. Bitte versuchen Sie es erneut. @@ -2436,7 +2449,15 @@ Versuchen Sie es in einigen Minuten erneut. diff --git a/indra/newview/skins/default/xui/es/menu_media_ctrl.xml b/indra/newview/skins/default/xui/es/menu_media_ctrl.xml index 8ea9286d8e..b4dfe9907a 100644 --- a/indra/newview/skins/default/xui/es/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/es/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/es/menu_mode_change.xml b/indra/newview/skins/default/xui/es/menu_mode_change.xml new file mode 100644 index 0000000000..608505d192 --- /dev/null +++ b/indra/newview/skins/default/xui/es/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/es/menu_viewer.xml b/indra/newview/skins/default/xui/es/menu_viewer.xml index b0d16d1ca4..bc8a5731ab 100644 --- a/indra/newview/skins/default/xui/es/menu_viewer.xml +++ b/indra/newview/skins/default/xui/es/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -248,6 +247,7 @@ + diff --git a/indra/newview/skins/default/xui/es/notifications.xml b/indra/newview/skins/default/xui/es/notifications.xml index 2ec1b333a9..4fb29b9427 100644 --- a/indra/newview/skins/default/xui/es/notifications.xml +++ b/indra/newview/skins/default/xui/es/notifications.xml @@ -85,6 +85,19 @@ Asegúrate de que tu conexión a Internet está funcionando adecuadamente. ¿Guardar los cambios en las ropas o partes del cuerpo actuales? + + No tienes permiso para copiar este objeto en el Buzón de salida de comerciante. ¿Estás seguro de que quieres mover el objeto siguiente? + [ITEM_NAME] + + + + Envío al mercado finalizado. + + + + El envío al mercado ha tenido errores. Corrige los problemas de tu buzón de salida y repite la operación. Muchas gracias. + + Hubo un problema al subir el texto de un script por la siguiente razón: [REASON]. Por favor, inténtalo más tarde. @@ -2430,7 +2443,15 @@ Por favor, vuelve a intentarlo en unos momentos. diff --git a/indra/newview/skins/default/xui/fr/menu_media_ctrl.xml b/indra/newview/skins/default/xui/fr/menu_media_ctrl.xml index 787a5b3af2..1941ad2cbf 100644 --- a/indra/newview/skins/default/xui/fr/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/fr/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/fr/menu_mode_change.xml b/indra/newview/skins/default/xui/fr/menu_mode_change.xml new file mode 100644 index 0000000000..982a331c5b --- /dev/null +++ b/indra/newview/skins/default/xui/fr/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/fr/menu_viewer.xml b/indra/newview/skins/default/xui/fr/menu_viewer.xml index 46adc79a00..cf1dac2f3a 100644 --- a/indra/newview/skins/default/xui/fr/menu_viewer.xml +++ b/indra/newview/skins/default/xui/fr/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -253,6 +252,7 @@ + diff --git a/indra/newview/skins/default/xui/fr/notifications.xml b/indra/newview/skins/default/xui/fr/notifications.xml index ef95a1a389..1389c49f5b 100644 --- a/indra/newview/skins/default/xui/fr/notifications.xml +++ b/indra/newview/skins/default/xui/fr/notifications.xml @@ -85,6 +85,19 @@ Veuillez vérifier votre connexion Internet. Enregistrer les changements dans la partie du corps/les habits actuels ? + + Vous n'êtes pas autorisé à copier cet article dans la boîte d'envoi vers la Place du marché. Voulez-vous vraiment déplacer l'article suivant ? + [ITEM_NAME] + + + + Chargement sur la Place du marché terminé. + + + + Chargement sur la Place du marché effectué avec des erreurs ! Corrigez les problèmes dans votre boîte d'envoi et réessayez. Merci ! + + Une erreur est survenue lors du chargement du texte pour un script, suite au problème suivant : [REASON]. Veuillez réessayer ultérieurement. @@ -2422,7 +2435,15 @@ Veuillez réessayer dans quelques minutes. diff --git a/indra/newview/skins/default/xui/it/menu_media_ctrl.xml b/indra/newview/skins/default/xui/it/menu_media_ctrl.xml index a0e7370efd..aa9e583f8e 100644 --- a/indra/newview/skins/default/xui/it/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/it/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/it/menu_mode_change.xml b/indra/newview/skins/default/xui/it/menu_mode_change.xml new file mode 100644 index 0000000000..499dcf1873 --- /dev/null +++ b/indra/newview/skins/default/xui/it/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/it/menu_viewer.xml b/indra/newview/skins/default/xui/it/menu_viewer.xml index ef40cbda7c..7e3b344117 100644 --- a/indra/newview/skins/default/xui/it/menu_viewer.xml +++ b/indra/newview/skins/default/xui/it/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -248,6 +247,7 @@ + diff --git a/indra/newview/skins/default/xui/it/notifications.xml b/indra/newview/skins/default/xui/it/notifications.xml index d09f207af2..ab9de43e6e 100644 --- a/indra/newview/skins/default/xui/it/notifications.xml +++ b/indra/newview/skins/default/xui/it/notifications.xml @@ -85,6 +85,19 @@ Accertati che la tua connessione Internet stia funzionando correttamente. Salva i cambiamenti all'attuale parte del corpo/abito? + + Non hai l'autorizzazione necessaria per copiare questo oggetto nella casella in uscita di Marketplace. Sei sicuro di volere spostare gli oggetti seguenti? + [ITEM_NAME] + + + + Caricamento di Marketplace completato. + + + + Caricamento di Marketplace completato senza errori. Correggi i problemi nella casella in uscita e riprova. Grazie. + + C'è stato un problema importando il testo di uno script per la seguente ragione: [REASON]. Riprova più tardi. @@ -2424,7 +2437,15 @@ Riprova tra qualche istante. diff --git a/indra/newview/skins/default/xui/ja/menu_media_ctrl.xml b/indra/newview/skins/default/xui/ja/menu_media_ctrl.xml index d155dc17e0..faae4ef717 100644 --- a/indra/newview/skins/default/xui/ja/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/ja/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/ja/menu_mode_change.xml b/indra/newview/skins/default/xui/ja/menu_mode_change.xml new file mode 100644 index 0000000000..dff3392bd5 --- /dev/null +++ b/indra/newview/skins/default/xui/ja/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/ja/menu_viewer.xml b/indra/newview/skins/default/xui/ja/menu_viewer.xml index 223c1e1f11..edce5c50fc 100644 --- a/indra/newview/skins/default/xui/ja/menu_viewer.xml +++ b/indra/newview/skins/default/xui/ja/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -253,6 +252,7 @@ + diff --git a/indra/newview/skins/default/xui/ja/notifications.xml b/indra/newview/skins/default/xui/ja/notifications.xml index 6bff82bec4..c138aeb383 100644 --- a/indra/newview/skins/default/xui/ja/notifications.xml +++ b/indra/newview/skins/default/xui/ja/notifications.xml @@ -84,6 +84,19 @@ 現在の衣類、身体部位の変更を保存しますか? + + マーチャントのアウトボックスにこれをコピーする権限があります。次のアイテムを移動しますか? +[ITEM_NAME] + + + + マーケットプレイスへのアップロードが完了しました。 + + + + マーケットプレイスへのアップロードの完了時にエラーが発生しました。アウトボックスの問題を解決して、もう一度お試しください。ありがとうございます。 + + 次の理由で、スクリプト用テキストのアップロード時に問題が起こりました。 [REASON] @@ -2471,7 +2484,15 @@ Web ページにリンクすると、他人がこの場所に簡単にアクセ diff --git a/indra/newview/skins/default/xui/pt/menu_media_ctrl.xml b/indra/newview/skins/default/xui/pt/menu_media_ctrl.xml index 44117c8865..ac84b02870 100644 --- a/indra/newview/skins/default/xui/pt/menu_media_ctrl.xml +++ b/indra/newview/skins/default/xui/pt/menu_media_ctrl.xml @@ -3,4 +3,5 @@ + diff --git a/indra/newview/skins/default/xui/pt/menu_mode_change.xml b/indra/newview/skins/default/xui/pt/menu_mode_change.xml new file mode 100644 index 0000000000..314d3e409b --- /dev/null +++ b/indra/newview/skins/default/xui/pt/menu_mode_change.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/indra/newview/skins/default/xui/pt/menu_viewer.xml b/indra/newview/skins/default/xui/pt/menu_viewer.xml index ea54afed5e..e1d066261a 100644 --- a/indra/newview/skins/default/xui/pt/menu_viewer.xml +++ b/indra/newview/skins/default/xui/pt/menu_viewer.xml @@ -138,7 +138,6 @@ - @@ -248,6 +247,7 @@ + diff --git a/indra/newview/skins/default/xui/pt/notifications.xml b/indra/newview/skins/default/xui/pt/notifications.xml index 22de7edfdd..70d882822d 100644 --- a/indra/newview/skins/default/xui/pt/notifications.xml +++ b/indra/newview/skins/default/xui/pt/notifications.xml @@ -84,6 +84,19 @@ Verifique se a conexão à internet está funcionando. Salvar modificações? + + Você não tem permissão para copiar este item para a Caixa de saída do lojista. Tem certeza de que deseja mover o itens a seguir? + [ITEM_NAME] + + + + Envio para Mercado concluído. + + + + Envio para Mercado concluído com erros! Corrija os problemas em sua caixa de saída e tente novamente. Obrigado. + + Houve um problema com o carregamento do texto para um script devido à seguinte razão: [REASON]. Por favor, tente novamente mais tarde. @@ -2400,12 +2413,20 @@ Por favor, tente novamente em alguns instantes. Nenhum lote válido foi encontrado. - Um objeto chamado <nolink>[OBJECTFROMNAME]</nolink>, de [NAME_SLURL], lhe deu este(a) [OBJECTTYPE]: + Um objeto chamado <nolink>[OBJECTFROMNAME]</nolink>, de [NAME_SLURL], obteve este(a) [OBJECTTYPE]: <nolink>[ITEM_SLURL]</nolink>