The resonant acousto-optic effect