love.graphics internal Buffer objects are no longer OpenGL-specific.

--HG--
branch : minor
This commit is contained in:
Alex Szpakowski
2017-01-28 19:26:57 -04:00
parent 470098b7e6
commit d990044288
27 changed files with 594 additions and 532 deletions
+11 -1
View File
@@ -29,6 +29,7 @@
#include "Color.h"
#include "Quad.h"
#include "Texture.h"
#include "Buffer.h"
// STL
#include <vector>
@@ -38,6 +39,8 @@ namespace love
namespace graphics
{
class Graphics;
/**
* A class for creating, moving and drawing particles.
* A big thanks to bobthebloke.org
@@ -81,7 +84,7 @@ public:
/**
* Creates a particle system with the specified buffer size and texture.
**/
ParticleSystem(Texture *texture, uint32 buffer);
ParticleSystem(Graphics *gfx, Texture *texture, uint32 buffer);
ParticleSystem(const ParticleSystem &p);
/**
@@ -548,6 +551,8 @@ protected:
int quadIndex;
};
bool prepareDraw(Graphics *gfx, const Matrix4 &m);
// Pointer to the beginning of the allocated memory.
Particle *pMem;
@@ -647,6 +652,11 @@ protected:
bool relativeRotation;
Buffer *buffer;
// Vertex index buffer.
QuadIndices quadIndices;
private:
void resetOffset();