@flighthq/effects 0.1.0 → 0.2.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 (144) hide show
  1. package/dist/bevelEffect.d.ts +3 -0
  2. package/dist/bevelEffect.d.ts.map +1 -0
  3. package/dist/bevelEffect.js +5 -0
  4. package/dist/bevelEffect.js.map +1 -0
  5. package/dist/blurDownsample.d.ts +17 -0
  6. package/dist/blurDownsample.d.ts.map +1 -0
  7. package/dist/blurDownsample.js +35 -0
  8. package/dist/blurDownsample.js.map +1 -0
  9. package/dist/blurEffect.d.ts +3 -0
  10. package/dist/blurEffect.d.ts.map +1 -0
  11. package/dist/blurEffect.js +7 -0
  12. package/dist/blurEffect.js.map +1 -0
  13. package/dist/boxBlurMath.d.ts +27 -0
  14. package/dist/boxBlurMath.d.ts.map +1 -0
  15. package/dist/boxBlurMath.js +64 -0
  16. package/dist/boxBlurMath.js.map +1 -0
  17. package/dist/convolutionEffect.d.ts +3 -0
  18. package/dist/convolutionEffect.d.ts.map +1 -0
  19. package/dist/convolutionEffect.js +4 -0
  20. package/dist/convolutionEffect.js.map +1 -0
  21. package/dist/dropShadowEffect.d.ts +3 -0
  22. package/dist/dropShadowEffect.d.ts.map +1 -0
  23. package/dist/dropShadowEffect.js +5 -0
  24. package/dist/dropShadowEffect.js.map +1 -0
  25. package/dist/gaussianKernel.d.ts +17 -0
  26. package/dist/gaussianKernel.d.ts.map +1 -0
  27. package/dist/gaussianKernel.js +49 -0
  28. package/dist/gaussianKernel.js.map +1 -0
  29. package/dist/gradientBevelEffect.d.ts +3 -0
  30. package/dist/gradientBevelEffect.d.ts.map +1 -0
  31. package/dist/gradientBevelEffect.js +5 -0
  32. package/dist/gradientBevelEffect.js.map +1 -0
  33. package/dist/gradientGlowEffect.d.ts +3 -0
  34. package/dist/gradientGlowEffect.d.ts.map +1 -0
  35. package/dist/gradientGlowEffect.js +5 -0
  36. package/dist/gradientGlowEffect.js.map +1 -0
  37. package/dist/index.d.ts +14 -12
  38. package/dist/index.d.ts.map +1 -1
  39. package/dist/index.js +14 -12
  40. package/dist/index.js.map +1 -1
  41. package/dist/innerGlowEffect.d.ts +3 -0
  42. package/dist/innerGlowEffect.d.ts.map +1 -0
  43. package/dist/innerGlowEffect.js +5 -0
  44. package/dist/innerGlowEffect.js.map +1 -0
  45. package/dist/innerShadowEffect.d.ts +3 -0
  46. package/dist/innerShadowEffect.d.ts.map +1 -0
  47. package/dist/innerShadowEffect.js +5 -0
  48. package/dist/innerShadowEffect.js.map +1 -0
  49. package/dist/linearSampledGaussian.d.ts +22 -0
  50. package/dist/linearSampledGaussian.d.ts.map +1 -0
  51. package/dist/linearSampledGaussian.js +56 -0
  52. package/dist/linearSampledGaussian.js.map +1 -0
  53. package/dist/medianEffect.d.ts +3 -0
  54. package/dist/medianEffect.d.ts.map +1 -0
  55. package/dist/medianEffect.js +4 -0
  56. package/dist/medianEffect.js.map +1 -0
  57. package/dist/outerGlowEffect.d.ts +3 -0
  58. package/dist/outerGlowEffect.d.ts.map +1 -0
  59. package/dist/outerGlowEffect.js +5 -0
  60. package/dist/outerGlowEffect.js.map +1 -0
  61. package/dist/renderEffectDefaults.js +22 -20
  62. package/dist/renderEffectDefaults.js.map +1 -1
  63. package/dist/renderEffectInputs.d.ts.map +1 -1
  64. package/dist/renderEffectInputs.js +10 -11
  65. package/dist/renderEffectInputs.js.map +1 -1
  66. package/package.json +7 -2
  67. package/src/bevelEffect.test.ts +11 -0
  68. package/src/blurDownsample.test.ts +46 -0
  69. package/src/blurEffect.test.ts +17 -0
  70. package/src/boxBlurMath.test.ts +96 -0
  71. package/src/convolutionEffect.test.ts +20 -0
  72. package/src/dropShadowEffect.test.ts +11 -0
  73. package/src/gaussianKernel.test.ts +80 -0
  74. package/src/gradientBevelEffect.test.ts +15 -0
  75. package/src/gradientGlowEffect.test.ts +15 -0
  76. package/src/innerGlowEffect.test.ts +11 -0
  77. package/src/innerShadowEffect.test.ts +11 -0
  78. package/src/linearSampledGaussian.test.ts +87 -0
  79. package/src/medianEffect.test.ts +11 -0
  80. package/src/outerGlowEffect.test.ts +11 -0
  81. package/src/renderEffectDefaults.test.ts +4 -5
  82. package/src/renderEffectInputs.test.ts +3 -5
  83. package/src/renderEffectInterpolation.test.ts +6 -9
  84. package/src/renderEffectValidation.test.ts +2 -2
  85. package/dist/brightnessContrastEffect.d.ts +0 -3
  86. package/dist/brightnessContrastEffect.d.ts.map +0 -1
  87. package/dist/brightnessContrastEffect.js +0 -4
  88. package/dist/brightnessContrastEffect.js.map +0 -1
  89. package/dist/channelMixerEffect.d.ts +0 -3
  90. package/dist/channelMixerEffect.d.ts.map +0 -1
  91. package/dist/channelMixerEffect.js +0 -4
  92. package/dist/channelMixerEffect.js.map +0 -1
  93. package/dist/colorBlindSimulationEffect.d.ts +0 -3
  94. package/dist/colorBlindSimulationEffect.d.ts.map +0 -1
  95. package/dist/colorBlindSimulationEffect.js +0 -4
  96. package/dist/colorBlindSimulationEffect.js.map +0 -1
  97. package/dist/colorGradeEffect.d.ts +0 -3
  98. package/dist/colorGradeEffect.d.ts.map +0 -1
  99. package/dist/colorGradeEffect.js +0 -4
  100. package/dist/colorGradeEffect.js.map +0 -1
  101. package/dist/exposureEffect.d.ts +0 -3
  102. package/dist/exposureEffect.d.ts.map +0 -1
  103. package/dist/exposureEffect.js +0 -4
  104. package/dist/exposureEffect.js.map +0 -1
  105. package/dist/grayscaleEffect.d.ts +0 -3
  106. package/dist/grayscaleEffect.d.ts.map +0 -1
  107. package/dist/grayscaleEffect.js +0 -4
  108. package/dist/grayscaleEffect.js.map +0 -1
  109. package/dist/hueSaturationEffect.d.ts +0 -3
  110. package/dist/hueSaturationEffect.d.ts.map +0 -1
  111. package/dist/hueSaturationEffect.js +0 -4
  112. package/dist/hueSaturationEffect.js.map +0 -1
  113. package/dist/invertEffect.d.ts +0 -3
  114. package/dist/invertEffect.d.ts.map +0 -1
  115. package/dist/invertEffect.js +0 -4
  116. package/dist/invertEffect.js.map +0 -1
  117. package/dist/liftGammaGainEffect.d.ts +0 -3
  118. package/dist/liftGammaGainEffect.d.ts.map +0 -1
  119. package/dist/liftGammaGainEffect.js +0 -4
  120. package/dist/liftGammaGainEffect.js.map +0 -1
  121. package/dist/lookupTableGradeEffect.d.ts +0 -3
  122. package/dist/lookupTableGradeEffect.d.ts.map +0 -1
  123. package/dist/lookupTableGradeEffect.js +0 -4
  124. package/dist/lookupTableGradeEffect.js.map +0 -1
  125. package/dist/lutMath.d.ts +0 -7
  126. package/dist/lutMath.d.ts.map +0 -1
  127. package/dist/lutMath.js +0 -39
  128. package/dist/lutMath.js.map +0 -1
  129. package/dist/sepiaEffect.d.ts +0 -3
  130. package/dist/sepiaEffect.d.ts.map +0 -1
  131. package/dist/sepiaEffect.js +0 -4
  132. package/dist/sepiaEffect.js.map +0 -1
  133. package/src/brightnessContrastEffect.test.ts +0 -14
  134. package/src/channelMixerEffect.test.ts +0 -12
  135. package/src/colorBlindSimulationEffect.test.ts +0 -13
  136. package/src/colorGradeEffect.test.ts +0 -11
  137. package/src/exposureEffect.test.ts +0 -7
  138. package/src/grayscaleEffect.test.ts +0 -11
  139. package/src/hueSaturationEffect.test.ts +0 -15
  140. package/src/invertEffect.test.ts +0 -11
  141. package/src/liftGammaGainEffect.test.ts +0 -15
  142. package/src/lookupTableGradeEffect.test.ts +0 -11
  143. package/src/lutMath.test.ts +0 -67
  144. package/src/sepiaEffect.test.ts +0 -11
@@ -0,0 +1,87 @@
1
+ import { computeGaussianKernelWeights, getGaussianKernelSize } from './gaussianKernel';
2
+ import { computeLinearSampledGaussian, getLinearSampledGaussianTapCount } from './linearSampledGaussian';
3
+
4
+ describe('computeLinearSampledGaussian', () => {
5
+ const sumOf = (weights: ReadonlyArray<number>): number => weights.reduce((total, weight) => total + weight, 0);
6
+
7
+ it('produces combined weights that sum to 1', () => {
8
+ for (const sigma of [1, 2, 3.5, 6]) {
9
+ const weights: number[] = [];
10
+ const offsets: number[] = [];
11
+ computeLinearSampledGaussian(sigma, weights, offsets);
12
+ expect(sumOf(weights)).toBeCloseTo(1, 12);
13
+ }
14
+ });
15
+
16
+ it('sizes both arrays to the tap count', () => {
17
+ const weights: number[] = [];
18
+ const offsets: number[] = [];
19
+ computeLinearSampledGaussian(3, weights, offsets);
20
+ const tapCount = getLinearSampledGaussianTapCount(3);
21
+ expect(weights.length).toBe(tapCount);
22
+ expect(offsets.length).toBe(tapCount);
23
+ });
24
+
25
+ it('sets each paired offset to the weighted midpoint of its two texels', () => {
26
+ const sigma = 2;
27
+ const discrete: number[] = [];
28
+ computeGaussianKernelWeights(sigma, discrete);
29
+ const radius = (getGaussianKernelSize(sigma) - 1) / 2;
30
+
31
+ const weights: number[] = [];
32
+ const offsets: number[] = [];
33
+ computeLinearSampledGaussian(sigma, weights, offsets);
34
+
35
+ for (let tap = 0; tap < weights.length; tap++) {
36
+ const i = tap * 2;
37
+ const posA = i - radius;
38
+ if (i + 1 < discrete.length) {
39
+ const weightA = discrete[i];
40
+ const weightB = discrete[i + 1];
41
+ expect(weights[tap]).toBeCloseTo(weightA + weightB, 12);
42
+ const midpoint = (posA * weightA + (posA + 1) * weightB) / (weightA + weightB);
43
+ expect(offsets[tap]).toBeCloseTo(midpoint, 12);
44
+ // The bilinear tap samples strictly between its two source texels.
45
+ expect(offsets[tap]).toBeGreaterThanOrEqual(posA);
46
+ expect(offsets[tap]).toBeLessThanOrEqual(posA + 1);
47
+ } else {
48
+ // Odd kernel: the last texel is emitted alone at its integer offset.
49
+ expect(weights[tap]).toBeCloseTo(discrete[i], 12);
50
+ expect(offsets[tap]).toBe(posA);
51
+ }
52
+ }
53
+ });
54
+
55
+ it('reconstructs the discrete kernel mass at each tap', () => {
56
+ // A bilinear read at a fractional offset returns the linear blend of the two texels weighted by
57
+ // the tap weight; summed over the pair that equals w[i]+w[i+1] applied at those two positions.
58
+ const sigma = 3;
59
+ const discrete: number[] = [];
60
+ computeGaussianKernelWeights(sigma, discrete);
61
+ const weights: number[] = [];
62
+ const offsets: number[] = [];
63
+ computeLinearSampledGaussian(sigma, weights, offsets);
64
+ expect(sumOf(weights)).toBeCloseTo(sumOf(discrete), 12);
65
+ });
66
+
67
+ it('returns outWeights', () => {
68
+ const weights: number[] = [];
69
+ const offsets: number[] = [];
70
+ expect(computeLinearSampledGaussian(2, weights, offsets)).toBe(weights);
71
+ });
72
+ });
73
+
74
+ describe('getLinearSampledGaussianTapCount', () => {
75
+ it('is ceil(kernelSize / 2)', () => {
76
+ for (const sigma of [1, 2, 3.5, 6]) {
77
+ expect(getLinearSampledGaussianTapCount(sigma)).toBe(Math.ceil(getGaussianKernelSize(sigma) / 2));
78
+ }
79
+ });
80
+
81
+ it('roughly halves the discrete tap count', () => {
82
+ const discrete = getGaussianKernelSize(4);
83
+ const linear = getLinearSampledGaussianTapCount(4);
84
+ expect(linear).toBeLessThan(discrete);
85
+ expect(linear).toBe(Math.ceil(discrete / 2));
86
+ });
87
+ });
@@ -0,0 +1,11 @@
1
+ import { createMedianEffect } from './medianEffect';
2
+
3
+ describe('createMedianEffect', () => {
4
+ it('tags the intent type', () => {
5
+ expect(createMedianEffect().kind).toBe('MedianEffect');
6
+ });
7
+
8
+ it('carries options', () => {
9
+ expect(createMedianEffect({ radius: 2 })).toMatchObject({ radius: 2 });
10
+ });
11
+ });
@@ -0,0 +1,11 @@
1
+ import { createOuterGlowEffect } from './outerGlowEffect';
2
+
3
+ describe('createOuterGlowEffect', () => {
4
+ it('tags the intent type', () => {
5
+ expect(createOuterGlowEffect().kind).toBe('OuterGlowEffect');
6
+ });
7
+
8
+ it('carries options', () => {
9
+ expect(createOuterGlowEffect({ strength: 2 })).toMatchObject({ strength: 2 });
10
+ });
11
+ });
@@ -1,7 +1,6 @@
1
- import type { BloomEffect, GrayscaleEffect, RenderEffect, ToneMapEffect, VignetteEffect } from '@flighthq/types';
1
+ import type { BloomEffect, RenderEffect, ToneMapEffect, VignetteEffect } from '@flighthq/types';
2
2
 
3
3
  import { createBloomEffect } from './bloomEffect';
4
- import { createGrayscaleEffect } from './grayscaleEffect';
5
4
  import { getRenderEffectDefaults, normalizeRenderEffect } from './renderEffectDefaults';
6
5
  import { createToneMapEffect } from './toneMapEffect';
7
6
  import { createVignetteEffect } from './vignetteEffect';
@@ -42,10 +41,10 @@ describe('normalizeRenderEffect', () => {
42
41
  expect(out.radius).toBe(8); // filled from defaults
43
42
  });
44
43
  it('preserves explicitly set zero and false', () => {
45
- const effect = createGrayscaleEffect({ intensity: 0 });
46
- const out = { kind: 'GrayscaleEffect' } as GrayscaleEffect;
44
+ const effect = createBloomEffect({ threshold: 0 });
45
+ const out = { kind: 'BloomEffect' } as BloomEffect;
47
46
  normalizeRenderEffect(effect, out);
48
- expect(out.intensity).toBe(0); // 0 is explicit, should not be replaced by default 1
47
+ expect(out.threshold).toBe(0); // 0 is explicit, should not be replaced by default 0.8
49
48
  });
50
49
  it('carries over fields not in the defaults table', () => {
51
50
  const effect = createVignetteEffect({ intensity: 0.3 });
@@ -1,11 +1,10 @@
1
1
  import { createBloomEffect } from './bloomEffect';
2
2
  import { createBokehDepthOfFieldEffect } from './bokehDepthOfFieldEffect';
3
- import { createColorGradeEffect } from './colorGradeEffect';
4
- import { createGrayscaleEffect } from './grayscaleEffect';
5
3
  import { getRenderEffectInputs, getRenderEffectKinds, RENDER_EFFECT_KINDS } from './renderEffectInputs';
6
4
  import { createSsaoEffect } from './ssaoEffect';
7
5
  import { createTaaEffect } from './taaEffect';
8
6
  import { createToneMapEffect } from './toneMapEffect';
7
+ import { createVignetteEffect } from './vignetteEffect';
9
8
 
10
9
  describe('getRenderEffectInputs', () => {
11
10
  it('returns Hdr for BloomEffect', () => {
@@ -29,8 +28,7 @@ describe('getRenderEffectInputs', () => {
29
28
  });
30
29
 
31
30
  it('returns empty array for effects that need only the color buffer', () => {
32
- expect(getRenderEffectInputs(createGrayscaleEffect())).toEqual([]);
33
- expect(getRenderEffectInputs(createColorGradeEffect())).toEqual([]);
31
+ expect(getRenderEffectInputs(createVignetteEffect())).toEqual([]);
34
32
  });
35
33
 
36
34
  it('returns empty array for unknown kind', () => {
@@ -44,7 +42,7 @@ describe('getRenderEffectKinds', () => {
44
42
  expect(kinds).toContain('BloomEffect');
45
43
  expect(kinds).toContain('ToneMapEffect');
46
44
  expect(kinds).toContain('SsaoEffect');
47
- expect(kinds).toContain('GrayscaleEffect');
45
+ expect(kinds).toContain('VignetteEffect');
48
46
  });
49
47
 
50
48
  it('returns the same reference as RENDER_EFFECT_KINDS', () => {
@@ -1,23 +1,20 @@
1
- import type { GrayscaleEffect } from '@flighthq/types';
2
-
3
1
  import { createBloomEffect } from './bloomEffect';
4
- import { createColorGradeEffect } from './colorGradeEffect';
5
- import { createGrayscaleEffect } from './grayscaleEffect';
6
2
  import { canLerpRenderEffects, lerpRenderEffect } from './renderEffectInterpolation';
3
+ import { createVignetteEffect } from './vignetteEffect';
7
4
 
8
5
  describe('canLerpRenderEffects', () => {
9
6
  it('returns true for same kind', () => {
10
7
  expect(canLerpRenderEffects(createBloomEffect(), createBloomEffect())).toBe(true);
11
8
  });
12
9
  it('returns false for different kinds', () => {
13
- expect(canLerpRenderEffects(createBloomEffect(), createColorGradeEffect())).toBe(false);
10
+ expect(canLerpRenderEffects(createBloomEffect(), createVignetteEffect())).toBe(false);
14
11
  });
15
12
  });
16
13
 
17
14
  describe('lerpRenderEffect', () => {
18
15
  it('returns false and leaves out unchanged for mismatched kinds', () => {
19
16
  const a = createBloomEffect({ threshold: 0.5 });
20
- const b = createColorGradeEffect({ exposure: 1 });
17
+ const b = createVignetteEffect({ intensity: 1 });
21
18
  const out = createBloomEffect({ threshold: 0.99 });
22
19
  const result = lerpRenderEffect(a, b, 0.5, out);
23
20
  expect(result).toBe(false);
@@ -60,9 +57,9 @@ describe('lerpRenderEffect', () => {
60
57
  expect(a.threshold).toBeCloseTo(0.5, 5);
61
58
  });
62
59
  it('boolean fields snap at t=0.5 boundary', () => {
63
- const a = createGrayscaleEffect({ enabled: false } as Partial<GrayscaleEffect>);
64
- const b = createGrayscaleEffect({ enabled: true } as Partial<GrayscaleEffect>);
65
- const out = createGrayscaleEffect();
60
+ const a = createVignetteEffect({ enabled: false } as never);
61
+ const b = createVignetteEffect({ enabled: true } as never);
62
+ const out = createVignetteEffect();
66
63
  lerpRenderEffect(a, b, 0.4, out);
67
64
  expect((out as unknown as Record<string, unknown>).enabled).toBe(false);
68
65
  lerpRenderEffect(a, b, 0.5, out);
@@ -1,8 +1,8 @@
1
1
  import { createBloomEffect } from './bloomEffect';
2
- import { createColorGradeEffect } from './colorGradeEffect';
3
2
  import { validateRenderEffectList } from './renderEffectValidation';
4
3
  import { createSsaoEffect } from './ssaoEffect';
5
4
  import { createToneMapEffect } from './toneMapEffect';
5
+ import { createVignetteEffect } from './vignetteEffect';
6
6
 
7
7
  describe('validateRenderEffectList', () => {
8
8
  it('returns null when all required inputs are available', () => {
@@ -11,7 +11,7 @@ describe('validateRenderEffectList', () => {
11
11
  });
12
12
 
13
13
  it('returns null for effects that need only the color buffer', () => {
14
- const effects = [createColorGradeEffect()];
14
+ const effects = [createVignetteEffect()];
15
15
  expect(validateRenderEffectList(effects, [])).toBeNull();
16
16
  });
17
17
 
@@ -1,3 +0,0 @@
1
- import type { BrightnessContrastEffect } from '@flighthq/types';
2
- export declare function createBrightnessContrastEffect(options?: Readonly<Omit<BrightnessContrastEffect, 'kind'>>): BrightnessContrastEffect;
3
- //# sourceMappingURL=brightnessContrastEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"brightnessContrastEffect.d.ts","sourceRoot":"","sources":["../src/brightnessContrastEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAEhE,wBAAgB,8BAA8B,CAC5C,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,wBAAwB,EAAE,MAAM,CAAC,CAAM,GAC7D,wBAAwB,CAE1B"}
@@ -1,4 +0,0 @@
1
- export function createBrightnessContrastEffect(options = {}) {
2
- return { kind: 'BrightnessContrastEffect', ...options };
3
- }
4
- //# sourceMappingURL=brightnessContrastEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"brightnessContrastEffect.js","sourceRoot":"","sources":["../src/brightnessContrastEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,8BAA8B,CAC5C,UAA4D,EAAE;IAE9D,OAAO,EAAE,IAAI,EAAE,0BAA0B,EAAE,GAAG,OAAO,EAAE,CAAC;AAC1D,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ChannelMixerEffect } from '@flighthq/types';
2
- export declare function createChannelMixerEffect(options: Readonly<Omit<ChannelMixerEffect, 'kind'>>): ChannelMixerEffect;
3
- //# sourceMappingURL=channelMixerEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"channelMixerEffect.d.ts","sourceRoot":"","sources":["../src/channelMixerEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAE1D,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,QAAQ,CAAC,IAAI,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAC,GAAG,kBAAkB,CAEhH"}
@@ -1,4 +0,0 @@
1
- export function createChannelMixerEffect(options) {
2
- return { kind: 'ChannelMixerEffect', ...options };
3
- }
4
- //# sourceMappingURL=channelMixerEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"channelMixerEffect.js","sourceRoot":"","sources":["../src/channelMixerEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,wBAAwB,CAAC,OAAmD;IAC1F,OAAO,EAAE,IAAI,EAAE,oBAAoB,EAAE,GAAG,OAAO,EAAE,CAAC;AACpD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ColorBlindSimulationEffect } from '@flighthq/types';
2
- export declare function createColorBlindSimulationEffect(options?: Readonly<Omit<ColorBlindSimulationEffect, 'kind'>>): ColorBlindSimulationEffect;
3
- //# sourceMappingURL=colorBlindSimulationEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colorBlindSimulationEffect.d.ts","sourceRoot":"","sources":["../src/colorBlindSimulationEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAC;AAElE,wBAAgB,gCAAgC,CAC9C,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,0BAA0B,EAAE,MAAM,CAAC,CAAM,GAC/D,0BAA0B,CAE5B"}
@@ -1,4 +0,0 @@
1
- export function createColorBlindSimulationEffect(options = {}) {
2
- return { kind: 'ColorBlindSimulationEffect', ...options };
3
- }
4
- //# sourceMappingURL=colorBlindSimulationEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colorBlindSimulationEffect.js","sourceRoot":"","sources":["../src/colorBlindSimulationEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,gCAAgC,CAC9C,UAA8D,EAAE;IAEhE,OAAO,EAAE,IAAI,EAAE,4BAA4B,EAAE,GAAG,OAAO,EAAE,CAAC;AAC5D,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ColorGradeEffect } from '@flighthq/types';
2
- export declare function createColorGradeEffect(options?: Readonly<Omit<ColorGradeEffect, 'kind'>>): ColorGradeEffect;
3
- //# sourceMappingURL=colorGradeEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colorGradeEffect.d.ts","sourceRoot":"","sources":["../src/colorGradeEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAExD,wBAAgB,sBAAsB,CAAC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,gBAAgB,EAAE,MAAM,CAAC,CAAM,GAAG,gBAAgB,CAE/G"}
@@ -1,4 +0,0 @@
1
- export function createColorGradeEffect(options = {}) {
2
- return { kind: 'ColorGradeEffect', ...options };
3
- }
4
- //# sourceMappingURL=colorGradeEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"colorGradeEffect.js","sourceRoot":"","sources":["../src/colorGradeEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,sBAAsB,CAAC,UAAoD,EAAE;IAC3F,OAAO,EAAE,IAAI,EAAE,kBAAkB,EAAE,GAAG,OAAO,EAAE,CAAC;AAClD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ExposureEffect } from '@flighthq/types';
2
- export declare function createExposureEffect(options?: Readonly<Omit<ExposureEffect, 'kind'>>): ExposureEffect;
3
- //# sourceMappingURL=exposureEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"exposureEffect.d.ts","sourceRoot":"","sources":["../src/exposureEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAEtD,wBAAgB,oBAAoB,CAAC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,cAAc,EAAE,MAAM,CAAC,CAAM,GAAG,cAAc,CAEzG"}
@@ -1,4 +0,0 @@
1
- export function createExposureEffect(options = {}) {
2
- return { kind: 'ExposureEffect', ...options };
3
- }
4
- //# sourceMappingURL=exposureEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"exposureEffect.js","sourceRoot":"","sources":["../src/exposureEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,oBAAoB,CAAC,UAAkD,EAAE;IACvF,OAAO,EAAE,IAAI,EAAE,gBAAgB,EAAE,GAAG,OAAO,EAAE,CAAC;AAChD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { GrayscaleEffect } from '@flighthq/types';
2
- export declare function createGrayscaleEffect(options?: Readonly<Omit<GrayscaleEffect, 'kind'>>): GrayscaleEffect;
3
- //# sourceMappingURL=grayscaleEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"grayscaleEffect.d.ts","sourceRoot":"","sources":["../src/grayscaleEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAEvD,wBAAgB,qBAAqB,CAAC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,eAAe,EAAE,MAAM,CAAC,CAAM,GAAG,eAAe,CAE5G"}
@@ -1,4 +0,0 @@
1
- export function createGrayscaleEffect(options = {}) {
2
- return { kind: 'GrayscaleEffect', ...options };
3
- }
4
- //# sourceMappingURL=grayscaleEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"grayscaleEffect.js","sourceRoot":"","sources":["../src/grayscaleEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,qBAAqB,CAAC,UAAmD,EAAE;IACzF,OAAO,EAAE,IAAI,EAAE,iBAAiB,EAAE,GAAG,OAAO,EAAE,CAAC;AACjD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { HueSaturationEffect } from '@flighthq/types';
2
- export declare function createHueSaturationEffect(options?: Readonly<Omit<HueSaturationEffect, 'kind'>>): HueSaturationEffect;
3
- //# sourceMappingURL=hueSaturationEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"hueSaturationEffect.d.ts","sourceRoot":"","sources":["../src/hueSaturationEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAE3D,wBAAgB,yBAAyB,CACvC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,mBAAmB,EAAE,MAAM,CAAC,CAAM,GACxD,mBAAmB,CAErB"}
@@ -1,4 +0,0 @@
1
- export function createHueSaturationEffect(options = {}) {
2
- return { kind: 'HueSaturationEffect', ...options };
3
- }
4
- //# sourceMappingURL=hueSaturationEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"hueSaturationEffect.js","sourceRoot":"","sources":["../src/hueSaturationEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,yBAAyB,CACvC,UAAuD,EAAE;IAEzD,OAAO,EAAE,IAAI,EAAE,qBAAqB,EAAE,GAAG,OAAO,EAAE,CAAC;AACrD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { InvertEffect } from '@flighthq/types';
2
- export declare function createInvertEffect(options?: Readonly<Omit<InvertEffect, 'kind'>>): InvertEffect;
3
- //# sourceMappingURL=invertEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"invertEffect.d.ts","sourceRoot":"","sources":["../src/invertEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAEpD,wBAAgB,kBAAkB,CAAC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE,MAAM,CAAC,CAAM,GAAG,YAAY,CAEnG"}
@@ -1,4 +0,0 @@
1
- export function createInvertEffect(options = {}) {
2
- return { kind: 'InvertEffect', ...options };
3
- }
4
- //# sourceMappingURL=invertEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"invertEffect.js","sourceRoot":"","sources":["../src/invertEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,kBAAkB,CAAC,UAAgD,EAAE;IACnF,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,GAAG,OAAO,EAAE,CAAC;AAC9C,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { LiftGammaGainEffect } from '@flighthq/types';
2
- export declare function createLiftGammaGainEffect(options?: Readonly<Omit<LiftGammaGainEffect, 'kind'>>): LiftGammaGainEffect;
3
- //# sourceMappingURL=liftGammaGainEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"liftGammaGainEffect.d.ts","sourceRoot":"","sources":["../src/liftGammaGainEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAE3D,wBAAgB,yBAAyB,CACvC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,mBAAmB,EAAE,MAAM,CAAC,CAAM,GACxD,mBAAmB,CAErB"}
@@ -1,4 +0,0 @@
1
- export function createLiftGammaGainEffect(options = {}) {
2
- return { kind: 'LiftGammaGainEffect', ...options };
3
- }
4
- //# sourceMappingURL=liftGammaGainEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"liftGammaGainEffect.js","sourceRoot":"","sources":["../src/liftGammaGainEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,yBAAyB,CACvC,UAAuD,EAAE;IAEzD,OAAO,EAAE,IAAI,EAAE,qBAAqB,EAAE,GAAG,OAAO,EAAE,CAAC;AACrD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { LookupTableGradeEffect } from '@flighthq/types';
2
- export declare function createLookupTableGradeEffect(options?: Readonly<Omit<LookupTableGradeEffect, 'kind'>>): LookupTableGradeEffect;
3
- //# sourceMappingURL=lookupTableGradeEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lookupTableGradeEffect.d.ts","sourceRoot":"","sources":["../src/lookupTableGradeEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAE9D,wBAAgB,4BAA4B,CAC1C,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,sBAAsB,EAAE,MAAM,CAAC,CAAM,GAC3D,sBAAsB,CAExB"}
@@ -1,4 +0,0 @@
1
- export function createLookupTableGradeEffect(options = {}) {
2
- return { kind: 'LookupTableGradeEffect', ...options };
3
- }
4
- //# sourceMappingURL=lookupTableGradeEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lookupTableGradeEffect.js","sourceRoot":"","sources":["../src/lookupTableGradeEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,4BAA4B,CAC1C,UAA0D,EAAE;IAE5D,OAAO,EAAE,IAAI,EAAE,wBAAwB,EAAE,GAAG,OAAO,EAAE,CAAC;AACxD,CAAC"}
package/dist/lutMath.d.ts DELETED
@@ -1,7 +0,0 @@
1
- export declare function computeLookupTableCoord(r: number, // normalized R channel [0..1].
2
- g: number, // normalized G channel [0..1].
3
- b: number, // normalized B channel [0..1].
4
- lutSize: number, // cube size of the LUT (e.g. 16, 32, 64).
5
- out: [number, number]): void;
6
- export declare function getLookupTableTileLayout(lutSize: number, out: [number, number]): void;
7
- //# sourceMappingURL=lutMath.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lutMath.d.ts","sourceRoot":"","sources":["../src/lutMath.ts"],"names":[],"mappings":"AASA,wBAAgB,uBAAuB,CACrC,CAAC,EAAE,MAAM,EAAE,+BAA+B;AAC1C,CAAC,EAAE,MAAM,EAAE,+BAA+B;AAC1C,CAAC,EAAE,MAAM,EAAE,+BAA+B;AAC1C,OAAO,EAAE,MAAM,EAAE,0CAA0C;AAC3D,GAAG,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,GACpB,IAAI,CAiBN;AAKD,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,IAAI,CAIrF"}
package/dist/lutMath.js DELETED
@@ -1,39 +0,0 @@
1
- // LUT (lookup-table) recipe math for LookupTableGradeEffect. Substrate-agnostic helpers for
2
- // sampling 3D color LUTs stored as 2D strip-encoded textures. All functions are alias-safe.
3
- // Computes the UV coordinate in the 2D strip-encoded LUT texture that corresponds to an RGB color.
4
- // A 3D LUT of size N is encoded as a horizontal strip of N² tiles each of size N×1:
5
- // U encodes the B channel (tile index + R-within-tile).
6
- // V encodes the G channel (row within the strip, normalized to [0,1]).
7
- // Writes [u, v] into `out`. Caller applies bilinear filtering.
8
- // Alias-safe.
9
- export function computeLookupTableCoord(r, // normalized R channel [0..1].
10
- g, // normalized G channel [0..1].
11
- b, // normalized B channel [0..1].
12
- lutSize, // cube size of the LUT (e.g. 16, 32, 64).
13
- out) {
14
- const n = Math.max(1, lutSize);
15
- const halfTexel = 0.5 / n;
16
- // Clamp inputs to avoid bleeding at the LUT boundary.
17
- const rc = Math.max(0, Math.min(1, r));
18
- const gc = Math.max(0, Math.min(1, g));
19
- const bc = Math.max(0, Math.min(1, b));
20
- // B determines which horizontal tile (0..n-1).
21
- const bSlice = bc * (n - 1);
22
- const bIndex = Math.floor(bSlice);
23
- // U: tile offset + R within the tile.
24
- const u = (bIndex + rc * (1 - 1 / n) + halfTexel) / n;
25
- // V: G channel (one row per G step, stored bottom-to-top; some encoders are inverted — callers
26
- // can flip V if needed for their texture's storage convention).
27
- const v = gc * (1 - 1 / n) + halfTexel;
28
- out[0] = u;
29
- out[1] = v;
30
- }
31
- // Returns the [width, height] in pixels of the 2D strip texture required to store a 3D LUT of
32
- // the given cube size. Width = size², height = size (one row of G steps).
33
- // Writes [width, height] into `out`.
34
- export function getLookupTableTileLayout(lutSize, out) {
35
- const n = Math.max(1, lutSize);
36
- out[0] = n * n; // width: n tiles × n pixels each.
37
- out[1] = n; // height: one row per G step.
38
- }
39
- //# sourceMappingURL=lutMath.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lutMath.js","sourceRoot":"","sources":["../src/lutMath.ts"],"names":[],"mappings":"AAAA,4FAA4F;AAC5F,4FAA4F;AAE5F,mGAAmG;AACnG,oFAAoF;AACpF,0DAA0D;AAC1D,yEAAyE;AACzE,+DAA+D;AAC/D,cAAc;AACd,MAAM,UAAU,uBAAuB,CACrC,CAAS,EAAE,+BAA+B;AAC1C,CAAS,EAAE,+BAA+B;AAC1C,CAAS,EAAE,+BAA+B;AAC1C,OAAe,EAAE,0CAA0C;AAC3D,GAAqB;IAErB,MAAM,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;IAC/B,MAAM,SAAS,GAAG,GAAG,GAAG,CAAC,CAAC;IAC1B,sDAAsD;IACtD,MAAM,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IACvC,MAAM,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IACvC,MAAM,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IACvC,+CAA+C;IAC/C,MAAM,MAAM,GAAG,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC5B,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IAClC,sCAAsC;IACtC,MAAM,CAAC,GAAG,CAAC,MAAM,GAAG,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC;IACtD,+FAA+F;IAC/F,gEAAgE;IAChE,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,GAAG,SAAS,CAAC;IACvC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACX,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;AACb,CAAC;AAED,8FAA8F;AAC9F,0EAA0E;AAC1E,qCAAqC;AACrC,MAAM,UAAU,wBAAwB,CAAC,OAAe,EAAE,GAAqB;IAC7E,MAAM,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;IAC/B,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC,kCAAkC;IAClD,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,8BAA8B;AAC5C,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { SepiaEffect } from '@flighthq/types';
2
- export declare function createSepiaEffect(options?: Readonly<Omit<SepiaEffect, 'kind'>>): SepiaEffect;
3
- //# sourceMappingURL=sepiaEffect.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"sepiaEffect.d.ts","sourceRoot":"","sources":["../src/sepiaEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,wBAAgB,iBAAiB,CAAC,OAAO,GAAE,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC,CAAM,GAAG,WAAW,CAEhG"}
@@ -1,4 +0,0 @@
1
- export function createSepiaEffect(options = {}) {
2
- return { kind: 'SepiaEffect', ...options };
3
- }
4
- //# sourceMappingURL=sepiaEffect.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"sepiaEffect.js","sourceRoot":"","sources":["../src/sepiaEffect.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,iBAAiB,CAAC,UAA+C,EAAE;IACjF,OAAO,EAAE,IAAI,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;AAC7C,CAAC"}
@@ -1,14 +0,0 @@
1
- import { createBrightnessContrastEffect } from './brightnessContrastEffect';
2
-
3
- describe('createBrightnessContrastEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createBrightnessContrastEffect().kind).toBe('BrightnessContrastEffect');
6
- });
7
-
8
- it('carries options', () => {
9
- expect(createBrightnessContrastEffect({ brightness: 0.2, contrast: 1.5 })).toMatchObject({
10
- brightness: 0.2,
11
- contrast: 1.5,
12
- });
13
- });
14
- });
@@ -1,12 +0,0 @@
1
- import { createChannelMixerEffect } from './channelMixerEffect';
2
-
3
- describe('createChannelMixerEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createChannelMixerEffect({ matrix: [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0] }).kind).toBe('ChannelMixerEffect');
6
- });
7
-
8
- it('carries the matrix', () => {
9
- const matrix = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0];
10
- expect(createChannelMixerEffect({ matrix }).matrix).toBe(matrix);
11
- });
12
- });
@@ -1,13 +0,0 @@
1
- import { createColorBlindSimulationEffect } from './colorBlindSimulationEffect';
2
-
3
- describe('createColorBlindSimulationEffect', () => {
4
- it('carries options', () => {
5
- expect(createColorBlindSimulationEffect({ type: 'protanopia' })).toMatchObject({
6
- type: 'protanopia',
7
- });
8
- });
9
-
10
- it('tags the intent type', () => {
11
- expect(createColorBlindSimulationEffect().kind).toBe('ColorBlindSimulationEffect');
12
- });
13
- });
@@ -1,11 +0,0 @@
1
- import { createColorGradeEffect } from './colorGradeEffect';
2
-
3
- describe('createColorGradeEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createColorGradeEffect().kind).toBe('ColorGradeEffect');
6
- });
7
-
8
- it('carries options', () => {
9
- expect(createColorGradeEffect({ exposure: 1, saturation: 1.2 })).toMatchObject({ exposure: 1, saturation: 1.2 });
10
- });
11
- });
@@ -1,7 +0,0 @@
1
- import { createExposureEffect } from './exposureEffect';
2
-
3
- describe('createExposureEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createExposureEffect({ exposure: 1 }).kind).toBe('ExposureEffect');
6
- });
7
- });
@@ -1,11 +0,0 @@
1
- import { createGrayscaleEffect } from './grayscaleEffect';
2
-
3
- describe('createGrayscaleEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createGrayscaleEffect().kind).toBe('GrayscaleEffect');
6
- });
7
-
8
- it('carries options', () => {
9
- expect(createGrayscaleEffect({ intensity: 0.5 })).toMatchObject({ intensity: 0.5 });
10
- });
11
- });
@@ -1,15 +0,0 @@
1
- import { createHueSaturationEffect } from './hueSaturationEffect';
2
-
3
- describe('createHueSaturationEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createHueSaturationEffect().kind).toBe('HueSaturationEffect');
6
- });
7
-
8
- it('carries options', () => {
9
- expect(createHueSaturationEffect({ hue: 90, saturation: 1.4, lightness: 0.1 })).toMatchObject({
10
- hue: 90,
11
- saturation: 1.4,
12
- lightness: 0.1,
13
- });
14
- });
15
- });
@@ -1,11 +0,0 @@
1
- import { createInvertEffect } from './invertEffect';
2
-
3
- describe('createInvertEffect', () => {
4
- it('tags the intent type', () => {
5
- expect(createInvertEffect().kind).toBe('InvertEffect');
6
- });
7
-
8
- it('carries options', () => {
9
- expect(createInvertEffect({ intensity: 0.75 })).toMatchObject({ intensity: 0.75 });
10
- });
11
- });