Optical characterization of thin films with randomly rough boundaries using the photovoltage method