Apparatus, including a magnetic tracking system, whichgenerates a magnetic field near a living subject's body, anda probe, having a distal end that can contact registrationpoints on a surface of the body. The probe has a contactsensor, located within the distal end, that outputs firstsignals indicative of a quality of the contact between thedistal end with the registration points. Located within thedistal end is a magnetic detector that outputs second signalsthat are indicative of respective positions of theregistration points in a coordinate frame of the magnetictracking system. A processor receives a tomographic image ofthe subject, and verifies, based on the quality of thecontact indicated by the first signals, that the registrationpoints are valid, and registers the tomographic image in thecoordinate frame of the magnetic tracking system using thepositions of the valid registration points.