Automatic deformation measurement from digital images