[Solved] <BFace>{ 1 } behaviour changed?


I noticed a change in the way polygons with the { 1 } attribute are treated between Panda 1.7.1 and Panda 1.8.0.
In both cases they are rendered the same way (correctly), but in 1.8.0 the GeomTriangles primitive has now twice as many triangles as before.

For instance, the exact same egg that has 100 triangles in Panda 1.7.1 now has 200 triangles in Panda 1.8.0.

Is that an intentional change?


Yes, it was intentional. Generally, on modern hardware, the additional vertices will actually render faster than the original version with fewer vertices, because it involves one fewer state change. Also, the new approach works better in the presence of lighting. Of course the specific performance comparison depend on the precise nature of your scene and the hardware.

The change was only a change to the default setting of a config variable. If you set:

egg-emulate-bface 0

you will get the old behavior again. (Note that you may have to empty your cache to force the egg files to reload with the new setting.


Many thanks for your answer, perfectly clear!