Ground-based imaging air Cherenkov telescopes typically observe a solid angle of a few degrees in diameter. In many instances, the angular extent of γ-ray sources is comparable to the size of the field of view. For these objects, dedicated observations of source-free regions are required to estimate the background. The additional observation time and the non-simultaneous background estimate motivates alternative approaches to carry out imaging spectroscopy. In this contribution, we extend the so-called "template" background method that has been widely in use to generate sky maps to a general method to carry out imaging spectroscopy without the need of additional background observations. The method described in this contribution can be used for any imaging Cherenkov telescope data. Here, it is tested with published data taken with the H.E.S.S. array of Cherenkov telescopes and compared with the results of the standard analysis.