Advanced Computer Graphics James Gain Department of Computer













- Slides: 13
Advanced Computer Graphics: James Gain Department of Computer Science University of Cape Town jgain@cs. uct. ac. za Advanced Computer Graphics. Collaborative Visual Computing Laboratory
Objectives To show the problems caused by sampling in computer graphics (aliasing). To describe a variety of methods designed to combat these effects (antialiasing). Slides taken from ACM SIGGRAPH Educator’s Slide Set. 18/09/2020 Advanced Computer Graphics 2
Aliasing Occurs when the sampling inherent in rendering does not contain enough information for an accurate image. Original Scene Scanline Luminosity 18/09/2020 Sampling Pixel Centres Sampled Signal Advanced Computer Graphics Rendered Image Luminosity Signal 3
Effects of Aliasing • Common aliasing errors (called artefacts) are: jagged profiles, disappearing or improper fine detail, and disintegrating textures. Jagged Profiles Loss of Detail 18/09/2020 Advanced Computer Graphics 4
Disintegrating Texture • • • 18/09/2020 The checkers on a plane should become smaller with distance. But aliasing causes them to become larger and/or irregular. Increasing resolution only moves the artefact closer to the horizon. Advanced Computer Graphics 5
Antialiasing Developed to combat aliasing. Applies to all types of aliasing – PSC, RT and temporal. Prefiltering: • Treat a pixel as an area. Calculate overlap of polygon with pixel. Costly Postfiltering (supersampling): • • • 18/09/2020 Compute pixel colour by averaging multiple samples. Preferred Method. Sample the scene at n times the display resolution. For example, suppose the display resolution is 512 x 512. Sampling at three times the width and three times the height of the display resolution would yield 1536 x 1536 samples. A filter provides the weights used to compute the average. Advanced Computer Graphics 6
Prefiltering No Antialiasing 18/09/2020 Prefiltering Advanced Computer Graphics 7
Postfiltering Sampling: take jittered, regular or random samples. Jittered Regular Averaging: use an filter to assign weights to each sample. Sum all the weighted samples to obtain a pixel. 18/09/2020 Advanced Computer Graphics 8
Filtering Example 18/09/2020 Advanced Computer Graphics 9
Antialiasing Examples 18/09/2020 Advanced Computer Graphics 10
18/09/2020 Advanced Computer Graphics 11
18/09/2020 Advanced Computer Graphics 12
18/09/2020 Advanced Computer Graphics 13