CS 551 / CS 645 Antialiasing. What is a pixel? A pixel is not… –A box –A disk –A teeny tiny little light A pixel is a point –It has no dimension –It occupies.

Slides:



Advertisements
Similar presentations
Sampling, Aliasing.
Advertisements

Sampling and Reconstruction
Technische Universität München Fakultät für Informatik Computer Graphics SS 2014 Sampling Rüdiger Westermann Lehrstuhl für Computer Graphik und Visualisierung.
CS 445 / 645 Introduction to Computer Graphics Lecture 18 Antialiasing Antialiasing.
Computer Graphics Viewing, Rendering, Antialiasing گرد آوري و تاليف: دكتر احمد رضا نقش نيل چي دانشگاه اصفهان گروه مهندسي كامپيوتر.
David Luebke1/19/99 CS 551/651: Antialiasing David Luebke
MIT EECS 6.837, Durand and Cutler Sampling, Aliasing, & Mipmaps.
Photo-realistic Rendering and Global Illumination in Computer Graphics Spring 2012 Realism in Computer Graphics K. H. Ko School of Mechatronics Gwangju.
Aliasing & Antialiasing
School of Computing Science Simon Fraser University
Sampling, Aliasing, & Mipmaps
CS248 Midterm Review. CS248 Midterm Mon, November 4, 7-9 pm, Terman Aud Mostly “short answer” questions – Keep your answers short and sweet! Covers lectures.
CSCE 641 Computer Graphics: Image Sampling and Reconstruction Jinxiang Chai.
Sampling (Section 4.3) CS474/674 – Prof. Bebis. Sampling How many samples should we obtain to minimize information loss during sampling? Hint: take enough.
General Functions A non-periodic function can be represented as a sum of sin’s and cos’s of (possibly) all frequencies: F(  ) is the spectrum of the function.
CSCE 641 Computer Graphics: Image Sampling and Reconstruction Jinxiang Chai.
lecture 5, Sampling and the Nyquist Condition Sampling Outline  FT of comb function  Sampling Nyquist Condition  sinc interpolation Truncation.
Scan Conversion Week 6, Wed 8 Oct 2003
CS5520 Image-Based Rendering © Chun-Fa Chang, Spring 2003 Sampling Theorem & Antialiasing April 15, 2003.
University of British Columbia CPSC 414 Computer Graphics © Tamara Munzner 1 Sampling Week 7, Fri 17 Oct 2003 p1 demos sampling.
University of British Columbia CPSC 414 Computer Graphics © Tamara Munzner 1 Scan Conversion Week 6, Fri 10 Oct 2003 sampling.
Aliasing and Anti-Aliasing Copyright Zachary Wartell, University of North Carolina at Charlotte, All Rights Reserved Revision: 10/24/2007 3:38:00 AM ©Zachary.
CIS 681 Distributed Ray Tracing. CIS 681 Anti-Aliasing Graphics as signal processing –Scene description: continuous signal –Sample –digital representation.
CSC418 Computer Graphics n Aliasing n Texture mapping.
Sampling and Antialiasing CMSC 491/635. Abstract Vector Spaces Addition –C = A + B = B + A –(A + B) + C = A + (B + C) –given A, B, A + X = B for only.
Computer Graphics Mirror and Shadows
Sampling theorem In order to accurately reconstruct a signal from a periodically sampled version of it, the sampling frequency must be at least twice the.
CS 431/636 Advanced Rendering Techniques
© Chun-Fa Chang Sampling Theorem & Antialiasing. © Chun-Fa Chang Motivations “ My ray traced images have a lot more pixels than the TV screen. Why do.
Antialiasing CptS 548 Advanced Computer Graphics John C. Hart.
Ray Tracing Primer Ref: SIGGRAPH HyperGraphHyperGraph.
David Luebke 1 9/4/2015 CS 551/651: Advanced Computer Graphics Antialiasing Continued: Prefiltering and Supersampling.
Computer Graphics Inf4/MSc Computer Graphics Lecture 9 Antialiasing, Texture Mapping.
Image Synthesis Rabie A. Ramadan, PhD 3. 2 Our Problem.
Antialiasing CAP4730: Computational Structures in Computer Graphics.
Seeram Chapter 7: Image Reconstruction
10/26/04© University of Wisconsin, CS559 Fall 2004 Last Time Drawing lines Polygon fill rules Midterm Oct 28.
Filtering Robert Lin April 29, Outline Why filter? Filtering for Graphics Sampling and Reconstruction Convolution The Fourier Transform Overview.
CS 450: COMPUTER GRAPHICS ANTIALIASING SPRING 2015 DR. MICHAEL J. REALE.
Week 6 - Wednesday.  What did we talk about last time?  Light  Material  Sensors.
Tod R. Lauer (NOAO) July 19, 2010 The Formation of Astronomical Images Tod R. Lauer.
09/19/2002 (C) University of Wisconsin 2002, CS 559 Last Time Color Quantization Dithering.
Digital Image Processing DIGITIZATION. Summery of previous lecture Digital image processing techniques Application areas of the digital image processing.
Image Processing Basics. What are images? An image is a 2-d rectilinear array of pixels.
CMSC 635 Sampling and Antialiasing. Aliasing in images.
Duy & Piotr. How to reconstruct a high quality image with the least amount of samples per pixel the least amount of resources And preserving the image.
MIT EECS Sampling, Aliasing, & Mipmaps. MIT EECS Last Time? Global illumination “physically accurate light transport” The rendering equation.
Lecture 6 Rasterisation, Antialiasing, Texture Mapping,
02/05/2002 (C) University of Wisconsin 2002, CS 559 Last Time Color Quantization Mach Banding –Humans exaggerate sharp boundaries, but not fuzzy ones.
2D Sampling Goal: Represent a 2D function by a finite set of points.
Sampling Theorem & Antialiasing
Lecture 3: The Sampling Process and Aliasing 1. Introduction A digital or sampled-data control system operates on discrete- time rather than continuous-time.
CS559: Computer Graphics Lecture 12: Antialiasing & Visibility Li Zhang Spring 2008.
Lecture 5: Fourier and Pyramids
1 Dr. Scott Schaefer Antialiasing. 2/70 What is aliasing?
Instructor: Mircea Nicolescu Lecture 5 CS 485 / 685 Computer Vision.
David Luebke 3/17/2016 Advanced Computer Graphics Antialiasing David Luebke
Antialiasing. What is alias? Alias - A false signal in telecommunication links from beats between signal frequency and sampling frequency (from dictionary.com)
Sampling (Section 4.3) CS474/674 – Prof. Bebis.
Sampling Week 7, Fri 17 Oct 2003 p1 demos sampling.
… Sampling … … Filtering … … Reconstruction …
Sampling Theorem & Antialiasing
(C) 2002 University of Wisconsin, CS 559
Sampling and Antialiasing
General Functions A non-periodic function can be represented as a sum of sin’s and cos’s of (possibly) all frequencies: F() is the spectrum of the function.
Fundamentals Data.
Joshua Barczak CMSC435 UMBC
CSCE 643 Computer Vision: Image Sampling and Filtering
© University of Wisconsin, CS559 Spring 2004
CSC418 Computer Graphics Aliasing Texture mapping.
Presentation transcript:

CS 551 / CS 645 Antialiasing

What is a pixel? A pixel is not… –A box –A disk –A teeny tiny little light A pixel is a point –It has no dimension –It occupies no area –It cannot be seen –It can have a coordinate A pixel is more than a point, it is a sample

Samples Most things in the real world are continuous Everything in a computer is discrete The process of mapping a continuous function to a discrete one is called sampling The process of mapping a continuous variable to a discrete one is called quantization Rendering an image requires sampling and quantization

Line Segments We tried to sample a line segment so it would map to a 2D raster display We quantized the pixel values to 0 or 1 We saw stair steps, or jaggies

Line Segments Instead, quantize to many shades But what sampling algorithms is used?

Area Sampling Shade pixels according to the area covered by thickened line This is unweighted area sampling A rough approximation formulated by dividing each pixel into a finer grid of pixels

Unweighted Area Sampling Pixel intensity decreases as distance betewen the pixel center and edge increases Primitive cannot affect intensity of pixel if it does no intersect the pixel Equal areas cause equal intensity, regardless of distance from pixel center to area

Weighted Area Sampling Unweighted sampling colors two pixels identically when the primitive cuts the same area through the two pixels Intuitively, pixel cut through the center should be more heavily weighted than one cut along corner

Weighted Area Sampling Weighting function, W(x,y) –specifies the contribution of primitive passing through the point (x, y) from pixel center x Intensity W(x,y)

Images An image is a 2D function I(x, y) that specifies intensity for each point (x, y)

Sampling and Image Our goal is to convert the continuous image to a discrete set of samples The graphics system’s display hardware will attempt to reconvert the samples into a continuous image: reconstruction

Point Sampling an Image Simplest sampling is on a grid Sample depends solely on value at grid points

Point Sampling Multiply sample grid by image intensity to obtain a discrete set of points, or samples. Sampling Geometry

Some objects missed entirely, others poorly sampled Sampling Errors

Fixing Sampling Errors Supersampling –Take more than one sample for each pixel and combine them How many samples is enough? How do we know no features are lost?

Unweighted Area Sampling Average supersampled points All points are weighted equally

Weighted Area Sampling Points in pixel are weighted differently –Flickering occurs as object moves across display Overlapping regions eliminates flicker

Frequency Domain Fourier Transform –Convert signal, f(x), from spatial domain to frequency domain, F (u) –F (u) indicates how much of u frequency is in image

Sampling in the Frequency Domain Remember, sampling was defined as multiplying a grid of delta functions by the continuous image This is called a convolution in frequency domain The sampling grid The function being sampled

Convolution This amounts to accumulating copies of the function’s spectrum sampled at the delta functions of the sampling grid

Nyquist Rate The lower bound on an image’s sample rate is the Nyquist Rate The Nyquist rate is twice the highest frequency component in the spectrum Actually, sampling greater than Nyquist is usually required –Draw special case

Aliasing Sampling below Nyquist rate can result in loss of high-frequencies –Draw picture May also result in adding high frequency –Texture map of brick wall (seen on DVD’s)

Filtering To lower Nyquist rate, remove high frequencies from image: low-pass filter –Only low frequencies remain Sinc function is common filter: –sinc(x) = sin (  x)/  x Spatial Domain Frequency Domain

Sinc function Value of 1 at sample point and 0 at other integer values Exactly matches values at sample points But has infinite extent But has negative values But assumes sample repeats infinitely Truncated version introduces high frequencies again

Bilinear Filter Sometimes called a tent filter Easy to compute –just linearly interpolate between samples Finite extent and no negative values Still has artifacts

Supersampling Techniques Adaptive supersampling –store more points when necesssary Stochastic supersampling –Place sample points at stochastically determined points Eye has harder time detecting aliasing when combined with the noise generated by stochastics