00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00026 #include <archon/x3d/server/field_type.H>
00027 #include <archon/x3d/server/field.H>
00028 #include <archon/x3d/server/navigate.H>
00029
00030 namespace Archon
00031 {
00032 namespace X3D
00033 {
00034 const NodeType *Billboard::type = 0;
00035 const NodeType *Viewpoint::type = 0;
00036
00037 void initializeNavigateComponent()
00038 {
00039 vector<const FieldBase *> fields;
00040
00041
00042
00043
00044 fields.push_back(newExposedField("axisOfRotation", SFVec3f::type,
00045 &Billboard::axisOfRotation,
00046 &Billboard::axisOfRotationChanged,
00047 &Billboard::axisOfRotationStamp));
00048 Billboard::type =
00049 NodeType::newConcrete("Billboard", "children",
00050 Billboard::instantiate, &fields,
00051 GroupingNode::type, BoundedObject::type);
00052 fields.clear();
00053
00054
00055
00056
00057 fields.push_back(newExposedField("jump", SFBool::type,
00058 &Viewpoint::jump,
00059 &Viewpoint::jumpChanged,
00060 &Viewpoint::jumpStamp));
00061 fields.push_back(newExposedField("position", SFVec3f::type,
00062 &Viewpoint::position,
00063 &Viewpoint::positionChanged,
00064 &Viewpoint::positionStamp));
00065 fields.push_back(newExposedField("orientation", SFRotation::type,
00066 &Viewpoint::orientation,
00067 &Viewpoint::orientationChanged,
00068 &Viewpoint::orientationStamp));
00069 fields.push_back(newExposedField("fieldOfView", SFFloat::type,
00070 &Viewpoint::fieldOfView,
00071 &Viewpoint::fieldOfViewChanged,
00072 &Viewpoint::fieldOfViewStamp));
00073 fields.push_back(newExposedField("centerOfRotation", SFVec3f::type,
00074 &Viewpoint::centerOfRotation,
00075 &Viewpoint::centerOfRotationChanged,
00076 &Viewpoint::centerOfRotationStamp));
00077 fields.push_back(newPrivateField("description", SFString::type,
00078 &Viewpoint::description));
00079 Viewpoint::type =
00080 NodeType::newConcrete("Viewpoint", "children",
00081 Viewpoint::instantiate, &fields,
00082 BindableNode::type);
00083 fields.clear();
00084 }
00085 }
00086 }