mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 18:20:43 +09:00
LibGL: Set W-coordinate to 1 in glRect*
According to the spec, these calls should be identical to an invocation of `glVertex2*`, which sets the W-coordinate to 1 by default. This fixes the credits sequence rendering of Tux Racer.
This commit is contained in:
parent
e1a6966863
commit
65d4fb7649
Notes:
sideshowbarker
2024-07-17 11:39:47 +09:00
Author: https://github.com/gmta
Commit: 65d4fb7649
Pull-request: https://github.com/SerenityOS/serenity/pull/13738
Reviewed-by: https://github.com/sunverwerth ✅
3 changed files with 36 additions and 18 deletions
|
@ -2878,10 +2878,10 @@ void GLContext::gl_rect(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
|
|||
RETURN_WITH_ERROR_IF(m_in_draw_state, GL_INVALID_OPERATION);
|
||||
|
||||
gl_begin(GL_POLYGON);
|
||||
gl_vertex(x1, y1, 0.0, 0.0);
|
||||
gl_vertex(x2, y1, 0.0, 0.0);
|
||||
gl_vertex(x2, y2, 0.0, 0.0);
|
||||
gl_vertex(x1, y2, 0.0, 0.0);
|
||||
gl_vertex(x1, y1, 0.0, 1.0);
|
||||
gl_vertex(x2, y1, 0.0, 1.0);
|
||||
gl_vertex(x2, y2, 0.0, 1.0);
|
||||
gl_vertex(x1, y2, 0.0, 1.0);
|
||||
gl_end();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue