Student Name: Kae Thong Chew - PowerPoint PPT Presentation

1 / 56
About This Presentation
Title:

Student Name: Kae Thong Chew

Description:

The axiom as been defined as F F F F. to model a square shape ... The initial axiom screenshots for square shape. Example of Research Implementation Results ... – PowerPoint PPT presentation

Number of Views:60
Avg rating:3.0/5.0
Slides: 57
Provided by: chewka
Category:

less

Transcript and Presenter's Notes

Title: Student Name: Kae Thong Chew


1
Introduction
  • Student Name Kae Thong Chew
  • Presentation topic title Procedural Generation
    Terrains for Games using Fractals and L-systems.
  • Supervisor Dr. Penny De Byl

2
Why is this research important
  • Computer games today are incredibly complex
  • As game universes become more complex more
    worlds, more buildings, more rooms, with more
    polygons, textures, characters and so on
  • Hiring game artists become a very expensive
    exercise.

3
Why is this research important
  • As game worlds grow larger, so do the data files
    storing the game information game map designs,
    character models etc..
  • Example Castle Wolfenstein install file(1983)
    69kb but Return to Castle Wolfenstein (2001) demo
    install file 114.1 MB
  • How to solve this problem
  • Procedural terrain generation

4
Procedural Terrain Generation
  • Procedural terrain generation  is about making
    use of computer algorithms to dynamically
    generate terrain without manually hand drawn each
    of the terrain.

5
Different Approaches to Procedural Generated
Terrain
  • Some of the procedural generation methods used in
    contemporary games include
  • Fractal landscape
  • Perlin Noise
  • Pseudo Random Number Generator (PRNG)
  • L-systems
  • Voronoi maps

6
Fractal Landscape
  • A fractal landscape is recursively self-similar,
    that appears similar at all scales of
    magnification.

7
Fractal Landscape
  • A way to create this fractal landscape is to
    employ random midpoint displacement algorithm.

8
Fractal Landscape
  • Another method is to divide and purturb.

9
Fractal Landscapes
10
Fractal Landscapes
11
Perlin Noise
  • Developed by Ken Perlin to create textures.
  • Uses interpolation between a large number of
    pre-calculated gradient vectors to construct a
    value that varies pseudo-randomly over space
    and/or time to create textures.
  • linear interpolation cosine
    interpolation

12
Perlin Noise
  • Two-dimensional Perlin noise.
  • Salt and pepper noise, band-limited, and then
    up-sampled.
  • Procedural marble texture

13
Pseudo Random Number Generator (PRNG)
  • A pseudorandom number generator (PRNG) is an
    algorithm that generates a sequence of numbers
    which are not truly random.
  • This is used together with Perlin Noise to
    achieve nice-looking textures.

14
Voronoi maps
  • Voronoi maps choose a limited number of random
    specific points and calculates the distance of
    each grid cell from the nearest defined point.
  • Each point creates territories around itself
    until it meets a neighbouring shape.

15
Voronoi Maps
  • The final image represent the boundaries or the
    graduated distances where the calculations can be
    varied to generate different results.

16
Procedural Generation Methods used in Games
  • One good example of a game that uses the
    procedurally generated content technology is a PC
    simulation game called Spore.
  • Spore is a simulation game about life evolution.

17
Procedural Methods used in Games
  • Spore uses procedural generation methods where
    the game itself can generate its unique animation
    based from players creature design on the fly
    without game artists create them.

18
Procedural Methods used in Games
  • Spore implements procedural planet generation and
    a simulation of dynamic atmospheric scattering
    like the space phase of Spore.

19
L-systems
  • L-systems are a special kind of string rewriting
    grammars introduced by A.Lindenmayer in 1968 for
    modeling plants.
  • They rewrite a given string (a sequence of
    symbols) according to a grammar, i.e. a set of
    rules. To give an example, the single rule
  • a ? b a b
  • transforms the string
  • a b a c
  • into
  • b a b b b a b c

20
Examples of L-systems
  • Used for modelling tree plant branches
  • Example using
  • Axiom Xwhere rules F --gt FFrules X --gt
  • F-XXFFX-Xangle 22.5
  • will produce the image

21
Examples of L-systems
  • Using turtle graphics, to draw images
  • The Sierpinski triangle drawn using an L-system.
  • variables  A B
  • constants  -
  • axiom   A
  • rules   (A ? B-A-B),
  • (B ? ABA)
  • angle   60º
  • Evolution for n 2, n 4, n 6, n 9

22
L-System Turtle Implementation
  • L-Systems use string symbols to model elements of
    drawing on the computer screen as turtle graphics
    to produce screen images.
  • The "turtle" is an imaginary pen that is given
    drawing commands, such as go forward and turn
    right to draw on the screen.

23
L-systems used for creating cities
  • Parish and Müller (2001) procedurally using
    extended L-systems to build street maps and city
    buildings.

24
L-systems used for creating cities
  • This is useful for urban modelling and planning
    environment but lacks support for real time
    interactively.
  • However, this problem has been approached and
    refined by G. Stefan, P. Jeremy, S. Nigel and
    L.Geoff (2003) by creating a pseudo infinite
    virtual cities in real-time to the user.

25
L-systems used for creating cities
  • Real time procedural cities screenshots.

26
Research Interest
  • Both these L-System research work focus on
    modelling exterior look of buildings only but no
    attempt has been made on creating the interior
    design of the buildings
  • How do we determine the interior of buildings for
    game maps ?

27
L-Systems for Dynamic Creation of Building
Interiors
  • Using L-systems as modeling structure, we defined
    an interior area by giving a different sets of
    rules.
  • Considering the following example
  • The axiom as been defined as F F F F
  • to model a square shape
  • The rewriting rules for F string would be
  • F ? F W F
  • Where W is another set of rules to draw internal
    walls
  • W ? W W W W

28
Example of Research Implementation Results
  • The initial axiom screenshots for square shape.

29
Example of Research Implementation Results
  • After 1st iteration, interior walls which is
    grey texture are rendered within the square shape

30
Example of Research Implementation Results
  • At the 2nd iterations, more grey interior texture
    can be seen rendered within the square shape.

31
Creating L-System Interiors using Regular Polygons
  • Using the same L-Systems rules, regular polygons
    from triangles to decagons are chosen to create
    interior textures.
  • The result of the image are analyzed and compared
    with other regular polygon generated interiors.
  • Interior textures issues like overlapping and
    collision detection are discussed.

32
Example of L-System regular polygon interiors
  • Triangle L-Systems string rules
  • atom FFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 120

33
Example of L-System regular polygon interiors
  • Square L-Systems string rules
  • atom FFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 90

34
Example of L-System regular polygon interiors
  • Pentagon L-Systems string rules
  • atom FFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 72

35
Example of L-System regular polygon interiors
  • Hexagon L-Systems string rules
  • atom FFFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 60

36
Example of L-System regular polygon interiors
  • Heptagon L-Systems string rules
  • atom FFFFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 51.42857143

37
Example of L-System regular polygon interiors
  • Octagon L-Systems string rules
  • atom FFFFFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 45

38
Example of L-System regular polygon interiors
  • Nonagon L-Systems string rules
  • atom FFFFFFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 40

39
Example of L-System regular polygon interiors
  • Decagon L-Systems string rules
  • atom FFFFFFFFFF
  • Fstr FWF
  • Wstr WW-WW
  • angle 36

40
L-System Interiors Discussion
  • Some regular polygons were considered suitable
    for modelling purposes like generating game maps.
  • These polygons are squares and hexagons ? do not
    have overlapping and collision detections issues.

41
L-System Interiors Discussion
  • Squares are suitable candidates in generating
    city buildings architecture and game maps for
    tile-based strategy RPG.
  • Each of the squares are arranged to adjacent to
    one another in the grid, and each of the tile
    usually represents a game terrain for that game
    map.

42
L-System Interiors Discussion
  • Examples of square-based game maps like Super
    Robot Wars and Disgaea

43
L-System Interiors Discussion
  • Hexagon is used to generate hexagonal game map
    grids called hex map. Most of the war strategy
    games use this layout to generate their game
    maps.
  • The distance between the center of each hex cell
    and the center of all six adjacent hex cells
    remains constant.

44
L-System Interiors Discussion
  • Example of hex map game maps like Battle for
    Wesnoth.

45
L-System Interiors Discussion
  • The L-System examples can be further added
    graphics visually with different kinds of
    textures like doors, windows and picture frames
    to the system to become L-buildings.
  • Different algorithms can be added within string
    production rules to create interesting building
    structure patterns.

46
L-Buildings Examples
  • Screenshots of L-buildings interior design

47
L-System Versus Software Editor Tools
  • Reason of using L-Systems for procedurally
    generating building interiors.
  • L-System can achieve similar results of images to
    those images generated by graphic software
    editors like Maya.
  • The models file size generated by L-Systems and
    Maya are reviewed and compared.

48
L-System Versus Software Editor Tools
49
L-System Versus Software Editor Tools
50
L-System Versus Software Editor Tools
51
L-System Versus Software Editor Tools
52
L-System Versus Software Editor Tools
  • L-System rules settings file rarely increase in
    file sizes and used up a very small storage space
    because it depend on computational algorithm
    method.
  • For the Maya model files, it have significant
    increase in the file size depending on how many
    textures needed to be drawn on that screen.

53
L-System Versus Software Editor Tools
  • The level of efforts are easy for L-Systems
    string rules file.
  • Maya models need to manually draw again the
    required model.
  • L-Systems string rules only took a small amount
    of time to build the model .
  • Maya models files needed to take a lot of time.

54
Contributions to the Research and Games Community
  • Reduce the workload of game level designers.
  • Possibilities to create infinite game worlds.
  • Generate random interior textures with ease and
    produce interesting design.
  • Produce cheaper games while maintained the same
    or high standard quality of its gameplay.

55
Future Work For This Research
  • Complexity of the modelling task.
  • No collision detection.
  • More Randomness.

56
Thank you
  • Any Questions ?
Write a Comment
User Comments (0)
About PowerShow.com