summaryrefslogtreecommitdiff
path: root/indra/newview/llfeaturemanager.cpp
diff options
context:
space:
mode:
authorBrad Linden <46733234+brad-linden@users.noreply.github.com>2024-11-19 10:49:09 -0800
committerGitHub <noreply@github.com>2024-11-19 10:49:09 -0800
commit7be9c43f286671893ff0a9dee13d721a6731255b (patch)
treeb49f62290187b2b719d1fb3b2cdbb467c64b4bfd /indra/newview/llfeaturemanager.cpp
parentc654dac4b7593355a5754042d0b43e03924b3efb (diff)
brad/2744 handle shader errors (#3105)
* Partial solution to secondlife/viewer#2744 crash with better error handling. Handles shader compile errors better, and should turn crash into an LL_ERRS assertion failure. Strengthed more assertions and improved shader error line numbers * Even more error handling to get a handle on crash secondlife/viewer#2744 * Improved GLSL correctness on Intel chips that lack OpenGL 4.6 support. secondlife/viewer#2744 * Removed non-working fallback code for gDeferredPostProgram * Fixed incorrect llmax call
Diffstat (limited to 'indra/newview/llfeaturemanager.cpp')
-rw-r--r--indra/newview/llfeaturemanager.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp
index b5d8f70c2e..c5d074a5e8 100644
--- a/indra/newview/llfeaturemanager.cpp
+++ b/indra/newview/llfeaturemanager.cpp
@@ -655,6 +655,21 @@ void LLFeatureManager::applyBaseMasks()
if (gGLManager.mIsIntel)
{
maskFeatures("Intel");
+ if (gGLManager.mGLVersion < 4.59f)
+ {
+ // if we don't have OpenGL 4.6 on intel, set it to OpenGL 3.3
+ // we also want to trigger the GL3 fallbacks on these chipsets
+ // this is expected to be mainly pre-Haswell Intel HD Graphics 4X00 and 5X00.
+ // A lot of these chips claim 4.3 or 4.4 support, but don't seem to work.
+ // https://code.blender.org/2019/04/supported-gpus-in-blender-2-80/
+ // https://docs.blender.org/manual/en/latest/troubleshooting/gpu/windows/intel.html#legacy-intel-hd-4000-5000
+ // https://www.intel.com/content/www/us/en/support/articles/000005524/graphics.html
+ // this will disable things like reflection probes, HDR, FXAA and SMAA
+ gGLManager.mGLVersion = llmin(gGLManager.mGLVersion, 3.33f);
+ // and select GLSL version for OpenGL 3.3
+ gGLManager.mGLSLVersionMajor = 3;
+ gGLManager.mGLSLVersionMinor = 30;
+ }
}
if (gGLManager.mIsApple)
{