Is it possible to set a CALayer as the contents of a RealityKit material?

Is it possible to set a CALayer as the contents of a RealityKit material? Currently this is possible with SceneKit materials. I am wondering if there is something similar for RealityKit.

https://developer.apple.com/documentation/scenekit/scnmaterialproperty/1395372-contents

Answered by Graphics and Games Engineer in 696351022

Not directly, no. The closest thing is to write the contents of your CALayer to a RealityKit TextureResource (MTLTexture) using the DrawableQueue API. Feel free to submit a feature request on Feedback Assistant.

Accepted Answer

Not directly, no. The closest thing is to write the contents of your CALayer to a RealityKit TextureResource (MTLTexture) using the DrawableQueue API. Feel free to submit a feature request on Feedback Assistant.

Is it possible to set a CALayer as the contents of a RealityKit material?
 
 
Q