lima: Remove depth near/far workaround
authorAndreas Baierl <ichgeh@imkreisrum.de>
Mon, 20 Sep 2021 15:07:00 +0000 (17:07 +0200)
committerMarge Bot <eric+marge@anholt.net>
Tue, 21 Sep 2021 08:54:53 +0000 (08:54 +0000)
because this is fixed now.

Reviewed-by: Erico Nunes <nunes.erico@gmail.com>
Signed-off-by: Andreas Baierl <ichgeh@imkreisrum.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12804>

src/gallium/drivers/lima/lima_draw.c

index c0a0ba6..120148a 100644 (file)
@@ -656,15 +656,6 @@ lima_pack_render_state(struct lima_context *ctx, const struct pipe_draw_info *in
    near = float_to_ushort(ctx->viewport.near);
    far = float_to_ushort(ctx->viewport.far);
 
-   /* Insert a small 'epsilon' difference between 'near' and 'far' when
-    * they are equal, to avoid application bugs. */
-   if (far == near) {
-      if (near > 0)
-         near--;
-      if (far < USHRT_MAX)
-         far++;
-   }
-
    /* overlap with plbu? any place can remove one? */
    render->depth_range = near | (far << 16);