Graphics Reference
In-Depth Information
Many rendering parameters depend on the underlying capabilities of
the OpenGL ES implementation—for example, how many texture units
are available to a shader, or what the maximum size for a texture map
or aliased point is. Values of those types are queried using one of the
functions shown here:
void
glGetBooleanv
(GLenum
pname
, GLboolean *
params
)
void
glGetFloatv
(GLenum
pname
, GLfloat *
params
)
void
glGetIntegerv
(GLenum
pname
, GLint *
params
)
void
glGetInteger64v
(GLenum
pname
, GLint64 *
params
)
specifies the implementation-specific parameter to be queried
specifies an array of values of the respective type with
enough entries to hold the return values for the associated
parameter
pname
params
A number of implementation-dependent parameters can be queried, as
listed in Table 15-1.
Table 15-1
Implementation-Dependent State Queries
Minimum/
Initial
Value
State Variable
Description
Get Function
GL_MAX_ELEMENT_
INDEX
glGetInteger64v
Maximum element index
2
24
- 1
GL_SUBPIXEL_
BITS
Number of subpixel bits
supported
4
glGetIntegerv
GL_MAX_TEXTURE_
SIZE
Maximum size of a
texture
2048
glGetIntegerv
GL_MAX_3D_
TEXTURE_SIZE
Maximum size of 3D
texture supported
256
glGetIntegerv
GL_MAX_ARRAY_
TEXTURE_LAYERS
glGetIntegerv
Maximum number of
texture layers supported
256
(continues)