CS 563 Advanced Topics in Computer Graphics Texture Sampling - PowerPoint PPT Presentation

1 / 38
About This Presentation
Title:

CS 563 Advanced Topics in Computer Graphics Texture Sampling

Description:

CS 563 Advanced Topics in Computer Graphics Texture Sampling & antialiasing - Basic Texturing (Ch. 8) Physically Based Rendering Travis Grant grant_travis_at_emc.com – PowerPoint PPT presentation

Number of Views:149
Avg rating:3.0/5.0
Slides: 39
Provided by: Travis124
Category:

less

Transcript and Presenter's Notes

Title: CS 563 Advanced Topics in Computer Graphics Texture Sampling


1
CS 563 Advanced Topics in Computer
GraphicsTexture Sampling antialiasing - Basic
Texturing (Ch. 8)Physically Based Rendering
  • Travis Grant
  • grant_travis_at_emc.com

2
Outline
  • Texture Space Sampling Rate
  • Aliasing associated with Texture
  • Refracted and Reflected Rays
  • Texture Coordinate Generation
  • Texture Interface and basic textures

grant_travis_at_emc.com Slide 2
3
p. 496 Fig. 11.5 (a) ./images/11F05A.png
Grid texture on sphere w/ 1 sample per pixel
grant_travis_at_emc.com Slide 3
4
Two Core Challenges for removing Texture Aliasing
  • Sampling Rate
  • Must be computed in Texture space as opposed to
    screen space
  • Must determine rate which the texture function is
    being sampled
  • Sampling Theory
  • Given the sampling rate we need to remove excess
    frequencies beyond the Nyquist limit from the
    texture function

grant_travis_at_emc.com Slide 4
5
Texture Sampling Rate
texture space
object space
image space
PBRT Texture coordinates are (S,T) - Commonly
used industry Apps often use (u,v) - PBRT uses
(u,v) as a shapes parametric description
coordinates pf(u,v) p(x,y) - Where p(x,y) is
the Worldspace intersection point
p. 488 Fig. 11.2 Slide 5
6
Simple ExampleFinding Texture Sampling Rate
Image Space, Object Space Texture Space
perfectly aligned
  • sPx tPy

thus given a sample spacing of 1 pixel in the
image plane the sample spacing in (s,t) texture
space is (1/xr, 1/yr)
grant_travis_at_emc.com Slide 6
7
Simple ExampleFinding Texture Sampling Rate
Image Space, Object Space Texture Space
perfectly aligned
grant_travis_at_emc.com Slide 7
8
Texture Aliasing
Daylon Leveller Tutorial
- The previous example was purposely kept overly
simple - The following realities all lend to
more complex but common scenarios Object
Visibility Object Shape Perspective Shadowing
Texture Frequency Variance
Daylon Leveller Tutorial Slide 8
9
Texture Sampling Rate
p. 488 Fig. 11.2 Slide 9
10
Estimating Partial Derivatives
n
p. 491 Fig. 11.3 Slide 10
11
Estimating Partial Derivatives
p. 491 Fig. 11.3 Slide 11
12
(u,v) parameterization
dv
p
du
p. 492 Fig. 11.4 Slide 12
13
(u,v) parameterization
or
grant_travis_at_emc.com Slide 13
14
Filtering Texture Functions
first evaluate
band-limit by convolving with the sinc filter
convolved with the pixel filter g(x,y) centered
at the point (x,y)
grant_travis_at_emc.com Slide 14
15
  • What did we get for our efforts?

16
Texture Aliasing
p. 486 Fig. 11.1 (b) ./images/11F01B.png
p. 486 Fig. 11.1 (a) ./images/11F01A.png
Zoom-In of sphere from left Notice High-Frequency
detail is present
Severe aliasing artifacts
grant_travis_at_emc.com Slide 16
17
Texture Aliasing
p. 486 Fig. 11.1 (c) ./images/11F01C.png
p. 486 Fig. 11.1 (a) ./images/11F01A.png
Texture function applied
Severe aliasing artifacts
grant_travis_at_emc.com Slide 17
18
p. 496 Fig. 11.5 (c) ./images/11F05C.png
antialiased image, even with a single sample per
pixel
grant_travis_at_emc.com Slide 18
19
Reflected Refracted Rays
p. 496 Fig. 11.5 (a) ./images/11F05A.png
Tracking ray differentials Left is glass
(reflection refraction) Right is Mirror
(reflection)
grant_travis_at_emc.com Slide 19
20
Tracking Ray Differentials
p. 496 Fig. 11.5 (b) ./images/11F05B.png
p. 496 Fig. 11.5 (c) ./images/11F05C.png
aliasing artifacts
antialiasing w/ ray differentials
grant_travis_at_emc.com Slide 20
21
Specular Reflection
r
r
?
?
?
?
p. 497 Fig. 11.6 Slide 21
22
Specular Reflection
where
is the reflected direction with respect to a
shift of a pixel in the x and y directions
p. 497 Fig. 11.6 Slide 22
23
Texture Coordinate Generation
(s,t)
p. 499 Fig. 11.7 ./images/11F05A.png
(u,v)
Spherical
Planer
Cylindrical
Different texture coordinate generation
techniques Checkerboard texture applied to a
hyperboloid
grant_travis_at_emc.com Slide 23
24
TextureInterfaces and Basic Texture
  • Constant
  • Scale
  • Mix
  • Bilinear

25
References
  • Physically Based Rendering by Gregg Humphreys
    Matt Pharr
  • All Images Obtained from Physically Based
    Rendering CD-ROM
  • Figures recreated by tgrant from figures cited in
    Physically Based Rendering textbook
  • Daylon Graphics Leveller Documentation
  • Raytracer Texturing
  • www.cambridgeincolour.com (Sean T. Mchugh)
  • Digital Image Interpolation
  • Computer Graphics Principles Practice by
    Foley, van Dam, Feiner, Hughes
  • What We Need Around Here is More Aliasing by
    Blinn, J.F.
  • Return of the Jaggy by Blinn, J.F.
  • The Aliasing Problem in Computer-Generated
    Shaded Images by Crow, F.
  • A Comparison of Antialiasing Techniques by
    Crow, F.
  • Harvey Mudd College
  • HMC Tutorial on Partial Differentiation

grant_travis_at_emc.com Slide 25
26
Questions?
27
Backup Slides
grant_travis_at_emc.com Slide 27
28
Geometric Meaning of Partial Derivatives
  • Suppose the graph of z f(x,y) is the surface
    shown. Consider the partial derivative of f with
    respect to x at a point (x0,y0).
  • Holding y constant and varying x, we trace out a
    curve that is the intersection of the surface
    with the vertical plane y y0.
  • The partial derivative fx(x0,y0) measures the
    change in z per unit increase in x along this
    curve. That is, fx(x0,y0) is just the slope of
    the curve at (x0,y0). The geometrical
    interpretation of fy(x0,y0) is analogous.

Harvey Mudd College (see References) Slide 28
29
Blinn What we need around here is more Aliasing
Slide 29
30
Blinn What we need around here is more Aliasing
Slide 30
31
Blinn What we need around here is more Aliasing
Slide 31
32
Blinn What we need around here is more Aliasing
Slide 32
33
Aliasing Review
jaggies staircasing aliasing
Ideal Line on Low Resolution Grid
Aliased
reproduced from cambridgeincolour.com Slide 33
34
Aliasing Review
IF (Line_Is_Inside_Pixel) black
Ideal Line on Low Resolution Grid
Aliased
reproduced from cambridgeincolour.com Slide 34
35
Aliasing Review
High Frequency Variation
Ideal Line on Low Resolution Grid
Aliased
reproduced from cambridgeincolour.com Slide 35
36
Aliasing Review
Ideal Line on Low Resolution Grid
Anti-Aliased
reproduced from cambridgeincolour.com Slide 36
37
Unweighted Area Sampling
Three Properties of Unweighted area sampling 1)
Intensity of the pixel intersected by a line edge
decreases as the distance between the pixel
center and the edge increases 2) Non-intersected
pixels are not influenced 3) Only the total
amount of overlapped area matters (not weighted
based on orientation towards the center of the
pixel)
Ideal Line on Low Resolution Grid
Anti-Aliased
reproduced from cambridgeincolour.com Slide 37
38
Unweighted Area Sampling
Accounting for contributions of original -gt
result is of BLACK (light Gray)
Ideal Line on Low Resolution Grid
Anti-Aliased
reproduced from cambridgeincolour.com Slide 38
Write a Comment
User Comments (0)
About PowerShow.com