mirror of
https://github.com/open-goal/jak-project.git
synced 2024-11-23 22:29:53 +00:00
[jak2] fix glow sprite flickering (#2912)
oops, forgot to set `glDepthMask`, so sometimes it was enabled, and the drawing for the clear was writing into the depth buffer. Fixes https://github.com/open-goal/jak-project/issues/2735
This commit is contained in:
parent
df1b0a341c
commit
5c00f1abe1
@ -539,6 +539,8 @@ void GlowRenderer::draw_probes(SharedRenderState* render_state,
|
|||||||
glBindVertexArray(m_ogl.vao);
|
glBindVertexArray(m_ogl.vao);
|
||||||
glEnable(GL_PRIMITIVE_RESTART);
|
glEnable(GL_PRIMITIVE_RESTART);
|
||||||
glPrimitiveRestartIndex(UINT32_MAX);
|
glPrimitiveRestartIndex(UINT32_MAX);
|
||||||
|
// don't want to write to the depth buffer we just copied, just test against it.
|
||||||
|
glDepthMask(GL_FALSE);
|
||||||
GLint old_viewport[4];
|
GLint old_viewport[4];
|
||||||
glGetIntegerv(GL_VIEWPORT, old_viewport);
|
glGetIntegerv(GL_VIEWPORT, old_viewport);
|
||||||
glViewport(0, 0, m_ogl.probe_fbo_w, m_ogl.probe_fbo_h);
|
glViewport(0, 0, m_ogl.probe_fbo_w, m_ogl.probe_fbo_h);
|
||||||
|
Loading…
Reference in New Issue
Block a user