Paul Berry <stereotype...@gmail.com> writes: > On 22 August 2012 12:35, Eric Anholt <e...@anholt.net> wrote: > >> Paul Berry <stereotype...@gmail.com> writes: >> >> > Previously, when performing a fast depth clear, we would also clear >> > the miptree's resolve map. This destroyed important information, >> > since the resolve map contains information about needed resolves for >> > all levels and layers of the miptree, whereas a depth clear only >> > applies to a single level/layer combination at a time. As a result, >> > resolves would sometimes fail to occur, leading to incorrect >> > rendering. >> > >> > Fixes rendering artifacts with shadow maps in Unigine Heaven and >> > Unigine Sanctuary. >> >> Nice catch! >> >> However, isn't the issue really that we're incorrectly setting >> needs_depth_resolve on layers/levels of the referenced mt that we're not >> actually changing hiz state for, since they didn't get cleared? It >> seems like this fixes the current issue, but leaves that bug in place. >> > > No, those other layers of the miptree really did need a depth resolve, > because they were previously cleared and then rendered to. The complete > sequence of operations performed by the Unigine engine in the bug looks > like this:
Yeah, I had misread the resolve code in place while insufficiently awake (I thought we were setting our new resolve flag on all layers, not just the one referenced by the rb). Not clearing all resolve flags for other layers is obviously a requirement. I'm ambivalent about losing the assertion, since it caught a bug for Chad apparently, but it looks like a good series in that it fixes the bug. Reviewed-by: Eric Anholt <e...@anholt.net>
pgpEJJjqZl8t8.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev