lightcuts: a scalable approach to illumination

70
Lightcuts: A Scalable Approach to Illumination Bruce Walter, Sebastian Fernandez, Adam Arbree, Mike Donikian, Kavita Bala, Donald Greenberg Program of Computer Graphics, Cornell University

Upload: jafari

Post on 04-Jan-2016

30 views

Category:

Documents


0 download

DESCRIPTION

Lightcuts: A Scalable Approach to Illumination. Bruce Walter, Sebastian Fernandez, Adam Arbree, Mike Donikian, Kavita Bala, Donald Greenberg. Program of Computer Graphics, Cornell University. Lightcuts. Efficient, accurate complex illumination. Environment map lighting & indirect Time 111s. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Lightcuts: A Scalable Approach to Illumination

Lightcuts: A Scalable Approach to Illumination

Lightcuts: A Scalable Approach to Illumination

Bruce Walter, Sebastian Fernandez, Adam Arbree, Mike Donikian,

Kavita Bala, Donald Greenberg

Program of Computer Graphics, Cornell University

Page 2: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

2

Lightcuts Lightcuts

• Efficient, accurate complex illumination

Environment map lighting & indirectTime 111s

Textured area lights & indirectTime 98s

(640x480, Anti-aliased, Glossy materials)

Page 3: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

3

ScalableScalable

• Scalable solution for many point lights

– Thousands to millions

– Sub-linear cost

0

100

200

300

400

500

600

0 1000 2000 3000 4000

Number of Point Lights

Tim

e (s

ecs)

Standard

Ward

Lightcut

Tableau Scene

Page 4: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

4

Complex LightingComplex Lighting

• Simulate complex illumination using point lights

– Area lights

– HDR environment maps

– Sun & sky light

– Indirect illumination

• Unifies illumination

– Enables tradeoffs between components

Area lights + Sun/sky + Indirect

Page 5: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

5

Related WorkRelated Work• Hierarchical techniques

– Hierarchical radiosity [eg, Hanrahan et al. 91, Smits et al. 94]

– Light hierarchy [Paquette et al. 98]

• Many lights

– [eg, Teller & Hanrahan 93, Ward 94, Shirley et al. 96, Fernandez et al. 2002, Wald et al. 2003]

• Illumination coherence

– [eg, Kok & Jensen 92, Ward 92, Scheel et al. 2002, Krivanek et al. 2005]

• Env map illumination

– [Debevec 98, Agarwal et al. 2003, Kollig & Keller 2003, Ostromoukhov et al. 2004]

• Instant Radiosity

– [Keller 97, Wald et al. 2002]

Page 6: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

6

Talk OverviewTalk Overview

• Lightcuts

– Scalable accurate solution for complex illumination

• Reconstruction cuts

– Builds on lightcuts

– Use smart interpolation to further reduce cost

Page 7: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

7

Lightcuts ProblemLightcuts Problem

Visiblesurface

Page 8: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

8

Lightcuts ProblemLightcuts Problem

Page 9: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

9

Lightcuts ProblemLightcuts Problem

Camera

Page 10: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

10

Key ConceptsKey Concepts

• Light Cluster

– Approximate many lights by a single brighter light (the representative light)

Page 11: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

11

Key ConceptsKey Concepts

• Light Cluster

• Light Tree

– Binary tree of lights and clusters

Clusters

IndividualLights

Page 12: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

12

Key ConceptsKey Concepts

• Light Cluster

• Light Tree

• A Cut

– A set of nodes that partitions the lights into clusters

Page 13: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

13

Simple ExampleSimple Example

#1 #2 #3 #4

1 2 3 4

1 4

Light Tree

Clusters

IndividualLights

RepresentativeLight

4

Page 14: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

14

Three Example CutsThree Example Cuts

1 2 3 4

1 4

4

1 2 3 4

1 4

4

1 2 3 4

1 4

4

Three Cuts

#1 #2 #4 #1 #3 #4 #1 #4

Page 15: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

15

Three Example CutsThree Example Cuts

1 2 3 4

1 4

4

1 2 3 4

1 4

4

1 2 3 4

1 4

4

Three Cuts

#1 #2 #4 #1 #3 #4 #1 #4

Good Bad Bad

Page 16: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

16

Three Example CutsThree Example Cuts

1 2 3 4

1 4

4

1 2 3 4

1 4

4

1 2 3 4

1 4

4

Three Cuts

#1 #2 #4 #1 #3 #4 #1 #4

Bad Good Bad

Page 17: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

17

Three Example CutsThree Example Cuts

1 2 3 4

1 4

4

1 2 3 4

1 4

4

1 2 3 4

1 4

4

Three Cuts

#1 #2 #4 #1 #3 #4 #1 #4

Good Good Good

Page 18: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

18

Algorithm OverviewAlgorithm Overview

• Pre-process

– Convert illumination to point lights

– Build light tree

• For each eye ray

– Choose a cut to approximate the illumination

Page 19: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

19

Convert IlluminationConvert Illumination

• HDR environment map

– Apply captured light to scene

– Convert to directional point lightsusing [Agarwal et al. 2003]

• Indirect Illumination

– Convert indirect to direct illuminationusing Instant Radiosity [Keller 97]

• Caveats: no caustics, clamping, etc.

– More lights = more indirect detail

Page 20: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

20

Algorithm OverviewAlgorithm Overview

• Pre-process

– Convert illumination to point lights

– Build light tree

• For each eye ray

– Choose a cut to approximate the local illumination

• Cost vs. accuracy

• Avoid visible transition artifacts

Page 21: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

21

Perceptual MetricPerceptual Metric

• Weber’s Law

– Contrast visibility threshold is fixed percentage of signal

– Used 2% in our results

• Ensure each cluster’s error < visibility threshold

– Transitions will not be visible

– Used to select cut

Page 22: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

22

Illumination EquationIllumination Equation

Material term

result = Mi Gi Vi Iilights

Geometric term

Visibility term

Light intensity

Currently support diffuse, phong, and Ward

Page 23: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

23

Illumination EquationIllumination Equation

Material term

result = Mi Gi Vi Iilights

Geometric term

Visibility term

Light intensity

Page 24: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

24

Illumination EquationIllumination Equation

Material term

result = Mi Gi Vi Iilights

Geometric term

Visibility term

Light intensity

Page 25: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

25

Cluster ApproximationCluster Approximation

Cluster

result ~ Mj Gj Vj Iilights

~

j is the representative light

Page 26: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

26

error Mub Gub Vub Ii

Cluster Error BoundCluster Error Bound

Cluster

lights

• Bound each term

– Visibility <= 1 (trivial)

– Intensity is known

– Bound material and geometric terms using cluster bounding volume

ub == upper bound

Page 27: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

27

Cut Selection AlgorithmCut Selection Algorithm

Cut

• Start with coarse cut (eg, root node)

Page 28: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

28

Cut Selection AlgorithmCut Selection Algorithm

Cut

• Select cluster with largest error bound

Page 29: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

29

Cut Selection AlgorithmCut Selection Algorithm

Cut

• Refine if error bound > 2% of total

Page 30: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

30

Cut Selection AlgorithmCut Selection Algorithm

Cut

Page 31: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

31

Cut Selection AlgorithmCut Selection Algorithm

Cut

Page 32: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

32

Cut Selection AlgorithmCut Selection Algorithm

Cut

Page 33: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

33

Cut Selection AlgorithmCut Selection Algorithm

Cut

• Repeat until cut obeys 2% threshold

Page 34: Lightcuts: A Scalable Approach to Illumination

Lightcuts (128s) Reference (1096s)

Kitchen, 388K polygons, 4608 lights (72 area sources)

Page 35: Lightcuts: A Scalable Approach to Illumination

Lightcuts (128s) Reference (1096s)

Error Error x16

Kitchen, 388K polygons, 4608 lights (72 area sources)

Page 36: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

36

Combined IlluminationCombined Illumination

Lightcuts 128s

4 608 Lights(Area lights only)

Lightcuts 290s

59 672 Lights(Area + Sun/sky + Indirect)

Page 37: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

37

Combined IlluminationCombined Illumination

Lightcuts 128s

4 608 Lights(Area lights only)

Avg. 259 shadow rays / pixel

Lightcuts 290s

59 672 Lights(Area + Sun/sky + Indirect)

Avg. 478 shadow rays / pixel(only 54 to area lights)

Page 38: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

38

Lightcuts RecapLightcuts Recap

• Unified illumination handling

• Scalable solution for many lights

– Locally adaptive representation (the cut)

• Analytic cluster error bounds

– Most important lights always sampled

• Perceptual visibility metric

Lightcuts implementation sketch, Petree Hall C, ~4:30pm

Page 39: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

39

Talk OverviewTalk Overview

• Lightcuts

– Scalable accurate solution for complex illumination

• Reconstruction cuts

– Builds on lightcuts

– Use smart interpolation to further reduce cost

Page 40: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

40

Reconstruction CutsReconstruction Cuts

• Subdivide image into blocks

– Generate samples at corners

• Within blocks

– Interpolate smooth illumination

– Use shadow rays when needed to preserve features

• Shadow boundaries, glossy highlights, etc.

• Anti-aliasing

– (5-50 samples per pixel)

Page 41: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

41

Image SubdivisionImage Subdivision

• Divide into max block size (4x4 blocks)

4x4 block

Page 42: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

42

Image SubdivisionImage Subdivision

• Divide into max block size (4x4 blocks)

• Trace multiple eye rays per pixel

• Subdivide blocks if needed

– Based on material, surface normal,and local shadowing configuration

Page 43: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

43

Image SubdivisionImage Subdivision

• Divide into max block size (4x4 blocks)

• Trace multiple eye rays per pixel

• Subdivide blocks if needed

– Based on material, surface normal,and local shadowing configuration

• Compute samples at corners

Samples

Page 44: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

44

Image SubdivisionImage Subdivision

• Divide into max block size (4x4 blocks)

• Trace multiple eye rays per pixel

• Subdivide blocks if needed

– Based on material, surface normal,and local shadowing configuration

• Compute samples at corners

• Shade eye rays using reconstruction cuts

Samples Reconstructioncut

Page 45: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

45

Sample ConstructionSample Construction

• Compute a lightcut at each sample

• For each node on or above the cut

– Create impostor light (directional light)

– Reproduce cluster’s effect at sample

Cluster

ImpostorDirectional light

Page 46: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

46

Reconstruction CutReconstruction Cut

• Top-down traversal of light tree

– Comparing impostors from nearby samples

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 47: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

47

Reconstruction CutReconstruction Cut

• Recurse if samples differ significantly

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 48: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

48

Reconstruction CutReconstruction Cut

• Discard if cluster occluded at all samples

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 49: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

49

Reconstruction CutReconstruction Cut

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 50: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

50

Reconstruction CutReconstruction Cut

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 51: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

51

Reconstruction CutReconstruction Cut

• Interpolate if sample impostors are similar

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 52: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

52

Reconstruction CutReconstruction Cut

• If cluster contribution small enough, shoot shadow ray to representative light

– Lightcut-style evaluation

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 53: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

53

Reconstruction CutReconstruction Cut

Not visited

Recurse

Occluded

Interpolate

Shadow ray

Page 54: Lightcuts: A Scalable Approach to Illumination

Temple, 2.1M polygons, 505 064 lights, (Sun/sky+Indirect)

Page 55: Lightcuts: A Scalable Approach to Illumination

Temple, reconstruction cut block size

Page 56: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

56

Result StatisticsResult Statistics

• Temple model (2.1M polys, 505 064 lights)

Image algorithmAvg. eye rays

per pixelImage time

Lightcuts only 1 225s

Combined (anti-aliased) 5.5 189s

Cut type Avg. shadow rays per cut

Lightcut 373

Reconstruction cut 9.4

Page 57: Lightcuts: A Scalable Approach to Illumination

Grand Central, 1.46M polygons, 143 464 lights, (Area+Sun/sky+Indirect)

Avg. shadow rays per eye ray 46 (0.03%)

Page 58: Lightcuts: A Scalable Approach to Illumination

Tableau, 630K polygons, 13 000 lights, (EnvMap+Indirect)

Avg. shadow rays per eye ray 17 (0.13%)

Page 59: Lightcuts: A Scalable Approach to Illumination

Bigscreen, 628K polygons, 639 528 lights, (Area+Indirect)

Avg. shadow rays per eye ray 17 (0.003%)

Page 60: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

60

ConclusionsConclusions

• Lightcuts

– Scalable, unified framework for complex illumination

– Analytic cluster error bounds & perceptual visibility metric

• Reconstruction cuts

– Exploits coherence

– High-resolution, anti-aliased images

0

100

200

300

400

500

600

0 1000 2000 3000 4000

Number of Point Lights

Tim

e (s

ecs)

Standard

Ward

Lightcut

Page 61: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

61

Future WorkFuture Work

• Visibility bounds

• More light types

– Spot lights etc.

• More BRDF types

– Need cheap tight bounds

• Other illumination types

– Eg, caustics

Page 62: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

62

AcknowledgementsAcknowledgements

• National Science Foundation grant ACI-0205438

• Intel corporation for support and equipment

• The modelers– Kitchen: Jeremiah Fairbanks

– Bigscreen: Will Stokes

– Grand Central: Moreno Piccolotto, Yasemin Kologlu, Anne Briggs, Dana Gettman

– Temple: Veronica Sundstedt, Patrick Ledda, and the graphics group at University of Bristol

– Stanford and Georgia Tech for Buddha and Horse geometry

Page 63: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

63

The EndThe End

• Questions?

Lightcuts implementation sketch, Petree Hall C, ~4:30pm

Page 64: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

64

ScalableScalable

• Scalable solution for many point lights

– Thousands to millions

– Sub-linear cost

0

100

200

300

400

500

600

0 1000 2000 3000 4000 5000

Number of Point Lights

Tim

e (s

ecs)

Standard

Ward

Lightcuts

0

100

200

300

400

500

600

0 1000 2000 3000 4000

Number of Point Lights

Tim

e (s

ecs)

Standard

Ward

Lightcut

Tableau Scene Kitchen Scene

Page 65: Lightcuts: A Scalable Approach to Illumination

Lightcuts Reference

Error x 16Cut size

Page 66: Lightcuts: A Scalable Approach to Illumination

Kitchen, 388K polygons, 59,672 Lights

Page 67: Lightcuts: A Scalable Approach to Illumination

Kitchen, shadow ray false color

0 750 1500

Page 68: Lightcuts: A Scalable Approach to Illumination

Tableau, shadow ray false color

0 750 1500

Page 69: Lightcuts: A Scalable Approach to Illumination

Kitchen with sample locations marked

Page 70: Lightcuts: A Scalable Approach to Illumination

LIGHTCUTS

SIGGRAPH 2005

70

Types of Point LightsTypes of Point Lights

• Omni

– Spherical lights

• Oriented

– Area lights, indirect lights

• Directional

– HDR env maps, sun&sky