[osg-users] Mirror transformation

Gianluca Natale natale at europe.altair.com
Wed Sep 13 08:19:45 PDT 2017


IMO, it happens that, because of the mirror transformation (i.e. a negative scale factor in the global transformation),
back facets do appear as front facets on the projection plane, and viceversa.
And because of the 2-sided model lighting, normals are reverted when rendering the front facets (as they appear as back facets).
It should be fixed by reverting the front face definition for object transformed by the mirror transform.
I mean, I would apply a state set to that mirror transformation with this state attribute:

osg::FrontFace(CLOCKWISE);

It worked for me for a similar issue I had in the past.

Gianluca
 

-----Original Message-----
From: osg-users [mailto:osg-users-bounces at lists.openscenegraph.org] On Behalf Of Ale Maro
Sent: Wednesday, September 13, 2017 4:23 PM
To: osg-users at lists.openscenegraph.org
Subject: Re: [osg-users] Mirror transformation

I forgot to mention that the geode inherit from the root node a 2-sided lighting with different materials in front and back side.

Cheers,
Ale

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=71707#71707





_______________________________________________
osg-users mailing list
osg-users at lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


More information about the osg-users mailing list