2D Engine v0.1.0
Loading...
Searching...
No Matches
ComponentPool Struct Reference

Bitmask storage for each entities components. More...

#include <Scene.hpp>

Collaboration diagram for ComponentPool:
Collaboration graph

Public Member Functions

 ComponentPool (size_t elementsize)
 Construct a new Component Pool object based on Component size.
 
 ~ComponentPool ()
 Destroy the Component Pool object.
 
void * get (size_t index)
 Get the component value at the desired index.
 

Public Attributes

char * pData {nullptr}
 
size_t elementSize {0}
 

Detailed Description

Bitmask storage for each entities components.

Constructor & Destructor Documentation

◆ ComponentPool()

ComponentPool::ComponentPool ( size_t elementsize)
inline

Construct a new Component Pool object based on Component size.

Parameters
elementsize

◆ ~ComponentPool()

ComponentPool::~ComponentPool ( )
inline

Destroy the Component Pool object.

Member Function Documentation

◆ get()

void * ComponentPool::get ( size_t index)
inline

Get the component value at the desired index.

Parameters
index
Returns
void*

Member Data Documentation

◆ elementSize

size_t ComponentPool::elementSize {0}

◆ pData

char* ComponentPool::pData {nullptr}

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