precomputed local radiance transfer for real-time lighting design anders wang kristensen tomas...

32
Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented by Shao-Ti Lee 2010/04/08 1

Post on 19-Dec-2015

216 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

1

Precomputed Local Radiance Transfer for Real-time Lighting Design

Anders Wang KristensenTomas Akenine-Moller

Henrik Wann JensenSIGGRAPH ‘05

Presented by Shao-Ti Lee

2010/04/08

Page 2: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

2

OutlineIntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 3: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

3

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 4: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

4

IntroductionMAIN IDEA

◦Unstructured light cloud.

Page 5: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

5

IntroductionMAIN IDEA

◦Unstructured light cloud.

Page 6: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

6

IntroductionFEATURES

◦Local, not distant illumination. Accurately represent incident radiance on

different parts of the model.

◦Light positions and intensities are changeable.

◦Lights can be added or removed.◦Materials can be glossy.◦Camera is fully dynamic.◦Scene is assumed to be static.

Page 7: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

7

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 8: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

8

Related WorkPrecompute the exitant radiance

[Wood et al. 2000; Chen et al. 2002]◦Basis: sphere harmonics.

Page 9: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

9

Related WorkSphere harmonics.

ApproximatedExitantRadiance

ApproximatedExitant Radiancein the SH basis

SH Basis

Page 10: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

10

Related WorkClustered PCA(Principle

Component Analysis) [Sloan et al. 2003]◦For geometry data representation

compression. ClusteringEx. K-Means

PCA

Page 11: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

11

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 12: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

12

Constructing the Light Cloud

Before doing this, first divide the geometry into a set of discrete zones using a simple top-down partitioning algorithm.

Page 13: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

13

Constructing the Light Cloud

Use a two-stage approach to construct the light cloud.◦Stage 1 Make a sufficiently dense

uniform sampling of the region of interest.

◦Stage 2 The light cloud is then simplified by clustering similar lights using a bottom-up clustering algorithm.

Page 14: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

14

Constructing the Light Cloud

This is for point lights.

Page 15: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

15

Constructing the Light Cloud

This is for diffuse surface.

Page 16: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

16

Constructing the Light Cloud

A C

D E F

G H I A B C D E F G H I

Cluster List

Priority queue sorted by △jk

△AB △AD △BD △CE …..

S

S

Compute △SC , △SD , △SE , △SF , △SG ,△SH , △SI and re-sort the priority queue to end a loop and stop until △jk ≧1 for all j, k

B

Page 17: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

17

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 18: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

18

Compressing Surface Radiance

Before compression◦Per vertex matrix X , with np = nb x

nl elements per color channel. nb : The number of SH bases.

nl : The number of lights.

After compression using CPCA

ClusterMean

PCA vectors(bases)

weights

Page 19: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

19

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 20: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

20

Real-time RelightingOrganize the local lights in a kd-

tree and locate the m nearest lights.

Page 21: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

21

Real-time RelightingTo avoid undesirable popping

effects, set the weight for each pre-computed local light to

After computing all weights, normalization is used. And all weights are multiplied by the power of the light at l.

Page 22: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

22

Real-time RelightingVisibility problem

Solution: Use ray tracing with a few rays.

Cannot assign weights!

Page 23: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

23

Real-time RelightingDiscontinuity Problem

Suddenly disappear/appeardue to occlusion!

Solution:Smoothly fade out/in lights over time, but that now have become obscured by geometry.

Page 24: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

24

Real-time RelightingComputing Exitant Radiance

For each cluster, xm and bi are constant.

Page 25: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

25

Real-time RelightingReconstruct the vector of SH

coefficients representing exitant radiance in a vertex program by evaluating

◦Where is the variable to ensure that we get correct blending at the borders between clusters and between zones.

◦Recall that

Page 26: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

26

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 27: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

27

Results

Page 28: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

28

Results

Page 29: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

29

Results

Left: Method of authors.Right: Ray tracing with per pixel lighting.

Page 30: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

30

Results

Page 31: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

31

IntroductionRelated WorkConstructing the Light CloudCompressing Surface RadianceReal-time RelightingResultsConclusion

Page 32: Precomputed Local Radiance Transfer for Real-time Lighting Design Anders Wang Kristensen Tomas Akenine-Moller Henrik Wann Jensen SIGGRAPH ‘05 Presented

32

ConclusionThe system handles indirect

illumination efficiently for models with more than 100,000 triangles.

Future Work◦Soft shadow◦Spotlight