@flighthq/types 0.4.0-next.1416.ef4fae7 → 0.4.0-next.1487.e25e95d

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.
@@ -2,10 +2,26 @@ import type { EffectSourceMode } from './EffectSourceMode';
2
2
  import type { RenderEffect } from './RenderEffect';
3
3
  export interface BevelEffect extends RenderEffect {
4
4
  kind: 'BevelEffect';
5
+ /**
6
+ * Direction of the light that casts the bevel, in DEGREES (default 45).
7
+ *
8
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
9
+ * displayed. Each runner converts into its own texcoord space at its own seam. 0 offsets to
10
+ * the RIGHT and 90 offsets DOWNWARD, the way an author reads the picture.
11
+ *
12
+ * ★ THE UNIT IS STATED ON EVERY ANGLE FIELD IN THE SDK, and this family is why. `DirectionalBlurEffect`
13
+ * and `HalftoneEffect` carried radians here while these four carried degrees, with nothing in either
14
+ * header saying so; they are all degrees now. Naming only "radians" or only "degrees" without the
15
+ * origin and sense is what let the whole class of defect through in the first place.
16
+ */
5
17
  angle?: number;
6
18
  bevelType?: 'full' | 'inner' | 'outer';
7
19
  blurX?: number;
8
20
  blurY?: number;
21
+ /**
22
+ * Length of the bevel offset in PIXELS along `angle` (default 4). A magnitude, so it carries no origin of
23
+ * its own — the convention that decides where the offset LANDS lives on `angle`.
24
+ */
9
25
  distance?: number;
10
26
  highlightAlpha?: number;
11
27
  highlightColor?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"BevelEffect.d.ts","sourceRoot":"","sources":["../src/BevelEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,WAAY,SAAQ,YAAY;IAC/C,IAAI,EAAE,aAAa,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IAIxB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IAGrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
1
+ {"version":3,"file":"BevelEffect.d.ts","sourceRoot":"","sources":["../src/BevelEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,WAAY,SAAQ,YAAY;IAC/C,IAAI,EAAE,aAAa,CAAC;IACpB;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IAIxB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IAGrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -1,6 +1,11 @@
1
1
  import type { RenderEffect } from './RenderEffect';
2
2
  export interface ContactShadowsEffect extends RenderEffect {
3
3
  kind: 'ContactShadowsEffect';
4
+ /**
5
+ * Occlusion search radius, as the normalized radius forwarded to the SSAO pass (default 0.5). A
6
+ * magnitude with no direction and no origin — it is NOT an offset like `DropShadowEffect.distance`,
7
+ * which is a pixel length along an angle. Named here so the two are not read as the same parameter.
8
+ */
4
9
  distance?: number;
5
10
  opacity?: number;
6
11
  samples?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"ContactShadowsEffect.d.ts","sourceRoot":"","sources":["../src/ContactShadowsEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,MAAM,WAAW,oBAAqB,SAAQ,YAAY;IACxD,IAAI,EAAE,sBAAsB,CAAC;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
1
+ {"version":3,"file":"ContactShadowsEffect.d.ts","sourceRoot":"","sources":["../src/ContactShadowsEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,MAAM,WAAW,oBAAqB,SAAQ,YAAY;IACxD,IAAI,EAAE,sBAAsB,CAAC;IAC7B;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
@@ -1,6 +1,18 @@
1
1
  import type { RenderEffect } from './RenderEffect';
2
2
  export interface DirectionalBlurEffect extends RenderEffect {
3
3
  kind: 'DirectionalBlurEffect';
4
+ /**
5
+ * Direction the frame is smeared along, in DEGREES (default 0).
6
+ *
7
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
8
+ * displayed. Each runner converts into its own texcoord space at its own seam. 0 smears
9
+ * HORIZONTALLY and 90 smears VERTICALLY DOWNWARD.
10
+ *
11
+ * ★ THIS FIELD WAS RADIANS UNTIL THE UNIT WAS UNIFIED, and it is where "a unit is not a convention"
12
+ * became visible: the header said "radians" and nothing else, which reads as documented and is not. A blur axis is symmetric
13
+ * under a half turn, so only an off-axis angle can show a Y-origin error here — which is why the
14
+ * scene uses a diagonal one.
15
+ */
4
16
  angle?: number;
5
17
  length?: number;
6
18
  samples?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"DirectionalBlurEffect.d.ts","sourceRoot":"","sources":["../src/DirectionalBlurEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,qBAAsB,SAAQ,YAAY;IACzD,IAAI,EAAE,uBAAuB,CAAC;IAC9B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
1
+ {"version":3,"file":"DirectionalBlurEffect.d.ts","sourceRoot":"","sources":["../src/DirectionalBlurEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,qBAAsB,SAAQ,YAAY;IACzD,IAAI,EAAE,uBAAuB,CAAC;IAC9B;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
@@ -3,10 +3,26 @@ import type { RenderEffect } from './RenderEffect';
3
3
  export interface DropShadowEffect extends RenderEffect {
4
4
  kind: 'DropShadowEffect';
5
5
  alpha?: number;
6
+ /**
7
+ * Direction of the shadow offset, in DEGREES (default 45).
8
+ *
9
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
10
+ * displayed. Each runner converts into its own texcoord space at its own seam. 0 offsets to
11
+ * the RIGHT and 90 offsets DOWNWARD, the way an author reads the picture.
12
+ *
13
+ * ★ THE UNIT IS STATED ON EVERY ANGLE FIELD IN THE SDK, and this family is why. `DirectionalBlurEffect`
14
+ * and `HalftoneEffect` carried radians here while these four carried degrees, with nothing in either
15
+ * header saying so; they are all degrees now. Naming only "radians" or only "degrees" without the
16
+ * origin and sense is what let the whole class of defect through in the first place.
17
+ */
6
18
  angle?: number;
7
19
  blurX?: number;
8
20
  blurY?: number;
9
21
  color?: number;
22
+ /**
23
+ * Length of the shadow offset in PIXELS along `angle` (default 4). A magnitude, so it carries no origin of
24
+ * its own — the convention that decides where the offset LANDS lives on `angle`.
25
+ */
10
26
  distance?: number;
11
27
  quality?: number;
12
28
  sourceMode?: EffectSourceMode;
@@ -1 +1 @@
1
- {"version":3,"file":"DropShadowEffect.d.ts","sourceRoot":"","sources":["../src/DropShadowEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,gBAAiB,SAAQ,YAAY;IACpD,IAAI,EAAE,kBAAkB,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IAIf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
1
+ {"version":3,"file":"DropShadowEffect.d.ts","sourceRoot":"","sources":["../src/DropShadowEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,gBAAiB,SAAQ,YAAY;IACpD,IAAI,EAAE,kBAAkB,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IAIf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -1,7 +1,26 @@
1
1
  import type { RenderEffect } from './RenderEffect';
2
2
  export interface GodRaysEffect extends RenderEffect {
3
3
  kind: 'GodRaysEffect';
4
+ /**
5
+ * The light's horizontal position as a fraction of the frame, 0 at the LEFT edge and 1 at the right.
6
+ *
7
+ * ★ THE ORIGIN IS PART OF THE CONTRACT, NOT THE BACKEND'S BUSINESS. See `centerY`.
8
+ */
4
9
  centerX?: number;
10
+ /**
11
+ * The light's vertical position as a fraction of the frame, **0 at the TOP edge and 1 at the bottom** —
12
+ * the same top-left origin the authoring layer uses everywhere else, so `centerY: 0.4` names the row a
13
+ * reader would call 40% down the picture.
14
+ *
15
+ * ★ THIS ORIGIN IS DECLARED BECAUSE ITS ABSENCE WAS A SHIPPED BUG. The two backends' effect passes use
16
+ * opposite texture-space conventions — Gl's fullscreen quad carries bottom-left-origin texcoords, Wgpu's
17
+ * carries top-left — and both runners forwarded this value untouched. The same `centerY: 0.4` therefore
18
+ * placed the light 240 px down on Wgpu and 360 px down on Gl: the rays radiated from different points,
19
+ * the shader text was identical on both sides, and nothing in the type said which one was right.
20
+ *
21
+ * A runner must NORMALISE this value into its own texture space at its own seam, exactly as the SDK
22
+ * converts degrees to radians at the authoring/math boundary rather than letting each caller guess.
23
+ */
5
24
  centerY?: number;
6
25
  density?: number;
7
26
  decay?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"GodRaysEffect.d.ts","sourceRoot":"","sources":["../src/GodRaysEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,aAAc,SAAQ,YAAY;IACjD,IAAI,EAAE,eAAe,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
1
+ {"version":3,"file":"GodRaysEffect.d.ts","sourceRoot":"","sources":["../src/GodRaysEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,aAAc,SAAQ,YAAY;IACjD,IAAI,EAAE,eAAe,CAAC;IACtB;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;;;;;;;;;;OAaG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
@@ -3,11 +3,27 @@ import type { RenderEffect } from './RenderEffect';
3
3
  export interface GradientBevelEffect extends RenderEffect {
4
4
  kind: 'GradientBevelEffect';
5
5
  alphas: ReadonlyArray<number>;
6
+ /**
7
+ * Direction of the light that casts the bevel, in DEGREES (default 45).
8
+ *
9
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
10
+ * displayed. Each runner converts into its own texcoord space at its own seam. 0 offsets to
11
+ * the RIGHT and 90 offsets DOWNWARD, the way an author reads the picture.
12
+ *
13
+ * ★ THE UNIT IS STATED ON EVERY ANGLE FIELD IN THE SDK, and this family is why. `DirectionalBlurEffect`
14
+ * and `HalftoneEffect` carried radians here while these four carried degrees, with nothing in either
15
+ * header saying so; they are all degrees now. Naming only "radians" or only "degrees" without the
16
+ * origin and sense is what let the whole class of defect through in the first place.
17
+ */
6
18
  angle?: number;
7
19
  bevelType?: 'full' | 'inner' | 'outer';
8
20
  blurX?: number;
9
21
  blurY?: number;
10
22
  colors: ReadonlyArray<number>;
23
+ /**
24
+ * Length of the bevel offset in PIXELS along `angle` (default 4). A magnitude, so it carries no origin of
25
+ * its own — the convention that decides where the offset LANDS lives on `angle`.
26
+ */
11
27
  distance?: number;
12
28
  quality?: number;
13
29
  ratios: ReadonlyArray<number>;
@@ -1 +1 @@
1
- {"version":3,"file":"GradientBevelEffect.d.ts","sourceRoot":"","sources":["../src/GradientBevelEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,mBAAoB,SAAQ,YAAY;IACvD,IAAI,EAAE,qBAAqB,CAAC;IAC5B,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
1
+ {"version":3,"file":"GradientBevelEffect.d.ts","sourceRoot":"","sources":["../src/GradientBevelEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,mBAAoB,SAAQ,YAAY;IACvD,IAAI,EAAE,qBAAqB,CAAC;IAC5B,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC9B,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -2,6 +2,15 @@ import type { RenderEffect } from './RenderEffect';
2
2
  export interface HalftoneEffect extends RenderEffect {
3
3
  kind: 'HalftoneEffect';
4
4
  scale?: number;
5
+ /**
6
+ * Rotation of the halftone dot grid, in DEGREES (default 45).
7
+ *
8
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
9
+ * displayed. Each runner converts into its own texcoord space at its own seam.
10
+ *
11
+ * Only an angle that is not a multiple of a quarter turn can reveal a Y-origin error, because the
12
+ * grid is symmetric under those; the default 45 is deliberately not one.
13
+ */
5
14
  angle?: number;
6
15
  }
7
16
  //# sourceMappingURL=HalftoneEffect.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"HalftoneEffect.d.ts","sourceRoot":"","sources":["../src/HalftoneEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,cAAe,SAAQ,YAAY;IAClD,IAAI,EAAE,gBAAgB,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
1
+ {"version":3,"file":"HalftoneEffect.d.ts","sourceRoot":"","sources":["../src/HalftoneEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,cAAe,SAAQ,YAAY;IAClD,IAAI,EAAE,gBAAgB,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;;;;;OAQG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
@@ -3,10 +3,26 @@ import type { RenderEffect } from './RenderEffect';
3
3
  export interface InnerShadowEffect extends RenderEffect {
4
4
  kind: 'InnerShadowEffect';
5
5
  alpha?: number;
6
+ /**
7
+ * Direction of the inner shadow offset, in DEGREES (default 45).
8
+ *
9
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
10
+ * displayed. Each runner converts into its own texcoord space at its own seam. 0 offsets to
11
+ * the RIGHT and 90 offsets DOWNWARD, the way an author reads the picture.
12
+ *
13
+ * ★ THE UNIT IS STATED ON EVERY ANGLE FIELD IN THE SDK, and this family is why. `DirectionalBlurEffect`
14
+ * and `HalftoneEffect` carried radians here while these four carried degrees, with nothing in either
15
+ * header saying so; they are all degrees now. Naming only "radians" or only "degrees" without the
16
+ * origin and sense is what let the whole class of defect through in the first place.
17
+ */
6
18
  angle?: number;
7
19
  blurX?: number;
8
20
  blurY?: number;
9
21
  color?: number;
22
+ /**
23
+ * Length of the inner shadow offset in PIXELS along `angle` (default 4). A magnitude, so it carries no origin of
24
+ * its own — the convention that decides where the offset LANDS lives on `angle`.
25
+ */
10
26
  distance?: number;
11
27
  quality?: number;
12
28
  sourceMode?: InnerEffectSourceMode;
@@ -1 +1 @@
1
- {"version":3,"file":"InnerShadowEffect.d.ts","sourceRoot":"","sources":["../src/InnerShadowEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,iBAAkB,SAAQ,YAAY;IACrD,IAAI,EAAE,mBAAmB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IAGf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,qBAAqB,CAAC;IACnC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
1
+ {"version":3,"file":"InnerShadowEffect.d.ts","sourceRoot":"","sources":["../src/InnerShadowEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAKnD,MAAM,WAAW,iBAAkB,SAAQ,YAAY;IACrD,IAAI,EAAE,mBAAmB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IAGf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,qBAAqB,CAAC;IACnC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -1,7 +1,22 @@
1
1
  import type { RenderEffect } from './RenderEffect';
2
2
  export interface RadialBlurEffect extends RenderEffect {
3
3
  kind: 'RadialBlurEffect';
4
+ /**
5
+ * Horizontal centre of the radial smear as a fraction of the frame, 0 at the LEFT edge and 1 at the
6
+ * right (default 0.5). X has the same origin on every backend, so no runner converts it.
7
+ */
4
8
  centerX?: number;
9
+ /**
10
+ * Vertical centre of the radial smear as a fraction of the frame, 0 at the TOP edge and 1 at the
11
+ * bottom (default 0.5).
12
+ *
13
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
14
+ * displayed. Each runner converts into its own texcoord space at its own seam.
15
+ *
16
+ * ★ THE Gl RUNNER FLIPS THIS AND THE Wgpu RUNNER DOES NOT, and both are correct: Gl's fullscreen
17
+ * quad is bottom-left origin and Wgpu's is top-left. A centred blur is its own mirror, so 0.5 cannot
18
+ * show a missing conversion — the scene uses an off-centre value for exactly that reason.
19
+ */
5
20
  centerY?: number;
6
21
  strength?: number;
7
22
  samples?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"RadialBlurEffect.d.ts","sourceRoot":"","sources":["../src/RadialBlurEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,gBAAiB,SAAQ,YAAY;IACpD,IAAI,EAAE,kBAAkB,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
1
+ {"version":3,"file":"RadialBlurEffect.d.ts","sourceRoot":"","sources":["../src/RadialBlurEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,gBAAiB,SAAQ,YAAY;IACpD,IAAI,EAAE,kBAAkB,CAAC;IACzB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;;;;;;;OAUG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB"}
@@ -1,6 +1,16 @@
1
1
  import type { RenderEffect } from './RenderEffect';
2
2
  export interface TiltShiftEffect extends RenderEffect {
3
3
  kind: 'TiltShiftEffect';
4
+ /**
5
+ * Centre of the focus band on Y, 0 at the TOP edge and 1 at the bottom — the same orientation an
6
+ * author reads the picture in, and the same convention GodRaysEffect.centerY uses.
7
+ *
8
+ * This is a value in the DESCRIPTOR's space, not in any backend's texture space. A runner must
9
+ * normalise it into its own at its own seam, exactly as the SDK converts degrees to radians: the Gl
10
+ * runner flips it because its fullscreen quad is bottom-left-origin, while the Wgpu and Canvas
11
+ * runners pass it straight through. A centred band cannot reveal a runner that skips the
12
+ * conversion, because the distance is symmetric about 0.5.
13
+ */
4
14
  center?: number;
5
15
  width?: number;
6
16
  blur?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"TiltShiftEffect.d.ts","sourceRoot":"","sources":["../src/TiltShiftEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,eAAgB,SAAQ,YAAY;IACnD,IAAI,EAAE,iBAAiB,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACf"}
1
+ {"version":3,"file":"TiltShiftEffect.d.ts","sourceRoot":"","sources":["../src/TiltShiftEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,eAAgB,SAAQ,YAAY;IACnD,IAAI,EAAE,iBAAiB,CAAC;IACxB;;;;;;;;;OASG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACf"}
@@ -3,7 +3,23 @@ export interface VolumetricLightEffect extends RenderEffect {
3
3
  kind: 'VolumetricLightEffect';
4
4
  density?: number;
5
5
  lightColor?: number;
6
+ /**
7
+ * Horizontal light position as a fraction of the frame, 0 at the LEFT edge and 1 at the right.
8
+ *
9
+ * ★ NOT YET REALIZED: no backend runner reads this field, so the convention above is the intended
10
+ * one rather than an observed one, and it is settled the day a runner is written.
11
+ */
6
12
  lightX?: number;
13
+ /**
14
+ * Vertical light position as a fraction of the frame, 0 at the TOP edge and 1 at the bottom.
15
+ *
16
+ * Screen space: origin top-left, +Y down, angles measured from +X toward +Y — clockwise as
17
+ * displayed. Each runner converts into its own texcoord space at its own seam.
18
+ *
19
+ * ★ NOT YET REALIZED: no backend runner reads this field, so a future runner on a bottom-left-origin
20
+ * target must convert at its own seam, exactly as `RadialBlurEffect.centerY` and
21
+ * `GodRaysEffect.centerY` do.
22
+ */
7
23
  lightY?: number;
8
24
  samples?: number;
9
25
  scattering?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"VolumetricLightEffect.d.ts","sourceRoot":"","sources":["../src/VolumetricLightEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,MAAM,WAAW,qBAAsB,SAAQ,YAAY;IACzD,IAAI,EAAE,uBAAuB,CAAC;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IAIjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
1
+ {"version":3,"file":"VolumetricLightEffect.d.ts","sourceRoot":"","sources":["../src/VolumetricLightEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,MAAM,WAAW,qBAAsB,SAAQ,YAAY;IACzD,IAAI,EAAE,uBAAuB,CAAC;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC;IAIjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;;;;;;OASG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flighthq/types",
3
- "version": "0.4.0-next.1416.ef4fae7",
3
+ "version": "0.4.0-next.1487.e25e95d",
4
4
  "author": "Joshua Granick and other contributors",
5
5
  "license": "MIT",
6
6
  "repository": {