MATLAB: Camera calibration for measuring objects

camera calibration measuring planar objectsComputer Vision Toolbox

Hi. in the help of matlab for Measuring Planar Objects with a Calibrated Camera, a checkboared is used . this checkboard is beside the penny for measuring the diameter of it. i want to know that is there any way to measure diameter of penny without the checkboard , I mean that first use the checkboard for calibrating and then use penny in the another picture and measure it's diameter separately.

Best Answer

To measure a planar object with a single camera you need to know the extrinsics, which is the transformation between the plane of the object and the camera's coordinate system. You can take a picture of the checkerboard on the table separately and compute the extrinsics. You can then take a picture of the penny on the same table and measure it, but the camera must not move between these two pictures.
Alternatively, you can calibrate a stereo pair of cameras using the Stereo Camera Calibrator app, and then you would not need the checkerboard at all. You would also be able to measure non-planar objects.