Blends one sample at position t. sorted are the keys (by t ascending), temp_colors the result of make_colors for the same keys and space, and i0 the index of the last key at or before t; use -1 for a t before the first key when wrapping. Returns the red, green, blue, alpha color, encoded again. With a single key that key's color is returned. Asserts when there are no keys or the two arrays differ in length.
Keys at the same position make a step; outside the keys the nearest key's color holds, with the blend factor clamped to [0, 1].
interpolate_one_sample :: (
i0: int,
t: float,
interp: Interpolation,
sorted: [] *$T/Color_Keyframe,
temp_colors: [] Vector3
) -> rgba: Vector4
Parameters
- i0: int
- t: float
- interp: Interpolation
- sorted: [] *$T/Color_Keyframe
- temp_colors: [] Vector3
Returns
- rgba: Vector4