diff options
author | chai <chaifix@163.com> | 2021-10-25 03:22:49 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-10-25 03:22:49 +0800 |
commit | 0816cd70ca1a213b6ed872bcf3c0bf0912473722 (patch) | |
tree | ede23a398e78106551434ca762362ca04fd1ba8c /Resources/Scripts | |
parent | 180b715e72ffc292ebbc4695f8a63ce449004d27 (diff) |
*misc
Diffstat (limited to 'Resources/Scripts')
-rw-r--r-- | Resources/Scripts/Editor/AssetBrowser.lua | 13 | ||||
-rw-r--r-- | Resources/Scripts/EditorApplication.lua | 5 |
2 files changed, 13 insertions, 5 deletions
diff --git a/Resources/Scripts/Editor/AssetBrowser.lua b/Resources/Scripts/Editor/AssetBrowser.lua index 06661a2..3d03302 100644 --- a/Resources/Scripts/Editor/AssetBrowser.lua +++ b/Resources/Scripts/Editor/AssetBrowser.lua @@ -1,5 +1,6 @@ local Debug = GameLab.Debug
-local AssetBrowser = GameLab.Editor.GUI.EditorWindow.Extend("AssetBrowser", "GameLab.Editor")
+local AssetBrowser = GameLab.Editor.GUI.EditorWindow.Extend("GameLab.Editor.AssetBrowser")
+local GL = GameLab.Engine.GL
AssetBrowser.Ctor = function(self)
self.base.Ctor(self, "AssetBrowser")
@@ -7,7 +8,15 @@ AssetBrowser.Ctor = function(self) end
AssetBrowser.OnGUI = function(self)
-
+ Debug.Log("AssetBrowser.OnGUI()")
+ GL.ClearColor({0,0,0,1})
+ GL.Clear(GL.EBufferType.ColorBuffer)
+ GL.Color({1,1,0,1})
+ GL.Begin(GL.EPrimitiveType.Triangles)
+ GL.Vertex({0,0,-1})
+ GL.Vertex({0,1,-1})
+ GL.Vertex({1,0,-1})
+ GL.End()
end
AssetBrowser.OnFocus = function(self)
diff --git a/Resources/Scripts/EditorApplication.lua b/Resources/Scripts/EditorApplication.lua index a6515ba..e91725a 100644 --- a/Resources/Scripts/EditorApplication.lua +++ b/Resources/Scripts/EditorApplication.lua @@ -37,8 +37,6 @@ guiWindow:SetInstance(wnd) local v = GameLab.Engine.Math.Vector4.New(1,2,3,4) Debug.Log(inspect(v)) -local V4 = GameLab.Engine.Math.Vector4.Extend("V4", "GameLab.Engine.Math") - Debug.Log(EditorWindowManager.name) local c = Rendering.Color.New(1,1,1,1) @@ -46,7 +44,8 @@ Debug.Log(inspect(c)) Debug.Log(inspect(GL.EBufferType)) -GL.Clear() +GL.ClearColor({1,1,1,1}) +GL.Clear(GL.EBufferType.ColorBuffer) while true do |