summaryrefslogtreecommitdiff
path: root/indra/newview/llviewermedia.cpp
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2022-02-22 19:48:01 -0600
committerDave Parks <davep@lindenlab.com>2022-02-22 19:48:01 -0600
commit74641a121316a13e106d525fb1684c517791766d (patch)
treecebff8187d51369cc498d669184f5c046ca3a28d /indra/newview/llviewermedia.cpp
parentce534cf32e1df84b6b10435e9604b0cbde6abf95 (diff)
SL-16815 Cleanup -- disable multithreaded bumpmap generation while tracking down loading issues, fix sync issue in single threaded mode in media textures, restore LL_IMAGEGL_THREAD_CHECK functionality
Diffstat (limited to 'indra/newview/llviewermedia.cpp')
-rw-r--r--indra/newview/llviewermedia.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp
index 42bd5d8367..e442afe4b1 100644
--- a/indra/newview/llviewermedia.cpp
+++ b/indra/newview/llviewermedia.cpp
@@ -2911,10 +2911,16 @@ void LLViewerMediaImpl::update()
mTexUpdateQueue, // Worker thread queue
[=]() // work done on update worker thread
{
+#if LL_IMAGEGL_THREAD_CHECK
+ media_tex->getGLTexture()->mActiveThread = LLThread::currentID();
+#endif
doMediaTexUpdate(media_tex, data, data_width, data_height, x_pos, y_pos, width, height, true);
},
[=]() // callback to main thread
{
+#if LL_IMAGEGL_THREAD_CHECK
+ media_tex->getGLTexture()->mActiveThread = LLThread::currentID();
+#endif
mTextureUpdatePending = false;
media_tex->unref();
unref();
@@ -2991,7 +2997,10 @@ void LLViewerMediaImpl::doMediaTexUpdate(LLViewerMediaTexture* media_tex, U8* da
// copy just the subimage covered by the image raw to GL
media_tex->setSubImage(data, data_width, data_height, x_pos, y_pos, width, height, tex_name);
- media_tex->getGLTexture()->syncToMainThread(tex_name);
+ if (sync)
+ {
+ media_tex->getGLTexture()->syncToMainThread(tex_name);
+ }
// release the data pointer before freeing raw so LLImageRaw destructor doesn't
// free memory at data pointer