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

LibGL: Implement glPolygonOffset

This commit is contained in:
Stephan Unverwerth 2021-08-31 20:50:01 +02:00 committed by Ali Mohammad Pur
parent 7cbaaf8366
commit 15299b763c
7 changed files with 26 additions and 1 deletions

View file

@ -269,6 +269,9 @@ static void rasterize_triangle(const RasterizerOptions& options, Gfx::Bitmap& re
z = options.depth_min + (options.depth_max - options.depth_min) * (z + 1) / 2;
// FIXME: Also apply depth_offset_factor which depends on the depth gradient
z += options.depth_offset_constant * NumericLimits<float>::epsilon();
bool pass = false;
switch (options.depth_func) {
case GL_ALWAYS: