Precise determinations of high-energy gamma rays and errors in the pair-peak method