why? cause sorting around the global driver pool would basically use more cpu power then just copy data sequences into the right order And sorting data references costs 0 performance at all
16 lines
375 B
C++
16 lines
375 B
C++
#include <pd/lithium/pools.hpp>
|
|
|
|
namespace PD {
|
|
namespace Li {
|
|
static PD::Pool<Vertex> gVertexPool;
|
|
static PD::Pool<u16> gIndexPool;
|
|
|
|
PD_API PD::Pool<Vertex>& GetVertexPool() { return gVertexPool; }
|
|
PD_API PD::Pool<u16>& GetIndexPool() { return gIndexPool; }
|
|
|
|
PD_API void ResetPools() {
|
|
gVertexPool.NoReset();
|
|
gIndexPool.NoReset();
|
|
}
|
|
} // namespace Li
|
|
} // namespace PD
|