Skeleton: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (WIP)
m (WIP)
Line 1: Line 1:
{{wip}}
{{wip}}
{{todo|cleanup & clarify ... WIP}}
<div style="float:right;padding:0 1em;background:#FFF;">__TOC__</div>
 
A model's [[Skeleton]] is sometimes called the model's ''Rig'' or ''Bonetree''. Every model in Source must have a Skeleton, even if it is just a single, invisible "bone". A Model's Skeleton is the reference framework for all of the model's [[vertex geometry]]<!-- 3D coordinates, normals, etc -->, and it is the Skeleton's "rootbone" that locates the model's geometry to the [[Model Entity]]'s position and orientation in the World.
A model's [[Skeleton]] is sometimes called the model's ''Rig'' or ''Bonetree''. Every model in Source must have a Skeleton, even if it is just a single, invisible "bone". A Model's Skeleton is the reference framework for all of the model's [[vertex geometry]]<!-- 3D coordinates, normals, etc -->, and it is the Skeleton's "rootbone" that locates the model's geometry to the [[Model Entity]]'s position and orientation in the World.


A [[Model]]'s Rendered '''[[Skin]]''' is ''[[UV|projected]]'' over the '''[[Mesh]]''' which ''[[enveloped|envelopes]]'' the '''[[Skeleton]]'''.
A [[Model]]'s Rendered '''[[Skin]]''' is ''[[UV|projected]]'' over the '''[[Mesh]]''' which ''[[enveloped|envelopes]]'' the '''[[Skeleton]]'''.


A skeleton must have:
Every Skeleton must have:
* a rootbone.
* a rootbone.


== Skeleton Types ==
== Skeleton Types ==
There is one huge difference between just 2 types of skeleton : [[Rigid]] and [[NotRigid]].
By far ''the most important'' distinction between types of Skeleton is whether they are [[Rigid]] or [[NotRigid]].
=== [[Rigid]] Skeleton===
=== [[Rigid]] Skeleton===
Most models in source have [[Rigid Skeleton]]s, which means they may change position and orientation, but the may not articulate - none of their 'internal'  geometry can change. Happily, a Rigid Skeleton is so simple and easy to configure automatically that it is often overlooked. ....  
Most models in source have [[Rigid Skeleton]]s, which means they may change position and orientation, but the may not articulate - none of their 'internal'  geometry can change. Happily, a Rigid Skeleton is so simple and easy to configure automatically that it is often overlooked. ....  
Line 33: Line 32:
* prop_ragdoll : passive/physics ... [[$collisionjoints]]
* prop_ragdoll : passive/physics ... [[$collisionjoints]]
* prop_dynamic : active/animated ... see [[skeletal animation]]
* prop_dynamic : active/animated ... see [[skeletal animation]]
** machine model
** machine model (wheeled vehicle ?)
** character model (rigid npc: [[npc_rollermine]],...)
** character model (rigid npc: [[npc_rollermine]],...)
** viewmodel
** viewmodel
Line 57: Line 56:
== [[Vertex geometry]] ==
== [[Vertex geometry]] ==
{{todo|probably move this section out to its own page ?}}
{{todo|probably move this section out to its own page ?}}
Origin : Every game entity that can move has an origin. Every game entity that has non-brush geometry has an origin. All brush vertex geometry is related to the map origin = [[worldspawn]] entity. -->
* Vertex Geometry = 3D coordinates (XYZ axes) and sometimes vertex Normal vectors.
** Vertex coordinates are measured on XYZ axes from either the ''WorldOrigin'' or an ''EntityOrigin''.
*** '''WorldOrigin'''= [[worldspawn]] entity's position which is always the map origin (0,0)
*** '''EntityOrigin''' = the WorldPosition of that entity.
*** '''BoneOrigin''' = Studiomodel vertices are [[enveloped]] to one or more [[Bone]]s in the model's [[Skeleton]].
** Vertex Normals are used to imply a [http://en.wikipedia.org/wiki/Surface_normal Surface Normal] as if the vertex is the center of a surface rather than a vertex. This creates a kind of ''pseudo-''[http://en.wikipedia.org/wiki/Subdivision_surface subdivision surface], used by the [[Smoothing group|Smoothing]] (Shader?).
* Origin : Every game entity that can move has an origin. Every game entity that has non-brush geometry has an origin. All brush vertex geometry is related to the map origin = [[worldspawn]] entity.  
 
 
* Studiomodel geometry (vertex $origin = entity WorldPosition & [[angle]]s
* Brush geometry (vertex origin = worldspawn entity)
* non-vertex geometry (entities)
** sphere : eg [[light]] - radius = range/distance
** cone : eg [[light_spot]] - angles = direction, FOV = cone arc, ? = range/distance
*** NPC [[viewcone]]

Revision as of 14:55, 3 May 2008

Under construction.png
This page is actively undergoing a major edit.
As a courtesy, please do not edit this while this message is displayed.
If this page has not been edited for at least several hours to a few days, please remove this template. This message is intended to help reduce edit conflicts; please remove it between editing sessions to allow others to edit the page.

The person who added this notice will be listed in its edit history should you wish to contact them.

A model's Skeleton is sometimes called the model's Rig or Bonetree. Every model in Source must have a Skeleton, even if it is just a single, invisible "bone". A Model's Skeleton is the reference framework for all of the model's vertex geometry, and it is the Skeleton's "rootbone" that locates the model's geometry to the Model Entity's position and orientation in the World.

A Model's Rendered Skin is projected over the Mesh which envelopes the Skeleton.

Every Skeleton must have:

  • a rootbone.

Skeleton Types

By far the most important distinction between types of Skeleton is whether they are Rigid or NotRigid.

Rigid Skeleton

Most models in source have Rigid Skeletons, which means they may change position and orientation, but the may not articulate - none of their 'internal' geometry can change. Happily, a Rigid Skeleton is so simple and easy to configure automatically that it is often overlooked. ....

// eg: a "default" skeleton :
version 1
nodes
  0 "static_prop" -1
end
skeleton
time 0
  0 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
end
triangles
// ...

NotRigid Skeleton

only when the Skeleton has more than one bone can it have a joint to articulate. ...

Bone hierarchy (summary)

Rigging

Vertex geometry

Todo: probably move this section out to its own page ?
  • Vertex Geometry = 3D coordinates (XYZ axes) and sometimes vertex Normal vectors.
    • Vertex coordinates are measured on XYZ axes from either the WorldOrigin or an EntityOrigin.
      • WorldOrigin= worldspawn entity's position which is always the map origin (0,0)
      • EntityOrigin = the WorldPosition of that entity.
      • BoneOrigin = Studiomodel vertices are enveloped to one or more Bones in the model's Skeleton.
    • Vertex Normals are used to imply a Surface Normal as if the vertex is the center of a surface rather than a vertex. This creates a kind of pseudo-subdivision surface, used by the Smoothing (Shader?).
  • Origin : Every game entity that can move has an origin. Every game entity that has non-brush geometry has an origin. All brush vertex geometry is related to the map origin = worldspawn entity.


  • Studiomodel geometry (vertex $origin = entity WorldPosition & angles
  • Brush geometry (vertex origin = worldspawn entity)
  • non-vertex geometry (entities)
    • sphere : eg light - radius = range/distance
    • cone : eg light_spot - angles = direction, FOV = cone arc, ? = range/distance