Gl.GetProgramiv (gb.opengl.glsl)

Static Function GetProgramiv ( Program As Integer, Pname As Integer ) As Integer[]

Parameters

program

Specifies the program object to be queried.
pname

Specifies the object parameter. Accepted symbolic names are Gl.DELETE_STATUS, Gl.LINK_STATUS, Gl.VALIDATE_STATUS, Gl.INFO_LOG_LENGTH, Gl.ATTACHED_SHADERS, Gl.ACTIVE_ATTRIBUTES, Gl.ACTIVE_ATTRIBUTE_MAX_LENGTH, Gl.ACTIVE_UNIFORMS, Gl.ACTIVE_UNIFORM_BLOCKS, Gl.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH, Gl.ACTIVE_UNIFORM_MAX_LENGTH, Gl.TRANSFORM_FEEDBACK_BUFFER_MODE, Gl.TRANSFORM_FEEDBACK_VARYINGS, Gl.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH, Gl.GEOMETRY_VERTICES_OUT, Gl.GEOMETRY_INPUT_TYPE, and Gl.GEOMETRY_OUTPUT_TYPE.
params

Returns the requested object parameter.

Description

Gl.GetProgram returns in params the value of a parameter for a specific program object. The following parameters are defined:
Gl.DELETE_STATUS

params returns Gl.TRUE if program is currently flagged for deletion, and Gl.FALSE otherwise.
Gl.LINK_STATUS

params returns Gl.TRUE if the last link operation on program was successful, and Gl.FALSE otherwise.
Gl.VALIDATE_STATUS

params returns Gl.TRUE or if the last validation operation on program was successful, and Gl.FALSE otherwise.
Gl.INFO_LOG_LENGTH

params returns the number of characters in the information log for program including the null termination character (i.e., the size of the character buffer required to store the information log). If program has no information log, a value of 0 is returned.
Gl.ATTACHED_SHADERS

params returns the number of shader objects attached to program.
Gl.ACTIVE_ATTRIBUTES

params returns the number of active attribute variables for program.
Gl.ACTIVE_ATTRIBUTE_MAX_LENGTH

params returns the length of the longest active attribute name for program, including the null termination character (i.e., the size of the character buffer required to store the longest attribute name). If no active attributes exist, 0 is returned.
Gl.ACTIVE_UNIFORMS

params returns the number of active uniform variables for program.
Gl.ACTIVE_UNIFORM_MAX_LENGTH

params returns the length of the longest active uniform variable name for program, including the null termination character (i.e., the size of the character buffer required to store the longest uniform variable name). If no active uniform variables exist, 0 is returned.
Gl.TRANSFORM_FEEDBACK_BUFFER_MODE

params returns a symbolic constant indicating the buffer mode used when transform feedback is active. This may be Gl.SEPARATE_ATTRIBS or Gl.INTERLEAVED_ATTRIBS.
Gl.TRANSFORM_FEEDBACK_VARYINGS

params returns the number of varying variables to capture in transform feedback mode for the program.
Gl.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH

params returns the length of the longest variable name to be used for transform feedback, including the null-terminator.
Gl.GEOMETRY_VERTICES_OUT

params returns the maximum number of vertices that the geometry shader in program will output.
Gl.GEOMETRY_INPUT_TYPE

params returns a symbolic constant indicating the primitive type accepted as input to the geometry shader contained in program.
Gl.GEOMETRY_OUTPUT_TYPE

params returns a symbolic constant indicating the primitive type that will be output by the geometry shader contained in program.

Notes

Gl.ACTIVE_UNIFORM_BLOCKS and Gl.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are available only if the GL version 3.1 or greater.

Gl.GEOMETRY_VERTICES_OUT, Gl.GEOMETRY_INPUT_TYPE and Gl.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or greater.

If an error is generated, no change is made to the contents of params.

Errors

Gl.INVALID_VALUE is generated if program is not a value generated by OpenGL.

Gl.INVALID_OPERATION is generated if program does not refer to a program object.

Gl.INVALID_OPERATION is generated if pname is Gl.GEOMETRY_VERTICES_OUT, Gl.GEOMETRY_INPUT_TYPE, or Gl.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.

Gl.INVALID_ENUM is generated if pname is not an accepted value.

Associated Gets

Gl.GetActiveAttrib with argument program

Gl.GetActiveUniform with argument program

Gl.GetAttachedShaders with argument program

Gl.GetProgramInfoLog with argument program

Gl.IsProgram

See also

See original documentation on OpenGL website