[osg-users] Absolutely dark scene

Robert Osfield robert.osfield at gmail.com
Tue Mar 17 03:10:09 PDT 2009


Hi Fernan,

On Tue, Mar 17, 2009 at 10:00 AM, Fernan <osgforum at tevs.eu> wrote:

> first of all a greeting to everyone, because I'm new around here.
>
> I am developing an application that need to be done at night and become
> completely dark scene, but I can not.
>
> I do not know how to remove the whole lighting of the scene, it is made at
> night, but there is always some light.
>
> How can I create a totally dark scene?
>

The viewer by default has a headlight and enables the OpenGL light 0.  In
your case you'll likely want to add an osg::LightSource node to your scene
with the light settings that are appropriate for you scene.  This
LightSource will position the light in the 3D world, as well as control the
diffude, ambient etc. light settings.  See the osglightsource example.

Robert.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20090317/d9db1882/attachment-0003.htm>


More information about the osg-users mailing list