As some of you might know, downsampling AA is the thing right now so I am wondering as to how can that be implemented in Unity?
For people who don’t know, downsampling AA is rendering game at 2x(or more) of monitor pixel size and then resizing image down, producing smooth looking result.
It is very performance hungry since it is essentially brute force AA but for games with low requirements this can do a lot of justice.
Presumably you need either render textures or 4 cameras with 4 sets of grabbing pixels into textures, then you draw the texture using your own downscaling shader I presume… or something like bilinear filter.
I did a small test with render textures. Base resolution is 1280x720
1x - original image, nothing done 2x - render texture at 2560x1440, very smooth looking 4x - render texture at 5120x2880, too big of a size causes jaggies to show up, not as much as at 1x but noticeably more than at 2x, could be because of downsampling filter? Same happened at 3x too.
I have not yet tested at any other resolutions though so I have no idea how that will look.
the 4x is doing that because you’re trying to bilinear sample a 4x4 block, which ignores 2 rows and 2 columns, and produces a jump from one row to another at an offset, which is why it looks worse. It should look better than 2x. But you can’t rely on bilinear to do it, unless maybe you render the 4x texture to a 2x texture (half size downsample) then use that texture and render it half size again. Otherwise you need a custom shader that will sample 16 pixels and average them.
I’m not a rendering nut but I recalled reading an interview with one of the developers of “Trine 2” ( its not Unity Engine ) and recall that super-sampling was used but they still ran a AA algorithm on the larger render before down sampling… So I would think this suggests super sampling on its own is not enough.
That’s an interesting idea, wonder what would the performance difference be though.
Does unity have internal maximum resolution? As far as I know modern GPUs have a high max texture resolution.
The problem with splitting screen is some post process effects do not play well. You could in theory apply them to final image but that is too much work right now. Not to mention in that case they won’t get to use the high resolution picture.
That looks very informative. I’ll look into it. Thanks/
doing a half-downsample from 4x to 2x, then another from 2x to 1x, will of course be slower than then 2x to 1x, because you’ve got to do an additional 400% texture lookups, plus an extra 2x-sized write. But it may look nice