Am 07.05.2014 17:56, schrieb Marek Olšák:
> I could enable interpolation of gl_FragCoord at the sample instead of
> centroid and do:
>
> gl_SamplePos = fract(gl_FragCoord.xy);
> gl_FragCoord.xy = floor(gl_FragCoord.xy) + vec2(0.5); // center
>
> However, I wouldn't be able to get gl_FragCoord at
It's a pseudo-code that would be inserted at the beginning of the
shader by the shader compiler. gl_SamplePos is always read-only from a
user's point of view.
Marek
On Wed, May 7, 2014 at 6:02 PM, Ilia Mirkin wrote:
> On Wed, May 7, 2014 at 11:56 AM, Marek Olšák wrote:
>> I could enable interpo
On Wed, May 7, 2014 at 11:56 AM, Marek Olšák wrote:
> I could enable interpolation of gl_FragCoord at the sample instead of
> centroid and do:
>
> gl_SamplePos = fract(gl_FragCoord.xy);
Is that legal? I didn't think that sample position could be an output,
at least not with ARB_sample_shading (an
I could enable interpolation of gl_FragCoord at the sample instead of
centroid and do:
gl_SamplePos = fract(gl_FragCoord.xy);
gl_FragCoord.xy = floor(gl_FragCoord.xy) + vec2(0.5); // center
However, I wouldn't be able to get gl_FragCoord at the centroid.
I'm also not sure how gl_FragCoord should
On Wed, May 7, 2014 at 10:00 AM, Marek Olšák wrote:
> From: Marek Olšák
>
> The sample positions are read from a constant buffer.
FWIW I had to do the same thing in both nv50 and nvc0. I had proposed
that this should actually be done directly by the state tracker, but I
think claims were made to
From: Marek Olšák
The sample positions are read from a constant buffer.
---
src/gallium/drivers/radeon/cayman_msaa.c | 17 +
src/gallium/drivers/radeon/r600_pipe_common.c | 1 +
src/gallium/drivers/radeon/r600_pipe_common.h | 10 ++
src/gallium/drivers/radeonsi/si_s