summaryrefslogtreecommitdiff
path: root/source/modules/asura-core/graphics/image.h
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2019-04-06 07:39:49 +0800
committerchai <chaifix@163.com>2019-04-06 07:39:49 +0800
commite47baca4f23db43ec91fbf64d5d06d7c0dbee495 (patch)
tree9e909413bbf61834570e7dbdbe37fc8705f12730 /source/modules/asura-core/graphics/image.h
parente13616b5c40f912853be99f0603f0e4c97b22062 (diff)
*misc
Diffstat (limited to 'source/modules/asura-core/graphics/image.h')
-rw-r--r--source/modules/asura-core/graphics/image.h15
1 files changed, 6 insertions, 9 deletions
diff --git a/source/modules/asura-core/graphics/image.h b/source/modules/asura-core/graphics/image.h
index e4aecd1..d3cca4b 100644
--- a/source/modules/asura-core/graphics/image.h
+++ b/source/modules/asura-core/graphics/image.h
@@ -20,21 +20,16 @@ namespace AsuraEngine
namespace Graphics
{
- class ImageFactory;
-
///
/// ImageͼƬڴ󣬶ȡϷ󱣴ĽһImageڴ桢Դֻᱣһ
/// ݣҪimageêλãźתǶȣʹsprite
/// һֻࡣҪǿǵeditorengineʹòͬķװ
///
class Image ASURA_FINAL
- : public AEIO::Renewable
- , public AEScripting::Portable<Image, Texture>
+ : public AEScripting::Portable<Image, Texture>
{
public:
- LUAX_DECL_FACTORY(Image);
-
Image();
~Image();
@@ -43,19 +38,21 @@ namespace AsuraEngine
/// ͼύGPUϢ¹imageʹglTexImage2D
/// ύimageݡ
///
- bool Update(AEIO::DecodedData* decodeData) override;
- bool Update(AEIO::DecodedData* decodeData, const AEMath::Vector2i& pos);
+ bool Load(ImageData* decodeData);
+ bool Load(ImageData* decodeData, const AEMath::Vector2i& pos);
uint GetWidth();
uint GetHeight();
void Render(const RenderTarget* rt, const RenderState& state) override {};
- void Render(const RenderTarget* rt, const Math::Rectf& quad, const RenderState& state) override {};
+ void Render(const RenderTarget* rt, const AEMath::Rectf& quad, const RenderState& state) override {};
private:
//----------------------------------------------------------------------------//
+ LUAX_DECL_FACTORY(Image, Texture);
+
LUAX_DECL_METHOD(_New);
LUAX_DECL_METHOD(_Update);
LUAX_DECL_METHOD(_GetWidth);