From ee198b516bad5db9312dde3749bf864d6c7079b1 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Wed, 19 Feb 2025 22:21:44 +0100 Subject: animations --- doc/resources.md | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) (limited to 'doc/resources.md') diff --git a/doc/resources.md b/doc/resources.md index a7683e3..761a6fa 100644 --- a/doc/resources.md +++ b/doc/resources.md @@ -180,29 +180,25 @@ inherited. Attribute values are zipped similar to vertex attributes. | Key | Value Type | | | ---------- | ------------------ | --------- | +| `name` | `String` | | | `channel` | `AnimationChannel` | Multi key | | `duration` | `f32` | | ## AnimationChannel -| Key | Value Type | | -| --------------------- | ------------- | - | -| `t_mesh_translation` | `u32` | | -| `t_mesh_rotation` | `u32` | | -| `t_mesh_scale` | `u32` | | -| `t_mesh_morph_weight` | `u32`, `u32` | | -| `t_joint_translation` | `u32`, `u32` | | -| `t_joint_rotation` | `u32`, `u32` | | -| `t_joint_scale` | `u32`, `u32` | | -| `t_light_translation` | `u32` | | -| `time` | `Res<[f32]>` | | -| `value` | `Res<[Vec3]>` | | - -- **Joint targets**: Index into armature array of the prefab and index into - joint array of that armature. -- **Mesh targets**: Index into mesh array of the prefab. -- **Mesh morph targets**: Index into mesh array of the prefab and index into - morph targets array of that mesh. +| Key | Value Type | Indexes | `value` components | +| --------------------- | ------------ | ----------- | ------------------ | +| `t_mesh_translation` | `u32` | mesh | 3 | +| `t_mesh_rotation` | `u32` | mesh | 4 | +| `t_mesh_scale` | `u32` | mesh | 3 | +| `t_mesh_morph_weight` | `u32`, `u32` | mesh, morph | 1 | +| `t_joint_translation` | `u32`, `u32` | arma, joint | 3 | +| `t_joint_rotation` | `u32`, `u32` | arma, joint | 4 | +| `t_joint_scale` | `u32`, `u32` | arma, joint | 3 | +| `t_light_translation` | `u32` | mesh | 3 | +| `time` | `Res<[f32]>` | | | +| `value` | `Res<[f32]>` | | | + - **Time & Values**: Time and value arrays contain corresponding elements. Every point is a keyframe and lineraly interpolated by default. -- cgit v1.2.3-70-g09d2