Trouble with visp_camera_calibration
I've been trying to perform hand-eye calibration on my Baxter robot using the vispcameracalibration package with this tutorial: http://wiki.ros.org/visp_camera_calibration/Tutorials/CalibrationExternalCamera
I am using an ASUS Xtion, which is not a firewire camera, so I have changed the launch file as follows:
<node pkg="visp_camera_calibration" name="visp_camera_calibration_calibrator" type="visp_camera_calibration_calibrator"/>
<!-- <node pkg="visp_camera_calibration" name="visp_camera_calibration_image_processing" type="visp_camera_calibration_image_processing" args="camera_prefix:=/camera/rgb/"> -->
<node pkg="visp_camera_calibration" name="visp_camera_calibration_image_processing" type="visp_camera_calibration_image_processing">
<param name="gray_level_precision" value="0.7" />
<param name="size_precision" value="0.5" />
<param name="pause_at_each_frame" value="False" />
<param name="calibration_path" type="string" value="$(arg calibration_path)" />
<!-- 3D coordinates of all points on the calibration pattern. In this example, points are planar -->
<rosparam param="model_points_x">[0.0, 0.03, 0.06, 0.09, 0.12, 0.15, 0.0, 0.03, 0.06, 0.09, 0.12, 0.15, 0.0, 0.03, 0.06, 0.09, 0.12, 0.15, 0.0, 0.03, 0.06, 0.09, 0.12, 0.15, 0.0, 0.03, 0.06, 0.09, 0.12, 0.15, 0.0, 0.03, 0.06, 0.09, 0.12, 0.15]</rosparam>
<rosparam param="model_points_y">[0.0, 0.00, 0.00, 0.00, 0.00, 0.00, .03, 0.03, 0.03, 0.03, 0.03, 0.03, .06, 0.06, 0.06, 0.06, 0.06, 0.06, .09, 0.09, 0.09, 0.09, 0.09, 0.09, 0.12,0.12, 0.12, 0.12, 0.12, 0.12, 0.15,0.15, 0.15, 0.15, 0.15, 0.15]</rosparam>
<rosparam param="model_points_z">[0.0, 0.00, 0.00, 0.00, 0.00, 0.00, 0.0, 0.00, 0.00, 0.00, 0.00, 0.00, 0.0, 0.00, 0.00, 0.00, 0.00, 0.00, 0.0, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.0, 0.00, 0.00, 0.00, 0.00,0.00]</rosparam>
<!-- 3D coordinates of 4 points the user has to select to initialise the calibration process -->
<rosparam param="selected_points_x">[0.03, 0.03, 0.09, 0.12]</rosparam>
<rosparam param="selected_points_y">[0.03, 0.12, 0.12, 0.03]</rosparam>
<rosparam param="selected_points_z">[0.00, 0.00, 0.00, 0.00]</rosparam>
</node>
I realised that openni publishes to camera/rgb/imageraw as opposed to just camera/imageraw so I ran it with $ roslaunch calib-live-firewire.launch camera/imageraw:=/camera/rgb/imageraw cameraprefix:=/camera/rgb $ roslaunch opennilaunch openni.launch (new terminal)
This opens the image viewer fine and I can see the Xtion feed, as well as opens the rqt view fine. The issue is that I can't get the image into the calibration window.
I have opened in an OpenCV window inside the C++ code, so it is subscribing to the right topic, but is going wrong somewhere. I used this tutorial http://docs.ros.org/jade/api/visp_ros/html/tutorial-ros-grabber.html which works fine, to compare code and edited the line (no 148) inside src/imageprocessing.cpp from: vpDisplay* disp = new vpDisplayX(); to vpDisplay* disp = new vpDisplayX(img);
It now appears with a mysterious blank white screen as well, which I'm not sure about. I tried to attach a screenshot of what I see as well as the output of rqt_graph, but I don't have enough points - so here they are: https://drive.google.com/open?id=0BxLcrTQmK9-hLUVSd1hNRjMyclE
Here's the code repo: https://github.com/lagadic/vision_visp/tree/master/visp_camera_calibration
I can't think of any more information on the subject.
Asked by fleishman on 2016-08-08 09:07:20 UTC
Comments