GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  SOGLRENDERACTION (3)

NAME

SoGLRenderAction — renders a scene graph using OpenGL

CONTENTS

Inherits From
Synopsis
Description
Methods
See Also

INHERITS FROM

SoAction > SoGLRenderAction

SYNOPSIS

#include <Inventor/actions/SoGLRenderAction.h>

    typedef AbortCode    
                    
typedef AbortCode    SoGLRenderAbortCB(void *userData)    
typedef void    
                    
typedef void         SoGLRenderPassCB(void *userData)

enum TransparencyType {     SoGLRenderAction::SCREEN_DOOR    
                          SoGLRenderAction::SCREEN_DOOR Uses stipple patterns for screen-door transparency    
SoGLRenderAction::ADD    
                          SoGLRenderAction::ADD     Uses additive alpha blending    
SoGLRenderAction::DELAYED_ADD    
                          SoGLRenderAction::DELAYED_ADD Uses additive blending, rendering all transparent objects after opaque ones    
SoGLRenderAction::SORTED_OBJECT_ADD    
                          SoGLRenderAction::SORTED_OBJECT_ADD Same as DELAYED_ADD, but sorts transparent objects by distances of bounding boxes from camera    
SoGLRenderAction::BLEND    
                          SoGLRenderAction::BLEND   Uses multiplicative alpha blending    
SoGLRenderAction::DELAYED_BLEND    
                          SoGLRenderAction::DELAYED_BLEND Uses multiplicative alpha blending, rendering all transparent objects after opaque ones    
SoGLRenderAction::SORTED_OBJECT_BLEND    
                          SoGLRenderAction::SORTED_OBJECT_BLEND Same as DELAYED_BLEND, but sorts transparent objects by distances of bounding boxes from camera
}

enum AbortCode {     SoGLRenderAction::CONTINUE    
                             SoGLRenderAction::CONTINUE   Continue traversal as usual    
SoGLRenderAction::ABORT    
                             SoGLRenderAction::ABORT      Stop traversing the rest of the graph    
SoGLRenderAction::PRUNE    
                             SoGLRenderAction::PRUNE      Do not traverse this node or its children, but continue    
SoGLRenderAction::DELAY    
                             SoGLRenderAction::DELAY      Delay rendering of this node until the second pass
}

Methods from class SoGLRenderAction:

       
                          
                           SoGLRenderAction(const SbViewportRegion &viewportRegion)    
void    
                          
void                       setViewportRegion(const SbViewportRegion &newRegion)    
const SbViewportRegion &    
                          
const SbViewportRegion &   getViewportRegion() const    
void    
                          
void                       setUpdateArea(const SbVec2f &origin, const SbVec2f &size)    
void    
                          
void                       getUpdateArea(SbVec2f &origin, SbVec2f &size) const    
void    
                          
void                       setAbortCallback(SoGLRenderAbortCB *func, void *userData)    
void    
                          
void                       setTransparencyType(TransparencyType type)    
TransparencyType    
                          
TransparencyType           getTransparencyType() const    
void    
                          
void                       setSmoothing(SbBool smooth)    
SbBool    
                          
SbBool                     isSmoothing() const    
void    
                          
void                       setNumPasses(int num)    
int    
                          
int                        getNumPasses() const    
void    
                          
void                       setPassUpdate(SbBool flag)    
SbBool    
                          
SbBool                     isPassUpdate() const    
void    
                          
void                       setPassCallback(SoGLRenderPassCB *func, void *userData)    
void    
                          
void                       setCacheContext(uint32_t context)    
uint32_t    
                          
uint32_t                   getCacheContext() const

Methods from class SoAction:

    virtual void    
                    
virtual void         apply(SoNode *node)    
virtual void    
                    
virtual void         apply(SoPath *path)    
virtual void    
                    
virtual void         apply(const SoPathList &pathList, SbBool obeysRules = FALSE)    
static SoType    
                    
static SoType        getClassTypeId()    
virtual SoType    
                    
virtual SoType       getTypeId()    
virtual SbBool    
                    
virtual SbBool       isOfType(SoType type)    
virtual void    
                    
virtual void         invalidateState()

DESCRIPTION

This class traverses a scene graph and renders it using the OpenGL graphics library. It assumes that a valid window has been created and initialized for proper OpenGL rendering. The SoXtRenderArea class or any of its subclasses may be used to create such a window.

METHODS

       
                          
                           SoGLRenderAction(const SbViewportRegion &viewportRegion)
Constructor. The parameter defines the viewport region into which rendering will take place.

    void    
                          
void                       setViewportRegion(const SbViewportRegion &newRegion)    
const SbViewportRegion &    
                          
const SbViewportRegion &   getViewportRegion() const
Changes/returns viewport region to use for rendering.

    void    
                          
void                       setUpdateArea(const SbVec2f &origin, const SbVec2f &size)    
void    
                          
void                       getUpdateArea(SbVec2f &origin, SbVec2f &size) const
Sets/returns the current update area, which is the rectangular area of the viewport region that will actually be rendered into. This can be used for partial updates in applications that can manage them. The update area is specified in normalized viewport coordinates, where (0,0) is the lower left corner of the viewport and (1,1) is the upper right corner. The area is specified or returned as an origin and a size.

    void    
                          
void                       setAbortCallback(SoGLRenderAbortCB *func, void *userData)
Sets callback to call during rendering to test for an abort condition. It will be called for each node that is traversed. This allows applications to terminate rendering prematurely if some condition occurs. The callback function should return one of the AbortCode codes to indicate whether traversal should continue. Use of the various codes in a callback can allow applications to modify Inventor’s default order of rendering objects in a scene graph.

    void    
                          
void                       setTransparencyType(TransparencyType type)    
TransparencyType    
                          
TransparencyType           getTransparencyType() const
Sets/returns transparency quality level to use when rendering. The default is SCREEN_DOOR. (Note that SCREEN_DOOR transparency does not work in the case where transparency values are specified for each vertex of a shape. If this is the case, use one of the other transparency types.)

    void    
                          
void                       setSmoothing(SbBool smooth)    
SbBool    
                          
SbBool                     isSmoothing() const
Sets/returns smoothing flag. When on, smoothing uses OpenGL’s line- and point-smoothing features to provide cheap antialiasing of lines and points. The default is FALSE.

    void    
                          
void                       setNumPasses(int num)    
int    
                          
int                        getNumPasses() const
Sets/returns number of rendering passes for multipass rendering. Specifying more than one pass will result in antialiasing of the rendered scene, using OpenGL’s accumulation buffer. (Camera nodes typically move their viewpoints a little bit for each pass to achieve the antialiasing.) Each additional pass provides better antialiasing, but requires more rendering time The default is 1 pass.

    void    
                          
void                       setPassUpdate(SbBool flag)    
SbBool    
                          
SbBool                     isPassUpdate() const
Sets/returns a flag indicating whether intermediate results are displayed after each antialiasing pass for progressive improvement (default is FALSE).

    void    
                          
void                       setPassCallback(SoGLRenderPassCB *func, void *userData)
Sets a callback function to invoke between passes when antialiasing. Passing NULL (which is the default state) will cause a clear of the color and depth buffers to be performed.

    void    
                          
void                       setCacheContext(uint32_t context)    
uint32_t    
                          
uint32_t                   getCacheContext() const
Sets/returns the OpenGL cache context. A cache context is just an integer identifying when OpenGL display lists (which are used for render caching) can be shared between render actions; for example, see the documentation on GLX contexts for information on when OpenGL display lists can be shared between GLX windows.

SEE ALSO

SoSeparator, SoXtRenderArea

Search for    or go to Top of page |  Section 3 |  Main Index


SOGLRENDERACTION(3IV) (-->)

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.