From fc7b4579e49aaeecc81919e247e03f68bd5abfd4 Mon Sep 17 00:00:00 2001 From: chai Date: Sun, 18 Nov 2018 22:32:55 +0800 Subject: =?UTF-8?q?*=E7=B2=92=E5=AD=90=E7=B3=BB=E7=BB=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/libjin/Graphics/je_gl.h | 65 ++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 61 insertions(+), 4 deletions(-) (limited to 'src/libjin/Graphics/je_gl.h') diff --git a/src/libjin/Graphics/je_gl.h b/src/libjin/Graphics/je_gl.h index fba62a1..134cfee 100644 --- a/src/libjin/Graphics/je_gl.h +++ b/src/libjin/Graphics/je_gl.h @@ -4,16 +4,22 @@ #include #include "../math/je_matrix.h" +#include "../math/je_transform.h" -#include "je_color.h" #include "GLee/GLee.h" #include "ogl/OpenGL.h" +#include "je_color.h" + namespace JinEngine { namespace Graphics { + /*class Canvas; + class Shader; + class Font; +*/ class OpenGL : public ogl2d::OpenGL { @@ -41,6 +47,11 @@ namespace JinEngine void pop(); + /// + /// + /// + Math::Matrix getModelViewMatrix(const Math::Transform& tansform); + /// /// Get model view matrix. /// @@ -61,17 +72,63 @@ namespace JinEngine /// const Math::Matrix& getProjectionMatrix(); - private: + /// + /// + /// + void useShader(); - void solve(); + /// + /// + /// + void useFont(); - Color mCurrentColor; + /// + /// + /// + void useCanvas(); + + /// + /// + /// + void unUseShader(); + + private: + /// + /// + /// std::vector mModelViewMatrices; + + /// + /// + /// Math::Matrix mModelViewMatrix; + /// + /// + /// Math::Matrix mProjectionMatrix; + /// + /// + /// + Color mCurrentColor; +/* + /// + /// + /// + Canvas* mCurrentCanvas; + + /// + /// + /// + Shader* mCurrentShader; + + /// + /// + /// + Font* mCurrentFont; +*/ }; // Singleton. -- cgit v1.1-26-g67d0