Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WPIcal documentation initial draft #2691

Draft
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

ElliotScher
Copy link

Adds initial draft of documentation for new WPIcal tool: wpilibsuite/allwpilib#6915

@mcm001
Copy link
Contributor

mcm001 commented Aug 11, 2024

Great stuff so far overall! Great to see this coming together.

@ElliotScher ElliotScher requested review from mcm001 and rzblue August 12, 2024 02:14
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved
source/docs/software/wpilib-tools/wpical/index.rst Outdated Show resolved Hide resolved

Camera Calibration
------------------
To measure the distance between tags in a video, you need the camera's intrinsics to account for things like distortion. WPIcal allows users to upload a video file to calibrate the camera in the tool, or upload a JSON file with your camera's intrinsics
Copy link
Contributor

@mcm001 mcm001 Dec 27, 2024

Choose a reason for hiding this comment

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

How should I capture a video file? I was able to do it on linux with gstreamer, but it was pretty non-trivial.

gst-launch-1.0 -vvv v4l2src device=/dev/video0 extra-controls="c,gain=25,exposure_auto=1" ! image/jpeg,format=MJPG,width=1600,height=1200,framerate=50/1 ! jpegdec ! videoconvert ! tee name=t t. ! queue ! autovideosink t. ! queue ! videoconvert ! avimux ! filesink location=output.avi

Copy link
Author

Choose a reason for hiding this comment

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

I've been using a phone camera and then transferring the file to a computer to calibrate. For linux It will need to be transcoded. Do you think we should document how to capture the video for linux machines too?

Copy link
Contributor

Choose a reason for hiding this comment

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

OBS also works well

  1. Add a V4L2 video capture device
  2. Change properties:
    image
  3. Under settings->video change the base resolution
    image
  4. Settings->output, not sure why i don't see avi on linux but it should be an option

Copy link
Author

Choose a reason for hiding this comment

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

Do you think documenting the proper video capture method is within scope of the project? On all other platforms we're assuming users capture video beforehand.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants