remove redundant OpenGL version check to avoid NREs
This commit is contained in:
@@ -16,8 +16,6 @@ namespace OpenRA.Renderer.Sdl2
|
||||
{
|
||||
public static class ErrorHandler
|
||||
{
|
||||
static Version OpenGLversion;
|
||||
|
||||
public static void CheckGlVersion()
|
||||
{
|
||||
var version = GL.GetString(StringName.Version).Split(' ')[0].Split('.');
|
||||
@@ -31,7 +29,6 @@ namespace OpenRA.Renderer.Sdl2
|
||||
int.TryParse(version[1], out minor);
|
||||
|
||||
Console.WriteLine("Detected OpenGL version: {0}.{1}".F(major, minor));
|
||||
OpenGLversion = new Version(major, minor);
|
||||
if (major < 2)
|
||||
{
|
||||
WriteGraphicsLog("OpenRA requires OpenGL version 2.0 or greater and detected {0}.{1}".F(major, minor));
|
||||
@@ -63,11 +60,6 @@ namespace OpenRA.Renderer.Sdl2
|
||||
}
|
||||
Log.Write("graphics", "Renderer: {0}", GL.GetString(StringName.Renderer));
|
||||
Log.Write("graphics", "GL Version: {0}", GL.GetString(StringName.Version));
|
||||
if (OpenGLversion.Major < 2)
|
||||
{
|
||||
Log.Write("graphics", "Note: OpenRA requires OpenGL version 2.0+.\n"
|
||||
+"Please update your graphics card drivers to the latest version.\n");
|
||||
}
|
||||
Log.Write("graphics", "Shader Version: {0}", GL.GetString(StringName.ShadingLanguageVersion));
|
||||
Log.Write("graphics", "Available extensions:");
|
||||
Log.Write("graphics", GL.GetString(StringName.Extensions));
|
||||
|
||||
Reference in New Issue
Block a user