Zinc oxide is white in colour but on heating, Oxygen leaves as O2 leaving behind Zn2+ and 2 electrons. Zn2+ and the 2 electrons move to the interstitial sites of the crystal . This provides excess electrons in the crystal lattice of ZnO. When light falls on these crystals then these electrons absorb a part of the light in the visible region and hence impart a yellow colour to the ZnO.
ZnO ---heating---> Zn2+ + 1/2O2 + 2e