MAGE  v0.171.0
Matthias Advanced Game Engine
mage::rendering::ModelPart Struct Reference

#include <model_output.hpp>

Public Member Functions

bool HasDefaultChild () const noexcept
 
bool HasDefaultParent () const noexcept
 
bool HasDefaultMaterial () const noexcept
 

Public Attributes

AABB m_aabb
 
BoundingSphere m_sphere
 
SETTransform3D m_transform
 
U32 m_start_index = 0u
 
U32 m_nb_indices = 0u
 
std::string m_child = s_default_child
 
std::string m_parent = s_default_parent
 
std::string m_material = s_default_material
 

Static Public Attributes

static constexpr const_zstring s_default_child = "default"
 
static constexpr const_zstring s_default_parent = "root"
 
static constexpr const_zstring s_default_material = "none"
 

Detailed Description

A struct of model parts.

Member Function Documentation

◆ HasDefaultChild()

bool mage::rendering::ModelPart::HasDefaultChild ( ) const
noexcept

Checks whether this model part has the default child as its child.

Returns
true if this model part has the default child as its child. false otherwise.

◆ HasDefaultMaterial()

bool mage::rendering::ModelPart::HasDefaultMaterial ( ) const
noexcept

Checks whether this model part has the default material as its material.

Returns
true if this model part has the default material as its material. false otherwise.

◆ HasDefaultParent()

bool mage::rendering::ModelPart::HasDefaultParent ( ) const
noexcept

Checks whether this model part has the default parent as its parent.

Returns
true if this model part has the default parent as its parent. false otherwise.

Member Data Documentation

◆ m_aabb

AABB mage::rendering::ModelPart::m_aabb

The AABB of this model part.

◆ m_child

std::string mage::rendering::ModelPart::m_child = s_default_child

The name of this model part.

◆ m_material

std::string mage::rendering::ModelPart::m_material = s_default_material

The name of the material of this model part.

◆ m_nb_indices

U32 mage::rendering::ModelPart::m_nb_indices = 0u

The number of indices of this model part in the mesh of the corresponding model.

◆ m_parent

std::string mage::rendering::ModelPart::m_parent = s_default_parent

The name of the parent model part of this model part.

◆ m_sphere

BoundingSphere mage::rendering::ModelPart::m_sphere

The bounding sphere of this model part.

◆ m_start_index

U32 mage::rendering::ModelPart::m_start_index = 0u

The start index of this model part in the mesh of the corresponding model.

◆ m_transform

SETTransform3D mage::rendering::ModelPart::m_transform

The local transform of this model part.

◆ s_default_child

constexpr const_zstring mage::rendering::ModelPart::s_default_child = "default"
static

The default child name for model parts.

◆ s_default_material

constexpr const_zstring mage::rendering::ModelPart::s_default_material = "none"
static

The default material name for model parts.

◆ s_default_parent

constexpr const_zstring mage::rendering::ModelPart::s_default_parent = "root"
static

The default parent name for model parts.