Systems and methods facilitate the planning and performance of hip and other surgeries. A computer model of a hip may be generated and displayed. A template of a hip component that replaces a native portion of the hip may be superimposed on the model. Changes in leg length, offset, or anterior-posterior (AP) position as well as a virtual distance between a landmark on the model and a location on the template may be determined. During surgery, a physical distance corresponding to the virtual distance may be obtained. The template may be moved relative to the model to match the physical distance, and new change values in leg length, offset, or anterior-posterior (AP) position may be determined. The new change values may be evaluated, and the surgery may proceed, or the process may be repeated using templates corresponding to alternative components.