The Physics Abstraction Layer (PAL) is an
open-source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
cross-platform
In computing, cross-platform software (also called multi-platform software, platform-agnostic software, or platform-independent software) is computer software that is designed to work in several computing platforms. Some cross-platform software ...
physical simulation
Dynamical simulation, in computational physics, is the simulation of systems of objects that are free to move, usually in three dimensions according to Newton's laws of dynamics, or approximations thereof. Dynamical simulation is used in computer ...
API
An application programming interface (API) is a way for two or more computer programs to communicate with each other. It is a type of software interface, offering a service to other pieces of software. A document or standard that describes how ...
abstraction system. It is similar to a
physics engine
A physics engine is computer software that provides an approximate simulation of certain physical systems, such as rigid body dynamics (including collision detection), soft body dynamics, and fluid dynamics, of use in the domains of computer ...
wrapper, however it is far more flexible providing extended abilities. PAL is free software, released under the BSD license.
PAL is a high-level interface for low-level physics engines used in games, simulation systems, and other 3D applications. It supports a number of
dynamic simulation
Dynamic simulation (or dynamic system simulation) is the use of a computer program to model the time-varying behavior of a dynamical system. The systems are typically described by ordinary differential equations or partial differential equations. ...
methodologies, including
rigid body
In physics, a rigid body (also known as a rigid object) is a solid body in which deformation is zero or so small it can be neglected. The distance between any two given points on a rigid body remains constant in time regardless of external fo ...
,
liquids
A liquid is a nearly incompressible fluid that conforms to the shape of its container but retains a (nearly) constant volume independent of pressure. As such, it is one of the four fundamental states of matter (the others being solid, gas, ...
,
soft body,
ragdoll
The Ragdoll is a breed of cat with a distinct colorpoint coat and blue eyes. Its morphology is large and weighty, and it has a semi-long and silky soft coat. American breeder Ann Baker developed Ragdolls in the 1960s. They are best known for the ...
, and
vehicle dynamics
For motorized vehicles, such as automobiles, aircraft, and watercraft, vehicle dynamics is the study of vehicle motion, e.g., how a vehicle's forward movement changes in response to driver inputs, propulsion system outputs, ambient conditions, air ...
. PAL features a simple
C++ API
An application programming interface (API) is a way for two or more computer programs to communicate with each other. It is a type of software interface, offering a service to other pieces of software. A document or standard that describes how ...
and intuitive objects (e.g.
Solids
Solid is one of the four fundamental states of matter (the others being liquid, gas, and plasma). The molecules in a solid are closely packed together and contain the least amount of kinetic energy. A solid is characterized by structura ...
,
Joints
A joint or articulation (or articular surface) is the connection made between bones, ossicles, or other hard structures in the body which link an animal's skeletal system into a functional whole.Saladin, Ken. Anatomy & Physiology. 7th ed. McGraw- ...
,
Actuator
An actuator is a component of a machine that is responsible for moving and controlling a mechanism or system, for example by opening a valve. In simple terms, it is a "mover".
An actuator requires a control device (controlled by control signal) a ...
s,
Sensors, and
Materials
Material is a substance or mixture of substances that constitutes an object. Materials can be pure or impure, living or non-living matter. Materials can be classified on the basis of their physical and chemical properties, or on their geologica ...
). It also features
COLLADA
COLLADA (for ''COLLA''borative ''D''esign ''A''ctivity) is an interchange file format for interactive 3D applications. It is managed by the nonprofit technology consortium, the Khronos Group, and has been adopted by ISO as a publicly available ...
,
Scythe Physics Editor {{Infobox software
, name = Scythe Physics Editor
, title =
, logo =
, logo caption =
, logo_size =
, logo_alt =
, screenshot =
, cap ...
, and
XML
Extensible Markup Language (XML) is a markup language and file format for storing, transmitting, and reconstructing arbitrary data. It defines a set of rules for encoding documents in a format that is both human-readable and machine-readable. ...
-based file storage.
The Physics Abstraction Layer provides a number of benefits over directly using a physics engine:
* Flexibility – It allows developers to switch between different
physics engines to see which engine provides their needs, as well as quickly testing a new engine.
*
Portable
Portable may refer to:
General
* Portable building, a manufactured structure that is built off site and moved in upon completion of site and utility work
* Portable classroom, a temporary building installed on the grounds of a school to provide a ...
– Developers are able to use the physics engine which provides the best performance for different platforms, and are able to write platform independent code.
* Security – If a
middleware
Middleware is a type of computer software that provides services to software applications beyond those available from the operating system. It can be described as "software glue".
Middleware makes it easier for software developers to implement c ...
provider is acquired by another company or development is discontinued, developers can switch engines.
*
Scalable
Scalability is the property of a system to handle a growing amount of work by adding resources to the system.
In an economic context, a scalable business model implies that a company can increase sales given increased resources. For example, a ...
– The abstraction layer allows developers to run their code on handheld
console
Console may refer to:
Computing and video games
* System console, a physical device to operate a computer
** Virtual console, a user interface for multiple computer consoles on one device
** Command-line interface, a method of interacting with ...
platforms up to supercomputers.
* Ease of use – Implementation details of the physics engine are abstracted, providing a cleaner interface to the developer.
*
Benchmarking – Researchers can directly compare the performance of various
dynamic simulations systems.
PAL is designed with a
pluggable abstract factory allowing code to be written and compiled once and allowing runtime selection of different
physics engine
A physics engine is computer software that provides an approximate simulation of certain physical systems, such as rigid body dynamics (including collision detection), soft body dynamics, and fluid dynamics, of use in the domains of computer ...
s, as well as feature upgrades.
Supported engines
PAL supports multiple
physics engine
A physics engine is computer software that provides an approximate simulation of certain physical systems, such as rigid body dynamics (including collision detection), soft body dynamics, and fluid dynamics, of use in the domains of computer ...
s, including:
*
Box2D
Box2D is a free open source 2-dimensional physics simulator engine written in C++ by Erin Catto and published under the MIT license. It has been used in '' Crayon Physics Deluxe'', ''Limbo'', ''Rolando'', '' Incredibots'', ''Angry Birds'', '' ...
*
Bullet
A bullet is a kinetic projectile, a component of firearm ammunition that is shot from a gun barrel. Bullets are made of a variety of materials, such as copper, lead, steel, polymer, rubber and even wax. Bullets are made in various shapes and ...
*
Newton Game Dynamics
Newton Game Dynamics is an open-source physics engine for realistically simulating rigid bodies in games and other real-time applications. Its solver is deterministic and not based on traditional LCP or iterative methods.
Newton Game Dynamic ...
*
Open Dynamics Engine
The Open Dynamics Engine (ODE) is a physics engine written in C/C++. Its two main components are a rigid body dynamics simulation engine and a collision detection engine. It is free software licensed both under the BSD license and the LGPL ...
*
PhysX
PhysX is an open-source realtime physics engine middleware SDK developed by Nvidia as a part of Nvidia GameWorks software suite.
Initially, video games supporting PhysX were meant to be accelerated by PhysX PPU ( expansion cards designed by ...
(formerly NovodeX and incorporating
Meqon)
*
Tokamak physics engine
The Tokamak Game Physics SDK is an open-source physics engine.
At its beginnings, Tokamak was free for non commercial uses only. Since May 2007, it has become open sourced under a BSD License. Now it can be used under BSD or Zlib license, in ...
Supported file formats
PAL supports multiple file formats, including:
*
COLLADA
COLLADA (for ''COLLA''borative ''D''esign ''A''ctivity) is an interchange file format for interactive 3D applications. It is managed by the nonprofit technology consortium, the Khronos Group, and has been adopted by ISO as a publicly available ...
*
Scythe Physics Editor {{Infobox software
, name = Scythe Physics Editor
, title =
, logo =
, logo caption =
, logo_size =
, logo_alt =
, screenshot =
, cap ...
file format
*
XML
Extensible Markup Language (XML) is a markup language and file format for storing, transmitting, and reconstructing arbitrary data. It defines a set of rules for encoding documents in a format that is both human-readable and machine-readable. ...
Benchmark
The PAL project provides a set of standard benchmarks allowing developers to directly compare the physics engines and select the engine that provides the best solution in terms of computational efficiency and physical accuracy. Care should be taken when deciding on which engine to actually use though, since engines may be tweaked in ways which PAL doesn't support.
References
External links
*
Interactive PAL benchmark
{{Physics engines
Computer physics engines