v3d_line_smoothing_enabled(v3d) ?
V3D_LINE_RASTERIZATION_PERP_END_CAPS :
V3D_LINE_RASTERIZATION_DIAMOND_EXIT;
- }
+#if V3D_VERSION >= 71
+ /* The following follows the logic implemented in v3dv
+ * plus the definition of depth_clip_near/far and
+ * depth_clamp.
+ *
+ * Note: some extensions are not supported by v3d
+ * (like ARB_depth_clamp) that would affect this, but
+ * the values on rasterizer are taking that into
+ * account.
+ */
+ config.z_clipping_mode = v3d->rasterizer->base.depth_clip_near ||
+ v3d->rasterizer->base.depth_clip_far ?
+ V3D_Z_CLIP_MODE_MIN_ONE_TO_ONE : V3D_Z_CLIP_MODE_NONE;
+#endif
+ }
}
if (v3d->dirty & V3D_DIRTY_RASTERIZER &&