System and method for treating a patient (10). The system includes a drape (12) configured to be positioned over a joint (16) of the patient (10). The drape (12) includes one or more sensors (52, 56) that are configured to provide signals indicative of the orientation of the joint (16). A 3-D representation (60) of the joint (16) is registered to the joint (16), and the orientation of the representation (60) adjusted based on the signals provided by the sensors (52, 56). The method of treating the patient includes generating the 3-D representation (60) and positioning the drape (12) over the joint. The orientation of the 3-D representation (60) is adjusted based on the signals provided by the drape (12), and an image (17) generated from the 3-D representation (60). The image is displayed to provide a physician performing an injection with feedback regarding the position of a needle (76) relative to the patient (10).