@silentstatestudio/perseon 0.0.0-stage → 0.1.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 (47) hide show
  1. package/CHANGELOG.md +192 -0
  2. package/LICENSE.md +30 -0
  3. package/README.md +848 -2
  4. package/dist/authoring/index.cjs +213 -0
  5. package/dist/authoring/index.d.cts +866 -0
  6. package/dist/authoring/index.d.ts +866 -0
  7. package/dist/authoring/index.js +214 -0
  8. package/dist/authoring/index.js.map +1 -0
  9. package/dist/chunk-GDXCMDJ6.js +5462 -0
  10. package/dist/chunk-GDXCMDJ6.js.map +1 -0
  11. package/dist/chunk-ON4JV4BI.js +8432 -0
  12. package/dist/chunk-ON4JV4BI.js.map +1 -0
  13. package/dist/chunk-PT7F7TTB.cjs +8431 -0
  14. package/dist/chunk-Q2HLLGJ7.cjs +5461 -0
  15. package/dist/chunk-SVI6WUOB.js +1 -0
  16. package/dist/chunk-SVI6WUOB.js.map +1 -0
  17. package/dist/chunk-ZIMCQTYK.cjs +1 -0
  18. package/dist/colors-CUEeQ78V.d.cts +2247 -0
  19. package/dist/colors-pshUJaKB.d.ts +2247 -0
  20. package/dist/core/index.cjs +29 -0
  21. package/dist/core/index.d.cts +39 -0
  22. package/dist/core/index.d.ts +39 -0
  23. package/dist/core/index.js +30 -0
  24. package/dist/core/index.js.map +1 -0
  25. package/dist/index.cjs +29 -0
  26. package/dist/index.d.cts +3 -0
  27. package/dist/index.d.ts +3 -0
  28. package/dist/index.js +30 -0
  29. package/dist/index.js.map +1 -0
  30. package/dist/pixi-v7/index.cjs +513 -0
  31. package/dist/pixi-v7/index.d.cts +372 -0
  32. package/dist/pixi-v7/index.d.ts +372 -0
  33. package/dist/pixi-v7/index.js +514 -0
  34. package/dist/pixi-v7/index.js.map +1 -0
  35. package/dist/pixi-v8/index.cjs +608 -0
  36. package/dist/pixi-v8/index.d.cts +380 -0
  37. package/dist/pixi-v8/index.d.ts +380 -0
  38. package/dist/pixi-v8/index.js +609 -0
  39. package/dist/pixi-v8/index.js.map +1 -0
  40. package/dist/rendering-DeUo1BsK.d.cts +237 -0
  41. package/dist/rendering-DeUo1BsK.d.ts +237 -0
  42. package/dist/testing/index.cjs +159 -0
  43. package/dist/testing/index.d.cts +85 -0
  44. package/dist/testing/index.d.ts +85 -0
  45. package/dist/testing/index.js +160 -0
  46. package/dist/testing/index.js.map +1 -0
  47. package/package.json +148 -6
@@ -0,0 +1,866 @@
1
+ import { T as NumericDomain, aV as TextDomain, aA as ProbabilityCurvePresetId, i as CurveDefinition, az as ProbabilityCurvePreset, ac as ParticleLayerOptions, a2 as ParticleAnimationOptions, aw as PointValue } from '../colors-CUEeQ78V.cjs';
2
+ export { k as CustomParameterSampleScope, a_ as EMITTER_EVENT_TRIGGERS, r as EmitterEventTrigger, w as EventTrigger, a$ as OPTION_PATH_CATALOG, U as OptionNodeKind, b0 as OptionPathEntry, b1 as OptionScope, V as OptionStage, W as OptionStrategy, b2 as PARTICLE_EVENT_TRIGGERS, a5 as ParticleEventTrigger, b3 as findOptionPathEntry, b4 as isEmitterEventTrigger, b5 as isEventTrigger, b6 as isParticleEventTrigger, b7 as isValidEventName } from '../colors-CUEeQ78V.cjs';
3
+ import { P as ParticleBlendMode } from '../rendering-DeUo1BsK.cjs';
4
+
5
+ declare const MAX_PARAMETER_VALUE = 1000000;
6
+ declare const MIN_PARAMETER_VALUE = -1000000;
7
+ /**
8
+ * Shared upper bound for every user-facing name that travels through a config —
9
+ * point forces, event names, custom parameter labels, and (editor-side) emitter,
10
+ * particle and region names. 50 sits in the sweet spot for name-type inputs:
11
+ * comfortably above real-world names yet short enough not to truncate in a narrow
12
+ * layers panel. The single source of truth; the editor imports it rather than
13
+ * redeclaring its own.
14
+ */
15
+ declare const NAME_MAX_LENGTH = 50;
16
+ declare const TEXT_DOMAINS: {
17
+ name: {
18
+ minLength: number;
19
+ maxLength: number;
20
+ trim: true;
21
+ };
22
+ };
23
+ declare const COMMON_NUMERIC_DOMAINS: {
24
+ signedInteger: {
25
+ min: number;
26
+ max: number;
27
+ step: number;
28
+ decimals: number;
29
+ };
30
+ nonNegativeInteger: {
31
+ min: number;
32
+ max: number;
33
+ step: number;
34
+ decimals: number;
35
+ };
36
+ positiveInteger: {
37
+ min: number;
38
+ max: number;
39
+ step: number;
40
+ decimals: number;
41
+ };
42
+ signedDecimal: {
43
+ min: number;
44
+ max: number;
45
+ step: number;
46
+ decimals: number;
47
+ };
48
+ nonNegativeDecimal: {
49
+ min: number;
50
+ max: number;
51
+ step: number;
52
+ decimals: number;
53
+ };
54
+ normalized: {
55
+ min: number;
56
+ max: number;
57
+ step: number;
58
+ decimals: number;
59
+ };
60
+ normalizedPrecise: {
61
+ min: number;
62
+ max: number;
63
+ step: number;
64
+ decimals: number;
65
+ };
66
+ signedNormalizedPrecise: {
67
+ min: number;
68
+ max: number;
69
+ step: number;
70
+ decimals: number;
71
+ };
72
+ percentage: {
73
+ min: number;
74
+ max: number;
75
+ step: number;
76
+ decimals: number;
77
+ };
78
+ angleRadians: {
79
+ min: number;
80
+ max: number;
81
+ step: number;
82
+ decimals: number;
83
+ };
84
+ uint32: {
85
+ min: number;
86
+ max: number;
87
+ step: number;
88
+ decimals: number;
89
+ };
90
+ };
91
+ declare const CUSTOM_PARAMETER_DOMAINS: {
92
+ continuous: {
93
+ min: number;
94
+ max: number;
95
+ step: number;
96
+ decimals: number;
97
+ };
98
+ discrete: {
99
+ min: number;
100
+ max: number;
101
+ step: number;
102
+ decimals: number;
103
+ };
104
+ labelIndex: {
105
+ min: number;
106
+ max: number;
107
+ step: number;
108
+ decimals: number;
109
+ };
110
+ };
111
+ declare const PARTICLE_PARAMETER_DOMAINS: {
112
+ lifeProgress: {
113
+ min: number;
114
+ max: number;
115
+ step: number;
116
+ decimals: number;
117
+ };
118
+ lifetime: {
119
+ min: number;
120
+ max: number;
121
+ step: number;
122
+ decimals: number;
123
+ };
124
+ lifeElapsed: {
125
+ min: number;
126
+ max: number;
127
+ step: number;
128
+ decimals: number;
129
+ };
130
+ positionX: {
131
+ min: number;
132
+ max: number;
133
+ step: number;
134
+ decimals: number;
135
+ };
136
+ positionY: {
137
+ min: number;
138
+ max: number;
139
+ step: number;
140
+ decimals: number;
141
+ };
142
+ velocityX: {
143
+ min: number;
144
+ max: number;
145
+ step: number;
146
+ decimals: number;
147
+ };
148
+ velocityY: {
149
+ min: number;
150
+ max: number;
151
+ step: number;
152
+ decimals: number;
153
+ };
154
+ velocityMagnitude: {
155
+ min: number;
156
+ max: number;
157
+ step: number;
158
+ decimals: number;
159
+ };
160
+ velocityAngle: {
161
+ min: number;
162
+ max: number;
163
+ step: number;
164
+ decimals: number;
165
+ };
166
+ accelerationX: {
167
+ min: number;
168
+ max: number;
169
+ step: number;
170
+ decimals: number;
171
+ };
172
+ accelerationY: {
173
+ min: number;
174
+ max: number;
175
+ step: number;
176
+ decimals: number;
177
+ };
178
+ accelerationMagnitude: {
179
+ min: number;
180
+ max: number;
181
+ step: number;
182
+ decimals: number;
183
+ };
184
+ accelerationAngle: {
185
+ min: number;
186
+ max: number;
187
+ step: number;
188
+ decimals: number;
189
+ };
190
+ scaleX: {
191
+ min: number;
192
+ max: number;
193
+ step: number;
194
+ decimals: number;
195
+ };
196
+ scaleY: {
197
+ min: number;
198
+ max: number;
199
+ step: number;
200
+ decimals: number;
201
+ };
202
+ scaleVelocityX: {
203
+ min: number;
204
+ max: number;
205
+ step: number;
206
+ decimals: number;
207
+ };
208
+ scaleVelocityY: {
209
+ min: number;
210
+ max: number;
211
+ step: number;
212
+ decimals: number;
213
+ };
214
+ scaleAccelerationX: {
215
+ min: number;
216
+ max: number;
217
+ step: number;
218
+ decimals: number;
219
+ };
220
+ scaleAccelerationY: {
221
+ min: number;
222
+ max: number;
223
+ step: number;
224
+ decimals: number;
225
+ };
226
+ rotation: {
227
+ min: number;
228
+ max: number;
229
+ step: number;
230
+ decimals: number;
231
+ };
232
+ rotationVelocity: {
233
+ min: number;
234
+ max: number;
235
+ step: number;
236
+ decimals: number;
237
+ };
238
+ rotationAcceleration: {
239
+ min: number;
240
+ max: number;
241
+ step: number;
242
+ decimals: number;
243
+ };
244
+ alpha: {
245
+ min: number;
246
+ max: number;
247
+ step: number;
248
+ decimals: number;
249
+ };
250
+ alphaVelocity: {
251
+ min: number;
252
+ max: number;
253
+ step: number;
254
+ decimals: number;
255
+ };
256
+ alphaAcceleration: {
257
+ min: number;
258
+ max: number;
259
+ step: number;
260
+ decimals: number;
261
+ };
262
+ };
263
+ declare const PARTICLE_OPTION_DOMAINS: {
264
+ lifetime: {
265
+ min: number;
266
+ max: number;
267
+ step: number;
268
+ decimals: number;
269
+ };
270
+ gravityFactor: {
271
+ min: number;
272
+ max: number;
273
+ step: number;
274
+ decimals: number;
275
+ };
276
+ dampingFactor: {
277
+ min: number;
278
+ max: number;
279
+ step: number;
280
+ decimals: number;
281
+ };
282
+ windFactor: {
283
+ min: number;
284
+ max: number;
285
+ step: number;
286
+ decimals: number;
287
+ };
288
+ pointForceFactor: {
289
+ min: number;
290
+ max: number;
291
+ step: number;
292
+ decimals: number;
293
+ };
294
+ };
295
+ declare const POINT_FORCE_DOMAINS: {
296
+ strength: {
297
+ min: number;
298
+ max: number;
299
+ step: number;
300
+ decimals: number;
301
+ };
302
+ radius: {
303
+ min: number;
304
+ max: number;
305
+ step: number;
306
+ decimals: number;
307
+ };
308
+ positionX: {
309
+ min: number;
310
+ max: number;
311
+ step: number;
312
+ decimals: number;
313
+ };
314
+ positionY: {
315
+ min: number;
316
+ max: number;
317
+ step: number;
318
+ decimals: number;
319
+ };
320
+ };
321
+ declare const EMITTER_PARAMETER_DOMAINS: {
322
+ gravity: {
323
+ min: number;
324
+ max: number;
325
+ step: number;
326
+ decimals: number;
327
+ };
328
+ damping: {
329
+ min: number;
330
+ max: number;
331
+ step: number;
332
+ decimals: number;
333
+ };
334
+ windX: {
335
+ min: number;
336
+ max: number;
337
+ step: number;
338
+ decimals: number;
339
+ };
340
+ windY: {
341
+ min: number;
342
+ max: number;
343
+ step: number;
344
+ decimals: number;
345
+ };
346
+ windMagnitude: {
347
+ min: number;
348
+ max: number;
349
+ step: number;
350
+ decimals: number;
351
+ };
352
+ windAngle: {
353
+ min: number;
354
+ max: number;
355
+ step: number;
356
+ decimals: number;
357
+ };
358
+ spawnRate: {
359
+ min: number;
360
+ max: number;
361
+ step: number;
362
+ decimals: number;
363
+ };
364
+ spawnCount: {
365
+ min: number;
366
+ max: number;
367
+ step: number;
368
+ decimals: number;
369
+ };
370
+ spawnDuration: {
371
+ min: number;
372
+ max: number;
373
+ step: number;
374
+ decimals: number;
375
+ };
376
+ numberOfParticles: {
377
+ min: number;
378
+ max: number;
379
+ step: number;
380
+ decimals: number;
381
+ };
382
+ };
383
+ declare const EMITTER_OPTION_DOMAINS: {
384
+ maxAlive: {
385
+ min: number;
386
+ max: number;
387
+ step: number;
388
+ decimals: number;
389
+ };
390
+ initialPoolSize: {
391
+ min: number;
392
+ max: number;
393
+ step: number;
394
+ decimals: number;
395
+ };
396
+ simulateTime: {
397
+ min: number;
398
+ max: number;
399
+ step: number;
400
+ decimals: number;
401
+ };
402
+ ensureAliveCount: {
403
+ min: number;
404
+ max: number;
405
+ step: number;
406
+ decimals: number;
407
+ };
408
+ startDelay: {
409
+ min: number;
410
+ max: number;
411
+ step: number;
412
+ decimals: number;
413
+ };
414
+ repeat: {
415
+ min: number;
416
+ max: number;
417
+ step: number;
418
+ decimals: number;
419
+ };
420
+ repeatInterval: {
421
+ min: number;
422
+ max: number;
423
+ step: number;
424
+ decimals: number;
425
+ };
426
+ seed: {
427
+ min: number;
428
+ max: number;
429
+ step: number;
430
+ decimals: number;
431
+ };
432
+ maxUpdateRate: {
433
+ min: number;
434
+ max: number;
435
+ step: number;
436
+ decimals: number;
437
+ };
438
+ warmUpMaxTicks: {
439
+ min: number;
440
+ max: number;
441
+ step: number;
442
+ decimals: number;
443
+ };
444
+ };
445
+ declare const PARAMETER_OPTION_DOMAINS: {
446
+ randomListWeight: {
447
+ min: number;
448
+ max: number;
449
+ step: number;
450
+ decimals: number;
451
+ };
452
+ curveAxis: {
453
+ min: number;
454
+ max: number;
455
+ step: number;
456
+ decimals: number;
457
+ };
458
+ curveSegmentBend: {
459
+ min: number;
460
+ max: number;
461
+ step: number;
462
+ decimals: number;
463
+ };
464
+ colorStopPosition: {
465
+ min: number;
466
+ max: number;
467
+ step: number;
468
+ decimals: number;
469
+ };
470
+ areaCoordinate: {
471
+ min: number;
472
+ max: number;
473
+ step: number;
474
+ decimals: number;
475
+ };
476
+ areaSize: {
477
+ min: number;
478
+ max: number;
479
+ step: number;
480
+ decimals: number;
481
+ };
482
+ areaRotation: {
483
+ min: number;
484
+ max: number;
485
+ step: number;
486
+ decimals: number;
487
+ };
488
+ };
489
+ declare const MODIFIER_DOMAINS: {
490
+ strength: {
491
+ min: number;
492
+ max: number;
493
+ step: number;
494
+ decimals: number;
495
+ };
496
+ };
497
+ declare const MODULATOR_DOMAINS: {
498
+ frequency: {
499
+ min: number;
500
+ max: number;
501
+ step: number;
502
+ decimals: number;
503
+ };
504
+ amplitude: {
505
+ min: number;
506
+ max: number;
507
+ step: number;
508
+ decimals: number;
509
+ };
510
+ offset: {
511
+ min: number;
512
+ max: number;
513
+ step: number;
514
+ decimals: number;
515
+ };
516
+ phase: {
517
+ min: number;
518
+ max: number;
519
+ step: number;
520
+ decimals: number;
521
+ };
522
+ };
523
+ declare const SPRITE_ANIMATION_DOMAINS: {
524
+ animationFPS: {
525
+ min: number;
526
+ max: number;
527
+ step: number;
528
+ decimals: number;
529
+ };
530
+ startFrame: {
531
+ min: number;
532
+ max: number;
533
+ step: number;
534
+ decimals: number;
535
+ };
536
+ };
537
+
538
+ /**
539
+ * Single source of truth for particle blend modes.
540
+ *
541
+ * The `ParticleBlendMode` type is the union of all valid blend mode ids. This
542
+ * catalog is the single source of truth for the set of valid modes; adapters exhaustively map these in their backend
543
+ * implementations (pixi-v8 / pixi-v7).
544
+ *
545
+ * Blend is a container-level property (the GPU sets it per draw call, not per
546
+ * instance); the engine renders one container per Particle Layer, so each layer
547
+ * carries a fixed mode from this catalog.
548
+ *
549
+ * What a mode COSTS, and whether a backend can honor it at all, is deliberately
550
+ * not here. It is not a property of the mode: `overlay` is a shader pass on the
551
+ * v8 adapter and plain `normal` on the v7 one, and `subtract` is the reverse —
552
+ * fixed-function on v7, a shader pass on v8. A renderer answers that about
553
+ * itself through `IRendererCapabilities.blendModeSupport`.
554
+ */
555
+ /** Ordered catalog. Order is the display order; the cheap, universal modes first. */
556
+ declare const BLEND_MODE_CATALOG: readonly [{
557
+ readonly id: "normal";
558
+ }, {
559
+ readonly id: "add";
560
+ }, {
561
+ readonly id: "screen";
562
+ }, {
563
+ readonly id: "multiply";
564
+ }, {
565
+ readonly id: "subtract";
566
+ }, {
567
+ readonly id: "overlay";
568
+ }, {
569
+ readonly id: "darken";
570
+ }, {
571
+ readonly id: "lighten";
572
+ }, {
573
+ readonly id: "color-dodge";
574
+ }, {
575
+ readonly id: "color-burn";
576
+ }, {
577
+ readonly id: "hard-light";
578
+ }, {
579
+ readonly id: "soft-light";
580
+ }, {
581
+ readonly id: "difference";
582
+ }, {
583
+ readonly id: "exclusion";
584
+ }];
585
+ /** Default applied when a layer omits a blend mode. */
586
+ declare const DEFAULT_BLEND_MODE: ParticleBlendMode;
587
+ /** Narrows an unknown value to a catalog blend mode (used to validate configs). */
588
+ declare const isParticleBlendMode: (value: unknown) => value is ParticleBlendMode;
589
+
590
+ /** `timeSource` value that drives a modulator with the engine's clock. */
591
+ declare const MODULATOR_TIME_ELAPSED_SOURCE = "timeElapsed";
592
+
593
+ /**
594
+ * Version of the animation format this engine reads (`formatVersion`). A file
595
+ * without the field, or with another value, is rejected at load naming both.
596
+ */
597
+ declare const ANIMATION_FORMAT_VERSION = 2;
598
+
599
+ declare const COLOR_DOMAIN: NumericDomain;
600
+ /**
601
+ * Coerce a name-like string into its `TextDomain`: trim (when the domain asks)
602
+ * then clamp to `maxLength`. This is the lenient counterpart to the strict name check, which throws —
603
+ * it always returns a conforming value rather than throwing, so hosts can pass
604
+ * raw user input straight through. Its output always passes that check for the
605
+ * same domain.
606
+ */
607
+ declare const sanitizeName: (value: string, domain?: TextDomain) => string;
608
+
609
+ /**
610
+ * Paths a Linked parameter may read, per scope. Each scope lists only the
611
+ * fields it owns; a wider context (an emitter, a particle) also sees the outer
612
+ * scopes. Every path resolves to a number.
613
+ */
614
+ declare const LINKED_SOURCE_CATALOG: {
615
+ readonly playback: readonly ["gravity", "damping", "windMagnitude", "windAngle"];
616
+ readonly emitter: readonly ["spawnRate", "spawnCount", "spawnDuration"];
617
+ readonly particle: readonly ["lifeProgress", "lifetime", "lifeElapsed", "positionX", "positionY", "velocityX", "velocityY", "velocityMagnitude", "velocityAngle", "accelerationX", "accelerationY", "accelerationMagnitude", "accelerationAngle", "scaleX", "scaleY", "scaleVelocityX", "scaleVelocityY", "scaleAccelerationX", "scaleAccelerationY", "rotation", "rotationVelocity", "rotationAcceleration", "alpha", "alphaVelocity", "alphaAcceleration"];
618
+ };
619
+
620
+ declare const DEFAULT_PROBABILITY_CURVE_PRESET_ID: ProbabilityCurvePresetId;
621
+ declare const PROBABILITY_CURVE_PRESETS: readonly [{
622
+ readonly id: "uniform";
623
+ readonly label: "Uniform";
624
+ readonly description: "Equal probability across the full range.";
625
+ readonly iconKey: "line-horizontal";
626
+ readonly curve: {
627
+ readonly points: [{
628
+ readonly x: 0;
629
+ readonly y: 1;
630
+ }, {
631
+ readonly x: 1;
632
+ readonly y: 1;
633
+ }];
634
+ readonly segmentBends: [0];
635
+ };
636
+ }, {
637
+ readonly id: "lowBias";
638
+ readonly label: "Low Bias";
639
+ readonly description: "Higher probability near the minimum side.";
640
+ readonly iconKey: "slope-down";
641
+ readonly curve: {
642
+ readonly points: [{
643
+ readonly x: 0;
644
+ readonly y: 1;
645
+ }, {
646
+ readonly x: 1;
647
+ readonly y: 0.15;
648
+ }];
649
+ readonly segmentBends: [0];
650
+ };
651
+ }, {
652
+ readonly id: "highBias";
653
+ readonly label: "High Bias";
654
+ readonly description: "Higher probability near the maximum side.";
655
+ readonly iconKey: "slope-up";
656
+ readonly curve: {
657
+ readonly points: [{
658
+ readonly x: 0;
659
+ readonly y: 0.15;
660
+ }, {
661
+ readonly x: 1;
662
+ readonly y: 1;
663
+ }];
664
+ readonly segmentBends: [0];
665
+ };
666
+ }, {
667
+ readonly id: "centerBias";
668
+ readonly label: "Center Bias";
669
+ readonly description: "Smooth preference for the middle of the range.";
670
+ readonly iconKey: "peak-center";
671
+ readonly curve: {
672
+ readonly points: [{
673
+ readonly x: 0;
674
+ readonly y: 0.12;
675
+ }, {
676
+ readonly x: 0.5;
677
+ readonly y: 1;
678
+ }, {
679
+ readonly x: 1;
680
+ readonly y: 0.12;
681
+ }];
682
+ readonly segmentBends: [0.25, 0.25];
683
+ };
684
+ }, {
685
+ readonly id: "edgeBias";
686
+ readonly label: "Edge Bias";
687
+ readonly description: "Higher probability near both edges.";
688
+ readonly iconKey: "peak-edges";
689
+ readonly curve: {
690
+ readonly points: [{
691
+ readonly x: 0;
692
+ readonly y: 1;
693
+ }, {
694
+ readonly x: 0.5;
695
+ readonly y: 0.12;
696
+ }, {
697
+ readonly x: 1;
698
+ readonly y: 1;
699
+ }];
700
+ readonly segmentBends: [-0.25, -0.25];
701
+ };
702
+ }, {
703
+ readonly id: "bell";
704
+ readonly label: "Bell";
705
+ readonly description: "Gaussian-like central bell curve.";
706
+ readonly iconKey: "bell";
707
+ readonly curve: {
708
+ readonly points: [{
709
+ readonly x: 0;
710
+ readonly y: 0.04;
711
+ }, {
712
+ readonly x: 0.25;
713
+ readonly y: 0.42;
714
+ }, {
715
+ readonly x: 0.5;
716
+ readonly y: 1;
717
+ }, {
718
+ readonly x: 0.75;
719
+ readonly y: 0.42;
720
+ }, {
721
+ readonly x: 1;
722
+ readonly y: 0.04;
723
+ }];
724
+ readonly segmentBends: [-0.45, 0.35, 0.35, -0.45];
725
+ };
726
+ }, {
727
+ readonly id: "doublePeak";
728
+ readonly label: "Double Peak";
729
+ readonly description: "Two smooth internal probability peaks.";
730
+ readonly iconKey: "double-peak";
731
+ readonly curve: {
732
+ readonly points: [{
733
+ readonly x: 0;
734
+ readonly y: 0.12;
735
+ }, {
736
+ readonly x: 0.25;
737
+ readonly y: 1;
738
+ }, {
739
+ readonly x: 0.5;
740
+ readonly y: 0.18;
741
+ }, {
742
+ readonly x: 0.75;
743
+ readonly y: 1;
744
+ }, {
745
+ readonly x: 1;
746
+ readonly y: 0.12;
747
+ }];
748
+ readonly segmentBends: [0.22, 0.18, 0.18, 0.22];
749
+ };
750
+ }];
751
+ declare const PROBABILITY_CURVE_PRESET_OPTIONS: {
752
+ value: "uniform" | "lowBias" | "highBias" | "centerBias" | "edgeBias" | "bell" | "doublePeak";
753
+ label: "Uniform" | "Low Bias" | "High Bias" | "Center Bias" | "Edge Bias" | "Bell" | "Double Peak";
754
+ description: "Equal probability across the full range." | "Higher probability near the minimum side." | "Higher probability near the maximum side." | "Smooth preference for the middle of the range." | "Higher probability near both edges." | "Gaussian-like central bell curve." | "Two smooth internal probability peaks.";
755
+ }[];
756
+ declare const getProbabilityCurvePreset: (presetId: ProbabilityCurvePresetId) => ProbabilityCurvePreset;
757
+ declare const createProbabilityCurveFromPreset: (presetId?: ProbabilityCurvePresetId, xDomain?: Pick<NumericDomain, "min" | "max">) => CurveDefinition;
758
+
759
+ /**
760
+ * Type guards for parameter definitions. Used at runtime to discriminate the
761
+ * union variants of SpawnNumber / SpawnPoint / SpawnVector / SpawnPosition.
762
+ *
763
+ * Naming note: `isPointValue` / `isVectorValue` also act as the structural
764
+ * discriminator for the "Separated" variants `{x: SpawnNumber, y: SpawnNumber}`
765
+ * and `{angle: SpawnNumber, magnitude: SpawnNumber}` — those unions have the
766
+ * same object shape at runtime, since `SpawnNumber` extends `number`.
767
+ */
768
+ declare class ParameterTypeChecker {
769
+ static isObject(object: unknown): boolean;
770
+ static isPointValue(object: unknown): boolean;
771
+ static isVectorValue(object: unknown): boolean;
772
+ static isRandomValueRange(object: unknown): boolean;
773
+ static isRectangleArea(object: unknown): boolean;
774
+ static isCircleArea(object: unknown): boolean;
775
+ static isRingArea(object: unknown): boolean;
776
+ static isCapsuleArea(object: unknown): boolean;
777
+ static isPolygonArea(object: unknown): boolean;
778
+ static isRandomValueList(object: unknown): boolean;
779
+ static isParameterLinkRelation(object: unknown): boolean;
780
+ static isColorGradientDefinition(object: unknown): boolean;
781
+ /**
782
+ * A spawn-time random pick over a gradient: has `stops` but NO
783
+ * `sourceParameterId` (the discriminator vs `ColorGradientDefinition`, which
784
+ * always carries a source it re-samples every frame). Must be tested BEFORE
785
+ * `isColorGradientDefinition` since both shapes carry `stops`.
786
+ */
787
+ static isColorRandomRange(object: unknown): boolean;
788
+ /**
789
+ * A numeric value wrapped with a modifier stack: `{ base, modifiers[] }`.
790
+ * Detected before the bare-SpawnNumber variants so the compiler can peel the
791
+ * wrapper off and compile the base + stack.
792
+ */
793
+ static isModulatedValue(object: unknown): boolean;
794
+ static isPositiveNumber(value: unknown): boolean;
795
+ static isSpriteAnimationOptions(object: unknown): boolean;
796
+ /**
797
+ * Recognises any variant of SpawnNumber: plain number, RandomValueRange,
798
+ * RandomValueList<number>, or ParameterLinkRelation. Used by Scale's dual
799
+ * `SpawnNumber | SpawnPoint` discrimination — must NOT match
800
+ * `{x, y}` (Separated point) nor `RandomValueList<PointValue>`.
801
+ */
802
+ static isSpawnNumber(value: unknown): boolean;
803
+ }
804
+
805
+ /**
806
+ * Every texture id an animation will ask its renderer to resolve, in declaration
807
+ * order and without duplicates.
808
+ *
809
+ * This exists so a host can answer the one question an animation file cannot answer
810
+ * on its own: are the textures it names actually available? Ids are resolved
811
+ * against whatever the renderer has been given — for the Pixi adapters, the
812
+ * frames of a loaded atlas — and a missing one resolves to an empty texture
813
+ * *silently*. The animation then runs perfectly and draws nothing, which is the
814
+ * hardest failure in this pipeline to diagnose by eye.
815
+ *
816
+ * Walking the options tree belongs here rather than in each host: the shape of
817
+ * `particles` (one layer or a weighted list) and of `texture` (an id or a sprite
818
+ * animation) is the library's own vocabulary, and a host re-deriving it would be
819
+ * a second definition to keep in sync.
820
+ */
821
+ declare const collectTextureSources: (options: ParticleAnimationOptions) => string[];
822
+ /**
823
+ * The texture ids ONE Particle Layer names, in declaration order and without
824
+ * duplicates.
825
+ *
826
+ * A layer draws through a single render group, and a render group draws from a
827
+ * single texture source — so this is also the set that has to be packed
828
+ * together, whatever else the animation names.
829
+ */
830
+ declare const collectLayerTextureSources: (layer: ParticleLayerOptions) => string[];
831
+ /**
832
+ * The same ids as {@link collectTextureSources}, kept GROUPED by the layer that
833
+ * names them, in declaration order.
834
+ *
835
+ * A host packing those ids into atlases needs the grouping and not the flat
836
+ * set: every id one layer names has to end up in the same atlas, while two
837
+ * layers are free to come from different ones. Answering that from the flat set
838
+ * is impossible, and re-deriving the grouping outside the library would be a
839
+ * second definition of what `particles` and `texture` are shaped like.
840
+ */
841
+ declare const collectTextureSourcesByLayer: (options: ParticleAnimationOptions) => string[][];
842
+ /** Ids the animation names that `isAvailable` does not know about. */
843
+ declare const findMissingTextureSources: (options: ParticleAnimationOptions, isAvailable: (source: string) => boolean) => string[];
844
+
845
+ type CompiledCurveSegment = {
846
+ start: PointValue;
847
+ end: PointValue;
848
+ midpoint: PointValue;
849
+ leftControl: PointValue;
850
+ rightControl: PointValue;
851
+ bend: number;
852
+ leftXSpan: number;
853
+ rightXSpan: number;
854
+ segmentXSpan: number;
855
+ };
856
+ declare const compileCurveSegments: (curve: CurveDefinition) => CompiledCurveSegment[];
857
+
858
+ /**
859
+ * The shortest slice, in seconds, the warm-up steps the animation by. The warm-up runs in slices of the
860
+ * clock's shortest interval, which at a `maxUpdateRate` with no limit is a microsecond: a second of
861
+ * `simulateTime` would be a million ticks inside `start()`. At or under 1000 Hz the slices are the clock's own;
862
+ * above it they are this long, and the same simulated time is covered in fewer ticks.
863
+ */
864
+ declare const WARM_UP_MIN_STEP_SECONDS: number;
865
+
866
+ export { ANIMATION_FORMAT_VERSION, BLEND_MODE_CATALOG, COLOR_DOMAIN, COMMON_NUMERIC_DOMAINS, CUSTOM_PARAMETER_DOMAINS, DEFAULT_BLEND_MODE, DEFAULT_PROBABILITY_CURVE_PRESET_ID, EMITTER_OPTION_DOMAINS, EMITTER_PARAMETER_DOMAINS, LINKED_SOURCE_CATALOG, MAX_PARAMETER_VALUE, MIN_PARAMETER_VALUE, MODIFIER_DOMAINS, MODULATOR_DOMAINS, MODULATOR_TIME_ELAPSED_SOURCE, NAME_MAX_LENGTH, PARAMETER_OPTION_DOMAINS, PARTICLE_OPTION_DOMAINS, PARTICLE_PARAMETER_DOMAINS, POINT_FORCE_DOMAINS, PROBABILITY_CURVE_PRESETS, PROBABILITY_CURVE_PRESET_OPTIONS, ParameterTypeChecker, SPRITE_ANIMATION_DOMAINS, TEXT_DOMAINS, WARM_UP_MIN_STEP_SECONDS, collectLayerTextureSources, collectTextureSources, collectTextureSourcesByLayer, compileCurveSegments, createProbabilityCurveFromPreset, findMissingTextureSources, getProbabilityCurvePreset, isParticleBlendMode, sanitizeName };