From 08bd14e8006fa9be616bed6dc384d55c28c4e33f Mon Sep 17 00:00:00 2001 From: YoshiRulz Date: Wed, 11 Sep 2024 02:57:48 +1000 Subject: [PATCH] Skip setting `SDL_HINT_VIDEO_X11_FORCE_EGL` on NixOS see 60fae3540 --- src/BizHawk.Bizware.Graphics/OpenGL/SDL2OpenGLContext.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/BizHawk.Bizware.Graphics/OpenGL/SDL2OpenGLContext.cs b/src/BizHawk.Bizware.Graphics/OpenGL/SDL2OpenGLContext.cs index 8ec638b74d..e0abab56c1 100644 --- a/src/BizHawk.Bizware.Graphics/OpenGL/SDL2OpenGLContext.cs +++ b/src/BizHawk.Bizware.Graphics/OpenGL/SDL2OpenGLContext.cs @@ -1,5 +1,7 @@ // #define DEBUG_OPENGL +using System.IO; + #if DEBUG_OPENGL using System.Runtime.InteropServices; using Silk.NET.OpenGL; @@ -29,7 +31,7 @@ static SDL2OpenGLContext() // try to use EGL if it is available // GLX is the old API, and is the more or less "deprecated" at this point, and potentially more buggy with some drivers // we do need to a bit more work, in case EGL is not actually available or potentially doesn't have desktop GL support - SDL_SetHint(SDL_HINT_VIDEO_X11_FORCE_EGL, "1"); + if (!Directory.Exists("/nix")/* this is just for me --yoshi */) SDL_SetHint(SDL_HINT_VIDEO_X11_FORCE_EGL, "1"); } // init SDL video