Vicon Toolkit Documentation 2
IlabViconToolkit Namespace
ViconManager Class
Description
This is a static singleton class that interfaces directly with the Vicon Nexus to retrieve and interpret low-level information about the tracked objects.
Properties
- bool IsConnected - Gets a value of true if the ViconManager object is connected to the Vicon Nexus. Otherwise it returns false.
- IPAddress IP - Gets or sets the target IP address of the Nexus.
- int Port - Gets or sets the target port of the Nexus.
- float FrameRate - Gets the frame rate returned by the Nexus.
- List<ViconSubject> Subjects - A list of ViconSubject objects representing subject data returned from the Nexus.
- int HistoryDepth - Gets or sets the number of history frames to keep.
- int HistoryInterval - Gets or sets the frequency on which history frames are stored.
- int HistorySmooth - Gets or sets how many frames are averaged when producing the next history frame.
- bool Reconstruct - Gets or sets whether the toolkit should attempt to reconstruct the positions of missing/non-visible markers.
- int AutoPollInterval - Gets or sets the interval in milliseconds for automatic Nexus polling.
- bool AutoPollingEnabled - Gets or sets whether the ViconManager should automatically poll the Nexus for updated data, according to the AutoPollInterval.
- Matrix WorldBasis - Gets the matrix representing the world coordinate space.
- Matrix WorldBasisInverse - Gets the inverse of the WorldBasis.
Methods
- ViconSubject GetSubject(int index) - Returns the subject at the given index.
- ViconSubject GetSubject(string key) - Return the subject with the given name.
- bool HasSubject(string key) - Returns true if a subject with the given key name exists in the collection of subjects.
- void ManualPoll() - Used to manually poll the Nexus for updated data. Will throw an exception if AutoPollingEnabled is set to true.
- void Connect() - Called to attempt a connection to the Nexus using the specified IP and Port.
- void Disconnect() - Called to terminate an existing connection to the Nexus.
Events
- EventHandler Connected - Triggered when a connection is successfully established to the Nexus.
- EventHandler ConnectionFailed - Triggered when a connection attempt to the Nexus encounters a failure.
- EventHandler Disconnected - Triggered when the ViconManager disconnects from the Nexus.
- EventHandler SchemaUpdated - Triggered when the ViconManager receives a new or altered data schema. This is called once when the ViconManager first connects to the Nexus and retrieves the subjects list. It can be triggered later if a subject is added/removed or if the subject segment/joint/marker schema is altered.
- EventHandler DataUpdated - Triggered when the ViconManager receives new data from the Nexus. Called as a result of invoking ManualPoll or on the interval of automatic polling. The ViconManager is populated with the new data prior to invoking this event, so the event handler may access the new data when called.
ViconSubject Class
Description
Represents a known subject or body that the Vicon Nexus is tracking.
Properties
- string Name - Gets the name of the subject, which uniquely identifies it.
- ViconMarkerSet Markers - Returns a collection of ViconMarker objects which represent all markers within the subject.
- ViconSegmentSet Segments - Returns a collection of ViconSegment objects which represents all segments within the subject.
- ViconJointSet Joints - Returns a collection of ViconJoint objects which represents all joints within the subject.
- bool IsValid - Returns true if the ViconSubject is part of the current tracking schema.
- bool IsPresent - Returns true if the Nexus has received data for the subject, returns false otherwise.
- bool IsVisible - Returns true if the Nexus captured the subject on the last data update. False may indicate the subject has left the tracking area.
- int DetectedMarkerCount - Returns the number of markers actually captured by the Vicon Nexus. This number will be less than or equal to the total number of markers for this subject, depending on occlusion and visual range of the Vicon cameras.
- ViconManager Parent - Returns the ViconManager object to which this subject belongs.
- bool IsBound - Returns true if the subject was properly bound to a Vicon Skeleton Definition, false if not. NOTE: The Vicon Toolkit expects a copy of the Vicon Skeleton file (.VSK) of all tracked subjects to be present in the /subjects folder, which is a subfolder adjacent to the executable.
- List<ViconMarker[]> Sticks - Returns a list of start and end markers that connect the subject markers together into a visible structure. This is usually a trivial definition used within the Nexus software, however it may be useful for displaying objects.
Methods
- ViconMarker GetOriginMarker() - Attempts to find the marker with local coordinates of (0, 0, 0). If not, it returns the first marker in the set of markers.
- Vector3 WorldToPlane(Vector3 vec) - Converts a vector in world coordinates to the coordinate system defined by the 3 basis markers of the subject.
- Vector3 PlaneToWorld(Vector3 vec) - Converts a vector from the coordinate system defined by the 3 basis markers of the subject to world coordinates.
- Vector3 LocalToPlane(Vector3 vec) - Converts a vector from local subject coordinates to coordinate system defined by the 3 basis markers of the subject.
- Vector3 PlaneToLocal(Vector3 vec) - Converts a vector from coordinate system defined by the 3 basis markers of the subject to local subject coordinates.
- Vector3 WorldToLocal(Vector3 vec) - Converts a vector in world coordinates to local subject coordinates.
- Vector3 LocalToWorld(Vector3 vec) - Converts a vector in local subject coordinates to world coordinates.
Events
- EventHandler Invalidated - Occurs when the schema has changed and the current subject information is no longer valid.
- EventHandler VisibleChanged - Occurs when the IsVisible property changes.
ViconSegment Class
Description
An object that represents a rigid component of a subject. Every subject has at least one segment, which at the very least represents the entire object as a rigid body. Subjects with joints will have more than one segment, representing rigid parts that hinge together on the joint.
Properties
- string Name - Gets the name of the segment, which uniquely identifies it within the subject.
- bool IsValid - Returns true if the ViconSegment object is part of the current tracking schema.
- double AngleValue - The angle of the segment, relative to the Angle Axis.
- Vector3 AngleAxis - Returns a normalized vector representing the axis of the angle.
- double ElevationAngle - The angle between the segment and the "ground" (X/Y plane).
- double AzimuthAngle - The angle of the segment about the Z axis, where 0 is the +X direction, 90 is the +Y direction, 180 is the -X direction, and 270 is the -Y direction (relative to World Coordinates).
- Vector3 Location - Returns the location of the segment in World Coordinates.
- ViconSubject Parent - Returns the parent ViconSubject object.
- double PitchAngle - Returns the angle of Pitch (rotation about the X axis).
- double YawAngle - Returns the angle of Yaw (rotation about the Z axis).
- double RollAngle - Returns the angle of Roll (rotation about the Y axis).
- ViconMarkerSet Markers - Returns the list of ViconMarkers that belong to this segment.
- Vector3 CentreOfMass - Returns the point designated as the centre of mass of the segment.
- List<ViconTag> Tags - Returns a list of pre-parsed vicon tags for manual access to joint information.
Methods
- This object does not define any methods.
Events
- EventHandler Invalidated - Occurs when the schema has changed and the current segment information is no longer valid.
ViconJoint Class
Description
An object that represents a joint amongst ViconSegments within a subject. Rigid objects (with one single segment) do not have joints. (NOTE: At the current time, this is only a stub class and has yet to be fully implemented and tested.)
Properties
- string Name - Gets the name of the segment, which uniquely identifies it within the subject.
- bool IsValid - Returns true if the ViconSegment object is part of the current tracking schema.
- ViconSubject Parent - Returns the parent ViconSubject object.
- List<ViconTag> Tags - Returns a list of pre-parsed vicon tags for manual access to joint information.
Methods
- This object does not define any methods.
Events
- EventHandler Invalidated - Occurs when the schema has changed and the current joint information is no longer valid.
ViconMarker Class
Description
An object representing a marker within the subject.
Properties
- string Name - Gets the name of the segment, which uniquely identifies it within the subject.
- bool IsValid - Returns true if the ViconSegment object is part of the current tracking schema.
- ViconSubject Parent - Returns the parent ViconSubject object.
- List<ViconTag> Tags - Returns a list of pre-parsed vicon tags for manual access to joint information.
- bool IsRequired - Returns true if the marker is one of the required basis markers, false if not.
- bool IsDetected - Returns true if the marker position was detected by the Nexus, false if it was not visible.
- bool IsReconstructed - Returns true if the marker was not visible, and it's position was reconstructed.
- bool IsAvailable - Returns true if the marker position was detected by the Nexus, or its value was reconstructed. Returns false if the position could not be found by either method.
- Vector3 Location - Returns the marker's position in World Coordinates.
- Vector3 ModelPosition - Returns the marker's position within the model/skeleton definition.
- Vector3 Velocity - A vector containing the velocity of the marker along each axis.
- Vector3 Acceleration - A vector containing the acceleration of the marker along each axis.
- MarkerHistory History - Returns the history queue for this marker.
Methods
- This object does not define any methods.
Events
- EventHandler Invalidated - Occurs when the schema has changed and the current marker information is no longer valid.
IlabViconToolkit.Space Namespace
ViconSpace Component
Description
A component to encapsulate a set of TrackedSubjects, DisplayPlanes, etc. and track the relationships between them.
Properties
- DisplayPlane[] Displays - Gets the current list of DisplayPlane objects.
- TrackedSubject[] Subjects - Gets the current list of TrackedSubject objects.
- Matrix Basis - Gets the matrix representing the custom coordinate space.
- Matrix BasisInverse - Gets the inverse of the Basis.
- Vector3 Origin - Gets the World Space coordinate of the ViconSpace origin.
- static double SubjectChangeThreshold - Gets or sets the threshold value for a subject's movement to register as a change.
Methods
- void SetBasis(Vector3 up, Vector3 front, Vector3 left) - Allows you to define a custom coordinate system.
- void AddSubject(TrackedSubject subj) - Adds a tracked subject to the space.
- boolContainsSubject(TrackedSubject subj) - Returns true if the tracked subject has already been added.
- void RemoveSubject(TrackedSubject subj) - Removes a tracked subject from the space.
- void ClearSubjects() - Removes all tracked subjects from the space.
- void AddDisplay(DisplayPlane disp) - Adds a display to the space.
- boolContainsDisplay(DisplayPlane disp) - Returns true if the display has already been added.
- void RemoveDisplay(DisplayPlane disp) - Removes a display from the space.
- void ClearDisplay() - Removes all displays from the space.
- PlaneSubjectRelation GetRelation(TrackedSubject subj, DisplayPlane disp) - Gets the relation details between a TrackedSubject and a DisplayPlane.
- SubjectRelation GetRelation(TrackedSubject subj1, TrackedSubject subj2) - Gets the relation details between two different TrackedSubjects.
- static Vector3 WorldToSpace(Vector3 worldcoords, ViconSpace space) - Translates world coordinates to the custom ViconSpace coordinate system.
- static Vector3 SpaceToWorld(ViconSpace space, Vector3 spacecoords) - Translates ViconSpace coordinates to world coordinates.
- static Vector3 WorldToPlane(Vector3 worldcoords, Plane plane) - Translates world coordinates to the coordinates of a plane.
- static Vector3 PlaneToWorld(Plane plane, Vector3 planecoords) - Translates plane coordinates to world coordinates.
- static Vector3 SpaceToPlane(ViconSpace space, Vector3 spacecoords, Plane plane) - Translates ViconSpace coordinates to plane coordinates.
- static Vector3 PlaneToSpace(Plane plane, Vector3 planecoords, ViconSpace space) - Translates plane coordinates to ViconSpace coordinates.
- static double GetAngleDegrees(double radians, double x, bool accute) - Translates an acute angle from radians to an accute/obtuse angle in degrees.
- static Matrix VectorToMatrix(Vector3 vec) - Transforms a vector object to its representation as a 3x1 matrix.
- static Vector3 MatrixToVector(Matrix mat) - Transforms a 3x1 matrix object to its representation as a vector.
Events
- SubjectChangedHandler SubjectAdded - Occurs when a TrackedSubject is added to the space.
- SubjectChangedHandler SubjectRemoved - Occurs when a TrackedSubject is removed from the space.
- DisplayChangedHandler DisplayAdded - Occurs when a DisplayPlane is added to the space.
- DisplayChangedHandler DisplayRemoved - Occurs when a DisplayPlane is removed from the space.
TrackedSubject Class
Description
A class that represents an object that is being tracked, within a ViconSpace. NOTE: This is an abstract class that must be inherited to represent a specific subject.
Properties
- string Name - The name of the underlying ViconSubject.
- ViconSubject ViconSubject - The underlying ViconSubject object.
- Vector3 Location - A single point that represents the location of the subject in world coordinates. By default, this is the result of GetOrigin().
- Vector3 CentroidLocation - A point that represents the subject's centre of mass. By default, this is the result of MassMarker.Location.
- ViconMarker MassMarker - A marker that represents the subject's centre of mass. By default, this is the result of GetOriginMarker().
- bool CanPoint - Returns true if the TrackedSubject contains one or more PointingRays.
- PointingRay DefaultPointingRay - Returns a PointingRay that defines the default pointing direction.
- bool IsTracking - Returns true if the ViconSubject is being tracked by the Vicon system.
- bool IsVisible - Returns true if the ViconSubject is being tracked and is visible, false otherwise.
- intHoverInterval - Gets or sets the number of milliseconds that the TrackedSubject must be (relatively) still before the SubjectHover event is fired. Default is 50 milliseconds.
- double PitchAngle - Returns a pitch value representative of the entire subject. By default, this is the pitch value of the first segment.
- double YawAngle - Returns a yaw value representative of the entire subject. By default, this is the yaw value of the first segment.
- double RollAngle - Returns a roll value representative of the entire subject. By default, this is the roll value of the first segment.
- double ElevationAngle - Returns an elevation angle representative of the entire subject. By default, this is the eleveation angle of the first segment.
- double AzimuthAngle - Returns an azimuth angle representative of the entire subject. By default, this is the azimuth angle of the first segment.
- double Velocity - Returns a velocity magnitude value representative of the entire subject.
- double Acceleration - Returns an acceleration magnitude value representative of the entire subject.
- Vector3 VelocityVector - Returns a vector of velocity magnitudes in each axis, representative of the entire subject.
- Vector3 AccelerationVector - Returns a vector of acceleration magnitudes in each axis, representative of the entire subject.
- ICollidible CollisionVolume - Returns a collision volume object that approximates the physical space occupied by the subject.
Methods
- protected virtual void OnSubjectAdded() - Callback that must create all pointing rays and define the collision volume.
- protected virtual void OnSubjectRemoved() - Callback that must clear all pointing rays and destroy the collision volume.
- protected virtual void OnUpdatePointingVectors() - Callback that must update all pointing rays according to the current position of subject markers.
- protected virtual void OnUpdateCollisionVolume() - Callback that must update the collision volume according to the current position of subject markers.
- protected virtual void OnSetCentreMass(out int segment, out Vector3 position) - Callback that must set the centre of mass location, and the segment index that it belongs to.
- protected virtual Vector3 GetOrigin() - Returns the origin location of the origin marker.
- protected void AddPointingRay(string rayname, ViconSegment segment, double touchdistance) - Creates a pointing ray entry for this TrackedSubject, with the given name, attached to the given segment, with the given distance to register a touch.
- protected void RemovePointingRay(string rayname) - Removes the pointing ray with the given name, if it exists.
- protected void ClearPointingRays() - Removes all pointing rays.
- PointingRay GetPointingRay(string rayname) - Returns the ray with the given name.
- PointingRay[] GetPointingRays() - Returns all pointing rays in the TrackedSubject.
Events
- SubjectChangedHandler StatusChanged - Occurs when the underlying ViconSubject is added or removed.
- SubjectChangedHandler SubjectMove - Occurs when the subject's location changes beyond a threshold.
- SubjectChangedHandler SubjectHover - Occurs when the subject's location remains below a threshold for a given period of time.
- EventHandler VisibleChanged - Occurs when the ViconSubject's visibility changed.
DisplayPlane Class
Description
An object that represents the area of a display in a ViconSpace.
Properties
- string ID - A string that uniquely identifies this display from others.
- FileInfo ConfigFile - Gets a generated filename for display configuration information, based on the ID.
- Orientation DisplayType - Gets an indication of the orientation of the display - Horizontal, Vertical, or Other.
- bool IsCalibrated - Returns true if the display area has been calibrated.
- bool IsCalibrating - Returns true if the display has entered calibration state.
- Vector3 TopLeftCorner - Returns the top left-hand corner of the display in world coordinates.
- Vector3 TopRightCorner - Returns the top right-hand corner of the display in world coordinates.
- Vector3 BottomLeftCorner - Returns the bottom left-hand corner of the display in world coordinates.
- Vector3 BottomRightCorner - Returns the bottom right-hand corner of the display in world coordinates.
- Vector3 Center - Returns the location of the center of the display in world coordinates.
- double Width - Returns the width of the display in world units.
- double Height - Returns the height of the display in world units.
- PointF Location - Returns the coordinates of the top left-hand corner of the display area, in plane coordinates.
- SizeF Size - Returns the size of the display area in world units.
- RectangleF Bounds - Returns the bounds of the display on the plane.
- Vector3 ScreenXAxis - Returns the vector representing the X-Axis of the display.
- Vector3 ScreenYAxis - Returns the vector representing the Y-Axis of the display.
Methods
- bool Contains(PointF pt) - Returns true if the given point (in plane coordinates) is contained within the display bounds.
- void BeginCalibration() - Puts the display into calibration mode.
- void EndCalibration() - Finalizes the calibration and takes the display out of calibration mode.
- void SaveConfiguration() - Saves the display calibration to the ConfigFile adjacent to the executable.
- bool LoadConfiguration() - Attempts to load the display calibration from the ConfigFile - returns false if it doesn't exist.
- void ShowCalibrationDialog() - Automatically enters calibration mode, calls up a Dialog Box to assist the user in calibrating the display, saves the resulting configuration, and ends calibration mode.
Events
- DisplayChangedHandler CalibrationChanged - Occurs when the calibration mode changes.
PointingRay Class
Description
A class to represent a ray that emerges from the subject which is used to point at displays or other subjects in the space.
Properties
- ViconSegment Segment - The ViconSegment that the pointing ray is anchored to.
- string Name - The unique name of the pointing ray.
- double TouchDistance - The minimum distance that the origin of the pointing ray must be to another object to register a touch.
- Vector3 Origin - The starting point of the ray.
- Vector3 Direction - The normalized direction vector of the ray.
Methods
- CollisionDetails CollidesWith(ICollidible obj) - Returns the details of the collision with another object, if a collision exists.
- object Clone() - Returns a duplicate copy of the PointingRay.
PlaneSubjectRelation Class
Description
A class that contains the details of the relationship between a particular subject and display plane.
Properties
- ViconSpace Space - Gets the space that the subject and display plane are part of.
- DisplayPlane Display - Gets the display that comprises the relation.
- TrackedSubject Subject - Gets the subject that comprises the relation.
- CollisionDetails CollisionDetails - Gets the details of the collision between the subject and display plane, if one exists.
Indexers
- RayPlaneRelation this[PointingRay key] - Returns the relation between the specified pointing ray and the display plane.
- RayPlaneRelation this[string key] - Returns the relation between the ray with the specified name and the display plane.
Methods
- This class has no methods.
Events
- PlaneSubjectUpdateHandler CollisionEnter - Occurs when a collision is first detected.
- PlaneSubjectUpdateHandler CollisionLeave - Occurs when colliding objects are first separated.
SubjectRelation Class
Description
A class that contains the details of the relationship between two particular TrackedSubjects.
Properties
- ViconSpace Space - The ViconSpace that contains the subjects.
- TrackedSubject Subject1 - The first subject in the relation.
- TrackedSubject Subject2 - The second subject in the relation.
- CollisionDetails CollisionDetails - Gets the details of the subject collision, if one has occurred.
Indexers
- RaySubjectRelation this[TrackedSubject subj, PointingRay ray] - Gets the relation between a particular TrackedSubject and PointingRay.
- RaySubjectRelation this[string subjname, string rayname] - Gets the relation between a particular TrackedSubject and PointingRay.
Methods
- This class has no methods.
Events
- SubjectSubjectUpdateHandler CollisionEnter - Occurs when a collision is first detected.
- SubjectSubjectUpdateHandler CollisionLeave - Occurs when colliding objects are first separated.
RayPlaneRelation Class
Description
A class that contains the details of the relationship between a PointingRay and a DisplayPlane.
Properties
- bool PointsToward - Returns true if the pointing ray points toward the plane, false if it is parallel or points away.
- bool PointsInto - Return true if the pointing ray intersects with the plain within the display bounds, false if not.
- double Distance - Returns the distance between the pointing ray origin and the ray intersection with the plane.
- Vector3 WorldIntersection - Returns the ray intersection point in world coordinates.
- Vector3 PlaneIntersection - Returns the ray intersection point in plane coordinates.
- bool IsTouching - Returns true if the PointingRay is close enough to the plane to register a touch.
Events
- RayPlaneUpdateHandler DisplayEnter - Occurs when the intersection point enters the display bounds.
- RayPlaneUpdateHandler DisplayLeave - Occurs when the intersection point leaves the display bounds.
- RayPlaneUpdateHandler PointMove - Occurs when the intersection point changes significantly.
- RayPlaneUpdateHandler TouchDown - Occurs when the pointing ray touches the plane.
- RayPlaneUpdateHandler TouchUp - Occurs when a pointing ray stops touching the plane.
RaySubjectRelation Class
Description
A class that contains the details of the relationship between a PointingRay and a TrackedSubject.
Properties
- bool PointsToward - Returns true if the pointing ray points toward the subject, false if it is parallel or points away.
- bool PointsInto - Return true if the pointing ray intersects with the subject, false if not.
- double PointAngle - The angle between the ray and the origin of the TrackedSubject.
- Vector3 PointAxis - The rotation axis between the ray and the origin of the TrackedSubject.
- double Distance - The distance between the PointingRay's origin and the intersection with the TrackedSubject's collision bounds.
- Vector3 Intersection - The ray's point of intersection with the TrackedSubject's collision bounds.
- bool IsTouching - Returns true if the PointingRay is close enough to the TrackedSubject's collision bounds to register a touch.
Events
- RaySubjectUpdateHandler PointEnter - Occurs when the ray intersects with the collision volume.
- RaySubjectUpdateHandler PointLeave - Occurs when the ray ceases to intersect with the collision volume.
- RaySubjectUpdateHandler PointMove - Occurs when the ray intersection point moves.
- RaySubjectUpdateHandler TouchDown - Occurs when the pointing ray touches the collision bounds.
- RaySubjectUpdateHandler TouchUp - Occurs when the pointing ray stops touching the collision bounds.
IlabViconToolkit.Collision Namespace
CollisionDetails Class
Description
A class that contains the details of the collision between two ICollidible objects.
Properties
- bool Collides - Returns true if a collision occurs, false if not.
- double Distance - The distance between two collidible objects, when applicable.
- Vector3 IntersectPoint - The point of intersection between collidible objects, when applicable.
- Vector3 NearestPoint - The nearest point of intersection between collidible objects, when applicable.
Plane Class
Description
A class that represents a plane in 3-space.
Properties
- Matrix Basis - A matrix representing the plane coordinate space.
- Matrix BasisInverse - The inverse of the Basis.
- bool HasBasis - Returns true if the basis is available for this plane, false if not.
- Vector3 Normal - Returns a representative normal to the plane surface.
- Vector3 Point - Returns a representative point on the plane.
- Vector3 XAxis - Returns the X-axis that defines the plane coordinate space.
- Vector3 YAxis - Returns the Y-axis that defines the plane coordinate space.
Methods
- void Set(Vector3 point, Vector3 xaxis, Vector3 yaxis) - Sets the various properties of the plane.
Ray
Description
A class that represents a ray in 3-space.
Properties
- Vector3 Origin - The starting point of the ray.
- Vector3 Direction - The normalized direction vector of the ray.
Methods
- void Set(Vector3 origin, Vector3 direction) - Sets the ray data.
- CollisionDetails CollidesWith(ICollidible obj) - Returns the details of the collision with another object, if a collision exists.
- object Clone() - Creates an exact copy of this object with a different object reference.
Sphere
Description
A class that represents a sphere in 3-space.
Properties
- Vector3 Centroid - The center point of the sphere.
- double Radius - The radius of the sphere about the centroid.
Methods
- void Set(Vector3 centroid, double radius) - Sets the sphere data.
- CollisionDetails CollidesWith(ICollidible obj) - Returns the details of the collision with another object, if a collision exists.
- object Clone() - Creates an exact copy of this object with a different object reference.
IlabViconToolkit.Controls Namespace
CalibrateDisplayPlaneForm Form
Description
A form that assists the user to calibrate a DisplayPlane.
Properties
- Vector3 TopLeftCoordinate - Returns the new TopLeft corner of the plane.
- Vector3 TopRightCoordinate - Returns the new TopRight corner of the plane.
- Vector3 BottomLeftCoordinate - Returns the new BottomLeft corner of the plane.
- Vector3 BottomRightCoordinate - Returns the new BottomRight corner of the plane.
ViconComponent Component
Description
A component that allows access to static properties, methods and events of the ViconManager class.
Properties
- IPAddress IP - Gets or sets the target IP address of the Nexus.
- int Port - Gets or sets the target port of the Nexus.
- int HistoryDepth - Gets or sets the number of history frames to keep.
- int HistoryInterval - Gets or sets the frequency on which history frames are stored.
- int HistorySmooth - Gets or sets how many frames are averaged when producing the next history frame.
- bool Reconstruct - Gets or sets whether the toolkit should attempt to reconstruct the positions of missing/non-visible markers.
- int AutoPollInterval - Gets or sets the interval in milliseconds for automatic Nexus polling.
- bool AutoPollingEnabled - Gets or sets whether the ViconManager should automatically poll the Nexus for updated data, according to the AutoPollInterval.
Methods
- ViconSubject GetSubject(int index) - Returns the subject at the given index.
- ViconSubject GetSubject(string key) - Return the subject with the given name.
- bool HasSubject(string key) - Returns true if a subject with the given key name exists in the collection of subjects.
- void ManualPoll() - Used to manually poll the Nexus for updated data. Will throw an exception if AutoPollingEnabled is set to true.
- void Connect() - Called to attempt a connection to the Nexus using the specified IP and Port.
- void Disconnect() - Called to terminate an existing connection to the Nexus.
Events
- EventHandler Connected - Occurs when a connection to the Nexus is established.
- EventHandler ConnectionFailed - Occurs if a connection to the Nexus is rejected.
- EventHandler Disconnected - Occurs when the connection to the Nexus is terminated.
- EventHandler DataUpdated - Occurs when the Nexus data is updated.
- EventHandler SchemaUpdated - Occurs when the Nexus channel information is updated.
ViconConnectionDialog Form
Description
Allows the user to specify the IP address and port of the connection to the Nexus.
ViconMarkerMonitor Control
Description
A control that displays the properties of a given ViconMarker as it is updated in real time.
Properties
- ViconMarker ViconMarker - The ViconMarker object to monitor.
- int DecimalPlaces - The number of decimal places to use while displaying double precision numbers.
ViconSegmentMonitor Control
Description
A control that displays the properties of a given ViconSegment as it is updated in real time.
Properties
- ViconSegment ViconSegment - The ViconSegment object to monitor.
- int DecimalPlaces - The number of decimal places to use while displaying double precision numbers.
ViconSpaceTree Control
Description
A control that displays a treeview of all TrackedSubjects and DisplayPlanes within the given ViconSpace.
Properties
- ViconSpace Space - The ViconSpace to view.
- TrackedSubject SelectedSubject - Gets or sets the currently selected subject.
- DisplayPlane SelectedDisplay - Gets or sets the currently selected display.
ViconSpaceView2D Control
Description
A control that gives a 2D visual representation of Tracked Subjects, DisplayPlanes, and relations within the given ViconSpace.
Properties
- ViconSpace Space - The ViconSpace to visualize.
- View2DAxes View2D - Gets or sets the 2D view.
- float GridInterval - Gets or sets the frequency of major gridlines.
- int GridSubdivisions - Gets or sets the number of subdivisions between major gridlines.
- bool AllowViewSelect - Gets or sets whether the user can change the 2D view from the context menu.
- bool AllowZoomSelect - Gets or sets whether the user can change the zoom from the context menu.
ViconWorldTree Control
Description
A control that displays a treeview of all ViconSubjects and subcomponents, including ViconMarkers, ViconSegments, and ViconJoints.
Properties
- ViconSubject SelectedSubject - Gets or sets the selected ViconSubject node.
- ViconMarker SelectedMarker - Gets or sets the selected ViconMarker node.
- ViconSegment SelectedSegment - Gets or sets the selected ViconSegment node.
- ViconJoint SelectedJoint - Gets or sets the selected ViconJoint node.
ViconWorldView2D Control
Description
A control that gives a 2D visual representation of all tracked ViconSubjects in world space, with the option of displaying one or more DisplayPlanes.
Properties
- View2DAxes View2D - Gets or sets the 2D view.
- float GridInterval - Gets or sets the frequency of major gridlines.
- int GridSubdivisions - Gets or sets the number of subdivisions between major gridlines.
- bool AllowViewSelect - Gets or sets whether the user can change the 2D view from the context menu.
- bool AllowZoomSelect - Gets or sets whether the user can change the zoom from the context menu.