MeVisLab Resolution Independence API
|
Base class for all viewer nodes in MeVisLab. More...
#include <SoViewerNode.h>
Public Member Functions | |
SoViewerNode () | |
virtual void * | createViewer (void *hwnd, SoNode *scene) |
create a viewer in the given window, the scene is shown in the viewer | |
virtual void | deleteViewer (void *viewer) |
delete the viewer that was created with createViewer | |
virtual void * | getCurrentViewer () |
returns the currently viewer (or NULL, if none was created) | |
virtual void | syncFromViewerNode (SoViewerNode *) |
sync field from given src viewer node (derive to add more synched fields) | |
void | setKeyPressedCB (InvKeyPressedCB *cb, void *data) |
set a keypressed callback | |
bool | keyPressedNotify (void *message) |
run keypressed cb | |
void | setHandleEventCB (InvHandleEventCB *cb, void *data) |
set a handle event callback | |
bool | handleEventNotify (void *message) |
run handle event cb | |
void | setGenerateMovieCB (InvGenerateMovieCB *cb, void *data) |
set movie generation callback | |
void | generateMovie (const char *name, const char *extension, int count, float framerate, const char *targetFile=nullptr) |
run move generation | |
Static Public Member Functions | |
static void | initClass () |
Protected Member Functions | |
~SoViewerNode () override | |
Protected Attributes | |
void * | _currentViewer |
pointer to the current viewer (void, because the concrete type is unkown) | |
SoViewerProxy * | _viewerProxy |
pointer to the proxy for this viewer | |
InvGenerateMovieCB * | _movieCB |
callback for movie generation | |
void * | _movieCBData |
callback data for movie generation | |
InvKeyPressedCB * | _keyPressedCB |
callback for key pressed | |
void * | _keyPressedCBData |
callback data for key pressed | |
InvHandleEventCB * | _handleEventCB |
callback for handleEvent | |
void * | _handleEventCBData |
callback data for handleEvent | |
Base class for all viewer nodes in MeVisLab.
Since the SoQtExaminerViewer etc. are not SoNode classes and have no way to save their state persistently, we decided to wrap all viewers and their creation/persistence in the SoViewerNode and it's derived classes. The mostly used SoViewerNodes are located in the SoViewers
project, e.g. the SoRenderArea
and SoExaminerViewer
. In many cases when you want to add a viewer to MeVisLab, you would derive either from the SoRenderArea
or SoFullViewer
class and not from this base class.
Definition at line 41 of file SoViewerNode.h.
SoViewerNode::SoViewerNode | ( | ) |
|
overrideprotected |
|
virtual |
create a viewer in the given window, the scene is shown in the viewer
void pointer is used to be compatible to any windows system, on Qt it is a QWidget, on TGS SoWin it is a HWND. Only one viewer can be created at a time.
Reimplemented in SoExaminerViewer, SoFullViewer, and SoRenderArea.
|
virtual |
delete the viewer that was created with createViewer
Reimplemented in SoFullViewer, and SoRenderArea.
|
inline |
run move generation
Definition at line 88 of file SoViewerNode.h.
|
inlinevirtual |
returns the currently viewer (or NULL, if none was created)
Definition at line 61 of file SoViewerNode.h.
|
inline |
run handle event cb
Definition at line 79 of file SoViewerNode.h.
|
static |
|
inline |
run keypressed cb
Definition at line 70 of file SoViewerNode.h.
|
inline |
set movie generation callback
Definition at line 85 of file SoViewerNode.h.
|
inline |
set a handle event callback
Definition at line 76 of file SoViewerNode.h.
|
inline |
set a keypressed callback
Definition at line 67 of file SoViewerNode.h.
|
inlinevirtual |
sync field from given src viewer node (derive to add more synched fields)
Reimplemented in SoRenderArea.
Definition at line 64 of file SoViewerNode.h.
|
protected |
pointer to the current viewer (void, because the concrete type is unkown)
Definition at line 94 of file SoViewerNode.h.
|
protected |
callback for handleEvent
Definition at line 109 of file SoViewerNode.h.
|
protected |
callback data for handleEvent
Definition at line 111 of file SoViewerNode.h.
|
protected |
callback for key pressed
Definition at line 105 of file SoViewerNode.h.
|
protected |
callback data for key pressed
Definition at line 107 of file SoViewerNode.h.
|
protected |
callback for movie generation
Definition at line 101 of file SoViewerNode.h.
|
protected |
callback data for movie generation
Definition at line 103 of file SoViewerNode.h.
|
protected |
pointer to the proxy for this viewer
Definition at line 96 of file SoViewerNode.h.