@anime-studio/director 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.
Files changed (134) hide show
  1. package/dist/describe.d.ts +1 -1
  2. package/dist/direct/arcs.d.ts +17 -0
  3. package/dist/direct/arcs.d.ts.map +1 -0
  4. package/dist/direct/arcs.js +76 -0
  5. package/dist/direct/arcs.js.map +1 -0
  6. package/dist/direct/arms.d.ts +46 -0
  7. package/dist/direct/arms.d.ts.map +1 -0
  8. package/dist/direct/arms.js +233 -0
  9. package/dist/direct/arms.js.map +1 -0
  10. package/dist/direct/beat.d.ts +7 -0
  11. package/dist/direct/beat.d.ts.map +1 -0
  12. package/dist/direct/beat.js +339 -0
  13. package/dist/direct/beat.js.map +1 -0
  14. package/dist/direct/build.d.ts +7 -0
  15. package/dist/direct/build.d.ts.map +1 -0
  16. package/dist/direct/build.js +152 -0
  17. package/dist/direct/build.js.map +1 -0
  18. package/dist/direct/camera.d.ts +38 -0
  19. package/dist/direct/camera.d.ts.map +1 -0
  20. package/dist/direct/camera.js +279 -0
  21. package/dist/direct/camera.js.map +1 -0
  22. package/dist/direct/cast.d.ts +45 -0
  23. package/dist/direct/cast.d.ts.map +1 -0
  24. package/dist/direct/cast.js +172 -0
  25. package/dist/direct/cast.js.map +1 -0
  26. package/dist/direct/check.d.ts +17 -0
  27. package/dist/direct/check.d.ts.map +1 -0
  28. package/dist/direct/check.js +270 -0
  29. package/dist/direct/check.js.map +1 -0
  30. package/dist/direct/contact.d.ts +28 -0
  31. package/dist/direct/contact.d.ts.map +1 -0
  32. package/dist/direct/contact.js +222 -0
  33. package/dist/direct/contact.js.map +1 -0
  34. package/dist/direct/dialogue.d.ts +19 -0
  35. package/dist/direct/dialogue.d.ts.map +1 -0
  36. package/dist/direct/dialogue.js +110 -0
  37. package/dist/direct/dialogue.js.map +1 -0
  38. package/dist/direct/episode.d.ts +10 -0
  39. package/dist/direct/episode.d.ts.map +1 -0
  40. package/dist/direct/episode.js +286 -0
  41. package/dist/direct/episode.js.map +1 -0
  42. package/dist/direct/fixtures.d.ts +29 -0
  43. package/dist/direct/fixtures.d.ts.map +1 -0
  44. package/dist/direct/fixtures.js +147 -0
  45. package/dist/direct/fixtures.js.map +1 -0
  46. package/dist/direct/flight.d.ts +23 -0
  47. package/dist/direct/flight.d.ts.map +1 -0
  48. package/dist/direct/flight.js +110 -0
  49. package/dist/direct/flight.js.map +1 -0
  50. package/dist/direct/furniture.d.ts +59 -0
  51. package/dist/direct/furniture.d.ts.map +1 -0
  52. package/dist/direct/furniture.js +149 -0
  53. package/dist/direct/furniture.js.map +1 -0
  54. package/dist/direct/gestures.d.ts +31 -0
  55. package/dist/direct/gestures.d.ts.map +1 -0
  56. package/dist/direct/gestures.js +211 -0
  57. package/dist/direct/gestures.js.map +1 -0
  58. package/dist/direct/graphics.d.ts +20 -0
  59. package/dist/direct/graphics.d.ts.map +1 -0
  60. package/dist/direct/graphics.js +282 -0
  61. package/dist/direct/graphics.js.map +1 -0
  62. package/dist/direct/hand-holding.d.ts +28 -0
  63. package/dist/direct/hand-holding.d.ts.map +1 -0
  64. package/dist/direct/hand-holding.js +187 -0
  65. package/dist/direct/hand-holding.js.map +1 -0
  66. package/dist/direct/hiding.d.ts +19 -0
  67. package/dist/direct/hiding.d.ts.map +1 -0
  68. package/dist/direct/hiding.js +173 -0
  69. package/dist/direct/hiding.js.map +1 -0
  70. package/dist/direct/life.d.ts +67 -0
  71. package/dist/direct/life.d.ts.map +1 -0
  72. package/dist/direct/life.js +275 -0
  73. package/dist/direct/life.js.map +1 -0
  74. package/dist/direct/lighting.d.ts +22 -0
  75. package/dist/direct/lighting.d.ts.map +1 -0
  76. package/dist/direct/lighting.js +86 -0
  77. package/dist/direct/lighting.js.map +1 -0
  78. package/dist/direct/lying.d.ts +24 -0
  79. package/dist/direct/lying.d.ts.map +1 -0
  80. package/dist/direct/lying.js +205 -0
  81. package/dist/direct/lying.js.map +1 -0
  82. package/dist/direct/motion.d.ts +50 -0
  83. package/dist/direct/motion.d.ts.map +1 -0
  84. package/dist/direct/motion.js +270 -0
  85. package/dist/direct/motion.js.map +1 -0
  86. package/dist/direct/pictures.d.ts +24 -0
  87. package/dist/direct/pictures.d.ts.map +1 -0
  88. package/dist/direct/pictures.js +265 -0
  89. package/dist/direct/pictures.js.map +1 -0
  90. package/dist/direct/props-in-hand.d.ts +71 -0
  91. package/dist/direct/props-in-hand.d.ts.map +1 -0
  92. package/dist/direct/props-in-hand.js +285 -0
  93. package/dist/direct/props-in-hand.js.map +1 -0
  94. package/dist/direct/props.d.ts +32 -0
  95. package/dist/direct/props.d.ts.map +1 -0
  96. package/dist/direct/props.js +118 -0
  97. package/dist/direct/props.js.map +1 -0
  98. package/dist/direct/riding.d.ts +76 -0
  99. package/dist/direct/riding.d.ts.map +1 -0
  100. package/dist/direct/riding.js +290 -0
  101. package/dist/direct/riding.js.map +1 -0
  102. package/dist/direct/scene.d.ts +322 -0
  103. package/dist/direct/scene.d.ts.map +1 -0
  104. package/dist/direct/scene.js +287 -0
  105. package/dist/direct/scene.js.map +1 -0
  106. package/dist/direct/shared.d.ts +87 -0
  107. package/dist/direct/shared.d.ts.map +1 -0
  108. package/dist/direct/shared.js +42 -0
  109. package/dist/direct/shared.js.map +1 -0
  110. package/dist/direct/sitting.d.ts +62 -0
  111. package/dist/direct/sitting.d.ts.map +1 -0
  112. package/dist/direct/sitting.js +320 -0
  113. package/dist/direct/sitting.js.map +1 -0
  114. package/dist/direct/throws.d.ts +14 -0
  115. package/dist/direct/throws.d.ts.map +1 -0
  116. package/dist/direct/throws.js +89 -0
  117. package/dist/direct/throws.js.map +1 -0
  118. package/dist/direct/timeline.d.ts +23 -0
  119. package/dist/direct/timeline.d.ts.map +1 -0
  120. package/dist/direct/timeline.js +90 -0
  121. package/dist/direct/timeline.js.map +1 -0
  122. package/dist/direct/timing.d.ts +50 -0
  123. package/dist/direct/timing.d.ts.map +1 -0
  124. package/dist/direct/timing.js +138 -0
  125. package/dist/direct/timing.js.map +1 -0
  126. package/dist/direct/vocabulary.d.ts +33 -0
  127. package/dist/direct/vocabulary.d.ts.map +1 -0
  128. package/dist/direct/vocabulary.js +56 -0
  129. package/dist/direct/vocabulary.js.map +1 -0
  130. package/dist/direct.d.ts +8 -87
  131. package/dist/direct.d.ts.map +1 -1
  132. package/dist/direct.js +8 -6076
  133. package/dist/direct.js.map +1 -1
  134. package/package.json +3 -3
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scene.d.ts","sourceRoot":"","sources":["../../src/direct/scene.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,GAAG,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAC1G,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,GAAG,EAAE,KAAK,IAAI,EAAE,KAAK,SAAS,EAAY,MAAM,UAAU,CAAC;AACtF,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAE3C,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,WAAW,MAAM,iBAAiB,CAAC;AAC/C,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAA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AAO,KAAK,CAAC;AACjC,KAAK,aAAa,GAAG,OAAO,MAAM,CAAC;AACnC,KAAK,eAAe,GAAG,OAAO,QAAQ,CAAC;AACvC,KAAK,aAAa,GAAG,OAAO,MAAM,CAAC;AACnC,KAAK,WAAW,GAAG,OAAO,IAAI,CAAC;AAC/B,KAAK,YAAY,GAAG,OAAO,KAAK,CAAC;AACjC,MAAM,WAAW,UAAW,SAAQ,WAAW,EAAE,aAAa,EAAE,YAAY,EAAE,eAAe,EAAE,kBAAkB,EAAE,WAAW,EAAE,WAAW,EAAE,eAAe,EAAE,eAAe,EAAE,aAAa,EAAE,aAAa,EAAE,kBAAkB,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,aAAa,EAAE,gBAAgB,EAAE,cAAc,EAAE,YAAY,EAAE,aAAa,EAAE,eAAe,EAAE,aAAa,EAAE,WAAW,EAAE,YAAY;CAAG"}
@@ -0,0 +1,287 @@
1
+ import { r3, SLOT } from "./shared.js";
2
+ import { closest } from "./vocabulary.js";
3
+ import * as cast from "./cast.js";
4
+ import * as motion from "./motion.js";
5
+ import * as props from "./props.js";
6
+ import * as graphics from "./graphics.js";
7
+ import * as propsInHand from "./props-in-hand.js";
8
+ import * as arms from "./arms.js";
9
+ import * as beat from "./beat.js";
10
+ import * as fixtures from "./fixtures.js";
11
+ import * as lighting from "./lighting.js";
12
+ import * as throws from "./throws.js";
13
+ import * as riding from "./riding.js";
14
+ import * as handHolding from "./hand-holding.js";
15
+ import * as gestures from "./gestures.js";
16
+ import * as contact from "./contact.js";
17
+ import * as hiding from "./hiding.js";
18
+ import * as flight from "./flight.js";
19
+ import * as furniture from "./furniture.js";
20
+ import * as sitting from "./sitting.js";
21
+ import * as lying from "./lying.js";
22
+ import * as camera from "./camera.js";
23
+ import * as dialogue from "./dialogue.js";
24
+ import * as timing from "./timing.js";
25
+ import * as life from "./life.js";
26
+ import * as build from "./build.js";
27
+ export class BlockScene {
28
+ block;
29
+ kit;
30
+ time;
31
+ issues;
32
+ photoOf;
33
+ animation;
34
+ cameraStyle;
35
+ actors = [];
36
+ props = [];
37
+ script = [];
38
+ tracks = {};
39
+ walks = [];
40
+ x0 = {};
41
+ facing0 = {};
42
+ propKinds = new Map();
43
+ /** The drawings back to the old view after a turn around (dropped if a new view follows). */
44
+ turnBack = new Set();
45
+ busy = [];
46
+ views = [];
47
+ holds = [];
48
+ /** 2.5D rigs: the pose set in 3D (sitting), what the arms rest at, props hung on the body. */
49
+ pose3d = new Map();
50
+ restArms = new Map();
51
+ hung = new Map();
52
+ lastHang = new Map();
53
+ /** Limb angles set per actor and channel — [when it is reached, value, when it starts]: the next one goes the short way. */
54
+ angles = new Map();
55
+ /** When an arm is moved by a beat (automatic gestures keep out of the way). */
56
+ armBusy = [];
57
+ /** Which hand holds a prop ("F" near / "B" far): it keeps holding when the holder turns round. */
58
+ handOf = new Map();
59
+ /** The hand holding each prop over time (a turn round swaps it), so a later grab finds the right one. */
60
+ handLog = new Map();
61
+ /** Grabs back into the holding hand at a later moment: their anchor is settled when the block is built. */
62
+ regrabs = [];
63
+ /** Hand-in-hand clips (and their busy windows) that last until the hands let go. */
64
+ holdClips = [];
65
+ /** `enter` beats staged as the cast entry's entrance (the first per actor), per actor. */
66
+ placedEnters = new Map();
67
+ /** What a held prop is doing: fitted to the body (its fit, the hand's 3D target) until a moment. */
68
+ inUse = new Map();
69
+ /** Who holds whose hand (a on the left), so a new hold extends the chain instead of breaking it. */
70
+ handPairs = [];
71
+ faces = [];
72
+ /** When each actor started crossing to the far ground (smaller from then on). */
73
+ crossed = new Map();
74
+ /** Front-view gestures waiting for the posed face positions (resolved at the end of the build). */
75
+ pendingGestures = [];
76
+ /** IK reach targets set by the staging, per actor and chain (to come back to after a gesture). */
77
+ reachLog = [];
78
+ /** Riding: who is on which vehicle, and when. */
79
+ rides = [];
80
+ /** Block vehicles (id → kind, scale) and the ones lying on their side. */
81
+ vehicleOf = new Map();
82
+ fallen = new Set();
83
+ /** Block furniture (id → kind, scale). */
84
+ furnitureOf = new Map();
85
+ /** Sitting / lying (on furniture or the ground) and lying after a fall, until they get up. */
86
+ rests = [];
87
+ /** Compiled rigs of the kit's characters (the lying geometry of `lyingPose`), by character. */
88
+ rigs = new Map();
89
+ propStates = new Map();
90
+ /** Walks of the cast, leaning into the move once the block is staged (`animation.anticipation`). */
91
+ leans = [];
92
+ /** Limb keys of `arm3d`'s arcs (their in-betweens are timed already: no settle is added), and whether one is being set. */
93
+ arcKeys = new Set();
94
+ inArc = false;
95
+ cam;
96
+ present = [];
97
+ t0;
98
+ t1;
99
+ setDef;
100
+ // State used by the method groups (in their modules).
101
+ /** Where each photo of the album is (scene px: its centre and size), for the camera. */
102
+ photoSpots = new Map();
103
+ /** Hung props carried: by whom, in which hand, from when to when (and the arm kept busy meanwhile). */
104
+ carries = [];
105
+ /** The clip each fixture last played by a `fixture` beat (it holds its end until the next one). */
106
+ fixtureClips = new Map();
107
+ /** The light mood now (and when it last changed): layers, lights and fixtures follow it. */
108
+ mood = "day";
109
+ /** Pairs brought close on purpose (a hug, a high five, a hand-over, a punch…), when: the check lets them be nose to nose. */
110
+ closeOK = [];
111
+ /** Who hides behind what, and when (the check does not report their covered face then). */
112
+ hidings = [];
113
+ /**
114
+ * Camera moves the staging asked for ([from, until, momentary], episode time): the automatic camera
115
+ * keeps out of them; after a momentary one it frames the conversation again at once.
116
+ */
117
+ camBeats = [];
118
+ /** Takes (reaction and double takes) per actor: the face and the body are theirs while they last. */
119
+ takes = [];
120
+ /** Blinks staged on head turns (saccades keep out of them). */
121
+ blinkLog = [];
122
+ constructor(block, kit, time, issues, first = false,
123
+ /** A moment of another block as a frozen frame (for photos). */
124
+ photoOf = () => undefined,
125
+ /** Cartoon timing of the characters (the block's, else the staging's). */
126
+ animation,
127
+ /** How the camera behaves where no beat says otherwise (`Staging.camera.style`). */
128
+ cameraStyle = "dynamic") {
129
+ this.block = block;
130
+ this.kit = kit;
131
+ this.time = time;
132
+ this.issues = issues;
133
+ this.photoOf = photoOf;
134
+ this.animation = animation;
135
+ this.cameraStyle = cameraStyle;
136
+ // The first block starts the episode (whatever cuts show before its first line).
137
+ this.t0 = first ? 0 : time.blockStart(block);
138
+ this.t1 = time.blockEnd(block);
139
+ const set = kit.sets[block.set];
140
+ if (!set)
141
+ throw new Error(`block "${block.id}": unknown set "${block.set}" (sets: ${Object.keys(kit.sets).join(", ")})`);
142
+ this.setDef = set;
143
+ this.cam = { x: this.mark("center").x, y: (kit.height ?? 1080) / 2, zoom: 1, ...(set.bounds ? { bounds: set.bounds } : {}) };
144
+ }
145
+ t = (abs) => r3(Math.min(this.t1 - this.t0, Math.max(0, abs - this.t0)));
146
+ /** Anticipation and settle, 0..1 (the block's `animation`, else the staging's; 0: off). */
147
+ get anticipation() {
148
+ return Math.min(1, Math.max(0, Number(this.animation?.anticipation ?? 0) || 0));
149
+ }
150
+ push(a) {
151
+ // A pose the character does not draw is an error in a scene (it used to draw the default in
152
+ // silence): the director's own choices (a happy start, a scared face before a fall) are left
153
+ // out for such a character; staged ones are reported where they are staged (`stagedEmotion`).
154
+ if (a.action === "pose" && !this.hasPose(String(a.actor), String(a.control), a.value))
155
+ return;
156
+ this.script.push(a);
157
+ }
158
+ /** Whether the actor's character has this pose (a name or `{ name: weight }`; null: unset) on a pose control. */
159
+ hasPose(actor, control, value) {
160
+ const doc = this.kit.characters[this.characterOf(actor)];
161
+ const c = doc?.controls?.[control];
162
+ if (!c || c.type !== "pose" || value === null || value === undefined)
163
+ return true;
164
+ const views = control === "view" ? (doc.rig3d?.views ?? {}) : {};
165
+ const names = typeof value === "string" ? [value] : typeof value === "object" && !Array.isArray(value) ? Object.keys(value) : [];
166
+ return names.every((n) => n in (c.poses ?? {}) || n in views);
167
+ }
168
+ /** A staged emotion: a warning naming the character's emotions when it has no such pose. */
169
+ stagedEmotion(actor, value) {
170
+ if (this.hasPose(actor, "emotion", value))
171
+ return true;
172
+ const poses = Object.keys(this.kit.characters[this.characterOf(actor)]?.controls?.emotion?.poses ?? {});
173
+ const hint = typeof value === "string" && poses.length ? closest(value, poses) : ` (emotions: ${poses.join(", ") || "none"})`;
174
+ this.issue("warning", `${actor} has no emotion ${JSON.stringify(value)}${hint}`);
175
+ return false;
176
+ }
177
+ mark(name) {
178
+ if (typeof name !== "string") {
179
+ this.issue("error", `expected a mark name, got ${JSON.stringify(name)} (cast "at" takes a mark; use "offset" to move along)`);
180
+ return { x: (this.kit.width ?? 1920) / 2 };
181
+ }
182
+ const m = this.setDef.marks[name];
183
+ if (m)
184
+ return m;
185
+ if (name === "center")
186
+ return { x: (this.kit.width ?? 1920) / 2 };
187
+ if (name === "left")
188
+ return { x: 160 };
189
+ if (name === "right")
190
+ return { x: (this.kit.width ?? 1920) - 160 };
191
+ this.issue("error", `unknown mark "${name}" in set "${this.block.set}"${closest(name, [...Object.keys(this.setDef.marks), "center", "left", "right"])}`);
192
+ return { x: (this.kit.width ?? 1920) / 2 };
193
+ }
194
+ issue(severity, message) {
195
+ this.issues.push({ severity, where: `block ${this.block.id}`, message });
196
+ }
197
+ /** Episode time of a `When` (a word the line does not have is reported and timed on the line). */
198
+ when(w) {
199
+ return this.time.at(w, (m) => this.issue("warning", m));
200
+ }
201
+ member(id) {
202
+ return this.kit.cast[id];
203
+ }
204
+ scaleOf(id) {
205
+ return this.member(id)?.scale ?? 1;
206
+ }
207
+ /**
208
+ * A cast member's speed (scene px/s, at their scale): from the cast entry, else the defaults — for
209
+ * a run, the rig's own `run` clip's natural speed (its stride per cycle, at 1×: the legs at the
210
+ * cadence they were drawn at, a long-striding cartoon run not played in slow motion), else 380.
211
+ */
212
+ speedOf(id, mode = "walk") {
213
+ const own = this.member(id)?.speed?.[mode];
214
+ if (own === undefined && mode === "run") {
215
+ const run = this.kit.characters[this.characterOf(id)]?.clips?.run;
216
+ if (run?.stride && run.duration)
217
+ return (run.stride / run.duration) * this.scaleOf(id);
218
+ }
219
+ return (own ?? (mode === "run" ? 380 : mode === "fly" ? 360 : 170)) * this.scaleOf(id);
220
+ }
221
+ /**
222
+ * The set mark a place refers to — a mark name or `{ mark, dx }` (its x moved by `dx`) — with its
223
+ * `y` (a place on the far ground, a seat) and the rest of the mark; undefined for someone or a prop.
224
+ */
225
+ markOf(p) {
226
+ if (p === undefined)
227
+ return undefined;
228
+ if (typeof p === "string")
229
+ return this.present.includes(p) || this.propStates.has(p) ? undefined : this.setDef.marks[p];
230
+ if (!("mark" in p))
231
+ return undefined;
232
+ const m = this.setDef.marks[p.mark];
233
+ return m ? { ...m, x: m.x + (p.dx ?? 0) } : undefined;
234
+ }
235
+ /** Smallest distance between two characters standing side by side, `a` left of `b`, so that
236
+ * neither covers the other: what `a` reaches to the right plus what `b` reaches to the left. */
237
+ pairGap(a, b, aRight = true, bRight = true) {
238
+ const ea = this.member(a)?.rig.extent ?? { front: 60, back: 60 };
239
+ const eb = this.member(b)?.rig.extent ?? { front: 60, back: 60 };
240
+ return ((aRight ? ea.front : ea.back) * this.scaleOf(a) + (bRight ? eb.back : eb.front) * this.scaleOf(b)) * 0.95 + 20;
241
+ }
242
+ /** Scene x of a place at a given time. Next to someone = beside them, never on top of them. */
243
+ placeX(p, abs, who) {
244
+ const beside = (target, side) => {
245
+ const tx = this.xAt(target, abs);
246
+ const left = side ? side === "left" : !!who && this.xAt(who, abs) < tx;
247
+ // The walker ends facing the target.
248
+ return left ? tx - (who ? this.pairGap(who, target, true, false) : SLOT) : tx + (who ? this.pairGap(target, who, true, false) : SLOT);
249
+ };
250
+ if (typeof p === "string") {
251
+ if (this.present.includes(p))
252
+ return beside(p);
253
+ if (this.propStates.has(p))
254
+ return this.propX(p, abs);
255
+ return this.mark(p).x;
256
+ }
257
+ if ("mark" in p)
258
+ return this.mark(p.mark).x + (p.dx ?? 0);
259
+ return beside(p.near, p.side);
260
+ }
261
+ xAt(actor, abs) {
262
+ let x = this.x0[actor] ?? 960;
263
+ for (const w of this.walks.filter((w) => w.actor === actor).sort((a, b) => a.t0 - b.t0)) {
264
+ if (abs >= w.t1)
265
+ x = w.x1;
266
+ else if (abs > w.t0)
267
+ x = w.x0 + ((w.x1 - w.x0) * (abs - w.t0)) / (w.t1 - w.t0);
268
+ }
269
+ return x;
270
+ }
271
+ viewAt(actor, abs) {
272
+ return this.views.filter((v) => v.actor === actor && v.t <= abs).sort((a, b) => b.t - a.t)[0]?.view ?? "profile";
273
+ }
274
+ /** Life in the eyes and head, 0..1 (the block's `animation`, else the staging's; 0: off). */
275
+ get life() {
276
+ return Math.min(1, Math.max(0, Number(this.animation?.life ?? 0) || 0));
277
+ }
278
+ /** Arcs on IK moves, 0..1 (the block's `animation`, else the staging's; 0: off). */
279
+ get arcs() {
280
+ return Math.min(1, Math.max(0, Number(this.animation?.arcs ?? 0) || 0));
281
+ }
282
+ }
283
+ for (const group of [cast, motion, props, graphics, propsInHand, arms, beat, fixtures, lighting, throws, riding, handHolding, gestures, contact, hiding, flight, furniture, sitting, lying, camera, dialogue, timing, life, build]) {
284
+ for (const [name, value] of Object.entries(group))
285
+ Object.defineProperty(BlockScene.prototype, name, { value, writable: true, configurable: true });
286
+ }
287
+ //# sourceMappingURL=scene.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scene.js","sourceRoot":"","sources":["../../src/direct/scene.ts"],"names":[],"mappings":"AAMA,OAAO,EAAoD,EAAE,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAEtF,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,WAAW,MAAM,iBAAiB,CAAC;AAC/C,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACv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I,CAAC,SAAS,EAAE,IAAI,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAC1E,CAAC;CACF;AA6BD,KAAK,MAAM,KAAK,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,WAAW,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC;IACnO,KAAK,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,MAAM,CAAC,cAAc,CAAC,UAAU,CAAC,SAAS,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE,CAAC,CAAC;AACtJ,CAAC"}
@@ -0,0 +1,87 @@
1
+ /**
2
+ * Shared types, constants and small helpers of the director modules.
3
+ */
4
+ import type { Kit } from "../types.js";
5
+ export type Action = Record<string, unknown> & {
6
+ at: number;
7
+ action: string;
8
+ };
9
+ export type Key = [number, number | string | [number, number], string?];
10
+ export declare const r3: (n: number) => number;
11
+ export declare const norm: (s: string) => string;
12
+ /** A number in [0, 1) from a string (FNV-1a): the same in every render. */
13
+ export declare function hash01(s: string): number;
14
+ /**
15
+ * The cast member a line's `speaker` names — by id, by name or by one of their aliases (case and
16
+ * accents ignored) — or undefined (a narrator, "sfx", "song", an unknown name). The one resolver for
17
+ * staging and checks, so both see the same speaker.
18
+ */
19
+ export declare function speakerId(kit: Kit, speaker: string | undefined): string | undefined;
20
+ /** Lead time: a block (and its camera) starts this much before its first line. */
21
+ export declare const LEAD = 0.25;
22
+ /** A crossfade between blocks (s): the shot faded into begins this early in its scene. */
23
+ export declare const CROSSFADE = 0.6;
24
+ export declare const SLOT = 230;
25
+ /** A limb's angle channels (they turn the short way round; free moves of them may settle). */
26
+ export declare const LIMB: RegExp;
27
+ /** Per staged scene: pairs close together on purpose and who sits when (scene time), for the picture checks. */
28
+ export declare const STAGED: WeakMap<object, {
29
+ pairs: {
30
+ a: string;
31
+ b: string;
32
+ t0: number;
33
+ t1: number;
34
+ }[];
35
+ seated: {
36
+ actor: string;
37
+ t0: number;
38
+ t1: number;
39
+ }[];
40
+ }>;
41
+ /** How a rig sits facing the camera (`meta.sitFront`): see DIRECTOR.md, `sit`. */
42
+ export interface SitFront {
43
+ /** Share of the thigh that shows (rigs without a seated drawing). */
44
+ thigh?: number;
45
+ spread?: number;
46
+ hands?: "knees";
47
+ /** Drawn knees (setup space): the shins hang from them. */
48
+ knees?: {
49
+ F: [number, number];
50
+ B: [number, number];
51
+ };
52
+ /** The same seated in three-quarter (the half view). */
53
+ half?: {
54
+ knees?: {
55
+ F: [number, number];
56
+ B: [number, number];
57
+ };
58
+ };
59
+ /** How far the body sinks into the cushion (setup px). */
60
+ sink?: number;
61
+ }
62
+ export interface Walk {
63
+ actor: string;
64
+ t0: number;
65
+ t1: number;
66
+ x0: number;
67
+ x1: number;
68
+ }
69
+ export interface PropState {
70
+ id: string;
71
+ radius: number;
72
+ x: Key[];
73
+ y: Key[];
74
+ scale: Key[];
75
+ rotation: Key[];
76
+ heldBy: {
77
+ actor: string;
78
+ t0: number;
79
+ t1: number;
80
+ }[];
81
+ }
82
+ /** Camera beats that are a moment, not a shot: the conversation framing comes back `MOMENTARY_HOLD` s after them (unless timed). */
83
+ export declare const MOMENTARY_CAMERA: string[];
84
+ export declare const MOMENTARY_HOLD = 2.5;
85
+ /** The widest the conversation camera opens to fit everyone: 0.8 of the wide shot (zoom 1); beyond it, it frames the speaker. */
86
+ export declare const CONVERSATION_MIN_ZOOM = 0.8;
87
+ //# sourceMappingURL=shared.d.ts.map
@@ -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M,qBAAqB,MAAM,CAAC"}
@@ -0,0 +1,42 @@
1
+ export const r3 = (n) => Math.round(n * 1000) / 1000;
2
+ export const norm = (s) => s
3
+ .normalize("NFD")
4
+ .replace(/[̀-ͯ]/g, "")
5
+ .toLowerCase()
6
+ .replace(/[^a-z0-9 ]/g, " ")
7
+ .trim();
8
+ /** A number in [0, 1) from a string (FNV-1a): the same in every render. */
9
+ export function hash01(s) {
10
+ let h = 0x811c9dc5;
11
+ for (let i = 0; i < s.length; i++)
12
+ h = Math.imul(h ^ s.charCodeAt(i), 0x01000193);
13
+ return (h >>> 0) / 4294967296;
14
+ }
15
+ /**
16
+ * The cast member a line's `speaker` names — by id, by name or by one of their aliases (case and
17
+ * accents ignored) — or undefined (a narrator, "sfx", "song", an unknown name). The one resolver for
18
+ * staging and checks, so both see the same speaker.
19
+ */
20
+ export function speakerId(kit, speaker) {
21
+ if (!speaker)
22
+ return undefined;
23
+ const s = norm(speaker);
24
+ if (!s)
25
+ return undefined;
26
+ return Object.entries(kit.cast).find(([id, c]) => norm(id) === s || norm(c.name) === s || (c.aliases ?? []).some((a) => norm(a) === s))?.[0];
27
+ }
28
+ /** Lead time: a block (and its camera) starts this much before its first line. */
29
+ export const LEAD = 0.25;
30
+ /** A crossfade between blocks (s): the shot faded into begins this early in its scene. */
31
+ export const CROSSFADE = 0.6;
32
+ export const SLOT = 230;
33
+ /** A limb's angle channels (they turn the short way round; free moves of them may settle). */
34
+ export const LIMB = /^bones\.(arm|leg|hand|foot)\w*\.(rotation|turn|spread)$/;
35
+ /** Per staged scene: pairs close together on purpose and who sits when (scene time), for the picture checks. */
36
+ export const STAGED = new WeakMap();
37
+ /** Camera beats that are a moment, not a shot: the conversation framing comes back `MOMENTARY_HOLD` s after them (unless timed). */
38
+ export const MOMENTARY_CAMERA = ["crash", "whip", "shake"];
39
+ export const MOMENTARY_HOLD = 2.5;
40
+ /** The widest the conversation camera opens to fit everyone: 0.8 of the wide shot (zoom 1); beyond it, it frames the speaker. */
41
+ export const CONVERSATION_MIN_ZOOM = 0.8;
42
+ //# sourceMappingURL=shared.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.js","sourceRoot":"","sources":["../../src/direct/shared.ts"],"names":[],"mappings":"AAQA,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,IAAI,CAAC,GAAG,IAAI,CAAC;AAC7D,MAAM,CAAC,MAAM,IAAI,GAAG,CAAC,CAAS,EAAE,EAAE,CAChC,CAAC;KACE,SAAS,CAAC,KAAK,CAAC;KAChB,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC;KACrB,WAAW,EAAE;KACb,OAAO,CAAC,aAAa,EAAE,GAAG,CAAC;KAC3B,IAAI,EAAE,CAAC;AAEZ,2EAA2E;AAC3E,MAAM,UAAU,MAAM,CAAC,CAAS;IAC9B,IAAI,CAAC,GAAG,UAAU,CAAC;IACnB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE;QAAE,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC;IAClF,OAAO,CAAC,CAAC,KAAK,CAAC,CAAC,GAAG,UAAU,CAAC;AAChC,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,SAAS,CAAC,GAAQ,EAAE,OAA2B;IAC7D,IAAI,CAAC,OAAO;QAAE,OAAO,SAAS,CAAC;IAC/B,MAAM,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC;IACxB,IAAI,CAAC,CAAC;QAAE,OAAO,SAAS,CAAC;IACzB,OAAO,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAC/I,CAAC;AAED,kFAAkF;AAClF,MAAM,CAAC,MAAM,IAAI,GAAG,IAAI,CAAC;AACzB,0FAA0F;AAC1F,MAAM,CAAC,MAAM,SAAS,GAAG,GAAG,CAAC;AAC7B,MAAM,CAAC,MAAM,IAAI,GAAG,GAAG,CAAC;AACxB,8FAA8F;AAC9F,MAAM,CAAC,MAAM,IAAI,GAAG,yDAAyD,CAAC;AAE9E,gHAAgH;AAChH,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,OAAO,EAA8H,CAAC;AAmBhK,oIAAoI;AACpI,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;AAC3D,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,CAAC;AAClC,iIAAiI;AACjI,MAAM,CAAC,MAAM,qBAAqB,GAAG,GAAG,CAAC"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Sitting: on furniture or the floor, in 2D and on the 2.5D pipeline, seen from the front.
3
+ */
4
+ import { type Rig3dValues } from "@anime-studio/core";
5
+ import type { BlockScene } from "./scene.js";
6
+ import { type SitFront } from "./shared.js";
7
+ /** Sits on furniture (`seat` anchor), a set seat (mark with `seat`) or the ground: hips down, knees up, feet on the floor. */
8
+ export declare function sit(this: BlockScene, actor: string, on: string | null, at: number, view?: string, how?: {
9
+ legs?: string;
10
+ hands?: "knees" | "lap";
11
+ }): void;
12
+ /**
13
+ * Sitting seen from the front: the thighs point at the camera (foreshortened: shorter and rounder),
14
+ * the shins hang straight down to the floor under the knees; on the ground both are foreshortened.
15
+ */
16
+ /** A 2.5D rig (`rig3d`): poses are 3D, drawn from any angle. */
17
+ export declare function is3d(this: BlockScene, actor: string): boolean;
18
+ /** The view of a 2.5D rig drawn nearest to a yaw (degrees, 0 = facing the camera). */
19
+ export declare function nearestView(this: BlockScene, actor: string, yaw: number): string;
20
+ /** Which side of the body's middle a leg's hip is on (−1: −x, +1: +x) in the rig's 3D build; the near leg at −x when they share it. */
21
+ export declare function hipSide(this: BlockScene, actor: string, side: "F" | "B"): -1 | 1;
22
+ /**
23
+ * A leg's channels opened outwards by `deg` in a pose: the knee away from the body's middle, on
24
+ * its hip's side. Found on the rig's own forward kinematics (`rig3dPose`): `spread` (about the
25
+ * forward axis) swings a hanging limb sideways, `turn` (about the vertical) a raised one —
26
+ * whichever moves the knee out the most, with the sign that does; nothing when neither does.
27
+ */
28
+ export declare function legOut(this: BlockScene, actor: string, values: Rig3dValues, side: "F" | "B", deg: number): NonNullable<Rig3dValues[string]>;
29
+ /**
30
+ * Sitting in 3D (a 2.5D rig): thighs forward (knees up when the seat is low), shins down to the
31
+ * floor, the body a little back; hands on the knees or in the lap. The same pose reads from any
32
+ * angle the rig is drawn at.
33
+ */
34
+ export declare function sit3d(this: BlockScene, actor: string, seatH: number, at: number, how: {
35
+ legs?: string;
36
+ hands?: "knees" | "lap";
37
+ }, ground?: boolean): void;
38
+ /**
39
+ * Sitting on the floor in 3D: `straight` — legs out in front, leaning back on the hands behind;
40
+ * `hug` — knees up to the chest, arms around them.
41
+ */
42
+ export declare function sitFloor3d(this: BlockScene, actor: string, at: number, legs: string): void;
43
+ /**
44
+ * Puts a 2.5D rig's hands on its legs in a pose (`values`: the legs and the body's lean): arms
45
+ * reached in 3D (`reach3d`) to points the callback picks — `on(bone, t, inward)`: the top of a
46
+ * thigh at `t` of its length, moved towards the middle by `inward` of the hips' half width;
47
+ * `around(side)`: in front of the shins (hugging the knees); `behind(side)`: on the floor behind
48
+ * the hips. Elbows go back and out, unless `pole` says otherwise.
49
+ */
50
+ export declare function handsOnLegs(this: BlockScene, actor: string, at: number, values: Rig3dValues, pick: (P: {
51
+ on: (bone: string, t: number, inward: number) => [number, number, number];
52
+ around: (side: string) => [number, number, number];
53
+ behind: (side: string) => [number, number, number];
54
+ }, side: string) => [number, number, number], pole?: (side: string) => [number, number, number]): void;
55
+ export declare function unsit3d(this: BlockScene, actor: string, at: number): void;
56
+ /** A rig's seated-facing-the-camera description (`meta.sitFront`). */
57
+ export declare function sitFrontOf(this: BlockScene, actor: string): SitFront | undefined;
58
+ export declare function frontLegs(this: BlockScene, actor: string, x: number, seatY: number, floor: number, dir: number, at: number, how?: {
59
+ legs?: string;
60
+ hands?: "knees" | "lap";
61
+ }, view?: "front" | "half"): void;
62
+ //# sourceMappingURL=sitting.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sitting.d.ts","sourceRoot":"","sources":["../../src/direct/sitting.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,KAAK,WAAW,EAAsB,MAAM,oBAAoB,CAAC;AAC1E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAM,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAC;AAE7C,8HAA8H;AAC9H,wBAAgB,GAAG,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,IAAI,EAAE,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,GAAG,GAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,OAAO,GAAG,KAAK,CAAA;CAAO,QAoEtJ;AAED;;;GAGG;AACH,gEAAgE;AAChE,wBAAgB,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,WAEnD;AAED,sFAAsF;AACtF,wBAAgB,WAAW,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EA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