MeVisLab Resolution Independence API
Loading...
Searching...
No Matches
SoExaminerViewer.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef SO_EXAMINER_VIEWER_H
14#define SO_EXAMINER_VIEWER_H
15
16#include "SoViewers.h"
17#include "SoFullViewer.h"
18
19//=============================================================
23
24//=============================================================
26{
27
28 SO_NODE_HEADER(SoExaminerViewer);
29
30public:
32
34 SoSFBool feedback;
35 SoSFInt32 feedbackSize;
36 SoSFTrigger stopAnimating;
37 SoSFString mouseInteraction;
38
40
42
43 SoSFTrigger startRotation;
44 SoSFTrigger stopRotation;
45 SoSFVec3f rotationAxis;
46 SoSFFloat rotationAngle;
47 SoSFInt32 rotationSteps;
49 SoSFTrigger rotationStopped;
51
53
58
60
62 static void initClass();
63
66 void* createViewer(void* hwnd, SoNode* scene) override;
67
69 void setupViewer() override;
70
72 void storeViewerState() override;
73
75 void rotationChanged(SoSensor* sensor);
76 static void rotationChangedCB(void* data, SoSensor* sensor);
77
79 void reorientCamera(const SbRotation& rot);
80
83 void getSyncFieldNames(SbStringList& list) override;
84
85protected:
87
89 void stopAnimatingChanged(SoField*);
90 void feedbackChanged(SoField*);
91 void feedbackSizeChanged(SoField*);
94 void startRotationChanged(SoField*);
95 void stopRotationChanged(SoField*);
98
100
104 SoTimerSensor* _rotSensor;
105};
106
107#endif
#define SO_VIEWERS_CLASS_SPEC
Definition SoViewers.h:44
bool _rotating
flag if currently autorotating
static void initClass()
inventor runtime
void feedbackSizeChanged(SoField *)
void getSyncFieldNames(SbStringList &list) override
SoSFTrigger rotationStopped
void wheelRotationEnabledChanged(SoField *)
void stopAnimatingChanged(SoField *)
further field callbacks
void * createViewer(void *hwnd, SoNode *scene) override
SoTimerSensor * _rotSensor
timer sensor for autorotation
void animationEnabledChanged(SoField *)
SoSFBool wheelZoomEnabled
enable zoom/rotation by mouse wheel
void storeViewerState() override
called automatically by timer sensor if storeCurrentState is on
SoSFBool animationEnabled
Fields.
void feedbackChanged(SoField *)
void wheelZoomEnabledChanged(SoField *)
void mouseInteractionChanged(SoField *)
void evaluateInteractionString()
SoSFString mouseInteraction
SoSFInt32 rotationCurrentStep
void setupViewer() override
sets all values from fields
SoSFTrigger startRotation
Autorotation Fields around given axis.
SoSFTrigger stopRotation
SoSFBool wheelRotationEnabled
SoSFTrigger stopAnimating
void startRotationChanged(SoField *)
static void rotationChangedCB(void *data, SoSensor *sensor)
~SoExaminerViewer() override
void reorientCamera(const SbRotation &rot)
reorient the camera, rotating rot around the focus point of the viewer
void rotationChanged(SoSensor *sensor)
called when the autorotate time is triggered
void stopRotationChanged(SoField *)