2014-12-28 21:52:04 +01:00
|
|
|
#include "smalllibc/kosSyst.h"
|
2014-12-28 19:29:59 +01:00
|
|
|
|
|
|
|
#define DRAW_NONE 0
|
|
|
|
#define DRAW_ALPHA 1
|
|
|
|
#define DRAW_ALPHA_ADD 2
|
|
|
|
|
|
|
|
class CKosImage
|
|
|
|
{
|
|
|
|
private:
|
|
|
|
bool isColor;
|
|
|
|
RGB color;
|
|
|
|
int getPixel(int x, int y);
|
|
|
|
Byte mode;
|
|
|
|
int frame;
|
|
|
|
int frameWidth;
|
|
|
|
int frameHeight;
|
|
|
|
public:
|
|
|
|
CKosImage(CKosRender *render, RGBA *buffer, int width, int height);
|
|
|
|
~CKosImage(void);
|
|
|
|
|
|
|
|
void Draw(Point position, float angle, RGB color);
|
|
|
|
void Draw(Point position, float angle);
|
|
|
|
void Draw(Point position, float angle, int frame);
|
|
|
|
void SetMode(int mode);
|
|
|
|
void SetFrameSize(int width, int height);
|
|
|
|
protected:
|
|
|
|
CKosRender *render;
|
|
|
|
RGBA *buffer;
|
|
|
|
int width;
|
|
|
|
int height;
|
|
|
|
};
|