Hymn to Beauty
C++ 3D Engine
Component::Material Class Reference

Component providing a material to Entity. More...

#include <Material.hpp>

Inheritance diagram for Component::Material:
Component::SuperComponent

Public Member Functions

 Material ()
 Create new material. More...
 
 ~Material () override
 Destructor. More...
 
void Serialize (Json::Value &node, bool load) override
 Save or load component values to/from JSON. More...
 
- Public Member Functions inherited from Component::SuperComponent
 SuperComponent ()
 Create new SuperComponent. More...
 
virtual ~SuperComponent ()
 Destructor. More...
 
void Kill ()
 Kill the component, will be removed at the end of the frame. More...
 
bool IsKilled () const
 Get whether component has been killed. More...
 

Public Attributes

TextureAssetalbedo
 Albedo texture. More...
 
TextureAssetnormal
 Normal texture. More...
 
TextureAssetroughnessMetallic
 Roughness-metallic texture. More...
 
- Public Attributes inherited from Component::SuperComponent
Entityentity = nullptr
 Pointer to which entity this component corresponds. More...
 

Detailed Description

Component providing a material to Entity.

Constructor & Destructor Documentation

◆ Material()

Material::Material ( )

Create new material.

◆ ~Material()

Material::~Material ( )
override

Destructor.

Member Function Documentation

◆ Serialize()

void Material::Serialize ( Json::Value &  node,
bool  load 
)
overridevirtual

Save or load component values to/from JSON.

Parameters
nodeThe JSON node to save to or load from.
loadWhether to load (otherwise saves).

Implements Component::SuperComponent.

Member Data Documentation

◆ albedo

TextureAsset* Component::Material::albedo

Albedo texture.

◆ normal

TextureAsset* Component::Material::normal

Normal texture.

◆ roughnessMetallic

TextureAsset* Component::Material::roughnessMetallic

Roughness-metallic texture.

Roughness in green channel. Metallic in blue channel.


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