Total internal reflection gets harder at higher energies since the angle of incidence has to be smaller, meaning a the effective area of the mirrors gets smaller. Once you get up to gamma ray energies, mirrors are not really feasible, and straight line optics like coded masks are the way to go.
The coded mask technology is really cool. The mask pattern is chosen in such a way that the inverse transform generates a unique solution (along with a whole lot of background noise that gets distributed more evenly and so can be subtracted out). Not to downplay that subtraction - modelling the noise in a coded mask system is one of the hardest parts of analysing the data. Worked on data from a coded mask mission once - 2 years to model the noise and correct for it, 6 months to do the science on the results.