vtkGLSLShaderProgram Class Reference

#include <vtkGLSLShaderProgram.h>

Inheritance diagram for vtkGLSLShaderProgram:

Inheritance graph
Collaboration diagram for vtkGLSLShaderProgram:

Collaboration graph

List of all members.

Detailed Description

GLSL Shader Program.

vtkGLSLShaderProgram is a concerete implementation of vtkShaderProgram. It's main function is to 'Link' a vertex and a fragment shader together and install them into the rendering pipeline by calling OpenGL2.0.

Initialization of shader parameters is delegated to instances of vtkShader (vtkGLSLShader in this case).

Shader support in VTK includes key contributions by Gary Templet at Sandia National Labs.

Definition at line 47 of file vtkGLSLShaderProgram.h.

Public Types

typedef vtkShaderProgram Superclass

Public Member Functions

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void Render (vtkActor *actor, vtkRenderer *renderer)
virtual void PostRender (vtkActor *, vtkRenderer *)
virtual void ReleaseGraphicsResources (vtkWindow *)
unsigned int GetProgram ()

Static Public Member Functions

static int IsTypeOf (const char *type)
static vtkGLSLShaderProgramSafeDownCast (vtkObject *o)
static vtkGLSLShaderProgramNew ()

Protected Member Functions

 vtkGLSLShaderProgram ()
virtual ~vtkGLSLShaderProgram ()
virtual vtkShaderNewShader ()
virtual void LoadExtensions (vtkRenderWindow *)
int IsProgram ()
int IsLinked ()
int IsAttached (vtkGLSLShader *shader)
virtual void Link ()
virtual void SetInfo (const char *)
virtual char * GetInfo ()
void GetProgramInfo ()
void GetInfoLog ()

Protected Attributes

unsigned int Program
char * Info

Member Typedef Documentation

Reimplemented from vtkShaderProgram.

Definition at line 50 of file vtkGLSLShaderProgram.h.

Constructor & Destructor Documentation

vtkGLSLShaderProgram::vtkGLSLShaderProgram (  )  [protected]

virtual vtkGLSLShaderProgram::~vtkGLSLShaderProgram (  )  [protected, virtual]

Member Function Documentation

virtual const char* vtkGLSLShaderProgram::GetClassName (  )  [virtual]

Reimplemented from vtkShaderProgram.

static int vtkGLSLShaderProgram::IsTypeOf ( const char *  name  )  [static]

Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkShaderProgram.

virtual int vtkGLSLShaderProgram::IsA ( const char *  name  )  [virtual]

Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkShaderProgram.

static vtkGLSLShaderProgram* vtkGLSLShaderProgram::SafeDownCast ( vtkObject o  )  [static]

Reimplemented from vtkShaderProgram.

static vtkGLSLShaderProgram* vtkGLSLShaderProgram::New (  )  [static]

Create an object with Debug turned off, modified time initialized to zero, and reference counting on.

Reimplemented from vtkObject.

void vtkGLSLShaderProgram::PrintSelf ( ostream &  os,
vtkIndent  indent 
) [virtual]

Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkShaderProgram.

virtual void vtkGLSLShaderProgram::Render ( vtkActor actor,
vtkRenderer renderer 
) [virtual]

Implements vtkShaderProgram.

virtual void vtkGLSLShaderProgram::PostRender ( vtkActor ,
) [virtual]

Called to unload the shaders after the actor has been rendered.

Reimplemented from vtkShaderProgram.

virtual void vtkGLSLShaderProgram::ReleaseGraphicsResources ( vtkWindow  )  [virtual]

Release any graphics resources that are being consumed by this actor. The parameter window could be used to determine which graphic resources to release.

Reimplemented from vtkShaderProgram.

unsigned int vtkGLSLShaderProgram::GetProgram (  )  [inline]

Return the OpenGL program id.

Definition at line 71 of file vtkGLSLShaderProgram.h.

virtual vtkShader* vtkGLSLShaderProgram::NewShader (  )  [protected, virtual]

Creates and returns a new vtkGLSLShader.

Implements vtkShaderProgram.

virtual void vtkGLSLShaderProgram::LoadExtensions ( vtkRenderWindow  )  [protected, virtual]

Reimplemented from vtkShaderProgram.

int vtkGLSLShaderProgram::IsProgram (  )  [protected]

int vtkGLSLShaderProgram::IsLinked (  )  [protected]

int vtkGLSLShaderProgram::IsAttached ( vtkGLSLShader shader  )  [protected]

virtual void vtkGLSLShaderProgram::Link (  )  [protected, virtual]

virtual void vtkGLSLShaderProgram::SetInfo ( const char *   )  [protected, virtual]

virtual char* vtkGLSLShaderProgram::GetInfo (  )  [protected, virtual]

void vtkGLSLShaderProgram::GetProgramInfo (  )  [protected]

void vtkGLSLShaderProgram::GetInfoLog (  )  [protected]

Member Data Documentation

unsigned int vtkGLSLShaderProgram::Program [protected]

Definition at line 84 of file vtkGLSLShaderProgram.h.

char* vtkGLSLShaderProgram::Info [protected]

Definition at line 91 of file vtkGLSLShaderProgram.h.

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

Generated on Wed Aug 24 11:38:22 2011 for VTK by  doxygen 1.5.6