Class for generating materials for objects to render themselves in the merging step of deferred lighting. More...
#include <MergeMaterialGenerator.hh>
Public Types | |
enum | MaterialPermutations { MP_NO_TEXTURES = 0x00000000, MP_ONE_TEXTURE = 0x00000001, MP_TWO_TEXTURES = 0x00000002, MP_THREE_TEXTURES = 0x00000003, MP_TEXTURE_MASK = 0x0000000F, MP_HAS_DIFFUSE_COLOUR = 0x00000010, MP_NO_TEXCOORDS = 0x00000000, MP_ONE_TEXCOORD = 0x00000100, MP_TWO_TEXCOORDS = 0x00000200, MP_TEXCOORD_MASK = 0x00000700, MP_NORMAL_MAP = 0x00000800, MP_SKINNED = 0x00010000 } |
The relevant options for materials. More... | |
Public Types inherited from gazebo::rendering::MaterialGenerator | |
typedef uint32_t | Perm |
Bitfield used to signify a material permutations. More... | |
Public Member Functions | |
MergeMaterialGenerator (Ogre::String _matName, bool _useDSF) | |
Public Member Functions inherited from gazebo::rendering::MaterialGenerator | |
virtual | ~MaterialGenerator () |
const Ogre::MaterialPtr & | GetMaterial (Perm permutation) |
Static Public Attributes | |
static const uint32_t | FS_MASK = 0x0000FFFF |
The mask of the flags that matter for generating the fragment shader. More... | |
static const uint32_t | MAT_MASK = 0xFF00FFFF |
The mask of the flags that matter for generating the material. More... | |
static const uint32_t | VS_MASK = 0x00FFFF00 |
The mask of the flags that matter for generating the vertex shader. More... | |
Additional Inherited Members | |
Protected Types inherited from gazebo::rendering::MaterialGenerator | |
typedef std::map< Perm, Ogre::MaterialPtr > | MaterialMap |
typedef std::map< Perm, Ogre::GpuProgramPtr > | ProgramMap |
Protected Member Functions inherited from gazebo::rendering::MaterialGenerator | |
MaterialGenerator () | |
constructor is protected as this base class should never be constructed as-is. More... | |
const Ogre::GpuProgramPtr & | GetFragmentShader (Perm _perm) |
const Ogre::MaterialPtr & | GetTemplateMaterial (Perm _perm) |
const Ogre::GpuProgramPtr & | GetVertexShader (Perm _perm) |
Protected Attributes inherited from gazebo::rendering::MaterialGenerator | |
ProgramMap | fs |
Perm | fsMask |
Mask of permutation bits that influence fragment shader choice. More... | |
Impl * | impl |
Generator. More... | |
Ogre::String | materialBaseName |
Base name of materials generated by this. More... | |
MaterialMap | materials |
Perm | matMask |
Mask of permutation bits that influence template material choice. More... | |
std::string | schemeName |
MaterialMap | templateMat |
ProgramMap | vs |
Perm | vsMask |
Mask of permutation bits that influence vertex shader choice. More... | |
Class for generating materials for objects to render themselves in the merging step of deferred lighting.
This stage takes the LBuffer as an input and performs an extra geometry pass. It uses the material info from the geometry pass, and the light info from the LBuffer to recreate the Blinn-Phong lighting model. Alternatively, different lighting models can be recreated(like adding a fresnel term during merging).
gazebo::rendering::MergeMaterialGenerator::MergeMaterialGenerator | ( | Ogre::String | _matName, |
bool | _useDSF | ||
) |
|
static |
The mask of the flags that matter for generating the fragment shader.
|
static |
The mask of the flags that matter for generating the material.
|
static |
The mask of the flags that matter for generating the vertex shader.