Crystal Space: iShaderProgram Struct Reference (Crystal Space Public API Reference)

| ## Public API Reference

- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# iShaderProgram Struct Reference
[Common Plugin Classes]

A helper for shaders that which to use the general plugins. More...

`#include <csplugincommon/shader/shaderplugin.h>`

Inheritance diagram for iShaderProgram:

[legend]
List of all members.

## Public Member Functions
virtual void | Activate ()=0
| Sets this program to be the one used when rendering.
virtual bool | Compile ()=0
| Compile a program.
virtual void | Deactivate ()=0
| Deactivate program so that it's not used in next rendering.
virtual bool | Load (iShaderDestinationResolver *resolve, const char *program, csArray< csShaderVarMapping > &mappings)=0
| Loads from raw text.
virtual bool | Load (iShaderDestinationResolver *resolve, iDocumentNode *node)=0
| Loads from a document-node.
virtual void | ResetState ()=0
| Reset states to original.
virtual void | SetupState (const csRenderMesh *mesh, csRenderMeshModes &modes, const iShaderVarStack *stacks)=0
| Setup states needed for proper operation of the shaderprogram.

## Detailed Description

A helper for shaders that which to use the general plugins.

This is the main program plugin interface

Definition at line 66 of file shaderplugin.h.

## Member Function Documentation

virtual void iShaderProgram::Activate | ( |  | ) | `[pure virtual]`

Sets this program to be the one used when rendering.

virtual bool iShaderProgram::Compile | ( |  | ) | `[pure virtual]`

Compile a program.

virtual void iShaderProgram::Deactivate | ( |  | ) | `[pure virtual]`

Deactivate program so that it's not used in next rendering.

virtual bool iShaderProgram::Load | ( | iShaderDestinationResolver * | resolve,
|  | const char * | program,
|  | csArray< csShaderVarMapping > & | mappings |
| ) |  |  | `[pure virtual]`

Loads from raw text.

virtual bool iShaderProgram::Load | ( | iShaderDestinationResolver * | resolve,
|  | iDocumentNode * | node |
| ) |  |  | `[pure virtual]`

Loads from a document-node.

virtual void iShaderProgram::ResetState | ( |  | ) | `[pure virtual]`

Reset states to original.

virtual void iShaderProgram::SetupState | ( | const csRenderMesh * | mesh,
|  | csRenderMeshModes & | modes,
|  | const iShaderVarStack * | stacks |
| ) |  |  | `[pure virtual]`

Setup states needed for proper operation of the shaderprogram.

The documentation for this struct was generated from the following file:

- csplugincommon/shader/shaderplugin.h