A photon detector for relativistic heavy ion collisions