diff --git a/include/Core/SPK_Group.h b/include/Core/SPK_Group.h index 823562e..5a6335c 100644 --- a/include/Core/SPK_Group.h +++ b/include/Core/SPK_Group.h @@ -91,14 +91,14 @@ namespace SPK bool isEnabled(Param param) const; - size_t getNbParticles() const; - size_t getCapacity() const; + inline unsigned int getNbParticles() const; + inline unsigned int getCapacity() const; Particle getParticle(size_t index); const Particle getParticle(size_t index) const; - void reallocate(size_t capacity); - void empty(); + void reallocate(unsigned int capacity); + inline void empty(); void addEmitter(const Ref& emitter); void removeEmitter(const Ref& emitter); @@ -401,8 +401,8 @@ namespace SPK { bool initialized; - size_t nbParticles; - size_t maxParticles; + unsigned int nbParticles; + unsigned int maxParticles; // Particles attributes Vector3D* positions; @@ -734,12 +734,12 @@ namespace SPK return particleData.parameters[param] != NULL; } - inline size_t Group::getNbParticles() const + inline unsigned int Group::getNbParticles() const { return particleData.nbParticles; } - inline size_t Group::getCapacity() const + inline unsigned int Group::getCapacity() const { return particleData.maxParticles; } diff --git a/src/Core/SPK_Group.cpp b/src/Core/SPK_Group.cpp index ed241df..4a7cae9 100644 --- a/src/Core/SPK_Group.cpp +++ b/src/Core/SPK_Group.cpp @@ -54,7 +54,7 @@ namespace SPK deathAction(), octree(NULL) { - reallocate(capacity); + reallocate(static_cast(capacity)); } Group::Group(const Group& group) : @@ -270,7 +270,7 @@ namespace SPK } } - void Group::reallocate(size_t capacity) + void Group::reallocate(unsigned int capacity) { SPK_ASSERT(capacity != 0,"Group::reallocate(size_t) - Group capacity must not be 0");