11 #ifndef CAFU_MATSYS_MATERIAL_MANAGER_INTERFACE_HPP_INCLUDED
12 #define CAFU_MATSYS_MATERIAL_MANAGER_INTERFACE_HPP_INCLUDED
14 #include "Templates/Array.hpp"
51 virtual const std::map<std::string, MaterialT*>&
GetAllMaterials()
const=0;
56 virtual bool HasMaterial(
const std::string& MaterialName)
const=0;
virtual ArrayT< MaterialT * > RegisterMaterialScript(const std::string &FileName, const std::string &BaseDir)=0
Registers a material script file.
virtual ~MaterialManagerI()
Virtual destructor, so that nothing can go wrong and even g++ is happy.
Definition: MaterialManager.hpp:68
virtual const std::map< std::string, MaterialT * > & GetAllMaterials() const =0
Returns all the materials registered so far.
This class represents a surface material ("A datastructural representation of a scripts material def...
Definition: Material.hpp:22
This is an interface to the material manager.
Definition: MaterialManager.hpp:31
virtual MaterialT * GetMaterial(const std::string &MaterialName) const =0
Returns a material by its name.
virtual bool HasMaterial(const std::string &MaterialName) const =0
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.
virtual ArrayT< MaterialT * > RegisterMaterialScriptsInDir(const std::string &DirName, const std::string &BaseDir, const bool Recurse=true)=0
Registers all ".cmat" files in a directory as material script files.