Repository navigation
Conversation
rigidBodies() and rigidBodyByName() asked the DataStream SDK for the
segment named after the subject. Vicon Tracker names an object's segment
that way, but other setups name it differently ("root" here), and such
subjects were never reported, so motion_capture_tracking published no
poses at all. Ask the SDK for the subject's root segment instead, falling
back to the subject's name if that call fails.
Tested against a Vicon system streaming one object at 120 Hz (subject
"cf1", root segment "root"): no poses before, cf1 at 119.8 Hz after.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
MotionCaptureVicon::rigidBodies()andrigidBodyByName()read the pose withGetSegmentGlobalTranslation(name, name), that is, from the segment named after the subject. Vicon Tracker names an object's single segment after the object, but not every setup does; ours names itroot. For such subjects both lookups fail withInvalidSegmentName, the subject is skipped, andmotion_capture_trackingpublishes no poses at all, with no warning.Fix
Ask the DataStream SDK for the subject's root segment (
GetSubjectRootSegmentName) and read the pose from it, falling back to the subject's name if that call fails. Where the segment is named after the subject, the root segment is that segment, so existing setups behave as before.Testing
A Vicon system streaming one object at 120 Hz (subject
cf1, root segmentroot, as reported by the SDK's test client), read throughmotion_capture_trackingbuilt against this branch:/posescf1at (0.141, 0.008, 0.061) m