Gambas Documentation - /comp/gb.opengl.glsl/gl/isprogram

/comp/gb.opengl.glsl/gl/isprogram

# Gl.IsProgram (gb.opengl.glsl)

Static Function IsProgram ( Program As Integer ) As Boolean

Determines if a name corresponds to a program object.

### Parameters

program

  Specifies a potential program object.

### Description

Gl.IsProgram returns Gl.TRUE if program is the name of a program object previously created with Gl.CreateProgram and not yet deleted with Gl.DeleteProgram. If program is zero or a non-zero value that is not the name of a program object, or if an error occurs, Gl.IsProgram returns Gl.FALSE.

### Notes

No error is generated if program is not a valid program object name.

A program object marked for deletion with Gl.DeleteProgram but still in use as part of current rendering state is still considered a program object and Gl.IsProgram will return Gl.TRUE.

### Associated Gets

Gl.Get with the argument Gl.CURRENT_PROGRAM

Gl.GetActiveAttrib with arguments program and the index of an active attribute variable

Gl.GetActiveUniform with arguments program and the index of an active uniform variable

Gl.GetAttachedShaders with argument program

Gl.GetAttribLocation with arguments program and the name of an attribute variable

Gl.GetProgram with arguments program and the parameter to be queried

Gl.GetProgramInfoLog with argument program

Gl.GetUniform with arguments program and the location of a uniform variable

Gl.GetUniformLocation with arguments program and the name of a uniform variable

### See also

- Gl.AttachShader,

- Gl.BindAttribLocation,

- Gl.CreateProgram,

- Gl.DeleteProgram,

- Gl.DetachShader,

- Gl.LinkProgram,

Glu.niform, Glu.seProgram,

- Gl.ValidateProgram

See original documentation on OpenGL website