Open Inventor Release 2024.2.1
 
Loading...
Searching...
No Matches
SoVolumeDetail.h
1/*=======================================================================
2 *** THE CONTENT OF THIS WORK IS PROPRIETARY TO FEI S.A.S, (FEI S.A.S.), ***
3 *** AND IS DISTRIBUTED UNDER A LICENSE AGREEMENT. ***
4 *** ***
5 *** REPRODUCTION, DISCLOSURE, OR USE, IN WHOLE OR IN PART, OTHER THAN AS ***
6 *** SPECIFIED IN THE LICENSE ARE NOT TO BE UNDERTAKEN EXCEPT WITH PRIOR ***
7 *** WRITTEN AUTHORIZATION OF FEI S.A.S. ***
8 *** ***
9 *** RESTRICTED RIGHTS LEGEND ***
10 *** USE, DUPLICATION, OR DISCLOSURE BY THE GOVERNMENT OF THE CONTENT OF THIS ***
11 *** WORK OR RELATED DOCUMENTATION IS SUBJECT TO RESTRICTIONS AS SET FORTH IN ***
12 *** SUBPARAGRAPH (C)(1) OF THE COMMERCIAL COMPUTER SOFTWARE RESTRICTED RIGHT ***
13 *** CLAUSE AT FAR 52.227-19 OR SUBPARAGRAPH (C)(1)(II) OF THE RIGHTS IN ***
14 *** TECHNICAL DATA AND COMPUTER SOFTWARE CLAUSE AT DFARS 52.227-7013. ***
15 *** ***
16 *** COPYRIGHT (C) 1996-2024 BY FEI S.A.S, ***
17 *** BORDEAUX, FRANCE ***
18 *** ALL RIGHTS RESERVED ***
19**=======================================================================*/
20/*=======================================================================
21** Author : P. ESTRADE (Dec 2000)
22** Modified by : T.DUFOUR (MMM yyyy)
23**=======================================================================*/
24
25#ifndef _SO_VOLUME_DETAIL_
26#define _SO_VOLUME_DETAIL_
27
28#include <Inventor/details/SoSubDetail.h>
29#include <Inventor/SbPImpl.h>
30#include <VolumeViz/nodes/SoVolumeDataDrawStyle.h>
31#include <LDM/elements/SoDataRangeElement.h>
32
33class SoVolumeData;
34class SoROI;
35class SbLine;
37
38SO_PIMPL_BASE_PUBLIC_DECLARATION(SoVolumeDetail)
39
40
41//
42// Class: SoVolumeDetail
43//
44// Abstract class for SoVolumeRenderDetail and SoVolumeSkinDetail nodes.
45//
47
123class SoVolumeDetail : public SoDetail {
124
125 SO_DETAIL_HEADER(SoVolumeDetail);
126 SO_PIMPL_BASE_PUBLIC_HEADER(SoVolumeDetail);
127
128 public:
137
144 void getProfileObjectPos(SbVec3f profile[2]) const;
145
157 int getProfileDataPos(SbVec3i32 profile[2]) const;
158
176 int64_t getProfileValue(int index, SbVec3i32& pos, SbVec3f* objPos = 0, SbBool realValue = FALSE) const;
177
195 double getProfileValueD(int index, SbVec3i32& pos, SbVec3f* objPos, SbBool realValue = FALSE) const;
196
214 virtual SbBool getFirstNonTransparentValue(int64_t& value, SbVec3i32& pos, SbVec3f* objPos = 0, SbBool realValue = FALSE) const;
215
233 virtual SbBool getFirstNonTransparentValue(double& value, SbVec3i32& pos, SbVec3f* objPos = 0, SbBool realValue = FALSE) const;
234
236 virtual SoDetail* copy() const;
237
238 private:
239 void setDetails(SbLine line, SoVolumeData* vd, SoTransferFunction* tf, SoROI* r);
240
241 private:
242 static void initClass();
243 static void exitClass();
244
246 void setDataSetIdPairList(const SoLDM::DataSetIdPairList& dsPairList);
247
249 void setDrawStyleMap(const SoVolumeDataDrawStyle::MaskDrawStyleValueMap& styleMap);
250
252 void setTransferFunctionList(const std::vector<SoTransferFunction*>& tfList, int intersectionTfId);
253
255 void setIsovalueMap(const SoVolumeDataDrawStyle::IsovalueMap& isomap);
256
258 void setDataRangeMap(const SoDataRangeElement::DataRangeIdMap& dataRangeMap);
259
261 void setVolumeRenderTransparency(float transparency);
262
263 private:
265 SoVolumeDetail(const SoVolumeDetail& detail);
266};
267
268#endif /* _SO_VOLUME_DETAIL_ */
269
270
Directed line in 3D.
Definition SbLine.h:57
3D vector class.
Definition SbVec.h:932
3D vector class.
Definition SbVec.h:1517
Base class for describing detail information about a shape node.
Definition SoDetail.h:99
<a href="IconLegend.html"><img src="extLDM.gif" alt="Large Data Management" border="0"></a> Region o...
Definition SoROI.h:320
<a href="IconLegend.html"><img src="extLDM.gif" alt="Large Data Management" border="0"></a> Describe...
<a href="IconLegend.html"><img src="extVR.gif" alt="VolumeViz" border="0"></a> Volume data property ...
<a href="IconLegend.html"><img src="extVR.gif" alt="VolumeViz" border="0"></a> Base class for detail...
virtual SbBool getFirstNonTransparentValue(int64_t &value, SbVec3i32 &pos, SbVec3f *objPos=0, SbBool realValue=FALSE) const
Retrieves the value and position of the first non-transparent voxel along the pick ray (if any).
void getProfileObjectPos(SbVec3f profile[2]) const
Returns the profile position in object space (world coordinates).
double getProfileValueD(int index, SbVec3i32 &pos, SbVec3f *objPos, SbBool realValue=FALSE) const
Returns the index'th value (as a double) and its position in object and data space.
int getProfileDataPos(SbVec3i32 profile[2]) const
Returns the number of values along the profile and the profile position in data space (voxel coordina...
virtual SbBool getFirstNonTransparentValue(double &value, SbVec3i32 &pos, SbVec3f *objPos=0, SbBool realValue=FALSE) const
Retrieves the value and position of the first non-transparent voxel along the pick ray (if any).
int64_t getProfileValue(int index, SbVec3i32 &pos, SbVec3f *objPos=0, SbBool realValue=FALSE) const
Returns the index'th value (as an integer) and its position in object and data space.
SoVolumeDetail()
Constructor.
virtual SoDetail * copy() const
Returns an instance that is a copy of this instance.
virtual ~SoVolumeDetail()
Destructor.
int SbBool
Boolean type.
Definition SbBase.h:87
std::vector< DataSetIdPair > DataSetIdPairList
List of DataSetIdPair.
Definition SoLDM.h:76