Minor refactor

This commit is contained in:
Joshua Granick
2014-07-08 11:56:25 -07:00
parent 7df1416127
commit 84fbffa923
15 changed files with 178 additions and 158 deletions

View File

@@ -0,0 +1,38 @@
#ifndef LIME_GRAPHICS_IMAGE_H
#define LIME_GRAPHICS_IMAGE_H
#include <hx/CFFI.h>
#include <utils/ByteArray.h>
namespace lime {
class Image {
public:
Image ();
~Image ();
value Value ();
int width;
int height;
ByteArray *data;
private:
value mValue;
};
}
#endif

View File

@@ -1,33 +0,0 @@
#ifndef LIME_GRAPHICS_IMAGE_DATA_H
#define LIME_GRAPHICS_IMAGE_DATA_H
#include <hx/CFFI.h>
#include <utils/ByteArray.h>
namespace lime {
class ImageData {
public:
int width;
int height;
ByteArray *data;
ImageData();
~ImageData();
value Value();
private:
value mValue;
};
}
#endif

View File

@@ -3,15 +3,16 @@
namespace lime {
class ImageData;
class Image;
class JPEG {
public:
static bool Decode (const char *path, ImageData *imageData);
static bool Decode (const char *path, Image *image);
};

View File

@@ -4,14 +4,15 @@
namespace lime {
class ImageData;
class Image;
class PNG {
public:
static bool Decode (const char *path, ImageData *imageData);
static bool Decode (const char *path, Image *image);
};