Open Inventor Release 2024.2.0
 
Loading...
Searching...
No Matches
SoVolumeDataElement.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 (Feb 2000)
22** Modified by : J. HUMMEL to collect multiple volume data node (Apr 2005)
23**=======================================================================*/
24
25
26#ifndef _SO_VOLUME_DATA_ELEMENT_
27#define _SO_VOLUME_DATA_ELEMENT_
28
29#include <LDM/elements/SoDataSetElement.h>
30#include <VolumeViz/nodes/SoVolumeData.h>
31
32//wrapper
37
38public:
39 static void set(SoState* state, SoNode *node, SoVolumeData *volumeDataNode)
40 {
41 SoDataSetElement::set(state, node, (SoDataSet*)volumeDataNode);
42 }
43
44 static void set(SoState *state, SoNode *node,
45 SoVolumeData *volumeDataNode, const SbMatrix &matrix )
46 {
47 SoDataSetElement::set(state, node, (SoDataSet*)volumeDataNode, matrix);
48 }
49
50 static void get(SoState* state, std::vector<SoVolumeData*>& s)
51 {
52 std::vector<SoDataSet*> temp;
53 SoDataSetElement::get(state, temp);
54 for(unsigned int i = 0 ; i < temp.size() ; i++ ){
55 s.push_back((SoVolumeData*)temp[i]);
56 }
57 }
58
59
60 static void get(SoState* state, SoVolumeData*& vd)
61 {
62 std::pair<SoVolumeData*, int> p = SoDataSetElement::getLastOfType<SoVolumeData>(state, true);
63 vd = p.first;
64 }
65
66 static const SbMatrix &get(SoState *state, SoVolumeData*& v, SbBool &isIdent )
67 {
68 return SoDataSetElement::get(state, (SoDataSet*&)v, isIdent);
69 }
70};
71
72#endif // _SO_VOLUME_DATA_ELEMENT_
73
74
4x4 matrix class.
Definition SbMatrix.h:309
static void get(SoState *state, std::vector< SoDataSet * > &)
static void set(SoState *state, SoNode *node, SoDataSet *datasetNode)
<a href="IconLegend.html"><img src="extLDM.gif" alt="Large Data Management" border="0"></a> Data set...
Definition SoDataSet.h:139
Abstract base class for all database nodes.
Definition SoNode.h:145
Traversal state.
Definition SoState.h:74
static void get(SoState *state, SoVolumeData *&vd)
static void set(SoState *state, SoNode *node, SoVolumeData *volumeDataNode)
static void get(SoState *state, std::vector< SoVolumeData * > &s)
static const SbMatrix & get(SoState *state, SoVolumeData *&v, SbBool &isIdent)
static void set(SoState *state, SoNode *node, SoVolumeData *volumeDataNode, const SbMatrix &matrix)
<a href="IconLegend.html"><img src="extVR.gif" alt="VolumeViz" border="0"></a> Volume data property ...
int SbBool
Boolean type.
Definition SbBase.h:87