LibGL: Set correct matrices in glFrustum
and glOrtho
We were erroneously setting the projection matrix when `GL_MODELVIEW` was supplied.
This commit is contained in:
parent
5cf967e4f2
commit
d905de6a7a
Notes:
sideshowbarker
2024-07-18 03:35:30 +09:00
Author: https://github.com/gmta Commit: https://github.com/SerenityOS/serenity/commit/d905de6a7a Pull-request: https://github.com/SerenityOS/serenity/pull/12695 Reviewed-by: https://github.com/Quaker762 ✅ Reviewed-by: https://github.com/linusg ✅ Reviewed-by: https://github.com/sunverwerth ✅
1 changed files with 2 additions and 2 deletions
|
@ -401,7 +401,7 @@ void SoftwareGLContext::gl_frustum(GLdouble left, GLdouble right, GLdouble botto
|
|||
if (m_current_matrix_mode == GL_PROJECTION)
|
||||
m_projection_matrix = m_projection_matrix * frustum;
|
||||
else if (m_current_matrix_mode == GL_MODELVIEW)
|
||||
m_projection_matrix = m_model_view_matrix * frustum;
|
||||
m_model_view_matrix = m_model_view_matrix * frustum;
|
||||
else if (m_current_matrix_mode == GL_TEXTURE)
|
||||
m_texture_matrix = m_texture_matrix * frustum;
|
||||
else
|
||||
|
@ -432,7 +432,7 @@ void SoftwareGLContext::gl_ortho(GLdouble left, GLdouble right, GLdouble bottom,
|
|||
if (m_current_matrix_mode == GL_PROJECTION)
|
||||
m_projection_matrix = m_projection_matrix * projection;
|
||||
else if (m_current_matrix_mode == GL_MODELVIEW)
|
||||
m_projection_matrix = m_model_view_matrix * projection;
|
||||
m_model_view_matrix = m_model_view_matrix * projection;
|
||||
else if (m_current_matrix_mode == GL_TEXTURE)
|
||||
m_texture_matrix = m_texture_matrix * projection;
|
||||
else
|
||||
|
|
Loading…
Add table
Reference in a new issue