Falcon
Public Member Functions | List of all members
Particle Class Reference

#include <Particle.h>

Inheritance diagram for Particle:
Renderable

Public Member Functions

 Particle ()
 
 ~Particle ()
 
void Setup () override
 
void PreallocParticleDataAmount (u32 maxParticleData)
 
void AddParticleData (const ParticleData &data)
 
void ClearParticleData ()
 
u32 GetParticleDataAmount ()
 
void SetWorldMatrix (glm::mat4 mat)
 
glm::mat4 & GetWorldMatrix ()
 
void Bind () override
 
- Public Member Functions inherited from Renderable
 Renderable ()
 
virtual ~Renderable ()
 
void SetMaterial (Material *mat)
 
MaterialGetMaterial () const
 

Additional Inherited Members

- Public Attributes inherited from Renderable
boost::container::vector< Vertex, fmemory::STLAllocator< Vertex > > m_vertexArray
 
- Protected Attributes inherited from Renderable
Materialm_material = nullptr
 
VertexArraym_VAO = nullptr
 

Detailed Description

Particle Class tp store Particle Data for Renderables.

Constructor & Destructor Documentation

◆ Particle()

Particle::Particle ( )

Basic Particle Constructor

◆ ~Particle()

Particle::~Particle ( )

Particle class Destructor.

Member Function Documentation

◆ AddParticleData()

void Particle::AddParticleData ( const ParticleData data)

Adds particle data to the list of data for instanced rendering

Parameters
data- The particle data to add

◆ Bind()

void Particle::Bind ( )
overridevirtual

Binds the VertexArray object held by the mesh along with the relevant vertex and index buffer.

Reimplemented from Renderable.

◆ ClearParticleData()

void Particle::ClearParticleData ( )

Clears the particle data vector

◆ GetParticleDataAmount()

u32 Particle::GetParticleDataAmount ( )

Gets the size of the particle data array

Returns
The size of the particle data array

◆ GetWorldMatrix()

glm::mat4 & Particle::GetWorldMatrix ( )

◆ PreallocParticleDataAmount()

void Particle::PreallocParticleDataAmount ( u32  maxParticleData)

Preallocates the particle data vector with a specified size

Parameters
maxParticleData- The maximum number of items in the world

◆ Setup()

void Particle::Setup ( )
overridevirtual

Sets a vertex Array Object with the vertex and indexbuffer values in this mesh class.

Reimplemented from Renderable.

◆ SetWorldMatrix()

void Particle::SetWorldMatrix ( glm::mat4  mat)

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