Merge branch 'release/2025.03' of https://github.com/secondlife/viewer

# Conflicts:
#	indra/llmessage/llproxy.cpp
#	indra/llui/llfolderviewitem.cpp
#	indra/newview/CMakeLists.txt
#	indra/newview/llappviewer.cpp
#	indra/newview/llfilepicker.cpp
#	indra/newview/llfloaterpreference.cpp
#	indra/newview/lloutfitslist.cpp
#	indra/newview/llpanelmaininventory.cpp
#	indra/newview/llviewerprecompiledheaders.h
#	indra/newview/llviewerwindow.cpp
#	indra/newview/skins/default/xui/en/floater_world_map.xml
#	indra/newview/skins/default/xui/en/menu_viewer.xml
#	indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml
#	indra/newview/viewer_manifest.py
master
Ansariel 2025-03-12 19:31:51 +01:00
commit 750099db68
68 changed files with 695 additions and 331 deletions

View File

@ -3515,14 +3515,15 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>build</key>
<map>
<key>command</key>
<string>xcodebuild</string>
<string>cmake</string>
<key>options</key>
<array>
<string>-configuration</string>
<string>--build</string>
<string>.</string>
<string>--config</string>
<string>RelWithDebInfo</string>
<string>-project</string>
<string>SecondLife.xcodeproj</string>
<string>-parallelizeTargets</string>
<string>--parallel</string>
<string>$AUTOBUILD_CPU_COUNT</string>
</array>
</map>
<!-- FS:Ansariel: This will cause packages being installed twice
@ -3545,14 +3546,15 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>build</key>
<map>
<key>command</key>
<string>xcodebuild</string>
<string>cmake</string>
<key>options</key>
<array>
<string>-configuration</string>
<string>--build</string>
<string>.</string>
<string>--config</string>
<string>RelWithDebInfo</string>
<string>-project</string>
<string>SecondLife.xcodeproj</string>
<string>-parallelizeTargets</string>
<string>--parallel</string>
<string>$AUTOBUILD_CPU_COUNT</string>
</array>
</map>
<key>name</key>
@ -3579,14 +3581,15 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>build</key>
<map>
<key>command</key>
<string>xcodebuild</string>
<string>cmake</string>
<key>options</key>
<array>
<string>-configuration</string>
<string>--build</string>
<string>.</string>
<string>--config</string>
<string>Release</string>
<string>-project</string>
<string>SecondLife.xcodeproj</string>
<string>-parallelizeTargets</string>
<string>--parallel</string>
<string>$AUTOBUILD_CPU_COUNT</string>
</array>
</map>
<key>name</key>
@ -3605,14 +3608,15 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors</string>
<key>build</key>
<map>
<key>command</key>
<string>xcodebuild</string>
<string>cmake</string>
<key>options</key>
<array>
<string>-configuration</string>
<string>--build</string>
<string>.</string>
<string>--config</string>
<string>Release</string>
<string>-project</string>
<string>SecondLife.xcodeproj</string>
<string>-parallelizeTargets</string>
<string>--parallel</string>
<string>$AUTOBUILD_CPU_COUNT</string>
</array>
</map>
<key>name</key>

View File

@ -41,7 +41,7 @@ add_compile_definitions(BOOST_BIND_GLOBAL_PLACEHOLDERS)
# Force enable SSE2 instructions in GLM per the manual
# https://github.com/g-truc/glm/blob/master/manual.md#section2_10
add_compile_definitions(GLM_FORCE_DEFAULT_ALIGNED_GENTYPES=1 GLM_FORCE_SSE2=1)
add_compile_definitions(GLM_FORCE_DEFAULT_ALIGNED_GENTYPES=1 GLM_FORCE_SSE2=1 GLM_ENABLE_EXPERIMENTAL=1)
# Configure crash reporting
set(RELEASE_CRASH_REPORTING OFF CACHE BOOL "Enable use of crash reporting in release builds")
@ -55,6 +55,11 @@ if(NON_RELEASE_CRASH_REPORTING)
add_compile_definitions( LL_SEND_CRASH_REPORTS=1)
endif()
set(USE_LTO OFF CACHE BOOL "Enable Link Time Optimization")
if(USE_LTO)
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION ON)
endif()
# Don't bother with a MinSizeRel or Debug builds.
set(CMAKE_CONFIGURATION_TYPES "RelWithDebInfo;Release" CACHE STRING "Supported build types." FORCE)
@ -127,7 +132,7 @@ if (WINDOWS)
#ND: When using something like buildcache (https://github.com/mbitsnbites/buildcache)
# to make those wrappers work /Zi must be changed to /Z7, as /Zi due to it's nature is not compatible with caching
if( ${CMAKE_CXX_COMPILER_LAUNCHER} MATCHES ".*cache.*")
if(${CMAKE_CXX_COMPILER_LAUNCHER} MATCHES ".*cache.*")
add_compile_options( /Z7 )
string(REPLACE "/Zi" "/Z7" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
string(REPLACE "/Zi" "/Z7" CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")

View File

@ -981,7 +981,7 @@ void LLPolyMesh::initializeForMorph()
LLVector4a::memcpyNonAliased16((F32*) mScaledNormals, (F32*) mSharedData->mBaseNormals, sizeof(LLVector4a) * mSharedData->mNumVertices);
LLVector4a::memcpyNonAliased16((F32*) mBinormals, (F32*) mSharedData->mBaseNormals, sizeof(LLVector4a) * mSharedData->mNumVertices);
LLVector4a::memcpyNonAliased16((F32*) mScaledBinormals, (F32*) mSharedData->mBaseNormals, sizeof(LLVector4a) * mSharedData->mNumVertices);
LLVector4a::memcpyNonAliased16((F32*) mTexCoords, (F32*) mSharedData->mTexCoords, sizeof(LLVector2) * (mSharedData->mNumVertices + mSharedData->mNumVertices%2));
memcpy((F32*) mTexCoords, (F32*) mSharedData->mTexCoords, sizeof(LLVector2) * (mSharedData->mNumVertices)); // allocated in LLPolyMeshSharedData::allocateVertexData
for (S32 i = 0; i < mSharedData->mNumVertices; ++i)
{

View File

@ -331,11 +331,33 @@ U32 exception_filter(U32 code, struct _EXCEPTION_POINTERS* exception_infop)
return EXCEPTION_CONTINUE_SEARCH;
}
void sehandle(const LLCoros::callable_t& callable)
void cpphandle(const LLCoros::callable_t& callable, const std::string& name)
{
// SE and C++ can not coexists, thus two handlers
try
{
callable();
}
catch (const LLCoros::Stop& exc)
{
LL_INFOS("LLCoros") << "coroutine " << name << " terminating because "
<< exc.what() << LL_ENDL;
}
catch (const LLContinueError&)
{
// Any uncaught exception derived from LLContinueError will be caught
// here and logged. This coroutine will terminate but the rest of the
// viewer will carry on.
LOG_UNHANDLED_EXCEPTION(STRINGIZE("coroutine " << name));
}
}
void sehandle(const LLCoros::callable_t& callable, const std::string& name)
{
__try
{
callable();
// handle stop and continue exceptions first
cpphandle(callable, name);
}
__except (exception_filter(GetExceptionCode(), GetExceptionInformation()))
{
@ -347,16 +369,7 @@ void sehandle(const LLCoros::callable_t& callable)
throw std::exception(integer_string);
}
}
#else // ! LL_WINDOWS
inline void sehandle(const LLCoros::callable_t& callable)
{
callable();
}
#endif // ! LL_WINDOWS
#endif // LL_WINDOWS
} // anonymous namespace
// Top-level wrapper around caller's coroutine callable.
@ -369,10 +382,14 @@ void LLCoros::toplevel(std::string name, callable_t callable)
// set it as current
mCurrent.reset(&corodata);
#ifdef LL_WINDOWS
// can not use __try directly, toplevel requires unwinding, thus use of a wrapper
sehandle(callable, name);
#else // LL_WINDOWS
// run the code the caller actually wants in the coroutine
try
{
sehandle(callable);
callable();
}
catch (const Stop& exc)
{
@ -386,7 +403,6 @@ void LLCoros::toplevel(std::string name, callable_t callable)
// viewer will carry on.
LOG_UNHANDLED_EXCEPTION(STRINGIZE("coroutine " << name));
}
#ifndef LL_WINDOWS
catch (...)
{
// Stash any OTHER kind of uncaught exception in the rethrow() queue
@ -395,7 +411,7 @@ void LLCoros::toplevel(std::string name, callable_t callable)
<< name << LL_ENDL;
LLCoros::instance().saveException(name, std::current_exception());
}
#endif // ! LL_WINDOWS
#endif // else LL_WINDOWS
}
//static

View File

@ -77,6 +77,15 @@ std::string LLDate::asRFC1123() const
return toHTTPDateString (std::string ("%A, %d %b %Y %H:%M:%S GMT"));
}
std::string LLDate::toLocalDateString (std::string fmt) const
{
LL_PROFILE_ZONE_SCOPED;
time_t locSeconds = (time_t) mSecondsSinceEpoch;
struct tm * lt = localtime (&locSeconds);
return toHTTPDateString(lt, fmt);
}
std::string LLDate::toHTTPDateString (std::string fmt) const
{
LL_PROFILE_ZONE_SCOPED;

View File

@ -79,6 +79,7 @@ public:
std::string asRFC1123() const;
void toStream(std::ostream&) const;
bool split(S32 *year, S32 *month = NULL, S32 *day = NULL, S32 *hour = NULL, S32 *min = NULL, S32 *sec = NULL) const;
std::string toLocalDateString(std::string fmt) const;
std::string toHTTPDateString (std::string fmt) const;
static std::string toHTTPDateString (tm * gmt, std::string fmt);
/**

View File

@ -24,6 +24,8 @@
* $/LicenseInfo$
*/
#include "linden_common.h"
#include "llmath.h"
static LL_ALIGN_16(const F32 M_IDENT_3A[12]) =

View File

@ -24,6 +24,8 @@
* $/LicenseInfo$
*/
#include "linden_common.h"
#include "llmath.h"
#include "llmatrix4a.h"

View File

@ -24,6 +24,8 @@
* $/LicenseInfo$
*/
#include "linden_common.h"
#include "llmath.h"
#include "llrigginginfo.h"

View File

@ -24,6 +24,8 @@
* $/LicenseInfo$
*/
#include "linden_common.h"
#include "llmemory.h"
#include "llmath.h"
#include "llquantize.h"

View File

@ -24,6 +24,8 @@
* $/LicenseInfo$
*/
#include "linden_common.h"
#include "llvolumeoctree.h"
#include "llvector4a.h"

View File

@ -28,6 +28,7 @@
#define LL_V3COLORUTIL_H
#include "v3color.h"
#include "v4color.h"
inline LLColor3 componentDiv(LLColor3 const &left, LLColor3 const & right)
{

View File

@ -465,7 +465,7 @@ void LLProxy::applyProxySettings(CURL* handle)
/**
* @brief Send one TCP packet and receive one in return.
*
* This operation is done synchronously with a 1000ms timeout. Therefore, it should not be used when a blocking
* This operation is done synchronously with a 100ms timeout. Therefore, it should not be used when a blocking
* operation would impact the operation of the viewer.
*
* @param handle_ptr Pointer to a connected LLSocket of type STREAM_TCP.
@ -482,7 +482,7 @@ static apr_status_t tcp_blocking_handshake(LLSocket::ptr_t handle, char * dataou
apr_size_t expected_len = outlen;
handle->setBlocking(100000); // <FS:Beq/> extend the arbitrary timeout value to 100ms. this should be more than enough for most LAN proxies and plenty for a localhost
handle->setBlocking(100000); // 100ms, 100000us. Should be sufficient for localhost, nearby network
rv = apr_socket_send(apr_socket, dataout, &outlen);
if (APR_SUCCESS != rv)

View File

@ -822,11 +822,11 @@ void LLFontFreetype::renderGlyph(EFontGlyphType bitmap_type, U32 glyph_index, ll
|| FT_Err_Invalid_Composite == error
|| (FT_Err_Ok != error && LLStringOps::isEmoji(wch)))
{
glyph_index = FT_Get_Char_Index(mFTFace, '?');
// if '?' is not present, potentially can use last index, that's supposed to be null glyph
if (glyph_index > 0)
// value~0 always corresponds to the 'missing glyph'
error = FT_Load_Glyph(mFTFace, 0, FT_LOAD_FORCE_AUTOHINT);
if (FT_Err_Ok != error)
{
error = FT_Load_Glyph(mFTFace, glyph_index, load_flags ^ FT_LOAD_COLOR);
LL_ERRS() << "Loading fallback for char '" << (U32)wch << "', glyph " << glyph_index << " failed with error : " << (S32)error << LL_ENDL;
}
}

View File

@ -23,9 +23,7 @@
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
// <FS:Ansariel> Remove ugly dependency
//#include "../newview/llviewerprecompiledheaders.h"
#include "linden_common.h"
#include "llflashtimer.h"

View File

@ -31,8 +31,6 @@
#include "llrect.h"
#include "llcoord.h"
#include "llcontrol.h"
#include "llcoord.h"
#include "llcontrol.h"
#include "llinitparam.h"
#include "llregistry.h"
#include "llrender2dutils.h"

View File

@ -125,12 +125,15 @@ LLXmlTreeNode::LLXmlTreeNode( const std::string& name, LLXmlTreeNode* parent, LL
LLXmlTreeNode::~LLXmlTreeNode()
{
attribute_map_t::iterator iter;
for (iter=mAttributes.begin(); iter != mAttributes.end(); iter++)
delete iter->second;
for(LLXmlTreeNode* node : mChildren)
for (auto& attr : mAttributes)
{
delete node;
delete attr.second;
}
mAttributes.clear();
for (auto& child : mChildren)
{
delete child;
}
mChildren.clear();
}

View File

@ -1759,11 +1759,24 @@ if (DARWIN)
LIST(APPEND viewer_SOURCE_FILES llfilepicker_mac.mm)
LIST(APPEND viewer_HEADER_FILES llfilepicker_mac.h)
set_source_files_properties(
llappviewermacosx-objc.mm
PROPERTIES
SKIP_PRECOMPILE_HEADERS TRUE
)
set_source_files_properties(
llfilepicker_mac.mm
PROPERTIES
SKIP_PRECOMPILE_HEADERS TRUE
)
# This should be compiled with the viewer.
LIST(APPEND viewer_SOURCE_FILES llappdelegate-objc.mm)
set_source_files_properties(
llappdelegate-objc.mm
PROPERTIES
SKIP_PRECOMPILE_HEADERS TRUE
COMPILE_DEFINITIONS "${VIEWER_CHANNEL_VERSION_DEFINES}"
# BugsplatMac is a module, imported with @import. That language feature
# demands these -f switches.
@ -2183,7 +2196,11 @@ list(APPEND EVENT_HOST_SCRIPTS ${EVENT_HOST_SCRIPT_GLOB_LIST})
set(PACKAGE ON CACHE BOOL
"Add a package target that builds an installer package.")
if (OPENSIM )
if(USE_PRECOMPILED_HEADERS)
target_precompile_headers( ${VIEWER_BINARY_NAME} PRIVATE llviewerprecompiledheaders.h )
endif(USE_PRECOMPILED_HEADERS)
if (OPENSIM)
set(ND_VIEWER_FLAVOR "oss")
else (OPENSIM)
set(ND_VIEWER_FLAVOR "hvk")
@ -2199,10 +2216,6 @@ if (WINDOWS)
)
target_compile_options(${VIEWER_BINARY_NAME} PRIVATE /bigobj)
if(USE_PRECOMPILED_HEADERS)
target_precompile_headers( ${VIEWER_BINARY_NAME} PRIVATE llviewerprecompiledheaders.h )
endif(USE_PRECOMPILED_HEADERS)
# If adding a file to viewer_manifest.py in the WindowsManifest.construct() method, be sure to add the dependency
# here.
# *NOTE:Mani - This is a crappy hack to have important dependencies for the viewer_manifest copy action

View File

@ -12634,6 +12634,17 @@ Change of this parameter will affect the layout of buttons in notification toast
<key>Value</key>
<integer>1</integer>
</map>
<key>RenderReflectionProbeCount</key>
<map>
<key>Comment</key>
<string>Number of probes to render. Maximum of 256. Clamps to the nearest power of 2.</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>U32</string>
<key>Value</key>
<integer>256</integer>
</map>
<key>RenderReflectionProbeResolution</key>
<map>
<key>Comment</key>

View File

@ -87,6 +87,7 @@ vec3 clampHDRRange(vec3 color)
// This is a safety measure to prevent that.
// As to the specific number there - allegedly some HDR displays expect values to be in the 0-11.2 range. Citation needed.
// -Geenz 2025-03-05
color = mix(color, vec3(1), isinf(color));
color = mix(color, vec3(0.0), isnan(color));
return clamp(color, vec3(0.0), vec3(11.2));
}

View File

@ -86,6 +86,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 1
RenderDisableVintageMode 1 1
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Low Graphics Settings
@ -128,6 +129,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 512
RenderReflectionProbeCount 1 1
//
// Medium Low Graphics Settings
@ -170,6 +172,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 1024
RenderReflectionProbeCount 1 16
//
// Medium Graphics Settings (standard)
@ -211,6 +214,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 32
//
// Medium High Graphics Settings
@ -252,6 +256,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 64
//
// High Graphics Settings (SSAO + sun shadows)
@ -293,6 +298,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 128
//
// High Ultra Graphics Settings (deferred + SSAO + all shadows)
@ -334,6 +340,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Ultra graphics (REALLY PURTY!)
@ -375,6 +382,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Class Unknown Hardware (unknown)
@ -408,6 +416,7 @@ RenderReflectionProbeDetail 0 -1
RenderMirrors 0 0
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 0 0
list Intel
RenderAnisotropic 1 0
@ -429,6 +438,7 @@ RenderMirrors 0 0
RenderGLMultiThreadedTextures 0 0
RenderGLMultiThreadedMedia 0 0
RenderDisableVintageMode 1 0
RenderReflectionProbeCount 0 0
list TexUnit16orLess
RenderTerrainPBRDetail 1 -1

View File

@ -86,6 +86,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 1
RenderDisableVintageMode 1 1
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Low Graphics Settings
@ -128,6 +129,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 512
RenderReflectionProbeCount 1 1
//
// Medium Low Graphics Settings
@ -170,6 +172,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 1024
RenderReflectionProbeCount 1 16
//
// Medium Graphics Settings (standard)
@ -211,6 +214,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 32
//
// Medium High Graphics Settings
@ -252,6 +256,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 64
//
// High Graphics Settings (SSAO + sun shadows)
@ -293,6 +298,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 128
//
// High Ultra Graphics Settings (deferred + SSAO + all shadows)
@ -334,6 +340,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Ultra graphics (REALLY PURTY!)
@ -375,6 +382,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Class Unknown Hardware (unknown)
@ -408,6 +416,7 @@ RenderReflectionProbeDetail 0 -1
RenderMirrors 0 0
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 0 0
list Intel
RenderAnisotropic 1 0
@ -431,6 +440,7 @@ RenderMirrors 0 0
RenderGLMultiThreadedTextures 0 0
RenderGLMultiThreadedMedia 0 0
RenderDisableVintageMode 1 0
RenderReflectionProbeCount 0 0
list TexUnit16orLess
RenderTerrainPBRDetail 1 -1

View File

@ -86,6 +86,7 @@ RenderTonemapMix 1 1
RenderDisableVintageMode 1 1
RenderDownScaleMethod 1 0
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Low Graphics Settings
@ -128,6 +129,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 512
RenderReflectionProbeCount 1 1
//
// Medium Low Graphics Settings
@ -170,6 +172,7 @@ RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 1024
RenderReflectionProbeCount 1 16
//
// Medium Graphics Settings (standard)
@ -211,6 +214,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 32
//
// Medium High Graphics Settings
@ -252,6 +256,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 64
//
// High Graphics Settings (SSAO + sun shadows)
@ -293,6 +298,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 128
//
// High Ultra Graphics Settings (SSAO + all shadows)
@ -334,6 +340,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Ultra graphics (REALLY PURTY!)
@ -375,6 +382,7 @@ RenderExposure 1 1
RenderTonemapType 1 1
RenderTonemapMix 1 0.7
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 1 256
//
// Class Unknown Hardware (unknown)
@ -407,6 +415,7 @@ RenderShadowDetail 0 0
RenderMirrors 0 0
RenderDisableVintageMode 1 0
RenderMaxTextureResolution 1 2048
RenderReflectionProbeCount 0 0
list TexUnit8orLess
RenderDeferredSSAO 0 0
@ -447,6 +456,7 @@ RenderReflectionProbeDetail 0 0
RenderReflectionsEnabled 0 0
RenderMirrors 0 0
RenderDisableVintageMode 1 0
RenderReflectionProbeCount 0 0
list VaryingVectors16orLess
RenderTerrainPBRPlanarSampleCount 1 1

View File

@ -26,8 +26,6 @@
* $/LicenseInfo$
*/
#define GLM_ENABLE_EXPERIMENTAL 1
#include "glm/vec2.hpp"
#include "glm/vec3.hpp"
#include "glm/vec4.hpp"

View File

@ -5172,9 +5172,14 @@ void LLAgent::teleportViaLandmark(const LLUUID& landmark_asset_id)
void LLAgent::doTeleportViaLandmark(const LLUUID& landmark_asset_id)
{
bool is_local(false);
LLViewerRegion* regionp = getRegion();
LLViewerRegion* regionp = getRegion();
if (!regionp)
{
LL_WARNS("Teleport") << "called when agent region is null" << LL_ENDL;
return;
}
bool is_local(false);
if (LLLandmark* landmark = gLandmarkList.getAsset(landmark_asset_id, NULL))
{
LLVector3d pos_global;

View File

@ -1419,8 +1419,6 @@ void AISUpdate::parseCategory(const LLSD& category_map, S32 depth)
&& curr_cat->getVersion() > LLViewerInventoryCategory::VERSION_UNKNOWN
&& version > curr_cat->getVersion())
{
// Potentially should new_cat->setVersion(unknown) here,
// but might be waiting for a callback that would increment
LL_DEBUGS("Inventory") << "Category " << category_id
<< " is stale. Known version: " << curr_cat->getVersion()
<< " server version: " << version << LL_ENDL;

View File

@ -2770,6 +2770,14 @@ void LLAppViewer::initLoggingAndGetLastDuration()
{
LL_WARNS("MarkerFile") << duration_log_msg << LL_ENDL;
}
std::string user_data_path_cef_log = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "cef.log");
if (gDirUtilp->fileExists(user_data_path_cef_log))
{
std::string user_data_path_cef_old = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "cef.old");
LLFile::remove(user_data_path_cef_old, ENOENT);
LLFile::rename(user_data_path_cef_log, user_data_path_cef_old);
}
}
}
@ -3541,9 +3549,10 @@ void LLAppViewer::initStrings()
std::string strings_path_full = gDirUtilp->findSkinnedFilenameBaseLang(LLDir::XUI, strings_file);
if (strings_path_full.empty() || !LLFile::isfile(strings_path_full))
{
std::string crash_reason;
if (strings_path_full.empty())
{
LL_WARNS() << "The file '" << strings_file << "' is not found" << LL_ENDL;
crash_reason = "The file '" + strings_file + "' is not found";
}
else
{
@ -3551,24 +3560,23 @@ void LLAppViewer::initStrings()
int rc = LLFile::stat(strings_path_full, &st);
if (rc != 0)
{
LL_WARNS() << "The file '" << strings_path_full << "' failed to get status. Error code: " << rc << LL_ENDL;
crash_reason = "The file '" + strings_path_full + "' failed to get status. Error code: " + std::to_string(rc);
}
else if (S_ISDIR(st.st_mode))
{
LL_WARNS() << "The filename '" << strings_path_full << "' is a directory name" << LL_ENDL;
crash_reason = "The filename '" + strings_path_full + "' is a directory name";
}
else
{
LL_WARNS() << "The filename '" << strings_path_full << "' doesn't seem to be a regular file name" << LL_ENDL;
crash_reason = "The filename '" + strings_path_full + "' doesn't seem to be a regular file name";
}
}
// initial check to make sure files are there failed
gDirUtilp->dumpCurrentDirectories(LLError::LEVEL_WARN);
LLError::LLUserWarningMsg::showMissingFiles();
LL_ERRS() << "Viewer failed to find localization and UI files."
<< " Please reinstall viewer from https://www.firestormviewer.org/downloads"
<< " and contact https://www.firestormviewer.org/support if issue persists after reinstall." << LL_ENDL;
LL_ERRS() << "Viewer failed to open some of localization and UI files."
<< " " << crash_reason << "." << LL_ENDL;
}
LLTransUtil::parseStrings(strings_file, default_trans_args);
LLTransUtil::parseLanguageStrings("language_settings.xml");

View File

@ -33,6 +33,7 @@
#include "llagentui.h"
#include "llbase64.h"
#include "llcallbacklist.h"
#include "lldate.h"
#include "llenvironment.h"
#include "llimagejpeg.h"
#include "llmediactrl.h"
@ -703,7 +704,15 @@ void LLFloater360Capture::handleMediaEvent(LLPluginClassMedia* self, EMediaEvent
);
// execute the command on the page
mWebBrowser->getMediaPlugin()->executeJavaScript(cmd);
LLPluginClassMedia* plugin = mWebBrowser->getMediaPlugin();
if (plugin)
{
plugin->executeJavaScript(cmd);
}
else
{
LL_WARNS("360Capture") << "No media plugin found" << LL_ENDL;
}
}
}
break;
@ -784,7 +793,15 @@ void LLFloater360Capture::onSaveLocalBtn()
// send it to the browser instance, triggering the equirectangular capture
// process and complimentary offer to save the image
mWebBrowser->getMediaPlugin()->executeJavaScript(cmd);
LLPluginClassMedia* plugin = mWebBrowser->getMediaPlugin();
if (plugin)
{
plugin->executeJavaScript(cmd);
}
else
{
LL_WARNS("360Capture") << "No media plugin found" << LL_ENDL;
}
}
// We capture all 6 images sequentially and if parts of the world are moving
@ -874,15 +891,7 @@ const std::string LLFloater360Capture::generate_proposed_filename()
filename << "_";
// add in the current HH-MM-SS (with leading 0's) so users can easily save many shots in same folder
std::time_t cur_epoch = std::time(nullptr);
std::tm* tm_time = std::localtime(&cur_epoch);
filename << std::setfill('0') << std::setw(4) << (tm_time->tm_year + 1900);
filename << std::setfill('0') << std::setw(2) << (tm_time->tm_mon + 1);
filename << std::setfill('0') << std::setw(2) << tm_time->tm_mday;
filename << "_";
filename << std::setfill('0') << std::setw(2) << tm_time->tm_hour;
filename << std::setfill('0') << std::setw(2) << tm_time->tm_min;
filename << std::setfill('0') << std::setw(2) << tm_time->tm_sec;
filename << LLDate::now().toLocalDateString("%Y%m%d_%H%M%S");
// the unusual way we save the output image (originates in the
// embedded browser and not the C++ code) means that the system

View File

@ -31,6 +31,7 @@
#include "llagent.h"
#include "llagentui.h"
#include "llcombobox.h"
#include "llfloaterreg.h"
#include "llinventoryfunctions.h"
#include "llinventoryobserver.h"
#include "lllandmarkactions.h"
@ -397,6 +398,7 @@ void LLFloaterCreateLandmark::setItem(const uuid_set_t& items)
{
mItem = item;
mAssetID = mItem->getAssetUUID();
mParentID = mItem->getParentUUID();
setVisibleAndFrontmost(true);
break;
}
@ -426,8 +428,7 @@ void LLFloaterCreateLandmark::updateItem(const uuid_set_t& items, U32 mask)
closeFloater();
}
LLUUID folder_id = mFolderCombo->getValue().asUUID();
if (folder_id != mItem->getParentUUID())
if (mParentID != mItem->getParentUUID())
{
// user moved landmark in inventory,
// assume that we are done all other changes should already be commited

View File

@ -69,6 +69,7 @@ private:
LLTextEditor* mNotesEditor;
LLUUID mLandmarksID;
LLUUID mAssetID;
LLUUID mParentID;
LLLandmarksInventoryObserver* mInventoryObserver;
LLPointer<LLInventoryItem> mItem;

View File

@ -60,8 +60,7 @@ static const S32 USED_EMOJIS_IMAGE_INDEX = 0x23F2;
// https://www.compart.com/en/unicode/U+1F6D1
static const S32 EMPTY_LIST_IMAGE_INDEX = 0x1F6D1;
// The following categories should follow the required alphabetic order
static const std::string RECENTLY_USED_CATEGORY = "1 recently used";
static const std::string FREQUENTLY_USED_CATEGORY = "2 frequently used";
static const std::string FREQUENTLY_USED_CATEGORY = "frequently used";
// Floater state related variables
static std::list<llwchar> sRecentlyUsed;
@ -459,11 +458,10 @@ void LLFloaterEmojiPicker::fillGroups()
params.name = "all_categories";
createGroupButton(params, rect, ALL_EMOJIS_IMAGE_INDEX);
// Create group and button for "Recently used" and/or "Frequently used"
if (!sRecentlyUsed.empty() || !sFrequentlyUsed.empty())
// Create group and button for "Frequently used"
if (!sFrequentlyUsed.empty())
{
std::map<std::string, std::vector<LLEmojiSearchResult>> cats;
fillCategoryRecentlyUsed(cats);
fillCategoryFrequentlyUsed(cats);
if (!cats.empty())
@ -496,40 +494,6 @@ void LLFloaterEmojiPicker::fillGroups()
resizeGroupButtons();
}
void LLFloaterEmojiPicker::fillCategoryRecentlyUsed(std::map<std::string, std::vector<LLEmojiSearchResult>>& cats)
{
if (sRecentlyUsed.empty())
return;
std::vector<LLEmojiSearchResult> emojis;
// In case of empty mFilterPattern we'd use sRecentlyUsed directly
if (!mFilterPattern.empty())
{
// List all emojis in "Recently used"
const LLEmojiDictionary::emoji2descr_map_t& emoji2descr = LLEmojiDictionary::instance().getEmoji2Descr();
std::size_t begin, end;
for (llwchar emoji : sRecentlyUsed)
{
auto e2d = emoji2descr.find(emoji);
if (e2d != emoji2descr.end() && !e2d->second->ShortCodes.empty())
{
for (const std::string& shortcode : e2d->second->ShortCodes)
{
if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern))
{
emojis.emplace_back(emoji, shortcode, begin, end);
}
}
}
}
if (emojis.empty())
return;
}
cats.emplace(std::make_pair(RECENTLY_USED_CATEGORY, emojis));
}
void LLFloaterEmojiPicker::fillCategoryFrequentlyUsed(std::map<std::string, std::vector<LLEmojiSearchResult>>& cats)
{
if (sFrequentlyUsed.empty())
@ -770,7 +734,6 @@ void LLFloaterEmojiPicker::fillEmojisCategory(const std::vector<LLEmojiSearchRes
{
// Place the category title
std::string title =
category == RECENTLY_USED_CATEGORY ? getString("title_for_recently_used") :
category == FREQUENTLY_USED_CATEGORY ? getString("title_for_frequently_used") :
isupper(category.front()) ? category : LLStringUtil::capitalize(category);
LLEmojiGridDivider* div = new LLEmojiGridDivider(row_panel_params, title);
@ -783,21 +746,7 @@ void LLFloaterEmojiPicker::fillEmojisCategory(const std::vector<LLEmojiSearchRes
{
const LLEmojiDictionary::emoji2descr_map_t& emoji2descr = LLEmojiDictionary::instance().getEmoji2Descr();
LLEmojiSearchResult emoji { 0, "", 0, 0 };
if (category == RECENTLY_USED_CATEGORY)
{
for (llwchar code : sRecentlyUsed)
{
const LLEmojiDictionary::emoji2descr_map_t::const_iterator& e2d = emoji2descr.find(code);
if (e2d != emoji2descr.end() && !e2d->second->ShortCodes.empty())
{
emoji.Character = code;
emoji.String = e2d->second->ShortCodes.front();
createEmojiIcon(emoji, category, row_panel_params, row_list_params, icon_params,
icon_rect, max_icons, bg, row, icon_index);
}
}
}
else if (category == FREQUENTLY_USED_CATEGORY)
if (category == FREQUENTLY_USED_CATEGORY)
{
for (const auto& code : sFrequentlyUsed)
{

View File

@ -68,7 +68,6 @@ public:
private:
void initialize();
void fillGroups();
void fillCategoryRecentlyUsed(std::map<std::string, std::vector<LLEmojiSearchResult>>& cats);
void fillCategoryFrequentlyUsed(std::map<std::string, std::vector<LLEmojiSearchResult>>& cats);
void fillGroupEmojis(std::map<std::string, std::vector<LLEmojiSearchResult>>& cats, U32 index);
void createGroupButton(LLButton::Params& params, const LLRect& rect, llwchar emoji);

View File

@ -115,12 +115,12 @@ bool LLFloaterPerformance::postBuild()
mHUDList = mHUDsPanel->getChild<LLNameListCtrl>("hud_list");
mHUDList->setNameListType(LLNameListCtrl::SPECIAL);
mHUDList->setHoverIconName("StopReload_Off");
mHUDList->setIconClickedCallback(boost::bind(&LLFloaterPerformance::detachItem, this, _1));
mHUDList->setIconClickedCallback(boost::bind(&LLFloaterPerformance::detachObject, this, _1));
mObjectList = mComplexityPanel->getChild<LLNameListCtrl>("obj_list");
mObjectList->setNameListType(LLNameListCtrl::SPECIAL);
mObjectList->setHoverIconName("StopReload_Off");
mObjectList->setIconClickedCallback(boost::bind(&LLFloaterPerformance::detachItem, this, _1));
mObjectList->setIconClickedCallback(boost::bind(&LLFloaterPerformance::detachObject, this, _1));
mSettingsPanel->getChild<LLButton>("advanced_btn")->setCommitCallback(boost::bind(&LLFloaterPerformance::onClickAdvanced, this));
mSettingsPanel->getChild<LLButton>("defaults_btn")->setCommitCallback(boost::bind(&LLFloaterPerformance::onClickDefaults, this));
@ -527,9 +527,13 @@ void LLFloaterPerformance::setFPSText()
mTextFPSLabel->setValue(fps_text);
}
void LLFloaterPerformance::detachItem(const LLUUID& item_id)
void LLFloaterPerformance::detachObject(const LLUUID& obj_id)
{
LLAppearanceMgr::instance().removeItemFromAvatar(item_id);
LLViewerObject* obj = gObjectList.findObject(obj_id);
if (obj)
{
LLAppearanceMgr::instance().removeItemFromAvatar(obj->getAttachmentItemID());
}
}
void LLFloaterPerformance::onClickAdvanced()

View File

@ -48,7 +48,7 @@ public:
void hidePanels();
void showAutoadjustmentsPanel();
void detachItem(const LLUUID& item_id);
void detachObject(const LLUUID& obj_id);
void onAvatarListRightClick(LLUICtrl* ctrl, S32 x, S32 y);

View File

@ -510,6 +510,7 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key)
// mCommitCallbackRegistrar.add("Pref.AutoAdjustments", boost::bind(&LLFloaterPreference::onClickAutoAdjustments, this)); // <FS:Beq/> Not required in FS at present
mCommitCallbackRegistrar.add("Pref.HardwareDefaults", boost::bind(&LLFloaterPreference::setHardwareDefaults, this));
mCommitCallbackRegistrar.add("Pref.AvatarImpostorsEnable", boost::bind(&LLFloaterPreference::onAvatarImpostorsEnable, this));
mCommitCallbackRegistrar.add("Pref.UpdateIndirectMaxNonImpostors", boost::bind(&LLFloaterPreference::updateMaxNonImpostors, this));
mCommitCallbackRegistrar.add("Pref.UpdateIndirectMaxComplexity", boost::bind(&LLFloaterPreference::updateMaxComplexity, this));
mCommitCallbackRegistrar.add("Pref.RenderOptionUpdate", boost::bind(&LLFloaterPreference::onRenderOptionEnable, this));
mCommitCallbackRegistrar.add("Pref.LocalLightsEnable", boost::bind(&LLFloaterPreference::onLocalLightsEnable, this));
@ -528,10 +529,6 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key)
mCommitCallbackRegistrar.add("Pref.SpellChecker", boost::bind(&LLFloaterPreference::onClickSpellChecker, this));
mCommitCallbackRegistrar.add("Pref.Advanced", boost::bind(&LLFloaterPreference::onClickAdvanced, this));
// <FS:Ansariel> Improved graphics preferences
mCommitCallbackRegistrar.add("Pref.UpdateIndirectMaxNonImpostors", boost::bind(&LLFloaterPreference::updateMaxNonImpostors, this));
// </FS:Ansariel>
// <FS:Zi> Support preferences search SLURLs
mCommitCallbackRegistrar.add("Pref.CopySearchAsSLURL", boost::bind(&LLFloaterPreference::onCopySearch, this));
// </FS_ZI>
@ -550,6 +547,7 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key)
LLAvatarPropertiesProcessor::getInstance()->addObserver( gAgent.getID(), this );
mComplexityChangedSignal = gSavedSettings.getControl("RenderAvatarMaxComplexity")->getCommitSignal()->connect(boost::bind(&LLFloaterPreference::updateComplexityText, this));
mImpostorsChangedSignal = gSavedSettings.getControl("RenderAvatarMaxNonImpostors")->getSignal()->connect(boost::bind(&LLFloaterPreference::updateIndirectMaxNonImpostors, this, _2));
mCommitCallbackRegistrar.add("Pref.ClearLog", boost::bind(&LLConversationLog::onClearLog, &LLConversationLog::instance()));
mCommitCallbackRegistrar.add("Pref.DeleteTranscripts", boost::bind(&LLFloaterPreference::onDeleteTranscripts, this));
@ -945,7 +943,12 @@ void LLFloaterPreference::onDoNotDisturbResponseChanged()
LLFloaterPreference::~LLFloaterPreference()
{
LLConversationLog::instance().removeObserver(this);
if (LLAvatarPropertiesProcessor::instanceExists())
{
LLAvatarPropertiesProcessor::getInstance()->removeObserver(gAgent.getID(), this);
}
mComplexityChangedSignal.disconnect();
mImpostorsChangedSignal.disconnect();
}
// <FS:Zi> FIRE-19539 - Include the alert messages in Prefs>Notifications>Alerts in preference Search.
@ -2342,9 +2345,11 @@ void LLFloaterPreference::refresh()
getChild<LLUICtrl>("fsaa")->setValue((LLSD::Integer) gSavedSettings.getU32("RenderFSAASamples"));
updateSliderText(getChild<LLSliderCtrl>("RenderPostProcess", true), getChild<LLTextBox>("PostProcessText", true));
LLAvatarComplexityControls::setIndirectControls();
setMaxNonImpostorsText(gSavedSettings.getU32("RenderAvatarMaxNonImpostors"),getChild<LLTextBox>("IndirectMaxNonImpostorsText", true));
// </FS:Ansariel>
setMaxNonImpostorsText(
gSavedSettings.getU32("RenderAvatarMaxNonImpostors"),
getChild<LLTextBox>("IndirectMaxNonImpostorsText", true));
LLAvatarComplexityControls::setText(
gSavedSettings.getU32("RenderAvatarMaxComplexity"),
getChild<LLTextBox>("IndirectMaxComplexityText", true));
@ -2647,7 +2652,6 @@ void LLFloaterPreference::setPersonalInfo(const std::string& visibility, bool im
getChild<LLUICtrl>("voice_call_friends_only_check")->setValue(gSavedPerAccountSettings.getBOOL("VoiceCallsFriendsOnly"));
}
void LLFloaterPreference::refreshUI()
{
refresh();
@ -2683,34 +2687,6 @@ void LLFloaterPreference::updateSliderText(LLSliderCtrl* ctrl, LLTextBox* text_b
}
}
void LLFloaterPreference::updateMaxNonImpostors()
{
// Called when the IndirectMaxNonImpostors control changes
// Responsible for fixing the slider label (IndirectMaxNonImpostorsText) and setting RenderAvatarMaxNonImpostors
LLSliderCtrl* ctrl = getChild<LLSliderCtrl>("IndirectMaxNonImpostors",true);
U32 value = ctrl->getValue().asInteger();
if (0 == value || LLVOAvatar::NON_IMPOSTORS_MAX_SLIDER <= value)
{
value=0;
}
gSavedSettings.setU32("RenderAvatarMaxNonImpostors", value);
LLVOAvatar::updateImpostorRendering(value); // make it effective immediately
setMaxNonImpostorsText(value, getChild<LLTextBox>("IndirectMaxNonImpostorsText"));
}
void LLFloaterPreference::setMaxNonImpostorsText(U32 value, LLTextBox* text_box)
{
if (0 == value)
{
text_box->setText(LLTrans::getString("no_limit"));
}
else
{
text_box->setText(llformat("%d", value));
}
}
void LLFloaterPreference::updateMaxNonImpostorsLabel(const LLSD& newvalue)
{
U32 value = newvalue.asInteger();
@ -2790,6 +2766,44 @@ void LLAvatarComplexityControls::setRenderTimeText(F32 value, LLTextBox* text_bo
}
}
void LLFloaterPreference::updateMaxNonImpostors()
{
// Called when the IndirectMaxNonImpostors control changes
// Responsible for fixing the slider label (IndirectMaxNonImpostorsText) and setting RenderAvatarMaxNonImpostors
LLSliderCtrl* ctrl = getChild<LLSliderCtrl>("IndirectMaxNonImpostors", true);
U32 value = ctrl->getValue().asInteger();
if (0 == value || LLVOAvatar::NON_IMPOSTORS_MAX_SLIDER <= value)
{
value = 0;
}
gSavedSettings.setU32("RenderAvatarMaxNonImpostors", value);
LLVOAvatar::updateImpostorRendering(value); // make it effective immediately
setMaxNonImpostorsText(value, getChild<LLTextBox>("IndirectMaxNonImpostorsText"));
}
void LLFloaterPreference::updateIndirectMaxNonImpostors(const LLSD& newvalue)
{
U32 value = newvalue.asInteger();
if ((value != 0) && (value != gSavedSettings.getU32("IndirectMaxNonImpostors")))
{
gSavedSettings.setU32("IndirectMaxNonImpostors", value);
}
setMaxNonImpostorsText(value, getChild<LLTextBox>("IndirectMaxNonImpostorsText"));
}
void LLFloaterPreference::setMaxNonImpostorsText(U32 value, LLTextBox* text_box)
{
if (0 == value)
{
text_box->setText(LLTrans::getString("no_limit"));
}
else
{
text_box->setText(llformat("%d", value));
}
}
void LLFloaterPreference::updateMaxComplexity()
{
// Called when the IndirectMaxComplexity control changes

View File

@ -251,8 +251,6 @@ public:
// <FS:Ansariel> Improved graphics preferences
void updateSliderText(LLSliderCtrl* ctrl, LLTextBox* text_box);
void updateMaxNonImpostors();
void setMaxNonImpostorsText(U32 value, LLTextBox* text_box);
void updateMaxNonImpostorsLabel(const LLSD& newvalue);
void updateMaxComplexityLabel(const LLSD& newvalue);
// </FS:Ansariel>
@ -303,6 +301,9 @@ private:
void onDeleteTranscripts();
void onDeleteTranscriptsResponse(const LLSD& notification, const LLSD& response);
void updateDeleteTranscriptsButton();
void updateMaxNonImpostors();
void updateIndirectMaxNonImpostors(const LLSD& newvalue);
void setMaxNonImpostorsText(U32 value, LLTextBox* text_box);
void updateMaxComplexity();
void updateComplexityText();
static bool loadFromFilename(const std::string& filename, std::map<std::string, std::string> &label_map);
@ -332,6 +333,7 @@ private:
std::unique_ptr< ll::prefs::SearchData > mSearchData;
bool mSearchDataDirty;
boost::signals2::connection mImpostorsChangedSignal;
boost::signals2::connection mComplexityChangedSignal;
void onUpdateFilterTerm( bool force = false );

View File

@ -52,6 +52,8 @@ LLFloaterPreferenceGraphicsAdvanced::LLFloaterPreferenceGraphicsAdvanced(const L
mCommitCallbackRegistrar.add("Pref.Cancel", boost::bind(&LLFloaterPreferenceGraphicsAdvanced::onBtnCancel, this, _2));
mCommitCallbackRegistrar.add("Pref.OK", boost::bind(&LLFloaterPreferenceGraphicsAdvanced::onBtnOK, this, _2));
mImpostorsChangedSignal = gSavedSettings.getControl("RenderAvatarMaxNonImpostors")->getSignal()->connect(boost::bind(&LLFloaterPreferenceGraphicsAdvanced::updateIndirectMaxNonImpostors, this, _2));
}
LLFloaterPreferenceGraphicsAdvanced::~LLFloaterPreferenceGraphicsAdvanced()
@ -59,7 +61,6 @@ LLFloaterPreferenceGraphicsAdvanced::~LLFloaterPreferenceGraphicsAdvanced()
mComplexityChangedSignal.disconnect();
mComplexityModeChangedSignal.disconnect();
mLODFactorChangedSignal.disconnect();
mNumImpostorsChangedSignal.disconnect();
}
bool LLFloaterPreferenceGraphicsAdvanced::postBuild()
@ -255,8 +256,8 @@ void LLFloaterPreferenceGraphicsAdvanced::updateIndirectMaxNonImpostors(const LL
if ((value != 0) && (value != gSavedSettings.getU32("IndirectMaxNonImpostors")))
{
gSavedSettings.setU32("IndirectMaxNonImpostors", value);
setMaxNonImpostorsText(value, getChild<LLTextBox>("IndirectMaxNonImpostorsText"));
}
setMaxNonImpostorsText(value, getChild<LLTextBox>("IndirectMaxNonImpostorsText"));
}
void LLFloaterPreferenceGraphicsAdvanced::setMaxNonImpostorsText(U32 value, LLTextBox* text_box)

View File

@ -61,6 +61,7 @@ protected:
void onBtnOK(const LLSD& userdata);
void onBtnCancel(const LLSD& userdata);
boost::signals2::connection mImpostorsChangedSignal;
boost::signals2::connection mComplexityChangedSignal;
boost::signals2::connection mComplexityModeChangedSignal;
boost::signals2::connection mLODFactorChangedSignal;

View File

@ -891,7 +891,7 @@ void LLInvFVBridge::getClipboardEntries(bool show_asset_id,
disabled_items.push_back(std::string("Copy"));
}
if (isAgentInventory() && !single_folder_root)
if (isAgentInventory() && !single_folder_root && !isMarketplaceListingsFolder())
{
items.push_back(std::string("New folder from selected"));
items.push_back(std::string("Subfolder Separator"));
@ -5894,7 +5894,7 @@ void LLFolderBridge::dropToMyOutfits(LLInventoryCategory* inv_cat, LLPointer<LLI
// Note: creation will take time, so passing folder id to callback is slightly unreliable,
// but so is collecting and passing descendants' ids
inventory_func_type func = boost::bind(&LLFolderBridge::outfitFolderCreatedCallback, this, inv_cat->getUUID(), _1, cb);
inventory_func_type func = boost::bind(outfitFolderCreatedCallback, inv_cat->getUUID(), _1, cb, mInventoryPanel);
gInventory.createNewCategory(dest_id,
LLFolderType::FT_OUTFIT,
inv_cat->getName(),
@ -5902,11 +5902,25 @@ void LLFolderBridge::dropToMyOutfits(LLInventoryCategory* inv_cat, LLPointer<LLI
inv_cat->getThumbnailUUID());
}
void LLFolderBridge::outfitFolderCreatedCallback(LLUUID cat_source_id, LLUUID cat_dest_id, LLPointer<LLInventoryCallback> cb)
void LLFolderBridge::outfitFolderCreatedCallback(LLUUID cat_source_id,
LLUUID cat_dest_id,
LLPointer<LLInventoryCallback> cb,
LLHandle<LLInventoryPanel> inventory_panel)
{
LLInventoryModel::cat_array_t* categories;
LLInventoryModel::item_array_t* items;
getInventoryModel()->getDirectDescendentsOf(cat_source_id, categories, items);
LLInventoryPanel* panel = inventory_panel.get();
if (!panel)
{
return;
}
LLInventoryModel* model = panel->getModel();
if (!model)
{
return;
}
model->getDirectDescendentsOf(cat_source_id, categories, items);
LLInventoryObject::const_object_list_t link_array;

View File

@ -406,7 +406,10 @@ public:
static void staticFolderOptionsMenu();
protected:
void outfitFolderCreatedCallback(LLUUID cat_source_id, LLUUID cat_dest_id, LLPointer<LLInventoryCallback> cb);
static void outfitFolderCreatedCallback(LLUUID cat_source_id,
LLUUID cat_dest_id,
LLPointer<LLInventoryCallback> cb,
LLHandle<LLInventoryPanel> inventory_panel);
void callback_pasteFromClipboard(const LLSD& notification, const LLSD& response);
void perform_pasteFromClipboard();
void gatherMessage(std::string& message, S32 depth, LLError::ELevel log_level);

View File

@ -99,7 +99,7 @@ void LLInventoryItemsList::updateSelection()
for(std::vector<LLSD>::const_iterator cur_id_it = cur.begin(); cur_id_it != cur.end() && !mSelectTheseIDs.empty(); ++cur_id_it)
{
uuid_vec_t::iterator select_ids_it = std::find(mSelectTheseIDs.begin(), mSelectTheseIDs.end(), *cur_id_it);
uuid_vec_t::iterator select_ids_it = std::find(mSelectTheseIDs.begin(), mSelectTheseIDs.end(), cur_id_it->asUUID());
if(select_ids_it != mSelectTheseIDs.end())
{
selectItemByUUID(*select_ids_it);

View File

@ -30,6 +30,7 @@
#include "llaisapi.h"
#include "llagent.h"
#include "llappviewer.h"
#include "llappearancemgr.h"
#include "llcallbacklist.h"
#include "llinventorymodel.h"
#include "llinventorypanel.h"
@ -474,6 +475,22 @@ void LLInventoryModelBackgroundFetch::fetchCOF(nullary_func_t callback)
callback();
LLUUID cat_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CURRENT_OUTFIT);
LLInventoryModelBackgroundFetch::getInstance()->onAISFolderCalback(cat_id, id, FT_DEFAULT);
if (id.notNull())
{
// COF might have fetched base outfit folder through a link, but it hasn't
// fetched base outfit's content, which doesn't nessesary match COF,
// so make sure it's up to date
LLUUID baseoutfit_id = LLAppearanceMgr::getInstance()->getBaseOutfitUUID();
if (baseoutfit_id.notNull())
{
LLViewerInventoryCategory* cat = gInventory.getCategory(baseoutfit_id);
if (!cat || cat->getVersion() == LLViewerInventoryCategory::VERSION_UNKNOWN)
{
LLInventoryModelBackgroundFetch::getInstance()->fetchFolderAndLinks(baseoutfit_id, no_op);
}
}
}
});
// start idle loop to track completion

View File

@ -1035,8 +1035,8 @@ void LLOutfitListBase::onIdleRefreshList()
if (cat)
{
std::string name = cat->getName();
updateChangedCategoryName(cat, name);
}
updateChangedCategoryName(cat, name);
}
curent_time = LLTimer::getTotalSeconds();
if (curent_time >= end_time)

View File

@ -266,6 +266,15 @@ void LLPanelClassifiedInfo::processProperties(void* data, EAvatarProcessorType t
}
}
void LLPanelClassifiedInfo::setAvatarId(const LLUUID& avatar_id)
{
if (mAvatarId.notNull())
{
LLAvatarPropertiesProcessor::getInstance()->removeObserver(mAvatarId, this);
}
mAvatarId = avatar_id;
}
void LLPanelClassifiedInfo::resetData()
{
setClassifiedName(LLStringUtil::null);

View File

@ -53,7 +53,7 @@ public:
/*virtual*/ void processProperties(void* data, EAvatarProcessorType type);
void setAvatarId(const LLUUID& avatar_id) { mAvatarId = avatar_id; }
void setAvatarId(const LLUUID& avatar_id);
LLUUID& getAvatarId() { return mAvatarId; }

View File

@ -73,6 +73,9 @@ LLPanelEmojiComplete::LLPanelEmojiComplete(const LLPanelEmojiComplete::Params& p
{
LLScrollbar::Params sbparams;
sbparams.orientation(LLScrollbar::VERTICAL);
sbparams.doc_size(static_cast<S32>(mTotalEmojis));
sbparams.doc_pos(0);
sbparams.page_size(static_cast<S32>(mVisibleEmojis));
sbparams.change_callback([this](S32 index, LLScrollbar*) { onScrollbarChange(index); });
mScrollbar = LLUICtrlFactory::create<LLScrollbar>(sbparams);
addChild(mScrollbar);

View File

@ -2616,14 +2616,11 @@ void LLPanelMainInventory::onVisibilityChange( bool new_visibility )
{
menu->setVisible(false);
}
// <FS:Ansariel> FIRE-20109: Crash at start using Vintage skin
//getActivePanel()->getRootFolder()->finishRenamingItem();
LLInventoryPanel* panel = getActivePanel();
if (panel)
LLFolderView* root_folder = mActivePanel ? mActivePanel->getRootFolder() : nullptr;
if (root_folder)
{
panel->getRootFolder()->finishRenamingItem();
root_folder->finishRenamingItem();
}
// </FS:Ansariel>
}
}

View File

@ -80,6 +80,13 @@ class LLClassifiedHandler : public LLCommandHandler, public LLAvatarPropertiesOb
public:
// throttle calls from untrusted browsers
LLClassifiedHandler() : LLCommandHandler("classified", UNTRUSTED_THROTTLE) {}
virtual ~LLClassifiedHandler()
{
if (LLAvatarPropertiesProcessor::instanceExists())
{
LLAvatarPropertiesProcessor::getInstance()->removeObserver(LLUUID(), this);
}
}
std::set<LLUUID> mClassifiedIds;
std::string mRequestVerb;

View File

@ -221,6 +221,14 @@ void LLReflectionMapManager::update()
resume();
}
static LLCachedControl<U32> probe_count(gSavedSettings, "RenderReflectionProbeCount", 256U);
bool countReset = mReflectionProbeCount != probe_count;
if (countReset)
{
mResetFade = -0.5f;
}
initReflectionMaps();
static LLCachedControl<bool> render_hdr(gSavedSettings, "RenderHDREnabled", true);
@ -335,6 +343,13 @@ void LLReflectionMapManager::update()
}
}
if (countReset)
{
mResetFade = -0.5f;
}
mResetFade = llmin((F32)(mResetFade + gFrameIntervalSeconds), 1.f);
for (unsigned int i = 0; i < mProbes.size(); ++i)
{
LLReflectionMap* probe = mProbes[i];
@ -1012,60 +1027,18 @@ void LLReflectionMapManager::updateUniforms()
LL_PROFILE_ZONE_SCOPED_CATEGORY_DISPLAY;
// structure for packing uniform buffer object
// see class3/deferred/reflectionProbeF.glsl
struct ReflectionProbeData
{
// for box probes, matrix that transforms from camera space to a [-1, 1] cube representing the bounding box of
// the box probe
LLMatrix4 refBox[LL_MAX_REFLECTION_PROBE_COUNT];
LLMatrix4 heroBox;
// for sphere probes, origin (xyz) and radius (w) of refmaps in clip space
LLVector4 refSphere[LL_MAX_REFLECTION_PROBE_COUNT];
// extra parameters
// x - irradiance scale
// y - radiance scale
// z - fade in
// w - znear
LLVector4 refParams[LL_MAX_REFLECTION_PROBE_COUNT];
LLVector4 heroSphere;
// indices used by probe:
// [i][0] - cubemap array index for this probe
// [i][1] - index into "refNeighbor" for probes that intersect this probe
// [i][2] - number of probes that intersect this probe, or -1 for no neighbors
// [i][3] - priority (probe type stored in sign bit - positive for spheres, negative for boxes)
GLint refIndex[LL_MAX_REFLECTION_PROBE_COUNT][4];
// list of neighbor indices
GLint refNeighbor[4096];
GLint refBucket[256][4]; //lookup table for which index to start with for the given Z depth
// numbrer of active refmaps
GLint refmapCount;
GLint heroShape;
GLint heroMipCount;
GLint heroProbeCount;
};
mReflectionMaps.resize(mReflectionProbeCount);
getReflectionMaps(mReflectionMaps);
ReflectionProbeData rpd;
F32 minDepth[256];
for (int i = 0; i < 256; ++i)
{
rpd.refBucket[i][0] = mReflectionProbeCount;
rpd.refBucket[i][1] = mReflectionProbeCount;
rpd.refBucket[i][2] = mReflectionProbeCount;
rpd.refBucket[i][3] = mReflectionProbeCount;
mProbeData.refBucket[i][0] = mReflectionProbeCount;
mProbeData.refBucket[i][1] = mReflectionProbeCount;
mProbeData.refBucket[i][2] = mReflectionProbeCount;
mProbeData.refBucket[i][3] = mReflectionProbeCount;
minDepth[i] = FLT_MAX;
}
@ -1111,7 +1084,7 @@ void LLReflectionMapManager::updateUniforms()
if (refmap->mMinDepth < minDepth[i])
{
minDepth[i] = refmap->mMinDepth;
rpd.refBucket[i][0] = refmap->mProbeIndex;
mProbeData.refBucket[i][0] = refmap->mProbeIndex;
}
}
}
@ -1139,25 +1112,25 @@ void LLReflectionMapManager::updateUniforms()
}
}
modelview.affineTransform(refmap->mOrigin, oa);
rpd.refSphere[count].set(oa.getF32ptr());
rpd.refSphere[count].mV[3] = refmap->mRadius;
mProbeData.refSphere[count].set(oa.getF32ptr());
mProbeData.refSphere[count].mV[3] = refmap->mRadius;
}
rpd.refIndex[count][0] = refmap->mCubeIndex;
mProbeData.refIndex[count][0] = refmap->mCubeIndex;
llassert(nc % 4 == 0);
rpd.refIndex[count][1] = nc / 4;
rpd.refIndex[count][3] = refmap->mPriority;
mProbeData.refIndex[count][1] = nc / 4;
mProbeData.refIndex[count][3] = refmap->mPriority;
// for objects that are reflection probes, use the volume as the influence volume of the probe
// only possibile influence volumes are boxes and spheres, so detect boxes and treat everything else as spheres
if (refmap->getBox(rpd.refBox[count]))
if (refmap->getBox(mProbeData.refBox[count]))
{ // negate priority to indicate this probe has a box influence volume
rpd.refIndex[count][3] = -rpd.refIndex[count][3];
mProbeData.refIndex[count][3] = -mProbeData.refIndex[count][3];
}
rpd.refParams[count].set(
llmax(minimum_ambiance, refmap->getAmbiance())*ambscale, // ambiance scale
radscale, // radiance scale
mProbeData.refParams[count].set(
llmax(minimum_ambiance, refmap->getAmbiance())*ambscale * llmax(mResetFade, 0.f), // ambiance scale
radscale * llmax(mResetFade, 0.f), // radiance scale
refmap->mFadeIn, // fade in weight
oa.getF32ptr()[2] - refmap->mRadius); // z near
@ -1182,7 +1155,7 @@ void LLReflectionMapManager::updateUniforms()
}
// this neighbor may be sampled
rpd.refNeighbor[ni++] = idx;
mProbeData.refNeighbor[ni++] = idx;
neighbor_count++;
if (neighbor_count >= max_neighbors)
@ -1195,11 +1168,11 @@ void LLReflectionMapManager::updateUniforms()
if (nc == ni)
{
//no neighbors, tag as empty
rpd.refIndex[count][1] = -1;
mProbeData.refIndex[count][1] = -1;
}
else
{
rpd.refIndex[count][2] = ni - nc;
mProbeData.refIndex[count][2] = ni - nc;
// move the cursor forward
nc = ni;
@ -1237,19 +1210,19 @@ void LLReflectionMapManager::updateUniforms()
}
#endif
rpd.refmapCount = count;
mProbeData.refmapCount = count;
gPipeline.mHeroProbeManager.updateUniforms();
// Get the hero data.
rpd.heroBox = gPipeline.mHeroProbeManager.mHeroData.heroBox;
rpd.heroSphere = gPipeline.mHeroProbeManager.mHeroData.heroSphere;
rpd.heroShape = gPipeline.mHeroProbeManager.mHeroData.heroShape;
rpd.heroMipCount = gPipeline.mHeroProbeManager.mHeroData.heroMipCount;
rpd.heroProbeCount = gPipeline.mHeroProbeManager.mHeroData.heroProbeCount;
mProbeData.heroBox = gPipeline.mHeroProbeManager.mHeroData.heroBox;
mProbeData.heroSphere = gPipeline.mHeroProbeManager.mHeroData.heroSphere;
mProbeData.heroShape = gPipeline.mHeroProbeManager.mHeroData.heroShape;
mProbeData.heroMipCount = gPipeline.mHeroProbeManager.mHeroData.heroMipCount;
mProbeData.heroProbeCount = gPipeline.mHeroProbeManager.mHeroData.heroProbeCount;
//copy rpd into uniform buffer object
//copy mProbeData into uniform buffer object
if (mUBO == 0)
{
glGenBuffers(1, &mUBO);
@ -1258,7 +1231,7 @@ void LLReflectionMapManager::updateUniforms()
{
LL_PROFILE_ZONE_NAMED_CATEGORY_DISPLAY("rmmsu - update buffer");
glBindBuffer(GL_UNIFORM_BUFFER, mUBO);
glBufferData(GL_UNIFORM_BUFFER, sizeof(ReflectionProbeData), &rpd, GL_STREAM_DRAW);
glBufferData(GL_UNIFORM_BUFFER, sizeof(ReflectionProbeData), &mProbeData, GL_STREAM_DRAW);
glBindBuffer(GL_UNIFORM_BUFFER, 0);
}
@ -1392,7 +1365,8 @@ void LLReflectionMapManager::renderDebug()
void LLReflectionMapManager::initReflectionMaps()
{
U32 count = LL_MAX_REFLECTION_PROBE_COUNT;
static LLCachedControl<U32> probe_count(gSavedSettings, "RenderReflectionProbeCount", 256U);
U32 count = probe_count();
static LLCachedControl<U32> ref_probe_res(gSavedSettings, "RenderReflectionProbeResolution", 128U);
U32 probe_resolution = nhpo2(llclamp(ref_probe_res(), (U32)64, (U32)512));

View File

@ -56,6 +56,51 @@ public:
REALTIME = 2
};
// General guidance for UBOs is to statically allocate all of these fields to make your life ever so slightly easier.
// Then set a "max" value for the number of probes you'll ever have, and use that to index into the arrays.
// We do this with refmapCount. The shaders will just pick up on it there.
// This data structure should _always_ match what's in class3/deferred/reflectionProbeF.glsl.
// The shader can and will break otherwise.
// -Geenz 2025-03-10
struct ReflectionProbeData
{
// for box probes, matrix that transforms from camera space to a [-1, 1] cube representing the bounding box of
// the box probe
LLMatrix4 refBox[LL_MAX_REFLECTION_PROBE_COUNT];
LLMatrix4 heroBox;
// for sphere probes, origin (xyz) and radius (w) of refmaps in clip space
LLVector4 refSphere[LL_MAX_REFLECTION_PROBE_COUNT];
// extra parameters
// x - irradiance scale
// y - radiance scale
// z - fade in
// w - znear
LLVector4 refParams[LL_MAX_REFLECTION_PROBE_COUNT];
LLVector4 heroSphere;
// indices used by probe:
// [i][0] - cubemap array index for this probe
// [i][1] - index into "refNeighbor" for probes that intersect this probe
// [i][2] - number of probes that intersect this probe, or -1 for no neighbors
// [i][3] - priority (probe type stored in sign bit - positive for spheres, negative for boxes)
GLint refIndex[LL_MAX_REFLECTION_PROBE_COUNT][4];
// list of neighbor indices
GLint refNeighbor[4096];
GLint refBucket[256][4]; // lookup table for which index to start with for the given Z depth
// numbrer of active refmaps
GLint refmapCount;
GLint heroShape;
GLint heroMipCount;
GLint heroProbeCount;
};
// allocate an environment map of the given resolution
LLReflectionMapManager();
@ -207,8 +252,12 @@ private:
// if true, reset all probe render state on the next update (for teleports and sky changes)
bool mReset = false;
float mResetFade = 1.f;
// if true, only update the default probe
bool mPaused = false;
F32 mResumeTime = 0.f;
ReflectionProbeData mProbeData;
};

View File

@ -410,10 +410,16 @@ void LLViewerJointMesh::updateFaceData(LLFace *face, F32 pixel_area, bool damp_w
F32* vw = (F32*) vertex_weightsp.get();
F32* cw = (F32*) clothing_weightsp.get();
S32 tc_size = (num_verts*2*sizeof(F32)+0xF) & ~0xF;
LLVector4a::memcpyNonAliased16(tc, (F32*) mMesh->getTexCoords(), tc_size);
S32 vw_size = (num_verts*sizeof(F32)+0xF) & ~0xF;
LLVector4a::memcpyNonAliased16(vw, (F32*) mMesh->getWeights(), vw_size);
//S32 tc_size = (num_verts*2*sizeof(F32)+0xF) & ~0xF;
//LLVector4a::memcpyNonAliased16(tc, (F32*) mMesh->getTexCoords(), tc_size);
//S32 vw_size = (num_verts*sizeof(F32)+0xF) & ~0xF;
//LLVector4a::memcpyNonAliased16(vw, (F32*) mMesh->getWeights(), vw_size);
// Both allocated in LLPolyMeshSharedData::allocateVertexData(unsigned int)
memcpy(tc, mMesh->getTexCoords(), num_verts*2*sizeof(F32) );
memcpy(vw, mMesh->getWeights(), num_verts*sizeof(F32) );
LLVector4a::memcpyNonAliased16(cw, (F32*) mMesh->getClothingWeights(), num_verts*4*sizeof(F32));
}

View File

@ -1755,8 +1755,6 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
std::string user_data_path_cache = gDirUtilp->getCacheDir(false);
user_data_path_cache += gDirUtilp->getDirDelimiter();
std::string user_data_path_cef_log = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "cef_log.txt");
// See if the plugin executable exists
llstat s;
if(LLFile::stat(launcher_name, &s))
@ -1773,6 +1771,7 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
{
media_source = new LLPluginClassMedia(owner);
media_source->setSize(default_width, default_height);
std::string user_data_path_cef_log = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "cef.log");
media_source->setUserDataPath(user_data_path_cache, gDirUtilp->getUserName(), user_data_path_cef_log);
media_source->setLanguageCode(LLUI::getLanguage());
media_source->setZoomFactor(zoom_factor);

View File

@ -3037,6 +3037,17 @@ void LLViewerObject::fetchInventoryFromServer()
delete mInventory;
mInventory = NULL;
// This will get reset by doInventoryCallback or processTaskInv
mInvRequestState = INVENTORY_REQUEST_PENDING;
if (mRegionp && !mRegionp->getCapability("RequestTaskInventory").empty())
{
LLCoros::instance().launch("LLViewerObject::fetchInventoryFromCapCoro()",
boost::bind(&LLViewerObject::fetchInventoryFromCapCoro, mID));
}
else
{
LL_WARNS() << "Using old task inventory path!" << LL_ENDL;
// Results in processTaskInv
LLMessageSystem* msg = gMessageSystem;
msg->newMessageFast(_PREHASH_RequestTaskInventory);
@ -3046,15 +3057,13 @@ void LLViewerObject::fetchInventoryFromServer()
msg->nextBlockFast(_PREHASH_InventoryData);
msg->addU32Fast(_PREHASH_LocalID, mLocalID);
msg->sendReliable(mRegionp->getHost());
// This will get reset by doInventoryCallback or processTaskInv
mInvRequestState = INVENTORY_REQUEST_PENDING;
}
}
}
void LLViewerObject::fetchInventoryDelayed(const F64 &time_seconds)
{
// unless already waiting, drop previous request and shedule an update
// unless already waiting, drop previous request and schedule an update
if (mInvRequestState != INVENTORY_REQUEST_WAIT)
{
if (mInvRequestXFerId != 0)
@ -3085,6 +3094,80 @@ void LLViewerObject::fetchInventoryDelayedCoro(const LLUUID task_inv, const F64
}
}
//static
void LLViewerObject::fetchInventoryFromCapCoro(const LLUUID task_inv)
{
LLViewerObject *obj = gObjectList.findObject(task_inv);
if (obj)
{
LLCore::HttpRequest::policy_t httpPolicy(LLCore::HttpRequest::DEFAULT_POLICY_ID);
LLCoreHttpUtil::HttpCoroutineAdapter::ptr_t
httpAdapter(new LLCoreHttpUtil::HttpCoroutineAdapter("TaskInventoryRequest", httpPolicy));
LLCore::HttpRequest::ptr_t httpRequest(new LLCore::HttpRequest);
std::string url = obj->mRegionp->getCapability("RequestTaskInventory") + "?task_id=" + obj->mID.asString();
// If we already have a copy of the inventory then add it so the server won't re-send something we already have.
// We expect this case to crop up in the case of failed inventory mutations, but it might happen otherwise as well.
if (obj->mInventorySerialNum && obj->mInventory)
url += "&inventory_serial=" + std::to_string(obj->mInventorySerialNum);
obj->mInvRequestState = INVENTORY_XFER;
LLSD result = httpAdapter->getAndSuspend(httpRequest, url);
LLSD httpResults = result[LLCoreHttpUtil::HttpCoroutineAdapter::HTTP_RESULTS];
LLCore::HttpStatus status = LLCoreHttpUtil::HttpCoroutineAdapter::getStatusFromLLSD(httpResults);
// Object may have gone away while we were suspended, double-check that it still exists
obj = gObjectList.findObject(task_inv);
if (!obj)
{
LL_WARNS() << "Object " << task_inv << " went away while fetching inventory, dropping result" << LL_ENDL;
return;
}
bool potentially_stale = false;
if (status)
{
// Dealing with inventory serials is kind of funky. They're monotonically increasing and 16 bits,
// so we expect them to overflow, but we can use inv serial < expected serial as a signal that we may
// have mutated the task inventory since we kicked off the request, and those mutations may have not
// been taken into account yet. Of course, those mutations may have actually failed which would result
// in the inv serial never increasing.
//
// When we detect this case, set the expected inv serial to the inventory serial we actually received
// and kick off a re-request after a slight delay.
S16 serial = (S16)result["inventory_serial"].asInteger();
potentially_stale = serial < obj->mExpectedInventorySerialNum;
LL_INFOS() << "Inventory loaded for " << task_inv << LL_ENDL;
obj->mInventorySerialNum = serial;
obj->mExpectedInventorySerialNum = serial;
obj->loadTaskInvLLSD(result);
}
else if (status.getType() == 304)
{
LL_INFOS() << "Inventory wasn't changed on server!" << LL_ENDL;
obj->mInvRequestState = INVENTORY_REQUEST_STOPPED;
// Even though it wasn't necessary to send a response, we still may have mutated
// the inventory since we kicked off the request, check for that case.
potentially_stale = obj->mInventorySerialNum < obj->mExpectedInventorySerialNum;
// Set this to what we already have so that we don't re-request a second time.
obj->mExpectedInventorySerialNum = obj->mInventorySerialNum;
}
else
{
// Not sure that there's anything sensible we can do to recover here, retrying in a loop would be bad.
LL_WARNS() << "Error status while requesting task inventory: " << status.toString() << LL_ENDL;
obj->mInvRequestState = INVENTORY_REQUEST_STOPPED;
}
if (potentially_stale)
{
// Stale? I guess we can use what we got for now, but we'll have to re-request
LL_WARNS() << "Stale inv_serial? Re-requesting." << LL_ENDL;
obj->fetchInventoryDelayed(INVENTORY_UPDATE_WAIT_TIME_OUTDATED);
}
}
}
LLControlAvatar *LLViewerObject::getControlAvatar()
{
return getRootEdit()->mControlAvatar.get();
@ -3273,6 +3356,20 @@ void LLViewerObject::processTaskInv(LLMessageSystem* msg, void** user_data)
S16 serial = 0;
msg->getS16Fast(_PREHASH_InventoryData, _PREHASH_Serial, serial);
if (object->mRegionp && !object->mRegionp->getCapability("RequestTaskInventory").empty())
{
// It seems that simulator may ask us to re-download the task inventory if an update to the inventory
// happened out-of-band while we had the object selected (like if a script is saved.)
//
// If we're meant to use the HTTP capability, ignore the contents of the UDP message and fetch the
// inventory via the CAP so that we don't flow down the UDP inventory request path unconditionally here.
// We shouldn't need to wait, as any updates should already be ready to fetch by this point.
LL_INFOS() << "Handling unsolicited ReplyTaskInventory for " << task_id << LL_ENDL;
object->mExpectedInventorySerialNum = serial;
object->fetchInventoryFromServer();
return;
}
if (serial == object->mInventorySerialNum
&& serial < object->mExpectedInventorySerialNum)
{
@ -3492,6 +3589,47 @@ bool LLViewerObject::loadTaskInvFile(const std::string& filename)
return true;
}
void LLViewerObject::loadTaskInvLLSD(const LLSD& inv_result)
{
if (inv_result.has("contents"))
{
if(mInventory)
{
mInventory->clear(); // will deref and delete it
}
else
{
mInventory = new LLInventoryObject::object_list_t;
}
// Synthesize the "Contents" category, the viewer expects it, but it isn't sent.
LLPointer<LLInventoryObject> inv = new LLInventoryObject(mID, LLUUID::null, LLAssetType::AT_CATEGORY, "Contents");
mInventory->push_front(inv);
const LLSD& inventory = inv_result["contents"];
for (const auto& inv_entry : llsd::inArray(inventory))
{
if (inv_entry.has("item_id"))
{
LLPointer<LLViewerInventoryItem> inv = new LLViewerInventoryItem;
inv->unpackMessage(inv_entry);
mInventory->push_front(inv);
}
else
{
LL_WARNS_ONCE() << "Unknown inventory entry while reading from inventory file. Entry: '"
<< inv_entry << "'" << LL_ENDL;
}
}
}
else
{
LL_WARNS() << "unable to load task inventory: " << inv_result << LL_ENDL;
return;
}
doInventoryCallback();
}
void LLViewerObject::doInventoryCallback()
{
for (callback_list_t::iterator iter = mInventoryCallbacks.begin();

View File

@ -709,6 +709,7 @@ private:
// forms task inventory request after some time passed, marks request as pending
void fetchInventoryDelayed(const F64 &time_seconds);
static void fetchInventoryDelayedCoro(const LLUUID task_inv, const F64 time_seconds);
static void fetchInventoryFromCapCoro(const LLUUID task_inv);
public:
//
@ -850,6 +851,7 @@ protected:
static void processTaskInvFile(void** user_data, S32 error_code, LLExtStat ext_status);
bool loadTaskInvFile(const std::string& filename);
void loadTaskInvLLSD(const LLSD &inv_result);
void doInventoryCallback();
bool isOnMap();

View File

@ -29,22 +29,28 @@
#ifndef LL_LLVIEWERPRECOMPILEDHEADERS_H
#define LL_LLVIEWERPRECOMPILEDHEADERS_H
#include "llwin32headers.h"
// This file MUST be the first one included by each .cpp file
// in viewer.
// It is used to precompile headers for improved build speed.
#include "linden_common.h"
#include "llwin32headers.h"
#include <algorithm>
#include <deque>
#include <functional>
#include <list>
#include <map>
#include <set>
#include <vector>
#include <string_view>
#include <unordered_map>
#include <unordered_set>
// Library headers from llcommon project:
#include "apply.h"
#include "function_types.h"
#include "indra_constants.h"
#include "llinitparam.h"
#include "llapp.h"
@ -54,8 +60,10 @@
#include "llerror.h"
#include "llfasttimer.h"
#include "llframetimer.h"
#include "llinstancetracker.h"
#include "llpointer.h"
#include "llprocessor.h"
#include "llrand.h"
#include "llrefcount.h"
#include "llsafehandle.h"
#include "llsd.h"
@ -65,11 +73,13 @@
#include "llstring.h"
#include "llsys.h"
#include "lltimer.h"
#include "lluuid.h"
#include "stdtypes.h"
#include "u64.h"
// Library includes from llmath project
#include "llmath.h"
#include "llbbox.h"
#include "llbboxlocal.h"
#include "llcamera.h"
#include "llcoord.h"
@ -77,9 +87,7 @@
#include "llcrc.h"
#include "llplane.h"
#include "llquantize.h"
#include "llrand.h"
#include "llrect.h"
#include "lluuid.h"
#include "m3math.h"
#include "m4math.h"
#include "llquaternion.h"
@ -91,20 +99,50 @@
#include "v4coloru.h"
#include "v4math.h"
#include "xform.h"
#include "llvector4a.h"
#include "llmatrix4a.h"
#include "lloctree.h"
#include "llvolume.h"
// Library includes from llfilesystem project
#include "lldir.h"
// Library includes from llmessage project
#include "llassetstorage.h"
#include "llavatarnamecache.h"
#include "llcachename.h"
#include "llcorehttputil.h"
// Library includes from llrender project
#include "llgl.h"
#include "llrender.h"
// Library includes from llrender project
#include "llcharacter.h"
// Library includes from llui project
#include "llnotifications.h"
#include "llpanel.h"
#include "llfloater.h"
#include <boost/function.hpp>
#include <boost/signals2.hpp>
#include <boost/unordered_set.hpp>
#include <boost/unordered_map.hpp>
#include <boost/json.hpp>
#include "glm/glm.hpp"
#include "glm/gtc/type_ptr.hpp"
#include "glm/ext/quaternion_float.hpp"
#include "glm/gtx/quaternion.hpp"
#include "glm/gtx/matrix_decompose.hpp"
// Firestorm additions
#include "llavatarname.h"
#include "llavatarnamecache.h"
#include "llcorehttputil.h"
#include "llfloater.h"
#include "llformat.h"
#include "llmatrix4a.h"
#include "llpanel.h"
#include "lluictrl.h"
#include "llvector4a.h"
#include "llview.h"
@ -112,16 +150,12 @@
#include <boost/bind.hpp>
#include <boost/filesystem.hpp>
#include <boost/foreach.hpp>
#include <boost/function.hpp>
#include <boost/lexical_cast.hpp>
#include <boost/regex.hpp>
#include <boost/signals2.hpp>
#include <boost/tokenizer.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string_regex.hpp>
#include <boost/algorithm/string/replace.hpp>
#include <boost/function/function1.hpp>
#include <boost/unordered_map.hpp>
#include <boost/unordered_set.hpp>
#endif

View File

@ -3478,6 +3478,7 @@ void LLViewerRegionImpl::buildCapabilityNames(LLSD& capabilityNames)
capabilityNames.append("FetchInventory2");
capabilityNames.append("FetchInventoryDescendents2");
capabilityNames.append("IncrementCOFVersion");
capabilityNames.append("RequestTaskInventory");
AISAPI::getCapNames(capabilityNames);
} //</FS:Ansariel>

View File

@ -71,6 +71,7 @@
#include "llchatentry.h"
#include "indra_constants.h"
#include "llassetstorage.h"
#include "lldate.h"
#include "llerrorcontrol.h"
#include "llfontgl.h"
#include "llmousehandler.h"
@ -84,7 +85,6 @@
#include "message.h"
#include "object_flags.h"
#include "lltimer.h"
#include "llviewermenu.h"
#include "lltooltip.h"
#include "llmediaentry.h"
#include "llurldispatcher.h"
@ -92,7 +92,6 @@
// newview includes
#include "fscommon.h"
#include "llagent.h"
#include "llbox.h"
#include "llchicletbar.h"
#include "llconsole.h"
@ -124,7 +123,6 @@
#include "llfontfreetype.h"
#include "llgesturemgr.h"
#include "llglheaders.h"
#include "lltooltip.h"
#include "llhudmanager.h"
#include "llhudobject.h"
#include "llhudview.h"
@ -140,7 +138,6 @@
#include "llmorphview.h"
#include "llmoveview.h"
#include "llnavigationbar.h"
#include "llnotificationhandler.h"
// <FS:Zi> We don't use the mini location panel in Firestorm
// #include "llpaneltopinfobar.h"
#include "llpopupview.h"
@ -174,17 +171,13 @@
#include "lltoolselectland.h"
#include "lltrans.h"
#include "lluictrlfactory.h"
#include "llurldispatcher.h" // SLURL from other app instance
#include "llversioninfo.h"
#include "llvieweraudio.h"
#include "llviewercamera.h"
#include "llviewergesture.h"
#include "llviewertexturelist.h"
#include "llviewerinventory.h"
#include "llviewerinput.h"
#include "llviewermedia.h"
#include "llviewermediafocus.h"
#include "llviewermenu.h"
#include "llviewermessage.h"
#include "llviewerobjectlist.h"
#include "llviewerparcelmgr.h"
@ -224,8 +217,6 @@
// </FS:Ansariel> [FS communication UI]
#include "llwindowlistener.h"
#include "llviewerwindowlistener.h"
// <FS:Zi> We don't use the mini location panel in Firestorm
// #include "llpaneltopinfobar.h"
#include "llcleanup.h"
#include "llimview.h"
#include "llviewermenufile.h"
@ -5920,26 +5911,23 @@ void LLViewerWindow::saveImageLocal(LLImageFormatted *image, const snapshot_save
}
// Look for an unused file name
bool is_snapshot_name_loc_set = isSnapshotLocSet();
auto is_snapshot_name_loc_set = isSnapshotLocSet();
std::string filepath;
S32 i = 1;
S32 err = 0;
std::string extension("." + image->getExtension());
auto i = 1;
auto err = 0;
auto extension("." + image->getExtension());
auto now = LLDate::now();
do
{
filepath = sSnapshotDir;
filepath += gDirUtilp->getDirDelimiter();
filepath += sSnapshotBaseName;
if (is_snapshot_name_loc_set)
{
filepath += llformat("_%.3d",i);
}
filepath += now.toLocalDateString("_%Y-%m-%d_%H%M%S");
filepath += llformat("%.2d", i);
filepath += extension;
llstat stat_info;
err = LLFile::stat( filepath, &stat_info );
err = LLFile::stat(filepath, &stat_info);
i++;
}
while( -1 != err // Search until the file is not found (i.e., stat() gives an error).

View File

@ -1110,6 +1110,7 @@ bool LLVivoxVoiceClient::startAndLaunchDaemon()
std::string old_log = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "SLVoice.old");
if (gDirUtilp->fileExists(new_log))
{
LLFile::remove(old_log, ENOENT);
LLFile::rename(new_log, old_log);
}

View File

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="emojipicker" title="Emoji auswählen">
<floater.string name="title_for_recently_used" value="Zuletzt verwendet"/>
<floater.string name="title_for_frequently_used" value="Häufig verwendet"/>
<line_editor name="Filter" label="Nach Emoji filtern"/>
<text name="Dummy">Keine Emoji ausgewählt</text>

View File

@ -236,6 +236,7 @@
<slider label="Schattenqualität" tool_tip="Qualität der Schattendarstellung (Standard: 1)" name="ShadowResolution"/>
<slider label="Skalierung der Bodentexturen (Erfordert Neustart)" name="RenderTerrainScale" tool_tip="Setzt die Skalierung der Bodentexturen - niedriger bedeutet höhere Kompression"/>
<slider label="Schärfung" name="RenderSharpness"/>
<slider label="Max. Anzahl Reflexionsproben" name="MaxProbes"/>
<text name="TonemapTypeText">
Tone Mapper:
</text>

View File

@ -80,8 +80,7 @@
<layout_panel name="pnl_environment_altitudes">
<panel name="pnl_alt1">
<text name="txt_alt1">
Himmel [INDEX]
[ALTITUDE]m
Himmel [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor name="edt_invname_alt1">
Unbekannt
@ -90,8 +89,7 @@
</panel>
<panel name="pnl_alt2">
<text name="txt_alt2">
Himmel [INDEX]
[ALTITUDE]m
Himmel [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor name="edt_invname_alt2">
Unbekannt
@ -100,8 +98,7 @@
</panel>
<panel name="pnl_alt3">
<text name="txt_alt3">
Himmel [INDEX]
[ALTITUDE]m
Himmel [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor name="edt_invname_alt3">
Unbekannt

View File

@ -13,7 +13,6 @@
chrome="true"
height="350"
width="304">
<floater.string name="title_for_recently_used" value="Recently used"/>
<floater.string name="title_for_frequently_used" value="Frequently used"/>
<floater.string name="text_no_emoji_for_filter" value="No emoji found for '[FILTER]'"/>
<scroll_container

View File

@ -75,7 +75,7 @@
step_size="16"
doc_pos="0"
doc_size="3000"
page_size="0"
page_size="50"
/>
</layout_panel>
<layout_panel name="timers_panel"

View File

@ -257,7 +257,7 @@
height="16"
increment="1"
initial_value="12"
label="Max. # of non-impostors:"
label="Max. # animated avatars:"
label_width="185"
layout="topleft"
left="30"
@ -858,6 +858,23 @@
value="3"/>
</combo_box>
<slider
control_name="RenderReflectionProbeCount"
decimal_digits="0"
follows="left|top"
height="16"
increment="1"
initial_value="256"
label="Max. Reflection Probes:"
label_width="145"
layout="topleft"
left="420"
min_val="1"
max_val="256"
name="MaxProbes"
top_delta="24"
width="260" />
<slider
control_name="RenderExposure"
decimal_digits="1"

View File

@ -1250,7 +1250,7 @@ If you do not understand the distinction then leave this control alone."
layout="topleft"
left="10"
name="World Updating"
top_pad="5"
top_pad="2"
width="308">
World Updating:
</text>
@ -1263,7 +1263,7 @@ If you do not understand the distinction then leave this control alone."
layout="topleft"
left_delta="5"
name="WorldPause"
top_pad="6"
top_pad="4"
width="256"/>
<check_box
@ -1327,7 +1327,7 @@ If you do not understand the distinction then leave this control alone."
layout="topleft"
left_delta="10"
name="FSRestrictMaxTextureSize"
top_pad="4"
top_pad="2"
width="250">
Restrict maximum texture resolution to:
</text>
@ -1359,7 +1359,7 @@ If you do not understand the distinction then leave this control alone."
<text
type="string"
length="1"
top_pad="10"
top_pad="3"
follows="top|left"
height="18"
width="150"
@ -1533,7 +1533,7 @@ If you do not understand the distinction then leave this control alone."
min_val="1"
name="PrecachingDelay"
left="10"
top_pad="10"
top_pad="5"
width="405" />
<text
type="string"
@ -1599,6 +1599,22 @@ If you do not understand the distinction then leave this control alone."
width="405">
</slider>
<!-- End of Sharpening Settings-->
<slider
control_name="RenderReflectionProbeCount"
decimal_digits="0"
follows="left|top"
height="16"
increment="1"
initial_value="256"
label="Max. Reflection Probes:"
label_width="300"
layout="topleft"
left="10"
min_val="1"
max_val="256"
name="MaxProbes"
top_pad="0"
width="405" />
<!-- Tone Mapping Settings -->
<text
type="string"

View File

@ -272,8 +272,7 @@
top_pad="1"
halign="right"
name="txt_alt1">
Sky [INDEX]
[ALTITUDE]m
Sky [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor
follows="left|top"
@ -318,8 +317,7 @@
top_pad="1"
halign="right"
name="txt_alt2">
Sky [INDEX]
[ALTITUDE]m
Sky [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor
follows="left|top"
@ -364,8 +362,7 @@
top_pad="1"
halign="right"
name="txt_alt3">
Sky [INDEX]
[ALTITUDE]m
Sky [INDEX]&#xA;[ALTITUDE]m
</text>
<line_editor
follows="left|top"

View File

@ -1668,6 +1668,12 @@ class Darwin_x86_64_Manifest(ViewerManifest):
print("debug: adding {} to dylibs for openal".format(path_optional(os.path.join(relpkgdir, libfile), libfile)))
dylibs += path_optional(os.path.join(relpkgdir, libfile), libfile)
oldpath = os.path.join("@rpath", libfile)
self.run_command(
['install_name_tool', '-change', oldpath,
'@executable_path/../Resources/%s' % libfile,
executable])
print(f"debug: dylibs = {dylibs}")
# our apps

View File

@ -143,7 +143,7 @@ namespace tut
inline void ensure_memory_matches(const void* actual, U32 actual_len, const void* expected,U32 expected_len)
{
ensure_memory_matches(NULL, actual, actual_len, expected, expected_len);
ensure_memory_matches("", actual, actual_len, expected, expected_len);
}
template <class T,class Q>