Ben,

osg::View's setLightingMode with NO_LIGHT as a parameter doesn't actually
turn any lights off (just look at the source in osg/View.cpp). If the
lightingMode is *not* NO_LIGHT, then it sets light 0 with the default 0.8
diffuse value etc. I presume this is by design, although I'm not sure why!

Actually, this is all a bit confusing. For example, SceneView sets a global
ambient light model that you have to "suppress" after the fact.

Similarly, I notice that osg/View has LightingMode as enum {NO_LIGHT,
HEADLIGHT, SKY_LIGHT}, whereas SceneView has enum Options {
NO_SCENEVIEW_LIGHT = 0x0, HEADLIGHT = 0x1, SKY_LIGHT = 0x2}, which looks a
little bit... random... to me if any default conversion between the enums is
done. However a quick trawl through SceneView looks okay (LightingMode in
SceneView is typedef'd to Options).

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

Reply via email to