52#ifndef _SO_SCENE_MANAGER_
53#define _SO_SCENE_MANAGER_
62#include <Inventor/STL/vector>
63#include <Inventor/STL/set>
75class SoSceneManagerImpl;
79class SoGLRenderFromPBuffer;
81class SoSceneManagerSync;
88 class SoRenderAreaCoreImpl;
93using inventor::impl::SoRenderAreaCoreImpl;
109#pragma warning( push )
110#pragma warning( disable: 4251 )
213#ifndef HIDDEN_FROM_DOC
214 ,
int id = 0,
bool force =
false
533#ifndef HIDDEN_FROM_DOC
534 NUM_ANTIALIASING_MODE,
726 void updateRealTimeSensor();
747 bool needToSetViewport(
const int id = 0 );
749 void setNeedToSetViewport(
const int id = 0 );
756 void scheduleForcedRedraw();
758 SoSceneManagerImpl* getImpl()
const;
766 bool saveSnapshot(
const SbString& filename, Components components = RGBA)
const;
770 SoSceneManagerImpl* m_impl;
778#pragma warning( pop )
#define TRUE
Possible value of SbBool.
void SoSceneManagerRenderCB(void *userData, SoSceneManager *mgr)
This typedef defines the calling sequence for setRenderCallback() callbacks.
SbBool SoAbortRenderCB(SoAction *, void *userData)
This typedef defines the calling sequence for setAbortRenderCallback() callbacks.
Class encapsulating information about an OpenGL context: a handle on an OpenGL context and its id.
Class for smart character strings.
Class for representing a viewport.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Antialiasing cha...
Abstract base class for all actions.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> Antialiasing par...
Base class for all events.
<a href="IconLegend.html"><img src="extTGS.gif" alt="VSG extension" border="0"></a> OpenGL context m...
Renders a scene graph using Open Inventor's Render Engine.
Allows nodes in a graph to receive input events.
Abstract base class for all database nodes.
Sensor class that can be attached to Open Inventor nodes.
Sensor for one-time only callbacks.
Field containing an SbTime.
Manages scene graph rendering and event handling.
SoHandleEventAction * getHandleEventAction() const
void setInteractive(SbBool flag)
Indicates that the scene manager is in interactive mode or not.
friend class SoRenderAreaCoreImpl
void setBackgroundIndex(int index)
Defines the window background color when in color index mode.
SoSceneManager(int nb=1)
Constructor.
const SbVec2s & getOrigin() const
void setAntialiasing(SoAntialiasingParameters *advancedParameters)
Enable (or disable) antialiasing with specific parameters.
SiAntialiasingEventListener * getAntialiasingEventListener() const
void setRGBMode(SbBool onOrOff)
Defines the color mode (TRUE - RGB mode, FALSE - color map mode).
float getStillSuperSamplingQuality()
void setStillSuperSampling(float quality, float delay)
Set options for supersampling when "still" (not interacting).
const SbViewportRegion & getViewportRegion() const
static void enableRealTimeUpdate(SbBool flag)
Enables the realTime global field update which normally happen right after a redraw.
virtual void setSceneGraph(SoNode *newScene)
Defines the scene graph which is managed here.
void setShareContext(SbGLShareContext sc, SbBool issc=TRUE)
Sets the OpenGL context to be shared by the scene manager.
const SbVec2s & getWindowSize() const
SoAntialiasingParameters * getAntialiasingParameters() const
Returns the antialiasing parameters set using the setAntialiasing(SoAntialiasingParameters*) method.
SbBool isAutoInteractiveMode() const
void setRedrawPriority(uint32_t priority)
Sets the priority of the redraw sensor.
AntialiasingMode getAntialiasingMode() const
Returns the antialiasing mode set using the setAntialiasing(float,AntialiasingMode) method.
virtual ~SoSceneManager()
Destructor.
void setWindowSize(const SbVec2s &newSize, const float &newScale=1.0)
Defines the size of the window in which the scene manager should render.
AntialiasingMode
Enum which indicates the desired antialiasing algorithm.
@ FXAA
FXAA is a screen space antialiasing algorithm which uses shaders and is applied after the rendering.
@ AUTO
This is the default mode for antialiasing.
@ FSAA
FSAA is a full-screen antialiasing algorithm based on super-sampling.
@ NO_ANTIALIASING
Turn off antialiasing.
@ ACCUM_BUFFERS
Deprecated name of SUPERSAMPLING.
@ SUPERSAMPLING
The advantage of this algorithm is it gives high quality images even on lines.
@ SMAA
SMAA is a screen space antialiasing algorithm which uses shaders and is applied after the rendering.
float getClearDepth() const
void setAutoInteractiveMode(SbBool flag)
Defines the auto interactive mode.
void setOrigin(const SbVec2s &newOrigin)
Defines the origin of the viewport within the window.
void setClearDepth(float depth)
Defines the depth value used when the depth buffer is cleared.
SoDEPRECATED void getAntialiasing(SbBool &smoothing, int &numPasses) const
virtual SoDEPRECATED void render(SbBool clearWindow, SbBool clearZbuffer=TRUE)
SoDEPRECATED void setAntialiasing(SbBool smoothing, int numPasses)
Enables smoothing and/or multi-pass antialiasing for rendering.
void setBackgroundColorRGBA(const SbColorRGBA &color)
Defines the window background color when in RGBA mode.
void setBackgroundColor(const SbColor &c)
Defines the window background color when in RGB mode.
SbBool isAutoRedraw() const
Returns TRUE if there is currently a render callback registered.
void setAbortRenderCallback(SoAbortRenderCB *callback, void *userData=NULL)
Setup a callback that returns TRUE if rendering should be aborted.
void setAntialiasing(const float quality, const AntialiasingMode mode=AUTO)
Enable (or disable) antialiasing with specified quality and mode.
void setAntialiasingEventListener(SiAntialiasingEventListener *listener)
Sets an event listener which is called when the antialiasing configuration is modified.
void reinitialize()
Reinitializes graphics.
void scheduleRedraw()
Schedules a redraw for some time in the near future.
virtual void deactivate()
Deactivates the scene manager.
void setSize(const SbVec2s &newSize, const float &newScale=1.0)
Defines the size of the viewport within the window.
uint32_t getRedrawPriority() const
float getStillSuperSamplingDelay()
SbColorRGBA getBackgroundColorRGBA() const
SbColor getBackgroundColor() const
void setViewportRegion(const SbViewportRegion &newRegion)
Defines current viewport region to use for rendering.
int getBackgroundIndex() const
virtual SoNode * getSceneGraph() const
void setHandleEventAction(SoHandleEventAction *hea)
User supplied handle event action.
virtual void activate()
Activates the scene manager.
static uint32_t getDefaultRedrawPriority()
Gets the default priority of the redraw sensor.
static SbBool isRealTimeUpdateEnabled()
SoGLRenderAction * getGLRenderAction() const
const SbVec2s & getSize() const
virtual void render()
Applies an SoGLRenderAction to the scene graph managed here.
void setGLRenderAction(SoGLRenderAction *ra)
User supplied render action.
float getAntialiasingQuality() const
Returns the antialiasing quality set using the setAntialiasing(float,AntialiasingMode) method.
void setRenderCallback(SoSceneManagerRenderCB *f, void *userData=NULL)
The render callback provides a mechanism for automatically redrawing the scene in response to changes...
virtual SbBool processEvent(const SoEvent *event)
Processes the passed event by applying an SoHandleEventAction to the scene graph managed here.
Abstract base class for Open Inventor sensors.