11 #ifndef CAFU_MATSYS_MATERIAL_MANAGER_IMPLEMENTATION_HPP_INCLUDED
12 #define CAFU_MATSYS_MATERIAL_MANAGER_IMPLEMENTATION_HPP_INCLUDED
14 #include "MaterialManager.hpp"
43 const std::map<std::string, MaterialT*>&
GetAllMaterials()
const {
return Materials; }
44 bool HasMaterial(
const std::string& MaterialName)
const;
56 std::map<std::string, MaterialT*> Materials;
MaterialT * RegisterMaterial(const MaterialT &Mat)
Registers a copy of the given material Mat and returns a pointer to the registered copy...
Definition: MaterialManagerImpl.cpp:152
Definition: Expression.hpp:17
This class represents a surface material ("A datastructural representation of a scripts material def...
Definition: Material.hpp:22
This class implements the MaterialManagerI interface.
Definition: MaterialManagerImpl.hpp:23
ArrayT< MaterialT * > RegisterMaterialScript(const std::string &FileName, const std::string &BaseDir)
Registers a material script file.
Definition: MaterialManagerImpl.cpp:167
This is an interface to the material manager.
Definition: MaterialManager.hpp:31
MaterialT * GetMaterial(const std::string &MaterialName) const
Returns a material by its name.
Definition: MaterialManagerImpl.cpp:346
ArrayT< MaterialT * > RegisterMaterialScriptsInDir(const std::string &DirName, const std::string &BaseDir, const bool Recurse=true)
Registers all ".cmat" files in a directory as material script files.
Definition: MaterialManagerImpl.cpp:248
bool HasMaterial(const std::string &MaterialName) const
Returns whether the material with the given name is registered with the material manager, i.e. if a call to GetMaterial(MaterialName) will return successfully.
Definition: MaterialManagerImpl.cpp:338
const std::map< std::string, MaterialT * > & GetAllMaterials() const
Returns all the materials registered so far.
Definition: MaterialManagerImpl.hpp:43