Skip to content
This repository was archived by the owner on Jan 13, 2025. It is now read-only.

Idea to apply offset to camera transform 3d so that it can be more accurate in doing turning#119

Open
maxspier wants to merge 2 commits into
mainfrom
thought-vision-idea
Open

Idea to apply offset to camera transform 3d so that it can be more accurate in doing turning#119
maxspier wants to merge 2 commits into
mainfrom
thought-vision-idea

Conversation

@maxspier
Copy link
Copy Markdown
Member

@maxspier maxspier commented Apr 5, 2024

No description provided.

@maxspier maxspier requested review from jamesi8086 and rcahoon April 5, 2024 22:51
return GrayScaleCamera.getBestTargetTransform3d(toUse.getTrackedTargetWithID(tagId));
Transform3d current =
GrayScaleCamera.getBestTargetTransform3d(toUse.getTrackedTargetWithID(tagId));
Transform3d offset = new Transform3d(0.0, -0.229, 0.0, new Rotation3d());
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this number is highly magical.

why this particular value? where did it come from?

does this work if the robot is turning in either direction?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This value comes from my "measurement" of the camera's position to the middle of the bumper. I say "measurement" as I used wills fingers to measure so we should get something more accurate. This should work in all test cases since it moves the camera to the middle. It should have no impact on other things (or so I think).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

back then I recall we also have to rotate along a certain axis so that we compensate for the camera tilt

you should test (maybe unit tests or some logs) to see if the resultant coordinates make sense

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants