CS 354 R Game Technology

Similar documents
CS 378: Computer Game Technology

Particle Systems. Typical Time Step. Particle Generation. Controlling Groups of Objects: Particle Systems. Flocks and Schools

Traffic/Flocking/Crowd AI. Gregory Miranda

Simulation: Particle Systems

Under the Guidance of

ENHANCING THE CONTROL AND PERFORMANCE OF PARTICLE SYSTEMS THROUGH THE USE OF LOCAL ENVIRONMENTS. Abstract

Chapter 14 Particle Systems & Interactions

Computer Animation. Animation A broad Brush. Keyframing. Keyframing

Topics in Computer Animation

LECTURE 16: SWARM INTELLIGENCE 2 / PARTICLE SWARM OPTIMIZATION 2

Graphs, Search, Pathfinding (behavior involving where to go) Steering, Flocking, Formations (behavior involving how to go)

CS4621/5621 Fall Particle Systems and Compute Shaders

Announcements. Ray tracer is due in five days you should have started by now or you re going to have a bad week. Missing file posted on the web page

Dynamical Simulation 1: Particle Systems and ODEs

Particle Systems: Theory and Practice. Ciara Belle CMSC498A Spring 2012

PARTICLE SWARM OPTIMIZATION (PSO)

NUMB3RS Activity: Follow the Flock. Episode: In Plain Sight

Advanced Algorithms. Particle Systems. Reading. What is a Particle System?

8 Physics Simulations

CS 231. Crowd Simulation. Outline. Introduction to Crowd Simulation. Flocking Social Forces 2D Cellular Automaton Continuum Crowds

The 3D rendering pipeline (our version for this class)

NCCA National Center for Computer Animation Master Project ZHUO YAO LU. MSC Computer Animation. Media School. Bournemouth University NCCA 2005

Chapter 19- Object Physics

Particle Systems. Lecture 8 Taku Komura

Crowd simulation. Taku Komura

Atmospheric Reentry Geometry Shader


1/16. Emergence in Artificial Life. Sebastian Marius Kirsch Back Close

Realtime Water Simulation on GPU. Nuttapong Chentanez NVIDIA Research

When using Flocking with network rendering (LWSN, for instance) you must bake your Flocking results.

Swarm Intelligence Particle Swarm Optimization. Erick Luerken 13.Feb.2006 CS 790R, University of Nevada, Reno

Rendering diffuse objects using particle systems inside voxelized surface geometry. Thorsten Juckel Steffi Beckhaus

Particle Systems A Technique for Modeling a Class of Fuzzy Objects

History. Early viewers

Integrating Physics into a Modern Game Engine. Object Collision. Various types of collision for an object:

Master s Thesis. Animal Stampede Simulation

Computer Graphics. Si Lu. Fall uter_graphics.htm 11/27/2017

Unity Game Development

Week 9 Computational Intelligence: Particle Swarm Optimization

Chapter 13 - Modifiers

3D Starfields for Unity

Topic 10: Scene Management, Particle Systems and Normal Mapping. CITS4242: Game Design and Multimedia

12 - More Steering. from Milligan, "Artificial Intelligence for Games", Morgan Kaufman, 2006

Hierarchical Impostors for the Flocking Algorithm in 3D

Controlling Particle Systems. All elements of a particle system are controlled through this dialog: There are several key parts to this dialog:

Modelling Computational Fluid Dynamics with Swarm Behaviour

9 Dynamics. Getting Started with Maya 491

A simple example. Assume we want to find the change in the rotation angles to get the end effector to G. Effect of changing s

STEERING BEHAVIORS. Markéta Popelová, marketa.popelova [zavináč] matfyz.cz. 2012, Umělé Bytosti, MFF UK

Cloth Simulation on the GPU. Cyril Zeller NVIDIA Corporation

Building an Advanced Particle System

Designing the look and feel for Smoke and Neon powers The creation of a new toolset and pipeline for I:SS Pros and cons from our new workflow and

Streaming Massive Environments From Zero to 200MPH

CSE 167: Introduction to Computer Graphics Lecture #18: More Effects. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016

VEGETATION STUDIO FEATURES

Flames in Particle Flow

C O M P U T E R G R A P H I C S. Computer Animation. Guoying Zhao 1 / 66

CSE 167: Introduction to Computer Graphics Lecture #19: Wrapping Up. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2017

More Animation Techniques

Textures III. Week 10, Wed Mar 24

Computer Graphics: An Introduction. By Michael Berg

BCC 3D Extruded Image Shatter Filter

Animation Essentially a question of flipping between many still images, fast enough

Fundamentals of Computer Animation

Computer Graphics (CS 563) Lecture 4: Advanced Computer Graphics Image Based Effects: Part 1. Prof Emmanuel Agu

Procedural II, Collision. Week 10, Fri Mar 26

Formations in flow fields

Index FEATURES LIST 2

Magic Specific Attributes Quick Tips Features

Real-Time Volumetric Smoke using D3D10. Sarah Tariq and Ignacio Llamas NVIDIA Developer Technology

Effects, part 5. Particle Playground (PB only) Overview of Particle Playground workflow

Shape of Things to Come: Next-Gen Physics Deep Dive

GPU-based Distributed Behavior Models with CUDA

MIXED REALITY (AR & VR) WITH UNITY 3D (Microsoft HoloLens)

BCC Particle System Generator

GPU Particles. Jason Lubken

High-density Crowds. A masters student s journey to graphics and multi agent systems

Adding Virtual Characters to the Virtual Worlds. Yiorgos Chrysanthou Department of Computer Science University of Cyprus

Particle Systems. Sample Particle System. What is a particle system? Types of Particle Systems. Stateless Particle System

Workshop BOND UNIVERSITY. Bachelor of Interactive Multimedia and Design. Asteroids

Actions and Graphs in Blender - Week 8

16 - Other Topics. The Stencil Buffer. Erosion. Fragment Discarding. Multi-Texturing + +

CS 387/680: GAME AI MOVEMENT

What is a Rigid Body?

NVIDIA. Interacting with Particle Simulation in Maya using CUDA & Maximus. Wil Braithwaite NVIDIA Applied Engineering Digital Film

CS179 GPU Programming Recitation 4: CUDA Particles

Lecture 30 of 41. Animation 3 of 3: Inverse Kinematics Control & Ragdoll Physics

Lecture 30 of 41. Animation 3 of 3: Inverse Kinematics Control & Ragdoll Physics

DM842 Computer Game Programming: AI. Lecture 3. Movement Behaviors. Marco Chiarandini

Youngho Kim CIS665: GPU Programming

Where are we? Setup Sprites. Input. Collision Drawing Sprites. Initializing, loading, movement Parameters (color, alpha, scale, etc.

CS 354R: Computer Game Technology

Particle systems, collision detection, and ray tracing. Computer Graphics CSE 167 Lecture 17

Real-time Crowd Movement On Large Scale Terrains

About Phoenix FD PLUGIN FOR 3DS MAX AND MAYA. SIMULATING AND RENDERING BOTH LIQUIDS AND FIRE/SMOKE. USED IN MOVIES, GAMES AND COMMERCIALS.

Replicating Chaos Vehicle Replication in Watch Dogs 2. Matt Delbosc Team Lead Programmer Ubisoft Toronto

CUDA Particles. Simon Green

Algorithms. Algorithms GEOMETRIC APPLICATIONS OF BSTS. 1d range search line segment intersection kd trees interval search trees rectangle intersection

Algorithms. Algorithms GEOMETRIC APPLICATIONS OF BSTS. 1d range search line segment intersection kd trees interval search trees rectangle intersection

Unity Scripting 4. CS 491 / DES 400 Crea.ve Coding. Computer Science

Transcription:

CS 354 R Game Technology Particles and Flocking Behavior Fall 2017

Particle Effects 2

General Particle Systems Objects are considered point masses with orientation Simple rules control how the particles move Particles can be controlled/rendered to simulate different things: Fireworks Waterfalls, spray, foam Explosions (smoke, flame, chunks of debris) Clouds Crowds, herds Widely used in movies as well as games 3

Particle System Exercise 1. Consider one of these particle systems: Fireworks Waterfalls, spray, foam Explosions (smoke, flame, chunks of debris) Clouds Crowds, herds 2. Write high-level pseudocode explaining what needs to be done in what order to make it look correct 4

Particle System Step by Step 1. Inject new particles into the system and assign individual attributes There may be one or more sources Particles might be generated at random (clouds), in a constant stream (waterfall), or via a script (fireworks) 2. Remove any particles that have exceeded their lifetime May have a fixed lifetime, or die on some condition 3. Move all the current particles according to their script Script typically involves neighboring particles and environment 4. Render all the current particles Many options for rendering (shaders, textures etc) 5

Example: Rocket Smoke Trails Particles are spawned at a constant rate They have zero initial velocity, or maybe a small velocity going away from the rocket Rules: Particles can rise or fall (drift with the wind) Attach a density that grows quickly then falls over time Extinguish when density becomes small Render with billboard facing the viewer, scaled according to the density of the puff 6

Smoke Trails Time Extinguished New 7

Example: Object Fracturing System starts when the target is hit Target is broken into pieces and a particle is assigned to each piece Each particle gets an initial velocity away from the center of the explosion Particle rules: Move ballistically unless there is a collision Computer rigid body rotation or generate random rotation Resolve collisions by reflecting the velocity about the contact normal Rendering draws the appropriate piece of target at the particle s location 8

Object Fracturing Laurent Renaud (http://cgcookie.com/max/2009/08/18/creating-an-exploding-planet/) 9

Particles in Games They re everywhere! <https://www.youtube.com/watch?v=6_nsaytooqa> 10

Flocking Behavior Particles can also model flocks, swarms, crowds etc (https://portraitsofwildflowers.wordpress.com/2011/12/10/grackles-revisited/) 11

Flocking Models (Reynolds 87) Potential fields are most often used in avoiding collisions between the members of a group Member pushes on its neighbors to keep from colliding Additional rules for groups can be defined (result is flocking, herding, schooling, etc) Each rule contributes a desired direction, which are combined in some way to come up with the acceleration The aim is to obtain emergent behavior: Define simple rules on individuals that interact to give interesting global behavior e.g individual birds form a flock, but we never explicitly specify a leader, or shape, or speed 12

Flocking Rules Illustrated Separation: fly away away from neighbors that are too close Alignment: steer toward average velocity Cohesion: steer toward average position Avoidance: steer away from obstacles 13

Flocking Rules Explanation Separation: Try to avoid running into local flock-mates Works just like potential fields Normally, use a perception volume to limit visible flockmates Alignment: Try to fly in same direction as local flock-mates Gets everyone flying in the same direction Cohesion: Try to move toward the average position of local flock-mates Spaces everyone out evenly, and keep boundary members toward the group Avoidance: Try to avoid obstacles Just like potential fields! 14

Combining Commands Consider commands as accelerations Give a weight to each desire e.g. high for avoidance, low for cohesion Option 1: Apply in order of highest weight, until a max acceleration is reached Ensures that high priority things happen Option 2: Take weighted sum and truncate acceleration Makes sure some part of everything happens 15

Flocking Demo https://www.youtube.com/watch?v=rn8dzlgmt3m 16

Flocking Evaluation Advantages: Complex behavior from simple rules Many types of behavior can be expressed with different rules and parameters Disadvantages: Can be difficult to set parameters to achieve desired result All the problems of potential fields regarding strength of forces 17

Further Reading Flocks, Herds, and Schools: a Distributed Behavioral Model (http://www.cs.toronto.edu/~dt/siggraph97-course/cwr87/) Particles in Ogre (http://www.ogre3d.org/tikiwiki/-particle) 18