MeVisLab Toolbox Reference
SoCSODefines.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 <CSOBase/CSODefines.h>
20 #include <SoView2D.h>
21 
23 
24 ML_START_NAMESPACE
25 class StylePalette;
26 class CSOProcessorData;
27 ML_END_NAMESPACE
28 
29 class SoCSOTransform;
30 
32 
34 {
35  SoView2D* view2D = nullptr;
37  View2DEvent* ec = nullptr;
39 };
40 
42 
44 {
45  ml::CSOList* csoList = nullptr;
47  int hitMode = 0;
52  int timepointindex = -1;
53  bool deleteSeedPoint = false;
55 };
56 
58 
62 
64 
66 {
68  View2DSlice* slice = nullptr;
69  int z = -1;
71  int voxelAugmentZ = 0;
72  std::string seriesInstanceUID;
73  std::string frameOfReferenceUID;
74  int timePointIndex = 0;
76  ml::CoordinateSystemReference coordinateSystemReference;
77 
79 
80  std::string getViewerId() const
81  {
82  if (slicelist && slicelist->getOwner())
83  {
84  return slicelist->getOwner()->viewerId.getValue().getString();
85  }
86  return std::string("");
87  }
88 };
89 
91 
93 {
99 };
100 
102 
104 {
105  std::vector<ml::Vector3> positions;
106 };
107 
109 
112 {
113  double minZ = 0.0;
114  double maxZ = 0.0;
115 };
116 
118 
120 {
122  {
125  }
126 
129 };
130 
132 
134 {
136  ml::CSOList* csoList = nullptr;
137  ml::CSO* cso = nullptr;
138  std::vector<int> csoIds;
139  ml::AbstractTransformationPtr transformation = nullptr;
141 };
142 
144 
147 {
151 
154 
155  SbVec2f upperLeft;
156  SbVec2f labelSize;
157 
158  std::string labelName;
159  std::string labelString;
160  std::string labelCaption;
161 
163 
164  float labelFontColor[4];
166 };
167 
169 
172 {
175  SHOW_MARKER_CIRCLE = 2
176 };
177 
179 
182 {
184  COLOR_GENERAL = 1
185 };
186 
188 
191 {
194 };
195 
197 
200 {
206  unsigned short pathPointStyle;
207 
214 
215  float labelRed;
216  float labelGreen;
217  float labelBlue;
218  float labelAlpha;
219 };
220 
222 
226 {
228  bool isCurrentlyMovingCSO = false;
230 };
231 
233 
236 {
240 };
241 
243 
246 {
249 };
250 
252 
255 {
258 };
259 
261 
264 {
267 };
268 
270 
273 {
276 };
277 
279 
282 {
285 };
286 
288 
291 {
294 };
295 
297 
300 {
304 };
305 
307 
308 const unsigned short PATH_POINTS_PATTERN_NONE = 0x0000;
309 const unsigned short PATH_POINTS_PATTERN_SOLID = 0xFFFF; //<! Line pattern for a solid line.
310 const unsigned short PATH_POINTS_PATTERN_DASHED = 0xF0F0;
311 const unsigned short PATH_POINTS_PATTERN_DOTTED = 0xAAAA;
312 const unsigned short PATH_POINTS_PATTERN_SHORT_DASHED = 0xC7C7; //<! Line pattern for a short dashed line.
313 
315 
316 #define TAG_VIEWER_ID "viewerId"
317 
SEED_POINT_MARKER_MODES
Enumeration of markers for seed points.
Definition: SoCSODefines.h:172
@ SHOW_MARKER_NONE
Shows no marker at the seed point positions.
Definition: SoCSODefines.h:173
@ SHOW_MARKER_CIRCLE
Shows a circle at the seed point positions.
Definition: SoCSODefines.h:175
@ SHOW_MARKER_RECT
Shows a rectangle at the seed point positions.
Definition: SoCSODefines.h:174
COLOR_MODES
Enumeration of marker coloring.
Definition: SoCSODefines.h:182
@ COLOR_AS_CSO
The marker is shown in the same color as the CSO.
Definition: SoCSODefines.h:183
@ COLOR_GENERAL
Use the general marker color for all markers.
Definition: SoCSODefines.h:184
CSOSliceInformation
Definition: SoCSODefines.h:93
@ CSO_SLICE_COMPLETELY_BELOW
The CSO lies completely below the current slice.
Definition: SoCSODefines.h:98
@ CSO_SLICE_UNKNOWN
No information about the CSO and the current slice.
Definition: SoCSODefines.h:94
@ CSO_SLICE_COMPLETELY_ABOVE
The CSO lies completely above the current slice.
Definition: SoCSODefines.h:97
@ CSO_SLICE_CROSSED
The CSO is crossed by the current slice.
Definition: SoCSODefines.h:96
@ CSO_SLICE_COMPLETELY_ON
The CSO lies completely on the current slice.
Definition: SoCSODefines.h:95
SELECTION_COLOR_MODES
Defines the color mode for selected CSOs.
Definition: SoCSODefines.h:246
@ SELECTION_COLOR_MODE_BRIGHTEN
Selection color mode: the selected CSO is brightened.
Definition: SoCSODefines.h:247
@ SELECTION_COLOR_MODE_FIXED
Selection color mode: the selected CSO is set to a fixed color.
Definition: SoCSODefines.h:248
SELECTED_SEED_POINT_COLOR_MODES
Defines the color mode for selected seed points.
Definition: SoCSODefines.h:264
@ SELECTED_SEED_POINT_COLOR_MODE_BRIGHTEN
Selected seed point color mode: the selected seed point is brightened.
Definition: SoCSODefines.h:265
@ SELECTED_SEED_POINT_COLOR_MODE_FIXED
Selected seed point color mode: the selected seed point is set to a fixed color.
Definition: SoCSODefines.h:266
const unsigned short PATH_POINTS_PATTERN_SOLID
Definition: SoCSODefines.h:309
SELECTED_SEED_POINT_SIZE_MODES
Defines the size mode for selected seed points.
Definition: SoCSODefines.h:273
@ SELECTED_SEED_POINT_ENLARGE
Selected seed point size mode: the size of the selected seed point is enlarged.
Definition: SoCSODefines.h:274
@ SELECTED_SEED_POINT_FIXED
Selected seed point size mode: the size of the selected seed point is set to a fixed value.
Definition: SoCSODefines.h:275
const unsigned short PATH_POINTS_PATTERN_SHORT_DASHED
Definition: SoCSODefines.h:312
SELECTION_LINE_WIDTH_MODES
Defines the line width mode for selected CSOs.
Definition: SoCSODefines.h:255
@ SELECTION_LINE_FIXED
Selection line width mode: the line width of the selected CSO is set to a certain value.
Definition: SoCSODefines.h:257
@ SELECTION_LINE_WIDEN
Selection line width mode: the line width of the selected CSO is widened.
Definition: SoCSODefines.h:256
HIGHLIGHT_COLOR_MODES
Defines the highlighting color mode for CSOs under the mouse cursor.
Definition: SoCSODefines.h:282
@ HIGHLIGHT_COLOR_MODE_FIXED
Highlight color mode: the CSO under the mouse cursor is set to a fixed color.
Definition: SoCSODefines.h:284
@ HIGHLIGHT_COLOR_MODE_BRIGHTEN
Highlight color mode: the CSO under the mouse cursor is brightened.
Definition: SoCSODefines.h:283
SIDE_FILLING_LINE_WIDTH_MODES
Enumeration of line width modes for side fillings.
Definition: SoCSODefines.h:300
@ SIDE_FILLING_WIDTH_AS_CSO
Definition: SoCSODefines.h:301
@ SIDE_FILLING_WIDTH_MANUAL
Definition: SoCSODefines.h:303
@ SIDE_FILLING_WIDTH_AUTOMATIC
Definition: SoCSODefines.h:302
const unsigned short PATH_POINTS_PATTERN_NONE
Line pattern for no line at all.
Definition: SoCSODefines.h:308
const unsigned short PATH_POINTS_PATTERN_DASHED
Line pattern for a dashed line.
Definition: SoCSODefines.h:310
STYLE_PALETTE_INDEX_USE
Enumeration of the usage of style palette indices.
Definition: SoCSODefines.h:191
@ USE_INDEX_FOR_GROUP
The style of the according Group index is chosen (overrides CSO style).
Definition: SoCSODefines.h:193
@ USE_INDEX_FOR_CSO
The style of the according CSO index is chosen.
Definition: SoCSODefines.h:192
const unsigned short PATH_POINTS_PATTERN_DOTTED
Line pattern for a dotted line.
Definition: SoCSODefines.h:311
CSOEvalEventView2DInfos CSOProcessView2DInfos
Typedefs for backward compatibility.
Definition: SoCSODefines.h:60
CSOEvalEventCSOInfos CSOProcessCSOInfos
Definition: SoCSODefines.h:61
HIT_POINT_MODE
Enumeration for different hit point modes.
Definition: SoCSODefines.h:236
@ HIT_SEED_POINT
Hit point was near an existing seed point.
Definition: SoCSODefines.h:238
@ HIT_PATH_POINT
Hit point was near a path point.
Definition: SoCSODefines.h:239
@ HIT_NOTHING_HIT
Hit point was nowhere near an existing CSO.
Definition: SoCSODefines.h:237
HIGHLIGHT_LINE_WIDTH_MODES
Defines the highlighting line width mode for CSOs under the mouse cursor.
Definition: SoCSODefines.h:291
@ HIGHLIGHT_LINE_FIXED
Highlight line width mode: the line width of the CSOs under the mouse cursor is set to a certain valu...
Definition: SoCSODefines.h:293
@ HIGHLIGHT_LINE_WIDEN
Highlight line width mode: the line width of the CSOs under the mouse cursor is widened.
Definition: SoCSODefines.h:292
View2DEventPhase
event phase for simple extensions that grab the focus, do something (motion) and are released afterwa...
@ EVENT_ANY
Event phase is undefined and has to be checked by getEvent() method.
Abstract Open Inventor base class for uniform shader parameter nodes.
SoView2D is a 2D viewer for image data.
Definition: SoView2D.h:62
SoSFString viewerId
id string, needs to be unique in a network if used
Definition: SoView2D.h:82
View2DEvent stores all information on an event on a SoView2D.
a list that holds all View2DSlice objects (lazily created) of a SoView2D
SoView2D * getOwner()
Get the owning SoView2D.
a single slice that is stored in a View2DSliceList, typically created by a View2DSliceList
Definition: View2DSlice.h:48
The CSOBoundingBox defines an axis parallel bounding box with double precision.
A CSOList comprises a number of CSOs and CSOGroups and is the central object for contour segmentation...
Definition: CSOList.h:61
The CSOPathPoints is a list of world coordinates which are interpolated by a certain interpolation sc...
Definition: CSOPathPoints.h:37
The CSOProcesorData provides the network data interchange object for processing interaction events an...
The CSOSeedPoint can be interactively set and modified and is the framework for contours.
Definition: CSOSeedPoint.h:35
The CSO represents a contour segmentation object.
Definition: CSO.h:44
Base object class StylePalette for providing a collection of colors, line styles and marker types.
ml::AbstractTransformationPtr transformation
Definition: SoCSODefines.h:139
std::vector< int > csoIds
Definition: SoCSODefines.h:138
ml::CSOList * csoList
Definition: SoCSODefines.h:136
CSODrawSliceInformation sliceInfo
Definition: SoCSODefines.h:140
ml::CSOBoundingBox slabBB
Definition: SoCSODefines.h:135
CSOSliceInformation sliceInformation
Definition: SoCSODefines.h:127
std::string getViewerId() const
Definition: SoCSODefines.h:80
std::string frameOfReferenceUID
Definition: SoCSODefines.h:73
size_t worldToVoxelMatrixHashKey
Definition: SoCSODefines.h:70
ml::CoordinateSystemReference coordinateSystemReference
Definition: SoCSODefines.h:76
View2DSliceList * slicelist
Definition: SoCSODefines.h:67
SoCSOTransform * csoTransform
Definition: SoCSODefines.h:75
ml::StylePalette * stylePalette
Definition: SoCSODefines.h:78
std::string seriesInstanceUID
Definition: SoCSODefines.h:72
View2DSlice * slice
Definition: SoCSODefines.h:68
Structure holding information about the processor/editor state.
Definition: SoCSODefines.h:226
ml::CSO * csoCurrentlyUnderMouse
Definition: SoCSODefines.h:227
ml::CSOProcessorData * processorData
Definition: SoCSODefines.h:229
bool isCurrentlyMovingCSO
Definition: SoCSODefines.h:228
ml::CSO * recentlySelectedCSO
Definition: SoCSODefines.h:48
ml::CSOPathPoints * recentlySelectedPathPoints
Definition: SoCSODefines.h:50
ml::CSOSeedPoint * recentlySelectedSeedPoint
Definition: SoCSODefines.h:49
ml::CSOList * csoList
Definition: SoCSODefines.h:45
ml::Vector3 currentHitPoint
Definition: SoCSODefines.h:46
ml::CSOBoundingBox slabBB
Definition: SoCSODefines.h:51
View2DEventPhase phase
Definition: SoCSODefines.h:38
View2DSliceList * slicelist
Definition: SoCSODefines.h:36
Structure to store render information for a certain CSO and viewer.
Definition: SoCSODefines.h:147
CSODrawView2DInfos view2DInfos
Definition: SoCSODefines.h:149
CSODrawCSOInfos csoInfos
Definition: SoCSODefines.h:148
ml::Vector2 labelBoundingBoxV1
Definition: SoCSODefines.h:152
CSODrawSliceInformation drawSliceInfos
Definition: SoCSODefines.h:150
ml::Vector2 labelBoundingBoxV2
Definition: SoCSODefines.h:153
std::vector< ml::Vector3 > positions
Definition: SoCSODefines.h:105
Structure to hold visual parameters for the old editor.
Definition: SoCSODefines.h:200
unsigned short pathPointStyle
Definition: SoCSODefines.h:206
Defines the z slab of a CSO bounding box in voxel coordinates.
Definition: SoCSODefines.h:112