A ScinTween describes a series of curves by providing pairs of levels, timings, and curves. The curve is provided to the server which will generate a lookup table for use in VGens. ScinTween is similar to the audio Env class but with two notable differences, namely that the Tween curves (see table below) describe curves commonly used in visual animation instead of audio synthesis, and that Tweens cannot trigger done actions.
levels |
An array of single level values or subarrays of 2 or 4 values each, describing the one, two, or four-dimensional values to reach at each point of the tween. |
times |
An array with one less element than |
curves |
A symbol or an array of symbols, the same size as |
sampleRate |
An integer describing the number of points per second to put into the tween table. |
loop |
A boolean which if true will repeat the tween indefinitely. If false samples before 0 and after the total duration of the tween will return the values at 0 and the end of the tween respectively. |
(describe returnvalue here) A new ScinTween object.
The following images are generated as part of the Scintillator server regression tests. They are charts of all the supported tween curves running from level 0 to 1 over a period of 1, making them simple to chart using VTweenSampler1. The red line along the bottom of the image indicates a zero value and the blue line at the top indicates the 1 value. Note that many curves go above and below the extreme of their target level.
\backIn
| \backInOut
| \backOut
|
\bounceIn
| \bounceInOut
| \bounceOut
|
\circularIn
| \circularInOut
| \circularOut
|
\cubicIn
| \cubicInOut
| \cubicOut
|
\elasticIn
| \elasticInOut
| \elasticOut
|
\exponentialIn
| \exponentialInOut
| \exponentialOut
|
\linear
| ||
\quadraticIn
| \quadraticInOut
| \quadraticOut
|
\quarticIn
| \quarticInOut
| \quarticOut
|
\quinticIn
| \quinticInOut
| \quinticOut
|
\sinusoidalIn
| \sinusoidalInOut
| \sinusoidalOut
|