How to take a measurement with a camera