GLUS
Functions
glus_program.c File Reference
#include "GL/glus.h"

Functions

GLUSboolean GLUSAPIENTRY glusProgramCreateFromSource (GLUSprogram *shaderProgram, const GLUSchar **vertexSource, const GLUSchar **controlSource, const GLUSchar **evaluationSource, const GLUSchar **geometrySource, const GLUSchar **fragmentSource)
 Creates a program by compiling the giving sources. More...
 
GLUSboolean GLUSAPIENTRY glusProgramCreateComputeFromSource (GLUSprogram *shaderProgram, const GLUSchar **computeSource)
 Creates a compute shader program by compiling the giving source. More...
 
GLUSboolean GLUSAPIENTRY glusProgramLink (GLUSprogram *shaderProgram)
 Links a formerly created program. More...
 
GLUSboolean GLUSAPIENTRY glusProgramBuildFromSource (GLUSprogram *shaderProgram, const GLUSchar **vertexSource, const GLUSchar **controlSource, const GLUSchar **evaluationSource, const GLUSchar **geometrySource, const GLUSchar **fragmentSource)
 Builds a program by compiling and linking the giving sources. More...
 
GLUSboolean GLUSAPIENTRY glusProgramBuildComputeFromSource (GLUSprogram *shaderProgram, const GLUSchar **computeSource)
 Builds a compute shader program by compiling and linking the giving source. More...
 
GLUSboolean GLUSAPIENTRY glusProgramBuildSeparableFromSource (GLUSprogram *shaderProgram, const GLUSenum type, const GLUSchar **source)
 Builds a stand-alone, separable shader program by compiling and linking the giving source. More...
 
GLUSvoid GLUSAPIENTRY glusProgramDestroy (GLUSprogram *shaderprogram)
 Destroys a program by freeing all resources. More...
 

Function Documentation

GLUSboolean GLUSAPIENTRY glusProgramBuildComputeFromSource ( GLUSprogram shaderProgram,
const GLUSchar **  computeSource 
)

Builds a compute shader program by compiling and linking the giving source.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
computeSourceCompute shader source code.
Returns
GLUS_TRUE, if compiling and linking of program succeeded.
GLUSboolean GLUSAPIENTRY glusProgramBuildFromSource ( GLUSprogram shaderProgram,
const GLUSchar **  vertexSource,
const GLUSchar **  controlSource,
const GLUSchar **  evaluationSource,
const GLUSchar **  geometrySource,
const GLUSchar **  fragmentSource 
)

Builds a program by compiling and linking the giving sources.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
vertexSourceVertex shader source code.
controlSourceTessellation control shader source code. Optional.
evaluationSourceTessellation evaluation shader source code. Optional.
geometrySourceGeometry shader source code. Optional.
fragmentSourceFragment shader source code.
Returns
GLUS_TRUE, if compiling and linking of program succeeded.
GLUSboolean GLUSAPIENTRY glusProgramBuildSeparableFromSource ( GLUSprogram shaderProgram,
const GLUSenum  type,
const GLUSchar **  source 
)

Builds a stand-alone, separable shader program by compiling and linking the giving source.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
typeThe type of the shader.
sourceShader source code.
Returns
GLUS_TRUE, if compiling and creation of program succeeded.
GLUSboolean GLUSAPIENTRY glusProgramCreateComputeFromSource ( GLUSprogram shaderProgram,
const GLUSchar **  computeSource 
)

Creates a compute shader program by compiling the giving source.

Linking has to be done in a separate step.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
computeSourceCompute shader source code.
Returns
GLUS_TRUE, if compiling and creation of program succeeded.
GLUSboolean GLUSAPIENTRY glusProgramCreateFromSource ( GLUSprogram shaderProgram,
const GLUSchar **  vertexSource,
const GLUSchar **  controlSource,
const GLUSchar **  evaluationSource,
const GLUSchar **  geometrySource,
const GLUSchar **  fragmentSource 
)

Creates a program by compiling the giving sources.

Linking has to be done in a separate step.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
vertexSourceVertex shader source code.
controlSourceTessellation control shader source code. Optional.
evaluationSourceTessellation evaluation shader source code. Optional.
geometrySourceGeometry shader source code. Optional.
fragmentSourceFragment shader source code.
Returns
GLUS_TRUE, if compiling and creation of program succeeded.
GLUSvoid GLUSAPIENTRY glusProgramDestroy ( GLUSprogram shaderprogram)

Destroys a program by freeing all resources.

Parameters
shaderprogramThis structure holds the necessary information of the program and the different shaders.
GLUSboolean GLUSAPIENTRY glusProgramLink ( GLUSprogram shaderProgram)

Links a formerly created program.

Parameters
shaderProgramThis structure holds the necessary information of the program and the different shaders.
Returns
GLUS_TRUE, if linking of program succeeded.