Important Information

News

  • May 31, 2011
    Torque 3D 1.1 features Jimenez's MLAA!
  • April 20, 2011
    We setup a github project, to ease upgrading to new versions (check out the diffs in the downloads section!). For previous versions, only a commit per release, but we will hopefully have something better for future relases.
  • March 15, 2011
    Version 1.5 released. Don't miss it!
  • March 5, 2011
    Version 1.4 released, including a brand new DX9 port, check it out!
  • February 28, 2011
    We are happy to announce that we are releasing the original GPU Pro 2 MLAA source code.
  • October 27, 2010
  • October 4, 2010
    We now have a F.A.Q. Check it out!
  • September 6, 2010
    Web launched!

Abstract

Cover Cover

Multisample anti-aliasing (MSAA) remains the most extended solution to deal with aliasing, crucial when rendering high quality graphics. Even though it offers superior results in real time, it has a high memory footprint, posing a problem for the current generation of consoles, and it implies a non-negligible time consumption. Further, there are many platforms where MSAA and MRT (multiple render targets, required for fundamental techniques such as deferred shading) cannot coexist. The majority of alternatives to MSAA which have been developed, usually implemented in shader units, cannot compete in quality with MSAA, which remains the gold standard solution. This work introduces an alternative anti-aliasing method offering results whose quality lies between 4x and 8x MSAA at a fraction of its memory and time consumption (see below). Besides, the technique works as a post-process, and can therefore be easily integrated in the rendering pipeline of any game architecture.

The technique is an evolution of the work "Morphological Antialiasing", which is designed for the CPU and unable to run in real time. The method presented here departs from the same underlying idea, but was developed to run in a GPU, resulting in a completely different, extremely optimized, implementation. We shift the paradigm to use texture structures instead of lists, which in turn allows to handle all pattern types in a symmetric way, thus avoiding the need to decompose them into simpler ones, as done in previous approaches. In addition, pre-computation of certain values into textures allows for an even faster implementation.

The algorithm detects borders (either using color or depth information) and then finds specific patterns in these. Anti-aliasing is achieved by blending pixels in the borders intelligently, according to the type of pattern they belong to and their position within the pattern. Pre-computed textures and extensive use of hardware bilinear interpolation to smartly fetch multiple values in a single query are some of the key factors for keeping processing times at a minimum.

Typical execution times are 3.79 ms on Xbox 360 and 0.44 ms on a nVIDIA GeForce 9800 GTX+, for a resolution of 720p. Memory footprint is 2x the size of the backbuffer on Xbox 360 and 1.5x on the 9800 GTX+. Meanwhile, 8x MSAA takes an average of 5 ms per image on the same GPU at the same resolution, 1180% longer (i.e. processing times differ by an order of magnitude). The method presented can therefore challenge the current gold standard in real time anti-aliasing.

More details found in the GPU Pro 2 chapter and in Destroy All Jaggies in the June/July 2011 Game Developer Magazine issue.

Xbox360 GeForce9800GTX+
Avg. Std. Dev. Avg. Std. Dev. Speed-up
Assasin's Creed 4.37ms0.61ms0.55ms0.13ms6.31x*
Bioshock 3.44ms0.09ms0.37ms0.00msn/a
Crysis 3.92ms0.10ms0.44ms0.02ms14.80x
Dead Space 3.65ms0.45ms0.39ms0.03msn/a
Devil May Cry 4 3.46ms0.34ms0.39ms0.04ms5.75x
GTA IV 4.11ms0.23ms0.47ms0.04msn/a
Modern Warfare 24.38ms0.80ms0.57ms0.17ms2.48x*
NFS Shift 3.54ms0.35ms0.42ms0.04ms14.84x
Split/Second 3.85ms0.27ms0.46ms0.05msn/a
S.T.A.L.K.E.R. 3.18ms0.05ms0.36ms0.01msn/a
Grand Average 3.79ms0.33ms0.44ms0.05ms11.80x

Average times and standard deviations for a set of well-known commercial games. A column showing the speed-up factor of our algorithm with respect to 8x MSAA is also included for the PC/DirectX 10 implementation. Values marked with * indicate 4x MSAA, since 8x was not available, and the grand average of these includes only values for 8x MSAA.


Fable image #1 with MLAA Fable image #2 with MLAA Unigine image #1 with MLAA Figures showing our technique in action. Check out our image gallery for comparisons between 1x MSAA, 8x MSAA and MLAA. First and second images, from Fable III, courtesy of Lionhead Studios - Microsoft Game Studios. Third image, from Unigine Heaven Benchmark, courtesy of Unigine Corporation.

Movie

IMPORTANT: designed to viewed in HD at full screen.

Downloads

1 If the additional images are put in the same folder as the demo executable, they will be automatically loaded by the application (more info in the README). For running the demo, an installation of the June 2010 DirectX SDK is required.

F.A.Q.

How were the times measured for the Xbox 360 version?

We captured frames from the games listed in the table, and processed them running a XNA version of our technique on a real Xbox 360. Using a proper dev-kit would probably lead to better times.

How does the quality of your implementation compare with MSAA?

In the article we are conservative, and we say that quality is between 4x and 8x. However, it is something difficult to compare: when the technique works it is as good as 16x, when it breaks it is as bad as 1x. As the performance of our approach is one order of magnitude faster than MSAA, there is still room for quality enhancements, in expense of worser running times.

In which platforms does it run?

We have implementations in DirectX 10, for PC, and XNA, for Xbox 360. It could run in DirectX 9 without problems, as we are not using DirectX 10 special features. It is coded as a regular pixel shader, that runs as a post-process over a color image (with optionally depth as input).

What are the advantages of MLAA over MSAA?

Bibtex

@inbook{JIMENEZ2011_GPUPRO2A,
    author = {Jorge Jimenez and Belen Masia and Jose I. Echevarria and Fernando Navarro and Diego Gutierrez},
    editor = {Wolfgang Engel},
    title = {{GPU} Pro 2},
    chapter = {Practical Morphological Anti-Aliasing},
    publisher = {{AK} Peters Ltd.},
    year = {2011},
}
@inproceedings{JIMENEZ2011_SIGGRAPH11,
    author = {Jorge Jimenez and Diego Gutierrez and Jason Yang and Alexander Reshetov and
              Pete Demoreuille and Tobias Berghoff and Cedric Perthuis and Henry Yu and
              Morgan McGuire and Timothy Lottes and Hugh Malan and Emil Persson and
              Dmitry Andreev and Tiago Sousa},
    title = {Filtering Approaches for Real-Time Anti-Aliasing},
    booktitle = {ACM SIGGRAPH Courses},
    year = {2011},
}
@article{JIMENEZ2012_CGF,
    author = {Jorge Jimenez and Jose I. Echevarria and Tiago Sousa and Diego Gutierrez},
    title = {SMAA: Enhanced Morphological Antialiasing},
    journal = {Computer Graphics Forum (Proc. EUROGRAPHICS 2012)},
    year = {2012},
    volume = {31},
    number = {2},
}

Related

Links