Clouds by xiaoyounan


									  A Simple, Efficient Method for
  Realistic Animation of Clouds
Yoshinori Dobashi* Kazufumi Kaneda** Hideo Yamashita**
               Tsuyoshi Okita* Tomoyuki Nishita***

  *Hiroshima   City University   **Hiroshima   University   ***University   of Tokyo
 Introduction and Motivation
 Simulation
 Rendering
 Results
 Conclusion
        Problem Overview
 Realistic modeling and animation of
  (cumulus-type) clouds
 Two sub-problems:
   Simulation of cloud formation, extinction
    and advection by wind
   Rendering of the clouds, shadows and
    shafts of light
  Previous Work - Simulation
Two categories of simulation methods:

  1. Physical process of fluid dynamics
        Very accurate
        Computationally expensive

  2. Heuristic approach (procedural modeling)
        Computationally inexpensive
        Easier to implement
        Parameters needed
  Previous Work - Rendering
 Accounting for multiple scattering of light
    Computationally expensive

 Using 3-D textures for volume density
    Does not handle atmospheric effects such as
     shafts of light

 Rendering shafts of light using ray-tracing or
  a similar method
    Computationally expensive
 Simple and efficient simulation method
 Support of effects such as ...
   Cloud color by single scattering of light
   Shadows of clouds cast on the ground
   Shafts of light through clouds
 Hardware-accelerated rendering
 Visually convincing result
    Simulation – Basic Idea
 Cellular automaton with binary states
             Nagel‘s Method
 Water vapor turns to water to form clouds
 Use Nagel‘s method to simulate cloud
   Divide 3-D space evenly into 3-D cells
   Assign boolean variables to each cell:
      cld indicates whether cell contain clouds
      hum indicates whether cell has enough water vapor to
       form clouds
      act indicates whether phase transition is ready to occur
            Nagel‘s Method (cont‘d)
 Cell properties in the current animation frame
  ti are used to compute the cell properties in
  the next frame ti+1:
  hum(x, y, z, ti+1) = hum(x, y, z, ti)  act(x, y, z, ti)
  cld(x, y, z, ti+1) = cld(x, y, z, ti)  act(x, y, z, ti)
  act(x, y, z, ti+1) = act(x, y, z, ti) hum(x, y, z, ti) act(x, y, z , ti)

  act is a boolean function and its value is calculated by the
  status of act in the surrounding cells.
                 Cloud Extinction
 Extension to Nagel‘s method:
  cld(x, y, z, ti+1) = cld(x, y, z, ti)  IS(rnd > pext(x, y, z, ti))
  hum(x, y, z, ti+1) = hum(x, y, z, ti) IS(rnd < phum(x, y, z, ti))
  act(x, y, z, ti+1) = act(x, y, z, ti) IS(rnd < pact(x, y, z, ti))

      rnd : uniform random number
      pext : probability of cloud extinction
      phum : probability of vapor forming
      pact : probability of phase transition occurence
              Advection by Wind
 Clouds move, blown by winds
 Wind velocity is different depending on the
  height from the ground
  cld(x, y, z, ti+1) = cld(x – v(z), y, z, ti)
  hum(x, y, z, ti+1) = hum(x – v(z), y, z, ti)
  act(x, y, z, ti+1) = act(x – v(z), y, z, ti)

    v(z) : wind velocity, piecewise linear function
    Assumption: wind blows towards the direction of x-axis
     Controlling Cloud Motion
 Ellipsoids simulate air parcels
 Vapor and phase transition probability:
    higher at center / lower at edge
 Cloud extinction probability:
    Lower at center / higher at edge
 Ellipsoids move in direction of wind
 Different kinds of clouds by controlling
  ellipsoid parameters (sizes and position)
Fast Simulation using Bitfields
 Each cell state (cld, act, hum) can be
  stored in a single bit
 Low memory requirements
 Fast computation of simulation process
 Problem: Random numbers
 Solution: Precalculated look-up tables
    Rendering – Basic Idea
 Smoothing and volume rendering
   Splatting method for clouds
   Spherical shells for shafts of light
       Continuous Density
      Distribution Calculation
 Simulation output is a binary distribution
 Continuous density distribution results from
  smoothing the binary distribution
 Cloud density of a cell is the weighted
  average of the surrounding cells
 Each cell contributes a density distribution
  over an effective radius (Metaballs)
 Cloud density of an arbitrary point is therefore
  a weighted sum of a simple basis function
       Metaball Billboards
 Generate 2-D texture of metaballs
         Rendering - Step 1
 Set up parallel projection with sun at
  viewpoint and initialize framebuffer to 1.0
 Place billboards at centers of metaballs with
  their normals toward the sun
 Starting with billboard closest to the sun,
  project and blend billboards to framebuffer
 Read back value at projected billboard center
  to get attenuation ratio between sun and
    Rendering – Step 1 (cont‘d)
 After all metaballs have been projected,
  framebuffer contains shadow texture
        Rendering – Step 2
 Render all world objects except clouds
 Place billboards at centers of metaballs
  with their normals toward the observer
 Project and blend billboards to
  framebuffer starting with those farthest
  from viewpoint
Rendering – Step 2 (cont‘d)
             Shafts of Light
 Render using spherical shells (made of
 Modify Rendering – Step 2 to:
   Calculate colors of vertices of shell
    polygons (atmospheric conditions)
   Repeat for all shells (back-to-front):
      Render shell k with additive blending function
       and shadow texture mapping
      Render billboards between shell k-1 and shell k
Shafts of Light (cont‘d)
Results (cont‘d)
 Advantages:
   Simulation requires little computation
   Memory requirements are small
   Rendering is fast by making use of graphics
   Shadows of clouds and shafts of light can also be
 Possible improvements:
   Effects of terrain under clouds
   Level of detail
The End


To top