- Home /
Blend RenderTextures of different size
So i am trying to implement foveated rendering. The thing is i am rendering 3 cameras with different fov's into 3 RenderTextures of different size. Now i want to blend those RenderTextures but i cant find a tutorial how to blend textures of different sizes. The position where the smaller RenderTextures shall be blended into the bigger one is depeending on the useres viewpoint. Does any one have a good solution for this?
You can create a material with each RenderTexture set as a separate texture, then use a custom shader to blend them as you wish using the Graphics.Blit function into a fourth RenderTexture. If you don't know already, I would suggest looking into writing image effects in Unity as it follows a very similar process.
http://www.alanzucconi.com/2015/07/08/screen-shaders-and-postprocessing-effects-in-unity3d/