Stereo Camera Calibration
CX Stereo ball tracking
Calibration
Note that the CX Surround's camera are pre-calibrated
so this calibration procedure is only required for the CX Stereo which is using individual mounted cameras
Mounting the cameras sideways means the direction of play is then in the vertical direction
i.e. from down to up in the camera images instead of from right to left.
You will thus have to move the "Ball Launch position" to the bottom center of the camera image.
The above shows the converging camera calibration table that is automatically loaded when "Converging cameras" option is selected
Each row in the table consists of 5 values that are automatically calculated when the system is in calibration mode and new images are grabbed.
Note that if both cameras are perfectly aimed at the same center line then disparity at the converging point at floor level will be zero.
This will probably prove to be difficult to achieve but at least the disparity number at floor level should be a low number.
The above table shows a disparity (Disp) of 24 at floor level.
.
A graph plot of disparity to golf ball height shows a non-linear exponential curve.
Calibration
Note: please use Control Panel version 8.8.0.5 or greater for this procedure.
In order the raise the calibration black card and white strip, either a tripod can be used
or you attach the card to 2 magnets that slide directly up the metal tape measure
Calibration procedure
Should re-calibration be required then the following calibration procedure should be made:
Calibration setup
In order to calibrate, we need to raise a 20cm long white strip mounted on a black card from the floor up to around 170cm in 10cm steps on the center line.
You can use any method you like to raise the strip off the ground in the 10cm steps.
Attaching the strip to a metric tape measure that is suspended from the center line of the enclosure and extended to the floor is one method.
The above image shows a white strip card directly attached to a tape measure that can simply be moved up or down to the desired height.
You could also use an extend-able camera tripod.
Note that the calibration table consists of 17 row entries at set 10cm distances from 0 cm to 170 cm.
i.e. 0, 10, 20 ... to 170 cm
17 Calibration steps
Calibration mode new features
To help assist the calibration process, a couple of new features:
1. Pressing the SPACE bar on the keyboard switches the calibration mode on and off so that the images captured can be inspected before entering the values
2. The active row is now bright white
3. A beep and message is shown after the "Ins" key has been pressed showing that the values have been entered into the calibration table
This version of the CP includes the calibration table for the 260cm or 8ft 6" mounting height of the Stereo IR panel cameras.
The above image shows the white strip connected to the tape measure with the slider.
Using the calibration slider on the tape measure, a complete calibration can be done in 10 to 15 minutes.
When testing, set both RAW Path and RAW Launch angle to ON
Note that the above image is from the parallel setup page where the strip orientation is from right to left.
The converging camera strip oprientation is vertical i.e from down to up.
You can view the complete calibration table by selecting the "Show calibration table" option.
Although the real distance (d) the ball travels (and thus the ball speed) within the camera exposure time is always measured using RAW LA and Path
(i.e. as measured from the both ends of the ball trace)
it will be more accurate to measure LA and path using fixed launch positions for chipping as by the time the ball is in the FOV of the cameras with slow shots
the ball may well be descending and thus launch angles will be less or even negative if measured from trace ends instead of a known launch position height.
Note that when using a fixed launch position (i.e. when both the RAW LA and RAW path options are switched off)
then the fixed "Ball launch position" has to be set in both the left and right cameras separately
as the left and right cameras will see the launch position in a different places.
Switch RAW Path and RAW LA on/off in camera 2 of the Control Panel
Pros and Cons of Stereoscopic vs H cam V cam setups
Stereoscopic vision explained
The above diagram explains the basic stereoscopic principles.
Note: the above diagram shows the stereo cameras for the VisTrak IRV Stereo where the direction of play is from right to left and not from bottom to top as with the regular VisTrak Stereo system.
If the two 2 stereo cameras are aimed precisely at the center line and a ball is placed at floor level, the images of the will appear on top of each other.
The disparity of the ball is then zero (or near zero) and this is known as the "Converging point"
When the ball is elevated, the images of the ball in the camera frames will start to separate. The distance the ball images are apart is the "Disparity".
Using a "disparity to ball height" table and with weighted calculations, the exact height of the ball can be determined.
Knowing where the ball was before ball strike (frame 1) and the trigger delay time on the stereo cameras, the ball LA, speed and path can be determined.
Ball path is simply derived from the divergence the center of the disparity distance is from the center line.
i.e. a perfectly straight shot would show that the 2 ball images are the exact same distance from the center line.
Converging camera test shots
The above screen shots are from customer Kevin showing the left and right camera images os a full shot using the new Converging stereo setup.
Editing the stereo calibration table
The values again are:
Why edit the table?
A reason would be to verify that the table entries are correct.
e.g. in the above image the disparity of a white card placed at a height of 100 cm is 517 for P1
(P1 is the upper end point of the ball trace. P2 is the lower end point of the ball trace.
These two points are shown by the two green cross hairs on either end of the ball trace)
In this example, the height for a disparity of 517 is calculated to be 107.78.
If, for example, the white card that represents the ball trace was placed at a height of 100 cm off the ground and not 107 cm,
then you would adjust the current disparity of 468 for a height of 100cm to 517.
The scaling factor - used to convert trace lengths measured in pixels to real distances in cm - can also be adjusted.
Using this method, you can verify and adjust values for the complete 19 row table.
Note that you have to place your white card at the desired height (0 to 190 cm) and hit the
Soft Trigger in both left and right cameras to grab new frames for every height you are checking.
Using stereo cameras with VisTrak
If using stereo cameras with the VisTrak, the only function the cameras will have will be to determine the launch angle of the ball
which is based on the height of the P1 point of the trace above ground at its user defined launch position.
i.e. the VisTrak camera measures ball speed and direction and not the stereo cameras.
In this respect, the scaling factor entries in the stereo calibration table are not being used.