August 14-15, 2006 - PowerPoint PPT Presentation

slide1 n.
Skip this Video
Loading SlideShow in 5 Seconds..
August 14-15, 2006 PowerPoint Presentation
August 14-15, 2006

play fullscreen
1 / 42
Download
Download Presentation

August 14-15, 2006

Presentation Transcript

  1. “WALK IN” SLIDE August 14-15, 2006

  2. Overview of PhysX Overview of NVidia PhysX Bob Schade Former Developer Support Engineer for Ageia Technologies (which was bought by NVidia)

  3. Types of PhysX Objects – Slide 1 Types of PhysX ObjectsBasically 3 Types of Objects you can Build with the PhysX SDK • Physical Objects in Different States of Matter • Query Objects • Player / AI Objects (Special Gameplay Objects)

  4. I. Physical Objects – Slide 2 I. Physical Objects (in Different States of Matter) • Objects that represent physical objects in the scene. • Things you think of as regular, everyday objects. • Solids • Liquids • Gases

  5. I-1. Solids – Slide 3 I-1. Solids • Objects in Solid State of Matter • Static Objects • Kinematic Objects • Rigid Bodies (Non-Deformable Solids) • Rigid Bodies connected by Joints • Debris (Special Effects Rigid Bodies) • Soft Bodies (Deformable Solids)

  6. I-1A. Static Objects – Slide 4 I-1A. Static Objects • Stationary objects that are unaffected by forces. Pretty much anything generated by BSP or static geometry (see Unreal 3 Editor). • Collision objects / geometry. Defines the boundaries of the player’s movement. Physical Manifestation • Triangle mesh • Polygon mesh Examples • Floor • Walls • Stairs Frequency: Very common

  7. I-1B. Kinematic Objects – Slide 5 I-1B. Kinematic Objects • Essentially static objects until they start moving, at which point they push all dynamic objects out of the way. Usually move according to a preset animation. Physical Manifestation • Box • Sphere • Capsule • Convex mesh Examples • Moving platforms • Elevators • Giant doors that block entry to another area until the player finds a way to open them Frequency: Common

  8. I-1C. Rigid Bodies – Slide 6 I-1C. Rigid Bodies (Non-Deformable Solids) • Dynamic objects that fall under gravity and can be pushed around. Sometimes can be picked up and moved around or thrown. Physical Manifestation • Box • Sphere • Capsule • Convex mesh Examples • Boxes • Crates Frequency: Common

  9. I-1D. Joints – Slide 7 I-1D. Joints • Rigid Bodies connected by Joints Physical Manifestation • Rigid body objects jointed together at a point Examples • Swinging doors • Jointed ropes • Ragdolls Frequency: Somewhat common

  10. I-1D. Joints (cont.) – Slide 8 I-1D. Joints (cont.) • Special Note: “Physically-Driven Animation” Physically-Driven Animation • Joints can apply forces or torques to rigid bodies they connect together, allowing for physically-driven animation (See Example #3: “Natural Motion”) Found in • “Grand Theft Auto IV” • “Backbreaker” Frequency: Rare

  11. I-1E. Debris – Slide 9 I-1E. Debris / Special Effects Rigid Bodies • Dynamic objects that fall under gravity and can be pushed around. Normal rigid bodies are unaffected by them, they always push them out of the way. Physical Manifestation • Particles (point sprites) • Boxes, spheres, capsules • Convex meshes Examples • Sparks • Clutter • Debris from an explosion • Shattered glass Frequency: Somewhat common

  12. I-1F. Soft Bodies – Slide 10 I-1F. Soft Bodies (Deformable Solids) • Bendable, foldable objects built using meshes of point masses connected by springs. Physical Manifestation • Triangle mesh • Polygon mesh Examples • Cloth • Flags • Tarps • Bendable, squishy objects Frequency: Somewhat common

  13. I-2. Liquids – Slide 11 I-2. Liquids • Objects in Liquid State of Matter • Fluids

  14. I-2A. Fluids – Slide 12 I-2A. Fluids • Collections of particles that cohere to each other and fall under gravity. They will expand to fill the bottom of their container. Physical Manifestation • Particles (point sprites) • Fluids surfaces (triangle mesh) Examples • Blood • Oil • Pools of water Frequency: Rare

  15. I-3. Gases – Slide 13 I-3. Gases • Objects in Gaseous State of Matter • Fluids can be used to simulate Gases if they are weightless and only slightly cohesive.

  16. I-3A. Fluids to Simulate Gases – Slide 14 I-3A. Fluids to Simulate Gases • Collections of weightless particles that cohere to each other slightly. They will expand to fill their container. Often implemented just using simple particle systems. Physical Manifestation • Particles (point sprites) • Fluids surfaces (triangle mesh) Examples • Smoke • Fog • Fire Frequency: Somewhat common

  17. II. Query Objects – Slide 15 II. Query Objects • Non-Physical Objects used to make queries to the scene. • Raycasts • Volume Intersection Tests • Contacts

  18. II-1. Raycasts – Slide 16 II-1. Raycasts • Used to determine line of sight. • Answers the question: “Is Point B visible from Point A?” • Also: “What is the first object hit by the line segment AB and where is it hit?” Physical Manifestation • Line segment (AB) Examples • Line of sight test • Light ray Frequency: Very common

  19. II-2. Volume Intersection Tests – Slide 17 II-2. Volume Intersection Tests • Used to determine what objects are in a particular region of space. • Answers the question: “What objects intersect this geometric region?” • Geometric queries • Triggers • Forcefields

  20. II-2A. Geometric Queries – Slide 18 II-2A. Geometric Queries • Used to scan for objects in a particular geometric region, e.g., in front of or near the player or AI (See Example #5: “Obstacle Avoidance for AI”). Physical Manifestation • Box, sphere, capsule • Convex mesh Examples • AI obstacle detection box Frequency: Very common

  21. II-2B. Triggers – Slide 19 II-2B. Triggers • Used to determine when the player has entered a particular location, setting off an event like a trap or spawning enemies or starting a cutscene animation. • Used to signal the player has reached a checkpoint in the level or the end of the level. Physical Manifestation • Box, sphere, capsule • Convex mesh Examples • Trigger to spawn enemies Frequency: Very common

  22. II-2C. Forcefields – Slide 20 II-2C. Forcefields • Geometric volume where you apply a force to objects intersecting the volume. • Used to simulate buoyancy, wind, currents, magnetic fields. Physical Manifestation • Box, sphere, capsule • Convex mesh Examples • Wind tunnel • Tornado • Water currents • Force from explosion Frequency: Somewhat common

  23. II-3. Contacts – Slide 21 II-3. Contacts • Used to determine at what point one object is touching another object and with what force. • Answers the question: “At what point(s) is one object in contact with another object?” Physical Manifestation • Point of contact • Contact normal Examples • Sparks flying on contact • Splashes from rocks hitting pond • Objects denting each other • Sound created from impact Frequency: Common

  24. III. Player / AI Objects – Slide 22 III. Player / AI Objects • Objects that represent the Player or AI moving through the scene (a.k.a., avatar objects, special contact/force objects, special gameplay objects). • Used when you want lots of precise, specific control over the interaction of the object with the scene, physical environment. Used when the Player or AI provides precise, specific input to control the object, move the object around. • Character Controllers • Vehicles

  25. III-1. Character Controllers – Slide 23 III-1. Character Controllers • Physical object used to represent the player or AI as a character. Special Physical Properties Capsule glides effortlessly along floor and walls, capsule hops up objects under a certain height (climbs stairs), capsule glides up inclines until incline reaches certain angle, capsule glides down certain inclines until angle is too steep and it slides uncontrollable, capsule can jump to a certain height. Special example is “Mirror’s Edge” where the capsule is rigged with logic to do parkour moves. (See Example #1: “Mirror’s Edge”) Physical Manifestation • Capsule • Cylinder • Rectangular solid Examples • Most player characters are implemented this way Frequency: Very common

  26. III-1. “Better Know your AI” – Slide 24 III-1. “Better Know your AI” • Make your Player / AI character controllers interchangeable, i.e., playable by either the Player or the AI. This means that at any point in the game you can take over an AI character and start playing the game as an AI. Really good example: “Left 4 Dead 2”. Demonstrates player / AI interchangeability. I like this game because the AI character is capable of doing the same thing the player character is capable of. The player and the AI can operate the same character controller. The character controller is controlled by the player or the AI. The character controller is the same for both. The only difference is who is providing inputs to the character controller, the player or the AI. As an AI programmer I love this because it allows you to see the game through the eyes of the AI. When you can do this, you start to see all kinds of behaviours you might want to implement for your AI, because they’re behaviours you can actually try out yourself as a player. I highly recommend implementing your character controller this way: have a character controller that either the player or AI can take control of.

  27. III-2. Vehicles – Slide 25 III-2. Vehicles • Physical object used to represent the player or AI as a vehicle. • Cars • Motorcycles • Planes • Helicopters • Boats

  28. III-2A. Cars – Slide 26 III-2A. Cars • Car Objects Special Physical Properties Wheel contacts are special force contacts designed to exert different forces on the road depending on brakes, acceleration, road surface, downforce on the tire, etc. Physical Manifestation • Car chassis (convex mesh) • 4 wheel contacts Found in • Racing games • “Grand Theft Auto III” • “Burnout” Frequency: Very common

  29. III-2B. Motorcycles – Slide 27 III-2B. Motorcycles • Motorcycle Objects Special Physical Properties Wheel contacts are special force contacts designed to exert different forces on the road depending on brakes, acceleration, road surface, downforce on the tire, etc. Physical Manifestation • Motorcycle body (convex mesh) • 2 wheel contacts Found in • “Grand Theft Auto III: Vice City” Frequency: Somewhat common

  30. III-2C. Planes – Slide 28 III-2C. Planes • Plane Objects Special Physical Properties The propeller or jet engine provides thrust (force) to accelerate the plane horizontally. Airfoil surfaces provide lift as the plane picks up horizontal speed and also steer the plane (rudder). Physical Manifestation • Plane body (convex mesh) • 2 wheel contacts • Airfoil surfaces (elevators, rudder) • Propeller (jet engine) Found in • Flight simulators Frequency: Common

  31. III-2D. Helicopters – Slide 29 III-2D. Helicopters • Helicopter Objects Special Physical Properties The main rotor provides lift for the helicopter and also forward acceleration as the helicopter angles forward. The tail rotor provides force left or right to turn the helicopter around the main rotor axis. Physical Manifestation • Helicopter body (convex mesh) • 2 skid objects • Main rotor • Tail rotor (stabilizer) Found in • “Battlefield 2” Frequency: Somewhat common

  32. III-2E. Boats – Slide 30 III-2E. Boats • Boat Objects Special Physical Properties Boat displaces a certain amount of water and is buoyed up to a certain point on the water line depending on overall weight and displacement. The rudder steers the boat. The propeller provides force to move the boat forward. Physical Manifestation • Boat hull (convex mesh) • Rudder • Propeller (screws) Found in • “Far Cry 2” • “Grand Theft Auto III: Vice City” Frequency: Somewhat common

  33. Further Information Further Information For further technical information, download the NVidia PhysX SDK (see Example #11: “NVidia PhysX SDK Download”) Install the SDK and look at: C:\Program Files\NVIDIA Corporation\NVIDIA PhysX SDK\v2.8.3\TrainingPrograms …for tutorials on how to use the SDK.

  34. End Slide 1. “Mirror’s Edge”http://www.youtube.com/watch?v=tvhw_v3q4L82. Unreal Engine 3http://udn.epicgames.com/Three/DevelopmentKitProgramming.html3. Natural Motion (physically driven animation SDK and editor)http://www.naturalmotion.com/4. NVidia PhysX Particle Fluid Demo (last demo in the power pack)http://www.nvidia.com/content/graphicsplus/us/download.asp5. Obstacle Avoidance for AIhttp://www.red3d.com/cwr/steer/Obstacle.html © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

  35. End Slide 6. Simul-X (vehicle SDK)http://www.simul-x.com/7. CarX-Tech (vehicle SDK)http://www.carx-tech.com/8. PhysX Destruction Demohttp://www.youtube.com/watch?v=N1FOnpzUzZY9. NVidia PhysX Homepagehttp://www.nvidia.com/object/physx_new.html10. NVidia PhysX Developer Pagehttp://developer.nvidia.com/object/physx.html11. NVidia PhysX SDK Downloadhttp://developer.nvidia.com/object/physx_downloads.html © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

  36. Color Guidelines PowerPoint Guidelines • Font, size, and color for text have been formatted for you in the Slide Master • Use the color palette shown below • See next slide for additional guidelines Sample fillcolor Sample fillcolor Sample fillcolor

  37. End Slide August 14-15, 2006 DirectX Developer Centerhttp://msdn.microsoft.com/directxGame Development MSDN Forumshttp://forums.microsoft.com/msdnXbox 360 Centralhttp://xds.xbox.com/Game Developer Supportgameds@microsoft.comXNA Websitehttp://www.microsoft.com/xna © 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

  38. Information Management Name Title Company

  39. Name Title Company

  40. Name Title Company