Hi Ben,

If there are modes in your scene graph that enable lighting then
you'll get the default OpenGL lighting values.  You don't say what
effect you actually want to achieve so can't comment on what you
should do in your scene graph, you'll need to provide more info.

FYI, Viewer "is a" View, so you only need to do _viewer->setLightingMode(..);

Robert.

On Tue, Feb 17, 2009 at 4:35 PM, Ben Axelrod <[email protected]> wrote:
> I cannot seem to turn off the light in osg::View.  I can change it between
> headlight and sky light, but when I try NO_LIGHT, I still get the headlight.
>
>
>
> _viewer->getCamera()->getView()->setLightingMode(osg::View::SKY_LIGHT);
> //works
>
>
>
> _viewer->getCamera()->getView()->setLightingMode(osg::View::HEADLIGHT);
> //works
>
>
>
> _viewer->getCamera()->getView()->setLightingMode(osg::View::NO_LIGHT);
> //still get headlight
>
>
>
> How can I turn off this default light?  How is it related to the osg::Lights
> in the scene?  I noticed when I add an osg::Light, then the headlight is
> overridden.  How can I change the light parameters of the SKY_LIGHT or
> HEADLIGHT?
>
>
>
> I am using osg version 2.6.
>
>
>
> Thanks,
>
> -Ben
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to