A medical imaging system and a method electromagnetically track a position of structures with the medical imaging system and a C-arm arrangement. The medical imaging system contains a C-arm, a gantry, and at least one electromagnetic field generator assembly with at least one electromagnetic field generator which interacts with an electromagnetic sensor from receiving the electromagnetic radiation. Preferably, the electromagnetic sensor is positioned within a region of surgical interest in a patient. The electromagnetic field generator is directly embedded into the C-arm.