Low-cost growth of III-V and II-VI semiconductor thin films