/// <summary> /// Sets an OpenGL attribute /// </summary> /// <param name="attribute">The attribute to set</param> /// <param name="attributeValue">The new attribute value</param> public static void GLSetAttribute(OpenGLAttr attribute, int attributeValue) { if (Sdl.SDL_GL_SetAttribute((int)attribute, attributeValue) != 0) { throw SdlException.Generate(); } }
/// <summary> /// Gets the value of an OpenGL attribute /// </summary> /// <param name="attribute">The attribute to get</param> /// <returns>The current attribute value</returns> public static int GLGetAttribute(OpenGLAttr attribute) { int returnValue; if (Sdl.SDL_GL_GetAttribute((int)attribute, out returnValue) != 0) { throw SdlException.Generate(); } return(returnValue); }
/// <summary> /// Gets the value of an OpenGL attribute /// </summary> /// <param name="attribute">The attribute to get</param> /// <returns>The current attribute value</returns> public static int GLGetAttribute(OpenGLAttr attribute) { int returnValue; if (Sdl.SDL_GL_GetAttribute((int)attribute, out returnValue) != 0) { throw SdlException.Generate(); } return returnValue; }