diff options
author | chai <chaifix@163.com> | 2018-10-06 08:07:35 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2018-10-06 08:07:35 +0800 |
commit | 090b303a88b493eca0bde51b5a454043c893b0d8 (patch) | |
tree | cbc27aeac6d3e430556aa1ea8f80de2636104028 | |
parent | 789895b4b9f99668b8b772f271d07d1ce3115742 (diff) |
*update
-rw-r--r-- | bin/Jin.exe | bin | 498176 -> 479744 bytes | |||
-rw-r--r-- | bin/jin.exe | bin | 498176 -> 479744 bytes | |||
-rw-r--r-- | bin/main.lua | 3 | ||||
-rw-r--r-- | bin/metaball.shader | 2 | ||||
-rw-r--r-- | src/libjin/Graphics/Font.cpp | 1 | ||||
-rw-r--r-- | src/libjin/Math/Matrix.cpp | 4 | ||||
-rw-r--r-- | src/libjin/math/matrix.cpp | 4 |
7 files changed, 6 insertions, 8 deletions
diff --git a/bin/Jin.exe b/bin/Jin.exe Binary files differindex ba89bf2..7c364e0 100644 --- a/bin/Jin.exe +++ b/bin/Jin.exe diff --git a/bin/jin.exe b/bin/jin.exe Binary files differindex ba89bf2..7c364e0 100644 --- a/bin/jin.exe +++ b/bin/jin.exe diff --git a/bin/main.lua b/bin/main.lua index f4e586a..2a9ee22 100644 --- a/bin/main.lua +++ b/bin/main.lua @@ -5,7 +5,6 @@ local img2 local canvas local sw, sh = jin.graphics.getSize() local page -local fontdata local font function jin.core.onLoad() @@ -20,7 +19,7 @@ function jin.core.onLoad() img = jin.graphics.newTexture(bitmap2) canvas = jin.graphics.newCanvas(200, 100) - fontdata = jin.graphics.newFontData("font.ttf") + local fontdata = jin.graphics.newFontData("font.ttf") font = fontdata:newFont(15) local str = jin.filesystem.read("text.txt") page = font:typeset(str, 17, 0) diff --git a/bin/metaball.shader b/bin/metaball.shader index 7d3b759..67be889 100644 --- a/bin/metaball.shader +++ b/bin/metaball.shader @@ -21,4 +21,4 @@ Color frag(Color col, Texture tex, Vertex v) return c; } -#END_FRAGMENT_SHADER
\ No newline at end of file +#END_FRAGMENT_SHADER diff --git a/src/libjin/Graphics/Font.cpp b/src/libjin/Graphics/Font.cpp index a3a46dd..72be567 100644 --- a/src/libjin/Graphics/Font.cpp +++ b/src/libjin/Graphics/Font.cpp @@ -49,7 +49,6 @@ namespace graphics /* little endian unicode */ static const char* unicodeLittleEndian(const char* p, unsigned* res) { - } /*static*/ Font* Font::createFont(FontData* fontData, unsigned int fontSzie) diff --git a/src/libjin/Math/Matrix.cpp b/src/libjin/Math/Matrix.cpp index a80f37a..a6e2491 100644 --- a/src/libjin/Math/Matrix.cpp +++ b/src/libjin/Math/Matrix.cpp @@ -26,10 +26,10 @@ namespace math void Matrix::setOrtho(float l, float r, float b, float t, float n, float f) { - float w = r - l; + setIdentity(); + float w = r - l; float h = t - b; float z = f - n; - setIdentity(); e[0] = 2 / w; e[5] = 2 / h; e[10] = -2 / z; diff --git a/src/libjin/math/matrix.cpp b/src/libjin/math/matrix.cpp index a80f37a..a6e2491 100644 --- a/src/libjin/math/matrix.cpp +++ b/src/libjin/math/matrix.cpp @@ -26,10 +26,10 @@ namespace math void Matrix::setOrtho(float l, float r, float b, float t, float n, float f) { - float w = r - l; + setIdentity(); + float w = r - l; float h = t - b; float z = f - n; - setIdentity(); e[0] = 2 / w; e[5] = 2 / h; e[10] = -2 / z; |