Presentation is loading. Please wait.

Presentation is loading. Please wait.

Noises & Turbulences. Why Noises? One of the most popular procedural technique Very few things in nature are regular Great variety of noises exists The.

Similar presentations


Presentation on theme: "Noises & Turbulences. Why Noises? One of the most popular procedural technique Very few things in nature are regular Great variety of noises exists The."— Presentation transcript:

1 Noises & Turbulences

2 Why Noises? One of the most popular procedural technique Very few things in nature are regular Great variety of noises exists The simplest way = white noise: out = random(); –A very bad way of generating noise No memory No spatial relation to anything Not visually interesting

3 What is Noise? Defined by noise functionDefined by noise function R → R functionR → R function statistically invariant to translation R 2 → R functionR 2 → R function +statistically invariant to rotation Any R n → R functionAny R n → R function +sharp frequency spectrum

4 Lattice Noises Need to relate noise to space –Output = noise(point coord); Family of lattice noises: –Generate a 1D/2D/3D grid –Compute random values at grid points –Store values –During rendering: interpolate neighbors Questions to make a practical algorithm –What are the values at the nodes? –Interpolation strategy?

5 First noise in CGFirst noise in CG Ken Perlin: An Image Synthesizer, 1985Ken Perlin: An Image Synthesizer, 1985 Originally defined as a lattice gradient noiseOriginally defined as a lattice gradient noise Interpolation dependentInterpolation dependent different interpolation example different interpolation example Perlin Noise

6 Perlin Noise History Tron 1981Tron 1981

7 Lattice Noise Types Value noise –n-linear interpolation in between random values Gradient noise –Store gradient vectors in the nodes –Values are zero at the nodes Value-gradient noise a)weighted sum of value & gradient b)Hermite interpolation Lattice convolution noise –convolution interpolation

8 Value-Gradient Comparison Value / ValGrad 0.25 / ValGrad 0.5 / ValGrad 0.75 / Gradient

9 Ridged Noise Value / ValGrad 0.25 / ValGrad 0.5 / ValGrad 0.75 / Gradient Palette modulation used for interpolation

10 Most Simple = n-linearMost Simple = n-linear 1D linear 2D bilinear 1D linear 2D bilinear Interpolations

11 Interpolation Blending Functions Linear interpolation on f(0), f(1):Linear interpolation on f(0), f(1): f(x) = (1-x) f(0) + x f(1) uses blending functions (1-x), x In general:In general: f(x) = u(x) f(0) + v(x) f(1) Requirements on blending functions (x  0,1  )Requirements on blending functions (x  0,1  ) a)u(x) + v(x) = 1 b)u(0) = 1 v(0) = 0 c)u(1) = 0v(1) = 1

12 Smooth Interpolations C 2 continuity = ?C 2 continuity = ? Additional requirements on blending functionsAdditional requirements on blending functions Null derivations:Null derivations: d) u’(0) = 0v’(0) = 0 e) u’(1) = 0v’(1) = 0 One Solution: Hermite cubics P 1, P 4One Solution: Hermite cubics P 1, P 4 u(x) = 2x 3 + 3x 2 + 1u(x) = 2x 3 + 3x 2 + 1 v(x) = -2x 3 + 3x 2v(x) = -2x 3 + 3x 2 f(x) = 2( f(0) – f(1) )x 3 + 3( f(1) – f(0) ) 2 + f(0)f(x) = 2( f(0) – f(1) )x 3 + 3( f(1) – f(0) ) 2 + f(0)

13 Zero derivates  flats in lattice pointsZero derivates  flats in lattice points Use derivates aligned to neighborsUse derivates aligned to neighbors zero derivates aligned derivates zero derivates aligned derivates 1D Cubic Interpolations

14 2D Cubic Interpolations zero derivates aligned derivates zero derivates aligned derivates

15 Composed Interpolations Blending in 1D: f(x) = (1-x) f(0) + x f(1)Blending in 1D: f(x) = (1-x) f(0) + x f(1) What about f(x) = (1-x) u 0 (x) + x u 1 (x)What about f(x) = (1-x) u 0 (x) + x u 1 (x) Set requirementsSet requirements Solution = smoothest cubic interpolationSolution = smoothest cubic interpolation

16 Cosine Interpolation Blending functionsBlending functions u(x) = ( cos(x  ) + 1) / 2u(x) = ( cos(x  ) + 1) / 2 v(x) = ( 1 – cos(x  ) ) / 2v(x) = ( 1 – cos(x  ) ) / 2 Slower computationSlower computation

17 Sharp Interpolations Example

18 Deformed Lattice Interpolations Radial interpolationRadial interpolation –(r,  ) coordinate system –radius, angle –principle same as for ortho-lattices

19 Lattice Noises in 3D Stored lattice = memory consumptiveStored lattice = memory consumptive Store onlyStore only –256 random values –Permutation table Referencing:Referencing: Value table index: P[ ix+P[ iy+P[iz] ] ] P - permutation table Suppressed periodic structureSuppressed periodic structure

20 Convolution Noises 1.Generate random lattice 2.Apply convolution filter until necessary Gaussian convolutionGaussian convolution Values are averaged  averaged noiseValues are averaged  averaged noise

21 Averaged Noise Control = number of iterationsControl = number of iterations Modifications: anisotropic filtersModifications: anisotropic filters → →

22 Other Noise Types Spot Noise (van Wijk, 1991)Spot Noise (van Wijk, 1991) Sparse convolution noise (Lewis 1989)Sparse convolution noise (Lewis 1989) –Interpolation of randomly located random values –Suppresses grid artifacts fBm (Fractal Brownian Move)fBm (Fractal Brownian Move) –frequency based Integral NoiseIntegral Noise –noise(x) = f( noise(x-1) ) Voronoi NoiseVoronoi Noise

23 Spot Noise 1D spot noise function:1D spot noise function: Composition of spot function h(x):Composition of spot function h(x): →

24 Integral Noise n-th integration of white noisen-th integration of white noise

25 Integral Noise Algorithm Init: randomly generate f(0), f 1 (0), … f n-1 (0)Init: randomly generate f(0), f 1 (0), … f n-1 (0) In step x:In step x: 0.f n (x) = random(x) … i. f i (x) = f i (x-1) + f i+1 (x) … n. f(x) = f 0 (x) n+1. remember f(x), f 1 (x), … f n-1 (x) f i (x) = i-th derivate of f(x)f i (x) = i-th derivate of f(x)

26 2D Integral Noise Example Vertical, horizontal edge = 1D noiseVertical, horizontal edge = 1D noise Inner points are zig-zag traversedInner points are zig-zag traversed point[x,y] = composition of point[x-1,y] & point[x,y-1]point[x,y] = composition of point[x-1,y] & point[x,y-1]

27 Voronoi Noise 1.Randomly distribute n points 2.Visualize distance to the nearest neighbour

28 Turbulences Image modulation functionsImage modulation functions Output = f( x + turb(x) )Output = f( x + turb(x) ) Usual requirement = continuityUsual requirement = continuity Modulation sourceModulation source –Simple image –Explicit function

29 Original function = identityOriginal function = identity Lower turbulence is 3 times greater than upperLower turbulence is 3 times greater than upper 1D Turbulence Example

30 Perlin Turbulence k = smallest number satisfyingk = smallest number satisfying 1/2 k+1 < pixel size Sum of noise functionsSum of noise functions Fractal character:Fractal character: –doubling frequency –Halving amplitude Noise function = Perlin noiseNoise function = Perlin noise

31 i = octave number (frequency = 2 i )i = octave number (frequency = 2 i ) Composing Perlin Turbulence

32 1D Perlin Turbulence Frequency self-similarityFrequency self-similarity Not visually attractive in 1DNot visually attractive in 1D

33 2D Perlin Turbulence Noise functions:Noise functions: Composition:Composition:

34 Perlin Turbulence Example Direct visualizationDirect visualization –fractal terrains –clouds

35 Turbulence Modulated Images Image to modulate = clampImage to modulate = clamp Turbulence used: 2D averaged noiseTurbulence used: 2D averaged noise

36 Perlin Turbulence Clouds →

37 Clamp = sin(y)Clamp = sin(y) Perlin turbulencePerlin turbulence smaller turbulence larger turbulence smaller turbulence larger turbulence Marble

38 Wood Clamp = rotation sineClamp = rotation sine Brown paletteBrown palette

39 Other Turbulence Examples

40 Fire 3D turbulence (2D + time) of a flame3D turbulence (2D + time) of a flame

41 Fire Animation

42 Literature David Ebert, Kent Musgrave, Darwyn Peachey, Ken Perlin, and Worley. Texturing and Modeling: A Procedural Approach. Academic Press, October 1994. ISBN 0-12-228760-6.David Ebert, Kent Musgrave, Darwyn Peachey, Ken Perlin, and Worley. Texturing and Modeling: A Procedural Approach. Academic Press, October 1994. ISBN 0-12-228760-6. Ken Perlin: www.noisemachine.comwww.noisemachine.com Tons of examples on www


Download ppt "Noises & Turbulences. Why Noises? One of the most popular procedural technique Very few things in nature are regular Great variety of noises exists The."

Similar presentations


Ads by Google