Page 1 of 1
Posted: 21 Mar 2015, 23:17
sebr
I already sent a PM to Jig to explain that old bug (from original revolt 1.0)

Look a normal race :

Texture is ok and pink colors for shadow too

Now in mirored race :

pink colors are straingely mixed

If you look carefully you can see it at EVERY revolt tracks

Posted: 22 Mar 2015, 05:00
jigebren
Ok, thanks to your PM I could get it. Otherwise... ^_^

So the issue is the shadow of the roof on the pink wall around the basketball hoop. The gradient looks nice in normal mode, but is broken in mirrored mode. And as you've found out by yourself this has to do with quads vertex color.

A quad being internally composed of two triangles for DirectX, it appears that the triangle orientation is inverted in mirrored mode. In case the vertices have been assigned different vertex color, it will no longer give the expected gradient.

If we have this quad, with white "W" vertices except the top-left vertex set to black "B":

Code: Select all

B---W
|   |
|   |
|   |
W---W
According to the internal triangle orientation this can led to two different results (the left one being the expected one). I've marked with "G" the 50% grey middle points.

Code: Select all

Good:    Bad:
B-G-W    B-G-W
|G /|    |\  |
G / |    G G |
|/  |    |  \|
W---W    W---W
Don't know yet if we can easily do something about it. I presume not only the world but also models could be affected maybe? We'll check and let you know (but this should not be in the upcoming v1.2 release anyway).

Posted: 23 Mar 2015, 06:15
jigebren
This has been fixed. Thanks Sebr for finding it and for the efficient (French) report. The same issue was also possible not only for world but for models too (not sure there's already case where we can notice it though), it's fixed as well.

BTW it was the opportunity to clean up an old fix for TexAnim issue with triangle faces in mirrored mode now that the whole code use a more efficient trick...

Since we're started freezing the change already I'm not sure we will merge it for the upcoming release (but this is not a major bug anyway).

Posted: 24 Mar 2015, 00:28
sebr
cool now mirrored races will be as good looking as normal race :D