Skip to content

Custom tracking system

In the event you want to use a tracking system that is currently not natively supported, it's possible to manually send tracking data to MANUS Core.

This does not need to be enabled similar to other tracking systems. An array of tracker positions and rotation is sent to MANUS Core and added to the tracker list. To update tracker transformations a new list with identical trackerIDs is sent again.

Alternatively, data can also be sent using OSC. This allows sending tracking data without implementing the SDK in the tracking software. It also allows sending the tracking data from a different machine than the one running MANUS Core.

Example

Below is an example of sending tracker data from the SDK Client sample.

SendTestTracker (sdk/Trackers.cpp)
SdkResult Trackers::SendTestTracker(float p_HeightOffset)
{
    TrackerData t_Data;
    TrackerData_Init(&t_Data);
    FillTrackerId(t_Data.trackerId, "Test Tracker");
    t_Data.isHmd = false;
    t_Data.trackerType = TrackerType_Unknown;
    t_Data.position = { 0.0f, p_HeightOffset, 0.0f };
    t_Data.rotation = { 1.0f, 0.0f, 0.0f, 0.0f };
    t_Data.quality = TrackingQuality_Trackable;
    t_Data.trackedPoint = TrackedPoint_Casing;
    return CoreSdk_SendDataForTrackers(&t_Data, 1);
}
Tracker Sending Example
def send_test_tracker():
    data = ffi.new("TrackerData*")

    # Write the tracker ID string into the fixed-size char array
    tracker_id = b"Test Tracker"
    ffi.memmove(data.trackerId.id, tracker_id, len(tracker_id))
    data.trackerId.id[len(tracker_id)] = b'\x00'

    data.isHmd = False

    # The bodypart the tracker is tracking
    data.trackerType = TrackerType.Unknown

    data.position.x = 0.0
    data.position.y = 0.0
    data.position.z = 0.0
    data.rotation.w = 1.0
    data.rotation.x = 0.0
    data.rotation.y = 0.0
    data.rotation.z = 0.0
    data.quality = TrackingQuality.Trackable

    # Is the tracker positioned on the glove or tracking the wrist node directly
    data.trackedPoint = TrackedPoint.Casing

    result = lib.CoreSdk_SendDataForTrackers(data, 1)
    if result != SDKReturnCode.Success:
        print(f"Failed to send tracker data. The error given was {result}.")

alt text