@franzenzenhofer/asanakit 0.3.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -3
- package/dist/anatomy/muscles.js +1 -1
- package/dist/anatomy/muscles.js.map +1 -1
- package/dist/cli/commands/export.js +1 -1
- package/dist/cli/commands/export.js.map +1 -1
- package/dist/cli/commands/info.js +1 -1
- package/dist/cli/commands/info.js.map +1 -1
- package/dist/cli/commands/render.d.ts.map +1 -1
- package/dist/cli/commands/render.js +24 -10
- package/dist/cli/commands/render.js.map +1 -1
- package/dist/cli/commands/view.d.ts.map +1 -1
- package/dist/cli/commands/view.js +1 -0
- package/dist/cli/commands/view.js.map +1 -1
- package/dist/core/camera.d.ts +6 -2
- package/dist/core/camera.d.ts.map +1 -1
- package/dist/core/camera.js +6 -2
- package/dist/core/camera.js.map +1 -1
- package/dist/core/joints.d.ts +5 -1
- package/dist/core/joints.d.ts.map +1 -1
- package/dist/core/joints.js +14 -2
- package/dist/core/joints.js.map +1 -1
- package/dist/core/types.d.ts +17 -1
- package/dist/core/types.d.ts.map +1 -1
- package/dist/model/schema.d.ts +29 -11
- package/dist/model/schema.d.ts.map +1 -1
- package/dist/model/schema.js +32 -9
- package/dist/model/schema.js.map +1 -1
- package/dist/props/geometry.d.ts +46 -0
- package/dist/props/geometry.d.ts.map +1 -0
- package/dist/props/geometry.js +87 -0
- package/dist/props/geometry.js.map +1 -0
- package/dist/render/camera.d.ts +2 -0
- package/dist/render/camera.d.ts.map +1 -1
- package/dist/render/camera.js +1 -0
- package/dist/render/camera.js.map +1 -1
- package/dist/render/figure.d.ts.map +1 -1
- package/dist/render/figure.js +3 -2
- package/dist/render/figure.js.map +1 -1
- package/dist/render/props.d.ts +1 -1
- package/dist/render/props.d.ts.map +1 -1
- package/dist/render/props.js +25 -10
- package/dist/render/props.js.map +1 -1
- package/dist/render/styles.d.ts +2 -0
- package/dist/render/styles.d.ts.map +1 -1
- package/dist/render/styles.js +7 -5
- package/dist/render/styles.js.map +1 -1
- package/dist/three/props.d.ts +11 -0
- package/dist/three/props.d.ts.map +1 -0
- package/dist/three/props.js +56 -0
- package/dist/three/props.js.map +1 -0
- package/dist/three/scene.d.ts +6 -1
- package/dist/three/scene.d.ts.map +1 -1
- package/dist/three/scene.js +23 -11
- package/dist/three/scene.js.map +1 -1
- package/dist/viewer/html.d.ts +2 -1
- package/dist/viewer/html.d.ts.map +1 -1
- package/dist/viewer/html.js +11 -3
- package/dist/viewer/html.js.map +1 -1
- package/dist/viewer/viewer.bundle.js +177 -177
- package/docs/AUTHORING.md +35 -9
- package/package.json +1 -1
- package/poses/yoga/ashtanga/prasarita-padottanasana-a.pose.yaml +1 -0
- package/poses/yoga/ashtanga/prasarita-padottanasana-c.pose.yaml +1 -0
- package/poses/yoga/ashtanga/utthita-parsvakonasana.pose.yaml +1 -0
- package/poses/yoga/ashtanga/utthita-trikonasana.pose.yaml +1 -0
- package/poses/yoga/ashtanga/virabhadrasana-b.pose.yaml +1 -0
package/docs/AUTHORING.md
CHANGED
|
@@ -53,21 +53,47 @@ joints:
|
|
|
53
53
|
shinR: 60 # knee bends 60° (backward - the only way a knee goes)
|
|
54
54
|
```
|
|
55
55
|
|
|
56
|
-
The object form
|
|
56
|
+
The object form speaks the full anatomical vocabulary - every axis by both of its names:
|
|
57
57
|
|
|
58
58
|
```yaml
|
|
59
59
|
joints:
|
|
60
|
-
upperArmL: { abduct: 90 }
|
|
60
|
+
upperArmL: { abduct: 90 } # arm straight out to the side
|
|
61
61
|
thighR: { flex: 45, abduct: 30, twist: 20 }
|
|
62
|
+
upperArmR: { extend: 30 } # arm reaches behind the body
|
|
63
|
+
thighL: { adduct: 15, internalRotation: 10 }
|
|
62
64
|
```
|
|
63
65
|
|
|
64
|
-
- `flex` - forward bend for hips/arms/spine,
|
|
65
|
-
|
|
66
|
-
- `
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
66
|
+
- `flex` / `extend` - flexion and extension. Flexion is forward bend for hips/arms/spine,
|
|
67
|
+
backward for knees, toes-up (dorsiflexion) for ankles; extension is its opposite.
|
|
68
|
+
- `abduct` / `adduct` - away from / toward the midline, on either side. Center bones lean
|
|
69
|
+
toward the figure's left on positive `abduct` (lateral flexion).
|
|
70
|
+
- `twist`, or `externalRotation` / `internalRotation` by name - rotation about the bone.
|
|
71
|
+
Positive `twist` is external rotation (toes/palms turn outward); for center bones,
|
|
72
|
+
turning toward the figure's left (axial rotation).
|
|
73
|
+
|
|
74
|
+
Naming both directions of one axis (`flex` AND `extend`) is a contradiction and fails
|
|
75
|
+
loudly. The signs are per-side anatomical, so a mirrored pose is literally the same
|
|
76
|
+
numbers with L and R swapped - which is what `mirror: true` does.
|
|
77
|
+
|
|
78
|
+
### How classic movement terms map onto the format
|
|
79
|
+
|
|
80
|
+
| You say | You write |
|
|
81
|
+
|---|---|
|
|
82
|
+
| hip flexion / extension | `thighL: { flex: … }` / `{ extend: … }` |
|
|
83
|
+
| knee flexion | `shinL: 60` (knees only flex; the validator rejects the other way) |
|
|
84
|
+
| ankle dorsiflexion / plantarflexion | `footL: { flex: … }` / `{ extend: … }` |
|
|
85
|
+
| foot turnout (out-toeing) | `footL: { abduct: … }` or `thighL: { externalRotation: … }` |
|
|
86
|
+
| shoulder flexion (arm forward-up) | `upperArmL: { flex: … }` |
|
|
87
|
+
| shoulder abduction (arm sideways-up) | `upperArmL: { abduct: … }` |
|
|
88
|
+
| shoulder internal/external rotation | `upperArmL: { internalRotation: … }` / `{ externalRotation: … }` |
|
|
89
|
+
| elbow flexion | `forearmL: 90` |
|
|
90
|
+
| forearm pronation / supination | `forearmL: { internalRotation: … }` / `{ externalRotation: … }` |
|
|
91
|
+
| scapular elevation (shrug) | `clavicleL: { abduct: … }` |
|
|
92
|
+
| scapular protraction / retraction | `clavicleL: { flex: … }` / `{ extend: … }` |
|
|
93
|
+
| spinal flexion (forward fold) / extension (backbend) | `spine: { flex: … }` / `{ extend: … }` |
|
|
94
|
+
| spinal lateral flexion (side bend) | `spine: { abduct: … }` (positive = toward the figure's left) |
|
|
95
|
+
| spinal / cervical rotation (twist) | `spine: { twist: … }`, `neck: { twist: … }` |
|
|
96
|
+
| hip abduction / adduction | `thighL: { abduct: … }` / `{ adduct: … }` |
|
|
71
97
|
|
|
72
98
|
### The root
|
|
73
99
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@franzenzenhofer/asanakit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Programmatic stick-figure and body-posture visualization engine for yoga and surf. Declarative 3D pose format, deterministic any-angle SVG/PNG, interactive three.js viewer, GLB export, Rapier physics settling. CLI-first, AI-driveable.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"yoga",
|