Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | Static Public Attributes | List of all members
om::graphics::materials::Technique Class Reference

A class that represents a kind of visual effect that uses an ordered series of techniquees. More...

#include <omGraphicsTechnique.h>

Inheritance diagram for om::graphics::materials::Technique:
om::graphics::devices::GraphicsContextObject

Public Member Functions

 Technique ()
 Create a new material technique with no techniquees. More...
 
 Technique (const TechniqueUsage &newUsage)
 Create a new material technique with no techniquees or name and the specified usage. More...
 
const TechniqueUsagegetUsage () const
 Return an enum value indicating the semantic usage of this material technique. More...
 
void setUsage (const TechniqueUsage &newUsage)
 Set an enum value indicating the semantic usage of this material technique. More...
 
RenderPassgetPasses ()
 Return a flags object indicating the rendering passes this technique can be used for. More...
 
const RenderPassgetPasses () const
 Return a flags object indicating the rendering passes this technique can be used for. More...
 
void setPasses (const RenderPass &newRenderPasses)
 Set a flags object indicating the rendering passes this technique can be used for. More...
 
ShaderProgramgetProgram () const
 Return a pointer to the shader program that should be used to render this technique. More...
 
void setProgram (ShaderProgram *newProgram)
 Return a pointer to the shader program that should be used to render this technique. More...
 
ShaderConfigurationgetConfiguration ()
 Return a reference to the object that stores the compile-time configuration of this technique. More...
 
const ShaderConfigurationgetConfiguration () const
 Return a const reference to the object that stores the compile-time configuration of this technique. More...
 
void setConfiguration (const ShaderConfiguration &newConfiguration)
 Set the object that stores the compile-time configuration of this technique. More...
 
RenderModegetRenderMode ()
 Return the current render mode for this technique. More...
 
const RenderModegetRenderMode () const
 Return the current render mode for this technique. More...
 
void setRenderMode (const RenderMode &newRenderMode)
 Set the current render mode for this technique. More...
 
const ShaderBindingSetgetBindings () const
 Return a reference to the object that stores the renderable bindings for this technique. More...
 
Size getConstantCount () const
 Return the number of constant bindings associated with this technique. More...
 
const ConstantBindinggetConstantBinding (Index constantIndex) const
 Return a reference to the ConstantBinding at the specified index in this technique. More...
 
Bool getConstantIndex (const ShaderSourceString &constantName, Index &constantIndex) const
 Get the index of the binding for the constant variable with the specified name. More...
 
Bool getConstantIndex (const ConstantUsage &usage, Index &constantIndex) const
 Get the index of the first constant binding in the binding set that has the specified constant usage. More...
 
Bool getConstant (Index constantIndex, AttributeValue &value, Index arrayIndex=Index(0)) const
 Get the constant value for this technique at the specified index and array index. More...
 
Bool setConstant (Index constantIndex, const AttributeValue &value, Index arrayIndex=Index(0))
 Set the constant value for this technique at the specified index and array index, replacing any previous value. More...
 
Bool getConstant (ConstantUsage::Enum usage, AttributeValue &value, Index arrayIndex=Index(0)) const
 Get the constant value for this shader binding set with the given usage and array index. More...
 
Bool setConstant (ConstantUsage::Enum usage, const AttributeValue &value, Index arrayIndex=Index(0))
 Set the constant value for this shader binding set with the given usage and array index, replacing any previous value. More...
 
Bool getConstant (const ConstantUsage &usage, AttributeValue &value, Index arrayIndex=Index(0)) const
 Get the constant value for this shader binding set with the given usage and array index. More...
 
Bool setConstant (const ConstantUsage &usage, const AttributeValue &value, Index arrayIndex=Index(0))
 Set the constant value for this shader binding set with the given usage and array index, replacing any previous value. More...
 
ConstantUsage getConstantUsage (Index constantIndex) const
 Return an object indicating the usage of the constant in this technique at the given index. More...
 
Bool setConstantUsage (Index constantIndex, const ConstantUsage &newUsage)
 Set the usage of the constant in this technique at the given index. More...
 
ShaderBindingFlags getConstantFlags (Index constantIndex) const
 Return an object indicating the flags of the constant in this technique at the given index. More...
 
Bool setConstantFlags (Index constantIndex, const ShaderBindingFlags &newFlags)
 Set the flags of the constant in this technique at the given index. More...
 
Size getTextureCount () const
 Get the number of texture bindings associated with this technique. More...
 
const TextureBindinggetTextureBinding (Index textureIndex) const
 Return a reference to the TextureBinding at the specified index in this shader pas. More...
 
Bool getTextureIndex (const ShaderSourceString &variableName, Index &textureIndex) const
 Get the index of the binding for the texture variable with the specified name. More...
 
Bool getTextureIndex (TextureUsage::Enum usage, Index &textureIndex) const
 Get the index of the first texture binding in the binding set that has the specified texture usage. More...
 
Bool getTextureIndex (const TextureUsage &usage, Index &textureIndex) const
 Get the index of the first texture binding in the binding set that has the specified texture usage. More...
 
TexturegetTexture (Index textureIndex, Index arrayIndex=Index(0)) const
 Get the texture in this technique at the specified binding and array index. More...
 
Bool setTexture (Index textureIndex, Texture *texture, Index arrayIndex=Index(0))
 Set the texture in this technique at the specified binding and array index, replacing any previous texture. More...
 
TexturegetTexture (TextureUsage::Enum usage, Index arrayIndex=Index(0)) const
 Get the texture for this shader binding set with the given usage and array index. More...
 
Bool setTexture (TextureUsage::Enum usage, Texture *texture, Index arrayIndex=Index(0))
 Set the texture for this shader binding set with the given usage and array index, replacing any previous texture. More...
 
TexturegetTexture (const TextureUsage &usage, Index arrayIndex=Index(0)) const
 Get the texture for this shader binding set with the given usage and array index. More...
 
Bool setTexture (const TextureUsage &usage, Texture *texture, Index arrayIndex=Index(0))
 Set the texture for this shader binding set with the given usage and array index, replacing any previous texture. More...
 
TextureUsage getTextureUsage (Index textureIndex) const
 Return an object indicating the usage of the texture in this technique at the given index. More...
 
Bool setTextureUsage (Index textureIndex, const TextureUsage &newUsage)
 Set the usage of the texture in this technique at the given index. More...
 
ShaderBindingFlags getTextureFlags (Index textureIndex) const
 Return an object indicating the flags of the texture in this technique at the given index. More...
 
Bool setTextureFlags (Index textureIndex, const ShaderBindingFlags &newFlags)
 Set the flags of the texture in this technique at the given index. More...
 
Size getVertexBufferCount () const
 Get the number of vertex bindings associated with this technique. More...
 
const VertexBindinggetVertexBinding (Index bindingIndex) const
 Return a reference to the VertexBinding at the specified index in this shader pas. More...
 
Bool getVertexBufferIndex (const ShaderSourceString &variableName, Index &bindingIndex) const
 Get the index of the binding for the vertex variable with the specified name. More...
 
Bool getVertexBufferIndex (VertexUsage::Enum usage, Index &bindingIndex) const
 Get the index of the first vertex binding in the binding set that has the specified vertex usage. More...
 
Bool getVertexBufferIndex (const VertexUsage &usage, Index &bindingIndex) const
 Get the index of the first vertex binding in the binding set that has the specified vertex usage. More...
 
VertexBuffergetVertexBuffer (Index bindingIndex, Index arrayIndex=Index(0)) const
 Get the vertex buffer in this technique at the specified binding and array index. More...
 
Bool setVertexBuffer (Index bindingIndex, VertexBuffer *buffer, Index arrayIndex=Index(0))
 Set the vertex buffer in this technique at the specified binding and array index, replacing any previous buffer. More...
 
VertexBuffergetVertexBuffer (VertexUsage::Enum usage, Index arrayIndex=Index(0)) const
 Get the vertex buffer for this shader binding set with the given usage and array index. More...
 
Bool setVertexBuffer (VertexUsage::Enum usage, VertexBuffer *buffer, Index arrayIndex=Index(0))
 Set the vertex buffer for this shader binding set with the given usage and array index, replacing any previous buffer. More...
 
VertexBuffergetVertexBuffer (const VertexUsage &usage, Index arrayIndex=Index(0)) const
 Get the vertex buffer for this shader binding set with the given usage and array index. More...
 
Bool setVertexBuffer (const VertexUsage &usage, VertexBuffer *buffer, Index arrayIndex=Index(0))
 Set the vertex buffer for this shader binding set with the given usage and array index, replacing any previous buffer. More...
 
VertexUsage getVertexBufferUsage (Index bindingIndex) const
 Return an object indicating the usage of the vertex buffer in this technique at the given index. More...
 
Bool setVertexBufferUsage (Index bindingIndex, const VertexUsage &newUsage)
 Set the usage of the vertex buffer in this technique at the given index. More...
 
ShaderBindingFlags getVertexBufferFlags (Index textureIndex) const
 Return an object indicating the flags of the vertex binding in this technique at the given index. More...
 
Bool setVertexBufferFlags (Index textureIndex, const ShaderBindingFlags &newFlags)
 Set the flags of the vertex binding in this technique at the given index. More...
 
Bool isTransparent () const
 Return whether or not this technique produces pixels that are transparent. More...
 
virtual void setContext (devices::GraphicsContext *newContext)
 Prepare this technique and its techniquees for rendering with the specified context. More...
 
virtual void upload (UploadRequest &request)
 Upload this technique and its shaders' current CPU representation to the GPU device. More...
 
virtual void download (DownloadRequest &request)
 Download the technique and its shaders' GPU representation to CPU memory. More...
 
virtual Bool isUploaded () const
 Return whether or not this technique has been successfully created and uploaded to the device. More...
 
virtual Bool isDownloaded () const
 Return whether or not this technique has a copy of its data stored in CPU-side memory. More...
 
virtual Bool isValid () const
 Return whether or not the state of this technique is valid (either on CPU or GPU) and able to be used for rendering. More...
 
const DeviceShaderProgramgetRenderable () const
 Return a pointer to the context-renderable shader program for this technique, or NULL if there is none. More...
 
- Public Member Functions inherited from om::graphics::devices::GraphicsContextObject
virtual ~GraphicsContextObject ()
 Destory this graphics context object. More...
 
GraphicsContextgetContext () const
 Return a pointer to the graphics context this context object is using to do rendering. More...
 
void clearContext ()
 Clear the previous context from this object. More...
 
void upload ()
 Upload this resource's CPU representation to the GPU device. More...
 
void download ()
 Upload this resource's CPU representation to the GPU device. More...
 

Static Public Attributes

static const ResourceType RESOURCE_TYPE
 The resource type for a graphics technique. More...
 

Additional Inherited Members

- Protected Member Functions inherited from om::graphics::devices::GraphicsContextObject
 GraphicsContextObject ()
 Create a new graphics context object that doesn't have an associated graphics context. More...
 
 GraphicsContextObject (GraphicsContext *newContext)
 Create a new graphics context object that uses the specified context for rendering. More...
 
- Protected Attributes inherited from om::graphics::devices::GraphicsContextObject
GraphicsContextcontext
 A pointer to the graphics context this object is using. More...
 

Detailed Description

A class that represents a kind of visual effect that uses an ordered series of techniquees.

A material technique contains an ordered list of techniquees which indicate the different passes that are part of rendering a particular visual effect. These passes are performed in series during rendering in the order stored in the technique.

A material technique may be simply a different visual style (shiny or not shiny) or a totally different rendering technique (standard versus shadow map rendering).

Constructor & Destructor Documentation

om::graphics::materials::Technique::Technique ( )

Create a new material technique with no techniquees.

om::graphics::materials::Technique::Technique ( const TechniqueUsage newUsage)

Create a new material technique with no techniquees or name and the specified usage.

Member Function Documentation

const TechniqueUsage& om::graphics::materials::Technique::getUsage ( ) const
inline

Return an enum value indicating the semantic usage of this material technique.

void om::graphics::materials::Technique::setUsage ( const TechniqueUsage newUsage)
inline

Set an enum value indicating the semantic usage of this material technique.

RenderPass& om::graphics::materials::Technique::getPasses ( )
inline

Return a flags object indicating the rendering passes this technique can be used for.

const RenderPass& om::graphics::materials::Technique::getPasses ( ) const
inline

Return a flags object indicating the rendering passes this technique can be used for.

void om::graphics::materials::Technique::setPasses ( const RenderPass newRenderPasses)
inline

Set a flags object indicating the rendering passes this technique can be used for.

ShaderProgram* om::graphics::materials::Technique::getProgram ( ) const
inline

Return a pointer to the shader program that should be used to render this technique.

void om::graphics::materials::Technique::setProgram ( ShaderProgram newProgram)
inline

Return a pointer to the shader program that should be used to render this technique.

ShaderConfiguration& om::graphics::materials::Technique::getConfiguration ( )
inline

Return a reference to the object that stores the compile-time configuration of this technique.

const ShaderConfiguration& om::graphics::materials::Technique::getConfiguration ( ) const
inline

Return a const reference to the object that stores the compile-time configuration of this technique.

void om::graphics::materials::Technique::setConfiguration ( const ShaderConfiguration newConfiguration)
inline

Set the object that stores the compile-time configuration of this technique.

RenderMode& om::graphics::materials::Technique::getRenderMode ( )
inline

Return the current render mode for this technique.

const RenderMode& om::graphics::materials::Technique::getRenderMode ( ) const
inline

Return the current render mode for this technique.

void om::graphics::materials::Technique::setRenderMode ( const RenderMode newRenderMode)
inline

Set the current render mode for this technique.

const ShaderBindingSet& om::graphics::materials::Technique::getBindings ( ) const
inline

Return a reference to the object that stores the renderable bindings for this technique.

The bindings in this set correspond directly to the variables that are in the current device shader program for this technique. If there is no valid shader program, the binding set will be empty.

Size om::graphics::materials::Technique::getConstantCount ( ) const
inline

Return the number of constant bindings associated with this technique.

const ConstantBinding& om::graphics::materials::Technique::getConstantBinding ( Index  constantIndex) const
inline

Return a reference to the ConstantBinding at the specified index in this technique.

Binding indices range from 0 to the number of bindings minus one.

Bool om::graphics::materials::Technique::getConstantIndex ( const ShaderSourceString constantName,
Index constantIndex 
) const
inline

Get the index of the binding for the constant variable with the specified name.

This method finds the binding with the specified name and places its index in the output reference parameter if the binding was found.

The method returns whether or not there was a binding for a constant with that name.

Bool om::graphics::materials::Technique::getConstantIndex ( const ConstantUsage usage,
Index constantIndex 
) const
inline

Get the index of the first constant binding in the binding set that has the specified constant usage.

Bool om::graphics::materials::Technique::getConstant ( Index  constantIndex,
AttributeValue value,
Index  arrayIndex = Index(0) 
) const
inline

Get the constant value for this technique at the specified index and array index.

The method returns whether or not the constant at that index and array index was able to be accessed. The constant value is stored in the output value parameter.

Bool om::graphics::materials::Technique::setConstant ( Index  constantIndex,
const AttributeValue value,
Index  arrayIndex = Index(0) 
)
inline

Set the constant value for this technique at the specified index and array index, replacing any previous value.

The method returns whether or not the constant at that index and array index was able to be changed.

Bool om::graphics::materials::Technique::getConstant ( ConstantUsage::Enum  usage,
AttributeValue value,
Index  arrayIndex = Index(0) 
) const
inline

Get the constant value for this shader binding set with the given usage and array index.

The method returns whether or not the constant with that usage and array index was able to be accessed. The constant value is stored in the output value parameter.

Bool om::graphics::materials::Technique::setConstant ( ConstantUsage::Enum  usage,
const AttributeValue value,
Index  arrayIndex = Index(0) 
)
inline

Set the constant value for this shader binding set with the given usage and array index, replacing any previous value.

The method returns whether or not the constant with that usage and array index was able to be changed.

Bool om::graphics::materials::Technique::getConstant ( const ConstantUsage usage,
AttributeValue value,
Index  arrayIndex = Index(0) 
) const
inline

Get the constant value for this shader binding set with the given usage and array index.

The method returns whether or not the constant with that usage and array index was able to be accessed. The constant value is stored in the output value parameter.

Bool om::graphics::materials::Technique::setConstant ( const ConstantUsage usage,
const AttributeValue value,
Index  arrayIndex = Index(0) 
)
inline

Set the constant value for this shader binding set with the given usage and array index, replacing any previous value.

The method returns whether or not the constant with that usage and array index was able to be changed.

ConstantUsage om::graphics::materials::Technique::getConstantUsage ( Index  constantIndex) const
inline

Return an object indicating the usage of the constant in this technique at the given index.

Bool om::graphics::materials::Technique::setConstantUsage ( Index  constantIndex,
const ConstantUsage newUsage 
)
inline

Set the usage of the constant in this technique at the given index.

The method returns whether or not the constant's usage was able to be modified.

ShaderBindingFlags om::graphics::materials::Technique::getConstantFlags ( Index  constantIndex) const
inline

Return an object indicating the flags of the constant in this technique at the given index.

Bool om::graphics::materials::Technique::setConstantFlags ( Index  constantIndex,
const ShaderBindingFlags newFlags 
)
inline

Set the flags of the constant in this technique at the given index.

The method returns whether or not the constant's flags were able to be modified.

Size om::graphics::materials::Technique::getTextureCount ( ) const
inline

Get the number of texture bindings associated with this technique.

const TextureBinding& om::graphics::materials::Technique::getTextureBinding ( Index  textureIndex) const
inline

Return a reference to the TextureBinding at the specified index in this shader pas.

Binding indices range from 0 to the number of bindings minus one.

Bool om::graphics::materials::Technique::getTextureIndex ( const ShaderSourceString variableName,
Index textureIndex 
) const
inline

Get the index of the binding for the texture variable with the specified name.

This method finds the binding with the specified name and places its index in the output reference parameter if the binding was found.

The method returns whether or not there was a binding for a texture with that name.

Bool om::graphics::materials::Technique::getTextureIndex ( TextureUsage::Enum  usage,
Index textureIndex 
) const
inline

Get the index of the first texture binding in the binding set that has the specified texture usage.

Bool om::graphics::materials::Technique::getTextureIndex ( const TextureUsage usage,
Index textureIndex 
) const
inline

Get the index of the first texture binding in the binding set that has the specified texture usage.

Texture* om::graphics::materials::Technique::getTexture ( Index  textureIndex,
Index  arrayIndex = Index(0) 
) const
inline

Get the texture in this technique at the specified binding and array index.

Bool om::graphics::materials::Technique::setTexture ( Index  textureIndex,
Texture texture,
Index  arrayIndex = Index(0) 
)
inline

Set the texture in this technique at the specified binding and array index, replacing any previous texture.

Texture* om::graphics::materials::Technique::getTexture ( TextureUsage::Enum  usage,
Index  arrayIndex = Index(0) 
) const
inline

Get the texture for this shader binding set with the given usage and array index.

Bool om::graphics::materials::Technique::setTexture ( TextureUsage::Enum  usage,
Texture texture,
Index  arrayIndex = Index(0) 
)
inline

Set the texture for this shader binding set with the given usage and array index, replacing any previous texture.

Texture* om::graphics::materials::Technique::getTexture ( const TextureUsage usage,
Index  arrayIndex = Index(0) 
) const
inline

Get the texture for this shader binding set with the given usage and array index.

Bool om::graphics::materials::Technique::setTexture ( const TextureUsage usage,
Texture texture,
Index  arrayIndex = Index(0) 
)
inline

Set the texture for this shader binding set with the given usage and array index, replacing any previous texture.

TextureUsage om::graphics::materials::Technique::getTextureUsage ( Index  textureIndex) const
inline

Return an object indicating the usage of the texture in this technique at the given index.

Bool om::graphics::materials::Technique::setTextureUsage ( Index  textureIndex,
const TextureUsage newUsage 
)
inline

Set the usage of the texture in this technique at the given index.

The method returns whether or not the texture's usage was able to be modified.

ShaderBindingFlags om::graphics::materials::Technique::getTextureFlags ( Index  textureIndex) const
inline

Return an object indicating the flags of the texture in this technique at the given index.

Bool om::graphics::materials::Technique::setTextureFlags ( Index  textureIndex,
const ShaderBindingFlags newFlags 
)
inline

Set the flags of the texture in this technique at the given index.

The method returns whether or not the texture's flags were able to be modified.

Size om::graphics::materials::Technique::getVertexBufferCount ( ) const
inline

Get the number of vertex bindings associated with this technique.

const VertexBinding& om::graphics::materials::Technique::getVertexBinding ( Index  bindingIndex) const
inline

Return a reference to the VertexBinding at the specified index in this shader pas.

Binding indices range from 0 to the number of bindings minus one.

Bool om::graphics::materials::Technique::getVertexBufferIndex ( const ShaderSourceString variableName,
Index bindingIndex 
) const
inline

Get the index of the binding for the vertex variable with the specified name.

This method finds the binding with the specified name and places its index in the output reference parameter if the binding was found.

The method returns whether or not there was a binding for a vertex buffer with that name.

Bool om::graphics::materials::Technique::getVertexBufferIndex ( VertexUsage::Enum  usage,
Index bindingIndex 
) const
inline

Get the index of the first vertex binding in the binding set that has the specified vertex usage.

Bool om::graphics::materials::Technique::getVertexBufferIndex ( const VertexUsage usage,
Index bindingIndex 
) const
inline

Get the index of the first vertex binding in the binding set that has the specified vertex usage.

VertexBuffer* om::graphics::materials::Technique::getVertexBuffer ( Index  bindingIndex,
Index  arrayIndex = Index(0) 
) const
inline

Get the vertex buffer in this technique at the specified binding and array index.

Bool om::graphics::materials::Technique::setVertexBuffer ( Index  bindingIndex,
VertexBuffer buffer,
Index  arrayIndex = Index(0) 
)
inline

Set the vertex buffer in this technique at the specified binding and array index, replacing any previous buffer.

The method returns whether or not the vertex buffer at that index and array index was able to be changed.

VertexBuffer* om::graphics::materials::Technique::getVertexBuffer ( VertexUsage::Enum  usage,
Index  arrayIndex = Index(0) 
) const
inline

Get the vertex buffer for this shader binding set with the given usage and array index.

Bool om::graphics::materials::Technique::setVertexBuffer ( VertexUsage::Enum  usage,
VertexBuffer buffer,
Index  arrayIndex = Index(0) 
)
inline

Set the vertex buffer for this shader binding set with the given usage and array index, replacing any previous buffer.

The method returns whether or not the vertex buffer with that usage and array index was able to be changed.

VertexBuffer* om::graphics::materials::Technique::getVertexBuffer ( const VertexUsage usage,
Index  arrayIndex = Index(0) 
) const
inline

Get the vertex buffer for this shader binding set with the given usage and array index.

Bool om::graphics::materials::Technique::setVertexBuffer ( const VertexUsage usage,
VertexBuffer buffer,
Index  arrayIndex = Index(0) 
)
inline

Set the vertex buffer for this shader binding set with the given usage and array index, replacing any previous buffer.

The method returns whether or not the vertex buffer with that usage and array index was able to be changed.

VertexUsage om::graphics::materials::Technique::getVertexBufferUsage ( Index  bindingIndex) const
inline

Return an object indicating the usage of the vertex buffer in this technique at the given index.

Bool om::graphics::materials::Technique::setVertexBufferUsage ( Index  bindingIndex,
const VertexUsage newUsage 
)
inline

Set the usage of the vertex buffer in this technique at the given index.

The method returns whether or not the vertex buffer's usage was able to be modified.

ShaderBindingFlags om::graphics::materials::Technique::getVertexBufferFlags ( Index  textureIndex) const
inline

Return an object indicating the flags of the vertex binding in this technique at the given index.

Bool om::graphics::materials::Technique::setVertexBufferFlags ( Index  textureIndex,
const ShaderBindingFlags newFlags 
)
inline

Set the flags of the vertex binding in this technique at the given index.

The method returns whether or not the vertex binding's flags were able to be modified.

Bool om::graphics::materials::Technique::isTransparent ( ) const
inline

Return whether or not this technique produces pixels that are transparent.

A technique is deemed to be transparent if blending and transparency depth sorting is enabled by the technique's render mode.

virtual void om::graphics::materials::Technique::setContext ( devices::GraphicsContext newContext)
virtual

Prepare this technique and its techniquees for rendering with the specified context.

The method propagates the context to the technique's techniquees and regenerates any context-specific data for the new context if the upload flag is TRUE. The method returns whether or not the context can be successfully used for rendering this material technique.

Reimplemented from om::graphics::devices::GraphicsContextObject.

virtual void om::graphics::materials::Technique::upload ( UploadRequest request)
virtual

Upload this technique and its shaders' current CPU representation to the GPU device.

Reimplemented from om::graphics::devices::GraphicsContextObject.

virtual void om::graphics::materials::Technique::download ( DownloadRequest request)
virtual

Download the technique and its shaders' GPU representation to CPU memory.

Reimplemented from om::graphics::devices::GraphicsContextObject.

virtual Bool om::graphics::materials::Technique::isUploaded ( ) const
virtual

Return whether or not this technique has been successfully created and uploaded to the device.

Reimplemented from om::graphics::devices::GraphicsContextObject.

virtual Bool om::graphics::materials::Technique::isDownloaded ( ) const
virtual

Return whether or not this technique has a copy of its data stored in CPU-side memory.

Reimplemented from om::graphics::devices::GraphicsContextObject.

virtual Bool om::graphics::materials::Technique::isValid ( ) const
virtual

Return whether or not the state of this technique is valid (either on CPU or GPU) and able to be used for rendering.

Reimplemented from om::graphics::devices::GraphicsContextObject.

const DeviceShaderProgram* om::graphics::materials::Technique::getRenderable ( ) const
inline

Return a pointer to the context-renderable shader program for this technique, or NULL if there is none.

If the technique has a valid context and the shader program has been compiled successfully, the method returns a pointer to the GPU shader program instance for this technique object.

Otherwise, the technique is not renderable and NULL is returned.

Member Data Documentation

const ResourceType om::graphics::materials::Technique::RESOURCE_TYPE
static

The resource type for a graphics technique.


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