diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-09-09 17:21:52 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-09-09 17:21:52 -0400 |
commit | 9180c4e7a9b92b2a69a95533acc7bc1a1a41f415 (patch) | |
tree | 958701fe8f07defcc1d7071b481318ab662313b7 /indra/llwindow | |
parent | 0c451a60b7fe859f9deeaefb6360e96ec9af630f (diff) | |
parent | b7c82a8e7a5efcf56cf8c60ecc4922cf2942b70e (diff) |
Merge branch 'develop' into release/luau-scripting
Diffstat (limited to 'indra/llwindow')
-rw-r--r-- | indra/llwindow/llwindowwin32.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp index 8a2168893c..01edbb53af 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -4649,6 +4649,12 @@ void LLWindowWin32::LLWindowWin32Thread::checkDXMem() { if (!mGLReady || mGotGLBuffer) { return; } + if ((gGLManager.mHasAMDAssociations || gGLManager.mHasNVXGpuMemoryInfo) && gGLManager.mVRAM != 0) + { // OpenGL already told us the memory budget, don't ask DX + mGotGLBuffer = true; + return; + } + IDXGIFactory4* p_factory = nullptr; HRESULT res = CreateDXGIFactory1(__uuidof(IDXGIFactory4), (void**)&p_factory); @@ -4745,7 +4751,7 @@ void LLWindowWin32::LLWindowWin32Thread::run() { LL_PROFILE_ZONE_SCOPED_CATEGORY_WIN32; - // Check memory budget using DirectX + // Check memory budget using DirectX if OpenGL doesn't have the means to tell us checkDXMem(); if (mWindowHandleThrd != 0) |