From 03b3b8ae80559745f98ef94569b421adddeb441f Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 25 Mar 2019 23:46:59 +0800 Subject: *misc --- .../asura-lib-core/graphics/binding/_canvas.cpp | 0 .../asura-lib-core/graphics/binding/_color.cpp | 0 .../libs/asura-lib-core/graphics/binding/_gif.cpp | 0 .../asura-lib-core/graphics/binding/_image.cpp | 0 .../graphics/binding/_image_data.cpp | 62 +++++++++++ .../asura-lib-core/graphics/binding/_mesh2d.cpp | 0 .../graphics/binding/_mesh2d_data.cpp | 9 ++ .../asura-lib-core/graphics/binding/_shader.cpp | 114 +++++++++++++++++++++ .../graphics/binding/_sprite_batch.cpp | 0 .../asura-lib-core/graphics/binding/_window.cpp | 11 ++ .../graphics/binding/canvas.binding.cpp | 0 .../graphics/binding/color.binding.cpp | 0 .../graphics/binding/gif.binding.cpp | 0 .../graphics/binding/image.binding.cpp | 0 .../graphics/binding/image_data.binding.cpp | 62 ----------- .../graphics/binding/mesh2d.binding.cpp | 0 .../graphics/binding/mesh2d_data.binding.cpp | 9 -- .../graphics/binding/shader.binding.cpp | 114 --------------------- .../graphics/binding/sprite_batch.binding.cpp | 0 .../graphics/binding/window.binding.cpp | 11 -- 20 files changed, 196 insertions(+), 196 deletions(-) create mode 100644 source/libs/asura-lib-core/graphics/binding/_canvas.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_color.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_gif.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_image.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_image_data.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_mesh2d.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_mesh2d_data.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_shader.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_sprite_batch.cpp create mode 100644 source/libs/asura-lib-core/graphics/binding/_window.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/canvas.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/color.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/gif.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/image.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/image_data.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/mesh2d.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/mesh2d_data.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/shader.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/sprite_batch.binding.cpp delete mode 100644 source/libs/asura-lib-core/graphics/binding/window.binding.cpp (limited to 'source/libs/asura-lib-core/graphics/binding') diff --git a/source/libs/asura-lib-core/graphics/binding/_canvas.cpp b/source/libs/asura-lib-core/graphics/binding/_canvas.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_color.cpp b/source/libs/asura-lib-core/graphics/binding/_color.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_gif.cpp b/source/libs/asura-lib-core/graphics/binding/_gif.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_image.cpp b/source/libs/asura-lib-core/graphics/binding/_image.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_image_data.cpp b/source/libs/asura-lib-core/graphics/binding/_image_data.cpp new file mode 100644 index 0000000..72e33da --- /dev/null +++ b/source/libs/asura-lib-core/graphics/binding/_image_data.cpp @@ -0,0 +1,62 @@ +#include "../image_data.h" + +using namespace Luax; + +namespace AsuraEngine +{ + namespace Graphics + { + + LUAX_REGISTRY(ImageData) + { + + } + + LUAX_POSTPROCESS(ImageData) + { + LUAX_REGISTER_ENUM(state, "EBlendMode", + { "Additive", 1 } + ); + LUAX_REGISTER_ENUM(state, "EPixelFormat", + { "RGBA32", 1 } + ); + } + + // imagedata = ImageData.New(databuffer) + LUAX_IMPL_METHOD(ImageData, _New) + { + LUAX_STATE(L); + + Filesystem::DataBuffer* db = state.CheckUserdata(1); + ImageData* image = new ImageData(*db); + image->PushLuaxUserdata(state); + return 1; + } + + LUAX_IMPL_METHOD(ImageData, _GetPixel) + { + + } + + LUAX_IMPL_METHOD(ImageData, _GetSize) + { + + } + + LUAX_IMPL_METHOD(ImageData, _GetWidth) + { + + } + + LUAX_IMPL_METHOD(ImageData, _GetHeight) + { + + } + + LUAX_IMPL_METHOD(ImageData, _GetPixelFormat) + { + + } + + } +} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/_mesh2d.cpp b/source/libs/asura-lib-core/graphics/binding/_mesh2d.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_mesh2d_data.cpp b/source/libs/asura-lib-core/graphics/binding/_mesh2d_data.cpp new file mode 100644 index 0000000..6e15052 --- /dev/null +++ b/source/libs/asura-lib-core/graphics/binding/_mesh2d_data.cpp @@ -0,0 +1,9 @@ +namespace AsuraEngine +{ + namespace Graphics + { + + + + } +} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/_shader.cpp b/source/libs/asura-lib-core/graphics/binding/_shader.cpp new file mode 100644 index 0000000..2f2f507 --- /dev/null +++ b/source/libs/asura-lib-core/graphics/binding/_shader.cpp @@ -0,0 +1,114 @@ +#include "../shader.h" + +using namespace Luax; + +namespace AsuraEngine +{ + namespace Graphics + { + + void Shader::RegisterLuaxClass(LuaxState& state) + { + + LuaxEnum EBuiltIn[] = { + {0, 0} + }; + + state.RegisterEnum("EBuiltIn", EBuiltIn); + + } + + void Shader::RegisterLuaxPostprocess(LuaxState& state) + { + + } + + /// + /// 将此shader设置为活动。 + /// + int Shader::l_Use(lua_State* L) + { + LUAX_STATE(L); + + } + + /// + /// 将此shader设置为非活动。 + /// + int Shader::l_Unuse(lua_State* L) + { + LUAX_STATE(L); + + } + + /// + /// 从着色器代码中构建shader程序。如果成功返回true,失败返回false。 + /// + int Shader::l_Load(lua_State* L) + { + LUAX_STATE(L); + + } + + /// + /// 判断shader是否有这个uniform,如果有返回true,否则返回false + /// + int Shader::l_HasUniform(lua_State* L) + { + LUAX_STATE(L); + + } + + /// + /// 后的uniforms的location,如果没有这个uniform,返回nil,否则返回对应的loc + /// + int Shader::l_GetUniformLocation(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetBuiltInUniforms(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformFloat(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformTexture(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformVector2(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformVector3(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformVector4(lua_State* L) + { + LUAX_STATE(L); + + } + + int Shader::l_SetUniformColor(lua_State* L) + { + LUAX_STATE(L); + + } + + } +} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/_sprite_batch.cpp b/source/libs/asura-lib-core/graphics/binding/_sprite_batch.cpp new file mode 100644 index 0000000..e69de29 diff --git a/source/libs/asura-lib-core/graphics/binding/_window.cpp b/source/libs/asura-lib-core/graphics/binding/_window.cpp new file mode 100644 index 0000000..3befc8c --- /dev/null +++ b/source/libs/asura-lib-core/graphics/binding/_window.cpp @@ -0,0 +1,11 @@ +#include "../Window.h" + +namespace AsuraEngine +{ + namespace Graphics + { + + + + } +} diff --git a/source/libs/asura-lib-core/graphics/binding/canvas.binding.cpp b/source/libs/asura-lib-core/graphics/binding/canvas.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/color.binding.cpp b/source/libs/asura-lib-core/graphics/binding/color.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/gif.binding.cpp b/source/libs/asura-lib-core/graphics/binding/gif.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/image.binding.cpp b/source/libs/asura-lib-core/graphics/binding/image.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/image_data.binding.cpp b/source/libs/asura-lib-core/graphics/binding/image_data.binding.cpp deleted file mode 100644 index 72e33da..0000000 --- a/source/libs/asura-lib-core/graphics/binding/image_data.binding.cpp +++ /dev/null @@ -1,62 +0,0 @@ -#include "../image_data.h" - -using namespace Luax; - -namespace AsuraEngine -{ - namespace Graphics - { - - LUAX_REGISTRY(ImageData) - { - - } - - LUAX_POSTPROCESS(ImageData) - { - LUAX_REGISTER_ENUM(state, "EBlendMode", - { "Additive", 1 } - ); - LUAX_REGISTER_ENUM(state, "EPixelFormat", - { "RGBA32", 1 } - ); - } - - // imagedata = ImageData.New(databuffer) - LUAX_IMPL_METHOD(ImageData, _New) - { - LUAX_STATE(L); - - Filesystem::DataBuffer* db = state.CheckUserdata(1); - ImageData* image = new ImageData(*db); - image->PushLuaxUserdata(state); - return 1; - } - - LUAX_IMPL_METHOD(ImageData, _GetPixel) - { - - } - - LUAX_IMPL_METHOD(ImageData, _GetSize) - { - - } - - LUAX_IMPL_METHOD(ImageData, _GetWidth) - { - - } - - LUAX_IMPL_METHOD(ImageData, _GetHeight) - { - - } - - LUAX_IMPL_METHOD(ImageData, _GetPixelFormat) - { - - } - - } -} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/mesh2d.binding.cpp b/source/libs/asura-lib-core/graphics/binding/mesh2d.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/mesh2d_data.binding.cpp b/source/libs/asura-lib-core/graphics/binding/mesh2d_data.binding.cpp deleted file mode 100644 index 6e15052..0000000 --- a/source/libs/asura-lib-core/graphics/binding/mesh2d_data.binding.cpp +++ /dev/null @@ -1,9 +0,0 @@ -namespace AsuraEngine -{ - namespace Graphics - { - - - - } -} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/shader.binding.cpp b/source/libs/asura-lib-core/graphics/binding/shader.binding.cpp deleted file mode 100644 index 2f2f507..0000000 --- a/source/libs/asura-lib-core/graphics/binding/shader.binding.cpp +++ /dev/null @@ -1,114 +0,0 @@ -#include "../shader.h" - -using namespace Luax; - -namespace AsuraEngine -{ - namespace Graphics - { - - void Shader::RegisterLuaxClass(LuaxState& state) - { - - LuaxEnum EBuiltIn[] = { - {0, 0} - }; - - state.RegisterEnum("EBuiltIn", EBuiltIn); - - } - - void Shader::RegisterLuaxPostprocess(LuaxState& state) - { - - } - - /// - /// 将此shader设置为活动。 - /// - int Shader::l_Use(lua_State* L) - { - LUAX_STATE(L); - - } - - /// - /// 将此shader设置为非活动。 - /// - int Shader::l_Unuse(lua_State* L) - { - LUAX_STATE(L); - - } - - /// - /// 从着色器代码中构建shader程序。如果成功返回true,失败返回false。 - /// - int Shader::l_Load(lua_State* L) - { - LUAX_STATE(L); - - } - - /// - /// 判断shader是否有这个uniform,如果有返回true,否则返回false - /// - int Shader::l_HasUniform(lua_State* L) - { - LUAX_STATE(L); - - } - - /// - /// 后的uniforms的location,如果没有这个uniform,返回nil,否则返回对应的loc - /// - int Shader::l_GetUniformLocation(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetBuiltInUniforms(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformFloat(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformTexture(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformVector2(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformVector3(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformVector4(lua_State* L) - { - LUAX_STATE(L); - - } - - int Shader::l_SetUniformColor(lua_State* L) - { - LUAX_STATE(L); - - } - - } -} \ No newline at end of file diff --git a/source/libs/asura-lib-core/graphics/binding/sprite_batch.binding.cpp b/source/libs/asura-lib-core/graphics/binding/sprite_batch.binding.cpp deleted file mode 100644 index e69de29..0000000 diff --git a/source/libs/asura-lib-core/graphics/binding/window.binding.cpp b/source/libs/asura-lib-core/graphics/binding/window.binding.cpp deleted file mode 100644 index 3befc8c..0000000 --- a/source/libs/asura-lib-core/graphics/binding/window.binding.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include "../Window.h" - -namespace AsuraEngine -{ - namespace Graphics - { - - - - } -} -- cgit v1.1-26-g67d0