5 //---------------------- Groups ---------------------
7 /*! \defgroup GrpSystemWindow Window
10 The Window group contains everything related to the actual windows where the
11 final rendered image is shown. This includes all the different partsnecessary
12 to set up a window like Cameras Viewports, Forgrounds and Backgrounds.
14 See \ref PageSystemWindow for a description.
17 /*! \defgroup GrpSystemWindowForegrounds Foregrounds
18 \ingroup GrpSystemWindow
20 Foregrounds are used to add information after the viewport is rendered.
22 See \ref PageSystemWindowForegrounds for a description.
25 /*! \defgroup GrpSystemWindowCameras Cameras
26 \ingroup GrpSystemWindow
28 The Camera group includes all the Camera and camera enhancement objects.
30 See \ref PageSystemWindowCamera for a description.
33 /*! \defgroup GrpSystemWindowCameraDecorators Camera Decorators
34 \ingroup GrpSystemWindowCameras
36 The Camera Decorators group includes all the Camera Decorators for camera
39 See \ref PageSystemWindowCameraDecorators for a description.
42 /*! \defgroup GrpSystemWindowCameraDecoratorsStereo Stereo Camera Decorators
43 \ingroup GrpSystemWindowCameraDecorators
45 Camera Decorators group including the decorators needed to generate left/right
46 image pairs for three-dimensional stereo display.
48 See \ref PageSystemWindowCameraDecoratorsStereo for a description.
51 /*! \defgroup GrpSystemWindowViewports Viewports
52 \ingroup GrpSystemWindow
54 Viewports define how parts of the actual window are rendered, allowing
55 splitting up Windows into smaller parts for rendering.
57 See \ref PageSystemWindowViewports for a description.
60 /*! \defgroup GrpSystemWindowNavigators Navigators
61 \ingroup GrpSystemWindow
63 Navigators are helper classes to map mouse or keyboard events to manipulations
66 See \ref PageSystemWindowNavigators for a description.
70 //---------------------- Pages ---------------------
73 /*! \page PageSystemWindow Window
75 \latexonly Starter:NewChapter \endlatexonly
77 Windows are the general connection between OpenSG and the windowing system
78 used by the application/platform. OpenSG itself does not open its own windows,
79 that has to be done by the application. Using GLUT it's pretty trivial, take a
80 look at the tutorial examples on how to do that. For other window systems its
81 a little more work, but the goal is to have wrapper classes for the usual GUI
82 toolkits like QT, Motif etc. that simplify the task. We have one for QT,
83 OSGQGLManagedWidget, and are interested in similar ones for other Window
86 \section PageSystemWindowWindow Window
88 A osg::Window is the connection between OpenSG and the window system used.
89 There are variants for different supported window systems like X, WIN32, GLUT
90 and QT. The OpenSG Window object handles OpenGL context creation and
91 activation/deactivation, and needs to be informed about resizes. It manages
92 OpenGL objects like display lists and texture objects and is also responsible
93 for OpenGL extension detection and functions.
95 It doesn't do any input event handling or similar things, it's only for output
96 and keeping the osg::Viewport instances that fill the window and keep all the
97 rendering parameters. See \ref PageSystemWindowSimpleSceneManager for an
98 easy-to-use wrapper for setting these up.
100 There should be a 1:1 relation between an osg::Window and a window-system
101 window. As such the osg::Window is responsible for handlng the OpenGL related
102 tasks such as OpenGL object and extensions management (see \ref
103 PageSystemOGLObjects for details on that).
105 \subsection PageSystemWindowWindowPassive Passive Window
107 The osg::PassiveWindow is a helper class for integration into other OpenGL
108 programs. It does not manage its own OpenGL context, it expects the context to
109 be active whenever it is called. It also ignores swap commands, as these are
110 window system-specific. Thus the osg::PassiveWindow can be used in any window
111 system and GUI system to simplify integration. If the same OpenGL context is
112 active whenever it is initialised/called it will work nicely.
114 \section PageSystemWindowViewports Viewport
116 A osg::Viewport is a part of the window that is being rendered into. It can cover
117 the whole window, but doesn't have to. Every Window can handle an arbitrary
118 number of viewports, e.g. to allow the typical front/left/right/perspective
119 views in a single window. Every osg::Viewport can only be attached to one
122 The size of the viewport is defined by its left, right, bottom and top
123 coordinates, given in OpenGL conventions, i.e. the bottom of the screen has
124 the vertical coordinate 0. If the value is bigger than 1, it's a position in
125 pixel. That's independent of the window size, if the window is smaller, parts
126 of the viewport will be cut, if it's bigger parts of the window will not be
127 covered. If they are between 0 and 1 (inclusively) they are relative to the
128 window and are rescaled when the window is resized. If they are -1 they use
129 the extreme applicable value, i.e. 0 for left and bottom, 1 for right and top.
130 For relative sizes the actual value used for right and top is value * size -
131 1. This allows abutting viewports by using the same relative values for right
132 and left of the viewports that should fit. See the image for an example.
134 \image html viewports.png "Viewports in differently sized windows"
136 \image latex viewports.eps "Viewports in differently sized windows" width=8cm
138 An exception to this size definition is the osg::PassiveViewport. It is meant
139 to be used for integrating OpenSG into other applications and takes the size
140 from the currently active OpenGL viewport and thus ignores its settings. This
141 is pretty extreme, in most cases it will probably be enough to use a
142 osg::PassiveWindow and set the Viewport parameters to not interfere with
143 whatever other OpenGL rendering is taking place.
145 To define what is being rendered a viewport stores the root osg::Node of the scene
146 graph to be displayed, the osg::Camera, the osg::Background and
147 osg::Foreground instances to use. Of these, only the osg::Foreground is
148 optional, all others are needed to draw or render the osg::Viewport.
150 There are some special kinds of viewports for specific purposes. The default
151 osg::Viewport is for single buffered rendering, the osg::StereoBufferViewport
152 is used for quad-buffer stereo rendering and the osg::ColorBufferViewport
153 allows rendering to specific color channels only.
157 The osg::StereoBufferViewport only works if the selected window actually has
158 the four buffers. So make sure that your graphics card supports quad-buffer
159 rendering (i.e. has Visuals that are stereo) and that the selected Visual is
164 \anchor PageSystemWindowViewportsPassive The osg::PassiveViewport is totally
165 passive. It ignores its set size and position and instead takes the current
166 OpenGL settings. This allows pretty simple integratino into other OpenGL
167 programs, but the OpenGL context must be active and the viewport set correctly
170 \section PageSystemWindowCamera Camera
172 A osg::Camera defines the parts of the scene that are actually being rendered. The
173 definition can be split in two parts: position and orientation, and internal
176 Position and orientation of the camera are defined by a node in the
177 scene graph, a beacon, similarly to the definition used by light sources. The
178 camera uses the OpenGL defaults for specifying the used coordinate system,
179 i.e. the camera looks along the negative Z coordinate, X points to the right
180 and Y is up. Thus, to use a camera you need a beacon node in the scene to
181 define its position. This can be an object you want to attach the camera to,
182 but in general you'll probably have a Transform node somewhere close to the
185 This gives full flexibility to use a simple matrix to define camera position
186 and orientation, but can be tedious to specify. Many systems use a from-at-up
187 convention to define camera parameters, i.e. you specify a viewer position, a
188 point that should be in the center of the screen and the direction that should
189 be up on the screen. The osg::MatrixLookAt functions from OSGMatrixUtility.h can
190 convert these settings into a matrix that can directly be used to specify the
193 The internal parameters of the camera can vary between different kinds of
194 cameras. The only constant thing that a camera for OpenGL needs are the near
195 and far clip distances, which are defined in the general Camera class. The
196 others are defined in the specific camera classes.
198 The camera parameters needed for rendering are split into three matrices. The
199 first is for viewing, representing teh viewing part of the OpenGL GL_MODELVIEW
200 matrix. The GL_PROJECTION matrix is split into two. The first is the real
201 projection matrix, the second is a projection transformation matrix. The
202 projection transformation is used to add a coordinate system for non-coplanar
203 multi-screen projection setups like CAVEs. See "High-Quality High-Performance
204 Rendering for Multi-Screen Projection Systems" by Dirk Reiners, in Proceedings
205 of the 3 rd International Immersive Projection Technology Workshop for a
206 motivation of this additional coordinate system.
208 The camera has a bunch of functions to access its parameters and derived values
209 like its viewing frustum, and also to calculate rays through viewport pixel for
214 To add a new camera it is necessary to derive from Camera (or one of its
215 descendents) and to override the getProjection() method. It might make sense to
216 also override the getViewing() and/or getProjectionTranslation() methods, in
217 many cases that won't be necessary.
221 \subsection PageSystemWindowCameraPerspective Perspective Camera
223 osg::PerspectiveCamera is the standard camera used for OpenGL rendering. The
224 only additional attribute it has is the vertical field of view, in radians.
225 The horizontal field of view is automatically adjusted to the window size to
226 create a square aspect ratio.
230 It is a little lenient in that it interprets angles > Pi as degrees. Dont know
231 if we should make that official, though. We also need some provisions for
232 non-square aspect ratios.
236 \subsection PageSystemWindowCameraMatrix Matrix Camera
238 The osg::MatrixCamera is a very low-level camera class that keeps the
239 ModelView and Projection matrices directly. It ignores all other parameters it
240 has and just uses the given matrices.
242 Note: The MatrixCamera ignores the beacon's transformation. It really fully
243 replaces the modelview and projection matrices.
245 Note: The MatrixCamera also ignores the near and far fields for calculating
246 the projection. Nonetheless, other components of the system (e.g. the
247 osg::SkyBackground) may still depend on them. Given that they're necessary
248 to calculate the matrix they should be available in the providing system,
249 and they should be set on the MatrixCamera to prevent problems.
251 \subsection PageSystemWindowCameraDecorators Camera Decorators
253 A osg::CameraDecorator is object that can be used instead of a osg::Camera and
254 replaces/enhances some of its functionality. It is an implementation of the
255 standard Decorator pattern (see the Design Patterns book), in which a special
256 object, the decorator, is placed between the original object and a user of the
259 The main idea is to allow enhancing/manipulating arbitrary cameras for new
260 features with minimal impact on applications. The osg::ShearedStereoDecorator
261 for example allows using any camera, whether it's a perspective, orthographic
262 or whatever camera, to control a stereo projection. Todo that it is only
263 necessary to create two viewports, one for the left and right eye, and use two
264 decorators to decorate the single camera for the left and right eye. Changes
265 to the camera's parameters can be done just like in a single view application
266 and automatically influence all affected viewports, and the difference
267 neccessary to create the different images for the left and right eye are
268 managed by the decorators.
272 To create a new osg::CameraDecorator it is just necessary to derive from
273 osg::CameraDecorator and override the function that needs to change. To access
274 the parameters of the decorated object the osg::CameraDecorator::_sfDecoratee
275 field can be used. See osg::ShearedStereoCameraDecorator for an example.
279 \subsubsection PageSystemWindowCameraDecoratorsTile Tiled Rendering
281 The osg::TileCameraDecorator is used to select a rectangular part of the image
282 and scale it to the full viewport. The primary application area is distrbuting
283 the rendering of a large image over several screens. The viewing parameters can
284 be defined as if it was a single large viewport, and the
285 osg::TileCameraDecorator will pick the part it needs to render. This is
286 different from having multiple independent cameras positioned side by side, as
287 the center of projection needs to be the same for all parts of the image
290 The part of the image displayed is defined by its left/right/bottom top
291 coordinates and the width/height of the full image.
295 Pixel-based osg::Background instances like \ref
296 PageSystemWindowBackgroundGradient will not work with the
297 osg::TileCameraDecorator, as they directly access the physical viewport right
302 \subsubsection PageSystemWindowCameraDecoratorsMatrix Additional Matrices
304 The osg::MatrixCameraDecorator allows you to modify the matrices used for
305 rendering. It features separate matrices that are pre- and appended to the
306 viewing, projectionTranslation and projection matrices.
308 The main use is to manipulate the viewing matrix to allow a single camera to
309 look into different directions in different viewports. Note that if you want to
310 use a head-tracked environment, the \ref
311 PageSystemWindowCameraDecoratorsStereoProjection makes that a lot easier.
313 \subsubsection PageSystemWindowCameraDecoratorsStereo Stereo
315 An interesting applications of CameraDecorators is the use to generate the
316 left/right image pairs that are needed to display three-dimensional stereo
319 The osg::StereoCameraDecorator is the base class for all the Decorators that
320 are able to do this. It keeps the generic parameters that are needed for every
321 stereo image: the eye separation and the left/right eye distinction.
323 The eye separation defines the distance between the two eyes, given in the
324 units used in the models, not some global unit like centimeters.
326 The left/right eye distinction is handled by a simple bool, which is true for
327 the left eye decorators, and false for the right eye's.
329 The actual algorithm to generate the images is defined by the specific
332 \paragraph PageSystemWindowCameraDecoratorsStereoSheared Sheared Stereo
334 The osg::ShearedStereoCameraDecorator can be used to generate the left/right
335 image pair needed for stereoscopic displays. It uses the sheared frustum stereo
336 model, which is most appropriate for situations with a non-headtracked user or
337 multiple users, for head-tracked users see \ref
338 PageSystemWindowCameraDecoratorsStereoProjection.
340 The only parameters it needs is the zero parallax plane distance, which
341 defines the distance to a plane where left and right eye images perfectly
342 overlap (i.e. they have zero parallax). This is the plane that the eye will
343 associate with the projection screen or monitor, and the distance should be
344 accurate, as far as possible, to create the most realistic result. It is
345 defined in model units, just like the eye separation.
347 \paragraph PageSystemWindowCameraDecoratorsStereoProjection
350 The osg::ProjectionStereoCameraDecorator is used to calculate the
351 viewing and projection matrices needed for head-tracked stereo
352 setups like some power-walls or, mostly, CAVEs.
354 The main difference to standard stereo stems from the fact that
355 the user can now move in front of the screen. Thus the projection
356 matrix needs to be created so that the center of projection is at
357 the user's eye position and the frustum encloses the projection
358 screen. As OpenGL viewports can only be rectangular, this only
359 works right for rectangular projection screens conceptually. This
360 rectangular projection screen is defined by its four corners,
361 which have to be given to the
362 osg::ProjectionStereoCameraDecorator. The order for the four
363 corners is lower-left, lower-right, upper-right and finally
368 Internally the corners are used to calculate a local coordinate
369 system of the screen, defined by a left, bottom and normal vector.
370 In addition the width and height of the projection screen are
371 calculated. All of these are used to quickly calculate the
372 projection matrix. When looking at the parameters for glWindow
373 that is actually pretty simple and left as an exercise for the
378 The other information needed to calculate the matrices is the
379 position of the user's head. This is usually delivered by a
380 mechanical/magnetic/optical tracking system, which has its own
381 coordinate system. This is coordinate system to be used for the
382 user's head position as well as the corners of the projection
385 The is an additional coordinate system that needs to be taken into
386 account, that's the relation between the projection system and the
387 world. As most projection system setups are smaller than the
388 scenes they depict there is a way to move the whole system in the
389 world, in addition to the user moving inside the projection
390 system. This is conceptually equivalent to the standard user
391 navigation in a scene. To hide the specifics of the
392 osg::ProjectionStereoCameraDecorator from an application that
393 should also be used for standard screens, those two coordinate
394 systems are defined by the coordinate systems of two osg::Node
397 One of them is the osg::Camera's beacon Node. This is used to move
398 the projection system in the scene, just as if it was a simple
401 The other is the osg::ProjectionStereoCameraDecorator's user Node,
402 which should define the world position of the user's head. As the
403 tracker generates relative coordinates, this node should be a
404 descendant of the beacon node.
406 Thus the sub-graph for a head-tracked projected stereo should best
409 beacon->user (need a real picture here)
411 This allows simple switching between standard and head-tracked
412 mode, in which the eye position in standard mode is the origin of
413 the coordinate system in head-tracked mode.
415 \section PageSystemWindowBackground Background
417 A background defines how the window is cleared before anything is rendered.
418 There are a couple of different backgrounds.There can be only one background
421 \subsection PageSystemWindowBackgroundSolid Solid Background
423 osg::SolidBackground is the simplest variant, it just fills the background with a
426 \subsection PageSystemWindowBackgroundGradient Gradient Background
428 osg::GradientBackground fills the background with a color gradient. To specify the
429 gradient a color has to be associated with a vertical position in the viewport
430 (0 being at the bottom, 1 being at the top). An arbitrary number of gradient
431 steps can be used, if only one is given it is used for the whole screen, if
432 none is given black is used. Areas outside the secified gradient borders are
433 filled with black, too.
435 \subsection PageSystemWindowBackgroundImage Image Background
437 osg::ImageBackground draws an osg::Image to clear the background. The image can
438 be scaled to fill the viewport, or it can be kept in the lower left corner of
439 the viewport. The area not filled by the image can be cleared to a simple
440 color. The image is really used as an image and not as a texture, thus
441 clearing, especially with scaling, is not blindingly fast.
443 \subsection PageSystemWindowBackgroundPassive Passive Background
445 osg::PassiveBackground does nothing within the clear call, thus it also has no
446 Fields at all. It is mainly used to stack viewports on top of each other, i.e.
447 it makes it possible to have two viewports on top of each other to generate a
448 single combined image.
450 \subsection PageSystemWindowBackgroundDepthClear Depth Clear Background
452 osg::DepthClearBackground only clears the depth buffer, leaving the color
453 buffer untouched. It is mainly used to stack viewports on top of each other,
454 i.e. it makes it possible to have two viewports on top of each other to
455 generate a single combined image, where the second image lies on top of
456 everything in the first image.
458 \subsection PageSystemWindowBackgroundSky Sky Background
460 osg::SkyBackground is a sky/ground and skybox background, inspired by the VRML
462 http://www.vrml.org/technicalinfo/specifications/vrml97/part1/nodesRef.html#Background
463 for a description on the parameter restrictions.
465 In general it has a set of increasing sky angles and a set of sky colors (one
466 more than angles, for the apex). It has a similar set of parameters for the
467 ground. The sky box is defined by 6 (optional) textures, one for each side of
470 \section PageSystemWindowForegrounds Foreground
472 A foreground can be used to render something on top of the scene-graph image,
473 or manipulate the image if necessary. There can be an arbitrary number of
474 active foregrounds, which are evaluated in the order they are given in the
477 \subsection PageSystemWindowForegroundImage Image Foreground
479 ImageForeground renders images on top of the scene-graph image. The typical
480 use is adding a logo to the image. The can be RGB or RGBA images, correct alpha
481 blending is performed.
483 Images have to be loaded as osg::Image instances, their position has to be
484 defined as a 2D position in the [0,1]x[0,1] range.
486 \subsection PageSystemPolygonForeground Polygon Foreground
488 The PolygonForeground renders a single polygon on top of the viewport using a
489 given Material. The main purpose of the PolygonForeground is using a texture
490 instead of an image for rendering, but it's general enough for other things.
492 The polygon is specified using a set of 3D texture coordinates and a set of
493 2D positions. Both have to contain the same number of entries. The positions
494 can be interpreted in different ways. Values larger or equal to 0 are
495 interpreted starting from the left/bottom border of the viewport, values less
496 or equal to -1 are interpreted starting from the right/top border of the
497 viewport, which -1 being the right/topmost pixel of the viewport. Whether
498 these values are relative to the viewport size or represent absolute pixel
499 values is determined by the normalizedX/normalizedY fields. If set to true,
500 the calculated position is relative, with a 0 to 1 (or -2 to -1) range
501 covering the whole viewport. Otherwise they are direct pixel positions.
503 \subsection PageSystemWindowForegroundGrab Grab Foreground
505 The osg::GrabForeground can be used to grab the rendered viewport into an
506 osg::Image. The osg::Image has to be given to the foreground, if it is not set
509 The size of the osg::Image is used to define the size of the grabbed area. If
510 the image is set, but its size is 1 pixel in one dimension it is
511 resized to the size of the viewport (The 1 is needed as it's impossible to
512 create 0x0 pixel images).
514 \subsection PageSystemWindowForegroundGrabFile File Grab Foreground
516 The osg::FileGrabForeground is used to grab rendered viewports into a single
517 file or into a sequence of files.
519 It can be activated/deactivated using a flag, per default it is active. There's
520 no need to set the image on the osg::FileGrabForeground, it is created
521 automatically on first use.
523 To actually write the image the target file name needs to be set. To write a
524 sequence of frames it also keeps a frame counter, which can be automatically
525 incremented after each grabbed image. The name is used for a printf-style
526 command, thus "%d" in the name is replaced by the frame number.
530 Use "%04d" to create file names with leading zeros.
537 <li>an analog rotary display</li>
539 <li>a single-bar display</li>
541 <li>a block chart</li>
543 <li>a line chart</li>
545 <li>a simple text line</li>
549 Every display can be put at an arbitrary position on screen, defined by a
550 position in X-Window style, i.e. negative positive are taken to be relative to
551 the right edge of the screen. The size of every element can be given either in
552 pixel or relative to the viewport size, similar to the viewport itself, i.e.
553 sizes <=1 are taken to be relative. Every display can have up to three
554 independent colors. The min and max displayable values can either be set
555 directly, or they can be adapted dynamically. To control that adaption there
556 are two flags (Overflow Resize and Underflow Resize), which can be set for
559 Other flags allow the display the min and max values as text, the display of
560 the reciprocal value instead of the actual value, the display of dots at the
561 positions of data points and the smoothing of the display. The smoothing is
562 done using a running average filter of selectable length. If filtering is used
563 the displays show two indicators, one for the current, one for the filtered
566 Some general attributes for all displays can be set: the line width used, the
567 background color used and if the displays should have a drawn background
568 and/or drawn border at all.
570 \section PageSystemWindowNavigators Navigators
572 The Navigators are utility classes to manage the transformation of a camera.
573 There are different navigation models, which are handled by specific navigator
574 classes. The general Navigator features a default mouse and keyboard button
575 binding and a simple to use interface and can switch between these specific
578 \subsection PageSystemWindowNavigatorsNavigator General Navigator
580 The osg::Navigator is a helper class that wraps an instance of all the
581 different low-level navigators and provides functions to map mouse/key event
582 interaction to the lower-level navigator interfaces.
584 As a consequence the osg::Navigator is the most useful of the navigators and
585 should be used in applications.
587 Navigators can be run in absolute or relative mode. In absolute mode (the default)
588 they will try to counteract any changes made to matrices above the camera beacon.
589 In non-absolute mode they will not do anything about them.
591 The default active navigator is the osg::TrackballNavigator. For this
592 navigator the osg::Navigator will map a left mouse click with motion to a
593 rotation, a left mouse click without motion will set the center of rotation to
594 the hit point. A middle mouse click or move will translate in screen x/y, while
595 keeping the hit point under the mouse. A right mouse click with vertical
596 motion as well as using a mouse wheel (if configured to generate button 4 & 5
597 events) will move the viewer in the z direction.
599 The osg::FlyNavigator uses fly forward on left mouse button, backwards on right
600 mouse button and stay still on middle mouse button. In all modes mouse motion
601 is mapped to rotation.
603 \subsection PageSystemWindowNavigatorsTrackball Trackball Navigator
605 The osg::TrackballNavigator mimics a model enclosed in a glass sphere and
606 manipulated by dragging the sphere. The primary application area of the
607 osg::TrackballNavigator is examining a given object by looking at it from all
608 directions, it's an outside-in exploration.
610 Rotation is done by dragging a point on the sphere, translation by focussing the
611 sphere on a different position in space or by dragging the whole sphere. The
612 size of the sphere can be changed, by default it is 80% of the screen size. It
613 is also possible to click and drag outside the sphere. A useful special case is
614 clicking and dragging at the extreme left and right edges of the screen, which
615 can be used to rotate the model around the screen z-axis.
618 distance between the center of rotation and the viewer can also be changed by
619 dragging, resulting in a changing zoom.
621 \subsection PageSystemWindowNavigatorsFly Fly Navigator
623 The osg::FlyNavigator mimics a simple flying model. The user can move forwards
624 and backwards along the viewing direction and he can turn left/right and
625 up/down. The primary application area for the osg::FlyNavigator is models with
626 rather large extends like buildings, cities and landscape, that should be
627 explored from the inside rather than from the outside.
629 The primary parametrisation is a from/at/up point/vector triple, which
630 can be used to initialize and read from the navigator.
632 \subsection PageSystemWindowNavigatorsWalk Walk Navigator
634 The osg::WalkNavigator is an extension of the osg::FlyNavigator. It uses the
635 same interaction model, but in addition constrains the viewer to keep a specific
636 distance from a specified ground. It can also prevent him from walking through
637 walls and objects as well as preventing him from passing through too narrow
640 The main application area are architecture walkthroughs, where the user walks
642 a ground through one or more buildings.
645 \section PageSystemWindowSimpleSceneManager SimpleSceneManager
647 The SimpleSceneManager (SSM) is a utility class to simplify the creation of
648 simple applications. It manages a single window with a single viewport and a
649 minimal scene-graph with a beacon for the camera and a headlight. It keeps a
650 Trackball to interactively manipulate the camera.
652 It does not open a window itself, that is left to the user to keep the SSM
653 useful for arbitrary window systems. The window has to be passed to the SSM by
654 using setWindow(). That's one half of the necessary initialization. It can't
655 handle input itself, the application has to pass it user input events. It's a
656 lot simpler than it sounds, take a look at the tutorials to see how it works.
658 The other half of the necessary initialization is telling SSM what to draw by
659 calling setRoot(). That's it. It might be useful to call showAll() to position
660 the camera at a reasonable position, but that's not mandatory.
662 The SSM can be used in conjunction with any window system, it has been
663 integrated into an easy-to-use QT widget called OSGQGLWidget. See
664 testManagedWindowQT_qt.cpp for an example on how to use it.
666 As a little bonus, the SSM can display the "Powered by OpenSG" logo. Just call
667 useOpenSGLogo() and you're done. ;)