[Mesa-dev] [PATCH 1/4] i965/fs: Use sample interpolation for interpolateAtCentroid in persample mode

Kenneth Graunke kenneth at whitecape.org
Thu Sep 15 18:58:03 UTC 2016


On Wednesday, September 14, 2016 10:45:24 AM PDT Jason Ekstrand wrote:
> From the ARB_gpu_shader5 spec:
> 
>    The built-in functions interpolateAtCentroid() and interpolateAtSample()
>    will sample variables as though they were declared with the "centroid"
>    or "sample" qualifiers, respectively.
> 
> When running with persample dispatch forced by the API, we interpolate
> anything that isn't flat as if it's qualified by "sample".  In order to
> keep interpolateAtCentroid() consistent with the "centroid" qualifier, we
> need to make interpolateAtCentroid() do sample interpolation instead.
> Nothing in the GLSL spec guarantees that the result of
> interpolateAtCentroid is uniform across samples in any way, so this is a
> perfectly fine thing to do.
> 
> Fixes 8 of the new dEQP-VK.pipeline.multisample_interpolation.* Vulkan CTS
> tests that specifically validate consistency between the "sample" qualifier
> and interpolateAtSample()
> 
> Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
> ---
>  src/mesa/drivers/dri/i965/brw_fs.cpp | 26 ++++++++++++++++++++++++++
>  1 file changed, 26 insertions(+)

Series is:
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: This is a digitally signed message part.
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160915/713f99ed/attachment.sig>


More information about the mesa-dev mailing list