(Avatar Physics and Genetics)
2. Physics
Having a physical presence in a virtual world is a basic property of being a 3D avatar. It is also a basic
ingredient of the most primitive of computer games. Near the low end of the spectrum is something like Pac Man,
a sprite whose physical proper-ties consist simply of 2D location and orthogonal movement. Moving up through the
history of computer games, we encounter higher-level physical identities, incorporat-ing three dimensions, deeper
physics, articulated bodies, and realistic interactions with environmental factors, such as terrain. There is
almost no end to the levels of detail that can be added to this list, as we project into the future of experiencing
a virtual reality through our virtual selves.
As far as avatars are concerned, there is no one correct physical model: physics is simply a tool to aid in utility
and experience, and there are many levels of physical simulation that can be implemented for different purposes.
Deep physics, such as an intensive forward dynamics simulation, may not be the most appropriate for all situations,
as discovered in early experiments. The solution found was to use a hybrid, pseudo-physics model, with a variety
of motion-controllers. Just as Marvin Minsky suggested that intelligence cannot be characterized with one elegant
algorithm, suit-able for a single AI model, the human body’s ensemble of motions is likewise a col-lection of many
layers and styles of control.
However, if at some low level a Newtonian model is at work, many things will come for free. In this model,
the position and orientation of the (standing/walking) avatar are determined by a forward dynamics model, as
illustrated in Figure 1:
Figure 1. Forces affecting standing/walking avatar
Two forces act upon the avatar body to affect its linear velocity and angular velocity: 1) the knee force,
and 2) the gyroscope. The knee force acts upon the vertical component of the avatar’s velocity. Essen-tially,
if the vertical distance from the ground to the avatar’s position is less than the avatar’s leg length, then
a force is added to the avatar’s vertical velocity, pushing it upward. There is also a friction constant which
dampens the vertical velocity. The effect is much like the force the knees have on the body in order to keep it
above the ground. When you jump out of a tree and land on your feet, there is some give, and you spring back into
the standing position. The gyroscope is a force which acts upon the angular velocity of the avatar by applying
rotational forces which keep the upper body in an approximate upright orientation.
These two forces affect the position and orientation of the avatar’s body. Using this representation, the
avatar can be affected by gravity, always being kept approxi-mately leg-length above the ground, experiencing
(soft) collisions with the ground, and correcting itself from angular perturbation, as indicated in Figure 2.
Figure 2. Avatar interacting with terrain
When an avatar is weakened, the knee and gyroscope forces decrease, thus the ava-tar’s knees bend more
and the body has less energy to stay upright. A dead avatar has zero knee-spring and gyroscope forces - it is
essentially a passive Newtonian object, no longer exerting any life-force.
A few of the ways in which the positions and orientations of the individual bones are updated, in relation
to the above-mentioned physics, are described below.
2.1 Walking
Avatar locomotion is controlled by a computer mouse and/or keyboard, used to spec-ify two forces: forward,
and turning. Forward control adds forces to the avatar's lin-ear velocity along the avatar's forward axis.
Turning control adds forces to the ava-tar's angular velocity about the avatar's up axis. As secondary forces,
small amounts of pitching and rolling are caused by forward and turning forces, respectively (for effect,
not necessarily for realism). When the avatar is on the ground (i.e., the vertical distance between the pelvis
and the ground is less than or equal to leg length), and the avatar’s horizontal speed is larger than a small
threshold, the avatar is set to "walking mode", and is then animated by way of a walking system. The walking
system has three components:
1. Foot Step Animator
The foot step animator directly moves two ideal heel positions through space, corre-sponding to
the positions the heel would be in if the avatar were walking. The dis-tance of each forward step
and the period of the stepping cycle are determined by the horizontal speed and the lengths of the legs.
2. Inverse-Kinematic Leg-Bender
The inverse-kinematic leg bender sets the orientations of the thighs, shins, and feet, so that the heel
is placed as close as possible to the ideal position as determined above.
3. Periodic Body Part Oscillator
The periodic body part oscillator transforms non-leg body parts according to periodic waves whose
frequencies are determined by the step cycle, and whose amplitudes are determined by the horizontal speed.
Various parts of the body are oscillated to create distinct walking styles. These parts include the neck,
the hips, the shoulders, the arms, and many others. About a dozen parameters for these body part oscillations
are controlled by genes, and they are responsible for a large variety of gaits.
2.2 Animal Physics and Topology
A technique used for non-human physics is similar in principle to that of the avatar,
except that the number of point masses, springs, types of springs, and topology may vary.
As an example, a small mammal’s body may be represented as two main point masses (pelvis and chest)
connected by a high-friction spring, and supported above the ground by two vertical knee forces,
similar to the one used for the avatar, as illustrated in Figure 3.
Figure 3. Four-legged mammal physics
The head and neck complex may be built either with springs or with rigid body dy-namics.
In either case, each "body sphere" possesses a position, a radius, and a com-plete orientation
matrix defined in the world coordinate system.
While Newtonian physics are affecting the point masses in fairly realistic ways, the animal imparts
intentional forces on these parts as well. These can come in a great variety, depending on the animal
and depending on the mental state of the animal.
2.3 Interacting with the World
I will not go into much detail on the topic of how avatars interact with objects in the world other
than the ground. The avatar, for most purposes, is defined physically as a point mass with position and
velocity, and also having a radius, orientation, and rotational velocity. Thus it is also possible to detect
simple collisions with other ob-jects and to apply forces to the avatar and/or the other objects
appropriately. Higher detailed collisions with objects can be calculated on individual body spheres
(occurring at the joints of the skeleton), each of which possess a position, radius, and im-plied
velocity. Higher-detailed collisions (i.e., on arbitrarily-shaped body part volumes), while important
for intimate interactions, are beyond the scope of this explo-ration.
One basic example of interacting with objects in the world is an inverse-kinematic arm controller,
which handles placement of the hands on certain objects, and calcu-lates appropriate arm orientations.
This is similar to the inverse-kinematic leg-bender of the walking system described above.
(go to beginning of document)