LibGL: Complete glGetString implementation

GL_VERSION: The spec mandates the following format: x.y or x.y.z
optionally followed by text separated by space.

GL_EXTENSIONS: Return empty string. We do not support any extensions.
This commit is contained in:
Stephan Unverwerth 2021-08-16 18:18:41 +02:00 committed by Andreas Kling
parent 5b9c87a8b5
commit 894d81c1b8
Notes: sideshowbarker 2024-07-18 05:30:30 +09:00

View File

@ -397,7 +397,9 @@ GLubyte* SoftwareGLContext::gl_get_string(GLenum name)
case GL_RENDERER:
return reinterpret_cast<GLubyte*>(const_cast<char*>("SerenityOS OpenGL"));
case GL_VERSION:
return reinterpret_cast<GLubyte*>(const_cast<char*>("OpenGL 1.2 SerenityOS"));
return reinterpret_cast<GLubyte*>(const_cast<char*>("1.5"));
case GL_EXTENSIONS:
return reinterpret_cast<GLubyte*>(const_cast<char*>(""));
default:
dbgln_if(GL_DEBUG, "glGetString(): Unknown enum name!");
break;