GLAPI/glGet: Difference between revisions
(Corrected minimum for GL_MAX_COMPUTE_WORK_GROUP_SIZE Z dimension.) |
m (→Buffer Binding State: GL_MAX_TRANSFORM_FEEDBACK_BUFFERS breaks the convention) |
||
Line 106: | Line 106: | ||
| {{enum|GL_SHADER_STORAGE_BUFFER}} || {{defenum|GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS}} (min 8) || {{defenum|GL_SHADER_STORAGE_BUFFER_BINDING}} || {{defenum|GL_SHADER_STORAGE_BUFFER_START}} || {{defenum|GL_SHADER_STORAGE_BUFFER_SIZE}} | | {{enum|GL_SHADER_STORAGE_BUFFER}} || {{defenum|GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS}} (min 8) || {{defenum|GL_SHADER_STORAGE_BUFFER_BINDING}} || {{defenum|GL_SHADER_STORAGE_BUFFER_START}} || {{defenum|GL_SHADER_STORAGE_BUFFER_SIZE}} | ||
|- | |- | ||
| {{enum|GL_TRANSFORM_FEEDBACK_BUFFER}} || {{defenum| | | {{enum|GL_TRANSFORM_FEEDBACK_BUFFER}} || {{defenum|GL_MAX_TRANSFORM_FEEDBACK_BUFFERS}} || {{defenum|GL_TRANSFORM_FEEDBACK_BUFFER_BINDING}} || {{defenum|GL_TRANSFORM_FEEDBACK_BUFFER_START}} || {{defenum|GL_TRANSFORM_FEEDBACK_BUFFER_SIZE}} | ||
|- | |- | ||
| {{enum|GL_UNIFORM_BUFFER}} || {{defenum|GL_MAX_UNIFORM_BUFFER_BINDINGS}} (min 84) || {{defenum|GL_UNIFORM_BUFFER_BINDING}} || {{defenum|GL_UNIFORM_BUFFER_START}} || {{defenum|GL_UNIFORM_BUFFER_SIZE}} | | {{enum|GL_UNIFORM_BUFFER}} || {{defenum|GL_MAX_UNIFORM_BUFFER_BINDINGS}} (min 84) || {{defenum|GL_UNIFORM_BUFFER_BINDING}} || {{defenum|GL_UNIFORM_BUFFER_START}} || {{defenum|GL_UNIFORM_BUFFER_SIZE}} |
Revision as of 02:12, 18 August 2017
Core in version | 4.6 | |
---|---|---|
Core since version | 1.0 |
glGet: return the value or values of a selected parameter
Function Definition
void glGetBooleanv(GLenum pname, GLboolean * params); void glGetDoublev(GLenum pname, GLdouble * params); void glGetFloatv(GLenum pname, GLfloat * params); void glGetIntegerv(GLenum pname, GLint * params); void glGetInteger64v(GLenum pname, GLint64 * params);
- pname
- Specifies the parameter value to be returned. The symbolic constants in the list below are accepted.
- params
- Returns the value or values of the specified parameter.
Function Definition
void glGetBooleani_v(GLenum pname, GLuint index, GLboolean * data); void glGetIntegeri_v(GLenum pname, GLuint index, GLint * data); void glGetFloati_v(GLenum pname, GLuint index, GLfloat * data); void glGetDoublei_v(GLenum pname, GLuint index, GLdouble * data); void glGetInteger64i_v(GLenum pname, GLuint index, GLint64 * data);
- pname
- Specifies the parameter value to be returned. The symbolic constants in the list below are accepted.
- index
- Specifies the zero-based index of the particular element being queried.
- data
- Returns the value or values of the specified parameter.
Description
These four commands return values for simple state variables in GL. pname is a symbolic constant indicating the state variable to be returned, and params is a pointer to an array of the indicated type in which to place the returned data.
Type conversion is performed if params has a different type than the state variable value being requested. If glGetBooleanv is called, a floating-point (or integer) value is converted to GL_FALSE if and only if it is 0.0 (or 0). Otherwise, it is converted to GL_TRUE. If glGetIntegerv is called, boolean values are returned as GL_TRUE or GL_FALSE, and most floating-point values are rounded to the nearest integer value. Floating-point colors and normals, however, are returned with a linear mapping that maps 1.0 to the most positive representable integer value and to the most negative representable integer value. If glGetFloatv or glGetDoublev is called, boolean values are returned as GL_TRUE or GL_FALSE, and integer values are converted to floating-point values.
Many of the boolean parameters can also be queried more easily using glIsEnabled.
The following symbolic constants are accepted by pname:
- GL_CONTEXT_FLAGS (integer)
- The flags with which the context was created (such as debugging functionality).
- GL_MAJOR_VERSION (integer)
- The major version number of the OpenGL API supported by the current context.
- GL_MAX_SERVER_WAIT_TIMEOUT (64-bit integer, at least 0, see glWaitSync)
- The maximum glWaitSync timeout interval.
- GL_MIN_MAP_BUFFER_ALIGNMENT (integer, at least 64)
- The minimum alignment in basic machine units of pointers returned fromglMapBuffer and glMapBufferRange.
- GL_MINOR_VERSION (integer)
- The minor version number of the OpenGL API supported by the current context.
- GL_NUM_EXTENSIONS (integer, see glGetString)
- The number of extensions supported by the GL implementation for the current context.
- GL_NUM_SHADING_LANGUAGE_VERSIONS (integer, at least 3, see glGetString)
- The number of supported GLSL versions.
- GL_TIMESTAMP (GLint64, see glQueryCounter)
- The 64-bit value of the current GL time.
The following sections apply to different aspects of GL.
Buffer Binding State
- GL_ARRAY_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_ARRAY_BUFFER. If no buffer object is bound to this target, 0 is returned.
- GL_COPY_READ_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The buffer that is currently bound to the copy read bind point, or 0 for none.
- GL_COPY_WRITE_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The buffer that is currently bound to the copy write bind point, or 0 for none.
- GL_DRAW_INDIRECT_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_DRAW_INDIRECT_BUFFER. If no buffer object is bound to this target, 0 is returned.
- GL_ELEMENT_ARRAY_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_ELEMENT_ARRAY_BUFFER. If no buffer object is bound to this target, 0 is returned.
- GL_QUERY_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The buffer that is currently bound to the query bind point, or 0 for none.
- GL_TEXTURE_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The buffer that is currently bound to the generic texture bind point, or 0 for none.
- GL_VERTEX_ARRAY_BINDING (GLint, initially 0, see glBindVertexArray)
- The name of the vertex array object currently bound to the context, or 0 if none is bound.
Indexed buffer binding state is controlled through glBindBufferRange with a target that's specific to that bind point.
GL_type_BUFFER | GL_MAX_type_BUFFER_BINDINGS | GL_type_BUFFER_BINDING | GL_type_BUFFER_START | GL_type_BUFFER_SIZE |
---|---|---|---|---|
GL_ATOMIC_COUNTER_BUFFER | GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS (min 1) | GL_ATOMIC_COUNTER_BUFFER_BINDING | GL_ATOMIC_COUNTER_BUFFER_START | GL_ATOMIC_COUNTER_BUFFER_SIZE |
GL_SHADER_STORAGE_BUFFER | GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS (min 8) | GL_SHADER_STORAGE_BUFFER_BINDING | GL_SHADER_STORAGE_BUFFER_START | GL_SHADER_STORAGE_BUFFER_SIZE |
GL_TRANSFORM_FEEDBACK_BUFFER | GL_MAX_TRANSFORM_FEEDBACK_BUFFERS | GL_TRANSFORM_FEEDBACK_BUFFER_BINDING | GL_TRANSFORM_FEEDBACK_BUFFER_START | GL_TRANSFORM_FEEDBACK_BUFFER_SIZE |
GL_UNIFORM_BUFFER | GL_MAX_UNIFORM_BUFFER_BINDINGS (min 84) | GL_UNIFORM_BUFFER_BINDING | GL_UNIFORM_BUFFER_START | GL_UNIFORM_BUFFER_SIZE |
In the following, n refers to the value of GL_MAX_type_BUFFER_BINDINGS.
- GL_MAX_type_BUFFER_BINDINGS (integer)
- The maximum number of buffer bindings.
- GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS (integer, minimum is 8)
- The maximum number of shader storage buffer binding points on the context.
- GL_type_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The current name of the buffer binding, or 0 for none.
- GL_type_BUFFER_BINDING (indexed[n] name, initially 0, see glBindBufferRange)
- The current name of the buffer binding for each binding point, or 0 for none.
- GL_type_BUFFER_START (indexed[n] 64-bit integer, initially 0, see glBindBufferRange)
- The starting offset of the binding range for each buffer.
- GL_type_BUFFER_SIZE (indexed[n] 64-bit integer, initially 0, see glBindBufferRange)
- The size of the binding range for each buffer.
- GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS (integer, at least 64)
- The maximum number of components to write to a single buffer in interleaved mod.
- GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS (integer, at least 4)
- The maximum number of separate attributes or outputs that can be captured in transform feedback.
- GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS (integer, at least 4)
- The maximum number of buffer objects to write with transform feedback.
- GL_TRANSFORM_FEEDBACK_PAUSED (boolean, initially GL_FALSE)
- Whether transform feedback is paused on this object.
- GL_TRANSFORM_FEEDBACK_ACTIVE (boolean, initially GL_FALSE)
- Whether transform feedback is active on this object.
Debug Output State
See OpenGL 4.4, chapter 20, page 490 and OpenGL 4.4, table 23.67, page 588.
- GL_DEBUG_GROUP_STACK_DEPTH (GLint, initially 1)
- The current depth of the debug message group stack.
- GL_DEBUG_LOGGED_MESSAGES (GLint)
- The number of messages currently in the debug message log.
- GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH (GLint)
- The string length of the oldest debug message in the debug message log, or 0 if there are no strings.
- GL_DEBUG_OUTPUT (GLboolean, see glIsEnabled)
- The enabled state for debug output functionality. The initial value is GL_TRUE if this is a debug context, and GL_FALSE otherwise.
- GL_DEBUG_OUTPUT_SYNCHRONOUS (GLboolean, initially GL_FALSE, see glIsEnabled)
- The enabled state for synchronous debug message callbacks.
- GL_MAX_DEBUG_LOGGED_MESSAGES (GLint, at least 1)
- The maximum number of messages stored in the debug message log.
- GL_MAX_DEBUG_MESSAGE_LENGTH (GLint, at least 1)
- The maximum length of a debug message string, including its NUL terminator.
- GL_MAX_DEBUG_GROUP_STACK_DEPTH (GLint, at least 64)
- The maximum depth of the debug message group stack.
- GL_MAX_LABEL_LENGTH (GLint, at least 256, see glObjectLabel and glObjectPtrLabel)
- The maximum length of a label string that may be assigned to an object.
Framebuffers
- GL_COLOR_CLEAR_VALUE (GLfloat[4], initially (0.0, 0.0, 0.0, 0.0), see glClearColor)
- The red, green, blue, and alpha values used to clear the color buffers. Integer values, if requested, are linearly mapped from the internal floating-point representation such that 1.0 returns the most positive representable integer value, and -1.0 returns the most negative representable integer value.
- GL_COLOR_WRITEMASK (singualar or indexed[value of MAX_DRAW_BUFFERS] GLboolean[4], initially (GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE), see glColorMask)
- The red, green, blue, and alpha write enables for the color buffers. The single form reads from the first attached color buffer.
- GL_DEPTH_CLEAR_VALUE (GLfloat, initially 1, see glClearDepth)
- The value that is used to clear the depth buffer. Integer values, if requested, are linearly mapped from the internal floating-point representation such that 1.0 returns the most positive representable integer value, and -1.0 returns the most negative representable integer value.
- GL_DEPTH_FUNC (GLenum, initially GL_LESS, see glDepthFunc)
- The depth comparison function.
- GL_DEPTH_TEST (GLboolean, initially GL_FALSE, see glDepthFunc and glDepthRange)
- Whether depth testing of fragments is enabled.
- GL_DEPTH_WRITEMASK (GLboolean, initially GL_FALSE, see glDepthMask)
- If the depth buffer is enabled for writing.
- GL_DOUBLEBUFFER (GLboolean)
- Whether double buffering is supported.
- GL_DRAW_BUFFER (GLenum, see glDrawBuffer)
- Which buffers are being drawn to. This is selected from the currently bound GL_DRAW_FRAMEBUFFER. See glDrawBuffer. The initial value is GL_BACK if there are back buffers, otherwise it is GL_FRONT.
- GL_DRAW_BUFFERi (symbolic constant, see glDrawBuffers)
- params returns one value, a symbolic constant indicating which buffers are being drawn to by the corresponding output color. This is selected from the currently bound GL_DRAW_FRAMEBUFFER The initial value of GL_DRAW_BUFFER0 is GL_BACK if there are back buffers, otherwise it is GL_FRONT. The initial values of draw buffers for all other output colors is GL_NONE. i can be from 0 up to the value of MAX_DRAW_BUFFERS minus one.
- GL_DRAW_FRAMEBUFFER_BINDING (name, initially 0, see glBindFramebuffer)
- The framebuffer object currently bound to the GL_DRAW_FRAMEBUFFER target. If the default framebuffer is bound, this value will be zero.
- GL_MAX_COLOR_ATTACHMENTS (integer, at least 8)
- Maximum number of framebuffer attachment points for color buffers.
- GL_MAX_COLOR_TEXTURE_SAMPLES (integer, at least 1)
- The maximum number of samples for all color formats in a multisample texture.
- GL_MAX_DEPTH_TEXTURE_SAMPLES (integer, at least 1)
- The maximum number of samples in a multisample depth or depth-stencil texture.
- GL_MAX_DRAW_BUFFERS (integer, at least 8, see glDrawBuffers)
- The maximum number of simultaneous outputs that may be written in a fragment shader.
- GL_MAX_DUAL_SOURCE_DRAW_BUFFERS (integer, at least 1, see glBlendFunc and glBlendFuncSeparate)
- The maximum number of active draw buffers when using dual-source blending.
- GL_MAX_FRAMEBUFFER_HEIGHT (integer, at least 16384, see glFramebufferParameter)
- The maximum height for a framebuffer that has no attachments.
- GL_MAX_FRAMEBUFFER_LAYERS (integer, at least 2048, see glFramebufferParameter)
- The maximum number of layers for a framebuffer that has no attachments.
- GL_MAX_FRAMEBUFFER_SAMPLES (integer, at least 4, see glFramebufferParameter)
- The maximum samples in a framebuffer that has no attachments.
- GL_MAX_FRAMEBUFFER_WIDTH (integer, at least 16384, see glFramebufferParameter)
- The maximum width for a framebuffer that has no attachments.
- GL_MAX_INTEGER_SAMPLES (integer, at least 1)
- The maximum number of samples supported in integer format multisample buffers.
- GL_MAX_SAMPLES (integer, at least 4)
- The maximum number of samples supported for all non-integer formats.
- GL_READ_BUFFER (symbolic constant, initial value below, see glReadPixels
- {Which color buffer is selected for reading. The initial value is GL_BACK if there is a back buffer, otherwise it is GL_FRONT. This is selected from the currently bound GL_READ_FRAMEBUFFER.
- GL_READ_FRAMEBUFFER_BINDING (name, intially 0, see glBindFramebuffer)
- The framebuffer object currently bound to the GL_READ_FRAMEBUFFER target. If the default framebuffer is bound, this value will be zero.
- GL_RENDERBUFFER_BINDING (name, initially 0, see glBindRenderbuffer)
- The name of the renderbuffer object currently bound to the target GL_RENDERBUFFER. If no renderbuffer object is bound to this target, 0 is returned.
- GL_STENCIL_BACK_FAIL (symbolic constant, initially GL_KEEP, see glStencilOpSeparate)
- What action is taken for back-facing polygons when the stencil test fails.
- GL_STENCIL_BACK_FUNC (symbolic constant, initially GL_ALWAYS, see glStencilFuncSeparate)
- What function is used for back-facing polygons to compare the stencil reference value with the stencil buffer value.
- GL_STENCIL_BACK_PASS_DEPTH_FAIL (symbolic constant, initially GL_KEEP, see glStencilOpSeparate)
- What action is taken for back-facing polygons when the stencil test passes, but the depth test fails.
- GL_STENCIL_BACK_PASS_DEPTH_PASS (symbolic constant, initially GL_KEEP, see glStencilOpSeparate)
- What action is taken for back-facing polygons when the stencil test passes and the depth test passes.
- GL_STENCIL_BACK_REF (integer, initially 0, see glStencilFuncSeparate)
- The reference value that is compared with the contents of the stencil buffer for back-facing polygons.
- GL_STENCIL_BACK_VALUE_MASK (integer, initially ~0 (all ones), see glStencilFuncSeparate)
- The mask that is used for back-facing polygons to mask both the stencil reference value and the stencil buffer value before they are compared.
- GL_STENCIL_BACK_WRITEMASK (integer, initially ~0 (all ones), see glStencilMaskSeparate)
- The mask that controls writing of the stencil bitplanes for back-facing polygons.
- GL_STENCIL_CLEAR_VALUE (integer, initially 0)
- The index to which the stencil bitplanes are cleared. See glClearStencil.
- GL_STENCIL_FAIL (symbolic constant, initially GL_KEEP, see glStencilOp)
- What action is taken when the stencil test fails. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilOpSeparate.
- GL_STENCIL_FUNC (symbolic constant, initially GL_ALWAYS)
- What function is used to compare the stencil reference value with the stencil buffer value. See glStencilFunc. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilFuncSeparate and GL_STENCIL_BACK_FUNC.
- GL_STENCIL_PASS_DEPTH_FAIL (symbolic constant, initially GL_KEEP, see glStencilOp)
- What action is taken when the stencil test passes, but the depth test fails. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilOpSeparate.
- GL_STENCIL_PASS_DEPTH_PASS (symbolic constant, initially GL_KEEP, see glStencilOp)
- What action is taken when the stencil test passes and the depth test passes. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilOpSeparate.
- GL_STENCIL_REF (integer, initially 0, see glStencilFunc)
- The reference value that is compared with the contents of the stencil buffer. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilFuncSeparate.
- GL_STENCIL_TEST (boolean, initially GL_FALSE, see glIsEnabled)
- Whether stenciling is enabled.
- GL_STENCIL_VALUE_MASK (integer, initially ~0 (all ones), see glStencilFunc)
- The mask that is used to mask both the stencil reference value and the stencil buffer value before they are compared. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilFuncSeparate.
- GL_STENCIL_WRITEMASK (integer, initially ~0 (all ones), see glStencilMask)
- The mask that controls writing of the stencil bitplanes. This stencil state only affects non-polygons and front-facing polygons. Back-facing polygons use separate stencil state. See glStencilMaskSeparate.
- GL_STEREO (boolean)
- Whether stereo buffers (left and right) are supported.
Hints
See glHint. The initial values are always GL_DONT_CARE.
- GL_FRAGMENT_SHADER_DERIVATIVE_HINT (enumeration, initially GL_DONT_CARE, see glHint)
- A symbolic constant indicating the mode of the derivative calculations of dFdx, dFdy, and fwidth for fragment shaders.
- GL_LINE_SMOOTH_HINT (symbolic constant, initially GL_DONT_CARE, see glHint)
- The mode of the line antialiasing hint.
- GL_POLYGON_SMOOTH_HINT (symbolic constant, initially GL_DONT_CARE, see glHint)
- The mode of the polygon antialiasing hint.
- GL_TEXTURE_COMPRESSION_HINT (symbolic constant, initially GL_DONT_CARE, see glHint)
- The mode of the texture compression hint.
Image State
Indexed parameters set by glBindImageTexture. See OpenGL 4.4, table 23.45, page 566
- GL_IMAGE_BINDING_ACCESS (indexed[value of GL_MAX_IMAGE_UNITS] symbolic constant, initially GL_READ_ONLY)
- The read and/or write access for the bound texture.
- GL_IMAGE_BINDING_FORMAT (indexed[value of GL_MAX_IMAGE_UNITS] integer, initially GL_R8, see glBindImageTexture)
- The format used for accesses to bound textures.
- GL_IMAGE_BINDING_NAME (indexed[value of GL_MAX_IMAGE_UNITS] name, initially 0)
- The name of the bound texture object.
- GL_IMAGE_BINDING_LAYER (indexed[value of GL_MAX_IMAGE_UNITS] integer, initially 0)
- The layer of the bound texture, if not layered.
- GL_IMAGE_BINDING_LAYERED (indexed[value of GL_MAX_IMAGE_UNITS] boolean, initially GL_FALSE)
- Whether the texture object is bound with multiple layers.
- GL_IMAGE_BINDING_LEVEL (indexed[value of GL_MAX_IMAGE_UNITS] integer, initially 0)
- The level of the bound texture object.
Multisampling
See glIsEnabled with argument GL_MULTISAMPLE, glIsEnabled with argument GL_SAMPLE_ALPHA_TO_COVERAGE, glIsEnabled with argument GL_SAMPLE_ALPHA_TO_ONE, glIsEnabled with argument GL_SAMPLE_COVERAGE, glIsEnabled with argument GL_SAMPLE_MASK.
- GL_MAX_SAMPLE_MASK_WORDS (integer, at least 1)
- The maximum number of sample mask words.
- GL_MULTISAMPLE (boolean, initially GL_TRUE, see glSampleCoverage)
- Whether to use multisample rasterization.
- GL_SAMPLE_ALPHA_TO_COVERAGE (boolean, initially GL_FALSE, see glSampleCoverage)
- Whether to modify coverage from alpha.
- GL_SAMPLE_ALPHA_TO_ONE (boolean, initially GL_FALSE, see glSampleCoverage)
- Whether to set alpha to max.
- GL_SAMPLE_BUFFERS (integer, at least 0, see glSampleCoverage)
- The number of sample buffers associated with the framebuffer.
- GL_SAMPLE_COVERAGE (boolean, initially GL_FGALSE, see glSampleCoverage)
- Whether to use a mask to modify coverage.
- GL_SAMPLE_COVERAGE_INVERT (boolean, initially GL_FALSE, see glSampleCoverage)
- Whether to invert coverage mask value.
- GL_SAMPLE_COVERAGE_VALUE (float, initially 1, see glSampleCoverage)
- The sample coverage mask value.
- GL_SAMPLE_MASK (boolean, initially GL_TRUE, see glSampleCoverage)
- Whether use of the the sample mask is enabled.
- GL_SAMPLE_MASK_VALUE (indexed[n] integer, initially ~0 (all bits set), see glSampleMask)
- Indexed; the fragment coverage of a sample mask value. The number of elements may be returned with glGet with argument GL_MAX_SAMPLE_MASK_WORDS.
- GL_SAMPLES (integer, at least 0, see glSampleCoverage)
- The coverage mask size.
Pixel Operations
The blend operations all have single or indexed forms, for when there are more than one color buffers. The non-indexed forms return the first color buffer's settings.
- GL_BLEND (single or indexed[value of MAX_DRAW_BUFFERS] boolean, initially GL_FALSE, see glBlendFunc)
- Whether blending is enabled.
- GL_BLEND_COLOR (single or indexed[value of MAX_DRAW_BUFFERS] float[4], initially (0.0, 0.0, 0.0, 0.0), see glBlendColor)
- The red, green, blue, and alpha values which are the components of the blend color.
- GL_BLEND_DST_ALPHA
- params returns one value, the symbolic constant identifying the alpha destination blend function. The initial value is GL_ZERO. See glBlendFunc and glBlendFuncSeparate.
- GL_BLEND_DST_RGB (single or indexed[value of MAX_DRAW_BUFFERS] symbolic constant, initially GL_ZERO
- params returns one value, the symbolic constant identifying the RGB destination blend function. The initial value is GL_ZERO. See glBlendFunc and glBlendFuncSeparate.
- GL_BLEND_EQUATION_RGB (single or indexed[value of MAX_DRAW_BUFFERS] symbolic constant, initially GL_FUNC_ADD, see glBlendEquationSeparate)
- The RGB blend equation selection.
- GL_BLEND_EQUATION_ALPHA (single or indexed[value of MAX_DRAW_BUFFERS] symbolic constant, initially GL_FUNC_ADD, see glBlendEquationSeparate)
- The Alpha blend equation selection.
- GL_BLEND_SRC_ALPHA (single or indexed[value of MAX_DRAW_BUFFERS] symbolic constant, initially GL_ONE, see glBlendFunc and glBlendFuncSeparate)
- The alpha source blend function.
- GL_BLEND_SRC_RGB (single or indexed[value of MAX_DRAW_BUFFERS] symbolic constant, initially GL_ONE, see glBlendFunc and glBlendFuncSeparate)
- The RGB source blend function.
- GL_COLOR_LOGIC_OP (boolean, initially GL_FALSE, see glLogicOp)
- Whether a fragment's RGBA color values are merged into the framebuffer using a logical operation.
- GL_DITHER (boolean, initially GL_TRUE)
- Whether dithering of fragment colors and indices is enabled.
- GL_LOGIC_OP_MODE (symbolic constant, initially GL_COPY, see glLogicOp)
- The selected logic operation mode.
- GL_SCISSOR_BOX (indexed[value of GL_MAX_VIEWPORTS] float[4], see glScissor)
- The x and y window coordinates of the scissor box, followed by its width and height. Initially the x and y window coordinates are both 0 and the width and height are set to the size of the window. See glScissor. Using this name with the non-indexed glGet returns the first scissor box.
- GL_SCISSOR_TEST (indexed[value of GL_MAX_VIEWPORTS] boolean, initially GL_FALSE, see glScissor)
- Whether scissoring is enabled for this viewport.
Pixel Transfer Operations
See OpenGL 4.4, table 23.28, page 549.
- GL_CLAMP_READ_COLOR (enumeration, initially GL_FIXED_ONLY, see glClampColor)
- The read color clamping.
- GL_IMPLEMENTATION_COLOR_READ_FORMAT (symbolic constant, default GL_RGBA, see glReadPixels)
- The implementation's preferred pixel data format.
- GL_IMPLEMENTATION_COLOR_READ_TYPE (symbolic constant, default GL_UNSIGNED_BYTE, see glReadPixels)
- The implementation's preferred pixel data type.
- GL_PACK_ALIGNMENT (integer, initially 4, see glPixelStore)
- The byte alignment used for writing pixel data to memory.
- GL_PACK_COMPRESSED_BLOCK_DEPTH (integer, initially 0, see glPixelStore)
- The compressed block depth in pixels.
- GL_PACK_COMPRESSED_BLOCK_HEIGHT (integer, initially 0, see glPixelStore)
- The compressed block height in pixels.
- GL_PACK_COMPRESSED_BLOCK_SIZE (integer, initially 0, see glPixelStore)
- The compressed block size in bytes.
- GL_PACK_COMPRESSED_BLOCK_WIDTH (integer, initially 0, see glPixelStore)
- The compressed block width in pixels.
- GL_PACK_IMAGE_HEIGHT (integer, initially 0, see glPixelStore)
- The image height used for writing pixel data to memory.
- GL_PACK_LSB_FIRST (boolean, initially GL_FALSE, see glPixelStore)
- Whether single-bit pixels being written to memory are written first to the least significant bit of each unsigned byte.
- GL_PACK_ROW_LENGTH (integer, initially 0, see glPixelStore)
- The row length used for writing pixel data to memory.
- GL_PACK_SKIP_IMAGES (integer, initially 0, see glPixelStore)
- The number of pixel images skipped before the first pixel is written into memory.
- GL_PACK_SKIP_PIXELS (integer, initially 0, see glPixelStore)
- The number of pixel locations skipped before the first pixel is written into memory.
- GL_PACK_SKIP_ROWS (integer, initially 0, see glPixelStore)
- The number of rows of pixel locations skipped before the first pixel is written into memory.
- GL_PACK_SWAP_BYTES (boolean, initially GL_FALSE, see glPixelStore)
- Whether the bytes of two-byte and four-byte pixel indices and components are swapped before being written to memory.
- GL_PIXEL_PACK_BUFFER_BINDING (name, initially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_PIXEL_PACK_BUFFER, or 0 if none is bound.
- GL_PIXEL_UNPACK_BUFFER_BINDING (name, intiially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_PIXEL_UNPACK_BUFFER, or 0 is none is bound.
- GL_UNPACK_ALIGNMENT (integer, initially 4, see glPixelStore)
- The byte alignment used for reading pixel data from memory.
- GL_UNPACK_COMPRESSED_BLOCK_DEPTH (integer, initially 0, see glPixelStore)
- The compressed block depth in pixels.
- GL_UNPACK_COMPRESSED_BLOCK_HEIGHT (integer, initially 0, see glPixelStore)
- The compressed block height in pixels.
- GL_UNPACK_COMPRESSED_BLOCK_SIZE (integer, initially 0, see glPixelStore)
- The compressed block size in bytes.
- GL_UNPACK_COMPRESSED_BLOCK_WIDTH (integer, initially 0, see glPixelStore)
- The compressed block width in pixels.
- GL_UNPACK_IMAGE_HEIGHT (integer, initially 0, see glPixelStore)
- The image height used for reading pixel data from memory.
- GL_UNPACK_LSB_FIRST (boolean, initially GL_FALSE, see glPixelStore)
- Whether single-bit pixels being read from memory are read first from the least significant bit of each unsigned byte.
- GL_UNPACK_ROW_LENGTH (integer, initially 0, see glPixelStore)
- The row length used for reading pixel data from memory.
- GL_UNPACK_SKIP_IMAGES (integer, initially 0, see glPixelStore)
- The number of pixel images skipped before the first pixel is read from memory.
- GL_UNPACK_SKIP_PIXELS (integer, initially 0, see glPixelStore)
- The number of pixel locations skipped before the first pixel is read from memory.
- GL_UNPACK_SKIP_ROWS (integer, initially 0, see glPixelStore)
- The number of rows of pixel locations skipped before the first pixel is read from memory.
- GL_UNPACK_SWAP_BYTES
- params returns a single boolean value indicating whether the bytes of two-byte and four-byte pixel indices and components are swapped after being read from memory. The initial value is GL_FALSE. See glPixelStore.
Programs
This sections contains parameters relevant to programs and common to shader execution. See OpenGL 4.4, table 23.63, page 584.
- GL_CURRENT_PROGRAM (name, initially 0, see glUseProgram)
- The name of the program object that is currently active, or 0 if no program object is active.
- GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE (integer, minimum is 32)
- The maximum size in basic machine units of an atomic counter buffer.
- GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES (integer, minimum is 8)
- The limit on active image units and fragment outputs.
- GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS (integer, minimum is 8)
- The number of shader storage blocks accessible by a program.
- GL_MAX_IMAGE_SAMPLES (integer, minimum is 0)
- The maximum number of allowed samples for a texture level bound to an image unit.
- GL_MAX_IMAGE_UNITS (integer, minimum is 8)
- The number of units for image load, store, and atomic functions.
- GL_MAX_PROGRAM_TEXEL_OFFSET (integer, minimum is 7)
- The maximum texel offset allowed in a texture lookup.
- GL_MAX_SHADER_STORAGE_BLOCK_SIZE (64-bit integer, minimum is 224 (16,777,216))
- The maximum size in basic machine units of a shader storage block.
- GL_MAX_SUBROUTINES (integer, minimum is 256)
- The maximum number of subroutines per shader stage.
- GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS (integer, minimum is 1024)
- The maximum number of subroutine uniform locations per shader stage.
- GL_MAX_UNIFORM_BLOCK_SIZE (integer, minimum is 16384)
- The maximum size in basic machine units of a uniform block.
- GL_MAX_UNIFORM_LOCATIONS (integer, minimum is 1024)
- The maximum number of explicitly assignable uniform locations.
- GL_MAX_VARYING_VECTORS (integer, minimum is 15)
- The number of four-component vectors for varying variables.
- GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET (integer, minimum is 2047)
- The maximum offset that may be added to a vertex binding offset.
- GL_MAX_VERTEX_ATTRIB_BINDINGS (integer, minimum is 16)
- The maximum number of vertex buffers that may be bound.
- GL_MAX_VERTEX_ATTRIB_STRIDE (integer, minimum is 2048, see glVertexAttribPointer)
- The maximum vertex attribute stride.
- GL_MIN_PROGRAM_TEXEL_OFFSET (integer, maximum is -8)
- The minimum texel offset allowed in a texture lookup.
- GL_NUM_PROGRAM_BINARY_FORMATS (integer, at least 0)
- The number of program binary formats supported by the implementation and returned from GL_PROGRAM_BINARY_FORMATS
- GL_NUM_SHADER_BINARY_FORMATS (integer, at least 0)
- The number of shader binary formats supported by the implementation and returned from GL_SHADER_BINARY_FORMATS
- GL_PROGRAM_BINARY_FORMATS (integer[value of GL_NUM_PROGRAM_BINARY_FORMATS])
- An array of GL_NUM_PROGRAM_BINARY_FORMATS values, indicating the program binary formats supported by the implementation.
- GL_PROGRAM_PIPELINE_BINDING (name, initially 0, see glBindProgramPipeline)
- The name of the currently bound program pipeline object, or 0 if no program pipeline object is bound.
- GL_SHADER_BINARY_FORMATS (integer[value of GL_NUM_SHADER_BINARY_FORMATS])
- An array of GL_NUM_SHADER_BINARY_FORMATS values, indicating the shader binary formats supported by the implementation.
- GL_SHADER_COMPILER (boolean, always GL_TRUE)
- Whether an online shader compiler is present in the implementation. All desktop OpenGL implementations must support online shader compilations, and therefore the value of GL_SHADER_COMPILER will always be GL_TRUE.
- GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT (integer, defaults to 256, see glShaderStorageBlockBinding)
- The minimum required alignment for shader storage buffer sizes and offset.
- GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT (integer, defaults to 1, see glUniformBlockBinding)
- The minimum required alignment for uniform buffer sizes and offset.
Provoking Vertices
- GL_VIEWPORT_INDEX_PROVOKING_VERTEX (enumeration, see glProvokingVertex)
- params returns one value, the implementation dependent specifc vertex of a primitive that is used to select the viewport index and gl_ViewportIndex. If the value returned is equivalent to GL_PROVOKING_VERTEX, then the vertex selection follows the convention specified by glProvokingVertex. If the value returned is equivalent to GL_FIRST_VERTEX_CONVENTION, then the selection is always taken from the first vertex in the primitive. If the value returned is equivalent to GL_LAST_VERTEX_CONVENTION, then the selection is always taken from the last vertex in the primitive. If the value returned is equivalent to GL_UNDEFINED_VERTEX, then the selection is not guaranteed to be taken from any specific vertex in the primitive.
- GL_LAYER_PROVOKING_VERTEX (enumeration, see glProvokingVertex)
- The implementation dependent specific vertex of a primitive that is used to select the rendering layer and gl_Layer. If the value returned is equivalent to GL_PROVOKING_VERTEX, then the vertex selection follows the convention specified by glProvokingVertex. If the value returned is equivalent to GL_FIRST_VERTEX_CONVENTION, then the selection is always taken from the first vertex in the primitive. If the value returned is equivalent to GL_LAST_VERTEX_CONVENTION, then the selection is always taken from the last vertex in the primitive. If the value returned is equivalent to GL_UNDEFINED_VERTEX, then the selection is not guaranteed to be taken from any specific vertex in the primitive.
- GL_PROVOKING_VERTEX (enumeration, initially GL_LAST_VERTEX_CONVENTION, see glProvokingVertex)
- The provoking vertex mode.
Rasterization
See OpenGL 4.4, table 23.9, page 530.
- GL_ALIASED_LINE_WIDTH_RANGE (float[2], defaults to (1, 1), see glLineWidth)
- The range of widths supported for aliased lines.
- GL_CULL_FACE (boolean, initially FALSE)
- Whether polygon culling is enabled. See glCullFace and glIsEnabled with argument GL_CULL_FACE.
- GL_CULL_FACE_MODE (enumeration, initially GL_BACK)
- What face to cull when culling is enabled. See glCullFace.
- GL_FRONT_FACE (enumeration, initially GL_CCW
- Whether clockwise or anticlockwise are considered front facing polygons. See glFrontFace.
- GL_LINE_SMOOTH (boolean, initially FALSE)
- Whether to antialias lines. See glIsEnabled with argument GL_LINE_SMOOTH.
- GL_LINE_WIDTH (float, initially 1.0)
- The line width as specified with glLineWidth.
- GL_POINT_FADE_THRESHOLD_SIZE (float, initially 1.0)
- The point size threshold for alpha attenuation, as specified with glPointParameter with argument GL_POINT_FADE_THRESHOLD_SIZE.
- GL_POINT_SIZE (float, initially 1.0, see glPointSize)
- The point size.
- GL_POINT_SIZE_GRANULARITY (float, see glPointSize)
- The size difference between adjacent supported sizes for antialiased points.
- GL_POINT_SIZE_RANGE (float[2], defaults to (1, 1), see glPointSize)
- The smallest and largest supported sizes for antialiased points.
- GL_POINT_SPRITE_COORD_ORIGIN (enumeration, initially GL_UPPER_LEFT)
- The origin orientation for point sprites, as specified with glPointParameter with argument GL_POINT_SPRITE_COORD_ORIGIN.
- GL_POLYGON_MODE (enumeration[2], initially GL_FILL)
- The polygon rasterization mode for front and back faces.
- GL_POLYGON_OFFSET_FACTOR
- params returns one value, the scaling factor used to determine the variable offset that is added to the depth value of each fragment generated when a polygon is rasterized. The initial value is 0. See glPolygonOffset.
- GL_POLYGON_OFFSET_FILL (boolean, initially GL_FALSE)
- Whether polygon offset is enabled for polygons in fill mode. See glPolygonOffset.
- GL_POLYGON_OFFSET_LINE (boolean, initially GL_FALSE)
- Whether polygon offset is enabled for polygons in line mode. See glPolygonOffset.
- GL_POLYGON_OFFSET_POINT (boolean, initially GL_FALSE)
- Whether polygon offset is enabled for polygons in point mode. See glPolygonOffset.
- GL_POLYGON_OFFSET_UNITS
- params returns one value. This value is multiplied by an implementation-specific value and then added to the depth value of each fragment generated when a polygon is rasterized. The initial value is 0. See glPolygonOffset.
- GL_POLYGON_SMOOTH (boolean, initially GL_FALSE)
- Whether antialiasing of polygons is enabled. See glPolygonMode and glIsEnabled.
- GL_PROGRAM_POINT_SIZE (boolean, initially GL_FALSE, see glPointSize)
- Whether vertex program point size mode is enabled. If enabled, then the point size is taken from the shader built-in gl_PointSize. If disabled, then the point size is taken from the point state as specified by glPointSize.
- GL_RASTERIZER_DISCARD (boolean, initially GL_FALSE)
- Whether to discard primitives before rasterization. See glIsEnabled.
- GL_SMOOTH_LINE_WIDTH_RANGE (float[2], defaults to (1, 1), see glLineWidth)
- The range of widths supported for smooth (antialiased) lines.
- GL_SMOOTH_LINE_WIDTH_GRANULARITY (float, see glLineWidth)
- The level of quantization applied to smooth line width parameters.
- GL_SUBPIXEL_BITS (integer, at least 4)
- An estimate of the number of bits of subpixel resolution that are used to position rasterized geometry in window coordinates.
Shader Execution
This section contains limits that are relevant to shader execution.
- GL_FRAGMENT_INTERPOLATION_OFFSET_BITS (integer, at least 4)
- The subpixel bits for interpolateAtOffset.
- GL_MAX_FRAGMENT_INTERPOLATION_OFFSET (float, at least 0.5)
- The furthest positive offset for interplateAtOffset.
- GL_MIN_FRAGMENT_INTERPOLATION_OFFSET (float, at most -0.5)
- The furthest negative offset for interpolateAtOffset.
Shaders
This section contains limits that are present in all shader stages and parameters that are the sums of all shader stages. Subsections contain parameters that are specific to individual shader stages. See OpenGL 4.4, tables 23.57-62, page 578.
- GL_MAX_stage_ATOMIC_COUNTER_BUFFERS and GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS
- GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS, GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS, GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS, GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS_ATOMIC_COUNTER_BUFFERS, GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS, GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS
- {The maximum number of atomic counter buffers that may be accessed by a shader of each stage. The minimum value is 0 for all shader stages except for fragment shaders, which is 1. If an atomic counter buffer is used by multiple shader stages, each such use counts separately against the combined limit. The minimum combined limit is 1. See OpenGL 4.4, section 7.7, page 133.
- GL_MAX_stage_ATOMIC_COUNTERS and GL_MAX_COMBINED_ATOMIC_COUNTERS
- GL_MAX_COMPUTE_ATOMIC_COUNTERS, GL_MAX_FRAGMENT_ATOMIC_COUNTERS, GL_MAX_GEOMETRY_ATOMIC_COUNTERS, GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS, GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS, GL_MAX_VERTEX_ATOMIC_COUNTERS
- The maximum number of atomic counters available to shaders of each stage. The minimum value is 0 for all stages except for fragment shaders, which is 8. If more than one pipeline stage accesses the same atomic counter, each such access counts separately towards the combined total. The minimum combined total is 8. See OpenGL 4.4, section 11.1.3.6, page 354.
- GL_MAX_COMBINED_stage_UNIFORM_COMPONENTS
- GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS, GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS, GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS, GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS, GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS, GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS
- The maximum number of words for compute shader uniform variables in all uniform blocks (including default). The value must be at least (GL_MAX_stage_UNIFORM_BLOCK × GL_MAX_stage_UNIFORM_BLOCK_SIZE ÷ 4 + GL_MAX_stage_UNIFORM_COMPONENTS. See glUniform, OpenGL 4.4, table 7.5, page 118, and OpenGL 4.4, table 23.66, page 587.
- GL_MAX_stage_IMAGE_UNIFORMS and GL_MAX_COMBINED_IMAGE_UNIFORMS
- GL_MAX_COMPUTE_IMAGE_UNIFORMS, GL_MAX_FRAGMENT_IMAGE_UNIFORMS, GL_MAX_GEOMETRY_IMAGE_UNIFORMS, GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS, GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS, GL_MAX_VERTEX_IMAGE_UNIFORMS
- The maximum number of image uniforms available to the individual shader stage. If more than one shader stage accesses the same uniform, each such access counts separately. There is no minimum value except for the compute and fragment shader stages where it must be at least 8. The combined limit must be at least 8. See OpenGL 4.4, section 11.1.3.7, page 355.
- GL_MAX_stage_SHADER_STORAGE_BLOCKS and GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS
- GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS, GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS, GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS, GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS, GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS, GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS
- The maximum number of active shader storage blocks that may be accessed by a shader. There is no minimum limit except in fragment shaders where the minimum is 8. The combined limit must also be at least 8. See OpenGL 4.4, section 7.8, page 135.
- GL_MAX_stage_UNIFORM_COMPONENTS
- GL_MAX_COMPUTE_UNIFORM_COMPONENTS, GL_MAX_FRAGMENT_UNIFORM_COMPONENTS, GL_MAX_GEOMETRY_UNIFORM_COMPONENTS, GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS, GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS, GL_MAX_VERTEX_UNIFORM_COMPONENTS
- The maximum number of individual floating-point, integer, or boolean values that can be held in uniform variable storage for a shader. The value must be at least 512 for compute and geometry shaders, and 1024 for all other shader stages. See glUniform.
- GL_MAX_stage_TEXTURE_IMAGE_UNITS, GL_MAX_TEXTURE_IMAGE_UNITS (fragment), GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS
- GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS, GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS, GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS, GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS, GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS
- The maximum supported texture image units that can be used to access texture maps from the shader. The value may be at least 16. The combined limit must be at least 96. See glActiveTexture.
- GL_MAX_stage_COMPUTE_UNIFORM_BLOCKS and GL_MAX_COMBINED_UNIFORM_BLOCKS
- GL_MAX_COMPUTE_UNIFORM_BLOCKS, GL_MAX_FRAGMENT_UNIFORM_BLOCKS, GL_MAX_GEOMETRY_UNIFORM_BLOCKS, GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS, GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS, GL_MAX_VERTEX_UNIFORM_BLOCKS
- The maximum number of uniform blocks per shader. The value must be at least 14, and the combined limit must be at least 70. See glUniformBlockBinding.
Compute Shaders
See OpenGL 4.4, table 23.62, page 583.
- GL_DISPATCH_INDIRECT_BUFFER_BINDING (GLint, initially 0, see glBindBuffer)
- The name of the buffer object currently bound to the target GL_DISPATCH_INDIRECT_BUFFER, or 0 if none is bound.
- GL_MAX_COMPUTE_SHARED_MEMORY_SIZE (GLint, minimum is 32768)
- The maximum total storage size in bytes of all variables declared as shared in all compute shaders linked into a single program object.
- GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS (GLint, minimum is 1024)
- The number of invocations in a single local work group (i.e., the product of the three dimensions) that may be dispatched to a compute shader, which must be at least 1024.
- GL_MAX_COMPUTE_WORK_GROUP_COUNT (indexed[3] GLint, minimum is [65535, 65535, 65535])
- The maximum number of work groups that may be dispatched to a compute shader. Accepted by the indexed versions of glGet. Indices 0, 1, and 2 correspond to the X, Y and Z dimensions, respectively. The minimum is 65535 in each dimension.
- GL_MAX_COMPUTE_WORK_GROUP_SIZE (indexed[3] GLint, minimum is [1024, 1024, 64])
- The maximum size of a work groups that may be used during compilation of a compute shader. Accepted by the indexed versions of glGet. Indices 0, 1, and 2 correspond to the X, Y and Z dimensions, respectively.
Fragment Shaders
See OpenGL 4.4, table 23.61, page 582.
- GL_MAX_FRAGMENT_INPUT_COMPONENTS (GLint, at least 128)
- The maximum number of components of the inputs read by the fragment shader.
- GL_MAX_FRAGMENT_UNIFORM_VECTORS (GLint, at least 256)
- The maximum number of individual 4-vectors of floating-point, integer, or boolean values that can be held in uniform variable storage for a fragment shader. The value is equal to the value of GL_MAX_FRAGMENT_UNIFORM_COMPONENTS divided by 4. See glUniform.
- GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET (GLint, at least 7)
- The maximum texel offset for textureGather. See OpenGL 4.4, section 8.14.1, page 226.
- GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET (GLint, at most -8)
- The minimum texel offset for textureGather. See OpenGL 4.4, section 8.14.1, page 226.
Geometry Shaders
See OpenGL 4.4, table 23.60, page 581.
- GL_MAX_GEOMETRY_INPUT_COMPONENTS (GLint, at least 64)
- The maximum number of components of inputs read by a geometry shader.
- GL_MAX_GEOMETRY_OUTPUT_COMPONENTS (GLint, at least 128)
- The maximum number of components of outputs written by a geometry shader.
- GL_MAX_GEOMETRY_OUTPUT_VERTICES (GLint, at least 256)
- The maximum number of components of outputs written by a geometry shader.
- GL_MAX_GEOMETRY_SHADER_INVOCATIONS (GLint, at least 32)
- The maximum supported geometry shader invocation count.
- GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS (GLint, at least 1024)
- The maximum number of all components all vertices written by a geometry shader.
- GL_MAX_VERTEX_STREAMS (GLint, at least 4, see OpenGL 4.4, section 11.3.4.3, page 384)
- The total number of vertex streams geometry shaders may output to.
Tessellation Control Shaders
See OpenGL 4.4, table 23.2, page 523 and OpenGL 4.4, table 23.58, page 579.
- GL_MAX_PATCH_VERTICES (GLint, at least 32, see glPatchParameter and OpenGL 4.4, section 10.1.15, page 306)
- The maximum number of vertices in a patch primitive.
- GL_MAX_TESS_CONTROL_INPUT_COMPONENTS (GLint, at least 128, see OpenGL 4.4, section 11.2.1.2.2, page 363)
- The number of components for tessellation control shader per-vertex inputs.
- GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS (GLint, at least 128, see OpenGL 4.4, section 11.2.1.2.3, page 365)
- The number of components for tessellation control shader per-vertex outputs.
- GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS (GLint, at least 4096, see OpenGL 4.4, section 11.2.1.2.3, page 365)
- The number of components for tessellation control shader per-patch outputs.
- GL_MAX_TESS_GEN_LEVEL (GLint, at least 64, see OpenGL 4.4, section 11.2.2, page 368)
- The maximum level supported by the tessellation primitive generator.
- GL_MAX_TESS_PATCH_COMPONENTS (GLint, at least 120, see OpenGL 4.4, section 11.2.1.2.3, page 365)
- The number of components for tessellation control shader per-patch outputs.
- GL_PATCH_DEFAULT_INNER_LEVEL (GLfloat[2], initially (1.0, 1.0))
- The default inner tessellation level without a control shader.
- GL_PATCH_DEFAULT_OUTER_LEVEL (GLfloat[4], initially (1.0, 1.0, 1.0, 1.0))
- The default outer tessellation level without a control shader.
- GL_PATCH_VERTICES (GLint, initially 3)
- The number of vertices in the input patch.
Tessellation Evaluation Shaders
See OpenGL 4.4, table 23.59, page 580.
- GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS (GLint, at least 128, see OpenGL 4.4, section 11.2.3.3, page 379)
- The number of components for tesselation evaluation shader per-vertex inputs.
- GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS (GLint, at least 128, see OpenGL 4.4, section 11.2.3.4, page 380)
- The number of components for tesselation evaluation shader per-vertex outputs.
Vertex Shaders
See OpenGL 4.4, table 23.57, page 578.
- GL_MAX_VERTEX_ATTRIBS (GLint, at least 16, see glVertexAttrib)
- The maximum number of 4-component generic vertex attributes accessible to a vertex shader.
- GL_MAX_VERTEX_OUTPUT_COMPONENTS (GLint, at least 64)
- The maximum number of components of output written by a vertex shader.
- GL_MAX_VERTEX_UNIFORM_VECTORS (GLint, at least 256)
- The maximum number of 4-vectors that may be held in uniform variable storage for the vertex shader. The value of GL_MAX_VERTEX_UNIFORM_VECTORS is equal to the value of GL_MAX_VERTEX_UNIFORM_COMPONENTS divided by 4.
Textures
- GL_ACTIVE_TEXTURE (GLenum, default GL_TEXTURE0, see glActiveTexture)
- The active multitexture unit.
- GL_COMPRESSED_TEXTURE_FORMATS (GLenum[], see glCompressedTexImage2D
- A list of symbolic constants of length GL_NUM_COMPRESSED_TEXTURE_FORMATS indicating which compressed texture formats are available and suited for general-purpose usage. Formats with restrictions that need to be specifically understood prior to use will not be returned by this query. This query has been deprecated in OpenGL 4.2, because the vaguess of the term "general-purpose" makes it possible for implementations to choose to return no formats from the query.
- GL_MAX_3D_TEXTURE_SIZE (GLint, at least 2048, see glTexImage3D)
- The largest 3D texture dimension that the GL can handle. Use GL_PROXY_TEXTURE_3D to determine if a texture is too large.
- GL_MAX_ARRAY_TEXTURE_LAYERS (GLint, at least 2048, see glTexImage2D)
- The maximum number of layers allowed in an array texture.
- GL_MAX_CUBE_MAP_TEXTURE_SIZE (GLint, at least 16384, see glTexImage2D)
- The largest cube-map texture dimension that the GL can handle. Use GL_PROXY_TEXTURE_CUBE_MAP to determine if a texture is too large.
- GL_MAX_RECTANGLE_TEXTURE_SIZE (GLint, minimum 16384, see glTexImage2D)
- The largest rectangular texture dimensions that the GL can handle. Use GL_PROXY_RECTANGLE_TEXTURE to determine if a texture is too large. See glTexImage2D.
- GL_MAX_RENDERBUFFER_SIZE (GLint, at least 16384, see glFramebufferRenderbuffer)
- The maximum supported width and height for renderbuffers.
- GL_MAX_TEXTURE_BUFFER_SIZE (GLint, at least 65536)
- The maximum number of texels allowed in the texel array of a texture buffer object.
- GL_MAX_TEXTURE_LOD_BIAS (GLfloat, at least 2.0)
- The maximum, absolute value of the texture level-of-detail bias.
- GL_MAX_TEXTURE_SIZE (GLint, at least 16384, see glTexImage1D and glTexImage2D)
- The largest texture dimension that the GL can handle for 1D and 2D textures. Use a proxy texture target such as GL_PROXY_TEXTURE_1D or GL_PROXY_TEXTURE_2D to determine if a texture is too large.
- GL_NUM_COMPRESSED_TEXTURE_FORMATS (GLint, at least 18, see glCompressedTexImage2D)
- The number of available compressed texture formats that will be returned from GL_COMPRESSED_TEXTURE_FORMATS.
- GL_SAMPLER_BINDING (GLint, default 0, see glBindSampler)
- The name of the sampler object currently bound to the active texture unit.
- GL_TEXTURE_BINDING_type (GLint, default 0)
- GL_TEXTURE_BINDING_1D, GL_TEXTURE_BINDING_1D_ARRAY, GL_TEXTURE_BINDING_2D, GL_TEXTURE_BINDING_2D_ARRAY, GL_TEXTURE_BINDING_2D_MULTISAMPLE, GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY, GL_TEXTURE_BINDING_3D, GL_TEXTURE_BINDING_BUFFER, GL_TEXTURE_BINDING_CUBE_MAP, GL_TEXTURE_BINDING_RECTANGLE
- The name of the texture currently bound to the target. See glBindTexture. The corresponding targets are GL_TEXTURE_1D, GL_TEXTURE_1D_ARRAY, GL_TEXTURE_2D, GL_TEXTURE_2D_ARRAY, GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_TEXTURE_3D, GL_TEXTURE_BUFFER, GL_TEXTURE_CUBE_MAP, and GL_TEXTURE_RECTANGLE.
- GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT (GLint, at least 1, see glUniformBlockBinding)
- The minimum required alignment for texture buffer sizes and offset.
- GL_TEXTURE_CUBE_MAP_SEAMLESS (GLboolean, initially GL_FALSE)
- Whether seamless cube map filtering is enabled.
Transformation State
See OpenGL 4.4, table 23.7, page 528.
- GL_CLIP_DISTANCEi
- params returns one boolean value, whether the ith user clipping plane is enabled, which is initially FALSE. See glIsEnabled.
- GL_DEPTH_CLAMP (GLboolean, initially GL_FALSE, see glIsEnabled)
- Whether depth clamping is enabled.
- GL_DEPTH_RANGE (GLfloat[2], initially (0.0, 1.0), see glDepthRange)
- The near and far mapping limits for the depth buffer. Integer values, if requested, are linearly mapped from the internal floating-point representation such that 1.0 returns the most positive representable integer value, and -1.0 returns the most negative representable integer value.
- GL_MAX_CLIP_DISTANCES (GLint, at least 8)
- The maximum number of application-defined clipping planes.
- GL_MAX_VIEWPORT_DIMS (GLfloat[2], see glViewport)
- The maximum supported width and height of the viewport. These must be at least as large as the visible dimensions of the display being rendered to.
- GL_MAX_VIEWPORTS (GLint, at least 16, see glViewportIndexed)
- The maximum number of simultaneous viewports that are supported.
- GL_TRANSFORM_FEEDBACK_BINDING (GLint, initially 0)
- The name of the object bound for transform feedback operations.
- GL_VIEWPORT
- When used with non-indexed variants of glGet (such as glGetIntegerv), params returns four values: the x and y window coordinates of the viewport, followed by its width and height. Initially the x and y window coordinates are both set to 0, and the width and height are set to the width and height of the window into which the GL will do its rendering. See glViewport. When used with indexed variants of glGet (such as glGetIntegeri_v), params returns four values: the x and y window coordinates of the indexed viewport, followed by its width and height. Initially the x and y window coordinates are both set to 0, and the width and height are set to the width and height of the window into which the GL will do its rendering. See glViewportIndexed.
- GL_VIEWPORT_BOUNDS_RANGE (GLfloat[2], at least (-32768, 32767))
- The minimum and maximum viewport bounds range.
- GL_VIEWPORT_SUBPIXEL_BITS (GLint, at least 0)
- The number of bits of sub-pixel precision which the GL uses to interpret the floating point viewport bounds.
Vertex Arrays
Also see glGetVertexAttrib, glGetVertexAttribPointer, and glGetObjectLabel.
- GL_MAX_ELEMENT_INDEX (64-bit integer, always (232 - 1) (4,294,967,294))
- The maximum index that may be specified during the transfer of generic vertex attributes to the GL. This is maintained for compatibility with OpenGL ES.
- GL_MAX_ELEMENTS_INDICES (integer, see glDrawRangeElements)
- The recommended maximum number of vertex array indices.
- GL_MAX_ELEMENTS_VERTICES (integer, see glDrawRangeElements)
- The recommended maximum number of vertex array vertices.
- GL_PRIMITIVE_RESTART (boolean, initially GL_FALSE, see glIsEnabled)
- Whether primitive restart is enabled.
- GL_PRIMITIVE_RESTART_FIXED_INDEX (boolean, initially GL_FALSE)
- Whether primitive restart fixed index is enabled.
- GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED (boolean)
- Whether primitive restart support is available for a GL_PATCHES primitive.
- GL_PRIMITIVE_RESTART_INDEX (integer, initially 0, see glPrimitiveRestartIndex)
- The current primitive restart index.
- GL_VERTEX_BINDING_DIVISOR (indexed[] GLint)
- The instance step divisor of the first element in the bound buffer's data store for vertex attribute bound to the index.
- GL_VERTEX_BINDING_OFFSET (indexed[] GLint64, initially 0)
- Accepted by the indexed forms. params returns a single 64-bit integer value representing the byte offset of the first element in the bound buffer's data store for vertex attribute bound to index.
- GL_VERTEX_BINDING_STRIDE (intexed[] GLint, initially 0)
- Accepted by the indexed forms. params returns a single integer value representing the byte offset between the start of each element in the bound buffer's data store for vertex attribute bound to index.
Notes
The following parameters return the associated value for the active texture unit: GL_TEXTURE_1D, GL_TEXTURE_BINDING_1D, GL_TEXTURE_2D, GL_TEXTURE_BINDING_2D, GL_TEXTURE_3D and GL_TEXTURE_BINDING_3D.
GL_MAX_VIEWPORTS, GL_VIEWPORT_SUBPIXEL_BITS, GL_VIEWPORT_BOUNDS_RANGE, GL_LAYER_PROVOKING_VERTEX, and GL_VIEWPORT_INDEX_PROVOKING_VERTEX are available only if the GL version is 4.1 or greater.
GL_MAX_VERTEX_ATOMIC_COUNTERS, GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS, GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS, GL_MAX_GEOMETRY_ATOMIC_COUNTERS, GL_MAX_FRAGMENT_ATOMIC_COUNTERS, and GL_MIN_MAP_BUFFER_ALIGNMENT are accepted by pname only if the GL version is 4.2 or greater.
GL_MAX_ELEMENT_INDEX is accepted by pname only if the GL version is 4.3 or greater.
GL_MAX_COMPUTE_UNIFORM_BLOCKS, GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS, GL_MAX_COMPUTE_UNIFORM_COMPONENTS, GL_MAX_COMPUTE_ATOMIC_COUNTERS, GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS, GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS, GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS, GL_MAX_COMPUTE_WORK_GROUP_COUNT, and GL_MAX_COMPUTE_WORK_GROUP_SIZE and GL_DISPATCH_INDIRECT_BUFFER_BINDING are available only if the GL version is 4.3 or greater.
GL_MAX_DEBUG_GROUP_STACK_DEPTH, GL_DEBUG_GROUP_STACK_DEPTH and GL_MAX_LABEL_LENGTH are accepted only if the GL version is 4.3 or greater.
GL_MAX_UNIFORM_LOCATIONS is accepted only if the GL version is 4.3 or greater.
GL_MAX_FRAMEBUFFER_WIDTH, GL_MAX_FRAMEBUFFER_HEIGHT, GL_MAX_FRAMEBUFFER_LAYERS, and GL_MAX_FRAMEBUFFER_SAMPLES are available only if the GL version is 4.3 or greater.
GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS, GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS, GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS, GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS, GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS, and GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS are available only if the GL version is 4.3 or higher.
GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT is available only if the GL version is 4.3 or greater.
GL_VERTEX_BINDING_DIVISOR, GL_VERTEX_BINDING_OFFSET, GL_VERTEX_BINDING_STRIDE, GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET and GL_MAX_VERTEX_ATTRIB_BINDINGS are available only if the GL version is 4.3 or greater.
GL_MAX_VARYING_COMPONENTS and GL_MAX_VARYING_FLOATS are deprecated in GL version 4.4.
Errors
GL_INVALID_ENUM is generated if pname is not an accepted value.
GL_INVALID_VALUE is generated on any of glGetBooleani_v, glGetIntegeri_v, glGetFloati_v, glGetDoublei_v, or glGetInteger64i_v if index is outside of the valid range for the indexed state target.
See Also
glGetActiveUniform, glGetAttachedShaders, glGetAttribLocation, glGetBufferParameter, glGetBufferPointerv, glGetBufferSubData, glGetCompressedTexImage, glGetError, glGetProgram, glGetProgramInfoLog, glGetQueryiv, glGetQueryObject, glGetShader, glGetShaderInfoLog, glGetShaderSource, glGetString, glGetTexImage, glGetTexLevelParameter, glGetTexParameter, glGetUniform, glGetUniformLocation, glGetVertexAttrib, glGetVertexAttribPointerv, glIsEnabled
Copyright
Copyright © 1991-2006 Silicon Graphics, Inc. Copyright © 2010-2011 Khronos Group. This document is licensed under the SGI Free Software B License. For details, see http://oss.sgi.com/projects/FreeB/.