Models of Animated Rivers for the Interactive Exploration of Landscapes

134
a Ph.D. Defense by Qizhi Yu Under the Advisements of Dr. Fabrice Neyret Dr. Eric Bruneton November 17, 2008 Grenoble Institute of Technology (INPG) 1

description

Grenoble Institute of Technology (INPG). a Ph.D. Defense by Qizhi Yu Under the Advisements of Dr. Fabrice Neyret Dr. Eric Bruneton November 17, 2008. Models of Animated Rivers for the Interactive Exploration of Landscapes. Outline. Introduction Previous work Strategy overview - PowerPoint PPT Presentation

Transcript of Models of Animated Rivers for the Interactive Exploration of Landscapes

Page 1: Models of Animated Rivers  for the Interactive Exploration of Landscapes

a Ph.D. Defense byQizhi Yu

Under the Advisements of Dr. Fabrice Neyret

Dr. Eric Bruneton

November 17, 2008

Grenoble Institute of Technology (INPG)

1

qyu
Page 2: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions

ConclusionConclusion

2

Page 3: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions

ConclusionConclusion

3

Page 4: Models of Animated Rivers  for the Interactive Exploration of Landscapes

4

Page 5: Models of Animated Rivers  for the Interactive Exploration of Landscapes

5

Page 6: Models of Animated Rivers  for the Interactive Exploration of Landscapes

ObjectiveObjective Synthesize visually convincing rivers

Study contentStudy content Modeling▪ River shape & surface details

Animating▪ Water motion in rivers.

6

Page 7: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Many applications, need more Many applications, need more studiesstudies

EA: Crysis Google Earth 7

Page 8: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Multi-scaleMulti-scale Geometry ▪ Kilometer-scale length

millimeter-scale waves Water motion▪ Kilometer-scale mean flow

millimeter-scale fluctuation

Complicated physicsComplicated physics Turbulence Surface phenomena

8

Page 9: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Modeling and animating rivers Modeling and animating rivers

ConstraintsConstraints Real-timeReal-time Scalability Controllability Realism

25 fps or more25 fps or more

9

Page 10: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Modeling and animating rivers Modeling and animating rivers

ConstraintsConstraints Real-time ScalabilityScalability Controllability Realism

Very long or unbounded rivers Camera moves arbitrarily

Very long or unbounded rivers Camera moves arbitrarily

10

Page 11: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Modeling and animating riversModeling and animating rivers

ConstraintsConstraints Real-time Scalability ControllabilityControllability Realism Intuitive handles for

controlling appearance and behavior of rivers

Intuitive handles for controlling appearance and behavior of rivers

11

Page 12: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Modeling and animating rivers Modeling and animating rivers

ConstraintsConstraints Real-time Scalability Controllability RealismRealism

Animated surface details with temporal and spatial continuity

Animated surface details with temporal and spatial continuity

12

Page 13: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Modeling and animating rivers Modeling and animating rivers

ConstraintsConstraints Real-time Scalability Controllability Realism

13

Page 14: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions

ConclusionConclusion

14

Page 15: Models of Animated Rivers  for the Interactive Exploration of Landscapes

3D Navier-Stokes simulation3D Navier-Stokes simulation

2D depth-averaged simulation2D depth-averaged simulation

2D simulation 2D simulation

Surface wave models (2D) Surface wave models (2D)

15

Page 16: Models of Animated Rivers  for the Interactive Exploration of Landscapes

3D Navier-Stokes simulation3D Navier-Stokes simulation

2D depth-averaged simulation 2D depth-averaged simulation

2D simulation2D simulation

Surface wave models (2D) Surface wave models (2D)

16

Page 17: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Incompressible Navier-Stokes equations Incompressible Navier-Stokes equations Momentum conservation

Volume conservation

Boundary conditions

Computational Fluid Dynamics (CFD)Computational Fluid Dynamics (CFD) Numerical methods

17

Page 18: Models of Animated Rivers  for the Interactive Exploration of Landscapes

CFD CFD CG fluid animation CG fluid animation Stable solver [stam99]

Two approachesTwo approaches Eulerian : defines quantities at fixed

point Lagrangian: defines quantities at

particles

18

Page 19: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Water animation Water animation [EMF02] [EMF02] Solve NSE numerically on a grid to get

velocities Use level-set to track water-air

interface

19

Page 20: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Pouring water in a Pouring water in a glass [EMF02]glass [EMF02]

15 minutes per 15 minutes per frameframe

55 x 120 x55 55 x 120 x55 gridsgridsComputationally

expensive! 20

Page 21: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Poorly scalable Poorly scalable CG (stable solver): O(N^3)

Difficult to control for artistsDifficult to control for artists Water Behavior Initial values, boundary

conditions No intuitive relation

21

Page 22: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Smoothed Particle Hydrodynamics Smoothed Particle Hydrodynamics (SPH) (SPH) [MCG03][MCG03] Solve NSE in the “Lagrangian formalism”

Compared with Eulerian approachCompared with Eulerian approach Easier adaptive to complex domain Difficult to reconstruct

a smooth surface

For our purposeFor our purpose Similar problems

as Eulerian approach22

2200 particles5 fps

Page 23: Models of Animated Rivers  for the Interactive Exploration of Landscapes

3D Navier-Stokes simulation3D Navier-Stokes simulation

2D depth-averaged simulation 2D depth-averaged simulation

2D simulation2D simulation

Surface wave models (2D) Surface wave models (2D)

23

Page 24: Models of Animated Rivers  for the Interactive Exploration of Landscapes

2D Shallow Water model [Mol95]2D Shallow Water model [Mol95] Commonly used in Hydraulics for simulating rivers Assumptions▪ Hydrostatic approximation

▪ No vertical water motion Integrate the NS equations along vertical direction Unknowns: depth-averaged velocity & elevation of water surface

24

Page 25: Models of Animated Rivers  for the Interactive Exploration of Landscapes

PropertiesProperties A lot faster than 3D N-S simulation Loss some 3D surface features (e.g.

overturning ) Shallow waves ( wavelength >> depth)

For our purposeFor our purpose Still too expensive, especially for large

rivers Bounded domain (like other simulation).

25

Page 26: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Linear wave equation [KM90]Linear wave equation [KM90] Simplified from shallow water model Assumptions ▪ constant water depth, no advection term

Properties▪ Fast, can’t simulate river flow

26

Page 27: Models of Animated Rivers  for the Interactive Exploration of Landscapes

[Irving et al. 06][Irving et al. 06]

20 processors20 processors

25 minutes per 25 minutes per frameframe

27

Page 28: Models of Animated Rivers  for the Interactive Exploration of Landscapes

3D Navier-Stokes simulation3D Navier-Stokes simulation

2D depth-averaged simulation2D depth-averaged simulation

2D simulation

Surface wave models (2D) Surface wave models (2D)

28

Page 29: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Simulate 2D velocity by solving Simulate 2D velocity by solving 2D N-S2D N-S no surface elevation simulated

Use tricks for surface elevationUse tricks for surface elevation Pressure [CdVL95] Noise [TG01]

29

Page 30: Models of Animated Rivers  for the Interactive Exploration of Landscapes

3D Navier-Stokes simulation3D Navier-Stokes simulation

2D depth-averaged simulation2D depth-averaged simulation

2D simulation2D simulation

Surface wave models (2D) Surface wave models (2D)

30

Page 31: Models of Animated Rivers  for the Interactive Exploration of Landscapes

AssumptionAssumption Deep water: wave length depth Surface (heighfield) = sine waves

MethodMethod Wave spectrum FFT surface elevation

PropertiesProperties Fast, nice ocean waves No water flow, no boundary

We use it as texture examples.We use it as texture examples. 31

Page 32: Models of Animated Rivers  for the Interactive Exploration of Landscapes

AssumptionAssumption Height field

A procedural methodA procedural method Particles on surfaces, advected with a fixed

speed Each carries a wave shape function Superpose all particles height field

PropertiesProperties Imitate object-water interaction No water flow

32

Page 33: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Superpose sine waves [FR86, Pea86]Superpose sine waves [FR86, Pea86] Dynamic wave tracing [GS00]Dynamic wave tracing [GS00] Ship wave [Gla02]Ship wave [Gla02]

33

[Gla02]

[GS00]

[Pea86]

Not for river flow

Page 34: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Many work on water or wave Many work on water or wave animation (CG), river simulation animation (CG), river simulation (Hydraulics)(Hydraulics)

None for river animation under None for river animation under our constrains: our constrains: Real-time Scalability Controllability

34

Page 35: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions

ConclusionConclusion

35

Page 36: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Model river aspects in three Model river aspects in three scales, from coarse to finescales, from coarse to fine

36

Page 37: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Model river aspects in three Model river aspects in three scalesscales Macro-scale: river shape & mean Macro-scale: river shape & mean

water surface water surface

37

Page 38: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Model river aspects in three Model river aspects in three scalesscales Macro-scale: river shape & mean water

surface Meso-scale: individual & structured Meso-scale: individual & structured

waves waves

38

Page 39: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Model river aspects in three Model river aspects in three scalesscales Macro-scale: river shape & mean water

surface Meso-scale: individual & structured

waves Micro-scale: continuous field of Micro-scale: continuous field of

small wavessmall waves

39

Page 40: Models of Animated Rivers  for the Interactive Exploration of Landscapes

We need river velocityWe need river velocity Cause of many meso-scale phenomena Advect surface features

Model water motion in three Model water motion in three scalesscales Macro-scale: mean flow Meso-scale: individual perturbations Micro-scale: continuous irregular

fluctuations40

Page 41: Models of Animated Rivers  for the Interactive Exploration of Landscapes

We need river velocityWe need river velocity Cause of many meso-scale phenomena Advect surface features

Model water motion in three Model water motion in three scalesscales Macro-scale: mean flow Meso-scale: individual perturbations Micro-scale: continuous irregular

fluctuationsWe won’t solve ALL phenomena in this thesis . 41

Page 42: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions 1: Macro-scale1: Macro-scale 2: Meso-scale 3: Micro-scale

ConclusionConclusion42

Page 43: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions 1: Macro-scale1: Macro-scale 2: Meso-scale 3: Micro-scale

ConclusionConclusion43

Page 44: Models of Animated Rivers  for the Interactive Exploration of Landscapes

GoalGoal Shape of rivers Mean flow of rivers

44

Page 45: Models of Animated Rivers  for the Interactive Exploration of Landscapes

GoalGoal Shape of riversShape of rivers Mean flow of rivers

GIS or previous work [KMM88]GIS or previous work [KMM88]

45

Page 46: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Input Input river shape (described as a network)

46

Page 47: Models of Animated Rivers  for the Interactive Exploration of Landscapes

AssumptionAssumption a 2D steady flow

Visually convincing velocityVisually convincing velocity Divergence free Incompressible Boundary-conforming Flowing from source to sink (given flow rate

Q) Continuous

Requirements of algorithmsRequirements of algorithms Fast, scalable and controllable

47

Page 48: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Some existing work Some existing work [BHN07] [BHN07]

suggest suggest using stream function to get

divergence-free vector field

48

Page 49: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Stream function is defined Stream function is defined such that such that

IncompressibilityIncompressibility

49

Page 50: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Properties of stream functionProperties of stream function Const along boundaries Relates to the volume flow rate

Extend to a river networkExtend to a river network Given flow rates and a river network all

boundary values50

Page 51: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Given flow rates, and boundary Given flow rates, and boundary valuesvalues How to determine the internal field ?

51

Page 52: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Assumption Assumption Irrotational (potential) flow

52

Page 53: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Observe a numerical solution of Observe a numerical solution of a Laplace equation a Laplace equation

Streamlines (isocurve of stream function)

53

Page 54: Models of Animated Rivers  for the Interactive Exploration of Landscapes

[GW78][GW78] Interpolant of the Inverse-Distance

Weighted interpolation (IDW) [She68] similar to the harmonic functions.

We adapt IDWWe adapt IDW local for the performance reasons provide parameters for controlling

velocity profile

54

Page 55: Models of Animated Rivers  for the Interactive Exploration of Landscapes

55

d distance to boundariesf smooth functions search radiusp parameters

Page 56: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Our result Our result Numerical solutionNumerical solution

56

Page 57: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Finite differenceFinite difference

57

Page 58: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Interpolation relies heavily on Interpolation relies heavily on distance querydistance query Acceleration needed

Combine with tile-based terrain Combine with tile-based terrain [BN07][BN07] Generate an acceleration data structure in

each newly created terrain on-the-fly

Please see the thesis for more details.58

Page 59: Models of Animated Rivers  for the Interactive Exploration of Landscapes

59

Page 60: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Procedural river flowProcedural river flow Fast Scalable▪ Calculate at needed▪ Velocity locally dependent

Controllable ▪ Control velocity: flow rates, interpolation

parameters▪ Edit shape of river on-the-fly

60

Page 61: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions 1: Macro-scale 2: Meso-scale2: Meso-scale 3: Micro-scale

ConclusionConclusion61

Page 62: Models of Animated Rivers  for the Interactive Exploration of Landscapes

GoalGoal Modeling individual & structured wave

features on river surfaces, with our constraints.▪ Real-time▪ Scalability▪ Controllability▪ Quality

62

Page 63: Models of Animated Rivers  for the Interactive Exploration of Landscapes

63Real sceneReal scene

Page 64: Models of Animated Rivers  for the Interactive Exploration of Landscapes

High-resolution required for High-resolution required for simulation and renderingsimulation and rendering

64

Page 65: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Construct the vector features Construct the vector features from a given velocity field from a given velocity field without numerical simulationwithout numerical simulation

Shockwave

Shockwave

RipplesRipples

65

Page 66: Models of Animated Rivers  for the Interactive Exploration of Landscapes

ProblemsProblems Need to be improved ▪ robustness & efficiency

No solution for surface reconstruction and rendering

66

Page 67: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Improve on existing model [NP01]Improve on existing model [NP01] Result▪ Mean flow shockwave curves (wave crests) ▪ Animated by adding perturbationperturbation to the mean

flow

67

Page 68: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Improve on existing model [NP01]Improve on existing model [NP01] Result▪ Mean flow Mean flow shockwave curves (wave crests) ▪ Animated by adding perturbationperturbation to the mean

flow

Macro-scale

Macro-scale

Meso-scale, [WH91]

Meso-scale, [WH91]

68

Page 69: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Improve on existing model [NP01]Improve on existing model [NP01] Result▪ Mean flow shockwave curves (wave crests) ▪ Animated by adding perturbation perturbation to the mean

flow▪ Very efficientVery efficient

69

Page 70: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Improve on existing model Improve on existing model [NP01][NP01]

Construct appropriate Construct appropriate representation from wave representation from wave features for high-quality features for high-quality renderingrendering

70

Page 71: Models of Animated Rivers  for the Interactive Exploration of Landscapes

lo-res base water surface + hi-res wave lo-res base water surface + hi-res wave surfacesurface

71

Page 72: Models of Animated Rivers  for the Interactive Exploration of Landscapes

lo-res base water surface lo-res base water surface + hi-res wave + hi-res wave surfacesurface

Macro-scale

Macro-scale

72

Page 73: Models of Animated Rivers  for the Interactive Exploration of Landscapes

lo-res base water surface + lo-res base water surface + hi-res wave hi-res wave surfacesurface

Meso-scaleMeso-scale

73

Page 74: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Feature-aligned mesh reducesFeature-aligned mesh reduces geometric aliasing ( geometric aliasing (

normal-noise)normal-noise)

Not feature-aligned

Feature-aligned 74

Page 75: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Define wave surface as sweeping Define wave surface as sweeping a wave profile along the wave a wave profile along the wave curvecurve

User defined Wave profile

Wave curveWave curve

75

Water surface mesh

Water surface mesh

Page 76: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Sample by a quad meshSample by a quad meshaligned the wave curvealigned the wave curve

v 76

Wave curveWave curve

Page 77: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Accurate normals from the wave Accurate normals from the wave profileprofile

u

v

B

NT

P(u,v)

v 77

Page 78: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Mesh stitching ?Mesh stitching ? Re-mesh base surface at each frame, too

expensive

We solve it in the rendering We solve it in the rendering stage stage

Please refer to the thesis for more details

78

Page 79: Models of Animated Rivers  for the Interactive Exploration of Landscapes

79

Page 80: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Simply draw two wave strips Simply draw two wave strips with Z-bufferwith Z-buffer

80

Page 81: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Generate a dedicated mesh at Generate a dedicated mesh at crossingcrossing

81

Page 82: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Final resultFinal result

82

Page 83: Models of Animated Rivers  for the Interactive Exploration of Landscapes

83

Page 84: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Approach: feature-based vector Approach: feature-based vector simulationsimulation Simulation: construct & animate vector

features Rendering: featured-based

representation

84

Page 85: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions 1: Macro-scale 2: Meso-scale 3: Micro-scale3: Micro-scale

ConclusionConclusion85

Page 86: Models of Animated Rivers  for the Interactive Exploration of Landscapes

GoalGoal Modeling small scale animated surface

features

ApproachApproach dynamic textures

Two workTwo work Wave sprites▪ Focus on performance

Lagrangian texture advection▪ Focus on quality

86

Page 87: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction Previous workPrevious work Strategy overviewStrategy overview ContributionsContributions

1. Macro-scale 2. Meso-scale 3. Micro-scale▪ Wave spritesWave sprites▪ Lagrangian texture advection

ConclusionConclusion87

Page 88: Models of Animated Rivers  for the Interactive Exploration of Landscapes

• Sprite: a small textured elementSprite: a small textured element

• Sprites in texture world Sprites in texture world [LN03,LHN05] [LN03,LHN05] • to get large high-resolution texture , low

memory

• Idea: Idea: combine animation + combine animation + texture spritestexture sprites• to get very large river with animated

details, efficiently.88

Page 89: Models of Animated Rivers  for the Interactive Exploration of Landscapes

89

Page 90: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Dynamic adaptive samplingDynamic adaptive sampling A set of particles in world space advected by

flow Keep Poisson-disk distribution in screen

space.

Attach a textured sprite to each Attach a textured sprite to each particleparticle

90

Page 91: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Dynamic adaptive samplingDynamic adaptive sampling A set of particles in world space advected by

flow Keep Poisson-disk distribution Poisson-disk distribution in screen

space.

Attach a textured sprite to each Attach a textured sprite to each particleparticle

Why ?Why ?

91

Page 92: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Uniform densityUniform density Overlapping as little as possible

Easy to ensure spatial continuityEasy to ensure spatial continuity Superimposing sprites (with r=d) ensures

no-holesr

r = d diameter of poisson-disk

92

Page 93: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Dynamic adaptive samplingDynamic adaptive sampling A set of particles in world space

advected by flow Keep Poisson-disk distribution in screen screen

spacespace

Attach a sprite to each particleAttach a sprite to each particleAuto-adapt to

distanceAuto-adapt to

distance

93

Page 94: Models of Animated Rivers  for the Interactive Exploration of Landscapes

AlgorithmAlgorithm Advect particles with the flow in world

space Delete particles out of the view frustum Delete particles violating the minimum

distance required by the Poisson-disk distribution (in screen space)

Insert particles to keep Poisson-disk distribution

94

Page 95: Models of Animated Rivers  for the Interactive Exploration of Landscapes

AlgorithmAlgorithm Advect paticles with the flow Delete particles out of the view frustum Delete particles violating the minimum

distance required by the Poisson-disk distribution (in screen space)

Insert particles to keep Poisson-disk distribution Boundary-sampling algorithm [DH06]

95

Page 96: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Spatial continuitySpatial continuity Smooth kernel Constrained sampling issues near

boundary

Temporal continuityTemporal continuity Fading in/out

Please refer the thesis.Please refer the thesis.96

Page 97: Models of Animated Rivers  for the Interactive Exploration of Landscapes

A set of sprites well distributedA set of sprites well distributed Each sprite ▪ Live in texture space▪ maps to a portion of a reference texture

Reconstruct the global textureReconstruct the global texture Sprite has circular kernel in screen space

, but ellipse in object space▪ So we superimpose them in screen space

97

Page 98: Models of Animated Rivers  for the Interactive Exploration of Landscapes

98

Page 99: Models of Animated Rivers  for the Interactive Exploration of Landscapes

99

Efficient GPU. Inspired from [LN05]

Page 100: Models of Animated Rivers  for the Interactive Exploration of Landscapes

100

Page 101: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Wave-spritesWave-sprites Texture flow surface with scene-

independent performance (in real-time)

LimitationLimitation No sprite deformation considered Sliding of texture between sprites▪ bad especially in place where velocity

gradient is high101

Page 102: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction Previous workPrevious work Strategy overviewStrategy overview ContributionsContributions

1. Macro-scale 2. Meso-scale 3. Micro-scale▪ Wave spritesWave sprites▪ Lagrangian texture advectionLagrangian texture advection

ConclusionConclusion102

Page 103: Models of Animated Rivers  for the Interactive Exploration of Landscapes

A technique of dynamic textureA technique of dynamic texture Conform to the input flow Conserve texture properties (e.g.

spectrum)

PurposePurpose Augment coarse simulation with small

scale appearance

103

Page 104: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Advect texture coordinatesAdvect texture coordinates Texture follow flow and deform But, over stretching destroy texture

properties

Regenerate a textureRegenerate a texture After a delay: “latency”

Blend two de-phased texturesBlend two de-phased textures Illusion of advection

104

Page 105: Models of Animated Rivers  for the Interactive Exploration of Landscapes

How to choose a reasonable How to choose a reasonable latency ? latency ? high bad conservation of spectrum low bad conformation to flow Good one: adapt to local flow condition

(deformation)

In [MB95], only one global In [MB95], only one global valuevalue

105

Page 106: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Idea: adaptive local latencyIdea: adaptive local latency

Local deformation metrics Local deformation metrics

““MIPmap”-like approach:MIPmap”-like approach: Multiple layers of textures Each layer = Eulerian advection method Assign different “latency” to each layer For each pixel, interpolate two

“nearest” layers according to local 106

Page 107: Models of Animated Rivers  for the Interactive Exploration of Landscapes

““latency” of all layers are latency” of all layers are bounded in a rangebounded in a range e.g. For zero-velocity , the ideal latency

should be infinity close to still area, we can’t choose a good latency value

Interpolation : not accurateInterpolation : not accurate

Eulerian formalism Eulerian formalism not optimal in large sparse domain

(clouds, fire)107

Page 108: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IdeaIdea Lagrangian formalism as in “wave

sprites” work Attach to each particle a deformabledeformable

textured patches mapping to a reference texture

Reconstruct a global texture by blending all patches

108

Page 109: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Advected by flowAdvected by flow

Dynamic Poisson-Dynamic Poisson-disk distributiondisk distribution

d

109

Page 110: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Init: regular gridInit: regular grid

Kernel radius = dKernel radius = d Ensure full coverage

Patch size > 2d Patch size > 2d Allow deformation

2d

d

size

Poisson-disk

110

Page 111: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Init: regular gridInit: regular grid

Kernel radius = dKernel radius = d

Patch size > 2dPatch size > 2d

Map to a random portionMap to a random portion Store (u, v) at nodes

U

V

111

Page 112: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Nodes advected by Nodes advected by flow flow

112

Page 113: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Nodes advected by Nodes advected by flow flow

Delete a patch Delete a patch Exceed some

deformation metric

113

Page 114: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Nodes advected by Nodes advected by flow flow

Delete a patch Delete a patch Exceed some

deformation metric Patch boundary

intersects with kernelA new patch would be generated nearby automatically by Poisson-disk distribution mechanism

114

Page 115: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Temporal & spatialTemporal & spatial Insert / delete temporal Smooth kernel spatial

Define various temporal and Define various temporal and spatial spatial weightsweights on grid nodes on grid nodes

Please see details in the thesis

115

Page 116: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Encode all patches into one Encode all patches into one texture Ttexture Tpatchpatch

Texcoords (u, v) Weights w(x, t)

Accessing the advected textureAccessing the advected texture For each pixel▪ Determine the patches covering current pixel▪ Access reference texture via Tpatch

▪ Blending with weights (only kernel parts!) 116

Page 117: Models of Animated Rivers  for the Interactive Exploration of Landscapes

117

Page 118: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Compare against Eulerian Compare against Eulerian advectionadvection FFT▪ To evaluate the appearant spectrum

Optical flow▪ To evaluate the appearant motion

Input reference textureInput reference texture 3-octave Perlin noise

118

Page 119: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Various input flowVarious input flow

Please see my webpage for more Please see my webpage for more video resultsvideo results

119

Rotation

Shear Free Boundary

Page 120: Models of Animated Rivers  for the Interactive Exploration of Landscapes

120

Page 121: Models of Animated Rivers  for the Interactive Exploration of Landscapes

121

Page 122: Models of Animated Rivers  for the Interactive Exploration of Landscapes

We target textures specified by We target textures specified by global properties, e.g. spectrumglobal properties, e.g. spectrum Useful for natural flow

For non-noise texturesFor non-noise textures Many of them work well High-structured ones▪ Suffer from “ghosting” effects▪ Future work: choose best match portion

from reference texture

122

Page 123: Models of Animated Rivers  for the Interactive Exploration of Landscapes

123

Page 124: Models of Animated Rivers  for the Interactive Exploration of Landscapes

124

Page 125: Models of Animated Rivers  for the Interactive Exploration of Landscapes

A new texture advection methodA new texture advection method Lagrangian formalism▪ Brings decorrelation of texture mapping and

regeneration events Local patches▪ Ensure continuous texture animation ▪ Provide accurate distortion metric

126

Page 126: Models of Animated Rivers  for the Interactive Exploration of Landscapes

IntroductionIntroduction

Previous workPrevious work

Strategy overviewStrategy overview

ContributionsContributions

ConclusionConclusion

127

Page 127: Models of Animated Rivers  for the Interactive Exploration of Landscapes

By using our modelsBy using our models One can achieve real-time, scalable, and

controllable river animation with temporally and spatially continuous details on current desktop

128

Page 128: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Macro-scaleMacro-scale Velocity: more studies on parameters Influence of slope of river bed

129

Page 129: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Meso-scaleMeso-scale Hydraulic jumps, ship waves and

wakes ...

130

Page 130: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Micro-scale I: wave spritesMicro-scale I: wave sprites Various reference textures: domain wise

control Sprites density: adaptive to flow

condition

131

Page 131: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Micro-scale II: Lagrangian texture Micro-scale II: Lagrangian texture advectionadvection Extend to 3D volume Improve: for high-structured texture

132[RNGF03]

Page 132: Models of Animated Rivers  for the Interactive Exploration of Landscapes

Put models togetherPut models together

Integrate with existing systemsIntegrate with existing systems Google Earth, Proland [BN08], video

games …

133EA: Crysis

Google Earth

Proland

Page 133: Models of Animated Rivers  for the Interactive Exploration of Landscapes

134

Page 134: Models of Animated Rivers  for the Interactive Exploration of Landscapes

a Ph.D. Defense by

Qizhi Yu

Under the Advisements of

Dr. Fabrice Neyret

Dr. Eric Bruneton

November 17, 2008

Grenoble Institute of Technology

135