콘텐츠로 이동

애니메이션과 값

This content is for v0.4. Switch to the latest version for up-to-date documentation.

이 페이지는 문서 버전에 해당하는 project.v1.schema.json에서 자동 생성되며, 필드 설명은 원문(영어) 그대로입니다. 스키마는 형태만 검사합니다. 범위, 한도, 참조, 키프레임 순서는 엔진 검증 단계에서 검사합니다.

AnimatedPoint

A position that can move along curves between its keyframes.

Its JSON is that of an Animated<Vec2>, plus optional spatial tangents on each keyframe: with them, the value travels along the cubic Bezier from one keyframe's value through its out_tangent and the next keyframe's in_tangent, at the speed its timing curve sets along the curve's length. Without them it moves in a straight line, as an Animated<Vec2> does.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredVec2

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredPointKeyframe[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_EffectValue

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredEffectValue

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_EffectValue[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_Insets

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredInsets

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_Insets[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_LayoutLength

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredLayoutLength

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_LayoutLength[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_LayoutOffset

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredLayoutOffset

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_LayoutOffset[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_LayoutSize

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredLayoutSize

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_LayoutSize[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_Paint

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredPaint

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_Paint[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_Path

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredPath

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_Path[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_Vec2

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredVec2

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_Vec2[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_float

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequirednumber (float)

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_float[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Animated_string

A value that is either constant or controlled by sorted keyframes.

One of:

mode: "constant"

A value without animation.

FieldTypeDescription
valuerequiredstring

Value used at every timestamp.

mode: "keyframes"

Values evaluated from their keyframe sequence.

FieldTypeDescription
keyframesrequiredKeyframe_string[]

Strictly ascending keyframes. The evaluator clamps outside the sequence.

Easing

A timing curve from linear progress to eased progress, without a hold.

Transitions use it directly; keyframe Interpolation adds hold.

One of:

type: "linear"

Progress advances at a constant rate.

type: "cubic_bezier"

Progress follows a CSS cubic-bezier() curve.

FieldTypeDescription
x1requirednumber (float)

Horizontal coordinate of the first control point, in 0..=1.

x2requirednumber (float)

Horizontal coordinate of the second control point, in 0..=1.

y1requirednumber (float)

Vertical coordinate of the first control point.

y2requirednumber (float)

Vertical coordinate of the second control point.

Interpolation

Interpolation from one keyframe to the next.

Values are interpolated numerically: a rotation from 0 to 720 degrees turns twice, and one from 0 to 360 turns once. A host that wants the shortest path normalizes its keyframe values.

One of:

type: "hold"

Keep this keyframe's value until the next keyframe.

type: "linear"

Move to the next value at a constant rate.

type: "cubic_bezier"

Move to the next value along a CSS cubic-bezier() timing curve.

FieldTypeDescription
x1requirednumber (float)

Horizontal coordinate of the first control point, in 0..=1.

x2requirednumber (float)

Horizontal coordinate of the second control point, in 0..=1.

y1requirednumber (float)

Vertical coordinate of the first control point.

y2requirednumber (float)

Vertical coordinate of the second control point.

Keyframe_EffectValue

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredEffectValue

Value at time.

Keyframe_Insets

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredInsets

Value at time.

Keyframe_LayoutLength

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredLayoutLength

Value at time.

Keyframe_LayoutOffset

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredLayoutOffset

Value at time.

Keyframe_LayoutSize

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredLayoutSize

Value at time.

Keyframe_Paint

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredPaint

Value at time.

Keyframe_Path

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredPath

Value at time.

Keyframe_Vec2

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredVec2

Value at time.

Keyframe_float

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequirednumber (float)

Value at time.

Keyframe_string

One timestamped control value.

FieldTypeDescription
interpolationrequiredInterpolation

Interpolation from this keyframe to its successor.

timerequiredMediaTime

Timestamp of this value: timeline time, except in a composition node's settings, which are keyed in composition time, and in a shapes or layout generator's tree, which is keyed in its picture's time.

valuerequiredstring

Value at time.

PointKeyframe

One keyframe of an AnimatedPoint.

FieldTypeDescription
in_tangentVec2

The end of the way here from the previous keyframe's value, relative to this value: that curve's second control point.

interpolationrequiredInterpolation

Interpolation from this keyframe to its successor: how fast the value travels along the way there.

out_tangentVec2

The start of the way to the next keyframe's value, relative to this value: the curve's first control point.

timerequiredMediaTime

Timestamp of this value, as a Keyframe's.

valuerequiredVec2

Value at time.

Rgb

An opaque color as a color picker shows it: straight, sRGB-encoded components in the inclusive unit interval.

FieldTypeDescription
bluerequirednumber (float)

Blue component.

greenrequirednumber (float)

Green component.

redrequirednumber (float)

Red component.

Rgba

A straight (not premultiplied), sRGB-encoded color with alpha, each component in 0..=1.

Written as the object, or as CSS hex: "#rgb", "#rgba", "#rrggbb" or "#rrggbbaa", any case, each digit pair a component times 255. It is written back as the object: a component need not be a multiple of 1/255.

One of:

object

FieldTypeDescription
alpharequirednumber (float)

Coverage.

bluerequirednumber (float)

Blue component.

greenrequirednumber (float)

Green component.

redrequirednumber (float)

Red component.

string

Vec2

A two-dimensional value in normalized output coordinates.

FieldTypeDescription
xrequirednumber (float)

Horizontal component.

yrequirednumber (float)

Vertical component.