@msb235/blits 0.14.0 → 0.15.1
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/CHANGELOG.md +198 -0
- package/README.md +3 -3
- package/dist/ahead.d.ts +26 -0
- package/dist/ahead.js +264 -0
- package/dist/around.d.ts +11 -0
- package/dist/around.js +32 -0
- package/dist/bare.js +37 -14
- package/dist/blank.d.ts +10 -0
- package/dist/blank.js +26 -0
- package/dist/blend.d.ts +2 -1
- package/dist/blend.js +1 -6
- package/dist/bound.d.ts +70 -0
- package/dist/bound.js +351 -0
- package/dist/chain.d.ts +2 -1
- package/dist/chain.js +7 -5
- package/dist/changes.d.ts +24 -0
- package/dist/changes.js +189 -0
- package/dist/channels.d.ts +39 -13
- package/dist/channels.js +14 -5
- package/dist/color.d.ts +12 -10
- package/dist/color.js +25 -25
- package/dist/columns.d.ts +2 -1
- package/dist/columns.js +62 -38
- package/dist/contribution.d.ts +30 -0
- package/dist/contribution.js +374 -0
- package/dist/copyout.d.ts +10 -0
- package/dist/copyout.js +69 -24
- package/dist/crowd.d.ts +16 -6
- package/dist/crowd.js +20 -11
- package/dist/cue.d.ts +8 -1
- package/dist/cue.js +39 -13
- package/dist/cut.d.ts +8 -0
- package/dist/cut.js +4 -0
- package/dist/delay.d.ts +3 -0
- package/dist/delay.js +7 -0
- package/dist/drop.d.ts +9 -0
- package/dist/drop.js +84 -0
- package/dist/due.d.ts +24 -5
- package/dist/due.js +114 -34
- package/dist/easing.d.ts +6 -4
- package/dist/easing.js +7 -3
- package/dist/everyone.d.ts +8 -2
- package/dist/everyone.js +33 -3
- package/dist/fade.d.ts +2 -1
- package/dist/fade.js +2 -1
- package/dist/fill.d.ts +3 -2
- package/dist/fill.js +52 -20
- package/dist/fit.d.ts +44 -26
- package/dist/fit.js +10 -9
- package/dist/fold.d.ts +4 -37
- package/dist/fold.js +5 -513
- package/dist/gather.d.ts +12 -7
- package/dist/gather.js +179 -44
- package/dist/gone.js +2 -2
- package/dist/grid.d.ts +47 -0
- package/dist/grid.js +247 -0
- package/dist/handle.d.ts +2 -0
- package/dist/handle.js +14 -8
- package/dist/held.d.ts +2 -1
- package/dist/held.js +2 -1
- package/dist/history.d.ts +6 -5
- package/dist/history.js +7 -9
- package/dist/hosts.js +9 -15
- package/dist/index.d.ts +5 -4
- package/dist/keyfill.d.ts +1 -1
- package/dist/keyfill.js +5 -3
- package/dist/keyrows.d.ts +12 -0
- package/dist/keyrows.js +99 -12
- package/dist/lane.d.ts +38 -11
- package/dist/lane.js +46 -11
- package/dist/lanes.d.ts +30 -12
- package/dist/lanes.js +56 -36
- package/dist/leavings.d.ts +2 -2
- package/dist/leavings.js +1 -1
- package/dist/lives.d.ts +47 -0
- package/dist/lives.js +180 -0
- package/dist/meet.d.ts +2 -2
- package/dist/meet.js +95 -7
- package/dist/mixer.d.ts +56 -37
- package/dist/mixer.js +57 -171
- package/dist/motion.d.ts +14 -118
- package/dist/motion.js +16 -8
- package/dist/motions.d.ts +62 -155
- package/dist/motions.js +56 -370
- package/dist/moved.d.ts +1 -1
- package/dist/moved.js +16 -7
- package/dist/named.d.ts +6 -2
- package/dist/named.js +49 -3
- package/dist/numbers.d.ts +7 -0
- package/dist/numbers.js +33 -0
- package/dist/owed.d.ts +2 -0
- package/dist/owed.js +4 -0
- package/dist/pack.d.ts +2 -1
- package/dist/pack.js +2 -3
- package/dist/patch.d.ts +7 -3
- package/dist/patch.js +6 -2
- package/dist/places.d.ts +53 -0
- package/dist/places.js +171 -0
- package/dist/plot.d.ts +12 -0
- package/dist/plot.js +52 -0
- package/dist/project.d.ts +4 -4
- package/dist/project.js +9 -212
- package/dist/pull.js +22 -9
- package/dist/qualify.js +93 -31
- package/dist/reading.d.ts +6 -0
- package/dist/reading.js +5 -0
- package/dist/record.d.ts +5 -1
- package/dist/record.js +3 -2
- package/dist/relink.d.ts +1 -1
- package/dist/renumber.d.ts +10 -0
- package/dist/renumber.js +75 -0
- package/dist/restored.d.ts +2 -2
- package/dist/restored.js +1 -1
- package/dist/rests.d.ts +9 -0
- package/dist/rests.js +76 -0
- package/dist/revive.d.ts +3 -2
- package/dist/revive.js +2 -2
- package/dist/{locus.d.ts → role.d.ts} +10 -9
- package/dist/{locus.js → role.js} +3 -3
- package/dist/roles.d.ts +10 -0
- package/dist/roles.js +158 -0
- package/dist/roster.js +3 -3
- package/dist/rotation.d.ts +1 -1
- package/dist/rotation.js +1 -1
- package/dist/rows.js +28 -20
- package/dist/sample.d.ts +2 -2
- package/dist/sample.js +33 -7
- package/dist/seat.d.ts +17 -0
- package/dist/seat.js +25 -0
- package/dist/seek.js +5 -5
- package/dist/setting.d.ts +27 -0
- package/dist/setting.js +55 -0
- package/dist/shared.d.ts +1 -1
- package/dist/shared.js +1 -1
- package/dist/signals.d.ts +64 -32
- package/dist/signals.js +20 -18
- package/dist/stack.d.ts +5 -5
- package/dist/stack.js +5 -5
- package/dist/standing.d.ts +2 -1
- package/dist/standing.js +3 -2
- package/dist/store.d.ts +9 -0
- package/dist/store.js +24 -0
- package/dist/strays.d.ts +2 -1
- package/dist/strays.js +23 -15
- package/dist/stretch.d.ts +112 -0
- package/dist/stretch.js +9 -0
- package/dist/subject.d.ts +142 -0
- package/dist/subject.js +1 -0
- package/dist/tape.d.ts +9 -5
- package/dist/tape.js +5 -1
- package/dist/then.d.ts +9 -0
- package/dist/then.js +57 -0
- package/dist/ticker.d.ts +4 -4
- package/dist/trace.d.ts +4 -0
- package/dist/trace.js +255 -0
- package/dist/transport.d.ts +0 -8
- package/dist/transport.js +0 -4
- package/dist/turns.d.ts +4 -3
- package/dist/turns.js +4 -3
- package/dist/types/arc.d.ts +12 -11
- package/dist/types/channel.d.ts +12 -8
- package/dist/types/history.d.ts +35 -19
- package/dist/types/mix.d.ts +237 -163
- package/dist/types/motion.d.ts +151 -0
- package/dist/types/motion.js +1 -0
- package/dist/types/patch.d.ts +67 -34
- package/dist/types/place.d.ts +51 -36
- package/dist/types/trace.d.ts +51 -0
- package/dist/types/trace.js +1 -0
- package/dist/types/transport.d.ts +20 -18
- package/dist/types/voice.d.ts +144 -73
- package/dist/types/watch.d.ts +88 -40
- package/dist/types.d.ts +2 -0
- package/dist/unreached.d.ts +2 -0
- package/dist/unreached.js +7 -0
- package/dist/voice.d.ts +10 -143
- package/dist/voice.js +37 -82
- package/dist/warn.d.ts +2 -0
- package/dist/warn.js +1 -1
- package/dist/watch.d.ts +2 -2
- package/dist/watch.js +5 -3
- package/dist/wave.d.ts +4 -3
- package/dist/wave.js +3 -2
- package/dist/weigh.d.ts +7 -1
- package/dist/weigh.js +27 -0
- package/docs/schema.html +223 -34
- package/package.json +2 -2
package/dist/wave.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { patch } from './patch.js';
|
|
2
2
|
/**
|
|
3
|
-
* The unit wave
|
|
3
|
+
* The unit wave's value at `x` cycles, from -1 to 1. It starts at 0 and rises (square: +1 for the
|
|
4
|
+
* first half).
|
|
4
5
|
*
|
|
5
6
|
* @category patch
|
|
6
7
|
*/
|
|
@@ -39,7 +40,7 @@ function planOf(opts) {
|
|
|
39
40
|
return plan;
|
|
40
41
|
}
|
|
41
42
|
/**
|
|
42
|
-
* A periodic swing on each channel `depth` names, around its rest
|
|
43
|
+
* A periodic swing on each channel `depth` names, around its rest. An LFO for a bob, a sway or a
|
|
43
44
|
* pulse. An `fn` patch that keeps its options on `patch.wave`, for an engine reading the wave
|
|
44
45
|
* rather than calling it.
|
|
45
46
|
*
|
package/dist/weigh.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { Mixer } from './mixer.js';
|
|
2
|
-
import type { Subject
|
|
2
|
+
import type { Subject } from './subject.js';
|
|
3
|
+
import type { Voice } from './voice.js';
|
|
3
4
|
/**
|
|
4
5
|
* Where `prime` reads its numbers in `Mixer.primed`: as arguments, each would be boxed wherever V8
|
|
5
6
|
* does not inline the call, which turns on the order its compiles ran (bench/frame.mjs `glow`,
|
|
@@ -13,6 +14,11 @@ export declare const enum Primed {
|
|
|
13
14
|
}
|
|
14
15
|
/** Fills a voice's setting for a call to its patch, the weight aside, from `primed`. */
|
|
15
16
|
export declare function prime<I, O>(this: Mixer<I, O>, voice: Voice<I, O>, held: Subject<unknown>): void;
|
|
17
|
+
/**
|
|
18
|
+
* `prime` for a lane's call, from `arg`: the per-lane fields only where the setting was not
|
|
19
|
+
* already filled under `Arg.MARK`, since nothing but the engine writes a setting.
|
|
20
|
+
*/
|
|
21
|
+
export declare function primeLaned<I, O>(this: Mixer<I, O>, voice: Voice<I, O>, held: Subject<unknown>, arg: Float64Array): void;
|
|
16
22
|
/** A gap as a `dt`: Infinity under reduced motion, and no more than `maxDt`. */
|
|
17
23
|
export declare function capped<I, O>(this: Mixer<I, O>, gap: number): number;
|
|
18
24
|
/** The earliest voice time a read may still ask for, for a subject delayed `delay`. */
|
package/dist/weigh.js
CHANGED
|
@@ -17,8 +17,35 @@ export function prime(voice, held) {
|
|
|
17
17
|
setting.pass = pass;
|
|
18
18
|
setting.weight = 0;
|
|
19
19
|
setting.state = held.state;
|
|
20
|
+
setting.mark = 0;
|
|
20
21
|
voice.keepOn = held;
|
|
21
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* `prime` for a lane's call, from `arg`: the per-lane fields only where the setting was not
|
|
25
|
+
* already filled under `Arg.MARK`, since nothing but the engine writes a setting.
|
|
26
|
+
*/
|
|
27
|
+
export function primeLaned(voice, held, arg) {
|
|
28
|
+
const now = this.now;
|
|
29
|
+
const setting = voice.setting;
|
|
30
|
+
if (setting.mark !== arg[6 /* Arg.MARK */])
|
|
31
|
+
markSetting(setting, now, arg);
|
|
32
|
+
if (voice.patch.step === undefined && held.probed < now)
|
|
33
|
+
held.stepped = held.probed;
|
|
34
|
+
setting.dt = this.capped(now - held.stepped);
|
|
35
|
+
setting.weight = 0;
|
|
36
|
+
setting.state = held.state;
|
|
37
|
+
voice.keepOn = held;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* `primeLaned`'s once-a-lane fields, kept out of it so it fits `one`'s inlining budget beside
|
|
41
|
+
* `signalled`, which otherwise took its place (`glow^` 4.5% faster, 2026-10-28).
|
|
42
|
+
*/
|
|
43
|
+
function markSetting(setting, now, arg) {
|
|
44
|
+
setting.timestamp = now;
|
|
45
|
+
setting.elapsed = arg[1 /* Arg.ELAPSED */];
|
|
46
|
+
setting.pass = arg[3 /* Arg.PASS */];
|
|
47
|
+
setting.mark = arg[6 /* Arg.MARK */];
|
|
48
|
+
}
|
|
22
49
|
/** A gap as a `dt`: Infinity under reduced motion, and no more than `maxDt`. */
|
|
23
50
|
export function capped(gap) {
|
|
24
51
|
const cap = this.opts.maxDt;
|