A Novel Hemispherical Basis for Accurate and Efficient Rendering P. Gautron J. Křivánek S....

Preview:

Citation preview

A Novel Hemispherical Basis for Accurate and Efficient

Rendering

P. Gautron J. Křivánek

S. Pattanaik K. Bouatouch

Eurographics Symposium on Rendering 2004

15th Eurographics Workshop on Rendering - 21-23 June, Norrköping, Sweden

EGSR 2004 – Norrköping, Sweden 2

Problem Statement

BRDF Incoming/Outgoing Radiance

F(, ) Sample set

EGSR 2004 – Norrköping, Sweden 3

Problem Statement

Original Function Piecewise linear approximation

Need a more compact and smoothed representation

Better fitting Fast computation of integrals

EGSR 2004 – Norrköping, Sweden 4

Contribution

New set of basis functionsFormula similar to Spherical Harmonics Designed for representing hemispherical functions

Several rotation methods for projected functions

Applications in lighting simulation

EGSR 2004 – Norrköping, Sweden 5

Outline

Applications

BRDF representationEnvironment mappingDirectional radiance caching

Previous workBasis functionsRepresentation of hemispherical functions

Three approaches to hemispherical rotation

The new basisDefinition

EGSR 2004 – Norrköping, Sweden 6

Outline

Previous work

Three approaches to hemispherical rotation

Applications

BRDF representationEnvironment mappingDirectional radiance caching

Basis functionsRepresentation of hemispherical functions

The new basisDefinition

EGSR 2004 – Norrköping, Sweden 7

Basis Functions

fi = f(x)bi(x)dx f(x) = fi bi(x)

g(x) = gi bi(x) f(x)g(x)dx = fi gi

EGSR 2004 – Norrköping, Sweden 8

Spherical Harmonics

Y lm(,) l

m()K l

mP l

m(cos )=

(0,0)

(1,-1)

(2,-2) (2,-1) (2,0) (2,1) (2,2)

(1,0) (1,1)

EGSR 2004 – Norrköping, Sweden 9

Spherical HarmonicsMain Properties

Simple projection and reconstruction

Analytical rotations

EGSR 2004 – Norrköping, Sweden 10

SH For Hemispherical FunctionsZero Hemisphere

Equator discontinuity

Artifacts

Original SH

EGSR 2004 – Norrköping, Sweden 11

SH For Hemispherical Functions

Improve accuracy

Avoid equator discontinuity

Original

Optimizationmatrix

Even Reflection[Westin92]

Least-SquaresApproximation

[Sloan03]

Reflected Original

SH

SH

SH

EGSR 2004 – Norrköping, Sweden 12

SH For Hemispherical Functions

No rotation

No dot product

R

Above equator

EGSR 2004 – Norrköping, Sweden 13

SH For Hemispherical FunctionsConclusion

Do not fit the hemisphere

Specific improvements

No rotations

No dot product

EGSR 2004 – Norrköping, Sweden 14

Hemispherical Basis Functions

[Koenderink96] : Zernike Polynomials

Accurate representation

No rotationsUsed in CUReT BRDF Database

[Makhotkin96] : Shifted Jacobi Polynomials

Accurate representation

No rotationsNot used previously in computer graphics

EGSR 2004 – Norrköping, Sweden 15

Outline

Previous work

Three approaches to hemispherical rotation

Applications

BRDF representationEnvironment mappingDirectional radiance caching

Basis functionsRepresentation of hemispherical functions

The new basisDefinition

EGSR 2004 – Norrköping, Sweden 16

Our Novel Basis

Y lm(,) l

m()K l

mP l

m(cos )=

Spherical Harmonics

(0,0)

(1,-1)

(2,-2) (2,-1) (2,0) (2,1) (2,2)

(1,0) (1,1)

EGSR 2004 – Norrköping, Sweden 17

Our Novel BasisShifting

EGSR 2004 – Norrköping, Sweden 18

Our Novel Basis

H lm(,) l

m() P l

m(2cos -1)= K l

m~

(0,0)

(1,-1)

(2,-2) (2,-1) (2,0) (2,1) (2,2)

(1,0) (1,1)

Hemispherical Harmonics

EGSR 2004 – Norrköping, Sweden 19

HSH Rotation

Intuitive: conversion of HSH coefficients to SH

Analytic: Comparison of SH and HSH basis functions

Brute Force: Precomputation of rotation matrices

3 Methods

EGSR 2004 – Norrköping, Sweden 20

HSH RotationIntuitive

HSH SH R(SH) R(HSH)C RSH C-1

EGSR 2004 – Norrköping, Sweden 21

HSH RotationIntuitive

HSH SH R(SH) R(HSH)C RSH C-1

SparseComputed Numerically

EGSR 2004 – Norrköping, Sweden 22

HSH Rotation

Intuitive: conversion of HSH coefficients to SH

Analytic: Comparison of SH and HSH basis functions

Brute Force: Precomputation of rotation matrices

3 Methods

Reminders: Euler rotation angles

Hemispherical data rotation

EGSR 2004 – Norrköping, Sweden 23

Euler’s Rotation Theorem

« An arbitrary rotation may be described by only three parameters »

ZYZ Angles

EGSR 2004 – Norrköping, Sweden 24

HSH RotationRotation Around Vertical Axis

Y lm(,) l

m()K l

mP l

m(cos )=

H lm(,) l

m() P l

m(2cos -1)= K l

m~

EGSR 2004 – Norrköping, Sweden 25

HSH RotationRotation Around Other Axes

Y lm(,) l

m()K l

mP l

m(cos )=

H lm(,) l

m() P l

m(2cos -1)= K l

m~

EGSR 2004 – Norrköping, Sweden 26

Partial Deletion

β

Deleting vanishing part

(0,0)

C1 x

(1,-1)

C2 x

(1,0)

C3 x

(1,1)

C4 x

Deletion Matrix : projection of « cut » basis functions

computed numericallyhigh frequency dense matrix

EGSR 2004 – Norrköping, Sweden 27

HSH RotationAnalytic

Idea: Use SH rotation matrices

βSH

βHSH

HSH-projected function

SH-projected function using same coefficients

SH rotation

Impact of SH rotation onHSH projected function

βSH = arccos(2cos(βHSH)-1)

EGSR 2004 – Norrköping, Sweden 28

HSH RotationBrute Force

20° 40° 60° 80°Precomputed Rotation Matrices

50° Rotation around Y Axis ?

≈50°x 0.5x 0.5

EGSR 2004 – Norrköping, Sweden 29

Outline

Previous work

Three approaches to hemispherical rotation

Applications

BRDF representationEnvironment mappingDirectional radiance caching

Basis functionsRepresentation of hemispherical functions

The new basisDefinition

EGSR 2004 – Norrköping, Sweden 30

Application: BRDF RepresentationPrinciple

BRDF = 4D FunctionParabolic Parameterization

EGSR 2004 – Norrköping, Sweden 31

Application: BRDF Representation

EGSR 2004 – Norrköping, Sweden 32

Application: BRDF Representation

SHHSH

Less Ringing

Higher Frequency

Accuracy

EGSR 2004 – Norrköping, Sweden 33

Application: Environment MappingPrinciple

For each vertex

CPU

Rotation

CPU

Conversion

GPU

Environment BRDF

Additional Step

EGSR 2004 – Norrköping, Sweden 34

Application: Environment MappingPerformance

Rotation on CPU for SH and HSH

Added conversion (sparse matrix)

Accuracy overcomes computational overhead

EGSR 2004 – Norrköping, Sweden 35

Application : Radiance Caching

Goal : computation of indirect diffuse lightingIrradiance Caching Scheme

EGSR 2004 – Norrköping, Sweden 36

Application : Radiance Caching

Goal : computation of indirect diffuse lightingIrradiance Caching Scheme

EGSR 2004 – Norrköping, Sweden 37

Application : Radiance Caching

Interpolation

Goal : computation of indirect diffuse lightingIrradiance Caching Scheme

EGSR 2004 – Norrköping, Sweden 38

Application : Radiance Caching

HSHHSH

Goal : computation of indirect glossy lighting

EGSR 2004 – Norrköping, Sweden 39

Application : Radiance Caching

Goal : computation of indirect glossy lighting

EGSR 2004 – Norrköping, Sweden 40

Application : Radiance Caching

Interpolation

Goal : computation of indirect glossy lighting

EGSR 2004 – Norrköping, Sweden 41

Application : Radiance Caching

Incident Radiance BRDF

dot product

Goal : computation of indirect glossy lighting

EGSR 2004 – Norrköping, Sweden 42

Application : Radiance Caching

Low frequency BRDFs

New translational gradients formulas

Rotational gradient replaced by rotation

Results

EGSR 2004 – Norrköping, Sweden 43

Conclusion

New basis more accurate than SH

3 methods for computing rotations

Easy to use in SH applications : BRDF Representation, Environment Mapping, Global Illumination

More details on Radiance Caching in« Radiance Caching for Efficient Global Illumination Computation »

(J. Krivanek, P. Gautron, S. Pattanaik, K. Bouatouch)IRISA Technical Report #1623

EGSR 2004 – Norrköping, Sweden 44

Perspectives

Analytic formulas for

SH HSH Conversion MatrixHSH Rotation Matrices

Improve Radiance Caching Hardware Interactive Global Illumination

EGSR 2004 – Norrköping, Sweden 45

Any Questions ?

Rendered using Radiance Caching

EGSR 2004 – Norrköping, Sweden 46

Papers Download

http://www.cgg.cvut.cz/~xkrivanj/papers/index.htm

A Novel Hemispherical Basis for Accurate and Efficient Rendering

Radiance Caching for Efficient Global Illumination Computation

EGSR 2004 – Norrköping, Sweden 47

BRDF Representation Accuracy

Phong BRDF

EGSR 2004 – Norrköping, Sweden 48

BRDF Representation Accuracy

Anisotropic Ward BRDF

Recommended