Can I generate mipmaps for a RenderTargetIdentifier?


I created a temporary render texture by CommandBuffer.GetTemporaryRT(rtId) and the rtId is a RenderTargetIdentifier. Then I tried to generate mipmaps from by CommandBuffer.GenerateMips but it needs a RenderTexture parameter which I don't know how to cast the rtId into it.

This is in Unity 2020.2:

I other versions I don't think there is a way (other than using a temp RenderTexture with autoGenerateMips).

Fine. I will found a walkaround.