These materials are both transparent in the visible regime of light. However, because they have a higher index of refraction, the light passing through small particles is refracted and reflected off of many surfaces. The resultant scattered light makes them appear white. If the particles are smaller than the wavelength of light, they no longer interfere with its transmission and they are transparent again. They do have absorption bands in the UV regime, and still act as effective sun blocks.