mirror of
https://github.com/yawut/SDL.git
synced 2026-08-26 02:35:06 -05:00
At least allow returning the values that were set.
This commit is contained in:
@@ -2163,6 +2163,21 @@ SDL_GL_GetAttribute(SDL_GLattr attr, int *value)
|
||||
*value = (_this->gl_config.accelerated != 0);
|
||||
return 0;
|
||||
}
|
||||
case SDL_GL_RETAINED_BACKING:
|
||||
{
|
||||
*value = _this->gl_config.retained_backing;
|
||||
return 0;
|
||||
}
|
||||
case SDL_GL_CONTEXT_MAJOR_VERSION:
|
||||
{
|
||||
*value = _this->gl_config.major_version;
|
||||
return 0;
|
||||
}
|
||||
case SDL_GL_CONTEXT_MINOR_VERSION:
|
||||
{
|
||||
*value = _this->gl_config.minor_version;
|
||||
return 0;
|
||||
}
|
||||
default:
|
||||
SDL_SetError("Unknown OpenGL attribute");
|
||||
return -1;
|
||||
|
||||
Reference in New Issue
Block a user