A quantum dynamical study of the photoelectron spectra and the Renner-Teller effect in BrCN and ClCN based on four-component potential energy hypersurfaces