[Mesa-dev] [Bug 97231] GL_DEPTH_CLAMP doesn't clamp to the far plane

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sat Aug 6 21:15:27 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=97231

            Bug ID: 97231
           Summary: GL_DEPTH_CLAMP doesn't clamp to the far plane
           Product: Mesa
           Version: unspecified
          Hardware: x86-64 (AMD64)
                OS: Linux (All)
            Status: NEW
          Severity: major
          Priority: medium
         Component: Mesa core
          Assignee: mesa-dev at lists.freedesktop.org
          Reporter: jules.blok at gmail.com
        QA Contact: mesa-dev at lists.freedesktop.org

Created attachment 125579
  --> https://bugs.freedesktop.org/attachment.cgi?id=125579&action=edit
apitrace file to reproduce the problem

On both the Intel drivers and the software rasterizer (llvm) GL_DEPTH_CLAMP
doesn't properly clamp to the far plane as specified. It seems that it clamps
the depth value written to the depth buffer to 1.0 instead.

According to the specs:
https://www.opengl.org/registry/specs/ARB/depth_clamp.txt

    The one major issue is that fragments of a  primitive may extend
    beyond the conventional window space depth range for depth values
    (typically the range [0,1]).  Rather than discarding fragments that
    defy the window space depth range (effectively what near and far
    plane clipping accomplish), the depth values can be clamped to the
    current depth range.

I've attached an apitrace to reproduce the problem.

Expected output:
https://fifoci.dolphin-emu.org/media/results/a09836d8de0911b9c6bdceffe64561a54cd988e9.png

Actual output:
https://fifoci.dolphin-emu.org/media/results/565273f42d550e19b9b83921f177e4a898bbd5e6.png

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160806/2ac3564d/attachment.html>


More information about the mesa-dev mailing list