MeVisLab Toolbox Reference
Loading...
Searching...
No Matches
SoCSO3DVis.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
15
16#pragma once
17
18#include "SoCSOIncludes.h"
19#include "SoCSOSystem.h"
20
21#include <SoInteractionNode.h>
22
23
24namespace ml
25{
26 class CSOVisualizationSettings;
27}
28
30
31class SoCSO3DVisPickAction;
32
35{
36 friend class SoCSO3DVisPickAction;
37
38public:
42 static void initClass();
43
44
45 /* FIELDS */
46
55
60
83
88
92
95
98
99protected:
101 ~SoCSO3DVis() override;
102
103private:
104 /* DATA TYPES */
105
106 struct CSOSettings
107 {
108 float cRed;
109 float cGreen;
110 float cBlue;
111 float cAlpha;
112
113 int linePattern;
114 float lineWidth;
115
116 float mRed;
117 float mGreen;
118 float mBlue;
119 float mAlpha;
120
121 int markerMode;
122 float markerSize;
123 };
124
125 /* MEMBER VARIABLES */
126
128 SoSeparator* _separator;
130 ml::CSOList* _csoList;
132 bool _isInNotificationCB;
134 SbTime _lastUpdateTime;
136 bool _useRenderDelayTimer;
138 float _timerDelayMilliSeconds;
139
141 bool _hasValidStylePalette;
142
144 SoCSO3DVisPickAction* _pickAction;
145
146
147 /* METHODS */
148
150 void _generateScene();
153 void _setUpVisualization(ml::CSO* cso, CSOSettings& settings);
156 void _setUpVisualization(ml::CSO* cso, ml::CSOVisualizationSettings* visualizationSettings, CSOSettings& settings);
157
159 void _setClosestCSOSelected(const SbVec3f& selectionPoint);
160
161 void inCSOListChanged(SoField*);
162 void styleChanged(SoField*);
163 void lutChanged(SoField*);
164 void otherVisualizationChanged(SoField*);
165 void timerChanged(SoField*);
166 void enableSelectionChanged(SoField*);
167 void applyChanged(SoField*);
168
170 static void _csoListNotificationCB(void* userData, int notificationFlag);
171
172 SO_NODE_HEADER(SoCSO3DVis);
173};
174
#define SOCSO_EXPORT
Header file for system independent resolution.
Definition SoCSOSystem.h:21
Module for visualizing CSOs in 3D as an Open Inventor scene.
Definition SoCSO3DVis.h:35
SoSFBool enableSelection
Should the selection be enabled?
Definition SoCSO3DVis.h:62
SoSFMLBase inCSOList
The input CSOList.
Definition SoCSO3DVis.h:48
~SoCSO3DVis() override
Standard destructor.
SoSFBool useRenderTimeDelay
If checked, the scene is rendered only after the adjustable time.
Definition SoCSO3DVis.h:74
SoSFFloat timerDelayMilliSeconds
The adjustable timer delay.
Definition SoCSO3DVis.h:76
SoSFBool highlightSelectedGroups
Should the module highlight all CSOs that are in selected Groups?
Definition SoCSO3DVis.h:68
SoSFBool provideVertexProperties
Should texture coordinates and normals be provided in vertex properties?
Definition SoCSO3DVis.h:97
SoSFEnum stylePaletteUseIndexAs
Defines the use of style palette indices (CSO / Group).
Definition SoCSO3DVis.h:87
SoSFBool listenToFinishingNotifications
Shall the module listen to finishing notifications?
Definition SoCSO3DVis.h:80
SoSFEnum cursorShape
Cursor shape for action.
Definition SoCSO3DVis.h:66
SoSFFloat seedPointSizeScaling
This value is multiplied to all marker sizes as a scaling.
Definition SoCSO3DVis.h:72
static void initClass()
Initializes this class (inventor stuff)
SoSFBool performPreHitTest
Perform picking while hovering.
Definition SoCSO3DVis.h:64
SoSFFloat pathPointWidthOffset
This value is added to all line widths as an offset.
Definition SoCSO3DVis.h:70
SoSFBool listenToSelectionChangedNotifications
Shall the module listen to selection changed notifications?
Definition SoCSO3DVis.h:82
SoSFBool useStylePalette
Should a style palette be used for adjusting display options if one is attached?
Definition SoCSO3DVis.h:85
SoSFBool autoApply
Shall all changes of parameters take immediate effect?
Definition SoCSO3DVis.h:57
SoSFBool listenToRepaintNotifications
Shall the module listen to every repaint notification?
Definition SoCSO3DVis.h:78
SoSFMLBase inStylePalette
Input of a style palette.
Definition SoCSO3DVis.h:50
SoSFBool useLUT
Should use 4th component in path points as (absolute) index into LUT supplied by inLUT input.
Definition SoCSO3DVis.h:91
SoCSO3DVis()
Standard constructor.
SoSFMLBase inVisualizationSettings
Input for a CSOVisualizationSettings object.
Definition SoCSO3DVis.h:52
SoSFInt32 timepointToRender
Defines which timepoint to render; -1 renders all XMarkers.
Definition SoCSO3DVis.h:94
SoSFTrigger apply
Applies changes.
Definition SoCSO3DVis.h:59
SoSFMLBase inLUT
LUT for coloring of path points.
Definition SoCSO3DVis.h:54
SoInteractionNode is the base class for normal interaction nodes in OpenInventor that handle their in...
The SoSFMLBase field is the interface used by Inventor nodes to output ML Base objects to the outside...
Definition SoSFMLBase.h:46
A CSOList comprises a number of CSOs and CSOGroups and is the central object for contour segmentation...
Definition CSOList.h:61
The CSO represents a contour segmentation object.
Definition CSO.h:44
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
Main documentation file for ML users and developers.
Definition SoSFMLImage.h:64