Top Banner
03/03/03 © 2003 University of Wisc onsin Last Time Subsurface scattering models Sky models
27

03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

Jan 18, 2018

Download

Documents

Sybil Byrd

03/03/03© 2003 University of Wisconsin Dynamic Range Real scenes contain both very bright and very dark regions Dynamic range is the ratio of the brightest to darkest points in the scene Standard measurement is candelas per m 2 (defined shortly) For example, in the interior of the church the dynamic range is 100,000 to 1
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Last Time

• Subsurface scattering models• Sky models

Page 2: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Today

• Tone-reproduction

Page 3: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Dynamic Range

• Real scenes contain both very bright and very dark regions

• Dynamic range is the ratio of the brightest to darkest points in the scene

• Standard measurement is candelas per m2 (defined shortly)

• For example, in the interior of the church the dynamic range is 100,000 to 1

Page 4: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Tone Reproduction• The human eye can globally adapt to about 109:1

– Adjusts for the average brightness we perceive in one scene– Global adaptation lets us see in very low light or very bright conditions– But it’s slow - how slow?

• The human eye can locally adapt to about 10,000:1– In a single scene (global adaptation level), we can perceive contrast across

this range• Most display devices have a very limited dynamic range

– On the order of 100:1 for a very good monitor or film• Tone reproduction is the problem of making the 10,000:1 scene look

right on a 100:1 display device

Page 5: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

An Artist’s Approach

• Artists have known how to do this for centuries

• e.g. Vermeer (spot the tricks)

Page 6: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

More Vermeer

Page 7: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Measurements

• We have discussed things in terms of radiometry, with quantities such as Watts, meters, seconds, steradians

• Photometry deals with radiometric quantities pushed through a response function– A sensor (the human eye) has a response curve, V– Luminance (candelas per meter squared, cd/m2) is the integral of

radiance against the luminous efficiency function (the sensor response function)

Page 8: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Luminous Efficiency

dRV )()( Luminance

Page 9: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Color and Luminance

• The CIE XYZ color space is intended to encode luminance in the Y channel

• To get from RGB to XYZ, apply the following linear transform:– Taken from Sillion and Puech, other sources differ

bgr

ZYX

78.008.000.008.071.033.014.021.067.0

ZYX

bgr

284.1169.0083.0023.0652.1814.0261.0482.0730.1

Page 10: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

CIE (Y,x,y)

• The XYZ space includes brightness info with color info– X and Z get bigger as the color gets brighter

• To avoid this, use (Y,x,y)– x=X/(X+Y+Z)– y=Y/(X+Y+Z)

• (x,y) are chromaticity values

Page 11: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Automatic Tone Reproduction

• There are three main classes of solutions:– Global operators find a mapping from image to display luminance

that is the same for every pixel– Local operators change the mapping from one pixel to the next– Perceptually guided operators use elements of human perception to

guide the tone reproduction process

Page 12: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Linear Mappings• The simplest thing to do is to linearly map the highest intensity in the

image to the highest display intensity, or the lowest to the lowest– This gives very bad results, shown for mapping the maps lowest to lowest

Page 13: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Non-Linear Mappings

• Instead of linear, define some other mapping: Ld=M(Lw)– Display luminance is some function of the world luminance

• It is important to retain relative brightness, but not absolute brightness– If one point is brighter than another in the source, it should be

brighter in the output– The mapping M should be strictly increasing

Page 14: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Histogram Methods(Ward Larson, Rushmeier and Piatko, TVCG 97)

• In any one scene, the dynamic range is not filled uniformly• The aim of histogram methods is to generate a mapping that

“fills in the gaps” in the range

Page 15: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Building Histograms

• Work in brightness: B=log10(L)– Humans are more sensitive to “brightness,” but the formula is a hack

• The histogram is a count of how many pixels have each brightness– Choose a set of bins– Break the image into chunks that subtend about 1 of arc

• Assumes you know the camera– Average brightness in each chunk– Count chunks that fall in each bin, f(bi)– Result is graph on previous image

Page 16: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Cumulative Distribution

• We can consider the historgram counts as the probability of seeing a pixel in each range

• The cumulative distribution function is defined:

i

i

bi

bbi

bfTT

bfbP

Page 17: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Histogram Equalization

• The aim is an output histogram in which all the bins are roughly equally filled

• The naïve way to do this is to set:

• Then, go through and convert brightness back into luminance for display

wdmindmaxdminde BPLLLB logloglog

Page 18: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Naïve Histogram

Linear left.Histogram right.What went wrong?

Page 19: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Avoiding Super-Sensitivity

• We should make sure that we do not increase contrast beyond the linear mapping contrast:

• This imposes a constraint on the frequency in each bin:

• Reduce the count of bins that exceed the maximum– Have to iterate, because changing counts changes T

w

d

w

d

LL

dLdL

dmindmax LLbTbfloglog

Page 20: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Better Histogram Adjustment

OldNew

Page 21: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Cumulative Distributions

When does it fail to converge?When does it fail to maintain contrast?

Page 22: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

More Histogram Methods

• The process can be further adapted to handle human contrast sensitivity– Avoid wasting range on things that cannot be resolved– Explicitly make sure that irresolvable features remain that way

• Details next lecture

Page 23: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Local Methods

• Histogram methods do poorly if there is too much dynamic range in the input– Can’t avoid reducing contrast below what should be resolvable

• Local methods exploit the local nature of contrast– You don’t compare the brightness of two things across the room, only

neighboring points

• These methods are justified (in part) by the following:– Pixel intensity depends on the product of reflectance and illumination– Reflectance changes fast– Illumination changes slowly

Page 24: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

Basic Idea

• Filter to separate high and low frequencies• Compress the low frequencies

– Using diffusion filters, typically

• Add back in the high frequencies• LCIS is one algorithm

– Tumblin and Turk, SIGGRAPH 99

Page 25: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

What’s the Problem?

Page 26: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

For Comparison

Page 27: 03/03/03© 2003 University of Wisconsin Last Time Subsurface scattering models Sky models.

03/03/03 © 2003 University of Wisconsin

LCIS Problems

• Luminance does change quickly sometimes– At shadow boundaries and occlusion boundaries

• The filtering has to be carefully adapted to make sure the reflectance and lighting components are separated– Standard problem is a dark halo around a bright object– Sharp changes at shadows get interpreted as shading– When added back into contrast reduced base layer, they give

artifacts– This can be fixed (next lecture)