Gamma photometric redshifts for long gamma-ray bursts