Physics Thread

A short brain dump:

The physics thread takes care of all the Newtonian physics. Either it...

  • incorporates a physics engine in one form or the other which wraps hardware acceleration...
  • does it in software, in one of the many cores of your CPU.

About the physics engine

As for physics engines, there are many of them out there. For further discussion and to aid the decision process which of them will be our working horse, features and limitations of them are compiled and compared in the Physics Engines Comparison page.

Our requirements need to be listed as well (and most likely in a seperate place, but here is a start). The physics engine needs to support (incomplete): dynamic external boundary conditions (the motion of some objects is defined via a parametrized trajectory, e.g. the ellipses planet motion)

Interface to other parts of the engine

The physics thread handles a physical representation of every object in the game world. There must be a process of matching game models, which are to be rendered, to their corresponing physics model, which are basically a bunch of joint primitives with properties like mass and due to their shape a moment of inertia.
From this arrise a number of questions:

  • How do we handle the matching process during the game, i.e., how do we export position and alignment of objects from the physics world to the graphics world? The interesting part of this is to transform physics coordinate systems into rendering coordinates.
  • Are the physics models to be supplied additionally to graphics models or are they generated?
  • What happens to the graphics model if the physics engine supports breaking of joints and detects that a model is breaking apart?
  • Many physics engine support raycasting which is of essential interest to a good AI, one which is not aware of everything. We need an interface for that as well!
  • How do we coordinate the data transfer beween the physics engine and the part of the engine that creates the procedural landscape? You know, even if we are far away and don’t look a rubber ball bounces of the ground if dropped from some height.
 
deep/thrd/thrd_phys.txt · Last modified: 2006/10/06 20:00 by chuck_starchaser