TSR is very very expensive. On my macbook pro M1 it takes up most of the frame time. you can change it at runtime using this
r.AntiAliasingMode 0 // Off
r.AntiAliasingMode 1 // FXAA
r.AntiAliasingMode 2 // TAA (Works very well, gives significant performance back)
r.AntiAliasingMode 3 // MSAA
r.AntiAliasingMode 4 // TSR (New method, but extremely expensive)
setRes 1920x1080 // Sets backbuffer resolution, this is the resolution that TSR will upscale TO
r.ScreenPercentage 50 // Sets internal render resolution. TSR will upscale FROM this resolution (720p) To (1080p)
r.SecondaryScreenPercentage.GameViewport 50 // Scales the backbuffer resolution so that 720p is the new upscale target, and internal render will be at 360p
Lets take an example. if you wanted your device’s Screen Resolution to be 1920x1080, then
setRes 1920x1080
but you actually wanted TSR or TAA to upscale the internal resolution using smart algorithms to 720p then
r.SecondaryScreenPercentage.GameViewport 50
and you wanted to only actually render 360p for performance reasons, then
r.ScreenPercentage 50
using that config, your game will actually only render 360p and the TSR or TAA upscaler will actually make it look like it’s rendering at 720p with a performance cost, then the device will simply stretch it at NO peformance cost to 1080p. Hope this helps
if you simply want so specify initial resolution and target resolution then
setRes 1920x1080 (Target 1080p)
r.ScreenPercentage 50 (Initial 720p)
This works on pc. but on consoles you may not be able to change the screen resolutioin, they may be locked at 4k, so you would actually do this
r.SecondaryScreenPercentage.GameViewport 50 (Target 1080p)
r.ScreenPercentage 50 (Initial 720p)