A RenderTexture can be used to render a scene to a texture automatically by assigning it to the Camera component's targetTexture property.
You can then assign the RenderTexture.texture to materials to be displayed
Example: ```ts
// create new RenderTexture with a resolution
const rt = new RenderTexture(256, 256);
// assign to a camera
myCameraComponent.targetTexture = rt;
// assign to a material
myMaterial.map = rt.texture;
```
A RenderTexture can be used to render a scene to a texture automatically by assigning it to the
Camera
component'stargetTexture
property. You can then assign theRenderTexture.texture
to materials to be displayedExample: ```ts // create new RenderTexture with a resolution const rt = new RenderTexture(256, 256); // assign to a camera myCameraComponent.targetTexture = rt; // assign to a material myMaterial.map = rt.texture; ```