@pixerate/editor 0.136.0 → 0.137.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 (132) hide show
  1. package/dist/animation-editor/index.cjs +60 -55
  2. package/dist/animation-editor/index.cjs.map +1 -1
  3. package/dist/animation-editor/index.d.cts +4 -4
  4. package/dist/animation-editor/index.d.ts +4 -4
  5. package/dist/animation-editor/index.js +7 -2
  6. package/dist/animation-editor/index.js.map +1 -1
  7. package/dist/{bezier-CdccFsF8.d.cts → bezier-CZ2AhjID.d.cts} +1 -1
  8. package/dist/{bezier-DG9qNZQV.d.ts → bezier-Dywv3Bw8.d.ts} +1 -1
  9. package/dist/blending-D7jCmjO6.d.cts +1026 -0
  10. package/dist/blending-NgF3qo3d.d.ts +1026 -0
  11. package/dist/brushes-CnvZSYYU.d.cts +744 -0
  12. package/dist/brushes-DJmUbIgz.d.ts +744 -0
  13. package/dist/{brushstrokeRender-SII6MG4R.js → brushstrokeRender-2FAXA3XC.js} +13 -16
  14. package/dist/{brushstrokeRender-SII6MG4R.js.map → brushstrokeRender-2FAXA3XC.js.map} +1 -1
  15. package/dist/{brushstrokeRender-JNHVEUFG.cjs → brushstrokeRender-IMFY3FF6.cjs} +16 -19
  16. package/dist/brushstrokeRender-IMFY3FF6.cjs.map +1 -0
  17. package/dist/canvas/index.cjs +10 -10
  18. package/dist/canvas/index.cjs.map +1 -1
  19. package/dist/canvas/index.d.cts +7 -7
  20. package/dist/canvas/index.d.ts +7 -7
  21. package/dist/canvas/index.js +4 -4
  22. package/dist/{chunk-W4LNKTHT.cjs → chunk-2XS6LTUP.cjs} +63 -63
  23. package/dist/{chunk-W4LNKTHT.cjs.map → chunk-2XS6LTUP.cjs.map} +1 -1
  24. package/dist/{chunk-MAHQC3SK.js → chunk-3D77LOBM.js} +222 -135
  25. package/dist/chunk-3D77LOBM.js.map +1 -0
  26. package/dist/{chunk-BR7EKQUP.js → chunk-3G6J7UFV.js} +322 -2
  27. package/dist/chunk-3G6J7UFV.js.map +1 -0
  28. package/dist/{chunk-62XUO5LB.js → chunk-3X6IAJUQ.js} +2 -2
  29. package/dist/{chunk-EM3FMJWE.js → chunk-5FSRTP6E.js} +320 -3
  30. package/dist/chunk-5FSRTP6E.js.map +1 -0
  31. package/dist/{chunk-2R3UW57U.cjs → chunk-5OOIUXNJ.cjs} +333 -246
  32. package/dist/chunk-5OOIUXNJ.cjs.map +1 -0
  33. package/dist/{chunk-KZXLZCQ7.js → chunk-6S6362D2.js} +2 -2
  34. package/dist/{chunk-24ATT2PE.cjs → chunk-AEAAN4AD.cjs} +120 -120
  35. package/dist/{chunk-24ATT2PE.cjs.map → chunk-AEAAN4AD.cjs.map} +1 -1
  36. package/dist/{chunk-SVYE5HIM.js → chunk-EQQMGO42.js} +2 -2
  37. package/dist/{chunk-FHPVDTI2.cjs → chunk-F2Y4E4GU.cjs} +22 -22
  38. package/dist/{chunk-FHPVDTI2.cjs.map → chunk-F2Y4E4GU.cjs.map} +1 -1
  39. package/dist/{chunk-UYQUPUR6.js → chunk-HUO3TI4C.js} +3 -3
  40. package/dist/{chunk-DDSO4HS7.cjs → chunk-KEENUAFN.cjs} +2 -2
  41. package/dist/{chunk-DDSO4HS7.cjs.map → chunk-KEENUAFN.cjs.map} +1 -1
  42. package/dist/{chunk-2HC4DRF4.js → chunk-LLFHCSU2.js} +2 -2
  43. package/dist/{chunk-J5BA3BQ6.cjs → chunk-O7LUD7MH.cjs} +323 -3
  44. package/dist/chunk-O7LUD7MH.cjs.map +1 -0
  45. package/dist/{chunk-ILYFOJUN.js → chunk-OIBIRXRG.js} +3 -3
  46. package/dist/{chunk-B2CUCM7Y.cjs → chunk-PRSRYHQD.cjs} +36 -36
  47. package/dist/{chunk-B2CUCM7Y.cjs.map → chunk-PRSRYHQD.cjs.map} +1 -1
  48. package/dist/{chunk-6GFRKLLS.cjs → chunk-QBWEH3IM.cjs} +429 -112
  49. package/dist/chunk-QBWEH3IM.cjs.map +1 -0
  50. package/dist/{chunk-6QQR4LKE.js → chunk-SYT2TLQF.js} +35 -37
  51. package/dist/{chunk-6QQR4LKE.js.map → chunk-SYT2TLQF.js.map} +1 -1
  52. package/dist/{chunk-YT3JL7YM.cjs → chunk-TLCTTQFF.cjs} +53 -53
  53. package/dist/{chunk-YT3JL7YM.cjs.map → chunk-TLCTTQFF.cjs.map} +1 -1
  54. package/dist/{chunk-JLGNZMUV.cjs → chunk-XN2NBLV5.cjs} +313 -315
  55. package/dist/chunk-XN2NBLV5.cjs.map +1 -0
  56. package/dist/effects/index.d.cts +4 -4
  57. package/dist/effects/index.d.ts +4 -4
  58. package/dist/{export-Ds7zgGD8.d.ts → export-41rL6Cne.d.ts} +1 -1
  59. package/dist/{export-BOheWw2R.d.cts → export-CyJdfP_Z.d.cts} +5 -4
  60. package/dist/{export-CEYeRQXH.d.cts → export-D9mXp05Q.d.cts} +1 -1
  61. package/dist/{export-ByKKIA2S.d.ts → export-DwnZ_hvQ.d.ts} +5 -4
  62. package/dist/{helpers--ns3W2D7.d.ts → helpers-C-RgeyvH.d.ts} +18 -7
  63. package/dist/{helpers-BVkU4oUi.d.cts → helpers-v6GMazzg.d.cts} +18 -7
  64. package/dist/image-editor/index.cjs +984 -987
  65. package/dist/image-editor/index.cjs.map +1 -1
  66. package/dist/image-editor/index.d.cts +12 -11
  67. package/dist/image-editor/index.d.ts +12 -11
  68. package/dist/image-editor/index.js +92 -95
  69. package/dist/image-editor/index.js.map +1 -1
  70. package/dist/{opentype-yi-Kz4ND.d.cts → opentype-KR_jj6b_.d.cts} +1 -1
  71. package/dist/{opentype-DfoVYgmG.d.ts → opentype-a1KAW-qs.d.ts} +1 -1
  72. package/dist/paint/index.cjs +5 -8
  73. package/dist/paint/index.cjs.map +1 -1
  74. package/dist/paint/index.d.cts +4 -2
  75. package/dist/paint/index.d.ts +4 -2
  76. package/dist/paint/index.js +15 -18
  77. package/dist/paint-editor/index.cjs +403 -404
  78. package/dist/paint-editor/index.cjs.map +1 -1
  79. package/dist/paint-editor/index.d.cts +12 -748
  80. package/dist/paint-editor/index.d.ts +12 -748
  81. package/dist/paint-editor/index.js +77 -78
  82. package/dist/paint-editor/index.js.map +1 -1
  83. package/dist/{pathfinder-7JkMwYvC.d.cts → pathfinder-BHS4vQNm.d.cts} +1 -1
  84. package/dist/{pathfinder-GM3UWdBZ.d.ts → pathfinder-BVvTIBMo.d.ts} +1 -1
  85. package/dist/{pool-CkTxlLMC.d.ts → pool-CZQOrSXZ.d.ts} +1 -1
  86. package/dist/{pool-04qp8iW4.d.cts → pool-FjZZmZ80.d.cts} +1 -1
  87. package/dist/rand-8xbUb6ur.d.ts +1118 -0
  88. package/dist/rand-Cw9VLrVC.d.cts +1118 -0
  89. package/dist/raster/index.cjs +17 -19
  90. package/dist/raster/index.cjs.map +1 -1
  91. package/dist/raster/index.js +9 -11
  92. package/dist/raster/index.js.map +1 -1
  93. package/dist/{svg-rV6_HPmn.d.ts → svg-CSz3mzkw.d.ts} +2 -2
  94. package/dist/{svg-BDDKvWWY.d.cts → svg-DTb40ICU.d.cts} +2 -2
  95. package/dist/{tools-DPYerqeR.d.ts → tools-B0wXP5cF.d.ts} +1 -1
  96. package/dist/{tools-BAjSbTdY.d.cts → tools-Ca0kI1qo.d.cts} +1 -1
  97. package/dist/vector/index.cjs +1459 -1259
  98. package/dist/vector/index.cjs.map +1 -1
  99. package/dist/vector/index.d.cts +87 -11
  100. package/dist/vector/index.d.ts +87 -11
  101. package/dist/vector/index.js +213 -13
  102. package/dist/vector/index.js.map +1 -1
  103. package/dist/video-editor/index.d.cts +4 -4
  104. package/dist/video-editor/index.d.ts +4 -4
  105. package/dist/{warp-DQh9R7Ie.d.cts → warp-DTOp0lON.d.cts} +1 -1
  106. package/dist/{warp-XVL6SpSh.d.ts → warp-pd7hrH4T.d.ts} +1 -1
  107. package/package.json +1 -1
  108. package/skills/pixerate-vector/SKILL.md +8 -0
  109. package/dist/brushstrokeRender-JNHVEUFG.cjs.map +0 -1
  110. package/dist/chunk-2R3UW57U.cjs.map +0 -1
  111. package/dist/chunk-64PYNEHJ.js +0 -340
  112. package/dist/chunk-64PYNEHJ.js.map +0 -1
  113. package/dist/chunk-6GFRKLLS.cjs.map +0 -1
  114. package/dist/chunk-7QN76ESJ.js +0 -323
  115. package/dist/chunk-7QN76ESJ.js.map +0 -1
  116. package/dist/chunk-BR7EKQUP.js.map +0 -1
  117. package/dist/chunk-DCLJNVZS.cjs +0 -323
  118. package/dist/chunk-DCLJNVZS.cjs.map +0 -1
  119. package/dist/chunk-EM3FMJWE.js.map +0 -1
  120. package/dist/chunk-J5BA3BQ6.cjs.map +0 -1
  121. package/dist/chunk-JLGNZMUV.cjs.map +0 -1
  122. package/dist/chunk-MAHQC3SK.js.map +0 -1
  123. package/dist/chunk-Z6OUCS2K.cjs +0 -340
  124. package/dist/chunk-Z6OUCS2K.cjs.map +0 -1
  125. package/dist/rand-BszBST4s.d.ts +0 -2140
  126. package/dist/rand-DOH_aMvm.d.cts +0 -2140
  127. /package/dist/{chunk-62XUO5LB.js.map → chunk-3X6IAJUQ.js.map} +0 -0
  128. /package/dist/{chunk-KZXLZCQ7.js.map → chunk-6S6362D2.js.map} +0 -0
  129. /package/dist/{chunk-SVYE5HIM.js.map → chunk-EQQMGO42.js.map} +0 -0
  130. /package/dist/{chunk-UYQUPUR6.js.map → chunk-HUO3TI4C.js.map} +0 -0
  131. /package/dist/{chunk-2HC4DRF4.js.map → chunk-LLFHCSU2.js.map} +0 -0
  132. /package/dist/{chunk-ILYFOJUN.js.map → chunk-OIBIRXRG.js.map} +0 -0
@@ -5,14 +5,14 @@
5
5
 
6
6
 
7
7
 
8
- var _chunk6GFRKLLScjs = require('./chunk-6GFRKLLS.cjs');
8
+ var _chunkQBWEH3IMcjs = require('./chunk-QBWEH3IM.cjs');
9
9
 
10
10
 
11
11
 
12
12
 
13
13
 
14
14
 
15
- var _chunkJ5BA3BQ6cjs = require('./chunk-J5BA3BQ6.cjs');
15
+ var _chunkO7LUD7MHcjs = require('./chunk-O7LUD7MH.cjs');
16
16
 
17
17
  // src/paint/heal.ts
18
18
  var TOL = 2e-3;
@@ -650,9 +650,9 @@ var TilePixelSource = (_class2 = class {
650
650
  sample(x, y, out) {
651
651
  const lx = x - this.offset.x;
652
652
  const ly = y - this.offset.y;
653
- const tx = Math.floor(lx / _chunkJ5BA3BQ6cjs.TILE);
654
- const ty = Math.floor(ly / _chunkJ5BA3BQ6cjs.TILE);
655
- const key = _chunkJ5BA3BQ6cjs.tileKey.call(void 0, tx, ty);
653
+ const tx = Math.floor(lx / _chunkO7LUD7MHcjs.TILE);
654
+ const ty = Math.floor(ly / _chunkO7LUD7MHcjs.TILE);
655
+ const key = _chunkO7LUD7MHcjs.tileKey.call(void 0, tx, ty);
656
656
  if (key !== this.lastKey) {
657
657
  let t2 = this.cache.get(key);
658
658
  if (t2 === void 0) {
@@ -667,7 +667,7 @@ var TilePixelSource = (_class2 = class {
667
667
  out[0] = out[1] = out[2] = out[3] = 0;
668
668
  return false;
669
669
  }
670
- const p = (ly - ty * _chunkJ5BA3BQ6cjs.TILE) * _chunkJ5BA3BQ6cjs.TILE + (lx - tx * _chunkJ5BA3BQ6cjs.TILE);
670
+ const p = (ly - ty * _chunkO7LUD7MHcjs.TILE) * _chunkO7LUD7MHcjs.TILE + (lx - tx * _chunkO7LUD7MHcjs.TILE);
671
671
  if (this.channels === 1) {
672
672
  out[0] = out[1] = out[2] = t[p];
673
673
  out[3] = 255;
@@ -721,21 +721,21 @@ function readSourceRegion(source, rect, dx = 0, dy = 0) {
721
721
  }
722
722
  function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, options = {}) {
723
723
  const out = (_nullishCoalesce(options.into, () => ( tileData))).slice();
724
- const ox = tx * _chunkJ5BA3BQ6cjs.TILE + s.offset.x;
725
- const oy = ty * _chunkJ5BA3BQ6cjs.TILE + s.offset.y;
724
+ const ox = tx * _chunkO7LUD7MHcjs.TILE + s.offset.x;
725
+ const oy = ty * _chunkO7LUD7MHcjs.TILE + s.offset.y;
726
726
  let x0 = 0;
727
727
  let y0 = 0;
728
- let x1 = _chunkJ5BA3BQ6cjs.TILE;
729
- let y1 = _chunkJ5BA3BQ6cjs.TILE;
728
+ let x1 = _chunkO7LUD7MHcjs.TILE;
729
+ let y1 = _chunkO7LUD7MHcjs.TILE;
730
730
  if (options.region) {
731
731
  const r = options.region;
732
732
  x0 = Math.max(0, Math.floor(r.x) - ox);
733
733
  y0 = Math.max(0, Math.floor(r.y) - oy);
734
- x1 = Math.min(_chunkJ5BA3BQ6cjs.TILE, Math.ceil(r.x + r.width) - ox);
735
- y1 = Math.min(_chunkJ5BA3BQ6cjs.TILE, Math.ceil(r.y + r.height) - oy);
734
+ x1 = Math.min(_chunkO7LUD7MHcjs.TILE, Math.ceil(r.x + r.width) - ox);
735
+ y1 = Math.min(_chunkO7LUD7MHcjs.TILE, Math.ceil(r.y + r.height) - oy);
736
736
  if (x1 <= x0 || y1 <= y0) return out;
737
737
  if (options.into) {
738
- for (let y = y0; y < y1; y++) out.set(tileData.subarray((y * _chunkJ5BA3BQ6cjs.TILE + x0) * channels, (y * _chunkJ5BA3BQ6cjs.TILE + x1) * channels), (y * _chunkJ5BA3BQ6cjs.TILE + x0) * channels);
738
+ for (let y = y0; y < y1; y++) out.set(tileData.subarray((y * _chunkO7LUD7MHcjs.TILE + x0) * channels, (y * _chunkO7LUD7MHcjs.TILE + x1) * channels), (y * _chunkO7LUD7MHcjs.TILE + x0) * channels);
739
739
  }
740
740
  }
741
741
  const sel = s.selection;
@@ -748,17 +748,17 @@ function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, opti
748
748
  let covTile;
749
749
  for (let y = y0; y < y1; y++) {
750
750
  const dy = oy + y;
751
- const cty = Math.floor(dy / _chunkJ5BA3BQ6cjs.TILE);
751
+ const cty = Math.floor(dy / _chunkO7LUD7MHcjs.TILE);
752
752
  for (let x = x0; x < x1; x++) {
753
753
  const dx = ox + x;
754
- const ctx = Math.floor(dx / _chunkJ5BA3BQ6cjs.TILE);
755
- const key = _chunkJ5BA3BQ6cjs.tileKey.call(void 0, ctx, cty);
754
+ const ctx = Math.floor(dx / _chunkO7LUD7MHcjs.TILE);
755
+ const key = _chunkO7LUD7MHcjs.tileKey.call(void 0, ctx, cty);
756
756
  if (key !== covKey) {
757
757
  covKey = key;
758
758
  covTile = coverage.tiles.get(key);
759
759
  }
760
760
  if (!covTile) continue;
761
- const c = covTile[(dy - cty * _chunkJ5BA3BQ6cjs.TILE) * _chunkJ5BA3BQ6cjs.TILE + (dx - ctx * _chunkJ5BA3BQ6cjs.TILE)];
761
+ const c = covTile[(dy - cty * _chunkO7LUD7MHcjs.TILE) * _chunkO7LUD7MHcjs.TILE + (dx - ctx * _chunkO7LUD7MHcjs.TILE)];
762
762
  if (c <= 0) continue;
763
763
  let k = c * s.opacity;
764
764
  if (sel) {
@@ -767,7 +767,7 @@ function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, opti
767
767
  }
768
768
  if (k > 1) k = 1;
769
769
  if (k <= 0) continue;
770
- const p = y * _chunkJ5BA3BQ6cjs.TILE + x;
770
+ const p = y * _chunkO7LUD7MHcjs.TILE + x;
771
771
  if (channels === 1) {
772
772
  const g = out[p];
773
773
  let t;
@@ -795,9 +795,9 @@ function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, opti
795
795
  const g0 = rgb[1];
796
796
  const b0 = rgb[2];
797
797
  paint.tone(rgb);
798
- _chunk6GFRKLLScjs.put255.call(void 0, out, i, r0 + (rgb[0] - r0) * k);
799
- _chunk6GFRKLLScjs.put255.call(void 0, out, i + 1, g0 + (rgb[1] - g0) * k);
800
- _chunk6GFRKLLScjs.put255.call(void 0, out, i + 2, b0 + (rgb[2] - b0) * k);
798
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i, r0 + (rgb[0] - r0) * k);
799
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i + 1, g0 + (rgb[1] - g0) * k);
800
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i + 2, b0 + (rgb[2] - b0) * k);
801
801
  continue;
802
802
  }
803
803
  if (s.lockTransparency && a === 0) continue;
@@ -811,11 +811,11 @@ function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, opti
811
811
  cb[ch] = out[i + ch] / 255;
812
812
  cs[ch] = src[ch] / 255;
813
813
  }
814
- const o = _chunkJ5BA3BQ6cjs.blendPixel.call(void 0, blend, cb, cs, k);
815
- _chunk6GFRKLLScjs.put255.call(void 0, out, i, o[0]);
816
- _chunk6GFRKLLScjs.put255.call(void 0, out, i + 1, o[1]);
817
- _chunk6GFRKLLScjs.put255.call(void 0, out, i + 2, o[2]);
818
- if (!s.lockTransparency) _chunk6GFRKLLScjs.put255.call(void 0, out, i + 3, o[3]);
814
+ const o = _chunkO7LUD7MHcjs.blendPixel.call(void 0, blend, cb, cs, k);
815
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i, o[0]);
816
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i + 1, o[1]);
817
+ _chunkQBWEH3IMcjs.put255.call(void 0, out, i + 2, o[2]);
818
+ if (!s.lockTransparency) _chunkQBWEH3IMcjs.put255.call(void 0, out, i + 3, o[3]);
819
819
  }
820
820
  }
821
821
  return out;
@@ -823,20 +823,20 @@ function applyRetouchToTile(coverage, tileData, channels, tx, ty, paint, s, opti
823
823
  function applyToneToDeepTile(coverage, samples, tx, ty, tone, s, options = {}) {
824
824
  const linear = samples instanceof Float32Array;
825
825
  const out = (_nullishCoalesce(options.into, () => ( samples))).slice();
826
- const ox = tx * _chunkJ5BA3BQ6cjs.TILE + s.offset.x;
827
- const oy = ty * _chunkJ5BA3BQ6cjs.TILE + s.offset.y;
826
+ const ox = tx * _chunkO7LUD7MHcjs.TILE + s.offset.x;
827
+ const oy = ty * _chunkO7LUD7MHcjs.TILE + s.offset.y;
828
828
  let x0 = 0;
829
829
  let y0 = 0;
830
- let x1 = _chunkJ5BA3BQ6cjs.TILE;
831
- let y1 = _chunkJ5BA3BQ6cjs.TILE;
830
+ let x1 = _chunkO7LUD7MHcjs.TILE;
831
+ let y1 = _chunkO7LUD7MHcjs.TILE;
832
832
  if (options.region) {
833
833
  const r = options.region;
834
834
  x0 = Math.max(0, Math.floor(r.x) - ox);
835
835
  y0 = Math.max(0, Math.floor(r.y) - oy);
836
- x1 = Math.min(_chunkJ5BA3BQ6cjs.TILE, Math.ceil(r.x + r.width) - ox);
837
- y1 = Math.min(_chunkJ5BA3BQ6cjs.TILE, Math.ceil(r.y + r.height) - oy);
836
+ x1 = Math.min(_chunkO7LUD7MHcjs.TILE, Math.ceil(r.x + r.width) - ox);
837
+ y1 = Math.min(_chunkO7LUD7MHcjs.TILE, Math.ceil(r.y + r.height) - oy);
838
838
  if (x1 <= x0 || y1 <= y0) return out;
839
- if (options.into) for (let y = y0; y < y1; y++) out.set(samples.subarray((y * _chunkJ5BA3BQ6cjs.TILE + x0) * 4, (y * _chunkJ5BA3BQ6cjs.TILE + x1) * 4), (y * _chunkJ5BA3BQ6cjs.TILE + x0) * 4);
839
+ if (options.into) for (let y = y0; y < y1; y++) out.set(samples.subarray((y * _chunkO7LUD7MHcjs.TILE + x0) * 4, (y * _chunkO7LUD7MHcjs.TILE + x1) * 4), (y * _chunkO7LUD7MHcjs.TILE + x0) * 4);
840
840
  }
841
841
  const sel = s.selection;
842
842
  const rgb = [0, 0, 0];
@@ -846,17 +846,17 @@ function applyToneToDeepTile(coverage, samples, tx, ty, tone, s, options = {}) {
846
846
  let covTile;
847
847
  for (let y = y0; y < y1; y++) {
848
848
  const dy = oy + y;
849
- const cty = Math.floor(dy / _chunkJ5BA3BQ6cjs.TILE);
849
+ const cty = Math.floor(dy / _chunkO7LUD7MHcjs.TILE);
850
850
  for (let x = x0; x < x1; x++) {
851
851
  const dx = ox + x;
852
- const ctx = Math.floor(dx / _chunkJ5BA3BQ6cjs.TILE);
853
- const key = _chunkJ5BA3BQ6cjs.tileKey.call(void 0, ctx, cty);
852
+ const ctx = Math.floor(dx / _chunkO7LUD7MHcjs.TILE);
853
+ const key = _chunkO7LUD7MHcjs.tileKey.call(void 0, ctx, cty);
854
854
  if (key !== covKey) {
855
855
  covKey = key;
856
856
  covTile = coverage.tiles.get(key);
857
857
  }
858
858
  if (!covTile) continue;
859
- const c = covTile[(dy - cty * _chunkJ5BA3BQ6cjs.TILE) * _chunkJ5BA3BQ6cjs.TILE + (dx - ctx * _chunkJ5BA3BQ6cjs.TILE)];
859
+ const c = covTile[(dy - cty * _chunkO7LUD7MHcjs.TILE) * _chunkO7LUD7MHcjs.TILE + (dx - ctx * _chunkO7LUD7MHcjs.TILE)];
860
860
  if (c <= 0) continue;
861
861
  let k = c * s.opacity;
862
862
  if (sel) {
@@ -865,20 +865,20 @@ function applyToneToDeepTile(coverage, samples, tx, ty, tone, s, options = {}) {
865
865
  }
866
866
  if (k > 1) k = 1;
867
867
  if (k <= 0) continue;
868
- const i = (y * _chunkJ5BA3BQ6cjs.TILE + x) * 4;
868
+ const i = (y * _chunkO7LUD7MHcjs.TILE + x) * 4;
869
869
  if (out[i + 3] === 0) continue;
870
870
  for (let ch = 0; ch < 3; ch++) {
871
871
  const v = out[i + ch];
872
872
  if (linear) {
873
873
  excess[ch] = v > 1 ? v - 1 : 0;
874
- rgb[ch] = _chunkJ5BA3BQ6cjs.srgbEncode.call(void 0, v > 1 ? 1 : v < 0 ? 0 : v);
874
+ rgb[ch] = _chunkO7LUD7MHcjs.srgbEncode.call(void 0, v > 1 ? 1 : v < 0 ? 0 : v);
875
875
  } else rgb[ch] = v / 65535;
876
876
  before[ch] = rgb[ch];
877
877
  }
878
878
  tone(rgb);
879
879
  for (let ch = 0; ch < 3; ch++) {
880
880
  const e = before[ch] + (rgb[ch] - before[ch]) * k;
881
- if (linear) out[i + ch] = _chunkJ5BA3BQ6cjs.srgbDecode.call(void 0, e) + excess[ch];
881
+ if (linear) out[i + ch] = _chunkO7LUD7MHcjs.srgbDecode.call(void 0, e) + excess[ch];
882
882
  else out[i + ch] = e <= 0 ? 0 : e >= 1 ? 65535 : Math.round(e * 65535);
883
883
  }
884
884
  }
@@ -963,8 +963,8 @@ var RetouchDabStroke = (_class3 = class {
963
963
  constructor(brush, target, effect) {;_class3.prototype.__init5.call(this);_class3.prototype.__init6.call(this);_class3.prototype.__init7.call(this);_class3.prototype.__init8.call(this);
964
964
  this.brush = brush;
965
965
  this.effect = effect;
966
- this.walker = new (0, _chunk6GFRKLLScjs.DabWalker)(brush);
967
- this.medium = new (0, _chunk6GFRKLLScjs.TileMedium)(target);
966
+ this.walker = new (0, _chunkQBWEH3IMcjs.DabWalker)(brush);
967
+ this.medium = new (0, _chunkQBWEH3IMcjs.TileMedium)(target);
968
968
  }
969
969
 
970
970
 
@@ -995,11 +995,11 @@ var RetouchDabStroke = (_class3 = class {
995
995
  paint(dabs) {
996
996
  const rects = [];
997
997
  for (const d of dabs) {
998
- const rect = _chunk6GFRKLLScjs.dabRect.call(void 0, d, this.brush.hardness);
998
+ const rect = _chunkQBWEH3IMcjs.dabRect.call(void 0, d, this.brush.hardness);
999
999
  const n = rect.width * rect.height;
1000
1000
  if (this.buf.length < n) this.buf = new Float32Array(n);
1001
1001
  const cov = this.buf.subarray(0, n);
1002
- _chunk6GFRKLLScjs.rasterizeDab.call(void 0, { ...d, alpha: 1 }, this.brush.hardness, rect, cov);
1002
+ _chunkQBWEH3IMcjs.rasterizeDab.call(void 0, { ...d, alpha: 1 }, this.brush.hardness, rect, cov);
1003
1003
  this.medium.reset();
1004
1004
  this.effect(this.medium, d, rect, cov);
1005
1005
  rects.push(rect);
@@ -1011,7 +1011,7 @@ var RetouchDabStroke = (_class3 = class {
1011
1011
  }, _class3);
1012
1012
  function smudgeEffect(brush, strength, mixing = "rgb") {
1013
1013
  const s = Math.min(1, Math.max(0, strength));
1014
- const tip = new (0, _chunk6GFRKLLScjs.SmudgeTip)({ strength: s, length: s, mixing }, brush.size);
1014
+ const tip = new (0, _chunkQBWEH3IMcjs.SmudgeTip)({ strength: s, length: s, mixing }, brush.size);
1015
1015
  return (medium, d, rect, cov) => tip.dab(medium, { x: d.x, y: d.y, radius: d.radius, opacity: d.opacity * d.alpha }, rect, cov);
1016
1016
  }
1017
1017
  function spongeEffect(brush, saturate, vibrance) {
@@ -1034,9 +1034,9 @@ function spongeEffect(brush, saturate, vibrance) {
1034
1034
  rgb[1] = px[i + 1] / 255;
1035
1035
  rgb[2] = px[i + 2] / 255;
1036
1036
  sponge(rgb, k, saturate, vibrance);
1037
- _chunk6GFRKLLScjs.put255.call(void 0, px, i, rgb[0]);
1038
- _chunk6GFRKLLScjs.put255.call(void 0, px, i + 1, rgb[1]);
1039
- _chunk6GFRKLLScjs.put255.call(void 0, px, i + 2, rgb[2]);
1037
+ _chunkQBWEH3IMcjs.put255.call(void 0, px, i, rgb[0]);
1038
+ _chunkQBWEH3IMcjs.put255.call(void 0, px, i + 1, rgb[1]);
1039
+ _chunkQBWEH3IMcjs.put255.call(void 0, px, i + 2, rgb[2]);
1040
1040
  }
1041
1041
  }
1042
1042
  };
@@ -1057,19 +1057,19 @@ function rgbaViewOfGrey(target) {
1057
1057
  lockTransparency: true,
1058
1058
  selection: target.selection,
1059
1059
  readTile: (tx, ty) => {
1060
- const key = _chunkJ5BA3BQ6cjs.tileKey.call(void 0, tx, ty);
1060
+ const key = _chunkO7LUD7MHcjs.tileKey.call(void 0, tx, ty);
1061
1061
  let v = views.get(key);
1062
1062
  if (!v) {
1063
- v = expand(_nullishCoalesce(target.readTile(tx, ty), () => ( new Uint8ClampedArray(_chunkJ5BA3BQ6cjs.TILE * _chunkJ5BA3BQ6cjs.TILE))));
1063
+ v = expand(_nullishCoalesce(target.readTile(tx, ty), () => ( new Uint8ClampedArray(_chunkO7LUD7MHcjs.TILE * _chunkO7LUD7MHcjs.TILE))));
1064
1064
  views.set(key, v);
1065
1065
  }
1066
1066
  return v;
1067
1067
  },
1068
1068
  writeTile: (tx, ty) => {
1069
- const key = _chunkJ5BA3BQ6cjs.tileKey.call(void 0, tx, ty);
1069
+ const key = _chunkO7LUD7MHcjs.tileKey.call(void 0, tx, ty);
1070
1070
  let v = views.get(key);
1071
1071
  if (!v) {
1072
- v = expand(_nullishCoalesce(target.readTile(tx, ty), () => ( new Uint8ClampedArray(_chunkJ5BA3BQ6cjs.TILE * _chunkJ5BA3BQ6cjs.TILE))));
1072
+ v = expand(_nullishCoalesce(target.readTile(tx, ty), () => ( new Uint8ClampedArray(_chunkO7LUD7MHcjs.TILE * _chunkO7LUD7MHcjs.TILE))));
1073
1073
  views.set(key, v);
1074
1074
  }
1075
1075
  dirty.set(key, { tx, ty, data: v });
@@ -1133,4 +1133,4 @@ function unionRect(a, b) {
1133
1133
 
1134
1134
 
1135
1135
  exports.solveMembrane = solveMembrane; exports.seamlessClone = seamlessClone; exports.membraneFill = membraneFill; exports.dilateMask = dilateMask; exports.maskBounds = maskBounds; exports.bestOffset = bestOffset; exports.contentAwareFill = contentAwareFill; exports.TONE_RANGES = TONE_RANGES; exports.luma = luma; exports.dodgeBurnCurve = dodgeBurnCurve; exports.dodgeBurn = dodgeBurn; exports.saturationOf = saturationOf; exports.sponge = sponge; exports.perDabStrength = perDabStrength; exports.RETOUCH_SAMPLES = RETOUCH_SAMPLES; exports.SPOT_HEAL_TYPES = SPOT_HEAL_TYPES; exports.DEFAULT_RETOUCH = DEFAULT_RETOUCH; exports.normalizeRetouch = normalizeRetouch; exports.boxBlurPixels = boxBlurPixels; exports.retouchFilter = retouchFilter; exports.IDENTITY_CLONE_TRANSFORM = IDENTITY_CLONE_TRANSFORM; exports.isIdentityCloneTransform = isIdentityCloneTransform; exports.cloneSamplePoint = cloneSamplePoint; exports.TransformedPixelSource = TransformedPixelSource; exports.TilePixelSource = TilePixelSource; exports.RegionPixelSource = RegionPixelSource; exports.readSourceRegion = readSourceRegion; exports.applyRetouchToTile = applyRetouchToTile; exports.applyToneToDeepTile = applyToneToDeepTile; exports.toneOf = toneOf; exports.healPixels = healPixels; exports.spotHealPixels = spotHealPixels; exports.spotHealWindow = spotHealWindow; exports.RetouchDabStroke = RetouchDabStroke; exports.smudgeEffect = smudgeEffect; exports.spongeEffect = spongeEffect; exports.rgbaViewOfGrey = rgbaViewOfGrey;
1136
- //# sourceMappingURL=chunk-YT3JL7YM.cjs.map
1136
+ //# sourceMappingURL=chunk-TLCTTQFF.cjs.map