title: RealityKit – How to add a Video Material to a ModelEntity?
body: <p>I use the code to add a picture texture in RealityKit and it works fine. </p>
  
  <pre><code>var material = SimpleMaterial()
  
  material.baseColor = try! .texture(.load(named: "image.jpg"))
  </code></pre>
  
  <p>I try to use this code to add a video file to be a texture, but it crashes!!!</p>
  
  <pre><code>guard let url = Bundle.main.url(forResource: "data", withExtension: "mp4") else {
      return
  }
  material.baseColor = try! .texture(.load(contentsOf: url))
  </code></pre>
  
  <p>How can I add a video file? </p>