29 #ifndef __PLANARREFLECTOR_H__
30 #define __PLANARREFLECTOR_H__
73 FieldRef< H3DDisplayListObject,
74 H3DDisplayListObject::DisplayList,
75 &H3DDisplayListObject::displayList >, true > {
99 BaseField::onAdd( n );
100 if( n && pr->use_geometry_bound ) {
114 BaseField::onRemove( n );
115 if( n && pr->use_geometry_bound ) {
125 Inst< SFBound > _bound = 0,
126 Inst< SFVec3f > _bboxCenter = 0,
127 Inst< SFVec3f > _bboxSize = 0,
128 Inst< DisplayList > _displayList = 0,
129 Inst< SFGeometryNode > _geometry = 0,
130 Inst< SFFloat > _reflectivity = 0,
131 Inst< SFColor > _color = 0
139 const Vec3f &size = bboxSize->getValue();
140 if( size.x == -1 && size.y == -1 && size.z == -1 ) {
141 use_geometry_bound =
true;
145 g->
bound->route( this->bound );
149 bb->
center->setValue( bboxCenter->getValue() );
150 bb->
size->setValue( bboxSize->getValue() );
151 bound->setValue( bb );
170 virtual bool lineIntersect(
173 LineIntersectResult &result );
180 virtual void closestPoint(
const Vec3f &p,
181 NodeIntersectResult &result );
191 virtual bool movingSphereIntersect(
H3DFloat radius,
194 NodeIntersectResult &result );
223 bool use_geometry_bound;
228 Matrix4f local_to_global;
Contains the DependentSFNode and DependentMFNode template classes.
Header file for H3DDisplayListObject.
Header file for H3DMultiPassRenderObject.
Contains the SFColor field class.
Header file for X3DBoundedObject.
Header file for X3DGeometryNode, X3D scene-graph node.
Header file for X3DGroupingNode, X3D scene-graph node.
Header file for X3DViewpointNode, 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
DependentSFNode are modified TypedSFNode fields where the field dirty status is dependent on fields i...
Definition: DependentNodeFields.h:294
Class used for specifying a field member of a node in a DependentSFNode or DependentMFNode specificat...
Definition: DependentNodeFields.h:48
H3DUniquePtr< SFBound > bound
The field containing the bound object.
Definition: H3DBoundedObject.h:59
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
This abstract interface is inherited by all nodes that needs to render the scene an extra time(or mor...
Definition: H3DMultiPassRenderObject.h:41
Node is the base class for all classes that can be part of the H3D scene-graph.
Definition: Node.h:46
SFGeometryNode is dependent on the displayList field of its encapsulated X3DGeometryNode node,...
Definition: PlanarReflector.h:75
virtual void onAdd(Node *n)
This function will be called when the value of RefCountField changes.
Definition: PlanarReflector.h:97
SFGeometryNode()
Constructor.
Definition: PlanarReflector.h:83
virtual void onRemove(Node *n)
This function will be called when the value of RefCountField changes.
Definition: PlanarReflector.h:112
~SFGeometryNode()
Destructor.
Definition: PlanarReflector.h:87
The PlanarReflector defines a geometry which will act as a mirror in the scene.
Definition: PlanarReflector.h:62
H3DUniquePtr< SFColor > color
The color of the mirror.
Definition: PlanarReflector.h:219
H3DUniquePtr< SFFloat > reflectivity
The reflectivity of the mirror.
Definition: PlanarReflector.h:211
H3DUniquePtr< SFGeometryNode > geometry
Contains the X3DGeometryNode to be rendered.
Definition: PlanarReflector.h:201
virtual void initialize()
Sets up the bound field using the bboxCenter and bboxSize fields.
Definition: PlanarReflector.h:138
static H3DNodeDatabase database
The H3DNodeDatabase for this node.
Definition: PlanarReflector.h:226
TraverseInfo is a structure that is passed along when traversing the scene graph.
Definition: TraverseInfo.h:57
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
This is the base node type for all geometry in X3D.
Definition: X3DGeometryNode.h:61
The X3DViewpointNode node defines a specific location in the local coordinate system from which the u...
Definition: X3DViewpointNode.h:239
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