using System; using UnityEngine; public class RenderTexSaveInObject : MonoBehaviour { private void Start() { } private void Update() { if (Input.GetKeyDown(KeyCode.T)) { this.m_bKeyPress = true; } } public void OnPreRender() { } private void SaveRt() { UTY.SaveImage(base.GetComponent().targetTexture, null, TextureFormat.ARGB32); } private bool m_bKeyPress; }