mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 13:49:16 +00:00
LibGL: Implement glNormal3f
and glNormal3fv
This commit is contained in:
parent
ea6bcda79c
commit
78d0674228
Notes:
sideshowbarker
2024-07-17 22:51:54 +09:00
Author: https://github.com/gmta
Commit: 78d0674228
Pull-request: https://github.com/SerenityOS/serenity/pull/11154
Reviewed-by: https://github.com/sunverwerth ✅
6 changed files with 27 additions and 1 deletions
|
@ -514,6 +514,7 @@ void SoftwareGLContext::gl_vertex(GLdouble x, GLdouble y, GLdouble z, GLdouble w
|
|||
vertex.position = { static_cast<float>(x), static_cast<float>(y), static_cast<float>(z), static_cast<float>(w) };
|
||||
vertex.color = m_current_vertex_color;
|
||||
vertex.tex_coord = { m_current_vertex_tex_coord.x(), m_current_vertex_tex_coord.y() };
|
||||
vertex.normal = m_current_vertex_normal;
|
||||
|
||||
vertex_list.append(vertex);
|
||||
}
|
||||
|
@ -2240,6 +2241,13 @@ void SoftwareGLContext::gl_stencil_op_separate(GLenum face, GLenum sfail, GLenum
|
|||
m_stencil_backfacing_op = new_options;
|
||||
}
|
||||
|
||||
void SoftwareGLContext::gl_normal(GLfloat nx, GLfloat ny, GLfloat nz)
|
||||
{
|
||||
APPEND_TO_CALL_LIST_AND_RETURN_IF_NEEDED(gl_normal, nx, ny, nz);
|
||||
|
||||
m_current_vertex_normal = { nx, ny, nz };
|
||||
}
|
||||
|
||||
void SoftwareGLContext::present()
|
||||
{
|
||||
m_rasterizer.blit_to(*m_frontbuffer);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue