1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:27:35 +00:00

LibSoftGPU: Remove OpenGL type for culled side selection

Replaces the GLenum in RasterizerConfig, that selects the triangle sides
to be culled, with two booleans.
This commit is contained in:
Stephan Unverwerth 2021-12-22 23:23:15 +01:00 committed by Brian Gianforcaro
parent 24c76741e8
commit 1904be0370
3 changed files with 6 additions and 4 deletions

View file

@ -917,7 +917,8 @@ void SoftwareGLContext::gl_cull_face(GLenum cull_mode)
m_culled_sides = cull_mode;
auto rasterizer_options = m_rasterizer.options();
rasterizer_options.culled_sides = cull_mode;
rasterizer_options.cull_back = cull_mode == GL_BACK || cull_mode == GL_FRONT_AND_BACK;
rasterizer_options.cull_front = cull_mode == GL_FRONT || cull_mode == GL_FRONT_AND_BACK;
m_rasterizer.set_options(rasterizer_options);
}