aboutsummaryrefslogtreecommitdiff
path: root/src/lua/modules/graphics/je_lua_texture.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lua/modules/graphics/je_lua_texture.cpp')
-rw-r--r--src/lua/modules/graphics/je_lua_texture.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/lua/modules/graphics/je_lua_texture.cpp b/src/lua/modules/graphics/je_lua_texture.cpp
index d7571b6..08a98eb 100644
--- a/src/lua/modules/graphics/je_lua_texture.cpp
+++ b/src/lua/modules/graphics/je_lua_texture.cpp
@@ -1,5 +1,5 @@
#include "lua/modules/luax.h"
-#include "lua/modules/types.h"
+
#include "lua/common/je_lua_common.h"
#include "libjin/jin.h"
@@ -9,12 +9,14 @@ namespace JinEngine
{
namespace Lua
{
+
+ const char* Jin_Lua_Texture = "Texture";
typedef Shared<Texture>& SharedTexture;
LUA_IMPLEMENT inline SharedTexture checkTexture(lua_State* L)
{
- Proxy* proxy = (Proxy*)luax_checktype(L, 1, JIN_GRAPHICS_TEXTURE);
+ Proxy* proxy = (Proxy*)luax_checktype(L, 1, Jin_Lua_Texture);
return proxy->getShared<Texture>();
}
@@ -42,7 +44,7 @@ namespace JinEngine
LUA_IMPLEMENT int l_gc(lua_State* L)
{
- Proxy* proxy = (Proxy*)luax_checktype(L, 1, JIN_GRAPHICS_TEXTURE);
+ Proxy* proxy = (Proxy*)luax_checktype(L, 1, Jin_Lua_Texture);
proxy->release();
return 0;
}
@@ -56,7 +58,7 @@ namespace JinEngine
{ "getSize", l_getSize },
{ 0, 0 }
};
- luax_newtype(L, JIN_GRAPHICS_TEXTURE, f);
+ luax_newtype(L, Jin_Lua_Texture, f);
return 0;
}