A class that contains a set of techniques for drawing the visual appearance of an object.
More...
|
| | Material () |
| | Create a default material with no name and no techniques. More...
|
| |
| | Material (Technique *newTechnique) |
| | Create a material with no name that uses the specified technique. More...
|
| |
| virtual | ~Material () |
| | Destroy this material, releasing all resources. More...
|
| |
| Size | getTechniqueCount () const |
| | Return the total number of material techniques that are part of this material. More...
|
| |
| Technique * | getTechnique (Index index) const |
| | Return a pointer to the material technique at the specified index in this material. More...
|
| |
| void | setTechnique (Index index, Technique *newTechnique) |
| | Set a pointer to the material technique at the specified index in this material. More...
|
| |
| Technique * | getTechniqueForPass (RenderPass::Flag pass) const |
| | Return a technique for this material for the specified render pass. More...
|
| |
| Bool | addTechnique (Technique *newTechnique) |
| | Add a new material technique to this material with the specified usage. More...
|
| |
| Bool | removeTechnique (Index index) |
| | Remove the technique with the specified index from this material. More...
|
| |
| void | clearTechniques () |
| | Remove all material techniques from this material. More...
|
| |
| Size | getConstantCount () const |
| | Return the number of constants that are stored in this material. More...
|
| |
| ConstantSet & | getConstants () |
| | Return the object that contains the constants for this material. More...
|
| |
| const ConstantSet & | getConstants () const |
| | Return the object that contains the constants for this material. More...
|
| |
| const UByte * | getConstantData (Index constantIndex) const |
| | Return a pointer to the storage for the specified constant index. More...
|
| |
| const AttributeType & | getConstantType (Index constantIndex) const |
| | Return the type of the constant at the specified index. More...
|
| |
| template<typename T > |
| const T * | getConstant (ConstantUsage::Enum usage) const |
| | Return a pointer to the storage for the specified constant usage if it is part of this material. More...
|
| |
| template<typename T > |
| const T * | getConstant (const ConstantUsage &usage) const |
| | Return a pointer to the storage for the specified constant usage if it is part of this material. More...
|
| |
| Bool | getConstant (Index constantIndex, AttributeValue &value) const |
| | Get the value for the specified constant index if it is part of this material. More...
|
| |
| Bool | getConstant (ConstantUsage::Enum usage, AttributeValue &value) const |
| | Get the value for the specified constant usage if it is part of this material. More...
|
| |
| Bool | getConstant (const ConstantUsage &usage, AttributeValue &value) const |
| | Get the value for the specified constant usage if it is part of this material. More...
|
| |
| Bool | getConstant (Index constantIndex, const AttributeType &outputType, void *value) const |
| | Get the value for the specified constant index if it is part of this material. More...
|
| |
| Bool | getConstant (ConstantUsage::Enum usage, const AttributeType &outputType, void *value) const |
| | Get the value for the specified constant usage if it is part of this material. More...
|
| |
| Bool | getConstant (const ConstantUsage &usage, const AttributeType &outputType, void *value) const |
| | Get the value for the specified constant usage if it is part of this material. More...
|
| |
| template<typename T > |
| Bool | setConstant (ConstantUsage::Enum usage, const T &value) |
| | Set the value of the stored constant with the given usage. More...
|
| |
| template<typename T > |
| Bool | setConstant (const ConstantUsage &usage, const T &value) |
| | Set the value of the stored constant with the given usage. More...
|
| |
| Bool | setConstant (ConstantUsage::Enum usage, const AttributeValue &value) |
| | Set the value of the stored constant with the given usgae. More...
|
| |
| Bool | setConstant (const ConstantUsage &usage, const AttributeValue &value) |
| | Set the value of the stored constant with the given usgae. More...
|
| |
| const ConstantUsage & | getConstantUsage (Index constantIndex) const |
| | Return the usage of the constant at the specified index in this material. More...
|
| |
| void | setConstantUsage (Index constantIndex, const ConstantUsage &newUsage) |
| | Set the usage of the constant at the specified index in this material. More...
|
| |
| template<typename T > |
| Bool | addConstant (const ConstantUsage &usage, const T &value) |
| | Add a new constant with the specified usage and value to this material. More...
|
| |
| Bool | addConstant (const ConstantUsage &usage, const AttributeValue &value) |
| | Add a new constant with the specified usage and value to this material. More...
|
| |
| Bool | addConstant (const ConstantUsage &usage, const AttributeType &type, const void *value) |
| | Add a new constant with the specified usage and value to this material. More...
|
| |
| void | clearConstants () |
| | Remove all stored constants from this constant set object. More...
|
| |
| Size | getTextureCount () const |
| | Return the number of textures in this material. More...
|
| |
| TextureSet & | getTextures () |
| | Return the object that contains the textures for this material. More...
|
| |
| const TextureSet & | getTextures () const |
| | Return the object that contains the textures for this material. More...
|
| |
| Texture * | getTexture (Index textureIndex) const |
| | Return the texture at the specified index in this material. More...
|
| |
| Bool | setTexture (Index textureIndex, Texture *texture) |
| | Set the texture at the specified index in this material. More...
|
| |
| Texture * | getTexture (TextureUsage::Enum usage) const |
| | Return a pointer to the texture with the specified usage in this material. More...
|
| |
| Texture * | getTexture (const TextureUsage &usage) const |
| | Return a pointer to the texture with the specified usage in this material. More...
|
| |
| Bool | setTexture (TextureUsage::Enum usage, Texture *texture) |
| | Set the texture with the specified usage in this material. More...
|
| |
| Bool | setTexture (const TextureUsage &usage, Texture *texture) |
| | Set the texture with the specified usage in this material. More...
|
| |
| const TextureUsage & | getTextureUsage (Index textureIndex) const |
| | Return the usage type of the texture at the specified index in this material. More...
|
| |
| Bool | setTextureUsage (Index textureIndex, const TextureUsage &newUsage) |
| | Set the usage of the texture at the specified index in this material. More...
|
| |
| Bool | addTexture (const TextureUsage &usage, Texture *texture) |
| | Add a texture with the specified usage to this material. More...
|
| |
| Bool | removeTexture (const Texture *texture) |
| | Remove the first texture with the specified address from this material. More...
|
| |
| Bool | removeTexture (const TextureUsage &usage) |
| | Remove the texture with the specified usage from this material. More...
|
| |
| void | clearTextures () |
| | Clear all textures from this material. More...
|
| |
| virtual void | setContext (devices::GraphicsContext *newContext) |
| | Set a pointer to the graphics context this material and its techniques should use to do rendering. More...
|
| |
| virtual void | upload (UploadRequest &request) |
| | Upload this material and its techniques' current CPU representation to the GPU device. More...
|
| |
| virtual void | download (DownloadRequest &request) |
| | Download the material and its technique' GPU representation to CPU memory. More...
|
| |
| virtual | ~GraphicsContextObject () |
| | Destory this graphics context object. More...
|
| |
| GraphicsContext * | getContext () 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...
|
| |
| virtual Bool | isUploaded () const |
| | Return whether or not this graphics resource has been successfully created and uploaded to the device. More...
|
| |
| virtual Bool | isDownloaded () const |
| | Return whether or not this graphics resource has a copy of its data stored in CPU-side memory. More...
|
| |
| virtual Bool | isValid () const |
| | Return whether or not the state of this graphics resource is valid (either on CPU or GPU) and able to be used for rendering. More...
|
| |
A class that contains a set of techniques for drawing the visual appearance of an object.
Each technique represents a particular way of drawing an object. A material is a set of techniques, where each technique is associated with a usage type. The usage allows the renderer to pick the correct technique to render an object.