1 / 51

Physical Based Animation/Simulation

Physical Based Animation/Simulation. Particle Systems. Particle systems offer a solution to modeling amorphous, dynamic and fluid objects like clouds, smoke, water, explosions and fire. Representing Objects with Particles.

landen
Download Presentation

Physical Based Animation/Simulation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Physical Based Animation/Simulation

  2. Particle Systems Particle systems offer a solution to modeling amorphous, dynamic and fluid objects like clouds, smoke, water, explosions and fire.

  3. Representing Objects with Particles • An object is represented as clouds of primitive particles that define its volume rather than by polygons or patches that define its boundary. • A particle system is dynamic, particles changing form and moving with the passage of time. • Object is not deterministic, its shape and form are not completely specified. Instead

  4. Basic Model of Particle Systems • New particles are generated into the system. • Each new particle is assigned its individual attributes. • Any particles that have existed past their prescribed lifetime are extinguished. • The remaining particles are moved and transformed according to their dynamic attributes. • An image of the particles is rendered in the frame buffer, often using special purpose algorithms.

  5. Particle Attributes • Initial position • Initial velocity • Initial size • InitialSize = MeanSize + Rand() X VarSize • Initial color • Initial transparency • Shape • Lifetime Alias|Wavefront’s Maya

  6. Particle Dynamics A particle’s position is found by simply adding its velocity vector to its position vector. This can be modified by forces such as gravity. Other attributes can vary over time as well, such as color, transparency and size. These rates of change can be global or they can be stochastic for each particle.

  7. Particle Extinction • When generated, given a lifetime in frames. • Lifetime decremented each frame, particle is killed when it reaches zero. • Kill particles that no longer contribute to image (transparency below a certain threshold, etc.).

  8. Particle Rendering • Particles can obscure other objects behind them, can be transparent, and can cast shadows on other objects. The objects may be polygons, curved surfaces, or other particles.

  9. Star Trek II: The Wrath of Khan

  10. Particle Hierarchy Particle system such that particles can themselves be particle systems. The child particle systems can inherit the properties of the parents.

  11. Grass • Entire trajectory of a particle over its lifespan is rendered to produce a static image. • Green and dark green colors assigned to the particles which are shaded on the basis of the scene’s light sources. • Each particle becomes a blade of grass. white.sand by Alvy Ray Smith (he was also working at Lucasfilm)

  12. Soft Bodies • Particle system deforms the surface of a NURBS or polygonal object. chewing gum soft body

  13. Physical Based Animation/Simulation

  14. Flocking • Schooling or swarming or herding • Relate to groups of characters • Craig W. Reynolds, “Flocks, herds and schools: A distributed behavioral model”, SIGGRAPH 87 • Three simple rules (steering behavior): • Separation, Alignment, Cohesion • Together gives groups of autonomous agents (boids) a realistic form of group behavior similar to flocks of birds, schools of fish, or swarms of bees. ex1, ex2 • The steering behavior determines how a character reacts to other characters in its local neighborhood. Birds plus -oids

  15. Emergent Behaviors • Combination of three flocking rules results in emergence of fluid group movements • Emergent behavior • Behaviors that aren’t explicitly programmed into individual agent rules • Ants, bees, schooling fishes

  16. Three Rules (Steering Behaviors) • Separation: steer to avoid crowding local flockmates • Alignment: steer toward the average heading of local flockmates • Cohesion: steer to move toward the average position of local flockmates

  17. Three Rules (Steering Behaviors) • In each rule, the steering behavior determines how a character reacts to other characters in its local neighborhood. • Characters outside of the local neighborhood are ignored. • The neighborhood is specified by a distance which defines when two characters are “nearby”, and an angle which defines the character’s perceptual “field of view.”

  18. Separationsteer to avoid crowding local flockmates Gives a character the ability to maintain a certain separation distance from others nearby.

  19. How to Compute Steering for Separation? • First a search is made to find other characters within the specified neighborhood (exhaustive, spatial partitioning, caching scheme) • For each nearby character, a repulsive force is computed by subtracting the positions of our character and the nearby character, normalizing, and then applying a 1/r weighting. (That is, the position offset vector is scaled by 1/r 2.) • These repulsive forces for each nearby character are summed together to produce the overall steering force.

  20. Alignmentsteer toward the average heading of local flockmates Gives an character the ability to align itself with (that is, head in the same direction and/or speed as) other nearby characters

  21. How to Compute Steering for Alignment? • Find all characters in the local neighborhood (as described for separation) • Average together the velocity (or alternately, the unit forward vector) of the nearby characters. • This average is the “desired velocity,” and so the steering vector is the difference between the average and our character’s current velocity (or alternately, its unit forward vector). • This steering will tend to turn our character so it is aligned with its neighbors.

  22. Cohesionsteer to move toward the average position of local flockmates Gives an character the ability to cohere with (approach and form a group with) other nearby characters

  23. How to Compute Steering for Cohesion? • Find all characters in the local neighborhood (as described for separation) • Computing the “average position” (or “center of gravity”) of the nearby characters. • The steering force can applied in the direction of that “average position” (subtracting our character position from the average position, as in the original boids model), or it can be used as the target for seek steering behavior.

  24. Separation, Alignment and Cohesion • In some applications it is sufficient to simply sum up the three steering force vectors to produce a single combined steering for flocking • However for better control it is helpful to: • normalize the three steering components • scale them by three weighting factors before summing them. • As a result, boid flocking behavior is specified by nine numerical parameters: • a weight (for combining), • a distance and an angle (to define the neighborhood) foreach of the three component behaviors.

  25. Combined Behaviors and Groups • Flocking(combining: separation, alignment, cohesion) • Crowd Path Following • Leader Following • Unaligned Collision Avoidance • Queuing(at a doorway)

  26. Physical Based Animation/Simulation

  27. Cognitive Modeling Use AI to allow for planning and learning

  28. User Control Simulation Frame Control Algorithms Simplified control loop • Use feedback to maintain: • balance • velocity (speed and direction) • etc.

  29. State Machines Separate the motion or behavior into several simple states Simple states allow us to generate laws State transitions are triggered by events Example: fall forward until foot hits the ground

  30. Running State Machine

  31. Overview • Virtual Creatures • Creature Representation • Creature Control • Physical Simulation • Behavior • Evolution • Results

  32. Virtual Creatures • Complexity vs. Control • Genetic Algorithms • Darwin (fitness) • Differs from previous work

  33. Creature Representation • Genotype • Phenotype

  34. Creature Representation • Directed Graph • Nodes • Information • Dimensions • Joint-type • Joint-limits • Recursive-limit • Neurons • Connections • Child Node • Position • Orientation

  35. Creature Control • Brain • A directed graph of “neurons” • Effectors • Applied at Joints as Forces or Torques • Muscle Pairs

  36. Creature Control • Neurons • Provide different functions • Sum, product, abs, max, sin, cos, oscillators, etc… • Output vs. Input • Number of inputs dependant on function • Output dependant on input and maybe previous state

  37. Combining Control and Representation

  38. Physical Simulation • Collision Detection • Bounding Box + Pair Specific • Collision Response • Impulses + penalty springs • Friction • Viscosity • For simulating underwater

  39. Behavior • Evolution for a specific behavior • Swimming • Walking • Jumping • Following (Land/Water) • Fitness function evaluated at each step • Weights for more preferred methods

  40. Evolution • Recipe for a successful evolution • Create initial genotypes • From scratch • Calculate survival ratio • Evaluate fitness and kill off the weaklings • Reproduce the most fit • Evolve, and proceed to step 3.

  41. Evolution Mating: CrossOver & Mutation • Reproductive Method • 40% Asexual • 30% Crossover • 30% Grafting

  42. Performance • CM-5 with 32 processors – 3 Hours • Population of 300 • 100 Generations

  43. Results • Homogeneity • Swimmers • Paddlers • Tail-waggers • Walkers • Lizard-like • Pushers/Pullers • Hoppers • Followers • Steering Fins • Paddlers

  44. Overview of vBeluga • Virtual belugas are shown in a wild pod context • Incorporates research on beluga behavior and vocalization conducted at aquarium UBC Zoology • Flow: scientist – game – visitors : wild belugas : captive - wild • Simulation : AI architecture - belugas can learn and alter their behavior based on changes in their environment – updatable: new scientific thinking • Physically-based system allows for natural whale locomotion and realistic water – game research • Realistic graphics : use of actuators (virtual bones and muscles) - game research

  45. Beluga Behavior SystemNNet, Action Selection DiPaola,Akai,Kraus 06 "Experiencing Belugas: Developing an Action Selection-Based Aquarium Interactive", Journal of Adaptive Behavior Foundation AI (NSERC) DiPaola,Akai 06 “Designing Adaptive Multimedia Interactives to Support Shared Learning Experiences", ACM Siggraph EducationDesign HCI / Informal Learning (SAGE) DiPaola,Akai 06 "Blending Science Knowledge and AI Gaming Techniques for Experiential Learning", CA Game Studies Assoc. Gaming/Learning DiPaola,Akai 05 “Shifting Boundaries: the Ontological Implications of Simulating Marine Mammals”, NewForms, Museum of Anthropology IT/Society

  46. Vancouver Aquarium: Adv. Layer

  47. Neural Net Layer

  48. Flexibility of use • Decouple Display with UI (tabletop) • Control crowd by related placement • Main gallery full ui: tabletop, projection, signage • Summer camp simple ui: on every system • Beluga encounters guided system • Corporate gathering main system, ambient mode

More Related