00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00027
00029 #ifndef __INDEXEDLINESET_H__
00030 #define __INDEXEDLINESET_H__
00031
00032 #include "X3DGeometryNode.h"
00033 #include "DependentNodeFields.h"
00034 #include "X3DCoordinateNode.h"
00035 #include "X3DColorNode.h"
00036 #include "CoordBoundField.h"
00037 #include "IndexedLineSet.h"
00038 #include "MFInt32.h"
00039
00040 namespace H3D {
00041
00106 class H3DAPI_API IndexedLineSet : public X3DGeometryNode {
00107 public:
00110 H3D_VALUE_EXCEPTION( int, InvalidColorIndex );
00111
00114 H3D_VALUE_EXCEPTION( int, InvalidColorIndexSize );
00115
00118 typedef DependentSFNode< X3DCoordinateNode,
00119 FieldRef< X3DGeometricPropertyNode,
00120 Field,
00121 &X3DCoordinateNode::propertyChanged > >
00122 SFCoordinateNode;
00123
00126 typedef DependentSFNode< X3DColorNode,
00127 FieldRef< X3DGeometricPropertyNode,
00128 Field,
00129 &X3DColorNode::propertyChanged > >
00130 SFColorNode;
00131
00133 IndexedLineSet( Inst< SFNode > _metadata = 0,
00134 Inst< CoordBoundField > _bound = 0,
00135 Inst< DisplayList > _displayList = 0,
00136 Inst< MFInt32 > _set_colorIndex = 0,
00137 Inst< MFInt32 > _set_coordIndex = 0,
00138 Inst< SFColorNode > _color = 0,
00139 Inst< SFCoordinateNode > _coord = 0,
00140 Inst< MFInt32 > _colorIndex = 0,
00141 Inst< SFBool > _colorPerVertex = 0,
00142 Inst< MFInt32 > _coordIndex = 0 );
00143
00144 #ifdef USE_HAPTICS
00147 virtual void traverseSG( TraverseInfo &ti );
00148 #endif
00149
00151 virtual void render();
00152
00157 auto_ptr< MFInt32 > set_colorIndex;
00158
00163 auto_ptr< MFInt32 > set_coordIndex;
00164
00174 auto_ptr< SFColorNode > color;
00175
00181 auto_ptr< SFCoordinateNode > coord;
00182
00191 auto_ptr< MFInt32 > colorIndex;
00192
00200 auto_ptr< SFBool > colorPerVertex;
00201
00210 auto_ptr< MFInt32 > coordIndex;
00211
00213 static H3DNodeDatabase database;
00214 };
00215 }
00216
00217 #endif