From 8585c92b7d0744a1f1a39c872cf5096621161b6c Mon Sep 17 00:00:00 2001 From: chai Date: Thu, 16 Aug 2018 14:21:56 +0800 Subject: *update --- src/lua/graphics/Image.h | 65 ------------------------------------------------ 1 file changed, 65 deletions(-) delete mode 100644 src/lua/graphics/Image.h (limited to 'src/lua/graphics/Image.h') diff --git a/src/lua/graphics/Image.h b/src/lua/graphics/Image.h deleted file mode 100644 index 0d1d010..0000000 --- a/src/lua/graphics/Image.h +++ /dev/null @@ -1,65 +0,0 @@ -#ifndef __JIN_LUA_GRAPHICS_IMAGE_H -#define __JIN_LUA_GRAPHICS_IMAGE_H -#include "libjin/jin.h" -#include "../luaopen_types.h" - -namespace jin -{ -namespace lua -{ -namespace graphics -{ - - class Image : public Object - { - public: - static Image* createImage(const char* file); - static Image* createImage(const void* mem, size_t size); - - int getWidth() - { - return image->getWidth(); - } - - int getHeight() - { - return image->getHeight(); - } - - void setAnchor(int x, int y) - { - image->setAnchor(x, y); - } - - jin::graphics::color getPixel(int x, int y) - { - return image->getPixel(x, y); - } - - inline const jin::graphics::Texture* getRawImage() const - { - return image; - } - - void draw(int x, int y, float sx, float sy, float r) - { - image->draw(x, y, sx, sy, r); - } - - private: - Image() {}; - - ~Image() - { - delete image; - } - - jin::graphics::Texture* image; - - }; - -} // graphics -} // lua -} // jin - -#endif // __JIN_LUA_GRAPHICS_IMAGE_H \ No newline at end of file -- cgit v1.1-26-g67d0