Light-matter interaction in photonic crystal slabs