@pixerate/editor 0.229.0 → 0.231.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 (73) hide show
  1. package/dist/animation-editor/camera-tools.d.cts +10 -0
  2. package/dist/animation-editor/camera-tools.d.ts +10 -0
  3. package/dist/animation-editor/camera.d.cts +67 -0
  4. package/dist/animation-editor/camera.d.ts +67 -0
  5. package/dist/animation-editor/compile.d.cts +4 -0
  6. package/dist/animation-editor/compile.d.ts +4 -0
  7. package/dist/animation-editor/controller.d.cts +34 -2
  8. package/dist/animation-editor/controller.d.ts +34 -2
  9. package/dist/animation-editor/effect-tools.d.cts +2 -1
  10. package/dist/animation-editor/effect-tools.d.ts +2 -1
  11. package/dist/animation-editor/evaluate.d.cts +9 -0
  12. package/dist/animation-editor/evaluate.d.ts +9 -0
  13. package/dist/animation-editor/flair.d.cts +8 -0
  14. package/dist/animation-editor/flair.d.ts +8 -0
  15. package/dist/animation-editor/index.cjs +603 -217
  16. package/dist/animation-editor/index.d.cts +2 -0
  17. package/dist/animation-editor/index.d.ts +2 -0
  18. package/dist/animation-editor/index.js +454 -68
  19. package/dist/animation-editor/issues.d.cts +16 -0
  20. package/dist/animation-editor/issues.d.ts +16 -0
  21. package/dist/animation-editor/tools.d.cts +1 -1
  22. package/dist/animation-editor/tools.d.ts +1 -1
  23. package/dist/animation-editor/types.d.cts +21 -3
  24. package/dist/animation-editor/types.d.ts +21 -3
  25. package/dist/canvas/index.cjs +7 -7
  26. package/dist/canvas/index.js +1 -1
  27. package/dist/{chunk-IGPEBXUD.cjs → chunk-5T3H7CGG.cjs} +21 -11
  28. package/dist/{chunk-K5GXW5TR.cjs → chunk-C73U5UI3.cjs} +14 -14
  29. package/dist/{chunk-LPTFDCJO.js → chunk-CSM5T6SE.js} +14 -4
  30. package/dist/{chunk-EBDZWIOP.cjs → chunk-ERJA5CGT.cjs} +5 -1
  31. package/dist/{chunk-5MQOBTNP.cjs → chunk-OPSK22DL.cjs} +80 -9
  32. package/dist/{chunk-PB6JV62G.js → chunk-SBPGIZQN.js} +1 -1
  33. package/dist/{chunk-UGYUGZE2.js → chunk-TCZ2J7PR.js} +71 -0
  34. package/dist/{chunk-W4KFNAWC.js → chunk-TYCJGFCF.js} +5 -1
  35. package/dist/effects/helpers.d.cts +35 -1
  36. package/dist/effects/helpers.d.ts +35 -1
  37. package/dist/effects/index.cjs +60 -44
  38. package/dist/effects/index.js +18 -2
  39. package/dist/effects/types.d.cts +15 -0
  40. package/dist/effects/types.d.ts +15 -0
  41. package/dist/image-editor/index.cjs +13 -13
  42. package/dist/image-editor/index.js +1 -1
  43. package/dist/paint-editor/index.cjs +7 -7
  44. package/dist/paint-editor/index.js +2 -2
  45. package/dist/vector/index.cjs +6 -6
  46. package/dist/vector/index.js +1 -1
  47. package/dist/video-editor/camera-tools.d.cts +10 -0
  48. package/dist/video-editor/camera-tools.d.ts +10 -0
  49. package/dist/video-editor/camera.d.cts +47 -0
  50. package/dist/video-editor/camera.d.ts +47 -0
  51. package/dist/video-editor/check.d.cts +1 -1
  52. package/dist/video-editor/check.d.ts +1 -1
  53. package/dist/video-editor/controller.d.cts +37 -2
  54. package/dist/video-editor/controller.d.ts +37 -2
  55. package/dist/video-editor/effect-tools.d.cts +2 -1
  56. package/dist/video-editor/effect-tools.d.ts +2 -1
  57. package/dist/video-editor/index.cjs +705 -390
  58. package/dist/video-editor/index.d.cts +2 -0
  59. package/dist/video-editor/index.d.ts +2 -0
  60. package/dist/video-editor/index.js +334 -19
  61. package/dist/video-editor/keyframes.d.cts +10 -3
  62. package/dist/video-editor/keyframes.d.ts +10 -3
  63. package/dist/video-editor/parse.d.cts +5 -3
  64. package/dist/video-editor/parse.d.ts +5 -3
  65. package/dist/video-editor/tools.d.cts +18 -0
  66. package/dist/video-editor/tools.d.ts +18 -0
  67. package/dist/video-editor/types.d.cts +37 -1
  68. package/dist/video-editor/types.d.ts +37 -1
  69. package/package.json +1 -1
  70. package/skills/pixerate-animation-editor/SKILL.md +28 -1
  71. package/skills/pixerate-animation-motion-graphics/SKILL.md +3 -0
  72. package/skills/pixerate-video-editor/SKILL.md +16 -1
  73. package/skills/pixerate-video-montage/SKILL.md +2 -1
@@ -1,8 +1,8 @@
1
1
  import { type VideoAnimatable, type VideoKeyframes } from './keyframes.cjs';
2
- import { type VideoClipMask, type VideoAsset, type VideoAssetProxy, type VideoClip, type VideoClipEffect, type VideoEffectRef, type VideoEffectValues, type VideoClipAnimation, type VideoGrade, type VideoGradeLut, type VideoMarker, type VideoProject, type VideoSequence, type VideoTrack, type VideoTranscriptWord, type VideoTransform, type VideoTransition } from './types.cjs';
2
+ import { type VideoClipMask, type VideoClipCamera, type VideoAsset, type VideoAssetProxy, type VideoClip, type VideoClipEffect, type VideoEffectRef, type VideoEffectValues, type VideoClipAnimation, type VideoGrade, type VideoGradeLut, type VideoMarker, type VideoProject, type VideoSequence, type VideoTrack, type VideoTranscriptWord, type VideoTransform, type VideoTransition } from './types.cjs';
3
3
  /**
4
- * Keyframes `{ keys: [{ t, v, ease }] }`: at least one key, in strictly increasing time (clip-relative
5
- * ms), each value within `range`.
4
+ * Keyframes `{ keys: [{ t, v, ease }] }`: at least one key, in time order (clip-relative ms; two
5
+ * at one time make a jump), each value within `range`.
6
6
  */
7
7
  export declare function parseVideoKeyframes(v: unknown, path: string, { min, max }?: {
8
8
  min?: number;
@@ -35,6 +35,8 @@ export declare function parseVideoClipEffects(v: unknown, path: string): VideoCl
35
35
  export declare function parseVideoTranscriptWords(v: unknown, path: string): VideoTranscriptWord[] | undefined;
36
36
  export declare function parseVideoAsset(v: unknown, path?: string): VideoAsset;
37
37
  export declare function parseVideoAssetProxies(v: unknown, path: string): VideoAssetProxy[] | undefined;
38
+ /** A clip's camera moves `{ in, during, from, framing, base }` (see `VideoClipCamera`). */
39
+ export declare function parseVideoClipCamera(v: unknown, path: string): VideoClipCamera | undefined;
38
40
  export declare function parseVideoClip(v: unknown, path?: string): VideoClip;
39
41
  export declare function parseVideoTrack(v: unknown, path?: string): VideoTrack;
40
42
  /** A nested sequence `{ id, name, tracks }` (see `VideoSequence`). */
@@ -1,8 +1,8 @@
1
1
  import { type VideoAnimatable, type VideoKeyframes } from './keyframes.js';
2
- import { type VideoClipMask, type VideoAsset, type VideoAssetProxy, type VideoClip, type VideoClipEffect, type VideoEffectRef, type VideoEffectValues, type VideoClipAnimation, type VideoGrade, type VideoGradeLut, type VideoMarker, type VideoProject, type VideoSequence, type VideoTrack, type VideoTranscriptWord, type VideoTransform, type VideoTransition } from './types.js';
2
+ import { type VideoClipMask, type VideoClipCamera, type VideoAsset, type VideoAssetProxy, type VideoClip, type VideoClipEffect, type VideoEffectRef, type VideoEffectValues, type VideoClipAnimation, type VideoGrade, type VideoGradeLut, type VideoMarker, type VideoProject, type VideoSequence, type VideoTrack, type VideoTranscriptWord, type VideoTransform, type VideoTransition } from './types.js';
3
3
  /**
4
- * Keyframes `{ keys: [{ t, v, ease }] }`: at least one key, in strictly increasing time (clip-relative
5
- * ms), each value within `range`.
4
+ * Keyframes `{ keys: [{ t, v, ease }] }`: at least one key, in time order (clip-relative ms; two
5
+ * at one time make a jump), each value within `range`.
6
6
  */
7
7
  export declare function parseVideoKeyframes(v: unknown, path: string, { min, max }?: {
8
8
  min?: number;
@@ -35,6 +35,8 @@ export declare function parseVideoClipEffects(v: unknown, path: string): VideoCl
35
35
  export declare function parseVideoTranscriptWords(v: unknown, path: string): VideoTranscriptWord[] | undefined;
36
36
  export declare function parseVideoAsset(v: unknown, path?: string): VideoAsset;
37
37
  export declare function parseVideoAssetProxies(v: unknown, path: string): VideoAssetProxy[] | undefined;
38
+ /** A clip's camera moves `{ in, during, from, framing, base }` (see `VideoClipCamera`). */
39
+ export declare function parseVideoClipCamera(v: unknown, path: string): VideoClipCamera | undefined;
38
40
  export declare function parseVideoClip(v: unknown, path?: string): VideoClip;
39
41
  export declare function parseVideoTrack(v: unknown, path?: string): VideoTrack;
40
42
  /** A nested sequence `{ id, name, tracks }` (see `VideoSequence`). */
@@ -69,6 +69,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
69
69
  transition?: import("./types.cjs").VideoTransition;
70
70
  effects?: import("./types.cjs").VideoClipEffect[];
71
71
  mask?: import("./types.cjs").VideoClipMask;
72
+ camera?: import("./types.cjs").VideoClipCamera;
72
73
  } | {
73
74
  source?: {
74
75
  in: number;
@@ -98,6 +99,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
98
99
  transition?: import("./types.cjs").VideoTransition;
99
100
  effects?: import("./types.cjs").VideoClipEffect[];
100
101
  mask?: import("./types.cjs").VideoClipMask;
102
+ camera?: import("./types.cjs").VideoClipCamera;
101
103
  } | {
102
104
  source?: {
103
105
  in: number;
@@ -122,6 +124,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
122
124
  transition?: import("./types.cjs").VideoTransition;
123
125
  effects?: import("./types.cjs").VideoClipEffect[];
124
126
  mask?: import("./types.cjs").VideoClipMask;
127
+ camera?: import("./types.cjs").VideoClipCamera;
125
128
  } | {
126
129
  source?: {
127
130
  in: number;
@@ -151,6 +154,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
151
154
  transition?: import("./types.cjs").VideoTransition;
152
155
  effects?: import("./types.cjs").VideoClipEffect[];
153
156
  mask?: import("./types.cjs").VideoClipMask;
157
+ camera?: import("./types.cjs").VideoClipCamera;
154
158
  } | {
155
159
  source?: {
156
160
  in: number;
@@ -174,6 +178,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
174
178
  transition?: import("./types.cjs").VideoTransition;
175
179
  effects?: import("./types.cjs").VideoClipEffect[];
176
180
  mask?: import("./types.cjs").VideoClipMask;
181
+ camera?: import("./types.cjs").VideoClipCamera;
177
182
  effect: string;
178
183
  provider?: string;
179
184
  values?: import("./types.cjs").VideoEffectValues;
@@ -202,6 +207,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
202
207
  transition?: import("./types.cjs").VideoTransition;
203
208
  effects?: import("./types.cjs").VideoClipEffect[];
204
209
  mask?: import("./types.cjs").VideoClipMask;
210
+ camera?: import("./types.cjs").VideoClipCamera;
205
211
  })[];
206
212
  volume?: number | undefined;
207
213
  syncLocked?: boolean | undefined;
@@ -286,6 +292,7 @@ export declare function describeVideoProject(project: VideoProject): {
286
292
  transition?: import("./types.cjs").VideoTransition;
287
293
  effects?: import("./types.cjs").VideoClipEffect[];
288
294
  mask?: import("./types.cjs").VideoClipMask;
295
+ camera?: import("./types.cjs").VideoClipCamera;
289
296
  } | {
290
297
  source?: {
291
298
  in: number;
@@ -315,6 +322,7 @@ export declare function describeVideoProject(project: VideoProject): {
315
322
  transition?: import("./types.cjs").VideoTransition;
316
323
  effects?: import("./types.cjs").VideoClipEffect[];
317
324
  mask?: import("./types.cjs").VideoClipMask;
325
+ camera?: import("./types.cjs").VideoClipCamera;
318
326
  } | {
319
327
  source?: {
320
328
  in: number;
@@ -339,6 +347,7 @@ export declare function describeVideoProject(project: VideoProject): {
339
347
  transition?: import("./types.cjs").VideoTransition;
340
348
  effects?: import("./types.cjs").VideoClipEffect[];
341
349
  mask?: import("./types.cjs").VideoClipMask;
350
+ camera?: import("./types.cjs").VideoClipCamera;
342
351
  } | {
343
352
  source?: {
344
353
  in: number;
@@ -368,6 +377,7 @@ export declare function describeVideoProject(project: VideoProject): {
368
377
  transition?: import("./types.cjs").VideoTransition;
369
378
  effects?: import("./types.cjs").VideoClipEffect[];
370
379
  mask?: import("./types.cjs").VideoClipMask;
380
+ camera?: import("./types.cjs").VideoClipCamera;
371
381
  } | {
372
382
  source?: {
373
383
  in: number;
@@ -391,6 +401,7 @@ export declare function describeVideoProject(project: VideoProject): {
391
401
  transition?: import("./types.cjs").VideoTransition;
392
402
  effects?: import("./types.cjs").VideoClipEffect[];
393
403
  mask?: import("./types.cjs").VideoClipMask;
404
+ camera?: import("./types.cjs").VideoClipCamera;
394
405
  effect: string;
395
406
  provider?: string;
396
407
  values?: import("./types.cjs").VideoEffectValues;
@@ -419,6 +430,7 @@ export declare function describeVideoProject(project: VideoProject): {
419
430
  transition?: import("./types.cjs").VideoTransition;
420
431
  effects?: import("./types.cjs").VideoClipEffect[];
421
432
  mask?: import("./types.cjs").VideoClipMask;
433
+ camera?: import("./types.cjs").VideoClipCamera;
422
434
  })[];
423
435
  volume?: number | undefined;
424
436
  syncLocked?: boolean | undefined;
@@ -523,6 +535,7 @@ export declare function describeVideoProject(project: VideoProject): {
523
535
  transition?: import("./types.cjs").VideoTransition;
524
536
  effects?: import("./types.cjs").VideoClipEffect[];
525
537
  mask?: import("./types.cjs").VideoClipMask;
538
+ camera?: import("./types.cjs").VideoClipCamera;
526
539
  } | {
527
540
  source?: {
528
541
  in: number;
@@ -552,6 +565,7 @@ export declare function describeVideoProject(project: VideoProject): {
552
565
  transition?: import("./types.cjs").VideoTransition;
553
566
  effects?: import("./types.cjs").VideoClipEffect[];
554
567
  mask?: import("./types.cjs").VideoClipMask;
568
+ camera?: import("./types.cjs").VideoClipCamera;
555
569
  } | {
556
570
  source?: {
557
571
  in: number;
@@ -576,6 +590,7 @@ export declare function describeVideoProject(project: VideoProject): {
576
590
  transition?: import("./types.cjs").VideoTransition;
577
591
  effects?: import("./types.cjs").VideoClipEffect[];
578
592
  mask?: import("./types.cjs").VideoClipMask;
593
+ camera?: import("./types.cjs").VideoClipCamera;
579
594
  } | {
580
595
  source?: {
581
596
  in: number;
@@ -605,6 +620,7 @@ export declare function describeVideoProject(project: VideoProject): {
605
620
  transition?: import("./types.cjs").VideoTransition;
606
621
  effects?: import("./types.cjs").VideoClipEffect[];
607
622
  mask?: import("./types.cjs").VideoClipMask;
623
+ camera?: import("./types.cjs").VideoClipCamera;
608
624
  } | {
609
625
  source?: {
610
626
  in: number;
@@ -628,6 +644,7 @@ export declare function describeVideoProject(project: VideoProject): {
628
644
  transition?: import("./types.cjs").VideoTransition;
629
645
  effects?: import("./types.cjs").VideoClipEffect[];
630
646
  mask?: import("./types.cjs").VideoClipMask;
647
+ camera?: import("./types.cjs").VideoClipCamera;
631
648
  effect: string;
632
649
  provider?: string;
633
650
  values?: import("./types.cjs").VideoEffectValues;
@@ -656,6 +673,7 @@ export declare function describeVideoProject(project: VideoProject): {
656
673
  transition?: import("./types.cjs").VideoTransition;
657
674
  effects?: import("./types.cjs").VideoClipEffect[];
658
675
  mask?: import("./types.cjs").VideoClipMask;
676
+ camera?: import("./types.cjs").VideoClipCamera;
659
677
  })[];
660
678
  volume?: number | undefined;
661
679
  syncLocked?: boolean | undefined;
@@ -69,6 +69,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
69
69
  transition?: import("./types.js").VideoTransition;
70
70
  effects?: import("./types.js").VideoClipEffect[];
71
71
  mask?: import("./types.js").VideoClipMask;
72
+ camera?: import("./types.js").VideoClipCamera;
72
73
  } | {
73
74
  source?: {
74
75
  in: number;
@@ -98,6 +99,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
98
99
  transition?: import("./types.js").VideoTransition;
99
100
  effects?: import("./types.js").VideoClipEffect[];
100
101
  mask?: import("./types.js").VideoClipMask;
102
+ camera?: import("./types.js").VideoClipCamera;
101
103
  } | {
102
104
  source?: {
103
105
  in: number;
@@ -122,6 +124,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
122
124
  transition?: import("./types.js").VideoTransition;
123
125
  effects?: import("./types.js").VideoClipEffect[];
124
126
  mask?: import("./types.js").VideoClipMask;
127
+ camera?: import("./types.js").VideoClipCamera;
125
128
  } | {
126
129
  source?: {
127
130
  in: number;
@@ -151,6 +154,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
151
154
  transition?: import("./types.js").VideoTransition;
152
155
  effects?: import("./types.js").VideoClipEffect[];
153
156
  mask?: import("./types.js").VideoClipMask;
157
+ camera?: import("./types.js").VideoClipCamera;
154
158
  } | {
155
159
  source?: {
156
160
  in: number;
@@ -174,6 +178,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
174
178
  transition?: import("./types.js").VideoTransition;
175
179
  effects?: import("./types.js").VideoClipEffect[];
176
180
  mask?: import("./types.js").VideoClipMask;
181
+ camera?: import("./types.js").VideoClipCamera;
177
182
  effect: string;
178
183
  provider?: string;
179
184
  values?: import("./types.js").VideoEffectValues;
@@ -202,6 +207,7 @@ export declare function describeVideoSequence(project: VideoProject, sequence: V
202
207
  transition?: import("./types.js").VideoTransition;
203
208
  effects?: import("./types.js").VideoClipEffect[];
204
209
  mask?: import("./types.js").VideoClipMask;
210
+ camera?: import("./types.js").VideoClipCamera;
205
211
  })[];
206
212
  volume?: number | undefined;
207
213
  syncLocked?: boolean | undefined;
@@ -286,6 +292,7 @@ export declare function describeVideoProject(project: VideoProject): {
286
292
  transition?: import("./types.js").VideoTransition;
287
293
  effects?: import("./types.js").VideoClipEffect[];
288
294
  mask?: import("./types.js").VideoClipMask;
295
+ camera?: import("./types.js").VideoClipCamera;
289
296
  } | {
290
297
  source?: {
291
298
  in: number;
@@ -315,6 +322,7 @@ export declare function describeVideoProject(project: VideoProject): {
315
322
  transition?: import("./types.js").VideoTransition;
316
323
  effects?: import("./types.js").VideoClipEffect[];
317
324
  mask?: import("./types.js").VideoClipMask;
325
+ camera?: import("./types.js").VideoClipCamera;
318
326
  } | {
319
327
  source?: {
320
328
  in: number;
@@ -339,6 +347,7 @@ export declare function describeVideoProject(project: VideoProject): {
339
347
  transition?: import("./types.js").VideoTransition;
340
348
  effects?: import("./types.js").VideoClipEffect[];
341
349
  mask?: import("./types.js").VideoClipMask;
350
+ camera?: import("./types.js").VideoClipCamera;
342
351
  } | {
343
352
  source?: {
344
353
  in: number;
@@ -368,6 +377,7 @@ export declare function describeVideoProject(project: VideoProject): {
368
377
  transition?: import("./types.js").VideoTransition;
369
378
  effects?: import("./types.js").VideoClipEffect[];
370
379
  mask?: import("./types.js").VideoClipMask;
380
+ camera?: import("./types.js").VideoClipCamera;
371
381
  } | {
372
382
  source?: {
373
383
  in: number;
@@ -391,6 +401,7 @@ export declare function describeVideoProject(project: VideoProject): {
391
401
  transition?: import("./types.js").VideoTransition;
392
402
  effects?: import("./types.js").VideoClipEffect[];
393
403
  mask?: import("./types.js").VideoClipMask;
404
+ camera?: import("./types.js").VideoClipCamera;
394
405
  effect: string;
395
406
  provider?: string;
396
407
  values?: import("./types.js").VideoEffectValues;
@@ -419,6 +430,7 @@ export declare function describeVideoProject(project: VideoProject): {
419
430
  transition?: import("./types.js").VideoTransition;
420
431
  effects?: import("./types.js").VideoClipEffect[];
421
432
  mask?: import("./types.js").VideoClipMask;
433
+ camera?: import("./types.js").VideoClipCamera;
422
434
  })[];
423
435
  volume?: number | undefined;
424
436
  syncLocked?: boolean | undefined;
@@ -523,6 +535,7 @@ export declare function describeVideoProject(project: VideoProject): {
523
535
  transition?: import("./types.js").VideoTransition;
524
536
  effects?: import("./types.js").VideoClipEffect[];
525
537
  mask?: import("./types.js").VideoClipMask;
538
+ camera?: import("./types.js").VideoClipCamera;
526
539
  } | {
527
540
  source?: {
528
541
  in: number;
@@ -552,6 +565,7 @@ export declare function describeVideoProject(project: VideoProject): {
552
565
  transition?: import("./types.js").VideoTransition;
553
566
  effects?: import("./types.js").VideoClipEffect[];
554
567
  mask?: import("./types.js").VideoClipMask;
568
+ camera?: import("./types.js").VideoClipCamera;
555
569
  } | {
556
570
  source?: {
557
571
  in: number;
@@ -576,6 +590,7 @@ export declare function describeVideoProject(project: VideoProject): {
576
590
  transition?: import("./types.js").VideoTransition;
577
591
  effects?: import("./types.js").VideoClipEffect[];
578
592
  mask?: import("./types.js").VideoClipMask;
593
+ camera?: import("./types.js").VideoClipCamera;
579
594
  } | {
580
595
  source?: {
581
596
  in: number;
@@ -605,6 +620,7 @@ export declare function describeVideoProject(project: VideoProject): {
605
620
  transition?: import("./types.js").VideoTransition;
606
621
  effects?: import("./types.js").VideoClipEffect[];
607
622
  mask?: import("./types.js").VideoClipMask;
623
+ camera?: import("./types.js").VideoClipCamera;
608
624
  } | {
609
625
  source?: {
610
626
  in: number;
@@ -628,6 +644,7 @@ export declare function describeVideoProject(project: VideoProject): {
628
644
  transition?: import("./types.js").VideoTransition;
629
645
  effects?: import("./types.js").VideoClipEffect[];
630
646
  mask?: import("./types.js").VideoClipMask;
647
+ camera?: import("./types.js").VideoClipCamera;
631
648
  effect: string;
632
649
  provider?: string;
633
650
  values?: import("./types.js").VideoEffectValues;
@@ -656,6 +673,7 @@ export declare function describeVideoProject(project: VideoProject): {
656
673
  transition?: import("./types.js").VideoTransition;
657
674
  effects?: import("./types.js").VideoClipEffect[];
658
675
  mask?: import("./types.js").VideoClipMask;
676
+ camera?: import("./types.js").VideoClipCamera;
659
677
  })[];
660
678
  volume?: number | undefined;
661
679
  syncLocked?: boolean | undefined;
@@ -6,7 +6,7 @@
6
6
  * track draws over one on a later track. Clips on one track never overlap.
7
7
  */
8
8
  import type { VideoAnimatable, VideoKeyframes } from './keyframes.cjs';
9
- import type { EffectValue } from '../effects/types.cjs';
9
+ import type { CameraMoveSpec, EffectValue } from '../effects/types.cjs';
10
10
  export type VideoAssetKind = 'video' | 'audio' | 'image';
11
11
  /** A spoken word in an asset's transcript, timed in the source (ms). */
12
12
  export interface VideoTranscriptWord {
@@ -230,6 +230,42 @@ interface VideoClipBase {
230
230
  effects?: VideoClipEffect[];
231
231
  /** A shape that cuts the picture out (see `VideoClipMask`). */
232
232
  mask?: VideoClipMask;
233
+ /** Provider camera moves baked into the transform's keyframes (see `VideoClipCamera`). */
234
+ camera?: VideoClipCamera;
235
+ }
236
+ /**
237
+ * Where a camera looks at a clip's picture: `zoom` × the picture as placed (default 1), centred
238
+ * on the point `x`, `y` pixels from the frame's centre (default 0, 0).
239
+ */
240
+ export interface VideoCameraFraming {
241
+ zoom?: number;
242
+ x?: number;
243
+ y?: number;
244
+ }
245
+ /**
246
+ * Camera moves from the effects provider played on a clip, the clip being the shot: `in` (a
247
+ * `transition` move, such as a glide or whip pan) moves from `from` to `framing` over its `ms`
248
+ * from the clip's start, and `during` (a `hold` move, such as a Ken Burns drift) plays across the
249
+ * rest of the clip at `framing`. They are baked into the clip's x, y, scale and rotation keys
250
+ * (one per frame, two at a cut), so previews, renders and exports play them without the provider;
251
+ * `base` keeps the transform from before, put back when the moves are cleared. Set them with
252
+ * `VideoEditorController.setClipCameraMove`, which bakes them; edit the keys directly and the
253
+ * moves no longer describe them.
254
+ */
255
+ export interface VideoClipCamera {
256
+ in?: CameraMoveSpec;
257
+ during?: CameraMoveSpec;
258
+ /** Where `in` starts (default the whole picture). */
259
+ from?: VideoCameraFraming;
260
+ /** Where `in` arrives and `during` plays (default the whole picture). */
261
+ framing?: VideoCameraFraming;
262
+ /** The clip's transform before the moves were baked. */
263
+ base: {
264
+ x?: number;
265
+ y?: number;
266
+ scale?: number;
267
+ rotation?: number;
268
+ };
233
269
  }
234
270
  /**
235
271
  * The shape of a clip mask: `rectangle` (with `cornerRadius`), `ellipse`, `linear` (a straight
@@ -6,7 +6,7 @@
6
6
  * track draws over one on a later track. Clips on one track never overlap.
7
7
  */
8
8
  import type { VideoAnimatable, VideoKeyframes } from './keyframes.js';
9
- import type { EffectValue } from '../effects/types.js';
9
+ import type { CameraMoveSpec, EffectValue } from '../effects/types.js';
10
10
  export type VideoAssetKind = 'video' | 'audio' | 'image';
11
11
  /** A spoken word in an asset's transcript, timed in the source (ms). */
12
12
  export interface VideoTranscriptWord {
@@ -230,6 +230,42 @@ interface VideoClipBase {
230
230
  effects?: VideoClipEffect[];
231
231
  /** A shape that cuts the picture out (see `VideoClipMask`). */
232
232
  mask?: VideoClipMask;
233
+ /** Provider camera moves baked into the transform's keyframes (see `VideoClipCamera`). */
234
+ camera?: VideoClipCamera;
235
+ }
236
+ /**
237
+ * Where a camera looks at a clip's picture: `zoom` × the picture as placed (default 1), centred
238
+ * on the point `x`, `y` pixels from the frame's centre (default 0, 0).
239
+ */
240
+ export interface VideoCameraFraming {
241
+ zoom?: number;
242
+ x?: number;
243
+ y?: number;
244
+ }
245
+ /**
246
+ * Camera moves from the effects provider played on a clip, the clip being the shot: `in` (a
247
+ * `transition` move, such as a glide or whip pan) moves from `from` to `framing` over its `ms`
248
+ * from the clip's start, and `during` (a `hold` move, such as a Ken Burns drift) plays across the
249
+ * rest of the clip at `framing`. They are baked into the clip's x, y, scale and rotation keys
250
+ * (one per frame, two at a cut), so previews, renders and exports play them without the provider;
251
+ * `base` keeps the transform from before, put back when the moves are cleared. Set them with
252
+ * `VideoEditorController.setClipCameraMove`, which bakes them; edit the keys directly and the
253
+ * moves no longer describe them.
254
+ */
255
+ export interface VideoClipCamera {
256
+ in?: CameraMoveSpec;
257
+ during?: CameraMoveSpec;
258
+ /** Where `in` starts (default the whole picture). */
259
+ from?: VideoCameraFraming;
260
+ /** Where `in` arrives and `during` plays (default the whole picture). */
261
+ framing?: VideoCameraFraming;
262
+ /** The clip's transform before the moves were baked. */
263
+ base: {
264
+ x?: number;
265
+ y?: number;
266
+ scale?: number;
267
+ rotation?: number;
268
+ };
233
269
  }
234
270
  /**
235
271
  * The shape of a clip mask: `rectangle` (with `cornerRadius`), `ellipse`, `linear` (a straight
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pixerate/editor",
3
- "version": "0.229.0",
3
+ "version": "0.231.0",
4
4
  "description": "UI-agnostic rich text and media editing core library",
5
5
  "author": "Pixerate",
6
6
  "license": "MIT",
@@ -155,13 +155,16 @@ refuse.
155
155
 
156
156
  | Tool | Use it to |
157
157
  | --- | --- |
158
- | `search_effects` | Find effects: `kind` motion (primitives to apply to nodes) or vector (effects with their own picture), `query`, `category`. `kind` camera lists camera moves (with `camera`: role transition or hold, `durationMs`, `cut`); they move a scene's camera and cannot be applied with these tools. |
158
+ | `search_effects` | Find effects: `kind` motion (primitives to apply to nodes) or vector (effects with their own picture), `query`, `category`. `kind` camera lists camera moves (with `camera`: role transition or hold, `durationMs`, `cut`); give them to a shot with `set_shot_camera_move`, not `apply_effect`. |
159
159
  | `describe_effect` | Read an effect's `controls` (names, ranges, units), `defaults` and `presets`, and whether it `appliesHere` (a motion effect). |
160
160
  | `list_applied_effects` | See the provider effects in the scene: their `instance` ids, the nodes they animate, their shots and values. |
161
161
  | `apply_effect` | Animate a node (`target`, a group animates as one) with a motion effect: the changes become ordinary commands, tagged with the effect, in a new shot after the last. Returns the instance id. |
162
162
  | `update_effect` | Make an applied effect again with new `values`, in the same place (`effect` is its instance id). |
163
163
  | `remove_effect` | Remove an applied effect: its commands, shots it alone filled and a vector effect's group. |
164
164
  | `add_vector_effect` | Add a vector effect's own picture as an artwork group (fitted into `box`) with its motion as new shots. Returns the instance and group ids. |
165
+ | `list_camera_moves` | List the provider's camera moves for a `role` (`transition`: how the camera gets into a shot; `hold`: how it moves while the shot holds), with `durationMs` and `cut`. Returns `available: false` without camera moves. Call before `set_shot_camera_move`; `describe_effect` gives a move's controls and presets. |
166
+ | `set_shot_camera_move` | Give a shot a camera move (`shot`, `role`, `move`, optional `ms` for a transition, `preset`, `values`): it is saved on the shot's camera as `in` or `during`. Returns the shot's camera and the `window` (ms) the move plays in. A wrong-role id is refused naming the moves that fit. |
167
+ | `clear_shot_camera_move` | Remove a shot's move for a `role`, keeping its framing. Returns the shot's camera (null when nothing is left). |
165
168
 
166
169
  ### Save and open
167
170
 
@@ -175,8 +178,32 @@ The host may add the shared document tools (see `pixerate-agent-tools`). An anim
175
178
  | `list_saved_animation_documents` | List saved animations (`key`, `name`, `savedAt`), newest first. |
176
179
  | `open_saved_animation_document` | Replace the animation with a saved one by `key`. One undo step. Ask before opening over changes the user has not saved. |
177
180
 
181
+ ### Camera moves
182
+
183
+ With a provider that has camera moves (Flair: `camera-glide`, `camera-whip-pan`,
184
+ `camera-punch-zoom`, `camera-cut` to get in; `camera-ken-burns`, `camera-crash-zoom` while
185
+ holding), a shot's camera can play one as it arrives and one while it holds:
186
+
187
+ 1. Frame the shot as usual (`update_shot` with `camera: { frame: "<id>" }` or a rectangle). A
188
+ move without a framing keeps the one the camera has.
189
+ 2. `list_camera_moves` with the `role`, pick by `description`, then `set_shot_camera_move`. Use
190
+ a preset (`describe_effect` lists them) before hand-tuning `values`.
191
+ 3. A transition's `ms` sets how long it takes (default the move's own, written out on the
192
+ shot); a hold move plays across the shot's `hold`, so lengthen the hold for a slower drift.
193
+ The next shot's move starts from where a hold move ends.
194
+ 4. `render_animation_frame` mid-move to look, and `check_animation`: `camera-move-first-shot`
195
+ (the first shot cuts, so its transition does not play), `camera-move-unknown`,
196
+ `camera-move-values`, `camera-move-not-played` (no provider with camera moves: the camera
197
+ eases between framings instead).
198
+
199
+ Exports to Flair tag each camera change with `<move>@<shot>`; with the provider set the camera
200
+ is sampled from the move, and a cut stays a jump.
201
+
178
202
  ## Pitfalls
179
203
 
204
+ - **One move per role per shot.** Whip pans and cuts jump half way: put them between framings
205
+ that differ, and do not follow a cut with a long glide into the same framing.
206
+
180
207
  - With agent playback on, the cursor clicks the shot a call names in the timeline and visits the stage elements its commands target. Results are unchanged.
181
208
  - **Effect commands are ordinary commands.** You can retime or edit them with `edit_animation` like
182
209
  any command, but `update_effect` replaces all of an effect's commands. Change values through the
@@ -66,6 +66,8 @@ This skill is the method. `pixerate-animation-editor` has the full tool referenc
66
66
  | Draw a line or outline | `draw`, or `enter` `style: "draw"` |
67
67
  | Attention on one element | `pulse`, `shake`, `wiggle` (sparingly) |
68
68
  | A set length | `fit_animation` with `seconds`, `keep` for fixed shots |
69
+ | The camera travels to the next part | `update_shot` camera `frame`, then `set_shot_camera_move` role `transition` (a glide; a whip pan for energy) |
70
+ | A slow push while a shot holds | `set_shot_camera_move` role `hold` (a Ken Burns drift), with a longer `hold` |
69
71
 
70
72
  ## Recipes
71
73
 
@@ -95,6 +97,7 @@ This skill is the method. `pixerate-animation-editor` has the full tool referenc
95
97
  - `add_commands`, `update_command`, `delete_commands`, `move_command`: refine commands
96
98
  - `edit_animation`: several edits as one undo step
97
99
  - `fit_animation`, `set_animation_settings`, `get_timing_grid`: length, settings and cues
100
+ - `list_camera_moves`, `set_shot_camera_move`: provider camera moves into and during a shot
98
101
  - `check_animation`, `get_motion_path`, `render_animation_frame`: check and look
99
102
  - `export_lottie`, `export_flair_motion`: deliver
100
103
  - `undo_animation`: take back a step
@@ -83,6 +83,12 @@ the pitfalls, and uses the tools below.
83
83
  or `add_video_effect_clip` (generators and titles). Tune with `update_effect` and
84
84
  `set_video_effect_keyframes`; check with `get_video_frame` (layers list `effects`) and
85
85
  `list_applied_effects`.
86
+ 12. **Camera moves** (a provider with camera moves, such as Flair): a clip is the shot.
87
+ `list_video_camera_moves` with a `role`, then `set_clip_camera_move`: `transition` moves
88
+ from `from` to `framing` from the clip's start (a glide, whip pan, punch zoom); `hold`
89
+ plays across the rest of the clip at `framing` (a Ken Burns drift on a still). The moves are
90
+ baked into the clip's x, y, scale and rotation keys at the project's fps, two keys at a cut,
91
+ so the preview and exports play them without the provider. Check with `get_video_frame`.
86
92
 
87
93
  ## Best practices
88
94
 
@@ -284,7 +290,7 @@ and every write tool is refused with the reason.
284
290
 
285
291
  | Tool | Use it to |
286
292
  | --- | --- |
287
- | `search_effects` | Find effects: words in `query`, filtered by `kind`, `category` or `use` (filter, overlay for clips; transition; generator, title). Returns ids, names, uses, whether they are transparent or loop, and their length. Camera moves (`kind` camera) are listed but not applied to clips (`appliesHere` false). Call `describe_effect` next. |
293
+ | `search_effects` | Find effects: words in `query`, filtered by `kind`, `category` or `use` (filter, overlay for clips; transition; generator, title). Returns ids, names, uses, whether they are transparent or loop, and their length. Camera moves (`kind` camera) are listed but go on clips with `set_clip_camera_move`, not `apply_effect`. Call `describe_effect` next. |
288
294
  | `describe_effect` | Read one effect's `controls` (a strict JSON Schema: names, types, ranges, units), `defaults`, `presets` and `inputs`, and whether it `appliesHere` (as a clip effect). Use the names and ranges for values. |
289
295
  | `list_applied_effects` | See the effects in the project per clip, in order: clip effects (`fx1`...), an effect clip's own effect (`generator`) and an effect transition (`transition`), with their saved values and `available` (false when the provider lacks it: drawn as a placeholder). |
290
296
  | `apply_effect` | Add a filter or overlay effect to a clip's stack (`target` clip id, `effect`, `values`, `index`, `enabled`, `opacity`). Effects run in order on the clip's picture before its grade and placement. Returns the effect's new id and the clip's effects. |
@@ -293,6 +299,9 @@ and every write tool is refused with the reason.
293
299
  | `add_video_effect_clip` | Put a generator, title or overlay effect on a video `track` as a clip filling the frame (`start`, `duration` default the effect's own length, `values`, `mode`). Transparent effects show the tracks beneath. Returns the clip id. |
294
300
  | `set_video_effect_transition` | Use a transition effect from the effects provider into a `clip` from the one ending where it starts (`duration` centred on the cut, `values`). Needs handles like a crossfade. For a cross dissolve, dip, wipe, push, slide or iris use the built-in `set_video_transition` instead. |
295
301
  | `set_video_effect_keyframes` | Animate one number `control` of a clip effect (or an effect clip's `generator`) with `keys` in clip ms, or `null` to stop animating it. |
302
+ | `list_video_camera_moves` | List the provider's camera moves for a `role` (`transition` into a clip, `hold` across it) with `durationMs` and `cut`. Returns `available: false` without camera moves. Call before `set_clip_camera_move`. |
303
+ | `set_clip_camera_move` | Play a camera move on a clip's picture (`clip`, `role`, `move`, `ms` for a transition, `preset`, `values`, `from` and `framing` as `{ zoom, x, y }`): baked into its transform keys, one per frame, two at a cut. Returns the camera, key counts, `cuts`, `windows` and `notes` (tilt, turn and blur cannot be baked). Refuses a clip keyed by hand. |
304
+ | `clear_clip_camera_move` | Remove a clip's move for a `role` and re-bake the other; with none left the transform goes back to what it was. |
296
305
 
297
306
  ### Save and open
298
307
 
@@ -308,6 +317,12 @@ The host may add the shared document tools (see `pixerate-agent-tools`). A video
308
317
 
309
318
  ## Pitfalls
310
319
 
320
+ - **Camera moves are baked keys.** After trimming or splitting a clip, `check_video_project`
321
+ reports `camera-stale`: set the move again to re-bake it. Editing the clip's x, y, scale or
322
+ rotation keys by hand leaves the moves no longer describing them; clear the moves first.
323
+ - **A cut is two keys at one time** (the value just before, then the value after). Keys may
324
+ share a time only in pairs; a speed ramp never takes one.
325
+
311
326
  - **An adjustment clip changes only tracks below it** (scope `underneath`). Put it on a new top
312
327
  track (`add_video_track` with `at: 0`), or use scope `all`. Adjustment clips have no sound and
313
328
  are left out of EDLs; ffmpeg exports draw a plain grade or full-strength LUT at full opacity
@@ -65,7 +65,7 @@ music track and cutting to them, see `pixerate-bgm-alignment`.
65
65
  | Time passing | Crossfade or dip between shots |
66
66
  | A section change | Dip to black or a held shot, then a new rhythm |
67
67
  | Continuity of motion | Cut on action (`roll_video_edit` onto the movement) |
68
- | Photos in a slideshow | Image assets, a slow push-in (`set_video_keyframes` scale 1 to 1.08) |
68
+ | Photos in a slideshow | Image assets, a slow push-in: with a provider that has camera moves, `set_clip_camera_move` role `hold` (a Ken Burns drift) on each photo; otherwise `set_video_keyframes` scale 1 to 1.08 |
69
69
 
70
70
  ## Recipes
71
71
 
@@ -96,4 +96,5 @@ start: 0, duration: <sequence>, fadeOut: 2000 }`; `update_video_clip` on the las
96
96
  - `roll_video_edit`, `slip_video_clip`, `trim_video_clip`, `close_video_gaps`: refine the rhythm
97
97
  - `set_video_transition`: crossfades and dips
98
98
  - `update_video_clip`, `set_video_keyframes`: fades, volume and push-ins
99
+ - `list_video_camera_moves`, `set_clip_camera_move`: provider camera moves (a drift across a photo)
99
100
  - `undo_video`: take back a step