[Maya2osg-users] Winding again!
Status: Alpha
Brought to you by:
jtaibo
From: Jean-Sébastien G. <jea...@cm...> - 2011-10-18 16:26:35
|
Hi guys, I think I found the case where winding will affect surfaces. An object scaled by -1 will have its normals inverted and winding will be inverted too. Maya sets the "opposite" mode on this. It makes it look OK in Maya. If, in the plugin, I set "flip normals if surface mode is opposite", then the plugin will invert the normals (* -1) but the winding will still be wrong, so they will be culled by CULL_FACE even though lighting is correct. If I reverse the normals in Maya, my guess is that Maya also reverses winding, because then all is OK. So I think the plugin should warn when the surface mode is set to opposite AND single sided, as that will not work unless triangle winding is reversed (which is maybe too complex for an export plugin to do). At least with a warning artists can see there is a problem and fix it on the affected surfaces. If the data is wrong, fix the data! :-) Thanks, J-S -- ______________________________________________________ Jean-Sébastien Guay jea...@cm... http://www.cm-labs.com/ http://whitestar02.dyndns-web.com/ |