@flighthq/scene2d 0.2.1-next.840.857425c

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 (45) hide show
  1. package/dist/bitmap.d.ts +8 -0
  2. package/dist/bitmap.d.ts.map +1 -0
  3. package/dist/bitmap.js +41 -0
  4. package/dist/bitmap.js.map +1 -0
  5. package/dist/displayContainer.d.ts +5 -0
  6. package/dist/displayContainer.d.ts.map +1 -0
  7. package/dist/displayContainer.js +12 -0
  8. package/dist/displayContainer.js.map +1 -0
  9. package/dist/displayObject.d.ts +12 -0
  10. package/dist/displayObject.d.ts.map +1 -0
  11. package/dist/displayObject.js +87 -0
  12. package/dist/displayObject.js.map +1 -0
  13. package/dist/displayObjectAnimation.d.ts +3 -0
  14. package/dist/displayObjectAnimation.d.ts.map +1 -0
  15. package/dist/displayObjectAnimation.js +82 -0
  16. package/dist/displayObjectAnimation.js.map +1 -0
  17. package/dist/htmlView.d.ts +8 -0
  18. package/dist/htmlView.d.ts.map +1 -0
  19. package/dist/htmlView.js +35 -0
  20. package/dist/htmlView.js.map +1 -0
  21. package/dist/index.d.ts +9 -0
  22. package/dist/index.d.ts.map +1 -0
  23. package/dist/index.js +9 -0
  24. package/dist/index.js.map +1 -0
  25. package/dist/renderView.d.ts +8 -0
  26. package/dist/renderView.d.ts.map +1 -0
  27. package/dist/renderView.js +35 -0
  28. package/dist/renderView.js.map +1 -0
  29. package/dist/scene2d.d.ts +10 -0
  30. package/dist/scene2d.d.ts.map +1 -0
  31. package/dist/scene2d.js +73 -0
  32. package/dist/scene2d.js.map +1 -0
  33. package/dist/video.d.ts +9 -0
  34. package/dist/video.d.ts.map +1 -0
  35. package/dist/video.js +41 -0
  36. package/dist/video.js.map +1 -0
  37. package/package.json +49 -0
  38. package/src/bitmap.test.ts +131 -0
  39. package/src/displayContainer.test.ts +37 -0
  40. package/src/displayObject.test.ts +241 -0
  41. package/src/displayObjectAnimation.test.ts +69 -0
  42. package/src/htmlView.test.ts +111 -0
  43. package/src/renderView.test.ts +104 -0
  44. package/src/scene2d.test.ts +165 -0
  45. package/src/video.test.ts +113 -0
@@ -0,0 +1,8 @@
1
+ import type { Bitmap, BitmapData, BitmapRuntime, Node, PartialNode, Rectangle } from '@flighthq/types';
2
+ export declare function computeBitmapLocalBoundsRectangle(out: Rectangle, source: Readonly<Node>): void;
3
+ export declare function createBitmap(obj?: Readonly<PartialNode<Bitmap>>): Bitmap;
4
+ export declare function createBitmapData(data?: Readonly<Partial<BitmapData>>): BitmapData;
5
+ export declare function createBitmapRuntime(): BitmapRuntime;
6
+ export declare function getBitmapRuntime(source: Readonly<Bitmap>): Readonly<BitmapRuntime>;
7
+ export declare function setBitmapImage(source: Bitmap, value: BitmapData['image']): void;
8
+ //# sourceMappingURL=bitmap.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bitmap.d.ts","sourceRoot":"","sources":["../src/bitmap.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,aAAa,EAAa,IAAI,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAKlH,wBAAgB,iCAAiC,CAAC,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,GAAG,IAAI,CAS9F;AAED,wBAAgB,YAAY,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,GAAG,MAAM,CAExE;AAED,wBAAgB,gBAAgB,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,GAAG,UAAU,CAMjF;AAED,wBAAgB,mBAAmB,IAAI,aAAa,CAEnD;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,QAAQ,CAAC,aAAa,CAAC,CAElF;AAED,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,CAAC,OAAO,CAAC,GAAG,IAAI,CAM/E"}
package/dist/bitmap.js ADDED
@@ -0,0 +1,41 @@
1
+ import { invalidateNodeLocalBounds, invalidateNodeLocalContent } from '@flighthq/node';
2
+ import { BitmapKind } from '@flighthq/types';
3
+ import { createNode2D, createNode2DRuntime, getNode2DRuntime } from './displayObject';
4
+ export function computeBitmapLocalBoundsRectangle(out, source) {
5
+ const bitmapData = source.data;
6
+ if (bitmapData.sourceRectangle !== null) {
7
+ out.width = bitmapData.sourceRectangle.width;
8
+ out.height = bitmapData.sourceRectangle.height;
9
+ }
10
+ else if (bitmapData.image) {
11
+ out.width = bitmapData.image.width;
12
+ out.height = bitmapData.image.height;
13
+ }
14
+ }
15
+ export function createBitmap(obj) {
16
+ return createNode2D(BitmapKind, obj, createBitmapData, createBitmapRuntime);
17
+ }
18
+ export function createBitmapData(data) {
19
+ return {
20
+ image: data?.image ?? null,
21
+ smoothing: data?.smoothing ?? true,
22
+ sourceRectangle: data?.sourceRectangle ?? null,
23
+ };
24
+ }
25
+ export function createBitmapRuntime() {
26
+ return createNode2DRuntime(defaultMethods);
27
+ }
28
+ export function getBitmapRuntime(source) {
29
+ return getNode2DRuntime(source);
30
+ }
31
+ export function setBitmapImage(source, value) {
32
+ source.data.image = value;
33
+ // A different image is new pixels (content) and possibly new dimensions (bounds) — not a
34
+ // compositing change, so this no longer bumps appearance.
35
+ invalidateNodeLocalContent(source);
36
+ invalidateNodeLocalBounds(source);
37
+ }
38
+ const defaultMethods = {
39
+ computeLocalBoundsRectangle: computeBitmapLocalBoundsRectangle,
40
+ };
41
+ //# sourceMappingURL=bitmap.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bitmap.js","sourceRoot":"","sources":["../src/bitmap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,0BAA0B,EAAE,MAAM,gBAAgB,CAAC;AAEvF,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC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;IACzF,0DAA0D;IAC1D,0BAA0B,CAAC,MAAM,CAAC,CAAC;IACnC,yBAAyB,CAAC,MAAM,CAAC,CAAC;AACpC,CAAC;AAED,MAAM,cAAc,GAAsC;IACxD,2BAA2B,EAAE,iCAAiC;CAC/D,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { DisplayObject, DisplayObjectRuntime, PartialNode } from '@flighthq/types';
2
+ export declare function createDisplayObject(obj?: Readonly<PartialNode<DisplayObject>>): DisplayObject;
3
+ export declare function createDisplayObjectRuntime(): DisplayObjectRuntime;
4
+ export declare function getDisplayObjectRuntime(source: Readonly<DisplayObject>): Readonly<DisplayObjectRuntime>;
5
+ //# sourceMappingURL=displayContainer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"displayContainer.d.ts","sourceRoot":"","sources":["../src/displayContainer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,oBAAoB,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAKxF,wBAAgB,mBAAmB,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,aAAa,CAAC,CAAC,GAAG,aAAa,CAE7F;AAED,wBAAgB,0BAA0B,IAAI,oBAAoB,CAEjE;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,QAAQ,CAAC,aAAa,CAAC,GAAG,QAAQ,CAAC,oBAAoB,CAAC,CAEvG"}
@@ -0,0 +1,12 @@
1
+ import { DisplayObjectKind } from '@flighthq/types';
2
+ import { createNode2D, createNode2DRuntime, getNode2DRuntime } from './displayObject';
3
+ export function createDisplayObject(obj) {
4
+ return createNode2D(DisplayObjectKind, obj, undefined, createDisplayObjectRuntime);
5
+ }
6
+ export function createDisplayObjectRuntime() {
7
+ return createNode2DRuntime();
8
+ }
9
+ export function getDisplayObjectRuntime(source) {
10
+ return getNode2DRuntime(source);
11
+ }
12
+ //# sourceMappingURL=displayContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"displayContainer.js","sourceRoot":"","sources":["../src/displayContainer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEpD,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEtF,MAAM,UAAU,mBAAmB,CAAC,GAA0C;IAC5E,OAAO,YAAY,CAAC,iBAAiB,EAAE,GAAG,EAAE,SAAS,EAAE,0BAA0B,CAAkB,CAAC;AACtG,CAAC;AAED,MAAM,UAAU,0BAA0B;IACxC,OAAO,mBAAmB,EAA0B,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAC,MAA+B;IACrE,OAAO,gBAAgB,CAAC,MAAM,CAAyB,CAAC;AAC1D,CAAC"}
@@ -0,0 +1,12 @@
1
+ import type { Adjustment, ClipRegion, ColorTransform, Node2D, Node2DDataFactory, Node2DRuntime, Node2DRuntimeFactory, Kind, MethodsOf, NodeAny, PartialNode } from '@flighthq/types';
2
+ export declare function addNode2DColorAdjustment(source: Node2D, adjustment: Adjustment): void;
3
+ export declare function createNode2D<R extends Node2DRuntime>(kind: Kind, obj?: Readonly<PartialNode<Node2D>>, createData?: Node2DDataFactory, createNode2DRuntimeFactory?: Node2DRuntimeFactory<R>): Node2D;
4
+ export declare function createNode2DRuntime(methods?: Readonly<Partial<MethodsOf<Node2DRuntime>>>): Node2DRuntime;
5
+ export declare function getNode2DColorAdjustments(source: Readonly<Node2D>): readonly Adjustment[] | null;
6
+ export declare function getNode2DRuntime(source: Readonly<Node2D>): Readonly<Node2DRuntime>;
7
+ export declare function isNode2D(node: NodeAny): node is Node2D;
8
+ export declare function setNode2DClip(source: Node2D, value: ClipRegion | null): void;
9
+ export declare function setNode2DColorAdjustments(source: Node2D, value: readonly Adjustment[] | null): void;
10
+ export declare function setNode2DColorTransform(source: Node2D, colorTransform: Readonly<ColorTransform> | null): void;
11
+ export { createDisplayObject } from './displayContainer';
12
+ //#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AAI,CAKnG;AAKD,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,QAAQ,CAAC,cAAc,CAAC,GAAG,IAAI,GAAG,IAAI,CAE7G;AAyBD,OAAO,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC"}
@@ -0,0 +1,87 @@
1
+ import { COLOR_ADJUSTMENT_CHANNEL_MIXING, COLOR_ADJUSTMENT_NONE, createColorTransformAdjustment, resolveColorAdjustmentsColorTransform, } from '@flighthq/adjustments';
2
+ import { createColorTransform } from '@flighthq/materials';
3
+ import { createNode, createNodeRuntime, getNodeRuntime, initAppearanceTrait, initBlendModeTrait, initBoundsRectangleRuntimeTrait, initBoundsRectangleTrait, initClipTrait, initMaterialTrait, initTransform2DRuntimeTrait, initTransform2DTrait, invalidateNodeAppearance, } from '@flighthq/node';
4
+ import { Node2DTraitsKey } from '@flighthq/types';
5
+ // Appends one pointwise color adjustment to this object's stack (creating the stack if absent), re-fuses
6
+ // the resolved cache, and invalidates appearance so the render walk hands the fold the new value.
7
+ // Allocates a new array — the stack is a plain `readonly Adjustment[]`, never mutated in place.
8
+ export function addNode2DColorAdjustment(source, adjustment) {
9
+ const runtime = getNodeRuntime(source);
10
+ const current = runtime.colorAdjustments;
11
+ runtime.colorAdjustments = current === null ? [adjustment] : [...current, adjustment];
12
+ resolveNode2DColorAdjustments(runtime);
13
+ invalidateNodeAppearance(source);
14
+ }
15
+ export function createNode2D(kind, obj, createData, createNode2DRuntimeFactory) {
16
+ const out = createNode(kind, obj, createData, createNode2DRuntimeFactory ?? createNode2DRuntime);
17
+ initTransform2DTrait(out, obj);
18
+ initBoundsRectangleTrait(out, obj);
19
+ initAppearanceTrait(out, obj);
20
+ initBlendModeTrait(out, obj);
21
+ initMaterialTrait(out, obj);
22
+ initClipTrait(out, obj);
23
+ return out;
24
+ }
25
+ export function createNode2DRuntime(methods) {
26
+ const out = createNodeRuntime(methods);
27
+ out.traits = Node2DTraitsKey;
28
+ out.scene2d = null;
29
+ initTransform2DRuntimeTrait(out, methods);
30
+ initBoundsRectangleRuntimeTrait(out, methods);
31
+ return out;
32
+ }
33
+ // Returns this object's pointwise color-adjustment stack (the source of truth on the node runtime), or
34
+ // null when it carries none.
35
+ export function getNode2DColorAdjustments(source) {
36
+ return getNodeRuntime(source).colorAdjustments;
37
+ }
38
+ export function getNode2DRuntime(source) {
39
+ return getNodeRuntime(source);
40
+ }
41
+ export function isNode2D(node) {
42
+ return getNodeRuntime(node).traits === Node2DTraitsKey;
43
+ }
44
+ export function setNode2DClip(source, value) {
45
+ source.clip = value;
46
+ invalidateNodeAppearance(source);
47
+ }
48
+ // Sets (or clears with null) this object's pointwise color-adjustment stack — the generic replacement for
49
+ // the removed color-transform trait. A color transform is one member: `createColorTransformAdjustment`.
50
+ // Re-fuses the resolved cache once here (not per frame) and invalidates appearance so the render walk
51
+ // hands the fold the affine ColorTransform the stack resolves to. Null is the untinted default.
52
+ export function setNode2DColorAdjustments(source, value) {
53
+ const runtime = getNodeRuntime(source);
54
+ runtime.colorAdjustments = value;
55
+ resolveNode2DColorAdjustments(runtime);
56
+ invalidateNodeAppearance(source);
57
+ }
58
+ // Convenience for the common single-tint path (the color-transform an agent looks for): sets this object's
59
+ // adjustment stack to one `ColorTransformAdjustment`, or clears it with null. Thin wrapper over
60
+ // `setNode2DColorAdjustments` — a color transform is just one adjustment in the generic stack.
61
+ export function setNode2DColorTransform(source, colorTransform) {
62
+ setNode2DColorAdjustments(source, colorTransform === null ? null : [createColorTransformAdjustment(colorTransform)]);
63
+ }
64
+ // Fuses the runtime's color-adjustment stack once into its cached affine `resolvedColorTransform`, setting
65
+ // `colorAdjustmentsChannelMixing` when the fused stack has off-diagonal channel-mixing terms the 8-float
66
+ // fold cannot represent yet (the render walk reports that through the shakeable guard). Called by the
67
+ // accessors on change — the render walk only reads the cache, so no fuse math weighs on the base render
68
+ // path. The cached ColorTransform is reused in place across re-fuses to avoid per-set allocation churn.
69
+ function resolveNode2DColorAdjustments(runtime) {
70
+ const adjustments = runtime.colorAdjustments;
71
+ if (adjustments === null || adjustments.length === 0) {
72
+ runtime.resolvedColorTransform = null;
73
+ runtime.colorAdjustmentsChannelMixing = false;
74
+ return;
75
+ }
76
+ const out = runtime.resolvedColorTransform ?? createColorTransform();
77
+ const status = resolveColorAdjustmentsColorTransform(adjustments, out);
78
+ if (status === COLOR_ADJUSTMENT_NONE) {
79
+ runtime.resolvedColorTransform = null;
80
+ runtime.colorAdjustmentsChannelMixing = false;
81
+ return;
82
+ }
83
+ runtime.resolvedColorTransform = out;
84
+ runtime.colorAdjustmentsChannelMixing = status === COLOR_ADJUSTMENT_CHANNEL_MIXING;
85
+ }
86
+ export { createDisplayObject } from './displayContainer';
87
+ //# sourceMappingURL=displayObject.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"displayObject.js","sourceRoot":"","sources":["../src/displayObject.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,+BAA+B,EAC/B,qBAAqB,EACrB,8BAA8B,EAC9B,qCAAqC,GACtC,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EACL,UAAU,EACV,iBAAiB,EACjB,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,+BAA+B,EAC/B,wBAAwB,EACxB,aAAa,EACb,iBAAiB,EACjB,2BAA2B,EAC3B,oBAAoB,EACpB,wBAAwB,GACzB,MAAM,gBAAgB,CAAC;AAexB,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAElD,yGAAyG;AACzG,kGAAkG;AAClG,gGAAgG;AAChG,MAAM,UAAU,wBAAwB,CAAC,MAAc,EAAE,UAAsB;IAC7E,MAAM,OAAO,GAAG,cAAc,CAAC,MAAM,CAAkB,CAAC;IACxD,MAAM,OAAO,GAAG,OAAO,CAAC,gBAAgB,CAAC;IACzC,OAAO,CAAC,gBAAgB,GAAG,OAAO,KAAK,IAAI,CAA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BAAoB,EAAE,CAAC;IACrE,MAAM,MAAM,GAAG,qCAAqC,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC;IACvE,IAAI,MAAM,KAAK,qBAAqB,EAAE,CAAC;QACrC,OAAO,CAAC,sBAAsB,GAAG,IAAI,CAAC;QACtC,OAAO,CAAC,6BAA6B,GAAG,KAAK,CAAC;QAC9C,OAAO;IACT,CAAC;IACD,OAAO,CAAC,sBAAsB,GAAG,GAAG,CAAC;IACrC,OAAO,CAAC,6BAA6B,GAAG,MAAM,KAAK,+BAA+B,CAAC;AACrF,CAAC;AAED,OAAO,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { AnimationClip } from '@flighthq/types';
2
+ export declare function applyAnimationClipToNode2D(clip: Readonly<AnimationClip>, time: number): void;
3
+ //# sourceMappingURL=displayObjectAnimation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"displayObjectAnimation.d.ts","sourceRoot":"","sources":["../src/displayObjectAnimation.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAyB,MAAM,iBAAiB,CAAC;AAK5E,wBAAgB,0BAA0B,CAAC,IAAI,EAAE,QAAQ,CAAC,aAAa,CAAC,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAyE5F"}
@@ -0,0 +1,82 @@
1
+ import { sampleAnimationTrack } from '@flighthq/animation';
2
+ import { invalidateNodeAppearance, invalidateNodeLocalTransform } from '@flighthq/node';
3
+ // Samples a target-free clip and applies channels carrying Node2DAnimationTarget descriptors.
4
+ // Unknown target refs and paths are ignored, matching the scene/skeleton binding layers. Transform
5
+ // paths invalidate local matrices; alpha/visibility paths invalidate appearance.
6
+ export function applyAnimationClipToNode2D(clip, time) {
7
+ for (const channel of clip.channels) {
8
+ const target = channel.targetRef;
9
+ if (target === null || typeof target !== 'object' || target.node === undefined)
10
+ continue;
11
+ sampleAnimationTrack(_scratch, channel.track, time);
12
+ const node = target.node;
13
+ switch (target.path) {
14
+ case 'Alpha':
15
+ node.alpha = _scratch[0];
16
+ invalidateNodeAppearance(node);
17
+ break;
18
+ case 'Pivot':
19
+ node.pivotX = _scratch[0];
20
+ node.pivotY = _scratch[1];
21
+ invalidateNodeLocalTransform(node);
22
+ break;
23
+ case 'PivotX':
24
+ node.pivotX = _scratch[0];
25
+ invalidateNodeLocalTransform(node);
26
+ break;
27
+ case 'PivotY':
28
+ node.pivotY = _scratch[0];
29
+ invalidateNodeLocalTransform(node);
30
+ break;
31
+ case 'Position':
32
+ node.x = _scratch[0];
33
+ node.y = _scratch[1];
34
+ invalidateNodeLocalTransform(node);
35
+ break;
36
+ case 'Rotation':
37
+ node.rotation = _scratch[0];
38
+ invalidateNodeLocalTransform(node);
39
+ break;
40
+ case 'Scale':
41
+ node.scaleX = _scratch[0];
42
+ node.scaleY = _scratch[1];
43
+ invalidateNodeLocalTransform(node);
44
+ break;
45
+ case 'ScaleX':
46
+ node.scaleX = _scratch[0];
47
+ invalidateNodeLocalTransform(node);
48
+ break;
49
+ case 'ScaleY':
50
+ node.scaleY = _scratch[0];
51
+ invalidateNodeLocalTransform(node);
52
+ break;
53
+ case 'Skew':
54
+ node.skewX = _scratch[0];
55
+ node.skewY = _scratch[1];
56
+ invalidateNodeLocalTransform(node);
57
+ break;
58
+ case 'SkewX':
59
+ node.skewX = _scratch[0];
60
+ invalidateNodeLocalTransform(node);
61
+ break;
62
+ case 'SkewY':
63
+ node.skewY = _scratch[0];
64
+ invalidateNodeLocalTransform(node);
65
+ break;
66
+ case 'Visible':
67
+ node.visible = _scratch[0] >= 0.5;
68
+ invalidateNodeAppearance(node);
69
+ break;
70
+ case 'X':
71
+ node.x = _scratch[0];
72
+ invalidateNodeLocalTransform(node);
73
+ break;
74
+ case 'Y':
75
+ node.y = _scratch[0];
76
+ invalidateNodeLocalTransform(node);
77
+ break;
78
+ }
79
+ }
80
+ }
81
+ const _scratch = [0, 0, 0, 0];
82
+ //# sourceMappingURL=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AC,KAAK,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;gBACzB,4BAA4B,CAAC,IAAI,CAAC,CAAC;gBACnC,MAAM;YACR,KAAK,SAAS;gBACZ,IAAI,CAAC,OAAO,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAI,GAAG,CAAC;gBAClC,wBAAwB,CAAC,IAAI,CAAC,CAAC;gBAC/B,MAAM;YACR,KAAK,GAAG;gBACN,IAAI,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;gBACrB,4BAA4B,CAAC,IAAI,CAAC,CAAC;gBACnC,MAAM;YACR,KAAK,GAAG;gBACN,IAAI,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;gBACrB,4BAA4B,CAAC,IAAI,CAAC,CAAC;gBACnC,MAAM;QACV,CAAC;IACH,CAAC;AACH,CAAC;AAED,MAAM,QAAQ,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { HtmlView, HtmlViewData, HtmlViewRuntime, Node, PartialNode, Rectangle } from '@flighthq/types';
2
+ export declare function computeHtmlViewLocalBoundsRectangle(out: Rectangle, source: Readonly<Node>): void;
3
+ export declare function createHtmlView(obj?: Readonly<PartialNode<HtmlView>>): HtmlView;
4
+ export declare function createHtmlViewData(data?: Readonly<Partial<HtmlViewData>>): HtmlViewData;
5
+ export declare function createHtmlViewRuntime(): HtmlViewRuntime;
6
+ export declare function getHtmlViewRuntime(source: Readonly<HtmlView>): Readonly<HtmlViewRuntime>;
7
+ export declare function setHtmlViewSize(source: HtmlView, width: number, height: number): void;
8
+ //# sourceMappingURL=htmlView.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"htmlView.d.ts","sourceRoot":"","sources":["../src/htmlView.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,YAAY,EAAE,eAAe,EAAa,IAAI,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAKxH,wBAAgB,mCAAmC,CAAC,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,GAAG,IAAI,CAIhG;AAED,wBAAgB,cAAc,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC,GAAG,QAAQ,CAE9E;AAED,wBAAgB,kBAAkB,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC,GAAG,YAAY,CAMvF;AAED,wBAAgB,qBAAqB,IAAI,eAAe,CAEvD;AAED,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,QAAQ,CAAC,QAAQ,CAAC,GAAG,QAAQ,CAAC,eAAe,CAAC,CAExF;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAKrF"}
@@ -0,0 +1,35 @@
1
+ import { invalidateNodeLocalBounds } from '@flighthq/node';
2
+ import { HtmlViewKind } from '@flighthq/types';
3
+ import { createNode2D, createNode2DRuntime, getNode2DRuntime } from './displayObject';
4
+ export function computeHtmlViewLocalBoundsRectangle(out, source) {
5
+ const data = source.data;
6
+ out.width = data.width;
7
+ out.height = data.height;
8
+ }
9
+ export function createHtmlView(obj) {
10
+ return createNode2D(HtmlViewKind, obj, createHtmlViewData, createHtmlViewRuntime);
11
+ }
12
+ export function createHtmlViewData(data) {
13
+ return {
14
+ element: data?.element ?? null,
15
+ height: data?.height ?? 100,
16
+ width: data?.width ?? 100,
17
+ };
18
+ }
19
+ export function createHtmlViewRuntime() {
20
+ return createNode2DRuntime(defaultMethods);
21
+ }
22
+ export function getHtmlViewRuntime(source) {
23
+ return getNode2DRuntime(source);
24
+ }
25
+ export function setHtmlViewSize(source, width, height) {
26
+ if (source.data.width === width && source.data.height === height)
27
+ return;
28
+ source.data.width = width;
29
+ source.data.height = height;
30
+ invalidateNodeLocalBounds(source);
31
+ }
32
+ const defaultMethods = {
33
+ computeLocalBoundsRectangle: computeHtmlViewLocalBoundsRectangle,
34
+ };
35
+ //# sourceMappingURL=htmlView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"htmlView.js","sourceRoot":"","sources":["../src/htmlView.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,gBAAgB,CAAC;AAE3D,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEtF,MAAM,UAAU,mCAAmC,CAAC,GAAc,EAAE,MAAsB;IACxF,MAAM,IAAI,GAAI,MAAmB,CAAC,IAAI,CAAC;IACvC,GAAG,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;IACvB,GAAG,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;AAC3B,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,GAAqC;IAClE,OAAO,YAAY,CAAC,YAAY,EAAE,GAAG,EAAE,kBAAkB,EAAE,qBAAqB,CAAa,CAAC;AAChG,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,IAAsC;IACvE,OAAO;QACL,OAAO,EAAE,IAAI,EAAE,OAAO,IAAI,IAAI;QAC9B,MAAM,EAAE,IAAI,EAAE,MAAM,IAAI,GAAG;QAC3B,KAAK,EAAE,IAAI,EAAE,KAAK,IAAI,GAAG;KAC1B,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,qBAAqB;IACnC,OAAO,mBAAmB,CAAC,cAAc,CAAoB,CAAC;AAChE,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,MAA0B;IAC3D,OAAO,gBAAgB,CAAC,MAAM,CAAoB,CAAC;AACrD,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,MAAgB,EAAE,KAAa,EAAE,MAAc;IAC7E,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,KAAK,KAAK,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,KAAK,MAAM;QAAE,OAAO;IACzE,MAAM,CAAC,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IAC1B,MAAM,CAAC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IAC5B,yBAAyB,CAAC,MAAM,CAAC,CAAC;AACpC,CAAC;AAED,MAAM,cAAc,GAAwC;IAC1D,2BAA2B,EAAE,mCAAmC;CACjE,CAAC"}
@@ -0,0 +1,9 @@
1
+ export * from './bitmap';
2
+ export * from './displayContainer';
3
+ export * from './displayObject';
4
+ export * from './displayObjectAnimation';
5
+ export * from './htmlView';
6
+ export * from './renderView';
7
+ export * from './scene2d';
8
+ export * from './video';
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,9 @@
1
+ export * from './bitmap';
2
+ export * from './displayContainer';
3
+ export * from './displayObject';
4
+ export * from './displayObjectAnimation';
5
+ export * from './htmlView';
6
+ export * from './renderView';
7
+ export * from './scene2d';
8
+ export * from './video';
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { Node, PartialNode, Rectangle, RenderView, RenderViewData, RenderViewRuntime } from '@flighthq/types';
2
+ export declare function computeRenderViewLocalBoundsRectangle(out: Rectangle, source: Readonly<Node>): void;
3
+ export declare function createRenderView(obj?: Readonly<PartialNode<RenderView>>): RenderView;
4
+ export declare function createRenderViewData(data?: Readonly<Partial<RenderViewData>>): RenderViewData;
5
+ export declare function createRenderViewRuntime(): RenderViewRuntime;
6
+ export declare function getRenderViewRuntime(source: Readonly<RenderView>): Readonly<RenderViewRuntime>;
7
+ export declare function setRenderViewSize(source: RenderView, width: number, height: number): void;
8
+ //# sourceMappingURL=renderView.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renderView.d.ts","sourceRoot":"","sources":["../src/renderView.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,IAAI,EACJ,WAAW,EACX,SAAS,EACT,UAAU,EACV,cAAc,EACd,iBAAiB,EAClB,MAAM,iBAAiB,CAAC;AAKzB,wBAAgB,qCAAqC,CAAC,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,GAAG,IAAI,CAIlG;AAED,wBAAgB,gBAAgB,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC,GAAG,UAAU,CAEpF;AAED,wBAAgB,oBAAoB,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC,GAAG,cAAc,CAM7F;AAED,wBAAgB,uBAAuB,IAAI,iBAAiB,CAE3D;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,QAAQ,CAAC,UAAU,CAAC,GAAG,QAAQ,CAAC,iBAAiB,CAAC,CAE9F;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAKzF"}
@@ -0,0 +1,35 @@
1
+ import { invalidateNodeLocalBounds } from '@flighthq/node';
2
+ import { RenderViewKind } from '@flighthq/types';
3
+ import { createNode2D, createNode2DRuntime, getNode2DRuntime } from './displayObject';
4
+ export function computeRenderViewLocalBoundsRectangle(out, source) {
5
+ const data = source.data;
6
+ out.width = data.width;
7
+ out.height = data.height;
8
+ }
9
+ export function createRenderView(obj) {
10
+ return createNode2D(RenderViewKind, obj, createRenderViewData, createRenderViewRuntime);
11
+ }
12
+ export function createRenderViewData(data) {
13
+ return {
14
+ height: data?.height ?? 0,
15
+ renderer: data?.renderer ?? null,
16
+ width: data?.width ?? 0,
17
+ };
18
+ }
19
+ export function createRenderViewRuntime() {
20
+ return createNode2DRuntime(defaultMethods);
21
+ }
22
+ export function getRenderViewRuntime(source) {
23
+ return getNode2DRuntime(source);
24
+ }
25
+ export function setRenderViewSize(source, width, height) {
26
+ if (source.data.width === width && source.data.height === height)
27
+ return;
28
+ source.data.width = width;
29
+ source.data.height = height;
30
+ invalidateNodeLocalBounds(source);
31
+ }
32
+ const defaultMethods = {
33
+ computeLocalBoundsRectangle: computeRenderViewLocalBoundsRectangle,
34
+ };
35
+ //# sourceMappingURL=renderView.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"renderView.js","sourceRoot":"","sources":["../src/renderView.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,gBAAgB,CAAC;AAU3D,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAEjD,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEtF,MAAM,UAAU,qCAAqC,CAAC,GAAc,EAAE,MAAsB;IAC1F,MAAM,IAAI,GAAI,MAAqB,CAAC,IAAI,CAAC;IACzC,GAAG,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;IACvB,GAAG,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;AAC3B,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,GAAuC;IACtE,OAAO,YAAY,CAAC,cAAc,EAAE,GAAG,EAAE,oBAAoB,EAAE,uBAAuB,CAAe,CAAC;AACxG,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,IAAwC;IAC3E,OAAO;QACL,MAAM,EAAE,IAAI,EAAE,MAAM,IAAI,CAAC;QACzB,QAAQ,EAAE,IAAI,EAAE,QAAQ,IAAI,IAAI;QAChC,KAAK,EAAE,IAAI,EAAE,KAAK,IAAI,CAAC;KACxB,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,uBAAuB;IACrC,OAAO,mBAAmB,CAAC,cAAc,CAAsB,CAAC;AAClE,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,MAA4B;IAC/D,OAAO,gBAAgB,CAAC,MAAM,CAAsB,CAAC;AACvD,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,MAAkB,EAAE,KAAa,EAAE,MAAc;IACjF,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,KAAK,KAAK,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,KAAK,MAAM;QAAE,OAAO;IACzE,MAAM,CAAC,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IAC1B,MAAM,CAAC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IAC5B,yBAAyB,CAAC,MAAM,CAAC,CAAC;AACpC,CAAC;AAED,MAAM,cAAc,GAA0C;IAC5D,2BAA2B,EAAE,qCAAqC;CACnE,CAAC"}
@@ -0,0 +1,10 @@
1
+ import type { Node2D, Scene2D, Scene2DRuntime, Scene2DSignals } from '@flighthq/types';
2
+ export declare function createScene2D(obj?: Readonly<Partial<Pick<Scene2D, 'align' | 'color' | 'scaleMode' | 'scene2dHeight' | 'scene2dWidth'>>>): Scene2D;
3
+ export declare function createScene2DRuntime(): Scene2DRuntime;
4
+ export declare function createScene2DSignals(): Scene2DSignals;
5
+ export declare function enableScene2DSignals(source: Scene2D): Scene2DSignals;
6
+ export declare function getScene2DRoot(source: Readonly<Node2D>): Scene2D | null;
7
+ export declare function getScene2DRuntime(source: Readonly<Scene2D>): Readonly<Scene2DRuntime>;
8
+ export declare function getScene2DSignals(source: Readonly<Scene2D>): Scene2DSignals | null;
9
+ export declare function setScene2DSize(source: Scene2D, width: number, height: number): void;
10
+ //# sourceMappingURL=scene2d.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scene2d.d.ts","sourceRoot":"","sources":["../src/scene2d.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAiB,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAUtG,wBAAgB,aAAa,CAC3B,GAAG,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,GAAG,WAAW,GAAG,eAAe,GAAG,cAAc,CAAC,CAAC,CAAC,GACzG,OAAO,CAYT;AAED,wBAAgB,oBAAoB,IAAI,cAAc,CAKrD;AAED,wBAAgB,oBAAoB,IAAI,cAAc,CAMrD;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,OAAO,GAAG,cAAc,CAGpE;AAID,wBAAgB,cAAc,CAAC,MAAM,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,OAAO,GAAG,IAAI,CAGvE;AAID,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,QAAQ,CAAC,cAAc,CAAC,CAErF;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,cAAc,GAAG,IAAI,CAGlF;AAED,wBAAgB,cAAc,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAMnF"}
@@ -0,0 +1,73 @@
1
+ import { createEntity } from '@flighthq/entity';
2
+ import { getNodeRoot, getNodeRuntime } from '@flighthq/node';
3
+ import { createSignal, emitSignal } from '@flighthq/signals';
4
+ import { EntityRuntimeKey } from '@flighthq/types';
5
+ import { createDisplayObject } from './displayObject';
6
+ // Allocates a Scene2D: a presentation-context Entity that owns a display-object `root` (allocated here), not a
7
+ // node in the tree. Carries the fit context (`align`/`scaleMode`) directly — fit is the Scene2D's concern, and
8
+ // the bedrock `Viewport` is a drawable rect, not a base of Scene2D — plus the view dimensions and background
9
+ // color. The entity runtime stays unbound; the root's runtime carries a back-pointer so getScene2DRoot
10
+ // resolves membership by a lazy walk to the root.
11
+ export function createScene2D(obj) {
12
+ const root = createDisplayObject();
13
+ const scene2d = createEntity({
14
+ align: obj?.align ?? 'topleft',
15
+ color: obj?.color ?? null,
16
+ root,
17
+ scaleMode: obj?.scaleMode ?? 'noscale',
18
+ scene2dHeight: obj?.scene2dHeight ?? 550,
19
+ scene2dWidth: obj?.scene2dWidth ?? 400,
20
+ });
21
+ getNodeRuntime(root).scene2d = scene2d;
22
+ return scene2d;
23
+ }
24
+ export function createScene2DRuntime() {
25
+ return {
26
+ binding: null,
27
+ scene2dSignals: null,
28
+ };
29
+ }
30
+ export function createScene2DSignals() {
31
+ return {
32
+ onFullscreenChanged: createSignal(),
33
+ onOrientationChanged: createSignal(),
34
+ onResize: createSignal(),
35
+ };
36
+ }
37
+ export function enableScene2DSignals(source) {
38
+ const runtime = ensureScene2DRuntime(source);
39
+ return (runtime.scene2dSignals ??= createScene2DSignals());
40
+ }
41
+ // Resolves the Scene2D a display object belongs to, or null when its root is not owned by a scene2d. Walks to the
42
+ // root (a cheap parent walk) and reads the scene2d back-pointer the root runtime carries.
43
+ export function getScene2DRoot(source) {
44
+ const root = getNodeRoot(source);
45
+ return getNodeRuntime(root).scene2d;
46
+ }
47
+ // The scene2d's runtime, allocated on first access (the entity is created unbound). Callers that only read
48
+ // enabled signals should use getScene2DSignals, which does not allocate.
49
+ export function getScene2DRuntime(source) {
50
+ return ensureScene2DRuntime(source);
51
+ }
52
+ export function getScene2DSignals(source) {
53
+ const runtime = source[EntityRuntimeKey];
54
+ return runtime?.scene2dSignals ?? null;
55
+ }
56
+ export function setScene2DSize(source, width, height) {
57
+ if (source.scene2dWidth === width && source.scene2dHeight === height)
58
+ return;
59
+ source.scene2dWidth = width;
60
+ source.scene2dHeight = height;
61
+ const runtime = source[EntityRuntimeKey];
62
+ if (runtime?.scene2dSignals)
63
+ emitSignal(runtime.scene2dSignals.onResize);
64
+ }
65
+ function ensureScene2DRuntime(source) {
66
+ const existing = source[EntityRuntimeKey];
67
+ if (existing !== undefined)
68
+ return existing;
69
+ const runtime = createScene2DRuntime();
70
+ source[EntityRuntimeKey] = runtime;
71
+ return runtime;
72
+ }
73
+ //# sourceMappingURL=scene2d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scene2d.js","sourceRoot":"","sources":["../src/scene2d.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE7D,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEnD,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAEtD,+GAA+G;AAC/G,+GAA+G;AAC/G,6GAA6G;AAC7G,uGAAuG;AACvG,kDAAkD;AAClD,MAAM,UAAU,aAAa,CAC3B,GAA0G;IAE1G,MAAM,IAAI,GAAG,mBAAmB,EAAE,CAAC;IACnC,MAAM,OAAO,GAAG,YAAY,CAAC;QAC3B,KAAK,EAAE,GAAG,EAAE,KAAK,IAAI,SAAS;QAC9B,KAAK,EAAE,GAAG,EAAE,KAAK,IAAI,IAAI;QACzB,IAAI;QACJ,SAAS,EAAE,G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AAC,YAAY,KAAK,KAAK,IAAI,MAAM,CAAC,aAAa,KAAK,MAAM;QAAE,OAAO;IAC7E,MAAM,CAAC,YAAY,GAAG,KAAK,CAAC;IAC5B,MAAM,CAAC,aAAa,GAAG,MAAM,CAAC;IAC9B,MAAM,OAAO,GAAG,MAAM,CAAC,gBAAgB,CAA+B,CAAC;IACvE,IAAI,OAAO,EAAE,cAAc;QAAE,UAAU,CAAC,OAAO,CAAC,cAAc,CAAC,QAAQ,CAAC,CAAC;AAC3E,CAAC;AAED,SAAS,oBAAoB,CAAC,MAAe;IAC3C,MAAM,QAAQ,GAAG,MAAM,CAAC,gBAAgB,CAA+B,CAAC;IACxE,IAAI,QAAQ,KAAK,SAAS;QAAE,OAAO,QAAQ,CAAC;IAC5C,MAAM,OAAO,GAAG,oBAAoB,EAAE,CAAC;IACvC,MAAM,CAAC,gBAAgB,CAAC,GAAG,OAAO,CAAC;IACnC,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -0,0 +1,9 @@
1
+ import type { Node, PartialNode, Rectangle, Video, VideoData, VideoRuntime } from '@flighthq/types';
2
+ export declare function computeVideoLocalBoundsRectangle(out: Rectangle, source: Readonly<Node>): void;
3
+ export declare function createVideo(obj?: Readonly<PartialNode<Video>>): Video;
4
+ export declare function createVideoData(data?: Readonly<Partial<VideoData>>): VideoData;
5
+ export declare function createVideoRuntime(): VideoRuntime;
6
+ export declare function getVideoRuntime(source: Readonly<Video>): Readonly<VideoRuntime>;
7
+ export declare function setVideoSmoothing(source: Video, value: boolean): void;
8
+ export declare function setVideoSource(source: Video, value: VideoData['source']): void;
9
+ //# sourceMappingURL=video.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"video.d.ts","sourceRoot":"","sources":["../src/video.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAa,IAAI,EAAE,WAAW,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAK/G,wBAAgB,gCAAgC,CAAC,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,GAAG,IAAI,CAM7F;AAED,wBAAgB,WAAW,CAAC,GAAG,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,GAAG,KAAK,CAErE;AAED,wBAAgB,eAAe,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,GAAG,SAAS,CAK9E;AAED,wBAAgB,kBAAkB,IAAI,YAAY,CAEjD;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,QAAQ,CAAC,KAAK,CAAC,GAAG,QAAQ,CAAC,YAAY,CAAC,CAE/E;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CAKrE;AAED,wBAAgB,cAAc,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,CAAC,QAAQ,CAAC,GAAG,IAAI,CAK9E"}
package/dist/video.js ADDED
@@ -0,0 +1,41 @@
1
+ import { invalidateNodeLocalBounds, invalidateNodeLocalContent } from '@flighthq/node';
2
+ import { VideoKind } from '@flighthq/types';
3
+ import { createNode2D, createNode2DRuntime, getNode2DRuntime } from './displayObject';
4
+ export function computeVideoLocalBoundsRectangle(out, source) {
5
+ const element = source.data.source?.element;
6
+ if (element !== undefined && element !== null) {
7
+ out.width = element.videoWidth;
8
+ out.height = element.videoHeight;
9
+ }
10
+ }
11
+ export function createVideo(obj) {
12
+ return createNode2D(VideoKind, obj, createVideoData, createVideoRuntime);
13
+ }
14
+ export function createVideoData(data) {
15
+ return {
16
+ smoothing: data?.smoothing ?? true,
17
+ source: data?.source ?? null,
18
+ };
19
+ }
20
+ export function createVideoRuntime() {
21
+ return createNode2DRuntime(defaultMethods);
22
+ }
23
+ export function getVideoRuntime(source) {
24
+ return getNode2DRuntime(source);
25
+ }
26
+ export function setVideoSmoothing(source, value) {
27
+ // Sampler filter mode is a content-rasterization concern, not a compositing one — same tier as a
28
+ // new image on a Bitmap, and it does not change the node's bounds.
29
+ source.data.smoothing = value;
30
+ invalidateNodeLocalContent(source);
31
+ }
32
+ export function setVideoSource(source, value) {
33
+ // A new source is new pixels (content) and possibly new dimensions (bounds).
34
+ source.data.source = value;
35
+ invalidateNodeLocalContent(source);
36
+ invalidateNodeLocalBounds(source);
37
+ }
38
+ const defaultMethods = {
39
+ computeLocalBoundsRectangle: computeVideoLocalBoundsRectangle,
40
+ };
41
+ //# sourceMappingURL=video.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"video.js","sourceRoot":"","sources":["../src/video.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,0BAA0B,EAAE,MAAM,gBAAgB,CAAC;AAEvF,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAE5C,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAEtF,MAAM,UAAU,gCAAgC,CAAC,GAAc,EAAE,MAAsB;IACrF,MAAM,OAAO,GAAI,MAAM,CAAC,IAAkB,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3D,IAAI,OAAO,KAAK,SAAS,IAAI,OAAO,KAAK,IAAI,EAAE,CAAC;QAC9C,GAAG,CAAC,KAAK,GAAG,OAAO,CAAC,UAAU,CAAC;QAC/B,GAAG,CAAC,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC;IACnC,CAAC;AACH,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,GAAkC;IAC5D,OAAO,YAAY,CAAC,SAAS,EAAE,GAAG,EAAE,eAAe,EAAE,kBAAkB,CAAU,CAAC;AACpF,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,IAAmC;IACjE,OAAO;QACL,SAAS,EAAE,IAAI,EAAE,SAAS,IAAI,IAAI;QAClC,MAAM,EAAE,IAAI,EAAE,MAAM,IAAI,I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