Castor3D 0.12.0
Multiplatform 3D engine
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
castor3d::Material Class Reference

#include <Material.hpp>

Inheritance diagram for castor3d::Material:
Inheritance graph
[legend]
Collaboration diagram for castor3d::Material:
Collaboration graph
[legend]

Public Member Functions

C3D_API Material (castor::String const &name, Engine &engine, PassTypeID type)
 Constructor. More...
 
virtual C3D_API ~Material ()
 Destructor. More...
 
C3D_API void initialise ()
 
C3D_API void cleanup ()
 
C3D_API PassSPtr createPass ()
 Creates a pass. More...
 
C3D_API void removePass (PassSPtr pass)
 Removes an external pass to rhe material. More...
 
C3D_API PassSPtr getPass (uint32_t index) const
 Retrieves a pass and returns it. More...
 
C3D_API void destroyPass (uint32_t index)
 Destroys the pass at the given index. More...
 
C3D_API bool hasAlphaBlending () const
 
C3D_API bool hasEnvironmentMapping () const
 
C3D_API bool hasSubsurfaceScattering () const
 
C3D_API bool isTextured (TextureFlags mask=TextureFlag::eAll) const
 
PassTypeID getType () const
 
uint32_t getPassCount () const
 
RenderPassRegisterInfogetRenderPassInfo () const
 
PassPtrArrayConstIt begin () const
 
PassPtrArrayIt begin ()
 
PassPtrArrayConstIt end () const
 
PassPtrArrayIt end ()
 
void setRenderPassInfo (RenderPassRegisterInfo *renderPassInfo)
 

Public Attributes

OnMaterialChanged onChanged
 

Static Public Attributes

static const castor::String DefaultMaterialName
 

Constructor & Destructor Documentation

◆ Material()

C3D_API castor3d::Material::Material ( castor::String const &  name,
Engine engine,
PassTypeID  type 
)

Constructor.

Parameters
[in]nameThe material name.
[in]engineThe core engine.
[in]typeThe material type.

◆ ~Material()

virtual C3D_API castor3d::Material::~Material ( )
virtual

Destructor.

Member Function Documentation

◆ begin() [1/2]

PassPtrArrayIt castor3d::Material::begin ( )
inline

◆ begin() [2/2]

PassPtrArrayConstIt castor3d::Material::begin ( ) const
inline

name Passes iteration.

◆ cleanup()

C3D_API void castor3d::Material::cleanup ( )

◆ createPass()

C3D_API PassSPtr castor3d::Material::createPass ( )

Creates a pass.

Returns
The created pass.

◆ destroyPass()

C3D_API void castor3d::Material::destroyPass ( uint32_t  index)

Destroys the pass at the given index.

Parameters
[in]indexThe pass index.

◆ end() [1/2]

PassPtrArrayIt castor3d::Material::end ( )
inline

◆ end() [2/2]

PassPtrArrayConstIt castor3d::Material::end ( ) const
inline

◆ getPass()

C3D_API PassSPtr castor3d::Material::getPass ( uint32_t  index) const

Retrieves a pass and returns it.

Parameters
[in]indexThe index of the wanted pass.
Returns
The retrieved pass or nullptr if not found.

◆ getPassCount()

uint32_t castor3d::Material::getPassCount ( ) const
inline

◆ getRenderPassInfo()

RenderPassRegisterInfo * castor3d::Material::getRenderPassInfo ( ) const
inline

◆ getType()

PassTypeID castor3d::Material::getType ( ) const
inline

◆ hasAlphaBlending()

C3D_API bool castor3d::Material::hasAlphaBlending ( ) const

name Getters.

◆ hasEnvironmentMapping()

C3D_API bool castor3d::Material::hasEnvironmentMapping ( ) const

◆ hasSubsurfaceScattering()

C3D_API bool castor3d::Material::hasSubsurfaceScattering ( ) const

◆ initialise()

C3D_API void castor3d::Material::initialise ( )

◆ isTextured()

C3D_API bool castor3d::Material::isTextured ( TextureFlags  mask = TextureFlag::eAll) const

◆ removePass()

C3D_API void castor3d::Material::removePass ( PassSPtr  pass)

Removes an external pass to rhe material.

Parameters
[in]passThe pass.

◆ setRenderPassInfo()

void castor3d::Material::setRenderPassInfo ( RenderPassRegisterInfo renderPassInfo)
inline

name Mutators.

Member Data Documentation

◆ DefaultMaterialName

const castor::String castor3d::Material::DefaultMaterialName
static

The default material name.

◆ onChanged

OnMaterialChanged castor3d::Material::onChanged

The signal raised when the material has changed.


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