Antialiasing in separate hardware - the way forward?

Started by
6 comments, last by Gian-Reto 6 years, 5 months ago

So I watched a review of the

" rel="external">mCable some weeks ago... and was immidiatly extremly hooked. Not only was this the first "premium HDMI cable" which actually was not snake oil, but the gaming version aimed to solve a problem I was looking for a solution to for a long time - patching antialiasing into the jaggy visuals of contemporary (or old) consoles.

Because of that I swallowed the steep price of 140$ for a 2m cable, and actually bought one (both to see if the thing actually was as good as reviewers said, and to get more enjoyment out of my PS4 games)...

 

Now the cable has arrived and I am pretty impressed. Its a plug and play affair, and the AA it offers is more than just decent. It's on par with high quality MSAA, and uses a sharpening filter of sorts. Almost all the jaggies are removed, beyond the capabilities of some of the less powerful AA algorithms I have tested on PC, and the only real downside is the slightest hint of image softening, and a slight contrast boost by the sharpening filter that might not be to everyones taste.

 

I was only able to test Horizon Zero Dawn until now, but boy, was I impressed by the difference it makes. No longer is the start screen a flickering mess thanks to the foliage and particle effects, and specular aliasing. And the effect is just as effective in the game. You have to hunt for problematic geometry to find the faintest traces of aliasing.

As said, there are downsides. The images looks slighly softer. But really, that might be mostly down to how oversharp the visuals of HZD normally look, and I am sure is something I will get used to in no time. It is nowhere near as bad as with bad AA algorithms like FXAA, and on par with what I would expect of a quality AA algorithm like MSAA.

Then there is the contrast boost. I am not sure if its a sideeffect of the sharpening filter of the AA algorithm (which can have the effect to unnaturally boost contrast at times), or if its an actual "feature" (some Unity posteffects used such a contrast boost together with a sharpening filter to make the textures pop more and make the game look sharper)... again, its very subtle, and you will probably get used to it. It is slightly sad that the brilliant AA cannot come without that, as contrast in HZD certainly didn't need a boost.

 

Now, was that all worth 140$? Well, lets say if you are as sensible to jaggies as I am and have money to spare (and play on consoles), the cable can be worth it (1080p and below, of course)... especially when playing PS3 or other low resolution games.

But I would prefer this to me more versatile than just being a plug and play cable with a built in, pre configured chip. You cannot configure anything (which is very console like, but being able to tone down the contrast boost effect for example would make it better in HZD for me for example), you cannot bypass it without switching cables (would make the cable more expensive I guess), and of course, the HDMI cable will get stale and will need replacement once TVs come out which need a faster connection (not sure the cable handles 4k HDR signals at 60HZ for example).

So in reality its a gadget to boost your consoles visuals for a generation.

 

Probably the PS4 Pro, when outputting the upscaled checkerboard image for a 4k TV, uses a similar approach (a hardware unit that works on the 2k output image to upscale it).... so that got me thinking:

Why not build such a chip into the hardware pipeline of common GPUs to relief the actual GPU from running the AA algorithm, and make the AA agnostic to the renderer being used? Especially now that VR games can completly saturate even powerful GPUs WITHOUT AA, and are in DIRE need for quality AA, and even normal games might use renderers that have no existing hardware AA solutions implemented in the current GPU hardware, the solution sounds extremly convenient.

 

Basically take an existing GPU (lets say a GTX 1060), let it render the game without AA (which could safe 10+% of performance, thus higher setting could be chosen or more FPS could be put on the screen), and wire a similar chip as the one used in the mCable between the GPU and the outputs to run AA on the final image (and potentially other posteffects).

 

Of course there are downsides.... might make the Card more expensive (I doubt it will be anywhere near the 140$ I paid for the HDMI cable on steroids though), and might introduce additional lag (on the mCable the lag currently is <1ms according to the manufacturer and reviews, and I haven't felt any additional lag myself, so don't know how much of a problem this would be).

But making a card 10-20% faster in case of running AA on the game because the GPU does no longer need to run this in its multipurpose cores, and instead a much faster and smaller asic could do the job sounds like a big plus to me. Having quality AA built into the hardware, and no longer depending on the engine or game used, or having to use expensive SSAA tricks with mods or through the driver also sounds pretty good to me.

 

 

So what do you think? Is this the future of Antialiasing? Will we see GPU manufacturers build additional units into the actual GPU to relief the graphics cores from AA chores? Might the Card manufacturers like Zotac or Gigabyte add additional AA ASIC chips to their cards for their custom designs, and sell them at a higher price as a premium product?

Or is there a problem with the idea I haven't thought about?

 

Clearly the first problem for an approach that integrates the function unit into the GPU itself is the fact that current GPUs are designed with HPC workloads in mind first, graphics second. Hence the double precision baggage even gamer graphics cards are still burdened with today.

But it seems times are changing, with Nvidia apparently differentiating their pro-grade/HPC cards and their gaming cards even further with Volta... apparently the gaming class products will use a new architecture called "Ampere" (which might be Volta minus the double precision and Tensor cores, and with a GDDR controller instead of the HBM one). Maybe some of the space safed by ripping out the tensor cores could be given to Posteffect Function units (which I would guess would run more advanced algorithms faster on a smaller space than more general cores)?

Advertisement

This sounds really bad.

GPUs have been moving away from specialized hardware and towards general purpose hardware forever. You'd be better off running whatever this algorithm is on the GPU than on another chip... And if your GPU is too weak, put that extra $140 into getting a better one than a fancy chip. The only valid use case seems to be optionally adding extra image processing to old fixed hardware (consoles). 

If you're talking about building the hardware into a GPU, then again you're probably better off dedicating that space to more compute cores, and adding any extra fixed-function behavior that it requires into the existing fixed-function texture sampling/filtering hardware. That way games can decide to use a different AA method and not have some fixed-function AA chip sitting idle -- the extra compute cores are running the game's own AA solution. Or if it does have some fancy fixed function filtering, then by integrating this into the existing texture filters, then you allow developers to use that hardware on other algorithms too (not just post processing).

As for upscaling though, yeah GPUs sometimes to have a hardware upscaler built into the video output hardware. Microsoft is a fan of making sure the hardware upscaler is as good as possible... so there may be some room to add some smarts into that... but on PC, it's not common to render at 480p any more and have the GPU upscale to 1080p output...

Secondly, there's two kinds of anti-aliasing techniques - ones that avoid aliasing in the first place (toksvig, increased sampling + filters) and ones that try to hide aliasing after it's occurred (FXAA, etc). 

The latter aren't a solution, they're a kludge, and they're not the future. The biggest problem with filters like FXAA is that they're not temporally stable. Jaggies get smoothed out, but "smooth jaggies" still crawl along edges. 

The current state of the art in geometric AA involves extra samples (MSAA + temporal) and smart filters. This kind of of external add on can never have access to that extra information, so is doomed to FXAA style kludge filtering. The current state of the art in specular aliasing attacks the problem at the complete other end of the pipeline - filtering before lighting calculations. An add on can never do that. 

[edit] Watched the video, and yeah, it's smoothing jaggies but in no way solving aliasing. This kind of flickering is everywhere:

PzLTAdq.gif

11 hours ago, Hodgman said:

This sounds really bad.

GPUs have been moving away from specialized hardware and towards general purpose hardware forever. You'd be better off running whatever this algorithm is on the GPU than on another chip... And if your GPU is too weak, put that extra $140 into getting a better one than a fancy chip. The only valid use case seems to be optionally adding extra image processing to old fixed hardware (consoles). 

If you're talking about building the hardware into a GPU, then again you're probably better off dedicating that space to more compute cores, and adding any extra fixed-function behavior that it requires into the existing fixed-function texture sampling/filtering hardware. That way games can decide to use a different AA method and not have some fixed-function AA chip sitting idle -- the extra compute cores are running the game's own AA solution. Or if it does have some fancy fixed function filtering, then by integrating this into the existing texture filters, then you allow developers to use that hardware on other algorithms too (not just post processing).

As for upscaling though, yeah GPUs sometimes to have a hardware upscaler built into the video output hardware. Microsoft is a fan of making sure the hardware upscaler is as good as possible... so there may be some room to add some smarts into that... but on PC, it's not common to render at 480p any more and have the GPU upscale to 1080p output...

Secondly, there's two kinds of anti-aliasing techniques - ones that avoid aliasing in the first place (toksvig, increased sampling + filters) and ones that try to hide aliasing after it's occurred (FXAA, etc). 

The latter aren't a solution, they're a kludge, and they're not the future. The biggest problem with filters like FXAA is that they're not temporally stable. Jaggies get smoothed out, but "smooth jaggies" still crawl along edges. 

The current state of the art in geometric AA involves extra samples (MSAA + temporal) and smart filters. This kind of of external add on can never have access to that extra information, so is doomed to FXAA style kludge filtering. The current state of the art in specular aliasing attacks the problem at the complete other end of the pipeline - filtering before lighting calculations. An add on can never do that. 

[edit] Watched the video, and yeah, it's smoothing jaggies but in no way solving aliasing. This kind of flickering is everywhere:

PzLTAdq.gif

 

Well, I guess it depends on the game. In HZD, the anti aliasing works way better than in that example. No idea, maybe I should try to capture example footage... if I only had the hardware for it.

But I see where you are coming from. Its certainly the most fancy posteffect AA I have seen to date, its still a posteffect AA. Some blurring is inevitable (though that is also true of most MSAA algorithms I have seen, which where the norm in pre deferred rendering games), and the whole image is inevitably altered somewhat (hence slight artefacts like the contrast boost, though after reading the Box, the manufacturer does praise this as a feature)... so clearly such a solution always has downsides.

 

It was my impression that having a hardwired hardware solution to this would be smaller and more efficient then running the same algorithm in more generalized GPU cores. Thus saving die space if added to the GPU die as additional function units over the cores needed to run the same algorithm on top of everything else, or a small add on to a card as an additional die sipping almost no power.

And again, with all the other solutions having their own limitations (temporal for example. While I am impressed how much improved the Unreal TAA seems to when I first tried it 2 years ago now that I picked up UE4 again, it still shows hints of motion blur), and AA being even more important now than years ago, it seems like a viable plug'n'play solution.

 

Again, not being able to configure the effect is a major downside. Its something that irks me with that cable on the consoles as a not-really-consolero being too much used to the configurability of PC to not care, and I guess it would irk me (and everyone else) even more on PC.

Still, if the effect works well enough, maybe people no longer see the need to tweak the AA? Again, in HZD the AA seemed almost perfect. Guess I will fire up some of my other PS4 games and see how the AA fares there. Looking at your example (Yeah, I didn't remember the examples from the video that much anymore) shows a lot potential for improvement, which of course would mean an algorithm not yet ready to be baked into hardware this way.

 

I think in conclusion, it is safe to say that this hardware has to work exceptionally well (fast, very good AA effect without any side effects) to even be considered. So probably a lod of R'n'D has to got into developing such a chip, which only does what more general GPU cores could do, just more efficient, and more standardized. Which, depending on the cost in time and money for that R'n'D, might turn this into a bad idea for a GPU manufacturer.

Especially when a more advanced solution, as you write, cannot be added just as a posteffect unit, but needs to be used by the GPU cores during rendering like multi sampling.

 

... what if the manufacturer of the mCable would offer its chip at a good price to the likes of Zotac or Gigabyte? What if they built the chip unto their boards, along with double wiring, so you could turn the hardware AA on or off (both for people not liking the effect or scared of the lag it might introduce)? That might turn yet another boring custom GPU card that just adds 5 MHz to the cards boost and adds fancy RGB lighting into a slightly more interesting offering.

At least one where I could see where the extra 50-100$ went into besides more bling. And people could just ignore the souped up version with the mCable chip and go with the more standart GPU card instead if they didn't like the effect or the idea.

One can already enable game-agnostic FXAA filter from both Nvidia and AMD graphics driver configuration pages, for budget cards and top tier alike. This is a hack, as (in my opinion) is the cable you mention.

I strongly agree with Hodgman - the post-processing smoothing does fix a quality issue, but introduces more than one quality issue in doing that.

Adding to that, most gamers - especially pro - would conceivably prefer sharper image as opposed to artificial smoothing, in order to see as much detail as possible.

Niko Suni

Well, as someone who saw the result of the mCable AA with my own eyes, at least in the games I tested (not many yet though), the effect is far superior to FXAA.

Sure, an improved game agnostic Filter AA in the driver might do the trick (which is kind of what the driver SSAA derivates are, really), but then you are still putting the burden on running that on the general GPU cores. Which, in case of a posteffect AA algorithm like FXAA (bad as that one is), seems like a waste. Probably an additional function unit run AFTER the final image has been assembled (instead of running in on the general GPU cores again on the final image) would be way more efficient IF you can life with a posteffect AA solution.

 

Well, sure, the FPS twitch gamers would probably dislike such a solution (who are mostly the sole reason why things like 240Hz monitors and soundcards bastardizing the mix to elevate sound cues of enemies approaching exist in the first place), but really, for most other games a sharper image is a bad trade off when it comes with severe aliasing and flickering artefacts (until we get into bad blurring caused by FXAA and similar cheap AA solutions).

Which is why ideally, the chip or function unit should be bypassable to turn the effect off, and if its an additional chip, there should be cards without it (if its on the GPU, and not really using up that much die space, well. A lot of die space on modern GPUs is already wasted on function units games cannot use, soooo...)

 

Calling it a hack is kinda right. But then there are many, many AA algorithms used today that are not really THAT much more than a hack, even implemented in AAA games.

I guess hodgeman is right in that it might NOT be the most premium solution to put on high end GPUs, but it might be an extremly pragmatic solution for consoles given these never seem to have the GPU cores to spare on AA, so as long as the chip could be produced cheaply, might be a good addition to the HDMI output of a console (especially when coming as standart, game devs could tweak the visuals of their games to work well with the hardware AA).

 

Giiven the chip works well enough, I might spend 50$ more for the option as long I can deactivate it for the games where the AA effect doesn't work as well... but then, I wouldn't say that if with todays GPU prices, I could still get an upgrade to a more powerful GPU with +50$ in the high end space. More GPU cores might trump having an AA chip on the board given both cost the same.

I certainly would pay 25-50$ more for a console to come with such a chip as standart, given it works well in most games. As said, I am highly sensible to jaggies. I recognize this is personal taste and other people are more sensible to a slightly softer overall image.

 

140$ is insanity, unless you really hate aliasing on consoles, we can all agree to that. If there was any other solution to getting AA working on the PS4, I might have given the mCable a pass. I think I will now also have fun experimenting with it on retro consoles, but I don't think the result really justifies the price for the retro consoles alone.

2 hours ago, Gian-Reto said:

It was my impression that having a hardwired hardware solution to this would be smaller and more efficient then running the same algorithm in more generalized GPU cores.

It would be (hopefully).. But let's say that it takes 1ms to run this algorithm -- with a 60Hz game, this hardware will be idle for 94% of the frame. If you used that space / transistors to build a compute core then it can be doing useful work for the entire frame. You also let devs who want to use a different AA solution write their own instead of getting some hard-coded NVidia magic.

Another issue that was mentioned in the video that you linked is that this solution makes your windows desktop look like crap, because it's trying to "fix" all the text on the screen that's already been perfectly AA'ed with ClearType(tm). Games are similar where typically you run SMAA/FXAA/etc first, and then render your UI afterwards. So you can't just bolt this onto the video output hardware of a GPU -- it has to be developer controlled and utilized at the correct point during a frame... and if it's developer controlled, it needs to be something that D3D/GL expose... so it may as well just be a normal Dispatch call running on the compute cores ;)

The algorithm in the MCable probably isn't any special either. It's likely based on SMAA/etc, plus a sobel contrast filter, plus a LUT based contrast "enhancement". Lots of high end TV's often also have similar effects built right into them these days (MPEG deblocking, anti-aliasing, motion vector calculation, framerate doubling, dynamic contrast boosts, etc...). These makes football broadcasts look amazing, but typically you should actually turn them all off when playing games!

4 hours ago, Hodgman said:

It would be (hopefully).. But let's say that it takes 1ms to run this algorithm -- with a 60Hz game, this hardware will be idle for 94% of the frame. If you used that space / transistors to build a compute core then it can be doing useful work for the entire frame. You also let devs who want to use a different AA solution write their own instead of getting some hard-coded NVidia magic.

Another issue that was mentioned in the video that you linked is that this solution makes your windows desktop look like crap, because it's trying to "fix" all the text on the screen that's already been perfectly AA'ed with ClearType(tm). Games are similar where typically you run SMAA/FXAA/etc first, and then render your UI afterwards. So you can't just bolt this onto the video output hardware of a GPU -- it has to be developer controlled and utilized at the correct point during a frame... and if it's developer controlled, it needs to be something that D3D/GL expose... so it may as well just be a normal Dispatch call running on the compute cores ;)

The algorithm in the MCable probably isn't any special either. It's likely based on SMAA/etc, plus a sobel contrast filter, plus a LUT based contrast "enhancement". Lots of high end TV's often also have similar effects built right into them these days (MPEG deblocking, anti-aliasing, motion vector calculation, framerate doubling, dynamic contrast boosts, etc...). These makes football broadcasts look amazing, but typically you should actually turn them all off when playing games!

I never said the effect was that special... just that I haven't seen it used in such a way until now... and tha I seldomly have seen a posteffect AA algorithm which worked so well without heavy sideeffects (probably might be just very careful tweaking of an existing algorithm by the manufacturer). Which, at least to me, seemed to bring a lot of merit to the idea of integrating such circuitry into more than just a cable.

 

But you mention the part in the video were the crap look of the desktop was mentioned... yeah, I forgot about that. Probably for a PC GPU, the card would have to only enable it in case of 3D content being run on the card. Which of course would make the whole implementation more complex.

Also, good point about the UI. While that isn't a problem in all games (doesn't seem to be a problem with HZD and the mCable AA as far as I could tell, UI elements were still quite sharp, only slightly softer (with antialiasing applied as well)... but then the HZD UI is overly sharp normally, so might be a case where the UI and the 3D elements look match in sharpness works in favour of running an AA posteffect over the whole image), it could prove to be way more situational than I thought at first.

 

Good point about the hardware being not that well utilized... but wouldn't that mean that hardware also uses way less power than better utilized function units? So as long as the constrains are more the overall power the die can consume, and not really die space, the trade off in space for more efficiency might still be a viable one (leaving all the other potential issues with the solution aside) compared to using the space for more compute cores?

As far as I am aware a part of the GPU of the PS4 has specialized compute cores (which I believe are not usable for normal graphics work during the normal rendering pipeline)... would it be rather a way towards running AA and other similar effects more efficiently to add a separate set of GPU cores, smaller and more specialized towards certain workloads (like AA or other similar calculations), while still being general enough to run different algorithms and maybe being used for different kind of filters and effects, than actual fixed function hardware?

I guess smaller, more specialized cores could also run certain filters and effect more efficiently, while relieving the bigger, more generalized cores from some of their duties.

 

As to the filtering the TVs offer... yeah. Those are seldomly that usefule without a ton of tinkering in menus for every new type of content you watch.

But: it has been the holy grail of the "smart" TVs to add Database and content recognition software to their TVs so that the TV could offer decent "Plug'n'Play" configuration that would enhance each content type depending on the input it received. Now, I have never really seen such systems work all that good (the best I have seen is TVs recognizing the input source, optimizing the image for 2D Bluerays, 3D Bluerays, HD or SD TV channels, and offering a game mode for console inputs... which is kinda crude compared to what some TV manufacturers stated as their mission goal)...

But lets pretend for a moment such a system could at some point work. That the image being shown can be analyzed in real time and the software recognizes if sports or a talkshow is being shown (sci-fi as that might sound). That finally, TV Channels would send Meta data to offer a crutch for the system not working all that well (which is more probable)...

IF the system would work close to 99.9% of the time, and the Plug n Play configuration would do a good job of enhancing the expierience with filters and whatnot, wouldn't that finally be a good thing (unless you are a purist, and want no alteration of the input image, thus turn the system off)?

 

Could a similar system be devised for filtering PC and game visuals? Thus the hardware would disable the filtering on 2D content (with the caveat that this would make filtering a windowed game harder). Filtering should be able to mask out areas of the screen (which could solve the issue with windowed games, and UI elements not being filtered at the same time). The game developers probably would need to have some control on how the filtering works for their game (and the player should be able to at least turn the effect off), so some standardized API would be needed.

Hm, I guess this all points towards a system which would go beyond a simple ASIC chip. Or am I underestimating how much flexibility we could get from a fixed function without the whole thing getting so complex it would no longer be more effiecient than more general GPU cores?

 

EDIT:

So I decided to give the cable another testrun with other games... currently I only have 3 PS4 games to test, as I correctly predicted that I wouldn't find the time to play more this year.

When playing the first level of Nier:Automata over the mCable, I noticed that the AA was less effective here. Mostly because the first level is filled with hard to antialias geometry like fences, and the hair on the character also seemed very aliased still. Seems like the algorithm has trouble with aliasing caused by small subpixel geometry or heightmap lighting (I started up HZD again to confirm and sure enough, this is less evident there (because there is less such geometry in the game as far as I can tell, and more aggressive LODing going on probably), but the few instances where aliasing is still visible are also small subpixel aliasing artefacts... Aloys Bowstring for example).

Worse yet, as a game that already has quite punchy and contrast rich visual, the contrast boost really did bother me there. The games visual go from punchy to being overblown in contrast.

The game was still looking quite sharp, though I haven't played it for some time, that might be why I noticed HZD visuals getting somwhat softer on the cable while not noticing such an effect in Nier.

 

In short, I probably had to check the game on a normal HDMI cable again to see if the aliasing is so bad normally that I could live with the tradeoff of the overblown contrast.

 

In Tales of Berseria however the result was more of a net positive. This games visuals are inspired by anime visuals, and the standart contrast is not turned up so much that the contrast boost really bothers me. On the opposite, it makes the game actually look more punchy in its bright colors.

AA works well, and with less complex geometry in the level, there is less instances where the AA doesn't work. Visuals also looked pretty sharp, so really, in this instance the mCable postprocessing clearly is a net positive overall.

 

Long story short: The cable works better in some games than in others, as expected. Being able to switch the postprocessing stack on or off depending on the game would be a clear improvement.

Even better, if the different postprocessing filters being run could be switched on and off selectively would make the cable much a better offer. After all, the AA works great mostly, and is an improvement even on games where there is too much of the problematic geometry. If the contrast boost comes from a separate effect and is not caused by the AA sharpening filter, I would prefer that off in 2 of 3 games I have tested until now.

And again, as was stated before in this thread, the AA clearly is not a magic bullet. Different algorithms would work better for different games, though I suspect the only algorithms that could tackle the sever aliasing in Nier:Automata would be expensive downsampling algorithms. UE4's TAA is good, but with the game having quite quick camera turns in the thirdperson camera bits, I wonder if TAA would be a good choice. Maybe should check out what people say about the PC version, but I have the feeling its one of the aweful ports, so probably no good AA available there too.

 

Again, I think for a console the chip might be an idea. After all, if the game dev could adapt to the filters being applied, he could tune the games graphics to that, even if it would be fixed function hardware.

 

 

EDIT 2:

Question for you, Hodgman, as I know you have considerable knowledge of developing for Playstation...

Thinking about the idea for consoles, I kept coming back to the fact that we already have more powerful versions of the current consoles out that run enhanced versions of the games written for the original version, yet none of them seems to be using AA as an enhanced graphics option... at least I am not aware of any.

As a possible reason I would guess developers, when offered the choice, would first up the Framerate to a solid 60Hz (because that was pretty much the most ranted about problem with the visuals of current gen consoles by players), then add more flashy effects and better textures (because those simply are easier to see in marketing material compared to smoother overall visuals) before even considering AA.

Are there other reasons? I would expect SMAA or TAA to be not that expensive to game that runs fine on a GPU of less than half the power. But are there technical limitations preventing it? Or are devs simply going for other options, and in light of still limited GPU resources AA simply cannot fit into the budget?

Is Sony preventing that by mandating which options have to be picked for the improved 1080p graphics for consoles?

Or is it simply easier to move the framelock from 30Hz to 60Hz and call it a day?

 

Would there a possibility to output the game at 2K and use the Checkerboard filtering to DOWNSAMPLE to 1080p, or is that fixed to upsample into 4K? Would eat up all the additional GPU power, but real Downsampling AA on a console... that would be something :)

This topic is closed to new replies.

Advertisement