Fractals and Terrain Synthesis

Slides:



Advertisements
Similar presentations
Iteration, the Julia Set, and the Mandelbrot Set.
Advertisements

November 12, 2013Computer Vision Lecture 12: Texture 1Signature Another popular method of representing shape is called the signature. In order to compute.
ATEC Procedural Animation Introduction to Procedural Methods in 3D Computer Animation Dr. Midori Kitagawa.
FRACTALS. WHAT ARE FRACTALS? Fractals are geometric figures, just like rectangles, circles, and squares, but fractals have special properties that those.
Chapter 9: Recursive Methods and Fractals E. Angel and D. Shreiner: Interactive Computer Graphics 6E © Addison-Wesley Mohan Sridharan Based on Slides.
L-systems Presented by Luv Kohli COMP258 October 30, 2002 Images copyright © 1992 D. Fowler, P. Prusinkiewicz, and J. Battjes.
Fractals Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts Director, Arts Technology Center University of New.
Procedural Modeling L-Systems Procedural Terrain Procedural Behavior Based on the slides from Spring 2007.
Simulating Trees with Fractals and L-Systems Eric M. Upchurch CS 579.
Course Website: Computer Graphics 11: 3D Object Representations – Octrees & Fractals.
Curve Analogies Aaron Hertzmann Nuria Oliver Brain Curless Steven M. Seitz University of Washington Microsoft Research Thirteenth Eurographics.
Fractals Infinite detail at every point Self similarity between parts and overall features of the object Zoom into Euclidian shape –Zoomed shape see more.
CS 4731: Computer Graphics Lecture 5: Fractals Emmanuel Agu.
Fractals Complex Adaptive Systems Professor Melanie Moses March
CS4395: Computer Graphics 1 Fractals Mohan Sridharan Based on slides created by Edward Angel.
Multifractals in Real World
Approaches To Infinity. Fractals Self Similarity – They appear the same at every scale, no matter how much enlarged.
Applied Mathematics Complex Systems Fractals Fractal by Zhixuan Li.
IlliDOL: A Framework for Exploration of L- Systems in Three Dimensions Vilas Dhar Math 198 Spring 2003.
10/21/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Terrain Dynamic LOD.
Computing & Information Sciences Kansas State University Lecture 37 of 42CIS 636/736: (Introduction to) Computer Graphics Lecture 37 of 42 Monday, 28 April.
Structured Chaos: Using Mata and Stata to Draw Fractals
Noise Based Texture Noise Based Texture CMPS260 Presentation Guoping Xu Mar. 05, 2003.
Procedural and Fractal Terrains
Interactive Terrain Synthesis
1 Excursions in Modern Mathematics Sixth Edition Peter Tannenbaum.
Algorithmic Art Mathematical Expansions –Geometric, Arithmetic Series, Fibonacci Numbers Computability –Turing Fractals and Brownian Motion, CA –Recursive.
11/19/02 (c) 2002, University of Wisconsin, CS 559 Last Time Many, many modeling techniques –Polygon meshes –Parametric instancing –Hierarchical modeling.
Noise and Procedural Techniques John Spitzer Simon Green NVIDIA Corporation.
4/15/04© University of Wisconsin, CS559 Spring 2004 Last Time More modeling: –Hierarchical modeling –Instancing and Parametric Instancing –Constructive.
Graphics Graphics Korea University cgvr.korea.ac.kr Model Construction 고려대학교 컴퓨터 그래픽스 연구실.
CS 376 Introduction to Computer Graphics 04 / 30 / 2007 Last Lecture :( Instructor: Michael Eckmann.
Model Construction 김 성 남. Contents What is Modeling? Model Construction - Interactive modeling tools - Scanning tools - Computer vision -
Calculating Fractal Dimension from Vector Images Kelly Ran FIGURE 1. Examples of fractals (a) Vector graphics image (b) Sierpinski Carpet D ≈ 1.89 FIGURE.
Multiscale Moment-Based Painterly Rendering Diego Nehab and Luiz Velho
L-Systems and Procedural Plants CSE 3541 Matt Boggus.
College of Computer and Information Science, Northeastern UniversityOctober 13, CS U540 Computer Graphics Prof. Harriet Fell Spring 2007 Lecture.
Ch 9 Infinity page 1CSC 367 Fractals (9.2) Self similar curves appear identical at every level of detail often created by recursively drawing lines.
Examining the World of Fractals. Myles Akeem Singleton Central Illinois Chapter National BDPA Technology Conference 2006 Los-Angeles, CA.
Computer Science Term 1, 2006 Tutorial 3 Assignment 4 – Special Effects.
How to Draw a Tree L-Systems in Computer Graphics Steven Janke.
Fractals smooth surfaces and regular shapes - Euclidean-geometry methods -object shapes were described with equations natural objects - have irregular.
Subdivision Schemes Basic idea: Start with something coarse, and refine it into smaller pieces for rendering –We have seen how subdivision may be used.
Strategies and Rubrics for Teaching Chaos and Complex Systems Theories as Elaborating, Self-Organizing, and Fractionating Evolutionary Systems Fichter,
WORKSHOP “Fractal patterns…” Morahalom, May, 2009 Fractal patterns in geology, and their application in mathematical modelling of reservoir properties.
David Chan TCM and what can you do with it in class?
Section 6.1 Images Viewing a Gallery of Fractals. Look for patterns.
(c) 2000, 2001 SNU CSE Biointelligence Lab Finding Region Another method for processing image  to find “regions” Finding regions  Finding outlines.
Game Programming, Math and the Real World Rolf Lakaemper, CIS, Temple University.
ATEC Procedural Animation Introduction to Procedural Methods in 3D Computer Animation Dr. Midori Kitagawa.
CSE 423 Computer Graphics | MUSHFIQUR ROUF CSE423:
In the name of God Computer Graphics. Shortcomings So Far The representations we have looked at so far have various failings: –Meshes are large, difficult.
Fractals! Bullock Math Academy March 22, 2014 Brian Shelburne
Fractals Ed Angel Professor Emeritus of Computer Science
 Introduction  Definition of a fractal  Special fractals: * The Mandelbrot set * The Koch snowflake * Sierpiński triangle  Fractals in nature  Conclusion.
Fractals Cassi Blum.
Course 3 Binary Image Binary Images have only two gray levels: “1” and “0”, i.e., black / white. —— save memory —— fast processing —— many features of.
Creating a Hat Curve Fractal Objectives: 1.To create a Hat Curve fractal on Geometer’s Sketchpad using iteration. 2.To find the length of the Hat Curve.
Lesson 1: Reflection and its Importance
Grafika Komputer dan Visualisasi Disusun oleh : Silvester Dian Handy Permana, S.T., M.T.I. Fakultas Telematika, Universitas Trilogi Pertemuan 12 : Realisme.
Grammars, L-Systems Jim Whitehead UC Santa Cruz School of Engineering courses.soe.ucsc.edu/courses/cmps265/Spring14/01 23 Apr 2014.
Introduction to Parametric Curve and Surface Modeling.
Fractals and L-Systems
CIS 781 Fractal Terrains.
Iterative Mathematics
ATCM 3310 Procedural Animation
© University of Wisconsin, CS559 Spring 2004
S.K.H. Bishop Mok Sau Tseng Secondary School
Modeling with Geometry
Last Time B-splines Project 3 was made available
Presentation transcript:

Fractals and Terrain Synthesis

WALL-E, 2008]

Proceduralism Philosophy of algorithmic content creation Frees up artist time to concentrate on most important elements (hero characters, major locations) Musgrave: "not one concession to the hated user"

Simulation and Optimization models through simulation of underlying process control through initial settings may be difficult to adjust rules of simulation Optimization: models through energy minimization control through constraints, energy terms may be difficult to design energy function

[Rusnell, Mould, and Eramian 2009]

Height Fields Each point on xy-plane has a unique height value Convenient for graphics – simplifies representation (can store in 2D array) Used for terrain, water waves Drawback: not able to represent full range of possibilities

Height Fields and Texture Can use any texture synthesis process to generate height fields simply interpret intensity as height, create mesh, render The most successful processes have used fractals self-similarity a feature of real terrains self-similarity defining characteristic of fractals

Iterated Function Systems Show up frequently in graphics L-systems replacement grammar a celebrated example Capable of producing commonly cited fractal shapes Sierpinski gasket Menger sponge Koch snowflake

Mandelbrot Set Said to “encode the Julia sets” coloring of the complex plane for connectivity of quadratic Julia sets say Jc is the set for zn+1 = zn2 + c Point c is in the Mandelbrot set if Jc is connected, not in the set otherwise Partitions complex plane “Mandelbrot separator” – fractal curve

Mandelbrot set calculation Turns out that it is quite straightforward to get the Mandelbrot set computationally: for each pixel c: let z0 = c compute z = z2+c repeatedly, until (a) |z| > 2 (diverges) (b) iteration count exceeds constant (say 1000) if diverged, color it according to the iteration number on which it diverged if never diverged, color with some special color

Fractals Nonfractal complexity: arises from accretion of different kinds of detail e.g., people: complex, but not self-similar Fractal complexity: arises from repeating the same details What detail to repeat? Perlin noise a suitable source of detail

Multiresolution Noise Different signals at different scales Fractals: clouds, mountains, coastlines sum 1/2 1/4 1/8 1/16

Multiresolution Noise FNoise(x,y,z) = sum((2^-i)*Noise(x*2^i…)) Extremely common formulation – so common that many mistake it for the basic noise primitive

Fractional Brownian Motion aka fBm requires parameter H (relative size of successive octaves – "roughness") val = 0; for (i = 0; i < octaves; i++) { val += Noise(point)*pow(2,-H*i); point *= 2; }

Fractional Brownian Motion aka fBm requires parameter H (relative size of successive octaves – "roughness") val = 0; for (i = 0; i < octaves; i++) { val += Noise(point)*pow(2,-H*i); point *= 2; } why 2? "Lacunarity" parameter

Lacunarity "Lacunarity" (from Latin "lacuna", gap) gives the spacing between octaves Larger values mean fewer octaves needed to cover same range of scales faster to compute but individual octaves may be visible Smaller values mean more densely packed octaves, richer appearance

Lacunarity Balance between speed and quality Value of 2 the "natural" choice but in genuinely self-similar fractals, may lead to visible artifacts as same features pile up Transcendental numbers good genuinely irrational, no piling at any scale Values slightly over 2 offer good compromise of speed/appearance e-1/2, π-1

Fractal ranges of scale Real fractals are band-limited: they have detail only at certain scales Computed fractals also band-limited practical limitations: don’t write code with infinite loops Mandelbrot: fractal objects have 3+ scales

Midpoint Displacement Repeated subdivision: begin with two endpoints; at each step, divide each edge and perturb the midpoint In 2D: on alternate steps, divide orthogonal and diagonal edges Among the first fractal terrain systems (Fournier/Fussell/Carpenter 1982) Problems: seams from early points

Midpoint Displacement

Midpoint Displacement

Characteristics of fBm Homogeneous: the same everywhere Isotropic: the same in all directions Real terrains are neither mountains differ from plains direction can matter (e.g., rivers flow downhill) Require multifractals

Multifractals Fractal dimension varies with location Simple multifractal: multiplicative cascade val = 1; for (i = 0; i < oct; i++) { val *= (Noise(point)+offset)*pow(2,-H*i) point *= 2; }

Problems Multiplicative formation unstable (can diverge) Extremely sensitive to value of offset Control elusive

Hybrid multifractals In real terrains, higher areas are rougher (new mountains) and lower areas smoother (worn down, silted over) Musgrave: weight of each octave multiplied by current value of function near value=0 (“sea level”), higher frequencies damped – very smooth higher values: more jagged need to clamp value to prevent divergence

Ridges Simple trick to get ridges out of noise: Noise values range from -1 to 1 Take 1-|N(p)| Absolute value reflects noise about y=0; negative moves reflections to top Cellular texture (Voronoi regions) naturally has ridges, if distance interpreted as height

von Koch snowflake

L-Systems "Lindenmeyer systems", after Aristid Lindenmeyer (1960's) Replacement grammar set of tokens rules for transformation of tokens All rules applied simultaneously across string

L-Systems Very successful for modeling certain classes of structured organic objects ferns trees seashells Success has impelled others to apply the methods more widely rust entire ecosystems

L-System example Tokens: A, B Rules A → B B → AB

L-System example Tokens: A, B Rules Initial string: A B → AB Initial string: A Sequence: A, B, AB, BAB, ABBAB… Lengths are Fibonacci numbers (why?)

Geometric Interpretation Strings are interesting, but application to graphics requires geometric interpretation Usual method: interpret individual tokens as geometric primitives

Turtle Graphics The language Logo (1967) – once widely used for education Turtle has heading and position; when it moves, it draws a line behind it Commands: F, B: move forward/backward fixed distance +,- : turn right/left fixed angle [, ] : push or pop the current state A : no-op

L-Systems and the Turtle Example replacement rules for the turtle: F → F-F++F-F everything else unchanged

von Koch snowflake

Branching 'Push' and 'pop' operators can produce branching: A → F[+A][-A]FA F → FF A is an 'apex' – the tip of a branch Each apex sprouts a new branch with buds midway along its length, while existing branches elongate

Turtle Graphics in 3D Turtle has orientation and position Commands: F, B: move forward/backward fixed distance +,- : turn right/left fixed angle (yaw) ^,& : turn up/down fixed angle (pitch) \, / : roll right/left fixed angle [, ] : push or pop the current state A : no-op

Ternary Tree As usual, just one rule: F → F[&F][/&F][\&F] Each segment has three branches attached to its tip