SceneKit Directional Light causing flickering
<p>I'm trying to add a directional light in Scenekit to cast shadows, but it is causing weird artefacts on objects.</p>

<p>The orange block below has a material with default settings and the diffuse set to orange.
The directional light is pointing downwards, and the scale is increased, otherwise it has default settings. (Making the scale smaller still has the same issue).</p>

<p>When I pan the camera around the texture is covered in flickering lines and dots, it looks terrible.</p>

<p><a href="https://i.stack.imgur.com/y6TUz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/y6TUz.png" alt="enter image description here"></a></p>

<p>This isn't visible on the simulator, only the device. What is going on and how can I fix it?</p>