diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-09-19 01:29:22 +0300 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-09-19 19:22:48 +0300 |
commit | ea28e97d85707099ef3cadf7f5632224498af401 (patch) | |
tree | 3f5e6517f50a942fb191877202d1ae10744eb72f /indra/llwindow/llwindowwin32.cpp | |
parent | ea8d7cb40501af9b31d784da78aaaf7353af58f3 (diff) | |
parent | 9241fb80588304f89c035e9811af96172982a8c2 (diff) |
Merge branch 'main' into marchcat/b-main-sync
# Conflicts:
# indra/newview/llviewertexturelist.cpp
Diffstat (limited to 'indra/llwindow/llwindowwin32.cpp')
-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 ad657429ef..76788de876 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -4631,6 +4631,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); @@ -4727,7 +4733,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) |