Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question How to re-assign the RenderTexture

Discussion in 'Graphics for ECS' started by Aditrc, Jun 14, 2023.

  1. Aditrc

    Aditrc

    Joined:
    Dec 15, 2018
    Posts:
    13
  2. mingwai

    mingwai

    Small Graphics Potato Unity Technologies

    Joined:
    Jan 16, 2017
    Posts:
    52
    Hi, attached an example (ReassignRTtoSubscene.zip) on how to do that.
    The idea is to have a component outside the subscene that holds the original RenderTexture asset reference, and then using an ECS system script to re-assign this RenderTexture asset reference to the material that the entity (object in subscene) uses.
     

    Attached Files: