|
| HlmsDatablock (IdString name, Hlms *creator, const HlmsMacroblock *macroblock, const HlmsBlendblock *blendblock, const HlmsParamVec ¶ms) |
|
virtual | ~HlmsDatablock () |
|
void | _linkRenderable (Renderable *renderable) |
|
void | _unlinkRenderable (Renderable *renderable) |
|
virtual void | calculateHash () |
| Calculates the hashes needed for sorting by the RenderQueue (i.e. mTextureHash)
|
|
HlmsDatablock * | clone (String name) const |
| Creates a copy of this datablock with the same settings, but a different name.
|
|
CompareFunction | getAlphaTest (void) const |
|
bool | getAlphaTestShadowCasterOnly (void) const |
|
float | getAlphaTestThreshold (void) const |
|
const HlmsBlendblock * | getBlendblock (bool casterBlock=false) const |
|
Hlms * | getCreator (void) const |
|
void | getFilenameAndResourceGroup (String const **outFilename, String const **outResourceGroup) const |
|
const vector< Renderable * >::type & | getLinkedRenderables (void) const |
|
const HlmsMacroblock * | getMacroblock (bool casterBlock=false) const |
|
IdString | getName (void) const |
|
const String * | getNameStr (void) const |
|
virtual bool | hasCustomShadowMacroblock (void) const |
|
void | operator delete (void *ptr) |
|
void | operator delete (void *ptr, const char *, int, const char *) |
|
void | operator delete (void *ptr, void *) |
|
void | operator delete[] (void *ptr) |
|
void | operator delete[] (void *ptr, const char *, int, const char *) |
|
void * | operator new (size_t sz) |
|
void * | operator new (size_t sz, const char *file, int line, const char *func) |
| operator new, with debug line info
|
|
void * | operator new (size_t sz, void *ptr) |
| placement operator new
|
|
void * | operator new[] (size_t sz) |
|
void * | operator new[] (size_t sz, const char *file, int line, const char *func) |
| array operator new, with debug line info
|
|
virtual void | saveTextures (const String &folderPath, set< String >::type &savedTextures, bool saveOitd, bool saveOriginal, HlmsTextureExportListener *listener) |
|
virtual void | setAlphaTest (CompareFunction compareFunction, bool shadowCasterOnly=false) |
| Sets the alpha test to the given compare function.
|
|
virtual void | setAlphaTestThreshold (float threshold) |
| Alpha test's threshold.
|
|
void | setBlendblock (const HlmsBlendblock &blendblock, bool casterBlock=false) |
| Sets a new blendblock that matches the same parameter as the input.
|
|
void | setBlendblock (const HlmsBlendblock *blendblock, bool casterBlock=false) |
| Sets the blendblock from the given pointer that was already retrieved from the HlmsManager.
|
|
void | setMacroblock (const HlmsMacroblock ¯oblock, bool casterBlock=false) |
| Sets a new macroblock that matches the same parameter as the input.
|
|
void | setMacroblock (const HlmsMacroblock *macroblock, bool casterBlock=false) |
| Sets the macroblock from the given pointer that was already retrieved from the HlmsManager.
|
|
An hlms datablock contains individual information about a specific material.
It consists of: A const pointer to an @HlmsMacroblock we do not own and may be shared by other datablocks. A const pointer to an @HlmsBlendblock we do not own and may be shared by other datablocks. The original properties from which this datablock was constructed. This type may be derived to contain additional information. Derived types can cache information present in mOriginalProperties as strings, like diffuse colour values, etc.
A datablock is the internal representation of the surface parameters (depth settings, textures to be used, diffuse colour, specular colour, etc). The notion of a datablock is the closest you'll get to a "material"
- If you need to change a macroblock, create a new one (HlmsManager keeps them cached if already created) and change the entire pointer.
- Each datablock has a pair of macroblocks and blendblocks. One of is for the regular passes, the other is for shadow mapping passes, since often you don't want them to be the same. Shadow mapping often wants to reverse culling (
- See also
- HlmsManager::setShadowMappingUseBackFaces) or use some depth bias. As for blendblocks, with transparent objects you may want to turn off alpha blending, but enable alpha testing instead.