1 Star 0 Fork 0

wgu938 / webcam_retrieval

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

README

Description

This package functions as a ROS node, facilitating the publication of images from the PC webcam for camera calibration tutorials.

Environment

  • Python=3.8.10
  • ROS Noetic

Setup

  • Clone this repo into your workspace (say, ~/catkin_webcam_ws/src)
  • Build the package by running catkin build under ~/catkin_webcam_ws
  • Source the package by running source ~/catkin_webcam_ws/devel/setup.bash
  • Print check-108.pdf under the checkboard directory

Usage

Terminal #1:

roscore

Terminal #2:

roslaunch webcam_retrieval start_webcam.launch 

Terminal #3:

rviz

Note that you need to change "Image Topic" to /image_view/image_raw in Rviz to see the camera readings.

Terminal #4:

rosrun camera_calibration cameracalibrator.py --size 8x6 --square 0.108 image:=/image_view/image_raw

In order to get a good calibration you will need to move the checkerboard around in the camera frame such that:

  • checkerboard on the camera's left, right, top and bottom of field of view
    • X bar - left/right in field of view
    • Y bar - top/bottom in field of view
    • Size bar - toward/away and tilt from the camera
  • checkerboard filling the whole field of view
  • checkerboard tilted to the left, right, top and bottom (Skew)

At each step, hold the checkerboard still until the image is highlighted in the calibration window. As you move the checkerboard around you will see three bars on the calibration sidebar increase in length. When the "CALIBRATE" button lights, you have enough data for calibration and can click "CALIBRATE" to see the results.

Calibration can take about a minute. The windows might be greyed out but just wait, it is working. At the end of calibration process, you will see the results in the terminal as follows.

Click "SAVE" to save the results (in form of a zip file), including the intrinsic matrix and all the images captured for the camera calibration.

Known issues

  • Cannot read or open camera.

    Open the terminal and type ls /dev/video* to list available serial ports for webcams connected to your system.

    Use the command ffplay /dev/video0 with different available video IDs to identify the working webcam. Replace the number in cv2.VideoCapture(0) with the correct ID in the webcam_node.py file.

References

空文件

简介

暂无描述 展开 收起
CMake 等 2 种语言
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/weibin93/webcam_retrieval.git
git@gitee.com:weibin93/webcam_retrieval.git
weibin93
webcam_retrieval
webcam_retrieval
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891