[Mesa-dev] depth writing and missing something

Dave Airlie airlied at gmail.com
Wed Sep 29 18:34:10 PDT 2010


So I've been playing with stencil writing on r600, and it lead me to
examine the depth writing.

So at the moment in gallium if we are writing to depth via DrawPixels,
we construct a fragment program that samples from a texture.

TEX OUT[0].z, IN[1], SAMP[0], 2D

Now from what I can see the format we pick to sample from is
Z24_UNORM_S8_USCALED, which from the u_format.csv file seems to say it
will put the results into X and Y components. Now if we sample from
the X and Y components and the texture dest writemask is Z, I can't
see how any value arrives in the right place. It seems to work but I'm
a bit lost where the magic is.

I'd have expected there to be swizzles in the sampler but I can't see
them being set to anything special either.

Dave.


More information about the mesa-dev mailing list