Create DrawQable class, make Image and Canvas DrawQable, and make love.graphics.drawq take a DrawQable as its first argument

This commit is contained in:
Bill Meltsner
2011-10-04 12:33:34 -04:00
parent 4cb247b3ea
commit 14348f6146
13 changed files with 233 additions and 40 deletions
+6 -13
View File
@@ -22,9 +22,8 @@
#define LOVE_GRAPHICS_OPENGL_QUAD_H
// LOVE
#include <common/Object.h>
#include <common/math.h>
#include <graphics/Drawable.h>
#include <graphics/Quad.h>
namespace love
{
@@ -32,19 +31,13 @@ namespace graphics
{
namespace opengl
{
class Quad : public Object
class Quad : public love::graphics::Quad
{
public:
struct Viewport
{
float x, y, w, h;
};
private:
protected:
vertex vertices[4];
Viewport viewport;
float sw, sh;