summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-10-28 10:53:40 +0800
committerchai <chaifix@163.com>2021-10-28 10:53:40 +0800
commitf6327c0948d666a4b61358c7aefed36eb070198d (patch)
treed3a57a6f048a205d850d9364c990c8eb7c7e6d41
parent8cbcd2dc3f7ea5a1d8656cd3885b553121cb7450 (diff)
*rename
-rw-r--r--Runtime/Graphics/PolyLine.cpp2
-rw-r--r--Runtime/Graphics/Quad.cpp2
-rw-r--r--Runtime/Math/Vector3.h23
-rw-r--r--Runtime/Scripting/GL/GL.bind.cpp4
4 files changed, 18 insertions, 13 deletions
diff --git a/Runtime/Graphics/PolyLine.cpp b/Runtime/Graphics/PolyLine.cpp
index d8ab85b..db27903 100644
--- a/Runtime/Graphics/PolyLine.cpp
+++ b/Runtime/Graphics/PolyLine.cpp
@@ -4,6 +4,6 @@
struct PolyLineVBOLayout
{
- Vector3 position;
+ Internal::Vector3 position;
Color32 color;
};
diff --git a/Runtime/Graphics/Quad.cpp b/Runtime/Graphics/Quad.cpp
index f584fe8..d769dd4 100644
--- a/Runtime/Graphics/Quad.cpp
+++ b/Runtime/Graphics/Quad.cpp
@@ -5,7 +5,7 @@
struct QuadVBOLayout
{
- Vector3 position;
+ Internal::Vector3 position;
Internal::Vector2 uv;
};
diff --git a/Runtime/Math/Vector3.h b/Runtime/Math/Vector3.h
index 08e2592..c0a35f3 100644
--- a/Runtime/Math/Vector3.h
+++ b/Runtime/Math/Vector3.h
@@ -1,17 +1,22 @@
#ifndef VECTOR3_H
#define VECTOR3_H
-struct Vector3
+namespace Internal
{
- float x, y, z;
- inline void Set(float x, float y, float z)
- {
- this->x = x;
- this->y = y;
- this->z = z;
- }
+ struct Vector3
+ {
+ float x, y, z;
-};
+ inline void Set(float x, float y, float z)
+ {
+ this->x = x;
+ this->y = y;
+ this->z = z;
+ }
+ };
+
+
+}
#endif \ No newline at end of file
diff --git a/Runtime/Scripting/GL/GL.bind.cpp b/Runtime/Scripting/GL/GL.bind.cpp
index f4c9f50..fe391c7 100644
--- a/Runtime/Scripting/GL/GL.bind.cpp
+++ b/Runtime/Scripting/GL/GL.bind.cpp
@@ -117,7 +117,7 @@ int End(lua_State* L)
int Vertex(lua_State* L)
{
LUA_BIND_STATE(L);
- if (LuaHelper::IsType(state, "GameLab.Engine.Math.Vector3", 1))
+ if (LuaHelper::IsType(state, "GameLab.Engine.Math.Internal::Vector3", 1))
{
float x = state.GetField(-1, "x", 0);
float y = state.GetField(-1, "y", 0);
@@ -133,7 +133,7 @@ int Vertex(lua_State* L)
}
else
{
- state.ErrorType(1, "Vector3 or vector3 table");
+ state.ErrorType(1, "Internal::Vector3 or vector3 table");
}
return 0;
}