29 #ifndef __X3DGROUPINGNODE_H__
30 #define __X3DGROUPINGNODE_H__
41 class H3DRenderStateObject;
63 FieldRef< H3DDisplayListObject,
64 H3DDisplayListObject::DisplayList,
65 &H3DDisplayListObject::displayList >,
84 virtual void onAdd(
Node *n );
87 virtual void onRemove(
Node *n );
101 virtual void onAdd(
Node *n );
112 virtual void onAdd(
Node *n );
130 AnyNumber< X3DBoundedObject::SFBound > > {
133 virtual void update();
138 Inst< RemoveChildren > _removeChildren = 0,
139 Inst< MFChild > _children = 0,
140 Inst< SFNode > _metadata = 0,
141 Inst< SFBound > _bound = 0,
142 Inst< SFVec3f > _bboxCenter = 0,
143 Inst< SFVec3f > _bboxSize = 0 );
154 const Vec3f &size = bboxSize->getValue();
155 if( size.x == -1 && size.y == -1 && size.z == -1 ) {
156 NodeVector children_nodes = children->getValue();
157 use_union_bound =
true;
160 children->setValue( children_nodes );
162 use_union_bound =
false;
164 bb->
center->setValue( bboxCenter->getValue() );
165 bb->
size->setValue( bboxSize->getValue() );
166 bound->setValue( bb );
172 virtual void render();
184 virtual bool lineIntersect(
187 LineIntersectResult &result );
195 virtual void closestPoint(
const Vec3f &p,
196 NodeIntersectResult &result );
206 virtual bool movingSphereIntersect(
H3DFloat radius,
209 NodeIntersectResult &result );
244 std::pair < H3DTime, H3DTime > getChildTimes ();
247 H3DTime time_in_last_traverseSG;
253 vector< X3DPointingDeviceSensorNode * > pt_dev_sensors;
Header file for ClipPlane, X3D scene-graph node.
Contains the DependentSFNode and DependentMFNode template classes.
Header file for H3DDisplayListObject.
Header file for X3DBoundedObject.
Header file for X3DChildNode, X3D scene-graph node.
Header file for X3DPointingDeviceSensorNode, X3D scene-graph node.
virtual void initialize()
The BoxBound is a Bound class that specifies the bound using an axis-aligned bounding box.
Definition: Bound.h:144
H3DUniquePtr< SFVec3f > center
The center point of the bounding box.
Definition: Bound.h:285
H3DUniquePtr< SFVec3f > size
The size of the bounding box.
Definition: Bound.h:287
DependentMFNode are modified TypedMFNode fields where the field dirty status is dependent on fields i...
Definition: DependentNodeFields.h:336
Class used for specifying a field member of a node in a DependentSFNode or DependentMFNode specificat...
Definition: DependentNodeFields.h:48
We use the Field's lazy evaluation mechanisms to manage the GL display lists for rendering,...
Definition: H3DDisplayListObject.h:60
This abstract interface class is the base class for all node types that wants to create an OpenGL dis...
Definition: H3DDisplayListObject.h:54
H3DUniquePtr< DisplayList > displayList
The DisplayList instance handling the OpenGL caching of this object.
Definition: H3DDisplayListObject.h:256
Node is the base class for all classes that can be part of the H3D scene-graph.
Definition: Node.h:46
TraverseInfo is a structure that is passed along when traversing the scene graph.
Definition: TraverseInfo.h:57
A template modifier class for adding type checking on the routes to any Field class.
Definition: TypedField.h:84
Template to make sure that the Nodes that are added to a MFNode are of a specified Node type.
Definition: MFNode.h:221
This X3D abstract interface type is basis for all X3D node types that have bounds specified as part o...
Definition: X3DBoundedObject.h:46
This abstract node type indicates that the concrete nodes which are instantiated based on it may be u...
Definition: X3DChildNode.h:42
AddChildren is a class that adds any node added to it to the children field of its owner (X3DGrouping...
Definition: X3DGroupingNode.h:99
MFChild sets up a routes from the Nodes that are added and removed from the field to the owner of the...
Definition: X3DGroupingNode.h:66
virtual ~MFChild()
Destructor.
Definition: X3DGroupingNode.h:79
DependentMFNode< X3DChildNode, FieldRef< H3DDisplayListObject, H3DDisplayListObject::DisplayList, &H3DDisplayListObject::displayList >, true > MFChildBase
The base class of MFChild.
Definition: X3DGroupingNode.h:74
RemoveChildren is a class that removes any node added to it from the children field of its owner (X3D...
Definition: X3DGroupingNode.h:110
SFBound is specialized to update from the SFBound fields routed to it.
Definition: X3DGroupingNode.h:130
This abstract node type indicates that concrete node types derived from it contain children nodes and...
Definition: X3DGroupingNode.h:53
virtual void initialize()
Sets up the bound field using the bboxCenter and bboxSize fields.
Definition: X3DGroupingNode.h:153
H3DUniquePtr< AddChildren > addChildren
The addChildren event appends nodes to the children field of a grouping node.
Definition: X3DGroupingNode.h:222
H3DUniquePtr< MFChild > children
The nodes that are grouped together by this node.
Definition: X3DGroupingNode.h:238
vector< H3DRenderStateObject * > render_states
A vector of all the H3DRenderStatesObject within this X3DGroupingNode.
Definition: X3DGroupingNode.h:262
bool use_union_bound
if true a route will be set up between the bound field of the nodes in children and the bound field o...
Definition: X3DGroupingNode.h:213
vector< ClipPlane * > clip_planes
A vector of only ClipPlane children of this X3DGroupingNode.
Definition: X3DGroupingNode.h:265
H3DUniquePtr< RemoveChildren > removeChildren
The removeChildren event removes nodes from the children field of the grouping node .
Definition: X3DGroupingNode.h:231
static H3DNodeDatabase database
The H3DNodeDatabase for this node.
Definition: X3DGroupingNode.h:241
bool children_multi_pass_transparency
Will be set in traverseSG to indicate if any of the children enables multi-pass transparency.
Definition: X3DGroupingNode.h:259
H3D API namespace.
Definition: Anchor.h:38
The H3DNodeDatabase contains a mapping between a name of a Node and the constructor for the Node with...
Definition: H3DNodeDatabase.h:194