Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

SH::ShProgram Class Reference

Thin wrapper around ShProgramNode. More...

#include <ShProgram.hpp>

Collaboration diagram for SH::ShProgram:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ShProgram (const ShProgram &other)
 ShProgram (const std::string &target)
 ShProgram (const ShProgramNodePtr &node)
ShProgramoperator= (const ShProgram &other)
ShProgramNodeCPtr node () const
 Obtain the node which this ShProgram wraps.
ShProgramNodePtr node ()
 Obtain the node which this ShProgram wraps.
void compile (const ShPointer< ShBackend > &backend)
 Forcefully compile this program for a particular backend, even if it has been compiled previously.
void compile (const std::string &target, const ShPointer< ShBackend > &backend)
 Forcefully compile this program for a particular backend, even if it has been compiled previously.
std::string describe_interface () const
 Obtain a listing of the inputs, outputs and uniforms used by this program.
ShPointer< ShBackendCode > code ()
 Obtain the code for currently active backend.
ShPointer< ShBackendCode > code (const ShPointer< ShBackend > &backend)
 Obtain the code for a particular backend.
ShPointer< ShBackendCode > code (const std::string &target, const ShPointer< ShBackend > &backend)
 Obtain the code for a particular backend. Generates it if necessary.
void updateUniform (const ShVariableNodePtr &uniform)
 Notify this program that a uniform variable has changed.
std::string target () const
std::string & target ()
 It may be useful to change a program's target sometimes.
ShProgramNode::VarList::const_iterator inputs_begin () const
ShProgramNode::VarList::const_iterator inputs_end () const
ShProgramNode::VarList::const_iterator outputs_begin () const
ShProgramNode::VarList::const_iterator outputs_end () const
ShProgramNode::VarList::const_iterator temps_begin () const
ShProgramNode::VarList::const_iterator temps_end () const
ShProgramNode::VarList::const_iterator constants_begin () const
ShProgramNode::VarList::const_iterator constants_end () const
ShProgramNode::VarList::const_iterator uniforms_begin () const
ShProgramNode::VarList::const_iterator uniforms_end () const
ShProgramNode::TexList::const_iterator textures_begin () const
ShProgramNode::TexList::const_iterator textures_end () const
ShProgramNode::ChannelList::const_iterator channels_begin () const
ShProgramNode::ChannelList::const_iterator channels_end () const
ShProgramNode::PaletteList::const_iterator palettes_begin () const
ShProgramNode::PaletteList::const_iterator palettes_end () const
template<typename T0>
ShProgram operator() (const ShChannel< T0 > &t0) const
ShProgram operator() (const ShStream &s0) const
template<typename T0, typename T1>
ShProgram operator() (const ShChannel< T0 > &t0, const ShChannel< T1 > &t1) const
ShProgram operator() (const ShStream &s0, const ShStream &s1) const
template<typename T0, typename T1, typename T2>
ShProgram operator() (const ShChannel< T0 > &t0, const ShChannel< T1 > &t1, const ShChannel< T2 > &t2) const
ShProgram operator() (const ShStream &s0, const ShStream &s1, const ShStream &s2) const
template<typename T0, typename T1, typename T2, typename T3>
ShProgram operator() (const ShChannel< T0 > &t0, const ShChannel< T1 > &t1, const ShChannel< T2 > &t2, const ShChannel< T3 > &t3) const
ShProgram operator() (const ShStream &s0, const ShStream &s1, const ShStream &s2, const ShStream &s3) const
template<typename T0, typename T1, typename T2, typename T3, typename T4>
ShProgram operator() (const ShChannel< T0 > &t0, const ShChannel< T1 > &t1, const ShChannel< T2 > &t2, const ShChannel< T3 > &t3, const ShChannel< T4 > &t4) const
ShProgram operator() (const ShStream &s0, const ShStream &s1, const ShStream &s2, const ShStream &s3, const ShStream &s4) const
ShProgram operator() (const ShRecord &rec) const
ShProgram operator() (const ShVariable &v0) const
ShProgram operator() (const ShVariable &v0, const ShVariable &v1) const
ShProgram operator() (const ShVariable &v0, const ShVariable &v1, const ShVariable &v2) const
ShProgram operator() (const ShVariable &v0, const ShVariable &v1, const ShVariable &v2, const ShVariable &v3) const

Detailed Description

Thin wrapper around ShProgramNode.

Definition at line 39 of file ShProgram.hpp.


Member Function Documentation

ShPointer<ShBackendCode> SH::ShProgram::code const ShPointer< ShBackend > &  backend  )  [inline]
 

Obtain the code for a particular backend.

Generates it if necessary. This operation will fail if this program does not have a particular target.

Definition at line 84 of file ShProgram.hpp.

ShPointer<ShBackendCode> SH::ShProgram::code  )  [inline]
 

Obtain the code for currently active backend.

This operation will fail if this program does not have a particular target.

Definition at line 79 of file ShProgram.hpp.

Referenced by SH::shBind(), and SH::shUnbind().

void SH::ShProgram::compile const std::string &  target,
const ShPointer< ShBackend > &  backend
[inline]
 

Forcefully compile this program for a particular backend, even if it has been compiled previously.

Use code() to obtain the actual code.

Definition at line 64 of file ShProgram.hpp.

void SH::ShProgram::compile const ShPointer< ShBackend > &  backend  )  [inline]
 

Forcefully compile this program for a particular backend, even if it has been compiled previously.

Use code() to obtain the actual code. This operation will fail if this program does not have a particular target.

Definition at line 60 of file ShProgram.hpp.

Referenced by SH::shCompile().


The documentation for this class was generated from the following files:
Generated on Thu Apr 21 17:35:18 2005 for Sh by  doxygen 1.4.2