mirror of
https://github.com/love2d/love.git
synced 2026-08-18 03:34:23 +02:00
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:
@@ -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;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user