CG-Project2
Loading...
Searching...
No Matches
MaterialComponent Class Reference

Component to store the mesh Material data. More...

#include <Component.hpp>

Inheritance diagram for MaterialComponent:
Collaboration diagram for MaterialComponent:

Public Member Functions

 MaterialComponent (const Material &material=material::defaultMaterials[0])
 Instances a Component with the given material.
 MaterialComponent (const material::MaterialType &type)
 Instances a Component by using the given material type to retrieve the Material object.

Public Attributes

Material material
 mesh material

Detailed Description

Constructor & Destructor Documentation

◆ MaterialComponent() [1/2]

MaterialComponent::MaterialComponent ( const Material & material = material::defaultMaterials[0])
inline

Instances a Component with the given material.

Parameters
materiala Material object

◆ MaterialComponent() [2/2]

MaterialComponent::MaterialComponent ( const material::MaterialType & type)
inline

Instances a Component by using the given material type to retrieve the Material object.

Parameters
typea material type or index
See also
material::MaterialType
material::getMaterialFromPool()

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