VEX Engine
Retro looking game engine made in vulkan mostly because i wanted to understand it better.
Loading...
Searching...
No Matches
vex::MeshComponent Struct Reference

Struct containing raw meshData, mesh id, texture paths and material properties. It just template and data for rendering backend to load/convert this data to its acceptible format. This is made weirdly cause its made in mind for multiple backends. IDK i hate this system but i have no better idea. More...

#include <BasicComponents.hpp>

Public Member Functions

bool getIsFresh ()
 (used internally by the engine, DO NOT CALL) returns true if the component is fresh.
void setRendered ()
 (used internally by the engine, DO NOT CALL) sets the component as rendered.
void forceRefresh ()
 (used internally by the engine, DO NOT CALL) forces the component to be refreshed.

Public Attributes

MeshData meshData
uint32_t id = UINT32_MAX
std::vector< std::string > textureNames
RenderType renderType = RenderType::OPAQUE
vex::rgba color = glm::vec4(1.f)
std::map< int, texture_asset_pathtextureOverrides
glm::vec3 localCenter = glm::vec3(0.0f)
float localRadius = 1.0f
glm::vec3 worldCenter = glm::vec3(0.0f)
float worldRadius = 1.0f

Private Attributes

bool fresh = true

Detailed Description

Struct containing raw meshData, mesh id, texture paths and material properties. It just template and data for rendering backend to load/convert this data to its acceptible format. This is made weirdly cause its made in mind for multiple backends. IDK i hate this system but i have no better idea.

Definition at line 418 of file BasicComponents.hpp.

Member Function Documentation

◆ forceRefresh()

void vex::MeshComponent::forceRefresh ( )
inline

(used internally by the engine, DO NOT CALL) forces the component to be refreshed.

Definition at line 446 of file BasicComponents.hpp.

◆ getIsFresh()

bool vex::MeshComponent::getIsFresh ( )
inline

(used internally by the engine, DO NOT CALL) returns true if the component is fresh.

Definition at line 436 of file BasicComponents.hpp.

◆ setRendered()

void vex::MeshComponent::setRendered ( )
inline

(used internally by the engine, DO NOT CALL) sets the component as rendered.

Definition at line 441 of file BasicComponents.hpp.

Member Data Documentation

◆ color

vex::rgba vex::MeshComponent::color = glm::vec4(1.f)

Definition at line 424 of file BasicComponents.hpp.

◆ fresh

bool vex::MeshComponent::fresh = true
private

Definition at line 451 of file BasicComponents.hpp.

◆ id

uint32_t vex::MeshComponent::id = UINT32_MAX

Definition at line 421 of file BasicComponents.hpp.

◆ localCenter

glm::vec3 vex::MeshComponent::localCenter = glm::vec3(0.0f)

Definition at line 429 of file BasicComponents.hpp.

◆ localRadius

float vex::MeshComponent::localRadius = 1.0f

Definition at line 430 of file BasicComponents.hpp.

◆ meshData

MeshData vex::MeshComponent::meshData

Definition at line 420 of file BasicComponents.hpp.

◆ renderType

RenderType vex::MeshComponent::renderType = RenderType::OPAQUE

Definition at line 423 of file BasicComponents.hpp.

◆ textureNames

std::vector<std::string> vex::MeshComponent::textureNames

Definition at line 422 of file BasicComponents.hpp.

◆ textureOverrides

std::map<int, texture_asset_path> vex::MeshComponent::textureOverrides

Definition at line 426 of file BasicComponents.hpp.

◆ worldCenter

glm::vec3 vex::MeshComponent::worldCenter = glm::vec3(0.0f)

Definition at line 432 of file BasicComponents.hpp.

◆ worldRadius

float vex::MeshComponent::worldRadius = 1.0f

Definition at line 433 of file BasicComponents.hpp.


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