Skeleton
From TrainzOnline
(Difference between revisions)
Revision as of 12:58, 16 October 2017
Animation in Trainz (and most other GPU-based renderers) involves several steps:
1. Creating a mesh, laid out in bind pose. 2. Creating a skeleton for that mesh, comprised of bones arranged in a hierarchy. 3. For each vertex of the mesh, defining which bones influence the vertex and how strong the influence is. 4. Defining animation sequences for the bones.
The mesh file contains the skeleton data (ie. a list of named bones and their parent-child relationships), and the vertex buffers in the mesh contains the per-vertex influence data.
The animation files contain a timeline with positioning data for each bone at various keyframes.