-
Notifications
You must be signed in to change notification settings - Fork 12
The animation language
Each sentence (i.e. instruction) consists of a time interval, an action, corresponding action parameters and optionally of one of the easing keywords for non-linear transitions.
The time interval is given in number of frames, there exist two variants, for either specifying a single time point or a time range:
From frame <begin> to frame <end> …
At frame <time> …
Actions include rotations, translations, zoom and rendering parameter changes.
- Rotations:
… rotate by <angle> degrees horizontally …
… rotate by <angle> degrees vertically …
… rotate by <angle> degrees around (axis_x, axis_y, axis_z)
- Translations:
… translate horizontally by <x> …
… translate vertically by <y> …
… translate by (x, y, z) …
- Zoom:
… zoom by a factor of <r> …
- Change:
- general properties:
… change bounding box min x to <n> …
… change bounding box max x to <n> …
… change bounding box x to (min, max) …
… change bounding box min y to <n> …
… change bounding box max y to <n> …
… change bounding box y to (min, max) …
… change bounding box min z to <n> …
… change bounding box max z to <n> …
… change bounding box z to (min, max) …
… change front clipping to <n> …
… change back clipping to <n> …
… change front/back clipping to <n> …
- channel-specific properties:
… change channel <c> min intensity to <n> …
… change channel <c> max intensity to <n> …
… change channel <c> intensity gamma to <n> …
… change channel <c> intensity to (min, max, gamma) …
… change channel <c> min alpha to <n> …
… change channel <c> max alpha to <n> …
… change channel <c> alpha gamma to <n> …
… change channel <c> alpha to (min, max, gamma) …
… change channel <c> color to (r, g, b) …
… change channel <c> weight to <n> …
… linearly (no acceleration)
… ease-in (slow start, then accelerating)
… ease-out (linear start, then decelerating)
… ease-in-out (slow start and slow end)
… ease (same as ease-in-out, but not as dramatic)
Oftentimes, multiple consecutive instructions share the same start, i.e. when several instructions are active during the same time interval. In that case, the common prefix (the time interval) can be shared between the two instructions, by placing it on an extra line that ends with a colon. Instructions which share this prefix should start with a dash:
From frame 0 to frame 180:
- rotate by 360 degrees horizontally
- change channel 1 weight to 0
In this example, between frames 0 and 180 the object performs a full 360-degree rotation, while during the same time period, the weight of channel 1 continuously decreases to 0.