public void Release(CommandBuffer cmd) { if (id >= 0) { cmd.ReleaseTemporaryRT(id); IdentifierPool.Release(id); Dispose(); } }
public static RenderTarget GetTemporary( CommandBuffer cmd, int width, int height, int depthBuffer = 0, FilterMode filterMode = FilterMode.Bilinear, RenderTextureFormat textureFormat = RenderTextureFormat.Default) { var id = IdentifierPool.Get(); cmd.GetTemporaryRT(id, width, height, depthBuffer, filterMode, textureFormat); return(FromExist(id, width, height, depthBuffer, filterMode, textureFormat)); }