3#include <Engine/RaEngine.hpp>
8#include <Engine/Data/MaterialTextureSet.hpp>
9#include <Engine/Data/RenderParameters.hpp>
10#include <Engine/Data/Texture.hpp>
11#include <Engine/Data/TextureManager.hpp>
12#include <Engine/RadiumEngine.hpp>
65 virtual bool isTransparent()
const {
return m_aspect == MaterialAspect::MAT_TRANSPARENT; }
79 return ShaderParameterProvider::getPropertyList();
109 MaterialAspect aspect = MaterialAspect::MAT_OPAQUE );
130 MaterialAspect m_aspect { MaterialAspect::MAT_OPAQUE };
133 bool m_isDirty {
true };
Base class for materials.
const std::string & getInstanceName() const
const std::string & getMaterialName() const
virtual ~Material()=default
bool isDirty()
Return dirty state.
virtual void setColoredByVertexAttrib(bool state)
Makes the Material take its base color from the VERTEX_COLOR attribute of the rendered geometry.
std::list< std::string > getPropertyList() const override
Get the list of properties the material migh use in a shader.
void setMaterialName(std::string newName)
Change the material name.
void setDirty()
Set dirty state to true.
void setMaterialAspect(const MaterialAspect &aspect)
void setClean()
Set dirty state to false.
virtual bool isColoredByVertexAttrib() const
Indicates if the material takes the VERTEX_COLOR attribute into account.
void needUpdate()
Mark the Material as needing update before the next OpenGL call.
MaterialAspect
Identifies the type of the material.
virtual bool isTransparent() const
const MaterialAspect & getMaterialAspect() const
Get the aspect (MAT_OPAQUE or MAT_TRANSPARENT) of the material.
Shader program parameter provider.
hepler function to manage enum as underlying types in VariableSet