How to render a video as a diffuse texture on a node in SceneKit when using a custom shader? It sounds like a simple thing, but:
- SceneKit elements do not support
AVPlayerLayeras input texture ( https://stackoverflow.com/a/1654775/ ... ) - Alternatives:
- using a SpriteKit scene with SKVideoNode, but:
- converts the video output to CGImage, transferring it to CALayer and transferring this layer to the video SceneKit node (SpriteKit is not involved). Details here , but not a viable solution, as soon as the video is a little large because all the output is copied to the image, and it is expensive.
SceneKit, opengl/metal, ...
, , SpriteKit Metal, SceneView , , , ...
: