|
The calibration file generated in the previous step enables the possibility to calculate point clouds from the two camera images using stereoscopy. To do this, the components StereoCameraProvider and StereoImagePointCloudProvider can be used. The RealArmar4Vision scenario already contains the StereoCameraProvider and can be executed on the head later. Therefore, only a scenario which starts the point cloud provider is required.
Create a new scenario in the Armar4 package and add the StereoImagePointCloudProvider component.
In the configuration of the new scenario, change the ImageProviderAdapterName to Armar4ImageProvider (since this is the name used in the RealArmar4Vision scenario). If you want to use the calibration file created before, open the configuration of the RealArmar4Vision scenario and enter the path to the calibration file created before under the CalibrationFile variable. Make sure that the camera UIDs are still set correctly (00b09d01009a72f1,00b09d01009a72ee).
Instead of the calibration scenario, now the RealArmar4Vision scenario needs to be started on the head computer to access the cameras. The newly created stereo vision scenario should be started from the second pc with the ScenarioManager. The widget PointCloudViewer can be added to the gui in order to view the resulting point clouds. Pressing ESC should enable the view of the PointCloudViewer to be rotatable using the mouse.
Running the two scenarios should now show images in the ImageMonitor widget and show point clouds in the PointCloudViewer widget. The StereoImagePointCloudProvider should calculate a point cloud estimation of the scene using stereoscopy. The quality of course depends on the quality of the calibration, the lighting, the visible correlation points and other potential disturbing factors. Additional components like the PointCloudSegmenter can now be added to the new scenario to process the point clouds.