diff options
author | Jelle Raaijmakers <jelle@gmta.nl> | 2021-12-01 15:33:23 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-12-12 21:51:08 +0100 |
commit | 78d06742284d52862e2aabb7cf83ae8b9cf9e237 (patch) | |
tree | ae9f90603af6e9def74fa7eda37170ff792dc398 /Userland/Libraries/LibGL/SoftwareGLContext.h | |
parent | ea6bcda79c81f6dccfa034160933ab23f1a0ade0 (diff) | |
download | serenity-78d06742284d52862e2aabb7cf83ae8b9cf9e237.zip |
LibGL: Implement `glNormal3f` and `glNormal3fv`
Diffstat (limited to 'Userland/Libraries/LibGL/SoftwareGLContext.h')
-rw-r--r-- | Userland/Libraries/LibGL/SoftwareGLContext.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Userland/Libraries/LibGL/SoftwareGLContext.h b/Userland/Libraries/LibGL/SoftwareGLContext.h index f5805a3dfa..335ed640e9 100644 --- a/Userland/Libraries/LibGL/SoftwareGLContext.h +++ b/Userland/Libraries/LibGL/SoftwareGLContext.h @@ -104,6 +104,7 @@ public: virtual void gl_scissor(GLint x, GLint y, GLsizei width, GLsizei height) override; virtual void gl_stencil_func_separate(GLenum face, GLenum func, GLint ref, GLuint mask) override; virtual void gl_stencil_op_separate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass) override; + virtual void gl_normal(GLfloat nx, GLfloat ny, GLfloat nz) override; virtual void present() override; private: @@ -143,6 +144,7 @@ private: double m_clear_depth = { 1.0 }; FloatVector4 m_current_vertex_color = { 1.0f, 1.0f, 1.0f, 1.0f }; FloatVector4 m_current_vertex_tex_coord = { 0.0f, 0.0f, 0.0f, 0.0f }; + FloatVector3 m_current_vertex_normal = { 0.0f, 0.0f, 1.0f }; Vector<GLVertex, 96> vertex_list; Vector<GLTriangle, 32> triangle_list; @@ -266,7 +268,8 @@ private: decltype(&SoftwareGLContext::gl_polygon_offset), decltype(&SoftwareGLContext::gl_scissor), decltype(&SoftwareGLContext::gl_stencil_func_separate), - decltype(&SoftwareGLContext::gl_stencil_op_separate)>; + decltype(&SoftwareGLContext::gl_stencil_op_separate), + decltype(&SoftwareGLContext::gl_normal)>; using ExtraSavedArguments = Variant< FloatMatrix4x4>; |