The first exhibition at the newly renamed King’s Gallery, Buckingham Palace takes the photographers as seriously as their high-born sitters.