by measuring lateral position of a boundary of the object