Skip to content

Instantly share code, notes, and snippets.

@shibbo
Created July 17, 2017 16:04
Show Gist options
  • Save shibbo/b408f1be9871f025ec037e4602aa128b to your computer and use it in GitHub Desktop.
Save shibbo/b408f1be9871f025ec037e4602aa128b to your computer and use it in GitHub Desktop.
#ifndef SPRITERENDERER_H
#define SPRITERENDERER_H
#include "objects/sprite.h"
class SpriteRenderer
{
public:
SpriteRenderer() {}
SpriteRenderer(Sprite* spr);
void render(QPainter* painter, QRect drawRect);
SpriteRenderer *ret;
Sprite* sprite;
};
class SpriteRectRenderer : public SpriteRenderer
{
public:
SpriteRectRenderer() {}
SpriteRectRenderer(Sprite* spr);
void render(QPainter* painter, QRect rect);
Sprite* sprite;
};
#endif // SPRITERENDERER_H
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment