A stochastic model of solid state thin film deposition: application to chalcopyrite growth