overview of Physics Engine
作者: 刘鹏
日期: 2009-02-21
本文介绍了物理引擎的概念、分类,分析了不同种类的物理引擎的技术特色,并给出了一个开源物理引擎项目列表。
What is Physics Engine
Category of Physics Engine
- Rigid Body Physics Engine
- Physical Physics Engine
Rigid Body Physics Engine
Features
- A traditional physics engine.
- A object is treated as one discrete entity simulated using Newtonian mechanics.
- The laws of torque and inertia are hard-coded into the engine, and the object's movement is determined using formulas derived from them.
Disadvantage
- Limit the number of ways objects can be interacted with.Objects can only be moved around. They cannot be broken in two, crushed, stretched, or split.
- Unable to simulate environments with complex or high numbers of interaction : water flowing over a mill wheel or flame eating at a building.
Physical physics engine
Features
- Based upon the work of Italian computer scientist Giovanni Tummarello.Tummarello's approch is an extension of what is known as a mass-spring system.
- The principle of mass-spring system.
- Physical objects like a box are not whole entities of themselves, but formed out of many smaller particles, refered as atoms.
- In a object, these atoms are connected to each other, usually in a lattice structure, by links.
- These links are essentially springs, and their behavior is governed by Hooke's law (the force applied by a spring is equal to the spring's elongation times some spring constant).
- Tummarello extended this paradigm in two ways
- Included an atom-based repulsion system that make every atom repel every other atom, simulating collisions;
- Added the ability for links to break when extended beyond a brek point.
Advantage
Can simulate just about anything you can throw at it. It can handle objects that bounce, roll, stretch, break, get sliced, get crushed,and everything in between,even simulating fluids with ease.
Disadvantage
It is not very good at large, rigid objects, which were the easiest thing to simulate with rigid body physics.
Open Physics Engine Project Reference
- Box2D 一个 2D 物理引擎
- bullet 一个 3D 物理引擎
- Chipmunk 一个 small 2D 物理引擎
- Open Dynamics engine an open source, high performance library for simulating rigid body dynamics.
- Havok