Energy dependency of dose response function of a Gd2O2S scintillator detection system for spot-scanning carbon-ion and proton radiotherapy