summaryrefslogtreecommitdiff
path: root/indra
AgeCommit message (Collapse)Author
2021-11-12SL-16220: Merge branch 'origin/DRTVWR-546' into glthreadNat Goodspeed
2021-11-12SL-11678 Avatar is reflecting on the under side of water surfaceAndrey Kleshchev
Avatar wasn't reflecting but distorting, since avatar was already under water it looked like a 'reflection' of avatar, but was not rotated right and with wrong angle.
2021-11-12SL-15993 Disabling transparent water should not disable advanced lightingAndrey Kleshchev
2021-11-12SL-16056 Improve 'avatar cloud' behaviorAndrey Kleshchev
Make avatar cloud delay longer proportionally to load time
2021-11-12SL-15391 Crash at getUniformLocationAndrey Kleshchev
2021-11-12SL-13561 When ALM is enabled, disabling water rendering breaks the skyAndrey Kleshchev
2021-11-12SL-15333 Crash in glh_init_extensionsAndrey Kleshchev
2021-11-11SL-16355 - spammy message removedBrad Payne (Vir Linden)
2021-11-11SL-16094: Stylish braces!Nat Goodspeed
2021-11-10Merged DRTVWR-546 into SL-16329Vir Linden
2021-11-10SL-16330 mac build fixMnikolenko Productengine
2021-11-10SL-16094: Only link IMM32.LIB for llurlentry tests on Windows.Nat Goodspeed
2021-11-10SL-15521 Fix debian license file not mentioning meshoptimizerAndrey Kleshchev
Just in case
2021-11-10SL-14403 Removed glodAndrey Kleshchev
2021-11-10Merge branch 'DRTVWR-546' into glthreadNat Goodspeed
2021-11-10SL-16094: Statically link to Windows IMM32.LIB.Nat Goodspeed
llwindowwin32.cpp's LLWinImm class used to dynamically load IMM32.DLL and populate its methods using GetProcAddress(). That was to support Windows XP. Since we've dropped Windows XP, use static linking instead, with dramatically fewer lines of code (and less of a thread safety alarm trigger). We retain the LLWinImm wrapper class only as a hook for Tracy instrumentation.
2021-11-10SL-16094: Add WorkQueue::size() method to support changeset 08336bb.Nat Goodspeed
We want to skip calling PostMessage() to bump the window thread out of GetMessage() in any frame with no work functions pending for that thread. That test depends on being able to sense the size() of the queue. Having converted to WorkQueue, we need that queue to support size().
2021-11-10SL-16330 move VSync checkbox to General groupMnikolenko Productengine
2021-11-09Merged DRTVWR-546 into SL-16329Vir Linden
2021-11-09SL-16329 - track frame time and jitter (as average deviation frame to frame) ↵Brad Payne (Vir Linden)
in stats window
2021-11-09SL-16330 Clean up vertical sync handling, add to UIMnikolenko Productengine
2021-11-09SL-16333 VLC 3 doesn't support -1 == infinity for input-repeatAndrey Lihatskiy
by Callum
2021-11-08SL-16094: Zap thread safety land mine; thin PostMessage() calls.Nat Goodspeed
LLWindowWin32::mWndProc was a public WNDPROC member. If set non-NULL, mainWindowProc() would call that before falling into its own handler code. But now, mWndProc would be called on the window thread instead of on the main thread. Running arbitrary callback code on the window thread could cause all sorts of problems. It could be made safe by posting the callback call to the "mainloop" WorkQueue for execution on the main thread. But as no code actually references it, delete it instead. Per DaveP, the recent change to LLWindowsWin32Thread::post() could end up calling PostMessage() many times per frame, with nontrivial overhead. Reinstate the more selective code that calls PostMessage() with the dummy message (to bust us out of GetMessage() to check pending window-thread work requests) at most once per frame.
2021-11-07SL-16299 Added the correct @rpath for libvlcAndrey Lihatskiy
2021-11-05SL-16094: Use ThreadPool for LLWindowWin32Thread.Nat Goodspeed
Move the whole LLWindowWin32Thread class inside LLWindowWin32, and make it a struct. Migrate the struct declaration to llwindowwin32.cpp. Derive it from ThreadPool, which provides the WorkQueue. Use runPending() instead of manually popping and running individual queue items. Make its post() operation always PostMessage(bogus) whenever we put an entry in the WorkQueue, so we won't remain blocked in GetMessage(). Instead of storing a back pointer to the LLWindowWin32 instance, store the relevant HWND and HDC in LLWindowWin32Thread itself to avoid cross-thread timing problems. Extract both instances of a large duplicated block of LLWindowWin32 code to a new recreateWindow() method, and call it in those places. Per the TODO, use a std::future to pass the new HWND and HDC back to LLWindowWin32 -- but also store them locally on the LLWindowWin32Thread instance.
2021-11-05SL-16202: Use WorkQueue::postTo() for texture create/post handshake.Nat Goodspeed
That is, when LLViewerFetchedTexture::scheduleCreateTexture() wants to call createTexture() on the LLImageGLThread, but postCreateTexture() on the main thread, use the "mainloop" WorkQueue to set up the handshake. Give ThreadPool a public virtual run() method so a subclass can override with desired behavior. This necessitates a virtual destructor. Add accessors for embedded WorkQueue (for post calls), ThreadPool name and width (in threads). Allow LLSimpleton::createInstance() to forward arguments to the subject constructor. Make LLImageGLThread an LLSimpleton - that abstraction didn't yet exist at the time LLImageGLThread was coded. Also derive from ThreadPool rather than LLThread. Make it a single-thread "pool" with a very large queue capacity.
2021-11-05SL-16288 FIXED Dragging a file across the viewer cancels the drag and ↵Mnikolenko Productengine
freezes the File Explorer
2021-11-04SL-14098 re-enable occlusion culling during reflection passDave Houlton
2021-11-04SL-13565 occlusion/reflection tracy markupDave Houlton
2021-11-04SL-16299 fix warning about CFBundleIdentifier not matching ↵Brad Kittenbrink
PRODUCT_BUNDLE_IDENTIFIER
2021-11-04SL-16202: Use large WorkQueue size limits for mainloop and General.Nat Goodspeed
Give ThreadPool and WorkQueue the ability to override default ThreadSafeSchedule capacity. Instantiate "mainloop" WorkQueue and "General" ThreadPool with very large capacity because we never want to have to block trying to push to either.
2021-11-04SL-16202: Streamline WorkQueues in LLImageGLThread.Nat Goodspeed
Use the new WorkQueue::postIfOpen() method in LLImageGLThread::post(). That makes the LLImageGLThread method a trivial wrapper, which can accept templated work items and pass them through to the WorkQueue method, eliminating double indirection due to multiple layers of std::function. Eliminate LLImageGLThread's WorkQueue intended for work on the main queue. Since the main loop already has a WorkQueue of its own, post work directly to that WorkQueue instead of using a separate WorkQueue misleadingly embedded in LLImageGLThread. Instead of looking up the main thread's WorkQueue every time, capture a pointer in LLImageGL's constructor. We no longer need a fallback queue for when the main thread's WorkQueue is full. We no longer need the main loop to poll LLImageGL to service the local main-thread-targeted WorkQueue, or to copy work from the fallback queue to the main queue. That eliminates LLImageGLThread::postCallback(), mCallbackQueue, mPendingCallbackQ, executeCallbacks() -- and even LLImageGL::updateClass() and LLAppViewer's call to it. Change LLViewerFetchedTexture::scheduleCreateTexture() to post work to the main thread's WorkQueue instead of calling LLImageGLThread::postCallback().
2021-11-04SL-16202: Add postIfOpen() methods to WorkQueue, LLThreadSafeQueue.Nat Goodspeed
postIfOpen() provides a no-exception alternative to post(), which blocks if full but throws if closed. postIfOpen() likewise blocks if full, but returns true if able to post and false if the queue was closed.
2021-11-04SL-16202: Instantiate LLSimpleton::sInstance genericallyNat Goodspeed
instead of requiring a separate declaration for each subclass. The previous way produces errors in clang.
2021-11-04SL-16202: Merge branch 'sl-16220' into glthreadNat Goodspeed
2021-11-04SL-16299 Updated dullahan to CT build 565428; entitlements cleanupAndrey Lihatskiy
2021-11-03SL-16299 Added entitlements for the app bundle signingAndrey Lihatskiy
2021-11-02SL-16207: Fix bug in ll_convert_string_to_utf8_string().Nat Goodspeed
That function wants to pass a code_page to ll_convert_string_to_wide(), but the code_page parameter was being mistaken for the length parameter, leading to access violations.
2021-11-02SL-16207: Guess Microsoft compiler isn't smart about default params?Nat Goodspeed
clang allows us to specify, as a default function parameter, an expression involving a preceding parameter, e.g. (char* ptr, size_t len=strlen(ptr)). The Microsoft compiler produces errors, requiring more overloads to address that. Also #undef llstring.h's declaration helper macros at the bottom of the file. Once we've used them to declare stuff, they need not (should not) be visible to the consuming source file.
2021-11-02SL-16207: Create uniform overload sets for wide-string conversions.Nat Goodspeed
Use new ll_convert_forms() macro in llstring.h to declare, for each wide-string conversion function of interest, four overloads. The real one, the nontrivial one, is (const char*, size_t len), implemented in llstring.cpp. Then (const string&, size_t len), (const char*) and (const string&) are each trivially implemented with an inline call to (const char*, size_t len). Notably, we change all S32 len parameters to size_t. Using S32 is old skool. Tweak each nontrivial implementation in llstring.cpp to accept (const char*, size_t len) instead of (const string&) with or without explicit length. Eliminate from llstring.cpp trivial overloads (deriving length from either a const char* or from a string), since those are now inline in the header. Of course three of those overloads will be unified once we enable C++17 and change each relevant parameter to std::string_view, but we're not yet there. Meanwhile, this suite of overloads minimizes, to the best of our ability, new string allocations solely for parameter passing. And use of a macro means we need only change the macro once we get std::string_view. We take this step because some use cases require (const char*), some require (const string&, size_t len), others (const char*, size_t len) ... We were missing some key overloads, and had to work around them by instantiating new string objects (necessitating both allocation and character copying) just to pass the desired parameter. Using the macro ensures this consistent set of overloads for every wide-string conversion function. Additionally, knowing that the ugly-name overloads exist, ll_convert_forms() implicitly defines corresponding ll_convert<TARGET>() overloads. Streamline declarations of utf16str_to_wstring(), wstring_to_utf16str(), utf8str_to_utf16str(), utf16str_to_utf8str(), utf8str_to_wstring(), wstring_to_utf8str(), ll_convert_wide_to_wstring() and ll_convert_wstring_to_wide() using ll_convert_forms(). Use corresponding new ll_convert_cp_forms() macro to declare consistent overloads for conversion functions accepting an optional unsigned int code_page parameter. We used to delegate to the .cpp file the implementation of each overload accepting code_page so llstring.h need not include the Windows header defining the CP_UTF8 default; this is more simply accomplished by introducing a small ll_wstring_default_code_page() function to retrieve it from the .cpp file. That lets us specify the code_page parameter as optional, using that function as its default value. Use ll_convert_cp_forms() to streamline declarations of ll_convert_wide_to_string() and ll_convert_string_to_wide(). Introduce real implementations of ll_convert_wide_to_wstring() and ll_convert_wstring_to_wide(). The previous implementations merely copied individual characters, which is wrong: when we convert UTF16LE to UTF32, we can and should fold multi-character UTF16LE encodings to the corresponding single UTF32 character. The real implemenations leverage our awareness that both llutf16string and Windows std::wstring (either variant) use UTF16LE encoding, so we can reuse the corresponding llutf16string conversions. Introduce generic ll_convert_length() function, specialized as either std::strlen() or std::wcslen() depending on parameter type. (Even if std::wcslen() is derived from classic C, why doesn't the C++ standard library define a std::strlen(const wchar_t*) overload to call it?) Fix ll_convert_alias()'s ll_convert_impl specialization's operator() to accept boost::call_traits::param_type, so we can pass (e.g.) const std::wstring& but also const wchar_t* instead of const wchar_t*&.
2021-11-01SL-16207: Remove CMake cxx_range_for from media_plugin_cef.Nat Goodspeed
Now that we've enabled -std=c++14 for the whole viewer source tree, that CMake directive is actually a step backwards -- since it introduces -std=gnu++11 on the compiler command line, after the one we want, which apparently overrides c++14 with gnu++11 and causes errors with legitimate C++14 constructs.
2021-11-01SL-16237 FIXED Viewer hangs on loginMnikolenko Productengine
2021-10-29Fix merge conflictPtolemy
2021-10-28SL-9436 Don't render 100% transparent objects.Dave Parks
2021-10-28SL-15462 Convert waitForChannel() into state machineAndrey Kleshchev
2021-10-28SL-16148 SL-16244 SL-16270 SL-16253 Remove most BlockTimers, remove ↵Dave Parks
LLMemTracked, introduce alignas, hook most/all reamining allocs, disable synchronous occlusion, and convert frequently accessed LLSingletons to LLSimpleton
2021-10-28SL-16247 Post-d520 libvlc plugin fixesAndrey Lihatskiy
by Callum
2021-10-27SL-16220: Add tests for WorkQueue::waitForResult(), void & non-void.Nat Goodspeed
2021-10-27SL-16127: Make another pass removing redundant LLSD op [] calls, unused ↵Ptolemy
vars, and use atmospheric already calculated
2021-10-27SL-16207: Update llstring.h handling of different string types.Nat Goodspeed
In llpreprocessor.h, consider the case of clang on Windows: #define LL_WCHAR_T_NATIVE there as well as for the Microsoft compiler with /Zc:wchar_t switch. In stdtypes.h, inject a LLWCHAR_IS_WCHAR_T symbol to allow the preprocessor to make decisions about when the types are identical. llstring.h's conversion logic deals with three types of wide strings (LLWString, std::wstring and utf16string) based on three types of wide char (llwchar, wchar_t and U16, respectively). Sometimes they're three distinct types, sometimes wchar_t is identical to llwchar and sometimes wchar_t is identical to U16. Rationalize the three cases using ll_convert_u16_alias() and new ll_convert_wstr_alias() macros. stringize.h was directly calling wstring_to_utf8str() and utf8str_to_wstring(), which was producing errors with VS 2019 clang since there isn't actually a wstring_to_utf8str(std::wstring) overload. Use ll_convert<std::string>() instead, since that redirects to the relevant ll_convert_wide_to_string() function. (And now you see why we've been trying to migrate to the uniform ll_convert<target>() wrapper!) Similarly, call ll_convert<std::wstring>() instead of a two-step conversion from utf8str_to_wstring(), producing LLWString, then a character-by-character copy from LLWString to std::wstring. That isn't even correct: on Windows, we should be encoding from UTF32 to UTF16.