Page 1 of 1

Render depth to texture suffering Moiré pattern artefact

Posted: Sat Jul 05, 2014 11:13 am
by robmar
I´m rendering the scene depth to a RTT using the standard shader method to get a greyscale of the depth.

If I use it rendering to the standard frame buffer it works perfectly.

But if I render it to a RTT then I see this sort of moiré pattern, a splattering of pixels that have a very high depth level that move together as I spin the view or model.

I´ve spent hours going through everything but can´t find why the same shader used on an RTT causes this artefact.

Is this a known issue?

Re: Render depth to texture suffering Moiré pattern artefact

Posted: Fri Jul 25, 2014 1:14 am
by vectorcorpse
did u create a 32 bit float texture for the RTT and pass the data has float? if not u'll lose depth resolution since only int's will get stored on the texture.

Re: Render depth to texture suffering Moiré pattern artefact

Posted: Fri Jul 25, 2014 5:00 am
by robmar
Yes exactly, that worked well!