@pixerate/editor 0.208.0 → 0.210.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.
- package/dist/{chunk-X4LUGTQX.cjs → chunk-L52VMQZS.cjs} +21 -10
- package/dist/{chunk-DWYQPL2A.js → chunk-LQ5SALHK.js} +13 -2
- package/dist/chunk-MQDIP4CF.cjs +462 -0
- package/dist/chunk-XI2NV5U7.js +462 -0
- package/dist/{chunk-3EHPLDFQ.cjs → chunk-YF3YZZ6G.cjs} +16 -453
- package/dist/{chunk-USQCKRZG.js → chunk-ZGJGSCUW.js} +8 -445
- package/dist/image-editor/content-aware-fill-session.d.cts +109 -0
- package/dist/image-editor/content-aware-fill-session.d.ts +109 -0
- package/dist/image-editor/controller.d.cts +85 -3
- package/dist/image-editor/controller.d.ts +85 -3
- package/dist/image-editor/index.cjs +847 -396
- package/dist/image-editor/index.d.cts +1 -0
- package/dist/image-editor/index.d.ts +1 -0
- package/dist/image-editor/index.js +492 -41
- package/dist/image-editor/selection/tool-options.d.cts +3 -1
- package/dist/image-editor/selection/tool-options.d.ts +3 -1
- package/dist/image-editor/selection/worker.d.cts +10 -0
- package/dist/image-editor/selection/worker.d.ts +10 -0
- package/dist/image-editor/selection-worker.cjs +4 -3
- package/dist/image-editor/selection-worker.js +2 -1
- package/dist/image-editor/types.d.cts +14 -0
- package/dist/image-editor/types.d.ts +14 -0
- package/dist/paint/heal.d.cts +3 -1
- package/dist/paint/heal.d.ts +3 -1
- package/dist/paint/index.cjs +4 -2
- package/dist/paint/index.js +10 -8
- package/package.json +1 -1
- package/skills/pixerate-image-editor/SKILL.md +21 -23
- package/skills/pixerate-image-editor/references/layer-effects.md +24 -0
- package/skills/pixerate-image-selection-masking/SKILL.md +2 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class; var _class2; var _class3; var _class4; var _class5; var _class6; var _class7; var _class8; var _class9; var _class10; var _class11; var _class12; var _class13; var _class14; var _class15; var _class16;
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class; var _class2; var _class3; var _class4; var _class5; var _class6; var _class7; var _class8; var _class9; var _class10; var _class11; var _class12; var _class13; var _class14; var _class15; var _class16; var _class17;
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
@@ -52,7 +52,7 @@ var _chunk3T5VCDIVcjs = require('../chunk-3T5VCDIV.cjs');
|
|
|
52
52
|
|
|
53
53
|
|
|
54
54
|
|
|
55
|
-
var
|
|
55
|
+
var _chunkL52VMQZScjs = require('../chunk-L52VMQZS.cjs');
|
|
56
56
|
|
|
57
57
|
|
|
58
58
|
|
|
@@ -542,6 +542,7 @@ var _chunkK6PXS6DOcjs = require('../chunk-K6PXS6DO.cjs');
|
|
|
542
542
|
|
|
543
543
|
|
|
544
544
|
|
|
545
|
+
var _chunkYF3YZZ6Gcjs = require('../chunk-YF3YZZ6G.cjs');
|
|
545
546
|
|
|
546
547
|
|
|
547
548
|
|
|
@@ -549,7 +550,8 @@ var _chunkK6PXS6DOcjs = require('../chunk-K6PXS6DO.cjs');
|
|
|
549
550
|
|
|
550
551
|
|
|
551
552
|
|
|
552
|
-
|
|
553
|
+
|
|
554
|
+
var _chunkMQDIP4CFcjs = require('../chunk-MQDIP4CF.cjs');
|
|
553
555
|
|
|
554
556
|
|
|
555
557
|
|
|
@@ -3649,7 +3651,7 @@ function segmentationOutlines(result) {
|
|
|
3649
3651
|
function segmentToSelection(width, height, result) {
|
|
3650
3652
|
let out = null;
|
|
3651
3653
|
for (const ring of segmentationOutlines(result)) {
|
|
3652
|
-
out = _chunkQYLWG22Ncjs.combineSelections.call(void 0, out,
|
|
3654
|
+
out = _chunkQYLWG22Ncjs.combineSelections.call(void 0, out, _chunkL52VMQZScjs.polygonSelection.call(void 0, width, height, ring), "add");
|
|
3653
3655
|
}
|
|
3654
3656
|
if (result.mask && result.mask.width > 0 && result.mask.height > 0) {
|
|
3655
3657
|
const raw = _chunkQYLWG22Ncjs.selectionFromPixels.call(void 0, result.mask, { channel: "luminance" });
|
|
@@ -4707,7 +4709,7 @@ var PaintStrokeSession = (_class11 = class {
|
|
|
4707
4709
|
this.stroke = null;
|
|
4708
4710
|
this.retouch = stroke;
|
|
4709
4711
|
if (this.base.channels === 1) {
|
|
4710
|
-
const view =
|
|
4712
|
+
const view = _chunkYF3YZZ6Gcjs.rgbaViewOfGrey.call(void 0, this.mixerPixels());
|
|
4711
4713
|
this.mixer = stroke.create(view.target);
|
|
4712
4714
|
this.flushView = view.flush;
|
|
4713
4715
|
} else this.mixer = stroke.create(this.mixerPixels());
|
|
@@ -4754,7 +4756,7 @@ var PaintStrokeSession = (_class11 = class {
|
|
|
4754
4756
|
retouchDeepTile(key, tx, ty, paint, options) {
|
|
4755
4757
|
const r = this.retouch;
|
|
4756
4758
|
const read = this.readWork(key);
|
|
4757
|
-
const out =
|
|
4759
|
+
const out = _chunkYF3YZZ6Gcjs.applyRetouchToTile.call(void 0, this.stroke.coverage, _nullishCoalesce(read, () => ( new Float32Array(_chunk474IQG74cjs.TILE * _chunk474IQG74cjs.TILE * 4))), 4, tx, ty, paint, r.apply, options);
|
|
4758
4760
|
this.work.set(key, out);
|
|
4759
4761
|
const d = deepOfWorkTile(out, this.deep, read, this.base.tiles.get(key));
|
|
4760
4762
|
this.liveDeep.set(key, d);
|
|
@@ -4764,7 +4766,7 @@ var PaintStrokeSession = (_class11 = class {
|
|
|
4764
4766
|
/** The new tile of a coverage stroke over the pre-stroke tile `src`. */
|
|
4765
4767
|
compositeTile(src, tx, ty, options = {}, paint) {
|
|
4766
4768
|
const r = this.retouch;
|
|
4767
|
-
if (r && r.kind === "coverage") return
|
|
4769
|
+
if (r && r.kind === "coverage") return _chunkYF3YZZ6Gcjs.applyRetouchToTile.call(void 0, this.stroke.coverage, src, this.base.channels, tx, ty, _nullishCoalesce(paint, () => ( r.paint())), r.apply, options);
|
|
4768
4770
|
return _chunkPQ3H2AANcjs.applyStrokeToTile.call(void 0, this.stroke.coverage, src, this.base.channels, tx, ty, this.apply, options);
|
|
4769
4771
|
}
|
|
4770
4772
|
/** The live pixels a mixer stroke reads and writes; base tiles are copied on first write. */
|
|
@@ -4862,7 +4864,7 @@ var PaintStrokeSession = (_class11 = class {
|
|
|
4862
4864
|
const prev2 = this.touched.has(key) ? this.liveDeep.get(key) : void 0;
|
|
4863
4865
|
this.touched.add(key);
|
|
4864
4866
|
const opts = prev2 ? { into: prev2, region: r, channels: ch } : { channels: ch };
|
|
4865
|
-
const d = _optionalChain([rt, 'optionalAccess', _125 => _125.kind]) === "coverage" && _optionalChain([paint, 'optionalAccess', _126 => _126.kind]) === "tone" ?
|
|
4867
|
+
const d = _optionalChain([rt, 'optionalAccess', _125 => _125.kind]) === "coverage" && _optionalChain([paint, 'optionalAccess', _126 => _126.kind]) === "tone" ? _chunkYF3YZZ6Gcjs.applyToneToDeepTile.call(void 0, stroke.coverage, src2, tx, ty, paint.tone, rt.apply, opts) : _chunkPQ3H2AANcjs.applyStrokeToDeepTile.call(void 0, stroke.coverage, src2, tx, ty, this.apply, opts);
|
|
4866
4868
|
this.liveDeep.set(key, d);
|
|
4867
4869
|
this.live.set(key, { data: _chunkOLNIPTB3cjs.proxyOf.call(void 0, d, ch), uniform: null, deep: d });
|
|
4868
4870
|
continue;
|
|
@@ -5103,17 +5105,19 @@ var ImageEditorController = (_class12 = class {
|
|
|
5103
5105
|
/** The segmentation provider behind `selectSubject` (see `setSegmentationProvider`). */
|
|
5104
5106
|
__init82() {this.segmentation = null}
|
|
5105
5107
|
__init83() {this.selectionWorker = null}
|
|
5108
|
+
__init84() {this.documentOpener = null}
|
|
5106
5109
|
/** The effects provider slot (see `setEffectsProvider`). */
|
|
5107
|
-
|
|
5110
|
+
__init85() {this.effects = new (0, _chunkA3A5TI6Rcjs.EffectsSlot)()}
|
|
5108
5111
|
/** Renders provider effects: effect smart filter results and effect layers. */
|
|
5109
|
-
|
|
5110
|
-
|
|
5111
|
-
constructor(options = {}) {;_class12.prototype.__init71.call(this);_class12.prototype.__init72.call(this);_class12.prototype.__init73.call(this);_class12.prototype.__init74.call(this);_class12.prototype.__init75.call(this);_class12.prototype.__init76.call(this);_class12.prototype.__init77.call(this);_class12.prototype.__init78.call(this);_class12.prototype.__init79.call(this);_class12.prototype.__init80.call(this);_class12.prototype.__init81.call(this);_class12.prototype.__init82.call(this);_class12.prototype.__init83.call(this);_class12.prototype.__init84.call(this);_class12.prototype.__init85.call(this);_class12.prototype.__init86.call(this);_class12.prototype.__init87.call(this);_class12.prototype.__init88.call(this);_class12.prototype.__init89.call(this);_class12.prototype.__init90.call(this);_class12.prototype.__init91.call(this);_class12.prototype.__init92.call(this);_class12.prototype.__init93.call(this);_class12.prototype.__init94.call(this);_class12.prototype.__init95.call(this);_class12.prototype.__init96.call(this);_class12.prototype.__init97.call(this);_class12.prototype.__init98.call(this);_class12.prototype.__init99.call(this);_class12.prototype.__init100.call(this);_class12.prototype.__init101.call(this);_class12.prototype.__init102.call(this);
|
|
5112
|
+
__init86() {this.effectsEngine = new ImageEffectsEngine({ slot: this.effects })}
|
|
5113
|
+
__init87() {this.effectRefresh = "none"}
|
|
5114
|
+
constructor(options = {}) {;_class12.prototype.__init71.call(this);_class12.prototype.__init72.call(this);_class12.prototype.__init73.call(this);_class12.prototype.__init74.call(this);_class12.prototype.__init75.call(this);_class12.prototype.__init76.call(this);_class12.prototype.__init77.call(this);_class12.prototype.__init78.call(this);_class12.prototype.__init79.call(this);_class12.prototype.__init80.call(this);_class12.prototype.__init81.call(this);_class12.prototype.__init82.call(this);_class12.prototype.__init83.call(this);_class12.prototype.__init84.call(this);_class12.prototype.__init85.call(this);_class12.prototype.__init86.call(this);_class12.prototype.__init87.call(this);_class12.prototype.__init88.call(this);_class12.prototype.__init89.call(this);_class12.prototype.__init90.call(this);_class12.prototype.__init91.call(this);_class12.prototype.__init92.call(this);_class12.prototype.__init93.call(this);_class12.prototype.__init94.call(this);_class12.prototype.__init95.call(this);_class12.prototype.__init96.call(this);_class12.prototype.__init97.call(this);_class12.prototype.__init98.call(this);_class12.prototype.__init99.call(this);_class12.prototype.__init100.call(this);_class12.prototype.__init101.call(this);_class12.prototype.__init102.call(this);_class12.prototype.__init103.call(this);
|
|
5112
5115
|
this.effects.subscribe(() => this.queueEffectRefresh("all"));
|
|
5113
5116
|
this.effectsEngine.subscribe(() => this.queueEffectRefresh("incomplete"));
|
|
5114
5117
|
if (options.effects) this.effects.set(options.effects);
|
|
5115
5118
|
if (options.segmentation) this.segmentation = options.segmentation;
|
|
5116
|
-
if (options.selectionWorker) this.selectionWorker = new (0,
|
|
5119
|
+
if (options.selectionWorker) this.selectionWorker = new (0, _chunkL52VMQZScjs.SelectionWorkerClient)(options.selectionWorker);
|
|
5120
|
+
if (options.openDocument) this.documentOpener = options.openDocument;
|
|
5117
5121
|
this.maxHistoryDepth = _nullishCoalesce(options.maxHistoryDepth, () => ( 50));
|
|
5118
5122
|
if (options.textShaper !== void 0) this.textShaperValue = options.textShaper;
|
|
5119
5123
|
this.maxHistoryBytes = _nullishCoalesce(options.maxHistoryBytes, () => ( 512 * 1024 * 1024));
|
|
@@ -5148,7 +5152,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5148
5152
|
activeLayerId: null,
|
|
5149
5153
|
activeTarget: "pixels",
|
|
5150
5154
|
outputOpacity: 1,
|
|
5151
|
-
paint: { brush: { ..._chunkPQ3H2AANcjs.DEFAULT_BRUSH }, foreground: "#000000", background: "#ffffff", paint: { type: "color", color: "#000000" }, mixer: { ..._chunkPQ3H2AANcjs.DEFAULT_MIXER }, mixerLoad: _chunkPQ3H2AANcjs.EMPTY_MIXER_LOAD, retouch: { ...
|
|
5155
|
+
paint: { brush: { ..._chunkPQ3H2AANcjs.DEFAULT_BRUSH }, foreground: "#000000", background: "#ffffff", paint: { type: "color", color: "#000000" }, mixer: { ..._chunkPQ3H2AANcjs.DEFAULT_MIXER }, mixerLoad: _chunkPQ3H2AANcjs.EMPTY_MIXER_LOAD, retouch: { ..._chunkYF3YZZ6Gcjs.DEFAULT_RETOUCH }, cloneSource: null, cloneTransform: { ..._chunkYF3YZZ6Gcjs.IDENTITY_CLONE_TRANSFORM } },
|
|
5152
5156
|
fit: _nullishCoalesce(options.fit, () => ( "margin"))
|
|
5153
5157
|
};
|
|
5154
5158
|
if (options.image instanceof Object && "width" in options.image) {
|
|
@@ -5242,7 +5246,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5242
5246
|
* Where layer pixels changed since the last viewport render, when only strokes changed them
|
|
5243
5247
|
* (the renderer then recomposites just those rectangles); `'all'` after any other change.
|
|
5244
5248
|
*/
|
|
5245
|
-
|
|
5249
|
+
__init88() {this.pendingDirty = "all"}
|
|
5246
5250
|
notify(strokeRects) {
|
|
5247
5251
|
if (strokeRects) this.docRevision++;
|
|
5248
5252
|
if (strokeRects && this.pendingDirty !== "all") this.pendingDirty.push(...strokeRects);
|
|
@@ -5309,7 +5313,71 @@ var ImageEditorController = (_class12 = class {
|
|
|
5309
5313
|
*/
|
|
5310
5314
|
setSelectionWorker(factory) {
|
|
5311
5315
|
_optionalChain([this, 'access', _163 => _163.selectionWorker, 'optionalAccess', _164 => _164.terminate, 'call', _165 => _165()]);
|
|
5312
|
-
this.selectionWorker = factory ? new (0,
|
|
5316
|
+
this.selectionWorker = factory ? new (0, _chunkL52VMQZScjs.SelectionWorkerClient)(factory) : null;
|
|
5317
|
+
}
|
|
5318
|
+
/** Sets (or with `null` removes) how new documents are opened (see `DocumentOpener`). Not an edit. */
|
|
5319
|
+
setDocumentOpener(opener) {
|
|
5320
|
+
if (this.documentOpener === opener) return;
|
|
5321
|
+
this.documentOpener = opener;
|
|
5322
|
+
this.notify();
|
|
5323
|
+
}
|
|
5324
|
+
/** Whether the host can open new documents (the New Document outputs are available). */
|
|
5325
|
+
get canOpenDocuments() {
|
|
5326
|
+
return this.documentOpener !== null;
|
|
5327
|
+
}
|
|
5328
|
+
/**
|
|
5329
|
+
* A new one-layer document from the selection (or `options.selection`) on a pixel layer
|
|
5330
|
+
* (`layerId`, default the active one), the size of this image: the selected pixels on
|
|
5331
|
+
* transparency, or with `withMask` the whole layer masked by the selection. This document is
|
|
5332
|
+
* not changed. `decontaminate` (0..100) cleans the soft edge's colours as the new-layer
|
|
5333
|
+
* outputs do.
|
|
5334
|
+
*/
|
|
5335
|
+
documentFromSelection(options = {}) {
|
|
5336
|
+
const id = _nullishCoalesce(options.layerId, () => ( this.state.activeLayerId));
|
|
5337
|
+
if (!id) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("No layer given and none is active; pass layerId (see list_layers).");
|
|
5338
|
+
const layer = _chunkQE7D7TZRcjs.requireLayer.call(void 0, this.state.layers, id).layer;
|
|
5339
|
+
if (layer.type !== "pixel") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`A new document needs a pixel layer; "${id}" is a ${layer.type} layer.`);
|
|
5340
|
+
const sel = _nullishCoalesce(options.selection, () => ( this.state.selection));
|
|
5341
|
+
if (!_optionalChain([sel, 'optionalAccess', _166 => _166.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select what goes in the new document first.");
|
|
5342
|
+
const { width, height } = this.naturalSize;
|
|
5343
|
+
const surface = this.surfaceOf(layer);
|
|
5344
|
+
let copy;
|
|
5345
|
+
if (options.withMask) {
|
|
5346
|
+
let mask = this.maskFromSelection(sel);
|
|
5347
|
+
if (layer.offset.x || layer.offset.y) mask = { ...mask, surface: _chunk474IQG74cjs.translateSurface.call(void 0, mask.surface, -layer.offset.x, -layer.offset.y) };
|
|
5348
|
+
copy = { ...layer, id: _chunkQE7D7TZRcjs.newLayerId.call(void 0, ), surface, mask };
|
|
5349
|
+
} else {
|
|
5350
|
+
const sb = sel.bounds;
|
|
5351
|
+
const src = { x: sb.x - layer.offset.x, y: sb.y - layer.offset.y, width: sb.width, height: sb.height };
|
|
5352
|
+
const px2 = _chunk474IQG74cjs.readRegion.call(void 0, surface, src);
|
|
5353
|
+
const data = sel.data;
|
|
5354
|
+
for (let y = 0; y < sb.height; y++) {
|
|
5355
|
+
for (let x = 0; x < sb.width; x++) px2[(y * sb.width + x) * 4 + 3] = Math.round(px2[(y * sb.width + x) * 4 + 3] * (data[(sb.y + y) * width + sb.x + x] / 255));
|
|
5356
|
+
}
|
|
5357
|
+
copy = { ...layer, id: _chunkQE7D7TZRcjs.newLayerId.call(void 0, ), surface: _chunk474IQG74cjs.surfaceFromPixels.call(void 0, { width: src.width, height: src.height, data: px2 }, 4, src.x, src.y) };
|
|
5358
|
+
delete copy.mask;
|
|
5359
|
+
}
|
|
5360
|
+
delete copy.source;
|
|
5361
|
+
copy.visible = true;
|
|
5362
|
+
const amount = Math.min(100, Math.max(0, _nullishCoalesce(options.decontaminate, () => ( 0)))) / 100;
|
|
5363
|
+
if (amount > 0) copy = { ...copy, surface: this.decontaminatedSurface(copy, layer, sel, amount, Math.max(4, _nullishCoalesce(options.radius, () => ( 0)))) };
|
|
5364
|
+
const { layers, assets, smartContents } = _chunkQE7D7TZRcjs.serializeLayers.call(void 0, [copy]);
|
|
5365
|
+
const out = {
|
|
5366
|
+
version: _chunkQE7D7TZRcjs.LAYERED_SCHEMA_VERSION,
|
|
5367
|
+
width,
|
|
5368
|
+
height,
|
|
5369
|
+
layers,
|
|
5370
|
+
assets,
|
|
5371
|
+
activeLayerId: copy.id,
|
|
5372
|
+
crop: null,
|
|
5373
|
+
transform: { ...DEFAULT_TRANSFORM },
|
|
5374
|
+
opacity: 1
|
|
5375
|
+
};
|
|
5376
|
+
if (smartContents) out.smartContents = smartContents;
|
|
5377
|
+
if (this.state.bitDepth === 16 || this.state.bitDepth === 32) out.bitDepth = this.state.bitDepth;
|
|
5378
|
+
if (this.state.colorProfile) out.colorProfile = serializeColorProfile(this.state.colorProfile);
|
|
5379
|
+
if (this.state.colorMode) out.colorMode = serializeColorMode(this.state.colorMode);
|
|
5380
|
+
return out;
|
|
5313
5381
|
}
|
|
5314
5382
|
/** Whether the long selections run in a worker. */
|
|
5315
5383
|
get hasSelectionWorker() {
|
|
@@ -5321,10 +5389,10 @@ var ImageEditorController = (_class12 = class {
|
|
|
5321
5389
|
* `onProgress` hears its stages. The document is not changed.
|
|
5322
5390
|
*/
|
|
5323
5391
|
async runSelectionJob(job, pixels, options = {}) {
|
|
5324
|
-
_optionalChain([options, 'access',
|
|
5392
|
+
_optionalChain([options, 'access', _167 => _167.signal, 'optionalAccess', _168 => _168.throwIfAborted, 'call', _169 => _169()]);
|
|
5325
5393
|
if (this.selectionWorker) return this.selectionWorker.run(job, pixels, options);
|
|
5326
|
-
const result =
|
|
5327
|
-
_optionalChain([options, 'access',
|
|
5394
|
+
const result = _chunkL52VMQZScjs.runSelectionJob.call(void 0, job, pixels, options.onProgress);
|
|
5395
|
+
_optionalChain([options, 'access', _170 => _170.signal, 'optionalAccess', _171 => _171.throwIfAborted, 'call', _172 => _172()]);
|
|
5328
5396
|
return result;
|
|
5329
5397
|
}
|
|
5330
5398
|
/** Registers (or with `null` removes) the segmentation provider. Not an edit: no undo step. */
|
|
@@ -5399,8 +5467,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
5399
5467
|
*/
|
|
5400
5468
|
async updateEffectFilter(layerId, filterId, changes, commitToHistory = true) {
|
|
5401
5469
|
const layer = _chunkQE7D7TZRcjs.requireSmartObject.call(void 0, this.state.layers, layerId);
|
|
5402
|
-
const was = _optionalChain([layer, 'access',
|
|
5403
|
-
if (!was || was.kind !== "effect") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Smart object "${layer.name || layerId}" has no effect filter "${filterId}"; its filters are ${(_nullishCoalesce(_optionalChain([layer, 'access',
|
|
5470
|
+
const was = _optionalChain([layer, 'access', _173 => _173.smartFilters, 'optionalAccess', _174 => _174.filters, 'access', _175 => _175.find, 'call', _176 => _176((f) => f.id === filterId)]);
|
|
5471
|
+
if (!was || was.kind !== "effect") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Smart object "${layer.name || layerId}" has no effect filter "${filterId}"; its filters are ${(_nullishCoalesce(_optionalChain([layer, 'access', _177 => _177.smartFilters, 'optionalAccess', _178 => _178.filters]), () => ( []))).map((f) => `${f.id} (${f.kind === "effect" ? _nullishCoalesce(f.name, () => ( f.effect)) : f.kind})`).join(", ") || "none"}.`);
|
|
5404
5472
|
const update = {};
|
|
5405
5473
|
if (changes.values) {
|
|
5406
5474
|
const d = await this.describeEffect(was.effect);
|
|
@@ -5442,7 +5510,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5442
5510
|
const layer = {
|
|
5443
5511
|
type: "pixel",
|
|
5444
5512
|
id,
|
|
5445
|
-
name: _optionalChain([options, 'access',
|
|
5513
|
+
name: _optionalChain([options, 'access', _179 => _179.name, 'optionalAccess', _180 => _180.trim, 'call', _181 => _181()]) || d.name,
|
|
5446
5514
|
visible: true,
|
|
5447
5515
|
opacity: _nullishCoalesce(options.opacity, () => ( 1)),
|
|
5448
5516
|
blend: _nullishCoalesce(blend, () => ( "normal")),
|
|
@@ -5467,7 +5535,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5467
5535
|
*/
|
|
5468
5536
|
async updateEffectLayer(layerId, changes, commitToHistory = true) {
|
|
5469
5537
|
const found = _chunkUOGKSVRQcjs.findLayer.call(void 0, this.state.layers, layerId);
|
|
5470
|
-
const layer = _optionalChain([found, 'optionalAccess',
|
|
5538
|
+
const layer = _optionalChain([found, 'optionalAccess', _182 => _182.layer]);
|
|
5471
5539
|
if (!layer || layer.type !== "pixel" || !layer.generator) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`"${layerId}" is not an effect layer; add one with add_effect_layer.`);
|
|
5472
5540
|
_chunkQE7D7TZRcjs.requireUnlocked.call(void 0, layer, "pixels", "draw its effect again");
|
|
5473
5541
|
const g = layer.generator;
|
|
@@ -5496,7 +5564,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5496
5564
|
* and how long it runs, the longest of theirs (ms). Null when none animates.
|
|
5497
5565
|
*/
|
|
5498
5566
|
getAnimation() {
|
|
5499
|
-
const layers = _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers).filter((l) => l.type === "pixel" && l.visible && !!_optionalChain([l, 'access',
|
|
5567
|
+
const layers = _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers).filter((l) => l.type === "pixel" && l.visible && !!_optionalChain([l, 'access', _183 => _183.generator, 'optionalAccess', _184 => _184.animate]));
|
|
5500
5568
|
if (!layers.length) return null;
|
|
5501
5569
|
return { duration: Math.max(...layers.map((l) => l.generator.animate.duration)), layerIds: layers.map((l) => l.id) };
|
|
5502
5570
|
}
|
|
@@ -5513,7 +5581,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5513
5581
|
const { width, height } = this.naturalSize;
|
|
5514
5582
|
const surfaces = /* @__PURE__ */ new Map();
|
|
5515
5583
|
for (const l of _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers)) {
|
|
5516
|
-
if (l.type !== "pixel" || !l.visible || !_optionalChain([l, 'access',
|
|
5584
|
+
if (l.type !== "pixel" || !l.visible || !_optionalChain([l, 'access', _185 => _185.generator, 'optionalAccess', _186 => _186.animate])) continue;
|
|
5517
5585
|
const g = l.generator;
|
|
5518
5586
|
const pixels = await this.effectsEngine.renderLayer(g.effect, g.values, { width, height, depth: this.bitDepth, time: (_nullishCoalesce(g.time, () => ( 0))) + time });
|
|
5519
5587
|
surfaces.set(l.id, effectPixelsToSurface(pixels, this.bitDepth));
|
|
@@ -5533,7 +5601,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5533
5601
|
})
|
|
5534
5602
|
);
|
|
5535
5603
|
}
|
|
5536
|
-
|
|
5604
|
+
__init89() {this.displayFor = null}
|
|
5537
5605
|
/** Keeps the renderer's display transform in step with the document profile, mode and Proof Setup. */
|
|
5538
5606
|
syncDisplay() {
|
|
5539
5607
|
const s = this.state;
|
|
@@ -5574,7 +5642,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5574
5642
|
transform: { ...s.transform },
|
|
5575
5643
|
outputOpacity: s.outputOpacity,
|
|
5576
5644
|
selection: _nullishCoalesce(s.selection, () => ( null)),
|
|
5577
|
-
..._optionalChain([s, 'access',
|
|
5645
|
+
..._optionalChain([s, 'access', _187 => _187.channels, 'optionalAccess', _188 => _188.length]) ? { channels: s.channels } : {},
|
|
5578
5646
|
source: {
|
|
5579
5647
|
sourceUrl: s.sourceUrl,
|
|
5580
5648
|
element: this.imageElement,
|
|
@@ -5610,7 +5678,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5610
5678
|
if (entry.colorMode) s.colorMode = entry.colorMode;
|
|
5611
5679
|
else delete s.colorMode;
|
|
5612
5680
|
s.selection = entry.selection;
|
|
5613
|
-
if (_optionalChain([entry, 'access',
|
|
5681
|
+
if (_optionalChain([entry, 'access', _189 => _189.channels, 'optionalAccess', _190 => _190.length])) s.channels = entry.channels;
|
|
5614
5682
|
else delete s.channels;
|
|
5615
5683
|
if (this.imageElement !== entry.source.element && !this.samplePixelsOverride) this.samplePixels = null;
|
|
5616
5684
|
this.imageElement = entry.source.element;
|
|
@@ -5622,7 +5690,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5622
5690
|
}
|
|
5623
5691
|
}
|
|
5624
5692
|
/** Set while `asOneStep` runs: the step is already recorded, so nested commands add none. */
|
|
5625
|
-
|
|
5693
|
+
__init90() {this.historyGrouped = false}
|
|
5626
5694
|
/**
|
|
5627
5695
|
* Runs `fn` as one undo step: history is recorded once, before it, and the commands it calls
|
|
5628
5696
|
* record none. If `fn` throws, the step is dropped and the state goes back to before it, so a
|
|
@@ -5685,7 +5753,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5685
5753
|
get canUndo() {
|
|
5686
5754
|
return this.undoStack.length > 0;
|
|
5687
5755
|
}
|
|
5688
|
-
|
|
5756
|
+
__init91() {this.docRevision = 0}
|
|
5689
5757
|
/**
|
|
5690
5758
|
* Bumped on every change to the document (an undoable edit, a stroke, undo, redo), not on view
|
|
5691
5759
|
* or tool changes, nor on `loadImage` (the source image is the host's, not part of the document). `createImageEditorDocument` uses it to tell document changes apart.
|
|
@@ -5817,7 +5885,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5817
5885
|
return this.state.layers;
|
|
5818
5886
|
}
|
|
5819
5887
|
getLayer(id) {
|
|
5820
|
-
return _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, this.state.layers, id), 'optionalAccess',
|
|
5888
|
+
return _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, this.state.layers, id), 'optionalAccess', _191 => _191.layer]);
|
|
5821
5889
|
}
|
|
5822
5890
|
/** The active layer, or `undefined`. */
|
|
5823
5891
|
getActiveLayer() {
|
|
@@ -5830,7 +5898,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5830
5898
|
setActiveLayer(id, target = "pixels") {
|
|
5831
5899
|
if (id !== null && !this.getLayer(id)) return false;
|
|
5832
5900
|
const layer = id ? this.getLayer(id) : void 0;
|
|
5833
|
-
const t = target === "mask" && _optionalChain([layer, 'optionalAccess',
|
|
5901
|
+
const t = target === "mask" && _optionalChain([layer, 'optionalAccess', _192 => _192.mask]) ? "mask" : target === "filter-mask" && _optionalChain([layer, 'optionalAccess', _193 => _193.type]) === "smart" && _optionalChain([layer, 'access', _194 => _194.smartFilters, 'optionalAccess', _195 => _195.mask]) ? "filter-mask" : "pixels";
|
|
5834
5902
|
if (this.state.activeLayerId === id && this.state.activeTarget === t) return true;
|
|
5835
5903
|
this.state.activeLayerId = id;
|
|
5836
5904
|
this.state.activeTarget = t;
|
|
@@ -5849,7 +5917,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
5849
5917
|
if (!b) return null;
|
|
5850
5918
|
return { x: b.x + layer.offset.x, y: b.y + layer.offset.y, width: b.width, height: b.height, data: _chunk474IQG74cjs.readRegion.call(void 0, surface, b) };
|
|
5851
5919
|
}
|
|
5852
|
-
|
|
5920
|
+
__init92() {this.boundsCache = /* @__PURE__ */ new WeakMap()}
|
|
5853
5921
|
/**
|
|
5854
5922
|
* Document bounds of a layer's non-transparent pixels (pixel layers; the Background's source
|
|
5855
5923
|
* included), or `null` for an empty or non-pixel layer.
|
|
@@ -5992,11 +6060,11 @@ var ImageEditorController = (_class12 = class {
|
|
|
5992
6060
|
surfaceOf: (l) => this.surfaceOf(l),
|
|
5993
6061
|
version: `${this.sourceVersion()}:${this.patternsVersion()}`,
|
|
5994
6062
|
globalLight: this.state.globalLight,
|
|
5995
|
-
pattern: (id) => _nullishCoalesce(_optionalChain([this, 'access',
|
|
6063
|
+
pattern: (id) => _nullishCoalesce(_optionalChain([this, 'access', _196 => _196.state, 'access', _197 => _197.patterns, 'optionalAccess', _198 => _198.find, 'call', _199 => _199((p) => p.id === id)]), () => ( null))
|
|
5996
6064
|
};
|
|
5997
6065
|
}
|
|
5998
|
-
|
|
5999
|
-
|
|
6066
|
+
__init93() {this.sourceIds = /* @__PURE__ */ new WeakMap()}
|
|
6067
|
+
__init94() {this.nextSourceId = 1}
|
|
6000
6068
|
/** Changes whenever the Background's source pixels can have changed. */
|
|
6001
6069
|
sourceVersion() {
|
|
6002
6070
|
const key = this.samplePixelsOverride ? this.samplePixels : _nullishCoalesce(this.imageElement, () => ( this.samplePixels));
|
|
@@ -6045,7 +6113,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6045
6113
|
}
|
|
6046
6114
|
return fits ? fromPixels(px2) : null;
|
|
6047
6115
|
}
|
|
6048
|
-
|
|
6116
|
+
__init95() {this.opaqueCache = /* @__PURE__ */ new WeakMap()}
|
|
6049
6117
|
/** Whether every source pixel is opaque (some legacy renders depend on it). */
|
|
6050
6118
|
sourceIsOpaque() {
|
|
6051
6119
|
const s = this.sourceSurface();
|
|
@@ -6069,7 +6137,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6069
6137
|
if (!ctx || typeof ctx.getImageData !== "function") return null;
|
|
6070
6138
|
ctx.drawImage(el, 0, 0, width, height);
|
|
6071
6139
|
const data = ctx.getImageData(0, 0, width, height);
|
|
6072
|
-
if (!_optionalChain([data, 'optionalAccess',
|
|
6140
|
+
if (!_optionalChain([data, 'optionalAccess', _200 => _200.data]) || data.data.length < width * height * 4) return null;
|
|
6073
6141
|
return { width, height, data: data.data };
|
|
6074
6142
|
} catch (e24) {
|
|
6075
6143
|
return null;
|
|
@@ -6082,7 +6150,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6082
6150
|
const prev = this.state.layers;
|
|
6083
6151
|
const depth = this.bitDepth;
|
|
6084
6152
|
this.state.layers = next;
|
|
6085
|
-
_optionalChain([extra, 'optionalCall',
|
|
6153
|
+
_optionalChain([extra, 'optionalCall', _201 => _201()]);
|
|
6086
6154
|
if (depth !== 8 && this.bitDepth === depth) this.state.layers = keepDeepLayers(prev, this.state.layers);
|
|
6087
6155
|
if (this.state.activeLayerId && !_chunkUOGKSVRQcjs.findLayer.call(void 0, this.state.layers, this.state.activeLayerId)) {
|
|
6088
6156
|
this.state.activeLayerId = _chunkQE7D7TZRcjs.activeLayerAfterRemoval.call(void 0, prev, this.state.layers, this.state.activeLayerId);
|
|
@@ -6120,7 +6188,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6120
6188
|
const layer = {
|
|
6121
6189
|
type: "pixel",
|
|
6122
6190
|
id: init.id && !ids.has(init.id) ? init.id : _chunkQE7D7TZRcjs.newLayerId.call(void 0, ),
|
|
6123
|
-
name: _optionalChain([init, 'access',
|
|
6191
|
+
name: _optionalChain([init, 'access', _202 => _202.name, 'optionalAccess', _203 => _203.trim, 'call', _204 => _204()]) || this.nextLayerName(),
|
|
6124
6192
|
visible: _nullishCoalesce(init.visible, () => ( true)),
|
|
6125
6193
|
opacity: _nullishCoalesce(init.opacity, () => ( 1)),
|
|
6126
6194
|
blend: _nullishCoalesce(blend, () => ( "normal")),
|
|
@@ -6147,7 +6215,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6147
6215
|
async decodeImage(image) {
|
|
6148
6216
|
const trimmed = image.trim();
|
|
6149
6217
|
let png = null;
|
|
6150
|
-
if (/^data:image\/png/i.test(trimmed)) png = _nullishCoalesce(_optionalChain([_chunkOLNIPTB3cjs.parseDataUrl.call(void 0, trimmed), 'optionalAccess',
|
|
6218
|
+
if (/^data:image\/png/i.test(trimmed)) png = _nullishCoalesce(_optionalChain([_chunkOLNIPTB3cjs.parseDataUrl.call(void 0, trimmed), 'optionalAccess', _205 => _205.bytes]), () => ( null));
|
|
6151
6219
|
else if (/^[A-Za-z0-9+/=\s]+$/.test(trimmed) && trimmed.length > 16) {
|
|
6152
6220
|
try {
|
|
6153
6221
|
const bytes = _chunkOLNIPTB3cjs.base64ToBytes.call(void 0, trimmed);
|
|
@@ -6196,7 +6264,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6196
6264
|
removeLayer(id) {
|
|
6197
6265
|
const next = _chunkQE7D7TZRcjs.removeLayer.call(void 0, this.state.layers, id);
|
|
6198
6266
|
this.commitLayers(next, () => {
|
|
6199
|
-
if (this.state.selectedAnnotationId && !_chunkUOGKSVRQcjs.flattenLayers.call(void 0, next).some((l) => _optionalChain([_chunkQE7D7TZRcjs.annotationOfLayer.call(void 0, l), 'optionalAccess',
|
|
6267
|
+
if (this.state.selectedAnnotationId && !_chunkUOGKSVRQcjs.flattenLayers.call(void 0, next).some((l) => _optionalChain([_chunkQE7D7TZRcjs.annotationOfLayer.call(void 0, l), 'optionalAccess', _206 => _206.id]) === this.state.selectedAnnotationId)) {
|
|
6200
6268
|
this.state.selectedAnnotationId = null;
|
|
6201
6269
|
}
|
|
6202
6270
|
});
|
|
@@ -6205,9 +6273,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
6205
6273
|
moveLayer(id, placement) {
|
|
6206
6274
|
const next = _chunkQE7D7TZRcjs.moveLayer.call(void 0, this.state.layers, id, placement);
|
|
6207
6275
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, next, id);
|
|
6208
|
-
if (next === this.state.layers) return { parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
6276
|
+
if (next === this.state.layers) return { parentId: _nullishCoalesce(_optionalChain([loc, 'access', _207 => _207.parent, 'optionalAccess', _208 => _208.id]), () => ( null)), index: loc.index };
|
|
6209
6277
|
this.commitLayers(next);
|
|
6210
|
-
return { parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
6278
|
+
return { parentId: _nullishCoalesce(_optionalChain([loc, 'access', _209 => _209.parent, 'optionalAccess', _210 => _210.id]), () => ( null)), index: loc.index };
|
|
6211
6279
|
}
|
|
6212
6280
|
/**
|
|
6213
6281
|
* Changes name, visibility, opacity, fill, blend, clipping, locks or (groups) collapsed state, as
|
|
@@ -6224,7 +6292,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6224
6292
|
const group = {
|
|
6225
6293
|
type: "group",
|
|
6226
6294
|
id: _chunkQE7D7TZRcjs.newLayerId.call(void 0, "group"),
|
|
6227
|
-
name: _optionalChain([init, 'access',
|
|
6295
|
+
name: _optionalChain([init, 'access', _211 => _211.name, 'optionalAccess', _212 => _212.trim, 'call', _213 => _213()]) || "Group",
|
|
6228
6296
|
visible: true,
|
|
6229
6297
|
opacity: 1,
|
|
6230
6298
|
blend,
|
|
@@ -6317,7 +6385,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6317
6385
|
sel = this.layerTransparency(id);
|
|
6318
6386
|
} else {
|
|
6319
6387
|
const current = this.state.selection;
|
|
6320
|
-
if (!_optionalChain([current, 'optionalAccess',
|
|
6388
|
+
if (!_optionalChain([current, 'optionalAccess', _214 => _214.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, or use reveal-all / hide-all / transparency.");
|
|
6321
6389
|
sel = from === "hide-selection" ? _chunkQYLWG22Ncjs.invertSelection.call(void 0, current) : current;
|
|
6322
6390
|
}
|
|
6323
6391
|
mask = this.maskFromSelection(sel, props);
|
|
@@ -6348,7 +6416,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6348
6416
|
const layer = _chunkQE7D7TZRcjs.requireLayer.call(void 0, this.state.layers, id).layer;
|
|
6349
6417
|
const name = layer.name || id;
|
|
6350
6418
|
if (layer.type === "shape") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${name}" is a shape layer, whose path already is its vector mask; change it with set_shape_component, or rasterize the layer first.`);
|
|
6351
|
-
if (_optionalChain([layer, 'access',
|
|
6419
|
+
if (_optionalChain([layer, 'access', _215 => _215.mask, 'optionalAccess', _216 => _216.source])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${name}" has a depth mask, which cannot be combined with a vector mask; remove the depth mask first.`);
|
|
6352
6420
|
return layer;
|
|
6353
6421
|
}
|
|
6354
6422
|
requireVectorMask(id) {
|
|
@@ -6358,10 +6426,10 @@ var ImageEditorController = (_class12 = class {
|
|
|
6358
6426
|
}
|
|
6359
6427
|
/** Components from a path spec: `components`, or one `shape` / `subpaths`. */
|
|
6360
6428
|
vectorMaskComponents(path) {
|
|
6361
|
-
if (_optionalChain([path, 'access',
|
|
6429
|
+
if (_optionalChain([path, 'access', _217 => _217.components, 'optionalAccess', _218 => _218.length]) && (path.shape !== void 0 || path.subpaths !== void 0)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Give components, or shape / subpaths, not both.");
|
|
6362
6430
|
if (path.fillRule !== void 0 && path.fillRule !== "nonzero" && path.fillRule !== "evenodd") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("fillRule must be nonzero or evenodd.");
|
|
6363
|
-
const specs = _optionalChain([path, 'access',
|
|
6364
|
-
return specs.map((c, i) => this.componentFrom(c, _optionalChain([path, 'access',
|
|
6431
|
+
const specs = _optionalChain([path, 'access', _219 => _219.components, 'optionalAccess', _220 => _220.length]) ? path.components : [path];
|
|
6432
|
+
return specs.map((c, i) => this.componentFrom(c, _optionalChain([path, 'access', _221 => _221.components, 'optionalAccess', _222 => _222.length]) ? `components[${i}].` : ""));
|
|
6365
6433
|
}
|
|
6366
6434
|
/**
|
|
6367
6435
|
* Layer › Vector Mask: `reveal-all` (an empty path showing everything), `hide-all` (an empty path
|
|
@@ -6378,7 +6446,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6378
6446
|
vm = { components: this.vectorMaskComponents(path) };
|
|
6379
6447
|
if (path.fillRule === "evenodd") vm.fillRule = "evenodd";
|
|
6380
6448
|
} else if (from === "reveal-all" || from === "hide-all") {
|
|
6381
|
-
if (_optionalChain([path, 'access',
|
|
6449
|
+
if (_optionalChain([path, 'access', _223 => _223.components, 'optionalAccess', _224 => _224.length]) || path.shape !== void 0 || path.subpaths !== void 0) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`A ${from} vector mask starts empty; use from path to give a path.`);
|
|
6382
6450
|
vm = { components: [], ...from === "reveal-all" ? { inverted: true } : {} };
|
|
6383
6451
|
} else {
|
|
6384
6452
|
throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Unknown vector mask source "${String(from)}". Use reveal-all, hide-all, path or selection.`);
|
|
@@ -6389,7 +6457,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6389
6457
|
/** The selection's outline as subpaths; throws when nothing is selected or nothing is left to trace. */
|
|
6390
6458
|
traceSelection(options) {
|
|
6391
6459
|
const sel = this.state.selection;
|
|
6392
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
6460
|
+
if (!_optionalChain([sel, 'optionalAccess', _225 => _225.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, then make a path from the selection.");
|
|
6393
6461
|
if (options.tolerance !== void 0 && !(options.tolerance >= 0.1 && options.tolerance <= 10)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("tolerance must be from 0.1 to 10 px.");
|
|
6394
6462
|
const subpaths = selectionToSubpaths(sel, options);
|
|
6395
6463
|
if (!subpaths.length) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("The selection is too small or too faint to trace (below minArea, or under half selected); lower minArea or threshold.");
|
|
@@ -6570,7 +6638,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6570
6638
|
const layer = loc.layer;
|
|
6571
6639
|
if (layer.type !== "pixel") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer via copy needs a pixel layer; "${id}" is a ${layer.type} layer.`);
|
|
6572
6640
|
const sel = this.state.selection;
|
|
6573
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
6641
|
+
if (!_optionalChain([sel, 'optionalAccess', _226 => _226.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select the pixels to copy first.");
|
|
6574
6642
|
if (options.cut) _chunkQE7D7TZRcjs.requireUnlocked.call(void 0, layer, "pixels", "cut from it");
|
|
6575
6643
|
const surface = this.surfaceOf(layer);
|
|
6576
6644
|
const sb = sel.bounds;
|
|
@@ -6588,14 +6656,14 @@ var ImageEditorController = (_class12 = class {
|
|
|
6588
6656
|
const copy = {
|
|
6589
6657
|
type: "pixel",
|
|
6590
6658
|
id: _chunkQE7D7TZRcjs.newLayerId.call(void 0, ),
|
|
6591
|
-
name: _optionalChain([options, 'access',
|
|
6659
|
+
name: _optionalChain([options, 'access', _227 => _227.name, 'optionalAccess', _228 => _228.trim, 'call', _229 => _229()]) || `${layer.name || "Layer"} ${options.cut ? "cut" : "copy"}`,
|
|
6592
6660
|
visible: true,
|
|
6593
6661
|
opacity: 1,
|
|
6594
6662
|
blend: "normal",
|
|
6595
6663
|
surface: _chunk474IQG74cjs.surfaceFromPixels.call(void 0, { width: src.width, height: src.height, data: px2 }, 4, src.x, src.y),
|
|
6596
6664
|
offset: { ...layer.offset }
|
|
6597
6665
|
};
|
|
6598
|
-
let next = _chunkUOGKSVRQcjs.insertLayer.call(void 0, this.state.layers, copy, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
6666
|
+
let next = _chunkUOGKSVRQcjs.insertLayer.call(void 0, this.state.layers, copy, _nullishCoalesce(_optionalChain([loc, 'access', _230 => _230.parent, 'optionalAccess', _231 => _231.id]), () => ( null)), loc.index + 1);
|
|
6599
6667
|
if (kept) {
|
|
6600
6668
|
const cutLayer = { ...layer, surface: _chunk474IQG74cjs.writeRegion.call(void 0, surface, src, kept) };
|
|
6601
6669
|
delete cutLayer.source;
|
|
@@ -6608,7 +6676,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6608
6676
|
return copy.id;
|
|
6609
6677
|
}
|
|
6610
6678
|
// --- Free Transform ---
|
|
6611
|
-
|
|
6679
|
+
__init96() {this.openTransform = null}
|
|
6612
6680
|
/** The Free Transform in progress (see `beginFreeTransform`), or `null`. */
|
|
6613
6681
|
getFreeTransform() {
|
|
6614
6682
|
if (this.openTransform && !this.openTransform.isOpen) this.openTransform = null;
|
|
@@ -6619,7 +6687,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6619
6687
|
layers: () => this.state.layers,
|
|
6620
6688
|
activeLayerId: () => this.state.activeLayerId,
|
|
6621
6689
|
activeTarget: () => this.state.activeTarget,
|
|
6622
|
-
selection: () => _optionalChain([this, 'access',
|
|
6690
|
+
selection: () => _optionalChain([this, 'access', _232 => _232.state, 'access', _233 => _233.selection, 'optionalAccess', _234 => _234.bounds]) ? this.state.selection : null,
|
|
6623
6691
|
canvas: () => this.naturalSize,
|
|
6624
6692
|
pixelsOf: (layer) => this.surfaceOf(layer),
|
|
6625
6693
|
shapeEnv: () => this.shapeEnv(),
|
|
@@ -6767,7 +6835,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6767
6835
|
* anything else nests as a layer document. Returns the smart object's id.
|
|
6768
6836
|
*/
|
|
6769
6837
|
convertToSmartObject(ids, options = {}) {
|
|
6770
|
-
const list = _optionalChain([ids, 'optionalAccess',
|
|
6838
|
+
const list = _optionalChain([ids, 'optionalAccess', _235 => _235.length]) ? ids : this.state.activeLayerId ? [this.state.activeLayerId] : [];
|
|
6771
6839
|
if (!list.length) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("No layers given and none is active; pass layerIds (see list_layers).");
|
|
6772
6840
|
const res = _chunkQE7D7TZRcjs.convertToSmartObject.call(void 0, this.state.layers, list, this.canvasSize, { surfaceOf: (l) => this.surfaceOf(l), name: options.name });
|
|
6773
6841
|
this.commitLayers(res.layers, () => {
|
|
@@ -6800,8 +6868,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
6800
6868
|
width: c.width,
|
|
6801
6869
|
height: c.height,
|
|
6802
6870
|
decoded: _chunkQE7D7TZRcjs.isContentsDecoded.call(void 0, c),
|
|
6803
|
-
fileType: _nullishCoalesce(_optionalChain([c, 'access',
|
|
6804
|
-
linkedPath: _nullishCoalesce(_optionalChain([c, 'access',
|
|
6871
|
+
fileType: _nullishCoalesce(_optionalChain([c, 'access', _236 => _236.file, 'optionalAccess', _237 => _237.type]), () => ( null)),
|
|
6872
|
+
linkedPath: _nullishCoalesce(_optionalChain([c, 'access', _238 => _238.linked, 'optionalAccess', _239 => _239.path]), () => ( null)),
|
|
6805
6873
|
instances: _chunkQE7D7TZRcjs.instancesOf.call(void 0, this.state.layers, c.id),
|
|
6806
6874
|
layerCount: c.document ? _chunkUOGKSVRQcjs.flattenLayers.call(void 0, c.document.layers).length : 0
|
|
6807
6875
|
},
|
|
@@ -6818,9 +6886,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
6818
6886
|
bounds: _chunkQE7D7TZRcjs.transformedBox.call(void 0, g)
|
|
6819
6887
|
},
|
|
6820
6888
|
smartFilters: {
|
|
6821
|
-
enabled: _nullishCoalesce(_optionalChain([stack, 'optionalAccess',
|
|
6822
|
-
filters: (_nullishCoalesce(_optionalChain([stack, 'optionalAccess',
|
|
6823
|
-
mask: _optionalChain([stack, 'optionalAccess',
|
|
6889
|
+
enabled: _nullishCoalesce(_optionalChain([stack, 'optionalAccess', _240 => _240.enabled]), () => ( true)),
|
|
6890
|
+
filters: (_nullishCoalesce(_optionalChain([stack, 'optionalAccess', _241 => _241.filters]), () => ( []))).map((f) => f.kind === "psd" ? { id: f.id, kind: "psd", name: f.name, enabled: f.enabled, blend: f.blend, opacity: f.opacity } : { ...f }),
|
|
6891
|
+
mask: _optionalChain([stack, 'optionalAccess', _242 => _242.mask]) ? { enabled: stack.mask.enabled !== false, linked: stack.mask.linked !== false, density: _nullishCoalesce(stack.mask.density, () => ( 1)), feather: _nullishCoalesce(stack.mask.feather, () => ( 0)), bounds: _chunk474IQG74cjs.contentBounds.call(void 0, stack.mask.surface), defaultValue: stack.mask.defaultValue } : null
|
|
6824
6892
|
},
|
|
6825
6893
|
bounds: this.getLayerBounds(id)
|
|
6826
6894
|
};
|
|
@@ -6959,7 +7027,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
6959
7027
|
* it in the same undo step (Photoshop limits a filter to the selection). Returns whether it did.
|
|
6960
7028
|
*/
|
|
6961
7029
|
maskFiltersWithSelection(id, useSelection) {
|
|
6962
|
-
if (!useSelection || !_optionalChain([this, 'access',
|
|
7030
|
+
if (!useSelection || !_optionalChain([this, 'access', _243 => _243.state, 'access', _244 => _244.selection, 'optionalAccess', _245 => _245.bounds])) return false;
|
|
6963
7031
|
this.setSmartFilterMask(id, "selection", {}, false);
|
|
6964
7032
|
return true;
|
|
6965
7033
|
}
|
|
@@ -6973,19 +7041,19 @@ var ImageEditorController = (_class12 = class {
|
|
|
6973
7041
|
removeSmartFilter(id, filterId) {
|
|
6974
7042
|
const res = _chunkQE7D7TZRcjs.removeSmartFilter.call(void 0, this.state.layers, id, filterId, this.canvasSize);
|
|
6975
7043
|
this.commitLayers(res.layers);
|
|
6976
|
-
return _nullishCoalesce(_optionalChain([res, 'access',
|
|
7044
|
+
return _nullishCoalesce(_optionalChain([res, 'access', _246 => _246.layer, 'access', _247 => _247.smartFilters, 'optionalAccess', _248 => _248.filters]), () => ( []));
|
|
6977
7045
|
}
|
|
6978
7046
|
/** Moves one smart filter to `index` (0 = bottom, applied first), as one undo step. Returns the filters. */
|
|
6979
7047
|
moveSmartFilter(id, filterId, index) {
|
|
6980
7048
|
const res = _chunkQE7D7TZRcjs.moveSmartFilter.call(void 0, this.state.layers, id, filterId, index, this.canvasSize);
|
|
6981
7049
|
this.commitLayers(res.layers);
|
|
6982
|
-
return _nullishCoalesce(_optionalChain([res, 'access',
|
|
7050
|
+
return _nullishCoalesce(_optionalChain([res, 'access', _249 => _249.layer, 'access', _250 => _250.smartFilters, 'optionalAccess', _251 => _251.filters]), () => ( []));
|
|
6983
7051
|
}
|
|
6984
7052
|
/** Turns a smart object's whole filter stack on or off (one undo step). */
|
|
6985
7053
|
setSmartFiltersEnabled(id, enabled) {
|
|
6986
7054
|
const res = _chunkQE7D7TZRcjs.setSmartFiltersEnabled.call(void 0, this.state.layers, id, enabled, this.canvasSize);
|
|
6987
7055
|
this.commitLayers(res.layers);
|
|
6988
|
-
return _nullishCoalesce(_optionalChain([res, 'access',
|
|
7056
|
+
return _nullishCoalesce(_optionalChain([res, 'access', _252 => _252.layer, 'access', _253 => _253.smartFilters, 'optionalAccess', _254 => _254.enabled]), () => ( true));
|
|
6989
7057
|
}
|
|
6990
7058
|
/**
|
|
6991
7059
|
* Sets the smart filter mask (one undo step): `reveal-all`, `hide-all`, `selection` (the
|
|
@@ -6997,11 +7065,11 @@ var ImageEditorController = (_class12 = class {
|
|
|
6997
7065
|
let mask;
|
|
6998
7066
|
if (from === "none") mask = null;
|
|
6999
7067
|
else if (from === "keep") {
|
|
7000
|
-
if (!_optionalChain([layer, 'access',
|
|
7068
|
+
if (!_optionalChain([layer, 'access', _255 => _255.smartFilters, 'optionalAccess', _256 => _256.mask])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Smart object "${layer.name || id}" has no filter mask; add one with from reveal-all, hide-all or selection.`);
|
|
7001
7069
|
mask = withMaskProps(layer.smartFilters.mask, props);
|
|
7002
7070
|
} else if (from === "selection") {
|
|
7003
7071
|
const sel = this.state.selection;
|
|
7004
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
7072
|
+
if (!_optionalChain([sel, 'optionalAccess', _257 => _257.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, or use reveal-all / hide-all.");
|
|
7005
7073
|
mask = this.maskFromSelection(sel, props);
|
|
7006
7074
|
} else {
|
|
7007
7075
|
const v = from === "reveal-all" ? 255 : 0;
|
|
@@ -7013,7 +7081,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7013
7081
|
if (mask && from !== "keep") this.state.activeTarget = "filter-mask";
|
|
7014
7082
|
else if (!mask && this.state.activeTarget === "filter-mask") this.state.activeTarget = "pixels";
|
|
7015
7083
|
}, commitToHistory);
|
|
7016
|
-
return _nullishCoalesce(_optionalChain([res, 'access',
|
|
7084
|
+
return _nullishCoalesce(_optionalChain([res, 'access', _258 => _258.layer, 'access', _259 => _259.smartFilters, 'optionalAccess', _260 => _260.mask]), () => ( null));
|
|
7017
7085
|
}
|
|
7018
7086
|
/**
|
|
7019
7087
|
* Decodes smart object contents that came as files the synchronous decoders cannot read (a JPEG
|
|
@@ -7046,7 +7114,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7046
7114
|
return left;
|
|
7047
7115
|
}
|
|
7048
7116
|
// --- Smart object contents (Edit Contents) ---
|
|
7049
|
-
|
|
7117
|
+
__init97() {this.contentsStack = []}
|
|
7050
7118
|
/** The smart objects whose contents are open (outermost first); empty when the document itself is shown. */
|
|
7051
7119
|
getEditingContents() {
|
|
7052
7120
|
return this.contentsStack.map((e) => ({ layerId: e.layerId, name: e.name }));
|
|
@@ -7061,7 +7129,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7061
7129
|
if (this.getFreeTransform()) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("A Free Transform is open; commit or cancel it first.");
|
|
7062
7130
|
const layer = _chunkQE7D7TZRcjs.requireSmartObject.call(void 0, this.state.layers, id);
|
|
7063
7131
|
const c = layer.contents;
|
|
7064
|
-
if (!_chunkQE7D7TZRcjs.isContentsDecoded.call(void 0, c)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`The contents of "${layer.name || id}" are a ${_nullishCoalesce(_optionalChain([c, 'access',
|
|
7132
|
+
if (!_chunkQE7D7TZRcjs.isContentsDecoded.call(void 0, c)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`The contents of "${layer.name || id}" are a ${_nullishCoalesce(_optionalChain([c, 'access', _261 => _261.file, 'optionalAccess', _262 => _262.type]), () => ( "file"))} that could not be decoded here; run prepareSmartObjects() in a browser first.`);
|
|
7065
7133
|
const saved = {
|
|
7066
7134
|
state: { ...this.state },
|
|
7067
7135
|
undo: this.undoStack,
|
|
@@ -7092,9 +7160,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
7092
7160
|
editingContents: this.getEditingContents()
|
|
7093
7161
|
};
|
|
7094
7162
|
delete this.state.legacyOutputBlur;
|
|
7095
|
-
if (_optionalChain([c, 'access',
|
|
7163
|
+
if (_optionalChain([c, 'access', _263 => _263.document, 'optionalAccess', _264 => _264.globalLight])) this.state.globalLight = c.document.globalLight;
|
|
7096
7164
|
else delete this.state.globalLight;
|
|
7097
|
-
if (_optionalChain([c, 'access',
|
|
7165
|
+
if (_optionalChain([c, 'access', _265 => _265.document, 'optionalAccess', _266 => _266.patterns, 'optionalAccess', _267 => _267.length])) this.state.patterns = c.document.patterns;
|
|
7098
7166
|
else delete this.state.patterns;
|
|
7099
7167
|
this.imageElement = null;
|
|
7100
7168
|
this.samplePixels = null;
|
|
@@ -7114,23 +7182,23 @@ var ImageEditorController = (_class12 = class {
|
|
|
7114
7182
|
closeSmartObjectContents(save = true) {
|
|
7115
7183
|
const top = this.contentsStack.pop();
|
|
7116
7184
|
if (!top) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("No smart object contents are open; open them with edit_smart_object_contents.");
|
|
7117
|
-
if (_optionalChain([this, 'access',
|
|
7185
|
+
if (_optionalChain([this, 'access', _268 => _268.openTransform, 'optionalAccess', _269 => _269.isOpen])) this.openTransform.cancel();
|
|
7118
7186
|
this.openTransform = null;
|
|
7119
7187
|
const edited = this.state;
|
|
7120
7188
|
const changed = save && this.undoStack.length > 0;
|
|
7121
7189
|
let next = null;
|
|
7122
7190
|
if (changed) {
|
|
7123
|
-
const layer = _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, top.saved.state.layers, top.layerId), 'optionalAccess',
|
|
7124
|
-
const old = _optionalChain([layer, 'optionalAccess',
|
|
7191
|
+
const layer = _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, top.saved.state.layers, top.layerId), 'optionalAccess', _270 => _270.layer]);
|
|
7192
|
+
const old = _optionalChain([layer, 'optionalAccess', _271 => _271.contents]);
|
|
7125
7193
|
const { width, height } = edited.imageDimensions;
|
|
7126
7194
|
const only = edited.layers.length === 1 ? edited.layers[0] : null;
|
|
7127
|
-
const plain3 = _optionalChain([only, 'optionalAccess',
|
|
7128
|
-
if (_optionalChain([old, 'optionalAccess',
|
|
7195
|
+
const plain3 = _optionalChain([only, 'optionalAccess', _272 => _272.type]) === "pixel" && only.visible && only.opacity === 1 && only.blend === "normal" && !only.mask && !only.effects && !_optionalChain([only, 'access', _273 => _273.filters, 'optionalAccess', _274 => _274.length]) && !only.clipped && (_nullishCoalesce(only.fillOpacity, () => ( 1))) === 1 && only.source !== "document";
|
|
7196
|
+
if (_optionalChain([old, 'optionalAccess', _275 => _275.kind]) === "raster" && plain3) {
|
|
7129
7197
|
const px2 = _chunk474IQG74cjs.readRegion.call(void 0, only.surface, { x: -only.offset.x, y: -only.offset.y, width, height });
|
|
7130
7198
|
next = _chunkQE7D7TZRcjs.rasterContents.call(void 0, { width, height, data: px2 }, old.name, old.id);
|
|
7131
7199
|
} else {
|
|
7132
7200
|
const doc = { layers: edited.layers, globalLight: edited.globalLight, patterns: edited.patterns };
|
|
7133
|
-
next = _chunkQE7D7TZRcjs.documentContents.call(void 0, doc, width, height, _optionalChain([old, 'optionalAccess',
|
|
7201
|
+
next = _chunkQE7D7TZRcjs.documentContents.call(void 0, doc, width, height, _optionalChain([old, 'optionalAccess', _276 => _276.kind]) === "document" ? old.name : `${(_nullishCoalesce(_optionalChain([old, 'optionalAccess', _277 => _277.name]), () => ( "Contents"))).replace(/\.\w+$/, "")}.psb`, top.contentsId);
|
|
7134
7202
|
}
|
|
7135
7203
|
}
|
|
7136
7204
|
const saved = top.saved;
|
|
@@ -7155,7 +7223,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7155
7223
|
}
|
|
7156
7224
|
/** The document's own layers (not the contents open for editing). */
|
|
7157
7225
|
rootLayers() {
|
|
7158
|
-
return _nullishCoalesce(_optionalChain([this, 'access',
|
|
7226
|
+
return _nullishCoalesce(_optionalChain([this, 'access', _278 => _278.contentsStack, 'access', _279 => _279[0], 'optionalAccess', _280 => _280.saved, 'access', _281 => _281.state, 'access', _282 => _282.layers]), () => ( this.state.layers));
|
|
7159
7227
|
}
|
|
7160
7228
|
/** Drops every open contents edit (loading another document). */
|
|
7161
7229
|
abandonContents() {
|
|
@@ -7195,7 +7263,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7195
7263
|
this.commitLayers(_chunkQE7D7TZRcjs.setLayerEffects.call(void 0, this.state.layers, id, effects), void 0, commitToHistory);
|
|
7196
7264
|
return this.getLayerEffects(id);
|
|
7197
7265
|
}
|
|
7198
|
-
|
|
7266
|
+
__init98() {this.patternIds = /* @__PURE__ */ new WeakMap()}
|
|
7199
7267
|
/** Changes whenever the document's pattern list is replaced (the compositor then drops its caches). */
|
|
7200
7268
|
patternsVersion() {
|
|
7201
7269
|
const list = this.state.patterns;
|
|
@@ -7357,7 +7425,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7357
7425
|
});
|
|
7358
7426
|
return bg.id;
|
|
7359
7427
|
}
|
|
7360
|
-
|
|
7428
|
+
__init99() {this.thumbCache = /* @__PURE__ */ new WeakMap()}
|
|
7361
7429
|
/**
|
|
7362
7430
|
* A small RGBA preview of a pixel layer over the canvas (or of its mask with `mask: true`),
|
|
7363
7431
|
* longest side `maxSide` px, point-sampled; `null` for layers without pixels.
|
|
@@ -7376,7 +7444,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7376
7444
|
const oy = layer.type === "pixel" ? layer.offset.y : 0;
|
|
7377
7445
|
const key = `${tw}x${th}:${ox},${oy}`;
|
|
7378
7446
|
let byKey = this.thumbCache.get(surface);
|
|
7379
|
-
const hit = _optionalChain([byKey, 'optionalAccess',
|
|
7447
|
+
const hit = _optionalChain([byKey, 'optionalAccess', _283 => _283.get, 'call', _284 => _284(key)]);
|
|
7380
7448
|
if (hit) return hit;
|
|
7381
7449
|
const out = new Uint8ClampedArray(tw * th * 4);
|
|
7382
7450
|
for (let y = 0; y < th; y++) {
|
|
@@ -7412,7 +7480,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7412
7480
|
/** Brush settings, colours and tool options of the paint tools (view state, no undo). */
|
|
7413
7481
|
setPaintOptions(options) {
|
|
7414
7482
|
const cur = this.state.paint;
|
|
7415
|
-
const retouch = options.retouch ?
|
|
7483
|
+
const retouch = options.retouch ? _chunkYF3YZZ6Gcjs.normalizeRetouch.call(void 0, options.retouch, cur.retouch) : cur.retouch;
|
|
7416
7484
|
const cloneSource = cur.cloneSource && retouch.aligned !== cur.retouch.aligned ? { ...cur.cloneSource, offset: null } : cur.cloneSource;
|
|
7417
7485
|
let source = cur.paint;
|
|
7418
7486
|
let foreground = options.foreground !== void 0 ? toHex(parseColor(options.foreground)) : cur.foreground;
|
|
@@ -7479,7 +7547,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7479
7547
|
*/
|
|
7480
7548
|
setCloneTransform(t) {
|
|
7481
7549
|
const cur = this.state.paint.cloneTransform;
|
|
7482
|
-
const next = t ? { ...cur, ...t } : { ...
|
|
7550
|
+
const next = t ? { ...cur, ...t } : { ..._chunkYF3YZZ6Gcjs.IDENTITY_CLONE_TRANSFORM };
|
|
7483
7551
|
for (const k of ["scaleX", "scaleY"]) {
|
|
7484
7552
|
const v = next[k];
|
|
7485
7553
|
if (!Number.isFinite(v) || Math.abs(v) < 0.01 || Math.abs(v) > 10) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`${k} must be a scale factor between 0.01 and 10 in size (negative flips), not ${String(v)}.`);
|
|
@@ -7517,7 +7585,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7517
7585
|
if (layer.mask.source) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${name}" has a depth mask, which is generated, not painted.`);
|
|
7518
7586
|
_chunkQE7D7TZRcjs.requireUnlocked.call(void 0, layer, "all", action);
|
|
7519
7587
|
} else if (ch === "filter-mask") {
|
|
7520
|
-
if (layer.type !== "smart" || !_optionalChain([layer, 'access',
|
|
7588
|
+
if (layer.type !== "smart" || !_optionalChain([layer, 'access', _285 => _285.smartFilters, 'optionalAccess', _286 => _286.mask])) {
|
|
7521
7589
|
throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${name}" has no smart filter mask to ${action}; add one with set_smart_filter_mask, or target pixels or mask.`, `Layer "${name}" has no smart filter mask to ${action}.`);
|
|
7522
7590
|
}
|
|
7523
7591
|
if (!_chunkQE7D7TZRcjs.isContentsDecoded.call(void 0, layer.contents)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`The contents of "${name}" are not decoded here, so its filter mask cannot be painted; run prepareSmartObjects() first.`, `The smart object "${name}" is still loading; try again in a moment.`);
|
|
@@ -7532,7 +7600,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7532
7600
|
if (!layer.visible) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${name}" is hidden; show it before you ${action}.`);
|
|
7533
7601
|
const offset = layer.type === "pixel" ? layer.offset : { x: 0, y: 0 };
|
|
7534
7602
|
const surface = ch === "mask" ? layer.mask.surface : ch === "filter-mask" ? layer.smartFilters.mask.surface : this.surfaceOf(layer);
|
|
7535
|
-
const lockTransparency = ch === "pixels" && Boolean(_optionalChain([layer, 'access',
|
|
7603
|
+
const lockTransparency = ch === "pixels" && Boolean(_optionalChain([layer, 'access', _287 => _287.locks, 'optionalAccess', _288 => _288.transparency]));
|
|
7536
7604
|
return { id, layer, channel: ch, offset, surface, lockTransparency };
|
|
7537
7605
|
}
|
|
7538
7606
|
/** The layer with its pixels (or mask) replaced by `surface`. */
|
|
@@ -7576,22 +7644,22 @@ var ImageEditorController = (_class12 = class {
|
|
|
7576
7644
|
blend: target.channel !== "pixels" ? "normal" : brush.blend,
|
|
7577
7645
|
lockTransparency: target.lockTransparency,
|
|
7578
7646
|
// In Quick Mask mode the selection is what is painted, so it does not limit the stroke.
|
|
7579
|
-
selection: target.channel !== "quick-mask" && _optionalChain([this, 'access',
|
|
7647
|
+
selection: target.channel !== "quick-mask" && _optionalChain([this, 'access', _289 => _289.state, 'access', _290 => _290.selection, 'optionalAccess', _291 => _291.bounds]) ? this.state.selection : null,
|
|
7580
7648
|
offset: target.offset
|
|
7581
7649
|
};
|
|
7582
7650
|
const depth = target.channel !== "filter-mask" && target.channel !== "quick-mask" && this.bitDepth !== 8 ? this.bitDepth : null;
|
|
7583
7651
|
if (tool === "mixer") return new PaintStrokeSession(this, target, this.mixerStroke(init, brush), apply, depth);
|
|
7584
7652
|
if (isRetouchTool(tool)) return new PaintStrokeSession(this, target, this.retouchStroke(tool, init, brush, target, apply), apply, depth);
|
|
7585
|
-
const gradient = tool === "brush" && _optionalChain([strokePaint, 'optionalAccess',
|
|
7653
|
+
const gradient = tool === "brush" && _optionalChain([strokePaint, 'optionalAccess', _292 => _292.type]) === "gradient" ? _chunkPQ3H2AANcjs.resolvePaintGradient.call(void 0, strokePaint, { paint: toHex(color), secondary: toHex(background) }) : null;
|
|
7586
7654
|
return new PaintStrokeSession(this, target, new (0, _chunkPQ3H2AANcjs.StrokeCoverage)(brush, gradient, _nullishCoalesce(init.seed, () => ( 0))), apply, depth);
|
|
7587
7655
|
}
|
|
7588
7656
|
/** A retouching stroke's start: its settings, what it samples and how it composites. */
|
|
7589
7657
|
retouchStroke(tool, init, brush, target, apply) {
|
|
7590
|
-
const settings =
|
|
7658
|
+
const settings = _chunkYF3YZZ6Gcjs.normalizeRetouch.call(void 0, _nullishCoalesce(init.retouch, () => ( {})), this.state.paint.retouch);
|
|
7591
7659
|
const mask = target.channel !== "pixels";
|
|
7592
7660
|
if (tool === "sponge" && mask) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("The Sponge changes saturation, and a mask has none; target pixels (channel pixels), or use dodge or burn on the mask.");
|
|
7593
|
-
if (tool === "smudge") return { kind: "dabs", create: (pixels) => new (0,
|
|
7594
|
-
if (tool === "sponge") return { kind: "dabs", create: (pixels) => new (0,
|
|
7661
|
+
if (tool === "smudge") return { kind: "dabs", create: (pixels) => new (0, _chunkYF3YZZ6Gcjs.RetouchDabStroke)(brush, pixels, _chunkYF3YZZ6Gcjs.smudgeEffect.call(void 0, brush, settings.strength)) };
|
|
7662
|
+
if (tool === "sponge") return { kind: "dabs", create: (pixels) => new (0, _chunkYF3YZZ6Gcjs.RetouchDabStroke)(brush, pixels, _chunkYF3YZZ6Gcjs.spongeEffect.call(void 0, brush, settings.spongeMode === "saturate", settings.vibrance)) };
|
|
7595
7663
|
const retouchApply = {
|
|
7596
7664
|
opacity: tool === "clone" || tool === "heal" || tool === "history" ? brush.opacity : tool === "blur" || tool === "sharpen" ? brush.opacity * settings.strength : 1,
|
|
7597
7665
|
blend: tool === "clone" && !mask ? brush.blend : "normal",
|
|
@@ -7601,7 +7669,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7601
7669
|
};
|
|
7602
7670
|
const coverage = new (0, _chunkPQ3H2AANcjs.StrokeCoverage)(brush);
|
|
7603
7671
|
if (tool === "dodge" || tool === "burn") {
|
|
7604
|
-
const paint2 = { kind: "tone", tone:
|
|
7672
|
+
const paint2 = { kind: "tone", tone: _chunkYF3YZZ6Gcjs.toneOf.call(void 0, tool, settings) };
|
|
7605
7673
|
return { kind: "coverage", coverage, apply: retouchApply, start: () => {
|
|
7606
7674
|
}, paint: () => paint2 };
|
|
7607
7675
|
}
|
|
@@ -7609,11 +7677,11 @@ var ImageEditorController = (_class12 = class {
|
|
|
7609
7677
|
const n = target.surface.channels;
|
|
7610
7678
|
const depth = !mask && this.bitDepth !== 8 ? this.bitDepth : null;
|
|
7611
7679
|
const m = 6;
|
|
7612
|
-
const filtered = new (0,
|
|
7680
|
+
const filtered = new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)(
|
|
7613
7681
|
(tx, ty) => {
|
|
7614
7682
|
const r = { x: tx * _chunk474IQG74cjs.TILE - m, y: ty * _chunk474IQG74cjs.TILE - m, width: _chunk474IQG74cjs.TILE + 2 * m, height: _chunk474IQG74cjs.TILE + 2 * m };
|
|
7615
7683
|
const d = workRegionOf(target.surface, r, depth);
|
|
7616
|
-
|
|
7684
|
+
_chunkYF3YZZ6Gcjs.retouchFilter.call(void 0, d, r.width, r.height, n, tool, 2, 1.2);
|
|
7617
7685
|
const out = new Float32Array(_chunk474IQG74cjs.TILE * _chunk474IQG74cjs.TILE * n);
|
|
7618
7686
|
for (let y = 0; y < _chunk474IQG74cjs.TILE; y++) out.set(d.subarray(((y + m) * r.width + m) * n, ((y + m) * r.width + m + _chunk474IQG74cjs.TILE) * n), y * _chunk474IQG74cjs.TILE * n);
|
|
7619
7687
|
return out;
|
|
@@ -7629,20 +7697,20 @@ var ImageEditorController = (_class12 = class {
|
|
|
7629
7697
|
const steps = settings.historySteps;
|
|
7630
7698
|
const entry = steps > 0 ? _nullishCoalesce(this.undoStack[this.undoStack.length - steps], () => ( this.undoStack[0])) : this.undoStack[0];
|
|
7631
7699
|
if (!entry) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("There is no earlier state to paint from yet: the History Brush paints a layer as it was some undo steps back. Make a change first.");
|
|
7632
|
-
const then = _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, entry.layers, target.id), 'optionalAccess',
|
|
7700
|
+
const then = _optionalChain([_chunkUOGKSVRQcjs.findLayer.call(void 0, entry.layers, target.id), 'optionalAccess', _293 => _293.layer]);
|
|
7633
7701
|
if (!then) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${target.id}" did not exist ${steps > 0 ? `${steps} steps back` : "in the oldest state"}; choose fewer history steps (historySteps).`);
|
|
7634
|
-
const surface = target.channel === "mask" ? _optionalChain([then, 'access',
|
|
7702
|
+
const surface = target.channel === "mask" ? _optionalChain([then, 'access', _294 => _294.mask, 'optionalAccess', _295 => _295.surface]) : then.type === "pixel" ? then.surface : void 0;
|
|
7635
7703
|
if (!surface) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${target.id}" had no ${target.channel === "mask" ? "mask" : "pixels"} in that state.`);
|
|
7636
7704
|
const offset2 = then.type === "pixel" ? then.offset : { x: 0, y: 0 };
|
|
7637
7705
|
const depth = !mask && this.bitDepth !== 8 ? this.bitDepth : null;
|
|
7638
|
-
const source2 = depth ? new (0,
|
|
7706
|
+
const source2 = depth ? new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)((tx, ty) => workTileOf(surface.tiles.get(_chunk474IQG74cjs.tileKey.call(void 0, tx, ty))), 4, offset2) : this.surfaceSource(surface, offset2);
|
|
7639
7707
|
const paint2 = { kind: "source", source: source2, dx: 0, dy: 0 };
|
|
7640
7708
|
return { kind: "coverage", coverage, apply: retouchApply, start: () => {
|
|
7641
7709
|
}, paint: () => paint2 };
|
|
7642
7710
|
}
|
|
7643
7711
|
const sample = mask ? "current" : settings.sample;
|
|
7644
7712
|
const deep = !mask && this.bitDepth !== 8 ? this.bitDepth : null;
|
|
7645
|
-
const own = deep ? new (0,
|
|
7713
|
+
const own = deep ? new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)((tx, ty) => workTileOf(target.surface.tiles.get(_chunk474IQG74cjs.tileKey.call(void 0, tx, ty))), 4, target.offset) : this.surfaceSource(target.surface, target.offset);
|
|
7646
7714
|
const source = sample === "current" ? own : this.compositeSource(sample === "all" ? null : target.id, deep);
|
|
7647
7715
|
const pad = (r, m) => ({ x: r.x - m, y: r.y - m, width: r.width + 2 * m, height: r.height + 2 * m });
|
|
7648
7716
|
const covered = (cov, r) => {
|
|
@@ -7663,14 +7731,14 @@ var ImageEditorController = (_class12 = class {
|
|
|
7663
7731
|
paint: () => trail,
|
|
7664
7732
|
finalPaint: (cov) => {
|
|
7665
7733
|
if (!cov.bounds) return null;
|
|
7666
|
-
const win =
|
|
7734
|
+
const win = _chunkYF3YZZ6Gcjs.spotHealWindow.call(void 0, cov.bounds, { width, height });
|
|
7667
7735
|
if (win.width <= 0 || win.height <= 0) return null;
|
|
7668
|
-
const img =
|
|
7736
|
+
const img = _chunkYF3YZZ6Gcjs.readSourceRegion.call(void 0, source, win);
|
|
7669
7737
|
const hole = covered(cov, win);
|
|
7670
|
-
const healed =
|
|
7738
|
+
const healed = _chunkYF3YZZ6Gcjs.spotHealPixels.call(void 0, win.width, win.height, img, hole, brush.size, settings.spotType, (off) => {
|
|
7671
7739
|
patch = off ? { x: off[0], y: off[1] } : null;
|
|
7672
7740
|
});
|
|
7673
|
-
return { kind: "source", source: new (0,
|
|
7741
|
+
return { kind: "source", source: new (0, _chunkYF3YZZ6Gcjs.RegionPixelSource)(win, healed), dx: 0, dy: 0 };
|
|
7674
7742
|
},
|
|
7675
7743
|
result: () => ({ spotHeal: { offset: patch } })
|
|
7676
7744
|
};
|
|
@@ -7681,7 +7749,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7681
7749
|
let offset = { x: 0, y: 0 };
|
|
7682
7750
|
let first = { x: 0, y: 0 };
|
|
7683
7751
|
const xf = this.state.paint.cloneTransform;
|
|
7684
|
-
const transformed =
|
|
7752
|
+
const transformed = _chunkYF3YZZ6Gcjs.isIdentityCloneTransform.call(void 0, xf) ? null : new (0, _chunkYF3YZZ6Gcjs.TransformedPixelSource)(source, (x, y) => _chunkYF3YZZ6Gcjs.cloneSamplePoint.call(void 0, xf, cs, { x: cs.x - offset.x, y: cs.y - offset.y }, x, y));
|
|
7685
7753
|
const paint = () => transformed ? { kind: "source", source: transformed, dx: 0, dy: 0 } : { kind: "source", source, dx: offset.x, dy: offset.y };
|
|
7686
7754
|
return {
|
|
7687
7755
|
kind: "coverage",
|
|
@@ -7696,16 +7764,16 @@ var ImageEditorController = (_class12 = class {
|
|
|
7696
7764
|
finalPaint: tool === "heal" ? (cov) => {
|
|
7697
7765
|
if (!cov.bounds) return null;
|
|
7698
7766
|
const g = pad(cov.bounds, 2);
|
|
7699
|
-
const src = transformed ?
|
|
7700
|
-
const dst =
|
|
7701
|
-
return { kind: "source", source: new (0,
|
|
7767
|
+
const src = transformed ? _chunkYF3YZZ6Gcjs.readSourceRegion.call(void 0, transformed, g) : _chunkYF3YZZ6Gcjs.readSourceRegion.call(void 0, source, g, offset.x, offset.y);
|
|
7768
|
+
const dst = _chunkYF3YZZ6Gcjs.readSourceRegion.call(void 0, source, g);
|
|
7769
|
+
return { kind: "source", source: new (0, _chunkYF3YZZ6Gcjs.RegionPixelSource)(g, _chunkYF3YZZ6Gcjs.healPixels.call(void 0, g.width, g.height, src, dst, covered(cov, g))), dx: 0, dy: 0 };
|
|
7702
7770
|
} : void 0,
|
|
7703
7771
|
result: () => ({ clone: { offset: { ...offset }, source: { x: first.x + offset.x, y: first.y + offset.y }, aligned: settings.aligned } })
|
|
7704
7772
|
};
|
|
7705
7773
|
}
|
|
7706
7774
|
/** A pixel source over a surface (layer pixels or a mask) in layer space at `offset`. */
|
|
7707
7775
|
surfaceSource(surface, offset) {
|
|
7708
|
-
return new (0,
|
|
7776
|
+
return new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)((tx, ty) => _nullishCoalesce(_optionalChain([surface, 'access', _296 => _296.tiles, 'access', _297 => _297.get, 'call', _298 => _298(_chunk474IQG74cjs.tileKey.call(void 0, tx, ty)), 'optionalAccess', _299 => _299.data]), () => ( (surface.defaultValue ? defaultTile(surface) : null))), surface.channels, offset);
|
|
7709
7777
|
}
|
|
7710
7778
|
/** A pixel source over the composite of the current layers (through `throughId` and below, or all of them), as it is now. */
|
|
7711
7779
|
compositeSource(throughId, depth = null) {
|
|
@@ -7713,7 +7781,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7713
7781
|
const layers = throughId ? layersThrough(stack, throughId) : stack;
|
|
7714
7782
|
const sources = this.compositorSources();
|
|
7715
7783
|
if (depth) {
|
|
7716
|
-
return new (0,
|
|
7784
|
+
return new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)((tx, ty) => {
|
|
7717
7785
|
const w = _chunkQE7D7TZRcjs.compositeDeep.call(void 0, layers, { x: tx * _chunk474IQG74cjs.TILE, y: ty * _chunk474IQG74cjs.TILE, width: _chunk474IQG74cjs.TILE, height: _chunk474IQG74cjs.TILE }, sources, depth);
|
|
7718
7786
|
for (let i = 0; i < w.length; i += 4) {
|
|
7719
7787
|
if (depth === 32) for (let c = 0; c < 3; c++) w[i + c] = _chunkOLNIPTB3cjs.srgbEncode.call(void 0, w[i + c]);
|
|
@@ -7723,7 +7791,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7723
7791
|
}, 4);
|
|
7724
7792
|
}
|
|
7725
7793
|
const compositor = new (0, _chunkQE7D7TZRcjs.LayerCompositor)();
|
|
7726
|
-
return new (0,
|
|
7794
|
+
return new (0, _chunkYF3YZZ6Gcjs.TilePixelSource)((tx, ty) => compositor.tile(layers, tx, ty, sources), 4);
|
|
7727
7795
|
}
|
|
7728
7796
|
/** A Mixer Brush stroke's start: the settings, and the load (refilled when asked or set to). */
|
|
7729
7797
|
mixerStroke(init, brush) {
|
|
@@ -7781,7 +7849,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7781
7849
|
paintStroke(init) {
|
|
7782
7850
|
if (!Array.isArray(init.points) || !init.points.length) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("points must hold at least one { x, y } point.");
|
|
7783
7851
|
for (const p of init.points) {
|
|
7784
|
-
if (!Number.isFinite(_optionalChain([p, 'optionalAccess',
|
|
7852
|
+
if (!Number.isFinite(_optionalChain([p, 'optionalAccess', _300 => _300.x])) || !Number.isFinite(_optionalChain([p, 'optionalAccess', _301 => _301.y]))) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Every point needs finite x and y (document pixels).");
|
|
7785
7853
|
}
|
|
7786
7854
|
const session = this.beginStroke(init);
|
|
7787
7855
|
session.push(init.points);
|
|
@@ -7810,7 +7878,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7810
7878
|
*/
|
|
7811
7879
|
strokeSelection(options) {
|
|
7812
7880
|
const sel = this.state.selection;
|
|
7813
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
7881
|
+
if (!_optionalChain([sel, 'optionalAccess', _302 => _302.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, then stroke the selection.");
|
|
7814
7882
|
const width = options.width;
|
|
7815
7883
|
if (!(width > 0 && width <= 250)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("width must be greater than 0 and at most 250 px.");
|
|
7816
7884
|
const location = _nullishCoalesce(options.location, () => ( "outside"));
|
|
@@ -7827,7 +7895,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7827
7895
|
*/
|
|
7828
7896
|
cropToSelection() {
|
|
7829
7897
|
const sel = this.state.selection;
|
|
7830
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
7898
|
+
if (!_optionalChain([sel, 'optionalAccess', _303 => _303.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select the area to keep, then crop to it.");
|
|
7831
7899
|
const crop = { ...sel.bounds };
|
|
7832
7900
|
this.setCrop(crop);
|
|
7833
7901
|
return crop;
|
|
@@ -7837,44 +7905,118 @@ var ImageEditorController = (_class12 = class {
|
|
|
7837
7905
|
* (PatchMatch, as the Spot Healing Brush's content-aware mode), blended by the selection's
|
|
7838
7906
|
* coverage. `output` `current` paints into the layer; `new-layer` puts the fill on a new layer
|
|
7839
7907
|
* above it. Samples within `sampleRadius` px of the selection (default its larger side, at
|
|
7840
|
-
* least 32). Deterministic for a `seed`. One undo step.
|
|
7908
|
+
* least 32), or from the given sampling area. Deterministic for a `seed`. One undo step.
|
|
7909
|
+
* 8-bit documents only for now. Runs here; see `contentAwareFillAsync` for the worker.
|
|
7841
7910
|
*/
|
|
7842
7911
|
contentAwareFill(options = {}) {
|
|
7912
|
+
const plan = this.prepareContentAwareFill(options);
|
|
7913
|
+
const filled = _chunkMQDIP4CFcjs.contentAwareFill.call(void 0, plan.window.width, plan.window.height, 4, plan.before, plan.hole, { seed: _nullishCoalesce(options.seed, () => ( 0)), exclude: plan.exclude });
|
|
7914
|
+
return this.applyContentAwareFill(plan, Uint8ClampedArray.from(filled), _nullishCoalesce(options.output, () => ( "current")));
|
|
7915
|
+
}
|
|
7916
|
+
/**
|
|
7917
|
+
* `contentAwareFill` with the synthesis in the selection worker when there is one, with
|
|
7918
|
+
* `signal` and `onProgress`. The layer is checked again before the result lands.
|
|
7919
|
+
*/
|
|
7920
|
+
async contentAwareFillAsync(options = {}) {
|
|
7921
|
+
const plan = this.prepareContentAwareFill(options);
|
|
7922
|
+
const filled = await this.synthesiseFill(plan, _nullishCoalesce(options.seed, () => ( 0)), options);
|
|
7923
|
+
return this.applyContentAwareFill(plan, filled, _nullishCoalesce(options.output, () => ( "current")));
|
|
7924
|
+
}
|
|
7925
|
+
/**
|
|
7926
|
+
* The fill without changing anything: the window, its pixels before and after (RGBA, the fill
|
|
7927
|
+
* blended by the selection's coverage) and the sampling area used, for a preview.
|
|
7928
|
+
*/
|
|
7929
|
+
async previewContentAwareFill(options = {}) {
|
|
7930
|
+
const plan = this.prepareContentAwareFill(options);
|
|
7931
|
+
const filled = await this.synthesiseFill(plan, _nullishCoalesce(options.seed, () => ( 0)), options);
|
|
7932
|
+
return { plan, after: this.blendFill(plan, filled, "current") };
|
|
7933
|
+
}
|
|
7934
|
+
async synthesiseFill(plan, seed, options) {
|
|
7935
|
+
const { width, height } = plan.window;
|
|
7936
|
+
const { pixels } = await this.runSelectionJob(
|
|
7937
|
+
{ op: "fill", hole: plan.hole, exclude: plan.exclude, seed },
|
|
7938
|
+
{ width, height, data: plan.before },
|
|
7939
|
+
options
|
|
7940
|
+
);
|
|
7941
|
+
return pixels;
|
|
7942
|
+
}
|
|
7943
|
+
/**
|
|
7944
|
+
* Checks and gathers what a Content-Aware Fill needs: the selection, the 8-bit pixel layer, the
|
|
7945
|
+
* window around the selection (and the sampling area), and which pixels it may copy from.
|
|
7946
|
+
*/
|
|
7947
|
+
prepareContentAwareFill(options = {}) {
|
|
7843
7948
|
const sel = this.state.selection;
|
|
7844
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
7949
|
+
if (!_optionalChain([sel, 'optionalAccess', _304 => _304.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select what to remove, then fill it.");
|
|
7845
7950
|
if (this.bitDepth !== 8) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Content-Aware Fill works on 8-bit documents for now; set_bit_depth 8 first, or use spot_heal.");
|
|
7846
7951
|
const output = _nullishCoalesce(options.output, () => ( "current"));
|
|
7847
7952
|
if (output !== "current" && output !== "new-layer") throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Unknown output "${String(output)}"; use current or new-layer.`);
|
|
7848
7953
|
const target = this.paintTarget(options.layerId, "pixels", "fill");
|
|
7849
7954
|
const { width, height } = this.naturalSize;
|
|
7850
7955
|
const b = sel.bounds;
|
|
7851
|
-
|
|
7852
|
-
|
|
7853
|
-
|
|
7854
|
-
|
|
7855
|
-
|
|
7856
|
-
|
|
7857
|
-
|
|
7858
|
-
|
|
7859
|
-
|
|
7860
|
-
|
|
7861
|
-
|
|
7956
|
+
let area = _nullishCoalesce(options.samplingArea, () => ( null));
|
|
7957
|
+
if (!area && options.samplingChannelId) area = this.requireChannel(options.samplingChannelId).mask;
|
|
7958
|
+
if (!area && _optionalChain([options, 'access', _305 => _305.sampleRects, 'optionalAccess', _306 => _306.length])) {
|
|
7959
|
+
for (const r of options.sampleRects) area = _chunkQYLWG22Ncjs.combineSelections.call(void 0, area, _chunkL52VMQZScjs.rectSelection.call(void 0, width, height, r, { antiAlias: false }), "add");
|
|
7960
|
+
}
|
|
7961
|
+
if (area && !area.bounds) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("The sampling area is empty; paint or give an area to sample from.");
|
|
7962
|
+
let win;
|
|
7963
|
+
if (_optionalChain([area, 'optionalAccess', _307 => _307.bounds])) {
|
|
7964
|
+
const a = area.bounds;
|
|
7965
|
+
const x0 = Math.max(0, Math.min(b.x - 8, a.x));
|
|
7966
|
+
const y0 = Math.max(0, Math.min(b.y - 8, a.y));
|
|
7967
|
+
win = { x: x0, y: y0, width: Math.min(width, Math.max(b.x + b.width + 8, a.x + a.width)) - x0, height: Math.min(height, Math.max(b.y + b.height + 8, a.y + a.height)) - y0 };
|
|
7968
|
+
} else {
|
|
7969
|
+
const margin = Math.max(32, Math.round(_nullishCoalesce(options.sampleRadius, () => ( Math.max(b.width, b.height)))));
|
|
7970
|
+
const x0 = Math.max(0, b.x - margin);
|
|
7971
|
+
const y0 = Math.max(0, b.y - margin);
|
|
7972
|
+
win = { x: x0, y: y0, width: Math.min(width, b.x + b.width + margin) - x0, height: Math.min(height, b.y + b.height + margin) - y0 };
|
|
7973
|
+
}
|
|
7974
|
+
if (win.width * win.height > 16e6) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("The area to fill and sample is too large (over 16 MP); fill a smaller selection or sample from a smaller area.");
|
|
7975
|
+
const before = _chunk474IQG74cjs.readRegion.call(void 0, target.surface, { x: win.x - target.offset.x, y: win.y - target.offset.y, width: win.width, height: win.height });
|
|
7976
|
+
const n = win.width * win.height;
|
|
7977
|
+
const coverage = new Uint8Array(n);
|
|
7978
|
+
const hole = new Uint8Array(n);
|
|
7979
|
+
const selData = sel.data;
|
|
7862
7980
|
for (let y = 0; y < win.height; y++) {
|
|
7863
7981
|
for (let x = 0; x < win.width; x++) {
|
|
7864
|
-
const c =
|
|
7982
|
+
const c = selData[(win.y + y) * sel.width + win.x + x];
|
|
7865
7983
|
coverage[y * win.width + x] = c;
|
|
7866
7984
|
hole[y * win.width + x] = c > 0 ? 1 : 0;
|
|
7867
7985
|
}
|
|
7868
7986
|
}
|
|
7869
|
-
|
|
7987
|
+
let exclude = null;
|
|
7988
|
+
if (area || _optionalChain([options, 'access', _308 => _308.excludeRects, 'optionalAccess', _309 => _309.length])) {
|
|
7989
|
+
exclude = new Uint8Array(n);
|
|
7990
|
+
if (area) {
|
|
7991
|
+
const ad = area.data;
|
|
7992
|
+
for (let y = 0; y < win.height; y++) for (let x = 0; x < win.width; x++) if (ad[(win.y + y) * width + win.x + x] < 128) exclude[y * win.width + x] = 1;
|
|
7993
|
+
}
|
|
7994
|
+
for (const r of _nullishCoalesce(options.excludeRects, () => ( []))) {
|
|
7995
|
+
for (let y = Math.max(0, Math.floor(r.y) - win.y); y < Math.min(win.height, Math.ceil(r.y + r.height) - win.y); y++) {
|
|
7996
|
+
for (let x = Math.max(0, Math.floor(r.x) - win.x); x < Math.min(win.width, Math.ceil(r.x + r.width) - win.x); x++) exclude[y * win.width + x] = 1;
|
|
7997
|
+
}
|
|
7998
|
+
}
|
|
7999
|
+
}
|
|
8000
|
+
return { layerId: target.id, window: win, bounds: { ...b }, before, hole, coverage, exclude };
|
|
8001
|
+
}
|
|
8002
|
+
/** The window's pixels with `filled` blended in by the coverage (`current`), or the fill alone, its alpha by the coverage (`new-layer`). */
|
|
8003
|
+
blendFill(plan, filled, output) {
|
|
8004
|
+
const { before, coverage } = plan;
|
|
7870
8005
|
const out = new Uint8ClampedArray(before.length);
|
|
7871
8006
|
for (let i = 0; i < coverage.length; i++) {
|
|
7872
|
-
const k = coverage[i];
|
|
8007
|
+
const k = coverage[i] / 255;
|
|
7873
8008
|
for (let c = 0; c < 4; c++) {
|
|
7874
8009
|
const p = i * 4 + c;
|
|
7875
8010
|
out[p] = output === "new-layer" ? c === 3 ? Math.round(filled[p] * k) : filled[p] : before[p] + (filled[p] - before[p]) * k;
|
|
7876
8011
|
}
|
|
7877
8012
|
}
|
|
8013
|
+
return out;
|
|
8014
|
+
}
|
|
8015
|
+
/** Puts a computed fill into the document as one undo step. */
|
|
8016
|
+
applyContentAwareFill(plan, filled, output) {
|
|
8017
|
+
const target = this.paintTarget(plan.layerId, "pixels", "fill");
|
|
8018
|
+
const { window: win, bounds: b } = plan;
|
|
8019
|
+
const out = this.blendFill(plan, filled, output);
|
|
7878
8020
|
if (output === "new-layer") {
|
|
7879
8021
|
const crop = { x: b.x - win.x, y: b.y - win.y, width: b.width, height: b.height };
|
|
7880
8022
|
const data = new Uint8ClampedArray(b.width * b.height * 4);
|
|
@@ -7882,12 +8024,13 @@ var ImageEditorController = (_class12 = class {
|
|
|
7882
8024
|
const id = this.addPixelLayer({ name: "Content-Aware Fill", pixels: { width: b.width, height: b.height, data }, x: b.x, y: b.y, aboveId: target.id });
|
|
7883
8025
|
return { layerId: id, bounds: { ...b }, output };
|
|
7884
8026
|
}
|
|
8027
|
+
const layerRect = { x: win.x - target.offset.x, y: win.y - target.offset.y, width: win.width, height: win.height };
|
|
7885
8028
|
const surface = _chunk474IQG74cjs.writeRegion.call(void 0, target.surface, layerRect, out);
|
|
7886
8029
|
this.commitLayers(_chunkUOGKSVRQcjs.mapLayer.call(void 0, this.state.layers, target.id, (l) => this.withSurface(l, "pixels", surface)));
|
|
7887
8030
|
return { layerId: target.id, bounds: { ...b }, output };
|
|
7888
8031
|
}
|
|
7889
8032
|
/** The pixel clipboard (Copy / Cut), or null. */
|
|
7890
|
-
|
|
8033
|
+
__init100() {this.clipboard = null}
|
|
7891
8034
|
/** What Copy or Cut last put on the editor's clipboard, or null. */
|
|
7892
8035
|
getClipboard() {
|
|
7893
8036
|
return this.clipboard;
|
|
@@ -7906,8 +8049,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
7906
8049
|
*/
|
|
7907
8050
|
copyPixels(options = {}) {
|
|
7908
8051
|
const { width, height } = this.naturalSize;
|
|
7909
|
-
const sel = _optionalChain([this, 'access',
|
|
7910
|
-
const rect = _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
8052
|
+
const sel = _optionalChain([this, 'access', _310 => _310.state, 'access', _311 => _311.selection, 'optionalAccess', _312 => _312.bounds]) ? this.state.selection : null;
|
|
8053
|
+
const rect = _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _313 => _313.bounds]), () => ( { x: 0, y: 0, width, height }));
|
|
7911
8054
|
let data;
|
|
7912
8055
|
if (options.merged) {
|
|
7913
8056
|
data = new Uint8ClampedArray(this.compositePixels(rect).data);
|
|
@@ -7947,7 +8090,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7947
8090
|
pastePixels(mode = "new-layer", image = this.clipboard) {
|
|
7948
8091
|
if (!image) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("The clipboard is empty; copy_pixels first.");
|
|
7949
8092
|
if (!PASTE_MODES.includes(mode)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Unknown paste mode "${String(mode)}"; use ${PASTE_MODES.join(", ")}.`);
|
|
7950
|
-
const sel = _optionalChain([this, 'access',
|
|
8093
|
+
const sel = _optionalChain([this, 'access', _314 => _314.state, 'access', _315 => _315.selection, 'optionalAccess', _316 => _316.bounds]) ? this.state.selection : null;
|
|
7951
8094
|
if ((mode === "into" || mode === "outside") && !sel) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Paste ${mode === "into" ? "Into" : "Outside"} needs a selection; select where it goes first.`);
|
|
7952
8095
|
const { width, height } = this.naturalSize;
|
|
7953
8096
|
let x;
|
|
@@ -7956,7 +8099,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
7956
8099
|
x = image.x;
|
|
7957
8100
|
y = image.y;
|
|
7958
8101
|
} else {
|
|
7959
|
-
const frame = _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
8102
|
+
const frame = _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _317 => _317.bounds]), () => ( { x: 0, y: 0, width, height }));
|
|
7960
8103
|
x = Math.round(frame.x + (frame.width - image.width) / 2);
|
|
7961
8104
|
y = Math.round(frame.y + (frame.height - image.height) / 2);
|
|
7962
8105
|
}
|
|
@@ -7973,8 +8116,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
7973
8116
|
if (!(opacity >= 0 && opacity <= 1)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("opacity must be from 0 to 1.");
|
|
7974
8117
|
const blend = _nullishCoalesce(_chunkQE7D7TZRcjs.parseBlend.call(void 0, options.blend), () => ( "normal"));
|
|
7975
8118
|
const quickMask = target.channel === "quick-mask";
|
|
7976
|
-
const sel = _nullishCoalesce(coverageMask, () => ( (!quickMask && options.useSelection !== false && _optionalChain([this, 'access',
|
|
7977
|
-
const region = _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
8119
|
+
const sel = _nullishCoalesce(coverageMask, () => ( (!quickMask && options.useSelection !== false && _optionalChain([this, 'access', _318 => _318.state, 'access', _319 => _319.selection, 'optionalAccess', _320 => _320.bounds]) ? this.state.selection : null)));
|
|
8120
|
+
const region = _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _321 => _321.bounds]), () => ( { x: 0, y: 0, width, height }));
|
|
7978
8121
|
const coverage = new (0, _chunkPQ3H2AANcjs.CoverageMap)();
|
|
7979
8122
|
const ones = new Float32Array(region.width * region.height);
|
|
7980
8123
|
if (sel) {
|
|
@@ -8099,7 +8242,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8099
8242
|
placeLayer(layers, node, where) {
|
|
8100
8243
|
if (where.aboveId) {
|
|
8101
8244
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, layers, where.aboveId);
|
|
8102
|
-
if (loc) return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
8245
|
+
if (loc) return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access', _322 => _322.parent, 'optionalAccess', _323 => _323.id]), () => ( null)), loc.index + 1);
|
|
8103
8246
|
}
|
|
8104
8247
|
if (where.parentId) {
|
|
8105
8248
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, layers, where.parentId);
|
|
@@ -8110,11 +8253,11 @@ var ImageEditorController = (_class12 = class {
|
|
|
8110
8253
|
const at = Math.max(0, Math.min(nodes.length, Math.round(where.adjustmentIndex)));
|
|
8111
8254
|
if (at < nodes.length) {
|
|
8112
8255
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, layers, nodes[at].id);
|
|
8113
|
-
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
8256
|
+
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access', _324 => _324.parent, 'optionalAccess', _325 => _325.id]), () => ( null)), loc.index);
|
|
8114
8257
|
}
|
|
8115
8258
|
if (nodes.length) {
|
|
8116
8259
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, layers, nodes[nodes.length - 1].id);
|
|
8117
|
-
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
8260
|
+
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, _nullishCoalesce(_optionalChain([loc, 'access', _326 => _326.parent, 'optionalAccess', _327 => _327.id]), () => ( null)), loc.index + 1);
|
|
8118
8261
|
}
|
|
8119
8262
|
}
|
|
8120
8263
|
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, layers, node, null, this.defaultInsertIndex(layers));
|
|
@@ -8153,7 +8296,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8153
8296
|
enabled: spec.enabled,
|
|
8154
8297
|
opacity: spec.opacity,
|
|
8155
8298
|
blend: spec.blend,
|
|
8156
|
-
mask: _nullishCoalesce(spec.mask, () => ( (spec.useSelection && _optionalChain([this, 'access',
|
|
8299
|
+
mask: _nullishCoalesce(spec.mask, () => ( (spec.useSelection && _optionalChain([this, 'access', _328 => _328.state, 'access', _329 => _329.selection, 'optionalAccess', _330 => _330.bounds]) ? _chunkQE7D7TZRcjs.layerMaskFromSelection.call(void 0, this.state.selection) : void 0)))
|
|
8157
8300
|
});
|
|
8158
8301
|
while (ids.has(layer.id)) layer.id = _chunkQE7D7TZRcjs.newLayerId.call(void 0, "adj");
|
|
8159
8302
|
const { width, height } = this.naturalSize;
|
|
@@ -8230,7 +8373,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8230
8373
|
const anchor = nodes[to];
|
|
8231
8374
|
const without = _chunkUOGKSVRQcjs.mapLayer.call(void 0, layers, id, () => null);
|
|
8232
8375
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, without, anchor.id);
|
|
8233
|
-
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, without, node, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
8376
|
+
return _chunkUOGKSVRQcjs.insertLayer.call(void 0, without, node, _nullishCoalesce(_optionalChain([loc, 'access', _331 => _331.parent, 'optionalAccess', _332 => _332.id]), () => ( null)), to > from ? loc.index + 1 : loc.index);
|
|
8234
8377
|
}
|
|
8235
8378
|
/** Moves a layer to `toIndex` among the adjustment layers (0 = bottom) as one undo step. Returns false if nothing moved. */
|
|
8236
8379
|
moveAdjustmentLayer(id, toIndex) {
|
|
@@ -8271,7 +8414,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8271
8414
|
return _nullishCoalesce(this.state.selection, () => ( null));
|
|
8272
8415
|
}
|
|
8273
8416
|
get hasSelection() {
|
|
8274
|
-
return Boolean(_optionalChain([this, 'access',
|
|
8417
|
+
return Boolean(_optionalChain([this, 'access', _333 => _333.state, 'access', _334 => _334.selection, 'optionalAccess', _335 => _335.bounds]));
|
|
8275
8418
|
}
|
|
8276
8419
|
/** Returns the current canvas (composition) dimensions. */
|
|
8277
8420
|
getCanvasSize() {
|
|
@@ -8363,7 +8506,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8363
8506
|
const prev = normalizeSelection(_nullishCoalesce(this.state.selection, () => ( null)));
|
|
8364
8507
|
if (prev === next || prev && next && sameSelection(prev, next)) return false;
|
|
8365
8508
|
this.recordHistory();
|
|
8366
|
-
if (!next && _optionalChain([prev, 'optionalAccess',
|
|
8509
|
+
if (!next && _optionalChain([prev, 'optionalAccess', _336 => _336.bounds])) this.lastSelection = prev;
|
|
8367
8510
|
this.state.selection = next;
|
|
8368
8511
|
this.notify();
|
|
8369
8512
|
return true;
|
|
@@ -8378,7 +8521,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8378
8521
|
return this.setSelection(null);
|
|
8379
8522
|
}
|
|
8380
8523
|
/** The selection a Deselect cleared, for `reselect` (not saved, not part of history). */
|
|
8381
|
-
|
|
8524
|
+
__init101() {this.lastSelection = null}
|
|
8382
8525
|
/** Whether `reselect` has a selection to bring back. */
|
|
8383
8526
|
canReselect() {
|
|
8384
8527
|
const { width, height } = this.naturalSize;
|
|
@@ -8401,19 +8544,19 @@ var ImageEditorController = (_class12 = class {
|
|
|
8401
8544
|
throw new RangeError(`${orientation === "row" ? "y" : "x"} ${position} is outside the image (0..${max - 1}).`);
|
|
8402
8545
|
}
|
|
8403
8546
|
const rect = orientation === "row" ? { x: 0, y: at, width, height: 1 } : { x: at, y: 0, width: 1, height };
|
|
8404
|
-
return this.shapeCommand(
|
|
8547
|
+
return this.shapeCommand(_chunkL52VMQZScjs.rectSelection.call(void 0, width, height, rect, { antiAlias: false }), options);
|
|
8405
8548
|
}
|
|
8406
8549
|
/** Select › Grow: adds connected pixels within `tolerance` of a selected colour (one undo step). */
|
|
8407
8550
|
async growSelection(options = {}) {
|
|
8408
8551
|
const sel = this.state.selection;
|
|
8409
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
8552
|
+
if (!_optionalChain([sel, 'optionalAccess', _337 => _337.bounds])) return false;
|
|
8410
8553
|
const pixels = await this.requirePixels(options);
|
|
8411
8554
|
return this.setSelection(growSelection(pixels, sel, options));
|
|
8412
8555
|
}
|
|
8413
8556
|
/** Select › Similar: adds every pixel within `tolerance` of a selected colour (one undo step). */
|
|
8414
8557
|
async selectSimilar(options = {}) {
|
|
8415
8558
|
const sel = this.state.selection;
|
|
8416
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
8559
|
+
if (!_optionalChain([sel, 'optionalAccess', _338 => _338.bounds])) return false;
|
|
8417
8560
|
const pixels = await this.requirePixels(options);
|
|
8418
8561
|
return this.setSelection(selectSimilar(pixels, sel, options));
|
|
8419
8562
|
}
|
|
@@ -8459,17 +8602,17 @@ var ImageEditorController = (_class12 = class {
|
|
|
8459
8602
|
/** Rectangular marquee in natural image pixels. */
|
|
8460
8603
|
selectRect(rect, options = {}) {
|
|
8461
8604
|
const { width, height } = this.naturalSize;
|
|
8462
|
-
return this.shapeCommand(
|
|
8605
|
+
return this.shapeCommand(_chunkL52VMQZScjs.rectSelection.call(void 0, width, height, rect, options), options);
|
|
8463
8606
|
}
|
|
8464
8607
|
/** Elliptical marquee inscribed in `rect`. */
|
|
8465
8608
|
selectEllipse(rect, options = {}) {
|
|
8466
8609
|
const { width, height } = this.naturalSize;
|
|
8467
|
-
return this.shapeCommand(
|
|
8610
|
+
return this.shapeCommand(_chunkL52VMQZScjs.ellipseSelection.call(void 0, width, height, rect, options), options);
|
|
8468
8611
|
}
|
|
8469
8612
|
/** Lasso / polygonal lasso. */
|
|
8470
8613
|
selectPolygon(points, options = {}) {
|
|
8471
8614
|
const { width, height } = this.naturalSize;
|
|
8472
|
-
return this.shapeCommand(
|
|
8615
|
+
return this.shapeCommand(_chunkL52VMQZScjs.polygonSelection.call(void 0, width, height, points, options), options);
|
|
8473
8616
|
}
|
|
8474
8617
|
/**
|
|
8475
8618
|
* Magnetic Lasso for a given outline: each point snaps to the strongest edge within `width` px
|
|
@@ -8505,7 +8648,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8505
8648
|
size: options.size,
|
|
8506
8649
|
grow: m === "add",
|
|
8507
8650
|
enhanceEdge: options.enhanceEdge,
|
|
8508
|
-
selection: m === "add" && _optionalChain([sel, 'optionalAccess',
|
|
8651
|
+
selection: m === "add" && _optionalChain([sel, 'optionalAccess', _339 => _339.bounds]) ? _chunkL52VMQZScjs.serializeMask.call(void 0, sel) : null
|
|
8509
8652
|
};
|
|
8510
8653
|
const { mask } = await this.runSelectionJob(job, pixels, {
|
|
8511
8654
|
signal: options.signal,
|
|
@@ -8525,7 +8668,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8525
8668
|
const { width, height } = this.naturalSize;
|
|
8526
8669
|
const image = await this.toDataURL({ format: "image/png" });
|
|
8527
8670
|
const results = await provider.segment({ ...request, image, width, height });
|
|
8528
|
-
_optionalChain([request, 'access',
|
|
8671
|
+
_optionalChain([request, 'access', _340 => _340.signal, 'optionalAccess', _341 => _341.throwIfAborted, 'call', _342 => _342()]);
|
|
8529
8672
|
const decoded = [];
|
|
8530
8673
|
for (const r of _nullishCoalesce(results, () => ( []))) decoded.push({ ...r, mask: r.mask !== void 0 ? await this.decodeMaskImage(r.mask) : void 0 });
|
|
8531
8674
|
return decoded;
|
|
@@ -8542,11 +8685,11 @@ var ImageEditorController = (_class12 = class {
|
|
|
8542
8685
|
let union = null;
|
|
8543
8686
|
for (const r of decoded) {
|
|
8544
8687
|
const one = segmentsToSelection(width, height, [r]);
|
|
8545
|
-
if (!_optionalChain([one, 'optionalAccess',
|
|
8688
|
+
if (!_optionalChain([one, 'optionalAccess', _343 => _343.bounds])) continue;
|
|
8546
8689
|
if ("rect" in target) {
|
|
8547
8690
|
const r0 = target.rect;
|
|
8548
8691
|
const grow = 0.1 * Math.max(r0.width, r0.height);
|
|
8549
|
-
const box =
|
|
8692
|
+
const box = _chunkL52VMQZScjs.rectSelection.call(void 0, width, height, { x: r0.x - grow, y: r0.y - grow, width: r0.width + 2 * grow, height: r0.height + 2 * grow }, { antiAlias: false });
|
|
8550
8693
|
const inside = _chunkQYLWG22Ncjs.combineSelections.call(void 0, one, box, "intersect");
|
|
8551
8694
|
if (!inside || _chunkQYLWG22Ncjs.selectionArea.call(void 0, inside) < _chunkQYLWG22Ncjs.selectionArea.call(void 0, one) * 0.5) continue;
|
|
8552
8695
|
union = _chunkQYLWG22Ncjs.combineSelections.call(void 0, union, inside, "add");
|
|
@@ -8610,7 +8753,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8610
8753
|
if (this.segmentation && options.useModel !== false) {
|
|
8611
8754
|
const { width, height } = this.naturalSize;
|
|
8612
8755
|
const sky = segmentsToSelection(width, height, await this.modelSegments({ target: "the sky", signal: options.signal }));
|
|
8613
|
-
if (!_optionalChain([sky, 'optionalAccess',
|
|
8756
|
+
if (!_optionalChain([sky, 'optionalAccess', _344 => _344.bounds])) return { selection: _nullishCoalesce(this.state.selection, () => ( null)), method: "model", note: "The segmentation model found no sky." };
|
|
8614
8757
|
this.setSelection(sky, _nullishCoalesce(options.mode, () => ( "replace")));
|
|
8615
8758
|
return { selection: _nullishCoalesce(this.state.selection, () => ( null)), method: "model" };
|
|
8616
8759
|
}
|
|
@@ -8641,7 +8784,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8641
8784
|
try {
|
|
8642
8785
|
const canvas = await this.renderSource();
|
|
8643
8786
|
const ctx = canvas.getContext("2d");
|
|
8644
|
-
const data2 = _optionalChain([ctx, 'optionalAccess',
|
|
8787
|
+
const data2 = _optionalChain([ctx, 'optionalAccess', _345 => _345.getImageData, 'optionalCall', _346 => _346(0, 0, width, height)]);
|
|
8645
8788
|
if (data2 && data2.data && data2.data.length >= width * height * 4) {
|
|
8646
8789
|
base = { width, height, data: data2.data };
|
|
8647
8790
|
this.samplePixels = base;
|
|
@@ -8716,7 +8859,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8716
8859
|
/** Select › Modify: grow, shrink, feather, border or smooth by `radius` pixels (one undo step). */
|
|
8717
8860
|
modifySelection(op, radius) {
|
|
8718
8861
|
const sel = this.state.selection;
|
|
8719
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
8862
|
+
if (!_optionalChain([sel, 'optionalAccess', _347 => _347.bounds])) return false;
|
|
8720
8863
|
return this.setSelection(_chunkQYLWG22Ncjs.modifySelection.call(void 0, sel, op, radius));
|
|
8721
8864
|
}
|
|
8722
8865
|
/**
|
|
@@ -8725,9 +8868,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
8725
8868
|
*/
|
|
8726
8869
|
async refineSelection(params, options = {}) {
|
|
8727
8870
|
const sel = this.state.selection;
|
|
8728
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
8871
|
+
if (!_optionalChain([sel, 'optionalAccess', _348 => _348.bounds])) return false;
|
|
8729
8872
|
const pixels = (_nullishCoalesce(params.radius, () => ( 0))) > 0 ? await this.requirePixels(options) : null;
|
|
8730
|
-
return this.setSelection(
|
|
8873
|
+
return this.setSelection(_chunkL52VMQZScjs.refineSelection.call(void 0, pixels, sel, params));
|
|
8731
8874
|
}
|
|
8732
8875
|
/**
|
|
8733
8876
|
* Select and Mask's output: refines the selection with `params`, then puts the result where
|
|
@@ -8747,13 +8890,17 @@ var ImageEditorController = (_class12 = class {
|
|
|
8747
8890
|
async refineSelectionTo(params, output = "selection", options = {}) {
|
|
8748
8891
|
const edits = _nullishCoalesce(options.edits, () => ( []));
|
|
8749
8892
|
const refineMode = _nullishCoalesce(options.refineMode, () => ( "color"));
|
|
8750
|
-
if (!_optionalChain([this, 'access',
|
|
8893
|
+
if (!_optionalChain([this, 'access', _349 => _349.state, 'access', _350 => _350.selection, 'optionalAccess', _351 => _351.bounds]) && !edits.length) throw new Error("Nothing is selected; select first, or pass edits that paint a selection.");
|
|
8751
8894
|
if (refineMode === "object" && !this.segmentation) {
|
|
8752
8895
|
throw new Error("Object aware refinement needs a segmentation model (setSegmentationProvider); use refineMode color.");
|
|
8753
8896
|
}
|
|
8754
8897
|
const amount = Math.min(100, Math.max(0, _nullishCoalesce(options.decontaminate, () => ( 0)))) / 100;
|
|
8755
|
-
const
|
|
8756
|
-
|
|
8898
|
+
const toDocument = output === "new-document" || output === "new-document-with-mask";
|
|
8899
|
+
const toLayer = output === "new-layer" || output === "new-layer-with-mask" || toDocument;
|
|
8900
|
+
if (amount > 0 && !toLayer) throw new Error("Decontaminate colors writes the cleaned colours to a new layer or document: use output new-layer, new-layer-with-mask, new-document or new-document-with-mask.");
|
|
8901
|
+
if (toDocument && !this.documentOpener) {
|
|
8902
|
+
throw new Error("This editor cannot open new documents (no document opener is set); use output new-layer or new-layer-with-mask instead.");
|
|
8903
|
+
}
|
|
8757
8904
|
let layerId;
|
|
8758
8905
|
if (output !== "selection") {
|
|
8759
8906
|
layerId = _nullishCoalesce(_nullishCoalesce(options.layerId, () => ( this.state.activeLayerId)), () => ( void 0));
|
|
@@ -8764,20 +8911,26 @@ var ImageEditorController = (_class12 = class {
|
|
|
8764
8911
|
const needsPixels = (_nullishCoalesce(params.radius, () => ( 0))) > 0 || edits.some((e) => e.kind !== "brush");
|
|
8765
8912
|
const pixels = needsPixels ? await this.requirePixels(options) : null;
|
|
8766
8913
|
const { width, height } = this.naturalSize;
|
|
8767
|
-
const edited =
|
|
8914
|
+
const edited = _chunkL52VMQZScjs.applyRefineEdits.call(void 0, pixels, _nullishCoalesce(this.state.selection, () => ( null)), edits, width, height);
|
|
8768
8915
|
let sel = edited.selection;
|
|
8769
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
8916
|
+
if (!_optionalChain([sel, 'optionalAccess', _352 => _352.bounds])) throw new Error("The edits leave nothing selected; paint with mode add first.");
|
|
8770
8917
|
if (refineMode === "object") {
|
|
8771
8918
|
const b = sel.bounds;
|
|
8772
8919
|
const found = await this.modelObject({ rect: b }, options.signal);
|
|
8773
8920
|
if (!found) throw new Error("The segmentation model found no object in the selection; use refineMode color.");
|
|
8774
8921
|
const near = _chunkQYLWG22Ncjs.modifySelection.call(void 0, sel, "expand", Math.max(4, _nullishCoalesce(params.radius, () => ( 8))));
|
|
8775
8922
|
const clipped = _chunkQYLWG22Ncjs.combineSelections.call(void 0, found, near, "intersect");
|
|
8776
|
-
if (!_optionalChain([clipped, 'optionalAccess',
|
|
8923
|
+
if (!_optionalChain([clipped, 'optionalAccess', _353 => _353.bounds])) throw new Error("The segmentation model found no object in the selection; use refineMode color.");
|
|
8777
8924
|
sel = clipped;
|
|
8778
8925
|
}
|
|
8779
|
-
const refined =
|
|
8926
|
+
const refined = _chunkL52VMQZScjs.refineSelection.call(void 0, pixels, sel, params, edited.refineBrush);
|
|
8780
8927
|
if (!refined.bounds) throw new Error("Refining left nothing selected; use a smaller shiftEdge or contrast.");
|
|
8928
|
+
if (toDocument) {
|
|
8929
|
+
const document2 = this.documentFromSelection({ layerId, withMask: output === "new-document-with-mask", selection: refined, decontaminate: amount * 100, radius: params.radius });
|
|
8930
|
+
const name = `${_chunkQE7D7TZRcjs.requireLayer.call(void 0, this.state.layers, layerId).layer.name || "Layer"} ${output === "new-document" ? "cutout" : "masked"}`;
|
|
8931
|
+
const documentId = await this.documentOpener(document2, { name, from: "select-and-mask" });
|
|
8932
|
+
return { output, layerId, refineMode, ...documentId ? { documentId } : {} };
|
|
8933
|
+
}
|
|
8781
8934
|
return this.asOneStep(() => {
|
|
8782
8935
|
this.setSelection(refined);
|
|
8783
8936
|
if (output === "selection") return { output, refineMode };
|
|
@@ -8808,6 +8961,16 @@ var ImageEditorController = (_class12 = class {
|
|
|
8808
8961
|
const layer = _chunkQE7D7TZRcjs.requireLayer.call(void 0, this.state.layers, id).layer;
|
|
8809
8962
|
const source = _chunkQE7D7TZRcjs.requireLayer.call(void 0, this.state.layers, sourceId).layer;
|
|
8810
8963
|
if (layer.type !== "pixel" || source.type !== "pixel" || !coverage.bounds) return;
|
|
8964
|
+
const surface = this.decontaminatedSurface(layer, source, coverage, amount, radius);
|
|
8965
|
+
const next = _chunkUOGKSVRQcjs.mapLayer.call(void 0, this.state.layers, id, (l) => {
|
|
8966
|
+
const updated = { ...l, surface };
|
|
8967
|
+
delete updated.source;
|
|
8968
|
+
return updated;
|
|
8969
|
+
});
|
|
8970
|
+
this.commitLayers(next);
|
|
8971
|
+
}
|
|
8972
|
+
/** `layer`'s surface with Decontaminate Colors applied along `coverage`'s soft edge, colours read from `source`. */
|
|
8973
|
+
decontaminatedSurface(layer, source, coverage, amount, radius) {
|
|
8811
8974
|
const { width, height } = this.naturalSize;
|
|
8812
8975
|
const pad = Math.ceil(radius * 3);
|
|
8813
8976
|
const b = coverage.bounds;
|
|
@@ -8821,14 +8984,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
8821
8984
|
const cov = new Uint8Array(box.width * box.height);
|
|
8822
8985
|
const all = coverage.data;
|
|
8823
8986
|
for (let y = 0; y < box.height; y++) cov.set(all.subarray((box.y + y) * width + box.x, (box.y + y) * width + box.x + box.width), y * box.width);
|
|
8824
|
-
const cleaned =
|
|
8987
|
+
const cleaned = _chunkL52VMQZScjs.decontaminateColors.call(void 0, original, cov, box.width, box.height, amount, radius);
|
|
8825
8988
|
for (let i = 3; i < cleaned.length; i += 4) cleaned[i] = rgba[i];
|
|
8826
|
-
|
|
8827
|
-
const updated = { ...l, surface: _chunk474IQG74cjs.writeRegion.call(void 0, surface, src, cleaned) };
|
|
8828
|
-
delete updated.source;
|
|
8829
|
-
return updated;
|
|
8830
|
-
});
|
|
8831
|
-
this.commitLayers(next);
|
|
8989
|
+
return _chunk474IQG74cjs.writeRegion.call(void 0, surface, src, cleaned);
|
|
8832
8990
|
}
|
|
8833
8991
|
/**
|
|
8834
8992
|
* Loads a selection from a mask image (an AI segmentation, a saved mask): a data URL / URL or
|
|
@@ -8857,7 +9015,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8857
9015
|
let mask;
|
|
8858
9016
|
if (source === "selection") {
|
|
8859
9017
|
const sel = this.state.selection;
|
|
8860
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
9018
|
+
if (!_optionalChain([sel, 'optionalAccess', _354 => _354.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, or export a channel or a layer mask.");
|
|
8861
9019
|
mask = sel;
|
|
8862
9020
|
} else if ("channelId" in source) {
|
|
8863
9021
|
mask = this.requireChannel(source.channelId).mask;
|
|
@@ -8881,7 +9039,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8881
9039
|
const canvas = this.renderer.createCanvas(w, h);
|
|
8882
9040
|
const ctx = canvas.getContext("2d");
|
|
8883
9041
|
if (ctx) ctx.drawImage(img, 0, 0, w, h);
|
|
8884
|
-
const data = _optionalChain([ctx, 'optionalAccess',
|
|
9042
|
+
const data = _optionalChain([ctx, 'optionalAccess', _355 => _355.getImageData, 'optionalCall', _356 => _356(0, 0, w, h)]);
|
|
8885
9043
|
if (!data) throw new Error("The mask image pixels are not available (no canvas access); pass pixels.");
|
|
8886
9044
|
return { width: w, height: h, data: data.data };
|
|
8887
9045
|
}
|
|
@@ -8897,7 +9055,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8897
9055
|
const provider = this.segmentation;
|
|
8898
9056
|
if (!provider) {
|
|
8899
9057
|
const pixels = await this.requirePixels({});
|
|
8900
|
-
_optionalChain([options, 'access',
|
|
9058
|
+
_optionalChain([options, 'access', _357 => _357.signal, 'optionalAccess', _358 => _358.throwIfAborted, 'call', _359 => _359()]);
|
|
8901
9059
|
const { mask: selection, reason } = await this.runSelectionJob({ op: "subject", enhanceEdge: options.enhanceEdge }, pixels, options);
|
|
8902
9060
|
if (selection.bounds) this.shapeCommand(selection, options);
|
|
8903
9061
|
const unused = target.trim() ? ` "${target.trim()}" was not used to choose it.` : "";
|
|
@@ -8913,17 +9071,17 @@ var ImageEditorController = (_class12 = class {
|
|
|
8913
9071
|
const decoded = await this.modelSegments({ target: description, maxSegments: options.maxSegments, signal: options.signal });
|
|
8914
9072
|
const segments = decoded.map((r) => {
|
|
8915
9073
|
const one = segmentsToSelection(width, height, [r]);
|
|
8916
|
-
return { label: r.label || description, bounds: _nullishCoalesce(_optionalChain([one, 'optionalAccess',
|
|
9074
|
+
return { label: r.label || description, bounds: _nullishCoalesce(_optionalChain([one, 'optionalAccess', _360 => _360.bounds]), () => ( null)), ...r.score !== void 0 ? { score: r.score } : {} };
|
|
8917
9075
|
});
|
|
8918
9076
|
const mask = segmentsToSelection(width, height, decoded);
|
|
8919
9077
|
if (mask && options.beforeApply) {
|
|
8920
9078
|
const outlines = decoded.flatMap((r, i) => {
|
|
8921
9079
|
const rings = segmentationOutlines(r);
|
|
8922
|
-
const b = _optionalChain([segments, 'access',
|
|
9080
|
+
const b = _optionalChain([segments, 'access', _361 => _361[i], 'optionalAccess', _362 => _362.bounds]);
|
|
8923
9081
|
return rings.length ? rings : b ? [[{ x: b.x, y: b.y }, { x: b.x + b.width, y: b.y }, { x: b.x + b.width, y: b.y + b.height }, { x: b.x, y: b.y + b.height }]] : [];
|
|
8924
9082
|
});
|
|
8925
9083
|
await options.beforeApply(outlines);
|
|
8926
|
-
_optionalChain([options, 'access',
|
|
9084
|
+
_optionalChain([options, 'access', _363 => _363.signal, 'optionalAccess', _364 => _364.throwIfAborted, 'call', _365 => _365()]);
|
|
8927
9085
|
}
|
|
8928
9086
|
if (mask) this.shapeCommand(mask, options);
|
|
8929
9087
|
return { segments: segments.filter((s) => s.bounds), method: "model" };
|
|
@@ -8956,7 +9114,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8956
9114
|
const view = this.state.maskView;
|
|
8957
9115
|
if (!view) return null;
|
|
8958
9116
|
const layer = this.getLayer(view.layerId);
|
|
8959
|
-
return _optionalChain([layer, 'optionalAccess',
|
|
9117
|
+
return _optionalChain([layer, 'optionalAccess', _366 => _366.mask]) && !layer.mask.source ? view : null;
|
|
8960
9118
|
}
|
|
8961
9119
|
/**
|
|
8962
9120
|
* Shows a layer's mask on the canvas: `gray` alone in grey (Alt-click the mask thumbnail),
|
|
@@ -8979,7 +9137,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8979
9137
|
if (!layer.mask) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${layer.name || id}" has no mask to show; add one with add_layer_mask.`);
|
|
8980
9138
|
if (layer.mask.source) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${layer.name || id}" has a depth mask, which is computed, not painted, so it has no mask view.`);
|
|
8981
9139
|
const cur = this.state.maskView;
|
|
8982
|
-
if (_optionalChain([cur, 'optionalAccess',
|
|
9140
|
+
if (_optionalChain([cur, 'optionalAccess', _367 => _367.layerId]) !== id || cur.mode !== mode) {
|
|
8983
9141
|
this.state.maskView = { layerId: id, mode };
|
|
8984
9142
|
this.notify();
|
|
8985
9143
|
}
|
|
@@ -8991,7 +9149,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
8991
9149
|
return _nullishCoalesce(this.state.channels, () => ( []));
|
|
8992
9150
|
}
|
|
8993
9151
|
getChannel(id) {
|
|
8994
|
-
return _nullishCoalesce(_optionalChain([this, 'access',
|
|
9152
|
+
return _nullishCoalesce(_optionalChain([this, 'access', _368 => _368.state, 'access', _369 => _369.channels, 'optionalAccess', _370 => _370.find, 'call', _371 => _371((c) => c.id === id)]), () => ( null));
|
|
8995
9153
|
}
|
|
8996
9154
|
requireChannel(id) {
|
|
8997
9155
|
const channel = this.getChannel(id);
|
|
@@ -9020,14 +9178,14 @@ var ImageEditorController = (_class12 = class {
|
|
|
9020
9178
|
*/
|
|
9021
9179
|
saveSelection(options = {}) {
|
|
9022
9180
|
const sel = this.state.selection;
|
|
9023
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
9181
|
+
if (!_optionalChain([sel, 'optionalAccess', _372 => _372.bounds])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Nothing is selected; select first, then save the selection to a channel.");
|
|
9024
9182
|
const { width, height } = this.naturalSize;
|
|
9025
9183
|
const sized = sel.width === width && sel.height === height ? sel : _chunkQYLWG22Ncjs.resizeSelection.call(void 0, sel, width, height);
|
|
9026
9184
|
const channels = [...this.getChannels()];
|
|
9027
9185
|
if (options.channelId !== void 0) {
|
|
9028
9186
|
const existing = this.requireChannel(options.channelId);
|
|
9029
9187
|
const mask = _nullishCoalesce(_chunkQYLWG22Ncjs.combineSelections.call(void 0, existing.mask.bounds ? existing.mask : null, sized, _nullishCoalesce(options.mode, () => ( "replace"))), () => ( _chunkQYLWG22Ncjs.createSelectionMask.call(void 0, width, height)));
|
|
9030
|
-
const next = { ...existing, mask, ..._optionalChain([options, 'access',
|
|
9188
|
+
const next = { ...existing, mask, ..._optionalChain([options, 'access', _373 => _373.name, 'optionalAccess', _374 => _374.trim, 'call', _375 => _375()]) ? { name: options.name.trim() } : {} };
|
|
9031
9189
|
this.setChannels(channels.map((c) => c.id === existing.id ? next : c));
|
|
9032
9190
|
return next;
|
|
9033
9191
|
}
|
|
@@ -9038,7 +9196,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9038
9196
|
const channels = this.getChannels();
|
|
9039
9197
|
const channel = {
|
|
9040
9198
|
id: this.newChannelId(),
|
|
9041
|
-
name: _optionalChain([name, 'optionalAccess',
|
|
9199
|
+
name: _optionalChain([name, 'optionalAccess', _376 => _376.trim, 'call', _377 => _377()]) || `Alpha ${channels.length + 1}`,
|
|
9042
9200
|
mask,
|
|
9043
9201
|
color: DEFAULT_CHANNEL_COLOR,
|
|
9044
9202
|
opacity: 0.5,
|
|
@@ -9083,7 +9241,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9083
9241
|
/** Duplicates an alpha channel just after it (one undo step). Returns the copy. */
|
|
9084
9242
|
duplicateChannel(id, name) {
|
|
9085
9243
|
const channel = this.requireChannel(id);
|
|
9086
|
-
const copy = { ...channel, id: this.newChannelId(), name: _optionalChain([name, 'optionalAccess',
|
|
9244
|
+
const copy = { ...channel, id: this.newChannelId(), name: _optionalChain([name, 'optionalAccess', _378 => _378.trim, 'call', _379 => _379()]) || `${channel.name} copy` };
|
|
9087
9245
|
const channels = [...this.getChannels()];
|
|
9088
9246
|
channels.splice(channels.findIndex((c) => c.id === id) + 1, 0, copy);
|
|
9089
9247
|
this.setChannels(channels);
|
|
@@ -9114,7 +9272,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9114
9272
|
quickMaskSurface() {
|
|
9115
9273
|
const { width, height } = this.naturalSize;
|
|
9116
9274
|
const sel = this.state.selection;
|
|
9117
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
9275
|
+
if (!_optionalChain([sel, 'optionalAccess', _380 => _380.bounds])) return _chunk474IQG74cjs.emptySurface.call(void 0, 1, 0);
|
|
9118
9276
|
return (sel.width === width && sel.height === height ? sel : _chunkQYLWG22Ncjs.resizeSelection.call(void 0, sel, width, height)).surface;
|
|
9119
9277
|
}
|
|
9120
9278
|
/** The selection a painted Quick Mask surface stands for (it shares the surface's tiles). */
|
|
@@ -9135,7 +9293,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9135
9293
|
*/
|
|
9136
9294
|
applySelectionAsLayerMask(layerId, props = {}) {
|
|
9137
9295
|
const sel = this.state.selection;
|
|
9138
|
-
if (!_optionalChain([sel, 'optionalAccess',
|
|
9296
|
+
if (!_optionalChain([sel, 'optionalAccess', _381 => _381.bounds]) || !this.getAdjustmentLayer(layerId)) return false;
|
|
9139
9297
|
return this.setLayerMask(layerId, this.maskFromSelection(sel, props));
|
|
9140
9298
|
}
|
|
9141
9299
|
setLayerMask(layerId, mask, commitToHistory = true) {
|
|
@@ -9175,7 +9333,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9175
9333
|
/** A layer's painted mask over the canvas as a selection mask; null without one (or for a depth mask). */
|
|
9176
9334
|
layerMaskCoverage(layerId) {
|
|
9177
9335
|
const layer = this.getLayer(layerId);
|
|
9178
|
-
if (!_optionalChain([layer, 'optionalAccess',
|
|
9336
|
+
if (!_optionalChain([layer, 'optionalAccess', _382 => _382.mask]) || layer.mask.source) return null;
|
|
9179
9337
|
const { width, height } = this.naturalSize;
|
|
9180
9338
|
const ox = layer.type === "pixel" ? layer.offset.x : 0;
|
|
9181
9339
|
const oy = layer.type === "pixel" ? layer.offset.y : 0;
|
|
@@ -9210,7 +9368,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9210
9368
|
this.state.layers = _chunkUOGKSVRQcjs.mapLayer.call(void 0, this.state.layers, target.id, (l) => {
|
|
9211
9369
|
const next = { ...l };
|
|
9212
9370
|
if (_chunkQE7D7TZRcjs.isDefaultDepthMask.call(void 0, merged)) {
|
|
9213
|
-
if (_optionalChain([next, 'access',
|
|
9371
|
+
if (_optionalChain([next, 'access', _383 => _383.mask, 'optionalAccess', _384 => _384.source])) delete next.mask;
|
|
9214
9372
|
} else next.mask = _chunkQE7D7TZRcjs.depthRasterMask.call(void 0, merged);
|
|
9215
9373
|
return next;
|
|
9216
9374
|
});
|
|
@@ -9220,7 +9378,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9220
9378
|
resetDepthMask() {
|
|
9221
9379
|
this.recordHistory();
|
|
9222
9380
|
const target = this.developLayer();
|
|
9223
|
-
if (_optionalChain([target, 'optionalAccess',
|
|
9381
|
+
if (_optionalChain([target, 'optionalAccess', _385 => _385.mask, 'optionalAccess', _386 => _386.source])) {
|
|
9224
9382
|
this.state.layers = _chunkUOGKSVRQcjs.mapLayer.call(void 0, this.state.layers, target.id, (l) => {
|
|
9225
9383
|
const next = { ...l };
|
|
9226
9384
|
delete next.mask;
|
|
@@ -9232,7 +9390,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9232
9390
|
// --- Annotations & Layers ---
|
|
9233
9391
|
/** The layer showing annotation `id`: an annotation layer, or a shape layer migrated from it. */
|
|
9234
9392
|
annotationLayer(id) {
|
|
9235
|
-
return _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers).find((l) => (l.type === "annotation" || l.type === "shape" || l.type === "type") && _optionalChain([_chunkQE7D7TZRcjs.annotationOfLayer.call(void 0, l), 'optionalAccess',
|
|
9393
|
+
return _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers).find((l) => (l.type === "annotation" || l.type === "shape" || l.type === "type") && _optionalChain([_chunkQE7D7TZRcjs.annotationOfLayer.call(void 0, l), 'optionalAccess', _387 => _387.id]) === id);
|
|
9236
9394
|
}
|
|
9237
9395
|
/** What migrating an annotation needs: the canvas size, patterns and the text shaper. */
|
|
9238
9396
|
annotationEnv() {
|
|
@@ -9250,7 +9408,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9250
9408
|
const fullAnnotation = { ...annotation, id };
|
|
9251
9409
|
const layer = _chunkQE7D7TZRcjs.annotationLayerFor.call(void 0, fullAnnotation, this.annotationEnv());
|
|
9252
9410
|
const loc = placement.aboveId ? _chunkUOGKSVRQcjs.findLayer.call(void 0, this.state.layers, placement.aboveId) : null;
|
|
9253
|
-
this.state.layers = loc ? _chunkUOGKSVRQcjs.insertLayer.call(void 0, this.state.layers, layer, _nullishCoalesce(_optionalChain([loc, 'access',
|
|
9411
|
+
this.state.layers = loc ? _chunkUOGKSVRQcjs.insertLayer.call(void 0, this.state.layers, layer, _nullishCoalesce(_optionalChain([loc, 'access', _388 => _388.parent, 'optionalAccess', _389 => _389.id]), () => ( null)), loc.index + 1) : _chunkUOGKSVRQcjs.insertLayer.call(void 0, this.state.layers, layer, null);
|
|
9254
9412
|
this.state.selectedAnnotationId = id;
|
|
9255
9413
|
this.notify();
|
|
9256
9414
|
return id;
|
|
@@ -9330,7 +9488,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9330
9488
|
this.notify();
|
|
9331
9489
|
}
|
|
9332
9490
|
// --- Rendering & Export ---
|
|
9333
|
-
|
|
9491
|
+
__init102() {this.blankSource = null}
|
|
9334
9492
|
/**
|
|
9335
9493
|
* What the renderer draws from: the source image, or, for a document without one (an opened
|
|
9336
9494
|
* PSD, a v3 document loaded on its own), a transparent canvas of the document size, since every
|
|
@@ -9358,7 +9516,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9358
9516
|
const cs = s.paint.cloneSource;
|
|
9359
9517
|
if (!cs) return null;
|
|
9360
9518
|
if (cursor && cs.offset && s.paint.retouch.aligned) {
|
|
9361
|
-
const [x, y] =
|
|
9519
|
+
const [x, y] = _chunkYF3YZZ6Gcjs.cloneSamplePoint.call(void 0, s.paint.cloneTransform, cs, { x: cs.x - cs.offset.x, y: cs.y - cs.offset.y }, cursor.x, cursor.y);
|
|
9362
9520
|
return { x, y };
|
|
9363
9521
|
}
|
|
9364
9522
|
return { x: cs.x, y: cs.y };
|
|
@@ -9373,7 +9531,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9373
9531
|
await this.renderer.renderToCanvas(targetCanvas, source, this.state, {
|
|
9374
9532
|
...options,
|
|
9375
9533
|
// The clone source follows the brush cursor (both editors pass it).
|
|
9376
|
-
cloneSourceMarker: _optionalChain([options, 'optionalAccess',
|
|
9534
|
+
cloneSourceMarker: _optionalChain([options, 'optionalAccess', _390 => _390.cloneSourceMarker]) !== void 0 ? options.cloneSourceMarker : _optionalChain([options, 'optionalAccess', _391 => _391.brushCursor]) ? this.cloneSourceMarker(options.brushCursor) : null,
|
|
9377
9535
|
dirty: dirty === "all" ? void 0 : dirty,
|
|
9378
9536
|
checkpointLayerId: this.state.activeLayerId
|
|
9379
9537
|
});
|
|
@@ -9386,7 +9544,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9386
9544
|
return this.renderer.createCanvas(1, 1);
|
|
9387
9545
|
}
|
|
9388
9546
|
this.syncViews();
|
|
9389
|
-
if (_optionalChain([options, 'optionalAccess',
|
|
9547
|
+
if (_optionalChain([options, 'optionalAccess', _392 => _392.layerIds])) {
|
|
9390
9548
|
const keep = new Set(options.layerIds);
|
|
9391
9549
|
const layers = _chunkUOGKSVRQcjs.flattenLayers.call(void 0, this.state.layers).filter((l) => keep.has(l.id));
|
|
9392
9550
|
return this.renderer.renderExport(source, { ...this.state, layers }, options);
|
|
@@ -9540,7 +9698,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9540
9698
|
let px2 = await this.decodeImage(newDataUrl);
|
|
9541
9699
|
if (px2.width !== width || px2.height !== height) px2 = resizePixels(px2, width, height);
|
|
9542
9700
|
const data = new Uint8ClampedArray(px2.data);
|
|
9543
|
-
const sel = _optionalChain([this, 'access',
|
|
9701
|
+
const sel = _optionalChain([this, 'access', _393 => _393.state, 'access', _394 => _394.selection, 'optionalAccess', _395 => _395.bounds]) ? this.state.selection : null;
|
|
9544
9702
|
if (sel) for (let p = 0, i = 3; p < width * height; p++, i += 4) data[i] = Math.round(data[i] * sel.data[p] / 255);
|
|
9545
9703
|
return this.addPixelLayer({ name: "Inpaint", pixels: { width, height, data } });
|
|
9546
9704
|
}
|
|
@@ -9587,7 +9745,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9587
9745
|
}
|
|
9588
9746
|
/** Font families the shaper offers (generic families at least). */
|
|
9589
9747
|
listFonts() {
|
|
9590
|
-
return _nullishCoalesce(_optionalChain([this, 'access',
|
|
9748
|
+
return _nullishCoalesce(_optionalChain([this, 'access', _396 => _396.getTextShaper, 'call', _397 => _397(), 'optionalAccess', _398 => _398.families, 'optionalCall', _399 => _399()]), () => ( ["sans-serif", "serif", "monospace"]));
|
|
9591
9749
|
}
|
|
9592
9750
|
typeInfo(id) {
|
|
9593
9751
|
const layer = _chunkQE7D7TZRcjs.requireTypeLayer.call(void 0, this.state.layers, id);
|
|
@@ -9661,8 +9819,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
9661
9819
|
const layer = this.layoutTypeLayer({ ...init, text, orientation: vertical ? "vertical" : "horizontal" });
|
|
9662
9820
|
const { width, height } = this.naturalSize;
|
|
9663
9821
|
const b = _chunk474IQG74cjs.contentBounds.call(void 0, layer.surface);
|
|
9664
|
-
const x0 = Math.max(0, _nullishCoalesce(_optionalChain([b, 'optionalAccess',
|
|
9665
|
-
const y0 = Math.max(0, _nullishCoalesce(_optionalChain([b, 'optionalAccess',
|
|
9822
|
+
const x0 = Math.max(0, _nullishCoalesce(_optionalChain([b, 'optionalAccess', _400 => _400.x]), () => ( 0)));
|
|
9823
|
+
const y0 = Math.max(0, _nullishCoalesce(_optionalChain([b, 'optionalAccess', _401 => _401.y]), () => ( 0)));
|
|
9666
9824
|
const x1 = Math.min(width, b ? b.x + b.width : 0);
|
|
9667
9825
|
const y1 = Math.min(height, b ? b.y + b.height : 0);
|
|
9668
9826
|
let mask;
|
|
@@ -9839,7 +9997,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9839
9997
|
if (colors.size > 1) warnings.push("The text had several colours; the shape takes the first one.");
|
|
9840
9998
|
const missing = _chunkQAUIZPYIcjs.layoutText.call(void 0, layer, shaper).missingFonts;
|
|
9841
9999
|
if (missing.length) warnings.push(`Missing fonts were drawn with a fallback: ${missing.join(", ")}.`);
|
|
9842
|
-
const first = _nullishCoalesce(_optionalChain([layer, 'access',
|
|
10000
|
+
const first = _nullishCoalesce(_optionalChain([layer, 'access', _402 => _402.runs, 'access', _403 => _403.find, 'call', _404 => _404((r) => r.length > 0), 'optionalAccess', _405 => _405.style]), () => ( _chunkQAUIZPYIcjs.DEFAULT_TEXT_STYLE));
|
|
9843
10001
|
const fill = first.opacity !== void 0 && first.opacity !== 1 ? { type: "color", color: first.color, opacity: first.opacity } : { type: "color", color: first.color };
|
|
9844
10002
|
const shape = _chunkQE7D7TZRcjs.createShapeLayer.call(void 0, { components: [{ op: "combine", subpaths }], fill, stroke: null, name: layer.name }, this.shapeEnv(), layer.id);
|
|
9845
10003
|
const keep = { visible: layer.visible, opacity: layer.opacity, blend: layer.blend };
|
|
@@ -9872,7 +10030,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
9872
10030
|
// --- Shape layers ---
|
|
9873
10031
|
/** What shape rendering needs: the canvas size and the document's patterns. */
|
|
9874
10032
|
shapeEnv() {
|
|
9875
|
-
return { ...this.naturalSize, pattern: (id) => _nullishCoalesce(_optionalChain([this, 'access',
|
|
10033
|
+
return { ...this.naturalSize, pattern: (id) => _nullishCoalesce(_optionalChain([this, 'access', _406 => _406.state, 'access', _407 => _407.patterns, 'optionalAccess', _408 => _408.find, 'call', _409 => _409((p) => p.id === id)]), () => ( null)) };
|
|
9876
10034
|
}
|
|
9877
10035
|
/** One component from tool or UI input (validated). */
|
|
9878
10036
|
componentFrom(spec, path) {
|
|
@@ -9915,9 +10073,9 @@ var ImageEditorController = (_class12 = class {
|
|
|
9915
10073
|
* open path) and stroked with `stroke`. Goes above the active layer unless placed. Returns its id.
|
|
9916
10074
|
*/
|
|
9917
10075
|
addShapeLayer(init) {
|
|
9918
|
-
const specs = _optionalChain([init, 'access',
|
|
9919
|
-
if (_optionalChain([init, 'access',
|
|
9920
|
-
const components = specs.map((c, i) => this.componentFrom(c, _optionalChain([init, 'access',
|
|
10076
|
+
const specs = _optionalChain([init, 'access', _410 => _410.components, 'optionalAccess', _411 => _411.length]) ? init.components : [init];
|
|
10077
|
+
if (_optionalChain([init, 'access', _412 => _412.components, 'optionalAccess', _413 => _413.length]) && (init.shape !== void 0 || init.subpaths !== void 0)) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)("Give components, or shape / subpaths, not both.");
|
|
10078
|
+
const components = specs.map((c, i) => this.componentFrom(c, _optionalChain([init, 'access', _414 => _414.components, 'optionalAccess', _415 => _415.length]) ? `components[${i}].` : ""));
|
|
9921
10079
|
const stroke = init.stroke ? _chunkQE7D7TZRcjs.normalizeShapeStroke.call(void 0, init.stroke, "stroke") : null;
|
|
9922
10080
|
const openOnly = components.every((c) => !c.live && c.subpaths.every((sp) => !sp.closed));
|
|
9923
10081
|
const fill = init.fill === void 0 ? stroke && openOnly ? null : _chunkQE7D7TZRcjs.normalizeShapePaint.call(void 0, this.state.paint.foreground, "fill") : init.fill === null ? null : _chunkQE7D7TZRcjs.normalizeShapePaint.call(void 0, init.fill, "fill");
|
|
@@ -10028,7 +10186,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10028
10186
|
if (layer.locks) next.locks = layer.locks;
|
|
10029
10187
|
if (this.state.selectedAnnotationId === layer.annotation.id) this.state.selectedAnnotationId = null;
|
|
10030
10188
|
} else if (layer.type === "pixel") {
|
|
10031
|
-
if (!_optionalChain([layer, 'access',
|
|
10189
|
+
if (!_optionalChain([layer, 'access', _416 => _416.filters, 'optionalAccess', _417 => _417.length])) throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Layer "${layer.name || id}" is already pixels with no filters to bake.`);
|
|
10032
10190
|
_chunkQE7D7TZRcjs.requireUnlocked.call(void 0, layer, "pixels", "rasterize it");
|
|
10033
10191
|
const spatial = layer.filters.some((f) => f.enabled && f.kind === "blur");
|
|
10034
10192
|
const content = { ...layer, visible: true, opacity: 1, blend: "normal" };
|
|
@@ -10047,7 +10205,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10047
10205
|
return this.rasterizeSmartObject(id);
|
|
10048
10206
|
} else if (layer.type === "shape" || layer.type === "type") {
|
|
10049
10207
|
next = layer.type === "shape" ? _chunkQE7D7TZRcjs.shapeAsPixelLayer.call(void 0, layer) : _chunkQE7D7TZRcjs.typeAsPixelLayer.call(void 0, layer);
|
|
10050
|
-
if (this.state.selectedAnnotationId && this.state.selectedAnnotationId === _optionalChain([layer, 'access',
|
|
10208
|
+
if (this.state.selectedAnnotationId && this.state.selectedAnnotationId === _optionalChain([layer, 'access', _418 => _418.annotation, 'optionalAccess', _419 => _419.id])) this.state.selectedAnnotationId = null;
|
|
10051
10209
|
} else {
|
|
10052
10210
|
throw new (0, _chunkQE7D7TZRcjs.LayerOperationError)(`Only shape, type and annotation layers, smart objects and pixel layers with filters rasterize; "${layer.name || id}" is a ${layer.type} layer. Merge it down or flatten instead.`);
|
|
10053
10211
|
}
|
|
@@ -10061,8 +10219,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
10061
10219
|
const doc = this.state.colorProfile;
|
|
10062
10220
|
const p = resolveProfile(doc);
|
|
10063
10221
|
const m = this.state.colorMode;
|
|
10064
|
-
const out = { name: _nullishCoalesce(_optionalChain([doc, 'optionalAccess',
|
|
10065
|
-
if (_optionalChain([m, 'optionalAccess',
|
|
10222
|
+
const out = { name: _nullishCoalesce(_optionalChain([doc, 'optionalAccess', _420 => _420.name]), () => ( p.description)), builtin: doc ? _nullishCoalesce(doc.builtin, () => ( null)) : "srgb", colorSpace: p.colorSpace, srgb: isSrgb(doc), mode: _nullishCoalesce(_optionalChain([m, 'optionalAccess', _421 => _421.mode]), () => ( "rgb")) };
|
|
10223
|
+
if (_optionalChain([m, 'optionalAccess', _422 => _422.mode]) === "cmyk") out.cmykProfile = { name: m.profile.name, builtin: _nullishCoalesce(m.profile.builtin, () => ( null)), intent: m.intent };
|
|
10066
10224
|
return out;
|
|
10067
10225
|
}
|
|
10068
10226
|
/**
|
|
@@ -10152,7 +10310,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10152
10310
|
const textEnv = this.textEnv();
|
|
10153
10311
|
const walk = (layers) => layers.map((l) => {
|
|
10154
10312
|
let next2 = l;
|
|
10155
|
-
if (_optionalChain([l, 'access',
|
|
10313
|
+
if (_optionalChain([l, 'access', _423 => _423.effects, 'optionalAccess', _424 => _424.items, 'access', _425 => _425.length])) next2 = { ...next2, effects: convertColorFields(l.effects, hex) };
|
|
10156
10314
|
if (l.type === "group") {
|
|
10157
10315
|
if (next2 !== l) converted.push(l.id);
|
|
10158
10316
|
return { ...next2, children: walk(l.children) };
|
|
@@ -10336,8 +10494,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
10336
10494
|
else delete s.bitDepth;
|
|
10337
10495
|
delete s.colorProfile;
|
|
10338
10496
|
delete s.colorMode;
|
|
10339
|
-
if (_optionalChain([result, 'access',
|
|
10340
|
-
else if (_optionalChain([result, 'access',
|
|
10497
|
+
if (_optionalChain([result, 'access', _426 => _426.sourceMode, 'optionalAccess', _427 => _427.mode]) === "cmyk") s.colorMode = { mode: "cmyk", profile: result.sourceMode.profile, intent: "relative" };
|
|
10498
|
+
else if (_optionalChain([result, 'access', _428 => _428.sourceMode, 'optionalAccess', _429 => _429.mode]) === "lab") s.colorMode = { mode: "lab" };
|
|
10341
10499
|
else if (result.iccProfile) {
|
|
10342
10500
|
try {
|
|
10343
10501
|
const doc = documentProfile(result.iccProfile);
|
|
@@ -10401,7 +10559,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10401
10559
|
const compositor = new (0, _chunkQE7D7TZRcjs.LayerCompositor)();
|
|
10402
10560
|
const bakeMask = (layer) => {
|
|
10403
10561
|
const mask = layer.mask;
|
|
10404
|
-
if (!_optionalChain([mask, 'optionalAccess',
|
|
10562
|
+
if (!_optionalChain([mask, 'optionalAccess', _430 => _430.source])) return mask;
|
|
10405
10563
|
add2("Parametric (depth) masks were baked into pixel masks", layer.name);
|
|
10406
10564
|
const plain3 = { ...layer, mask: { ...mask, density: 1, feather: 0, enabled: true } };
|
|
10407
10565
|
const ox = layer.type === "pixel" ? layer.offset.x : 0;
|
|
@@ -10418,7 +10576,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10418
10576
|
};
|
|
10419
10577
|
const prepare = async (layer) => {
|
|
10420
10578
|
const p = await prepareLayer(layer);
|
|
10421
|
-
if (_optionalChain([p, 'optionalAccess',
|
|
10579
|
+
if (_optionalChain([p, 'optionalAccess', _431 => _431.blend]) === "pigment") add2("The Pigment blend mode has no PSD equivalent and was written as Normal", layer.name);
|
|
10422
10580
|
return p;
|
|
10423
10581
|
};
|
|
10424
10582
|
const prepareLayer = async (layer) => {
|
|
@@ -10461,7 +10619,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10461
10619
|
return out2;
|
|
10462
10620
|
}
|
|
10463
10621
|
if (layer.type === "shape" || layer.type === "type") {
|
|
10464
|
-
if (layer.type === "type" && _optionalChain([layer, 'access',
|
|
10622
|
+
if (layer.type === "type" && _optionalChain([layer, 'access', _432 => _432.missingFonts, 'optionalAccess', _433 => _433.length])) add2(`Type layers drawn with a fallback for missing fonts (${layer.missingFonts.join(", ")}) keep the font names, so Photoshop may draw them differently`, layer.name);
|
|
10465
10623
|
const out2 = { ...layer };
|
|
10466
10624
|
const mask2 = bakeMask(layer);
|
|
10467
10625
|
if (mask2) out2.mask = mask2;
|
|
@@ -10480,7 +10638,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10480
10638
|
out.surface = this.surfaceOf(layer);
|
|
10481
10639
|
delete out.source;
|
|
10482
10640
|
}
|
|
10483
|
-
const active = _nullishCoalesce(_optionalChain([layer, 'access',
|
|
10641
|
+
const active = _nullishCoalesce(_optionalChain([layer, 'access', _434 => _434.filters, 'optionalAccess', _435 => _435.filter, 'call', _436 => _436(_chunkQE7D7TZRcjs.isActiveFilter)]), () => ( []));
|
|
10484
10642
|
if (active.length) {
|
|
10485
10643
|
add2("Layer filters (develop, blur) were baked into the pixels", layer.name);
|
|
10486
10644
|
const content = { ...out, visible: true, opacity: 1, blend: "normal" };
|
|
@@ -10491,7 +10649,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10491
10649
|
const data = compositor.composite([content], canvas, sources);
|
|
10492
10650
|
out = { ...out, surface: _chunk474IQG74cjs.surfaceFromPixels.call(void 0, { width, height, data }, 4, -layer.offset.x, -layer.offset.y) };
|
|
10493
10651
|
}
|
|
10494
|
-
if (_optionalChain([layer, 'access',
|
|
10652
|
+
if (_optionalChain([layer, 'access', _437 => _437.filters, 'optionalAccess', _438 => _438.some, 'call', _439 => _439((f) => !f.enabled)])) add2("Disabled layer filters were left out", layer.name);
|
|
10495
10653
|
delete out.filters;
|
|
10496
10654
|
const mask = bakeMask(layer);
|
|
10497
10655
|
if (mask) out.mask = mask;
|
|
@@ -10555,7 +10713,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10555
10713
|
);
|
|
10556
10714
|
}
|
|
10557
10715
|
layers = resizeLegacyMasks(layers, prev, next.dimensions);
|
|
10558
|
-
const env = { ...next.dimensions, pattern: (pid) => _nullishCoalesce(_optionalChain([this, 'access',
|
|
10716
|
+
const env = { ...next.dimensions, pattern: (pid) => _nullishCoalesce(_optionalChain([this, 'access', _440 => _440.state, 'access', _441 => _441.patterns, 'optionalAccess', _442 => _442.find, 'call', _443 => _443((p) => p.id === pid)]), () => ( null)) };
|
|
10559
10717
|
for (const l of _chunkUOGKSVRQcjs.flattenLayers.call(void 0, layers)) {
|
|
10560
10718
|
if (l.type === "annotation") {
|
|
10561
10719
|
layers = _chunkUOGKSVRQcjs.mapLayer.call(void 0, layers, l.id, () => ({ ...l, annotation: scaleAnnotation(l.annotation, sx, sy) }));
|
|
@@ -10564,7 +10722,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10564
10722
|
const scaled = a ? scaleAnnotation(a, sx, sy) : null;
|
|
10565
10723
|
const fromAnnotation = scaled ? _chunkQE7D7TZRcjs.shapeFromAnnotation.call(void 0, scaled) : null;
|
|
10566
10724
|
const m = [sx, 0, 0, sy, 0, 0];
|
|
10567
|
-
const components = _nullishCoalesce(_optionalChain([fromAnnotation, 'optionalAccess',
|
|
10725
|
+
const components = _nullishCoalesce(_optionalChain([fromAnnotation, 'optionalAccess', _444 => _444.components]), () => ( _chunkQE7D7TZRcjs.transformShapeComponents.call(void 0, l.components, (p) => ({ x: p.x * sx, y: p.y * sy }), m)));
|
|
10568
10726
|
const moved = { ...l, components, ...fromAnnotation ? { fill: fromAnnotation.fill, stroke: fromAnnotation.stroke } : {} };
|
|
10569
10727
|
if (scaled && fromAnnotation) moved.annotation = scaled;
|
|
10570
10728
|
else delete moved.annotation;
|
|
@@ -10582,7 +10740,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10582
10740
|
this.notify();
|
|
10583
10741
|
}
|
|
10584
10742
|
toJSON(options) {
|
|
10585
|
-
const root = _optionalChain([this, 'access',
|
|
10743
|
+
const root = _optionalChain([this, 'access', _445 => _445.contentsStack, 'access', _446 => _446[0], 'optionalAccess', _447 => _447.saved]);
|
|
10586
10744
|
const current = this.state;
|
|
10587
10745
|
const element = this.imageElement;
|
|
10588
10746
|
if (root) {
|
|
@@ -10593,8 +10751,8 @@ var ImageEditorController = (_class12 = class {
|
|
|
10593
10751
|
let out;
|
|
10594
10752
|
try {
|
|
10595
10753
|
out = this.serializeState();
|
|
10596
|
-
if (_optionalChain([this, 'access',
|
|
10597
|
-
if (_optionalChain([this, 'access',
|
|
10754
|
+
if (_optionalChain([this, 'access', _448 => _448.state, 'access', _449 => _449.selection, 'optionalAccess', _450 => _450.bounds])) out.selection = _chunkQYLWG22Ncjs.serializeSelection.call(void 0, this.state.selection);
|
|
10755
|
+
if (_optionalChain([this, 'access', _451 => _451.state, 'access', _452 => _452.channels, 'optionalAccess', _453 => _453.length])) out.channels = serializeChannels(this.state.channels);
|
|
10598
10756
|
} finally {
|
|
10599
10757
|
if (root) {
|
|
10600
10758
|
this.state = current;
|
|
@@ -10643,7 +10801,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10643
10801
|
this.notify();
|
|
10644
10802
|
}
|
|
10645
10803
|
/** Problems found by the last `loadJSON` / `initialState` of a v3 document (unreadable layers or assets). */
|
|
10646
|
-
|
|
10804
|
+
__init103() {this.lastLoadProblems = []}
|
|
10647
10805
|
applyStored(raw) {
|
|
10648
10806
|
const s = this.state;
|
|
10649
10807
|
const data = migrateSerializedImageEditorState(raw);
|
|
@@ -10708,10 +10866,10 @@ var ImageEditorController = (_class12 = class {
|
|
|
10708
10866
|
serializeState() {
|
|
10709
10867
|
const { width, height } = this.naturalSize;
|
|
10710
10868
|
const view = _chunkQE7D7TZRcjs.legacyView.call(void 0, this.stack(), width, height, null);
|
|
10711
|
-
if (view.exact && !this.state.globalLight && !_optionalChain([this, 'access',
|
|
10869
|
+
if (view.exact && !this.state.globalLight && !_optionalChain([this, 'access', _454 => _454.state, 'access', _455 => _455.patterns, 'optionalAccess', _456 => _456.length]) && this.bitDepth === 8 && !this.state.colorProfile && !this.state.colorMode) {
|
|
10712
10870
|
return {
|
|
10713
10871
|
// States without adjustment layers keep schema 1, so they round-trip unchanged.
|
|
10714
|
-
version: _optionalChain([view, 'access',
|
|
10872
|
+
version: _optionalChain([view, 'access', _457 => _457.adjustments, 'access', _458 => _458.layers, 'optionalAccess', _459 => _459.length]) ? 2 : 1,
|
|
10715
10873
|
crop: this.state.crop ? { ...this.state.crop } : null,
|
|
10716
10874
|
transform: { ...this.state.transform },
|
|
10717
10875
|
adjustments: serializeAdjustments(view.adjustments),
|
|
@@ -10736,7 +10894,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10736
10894
|
};
|
|
10737
10895
|
if (this.state.legacyOutputBlur !== void 0) out.legacyOutputBlur = this.state.legacyOutputBlur;
|
|
10738
10896
|
if (this.state.globalLight) out.globalLight = { ...this.state.globalLight };
|
|
10739
|
-
if (_optionalChain([this, 'access',
|
|
10897
|
+
if (_optionalChain([this, 'access', _460 => _460.state, 'access', _461 => _461.patterns, 'optionalAccess', _462 => _462.length])) out.patterns = _chunkQE7D7TZRcjs.serializePatterns.call(void 0, this.state.patterns);
|
|
10740
10898
|
if (smartContents) out.smartContents = smartContents;
|
|
10741
10899
|
if (this.state.bitDepth === 16 || this.state.bitDepth === 32) out.bitDepth = this.state.bitDepth;
|
|
10742
10900
|
if (this.state.colorProfile) out.colorProfile = serializeColorProfile(this.state.colorProfile);
|
|
@@ -10746,7 +10904,7 @@ var ImageEditorController = (_class12 = class {
|
|
|
10746
10904
|
}, _class12);
|
|
10747
10905
|
function serializeAdjustments(adjustments) {
|
|
10748
10906
|
const out = { ...adjustments };
|
|
10749
|
-
if (_optionalChain([out, 'access',
|
|
10907
|
+
if (_optionalChain([out, 'access', _463 => _463.layers, 'optionalAccess', _464 => _464.length])) out.layers = JSON.parse(JSON.stringify(out.layers));
|
|
10750
10908
|
else delete out.layers;
|
|
10751
10909
|
if (_chunkQE7D7TZRcjs.normalizeProcessVersion.call(void 0, out.process) === _chunkQE7D7TZRcjs.LEGACY_PROCESS_VERSION) {
|
|
10752
10910
|
delete out.process;
|
|
@@ -10782,11 +10940,11 @@ function withDevelop(layer, partial) {
|
|
|
10782
10940
|
return { ...layer, filters };
|
|
10783
10941
|
}
|
|
10784
10942
|
function withBlur(layer, radius) {
|
|
10785
|
-
const existing = _optionalChain([layer, 'access',
|
|
10943
|
+
const existing = _optionalChain([layer, 'access', _465 => _465.filters, 'optionalAccess', _466 => _466.find, 'call', _467 => _467((f) => f.kind === "blur")]);
|
|
10786
10944
|
const filters = (_nullishCoalesce(layer.filters, () => ( []))).filter((f) => f.kind !== "blur");
|
|
10787
10945
|
if (radius > 0) {
|
|
10788
10946
|
filters.push({
|
|
10789
|
-
id: _nullishCoalesce(_optionalChain([existing, 'optionalAccess',
|
|
10947
|
+
id: _nullishCoalesce(_optionalChain([existing, 'optionalAccess', _468 => _468.id]), () => ( (layer.source === "document" ? _chunkQE7D7TZRcjs.BLUR_FILTER_ID : _chunkQE7D7TZRcjs.newLayerId.call(void 0, "flt")))),
|
|
10790
10948
|
kind: "blur",
|
|
10791
10949
|
enabled: true,
|
|
10792
10950
|
radius
|
|
@@ -10882,7 +11040,7 @@ function collectStateTiles(layers, into) {
|
|
|
10882
11040
|
if (l.type === "shape" || l.type === "type") _chunk474IQG74cjs.collectTiles.call(void 0, l.surface, into);
|
|
10883
11041
|
if (l.type === "smart") {
|
|
10884
11042
|
_chunk474IQG74cjs.collectTiles.call(void 0, l.surface, into);
|
|
10885
|
-
if (_optionalChain([l, 'access',
|
|
11043
|
+
if (_optionalChain([l, 'access', _469 => _469.smartFilters, 'optionalAccess', _470 => _470.mask])) _chunk474IQG74cjs.collectTiles.call(void 0, l.smartFilters.mask.surface, into);
|
|
10886
11044
|
if (l.contents.raster) _chunk474IQG74cjs.collectTiles.call(void 0, l.contents.raster, into);
|
|
10887
11045
|
if (l.contents.document) collectStateTiles(l.contents.document.layers, into);
|
|
10888
11046
|
}
|
|
@@ -10914,7 +11072,7 @@ function pixelsOnly(layers) {
|
|
|
10914
11072
|
for (const l of layers) {
|
|
10915
11073
|
if (l.type === "adjustment") continue;
|
|
10916
11074
|
if (l.type === "group") out.push({ ...l, children: pixelsOnly(l.children) });
|
|
10917
|
-
else if (l.type === "pixel" && _optionalChain([l, 'access',
|
|
11075
|
+
else if (l.type === "pixel" && _optionalChain([l, 'access', _471 => _471.filters, 'optionalAccess', _472 => _472.length])) {
|
|
10918
11076
|
const p = { ...l };
|
|
10919
11077
|
delete p.filters;
|
|
10920
11078
|
out.push(p);
|
|
@@ -10980,7 +11138,7 @@ function toHex(c) {
|
|
|
10980
11138
|
return "#" + [c[0], c[1], c[2]].map((v) => Math.round(v).toString(16).padStart(2, "0")).join("");
|
|
10981
11139
|
}
|
|
10982
11140
|
function normalizeSelection(mask) {
|
|
10983
|
-
return _optionalChain([mask, 'optionalAccess',
|
|
11141
|
+
return _optionalChain([mask, 'optionalAccess', _473 => _473.bounds]) ? mask : null;
|
|
10984
11142
|
}
|
|
10985
11143
|
function sameSelection(a, b) {
|
|
10986
11144
|
if (a.width !== b.width || a.height !== b.height) return false;
|
|
@@ -11190,7 +11348,7 @@ function loadImageEditorDocument(input) {
|
|
|
11190
11348
|
}
|
|
11191
11349
|
const state = { version: 1, ...result.value };
|
|
11192
11350
|
if (isV2) {
|
|
11193
|
-
if (_optionalChain([state, 'access',
|
|
11351
|
+
if (_optionalChain([state, 'access', _474 => _474.adjustments, 'access', _475 => _475.layers, 'optionalAccess', _476 => _476.length])) state.version = 2;
|
|
11194
11352
|
result.report.version = 2;
|
|
11195
11353
|
}
|
|
11196
11354
|
if (state.selection === void 0) delete state.selection;
|
|
@@ -11398,7 +11556,7 @@ function findAdjustmentControl(id) {
|
|
|
11398
11556
|
}
|
|
11399
11557
|
function findLayerControl(kind, id) {
|
|
11400
11558
|
if (id === "opacity") return ADJUSTMENT_LAYER_OPACITY_CONTROL;
|
|
11401
|
-
return _optionalChain([ADJUSTMENT_LAYER_CONTROLS, 'access',
|
|
11559
|
+
return _optionalChain([ADJUSTMENT_LAYER_CONTROLS, 'access', _477 => _477[kind], 'optionalAccess', _478 => _478.find, 'call', _479 => _479((c) => c.id === id)]);
|
|
11402
11560
|
}
|
|
11403
11561
|
function clampControlValue(spec, v) {
|
|
11404
11562
|
if (typeof v !== "number" || !Number.isFinite(v)) return spec.default;
|
|
@@ -11805,7 +11963,9 @@ var REFINE_OUTPUTS = [
|
|
|
11805
11963
|
{ id: "selection", label: "Selection" },
|
|
11806
11964
|
{ id: "layer-mask", label: "Layer Mask" },
|
|
11807
11965
|
{ id: "new-layer", label: "New Layer" },
|
|
11808
|
-
{ id: "new-layer-with-mask", label: "New Layer with Layer Mask" }
|
|
11966
|
+
{ id: "new-layer-with-mask", label: "New Layer with Layer Mask" },
|
|
11967
|
+
{ id: "new-document", label: "New Document", needsDocuments: true },
|
|
11968
|
+
{ id: "new-document-with-mask", label: "New Document with Layer Mask", needsDocuments: true }
|
|
11809
11969
|
];
|
|
11810
11970
|
function describeSelection(mask) {
|
|
11811
11971
|
if (!mask || !mask.bounds) return "No selection";
|
|
@@ -11841,6 +12001,13 @@ var rectProperties = {
|
|
|
11841
12001
|
width: { type: "number", exclusiveMinimum: 0, description: "Width in natural image pixels." },
|
|
11842
12002
|
height: { type: "number", exclusiveMinimum: 0, description: "Height in natural image pixels." }
|
|
11843
12003
|
};
|
|
12004
|
+
var rectSchemaStrict = {
|
|
12005
|
+
type: "object",
|
|
12006
|
+
properties: rectProperties,
|
|
12007
|
+
required: ["x", "y", "width", "height"],
|
|
12008
|
+
additionalProperties: false,
|
|
12009
|
+
description: "A rectangle in natural image pixels."
|
|
12010
|
+
};
|
|
11844
12011
|
function shapeOptions(args) {
|
|
11845
12012
|
return { mode: _chunkQYLWG22Ncjs.parseSelectionMode.call(void 0, args.mode), feather: num2(args.feather, 0), antiAlias: args.antiAlias !== false };
|
|
11846
12013
|
}
|
|
@@ -11862,7 +12029,7 @@ function summary(controller) {
|
|
|
11862
12029
|
const area = _chunkQYLWG22Ncjs.selectionArea.call(void 0, sel);
|
|
11863
12030
|
return {
|
|
11864
12031
|
empty: !sel,
|
|
11865
|
-
bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
12032
|
+
bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _480 => _480.bounds]), () => ( null)),
|
|
11866
12033
|
/** Σ coverage in pixels. */
|
|
11867
12034
|
area: Math.round(area),
|
|
11868
12035
|
percent: Math.round(area / Math.max(1, width * height) * 1e4) / 100,
|
|
@@ -11938,7 +12105,7 @@ function createImageSelectionTools(controller) {
|
|
|
11938
12105
|
break;
|
|
11939
12106
|
}
|
|
11940
12107
|
case "polygon": {
|
|
11941
|
-
const list = Array.isArray(points) ? points.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess',
|
|
12108
|
+
const list = Array.isArray(points) ? points.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess', _481 => _481.x]), NaN), y: num2(_optionalChain([p, 'optionalAccess', _482 => _482.y]), NaN) })) : [];
|
|
11942
12109
|
if (list.length < 3 || !list.every((p) => Number.isFinite(p.x) && Number.isFinite(p.y))) {
|
|
11943
12110
|
throw new Error("polygon needs points: at least 3 { x, y } vertices.");
|
|
11944
12111
|
}
|
|
@@ -12027,11 +12194,11 @@ function createImageSelectionTools(controller) {
|
|
|
12027
12194
|
shiftEdge: { type: "number", minimum: -100, maximum: 100, description: "Move the edge out (+) or in (-), in percent." },
|
|
12028
12195
|
output: {
|
|
12029
12196
|
type: "string",
|
|
12030
|
-
enum: ["selection", "layer-mask", "new-layer", "new-layer-with-mask"],
|
|
12031
|
-
description: "Where the result goes (default selection). layer-mask keeps every pixel and is easiest to revise; new-layer-with-mask too, on a copy."
|
|
12197
|
+
enum: ["selection", "layer-mask", "new-layer", "new-layer-with-mask", "new-document", "new-document-with-mask"],
|
|
12198
|
+
description: "Where the result goes (default selection). layer-mask keeps every pixel and is easiest to revise; new-layer-with-mask too, on a copy. new-document and new-document-with-mask hand a new one-layer document to the host (only when the host can open documents; this one is unchanged) and return its documentId."
|
|
12032
12199
|
},
|
|
12033
12200
|
layerId: { type: "string", description: "The layer for layer outputs (default the active layer; see list_layers). New-layer outputs need a pixel layer." },
|
|
12034
|
-
decontaminate: { type: "number", minimum: 0, maximum: 100, description: "Decontaminate Colors amount 0-100 (default 0), only with
|
|
12201
|
+
decontaminate: { type: "number", minimum: 0, maximum: 100, description: "Decontaminate Colors amount 0-100 (default 0), only with the new-layer and new-document outputs." },
|
|
12035
12202
|
edits: {
|
|
12036
12203
|
type: "array",
|
|
12037
12204
|
description: "Strokes applied before refining, in order.",
|
|
@@ -12066,7 +12233,7 @@ function createImageSelectionTools(controller) {
|
|
|
12066
12233
|
},
|
|
12067
12234
|
annotations: writeAnnotations("Refine the selection edge"),
|
|
12068
12235
|
handler: async (params) => {
|
|
12069
|
-
const edits = Array.isArray(params.edits) ? params.edits.map((e) => e.kind === "object" ? { ...e } : { ...e, points: (_nullishCoalesce(e.points, () => ( []))).map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess',
|
|
12236
|
+
const edits = Array.isArray(params.edits) ? params.edits.map((e) => e.kind === "object" ? { ...e } : { ...e, points: (_nullishCoalesce(e.points, () => ( []))).map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess', _483 => _483.x]), NaN), y: num2(_optionalChain([p, 'optionalAccess', _484 => _484.y]), NaN) })) }) : [];
|
|
12070
12237
|
for (const e of edits) {
|
|
12071
12238
|
if (e.kind === "object") {
|
|
12072
12239
|
if (!e.rect === !e.point) throw new Error("An object edit takes rect (a box around the object) or point (on it).");
|
|
@@ -12230,7 +12397,7 @@ function createImageSelectionTools(controller) {
|
|
|
12230
12397
|
},
|
|
12231
12398
|
annotations: writeAnnotations("Select a polygon (lasso)", true),
|
|
12232
12399
|
handler: async (args) => {
|
|
12233
|
-
const list = Array.isArray(args.points) ? args.points.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess',
|
|
12400
|
+
const list = Array.isArray(args.points) ? args.points.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess', _485 => _485.x]), NaN), y: num2(_optionalChain([p, 'optionalAccess', _486 => _486.y]), NaN) })) : [];
|
|
12234
12401
|
if (list.length < 3 || !list.every((p) => Number.isFinite(p.x) && Number.isFinite(p.y))) {
|
|
12235
12402
|
throw new Error("points needs at least 3 { x, y } vertices in natural image pixels.");
|
|
12236
12403
|
}
|
|
@@ -12267,7 +12434,7 @@ function createImageSelectionTools(controller) {
|
|
|
12267
12434
|
},
|
|
12268
12435
|
annotations: writeAnnotations("Quick Selection"),
|
|
12269
12436
|
handler: async (args, context) => {
|
|
12270
|
-
const strokes = Array.isArray(args.strokes) ? args.strokes.map((s) => Array.isArray(s) ? s.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess',
|
|
12437
|
+
const strokes = Array.isArray(args.strokes) ? args.strokes.map((s) => Array.isArray(s) ? s.map((p) => ({ x: num2(_optionalChain([p, 'optionalAccess', _487 => _487.x]), NaN), y: num2(_optionalChain([p, 'optionalAccess', _488 => _488.y]), NaN) })) : []) : [];
|
|
12271
12438
|
if (!strokes.length || strokes.some((s) => !s.length || !s.every((p) => Number.isFinite(p.x) && Number.isFinite(p.y)))) {
|
|
12272
12439
|
throw new Error("strokes needs at least one stroke of { x, y } points in natural image pixels.");
|
|
12273
12440
|
}
|
|
@@ -12276,7 +12443,7 @@ function createImageSelectionTools(controller) {
|
|
|
12276
12443
|
mode: _chunkQYLWG22Ncjs.parseSelectionMode.call(void 0, args.mode),
|
|
12277
12444
|
sampleAllLayers: args.sampleAllLayers,
|
|
12278
12445
|
enhanceEdge: args.enhanceEdge,
|
|
12279
|
-
signal: _optionalChain([context, 'optionalAccess',
|
|
12446
|
+
signal: _optionalChain([context, 'optionalAccess', _489 => _489.signal])
|
|
12280
12447
|
});
|
|
12281
12448
|
return summary(controller);
|
|
12282
12449
|
}
|
|
@@ -12314,7 +12481,7 @@ function createImageSelectionTools(controller) {
|
|
|
12314
12481
|
sampleAllLayers: args.sampleAllLayers,
|
|
12315
12482
|
enhanceEdge: args.enhanceEdge,
|
|
12316
12483
|
useModel: args.useModel,
|
|
12317
|
-
signal: _optionalChain([context, 'optionalAccess',
|
|
12484
|
+
signal: _optionalChain([context, 'optionalAccess', _490 => _490.signal])
|
|
12318
12485
|
};
|
|
12319
12486
|
const { method } = rect ? await controller.selectObject({ rect: { x: num2(rect.x, NaN), y: num2(rect.y, NaN), width: num2(rect.width, NaN), height: num2(rect.height, NaN) } }, options) : await controller.selectObject({ point: { x: num2(point.x, NaN), y: num2(point.y, NaN) } }, options);
|
|
12320
12487
|
return { ...summary(controller), method };
|
|
@@ -12343,7 +12510,7 @@ function createImageSelectionTools(controller) {
|
|
|
12343
12510
|
softness: args.softness === void 0 ? void 0 : num2(args.softness, 4),
|
|
12344
12511
|
mode: _chunkQYLWG22Ncjs.parseSelectionMode.call(void 0, args.mode),
|
|
12345
12512
|
sampleAllLayers: args.sampleAllLayers,
|
|
12346
|
-
signal: _optionalChain([context, 'optionalAccess',
|
|
12513
|
+
signal: _optionalChain([context, 'optionalAccess', _491 => _491.signal])
|
|
12347
12514
|
});
|
|
12348
12515
|
return { ...summary(controller), noiseLevel };
|
|
12349
12516
|
}
|
|
@@ -12371,7 +12538,7 @@ function createImageSelectionTools(controller) {
|
|
|
12371
12538
|
mode: _chunkQYLWG22Ncjs.parseSelectionMode.call(void 0, args.mode),
|
|
12372
12539
|
sampleAllLayers: args.sampleAllLayers,
|
|
12373
12540
|
useModel: args.useModel,
|
|
12374
|
-
signal: _optionalChain([context, 'optionalAccess',
|
|
12541
|
+
signal: _optionalChain([context, 'optionalAccess', _492 => _492.signal])
|
|
12375
12542
|
});
|
|
12376
12543
|
return { ...summary(controller), method, ...note ? { note } : {} };
|
|
12377
12544
|
}
|
|
@@ -12469,7 +12636,7 @@ function createImageSelectionTools(controller) {
|
|
|
12469
12636
|
await controller.selectColorRangePreset(args.preset, { ...common, falloff: num2(args.fuzziness, 20) });
|
|
12470
12637
|
} else {
|
|
12471
12638
|
const samples = args.samples.map((s, i) => {
|
|
12472
|
-
if (typeof _optionalChain([s, 'optionalAccess',
|
|
12639
|
+
if (typeof _optionalChain([s, 'optionalAccess', _493 => _493.color]) !== "string" || !/^#?[0-9a-f]{6}$/i.test(s.color.trim())) throw new Error(`samples[${i}].color must be #rrggbb.`);
|
|
12473
12640
|
const at = typeof s.x === "number" && typeof s.y === "number" ? { x: s.x, y: s.y } : void 0;
|
|
12474
12641
|
return at ? { color: s.color, at } : { color: s.color };
|
|
12475
12642
|
});
|
|
@@ -12694,25 +12861,33 @@ function createImageSelectionTools(controller) {
|
|
|
12694
12861
|
const fillTool = {
|
|
12695
12862
|
name: "content_aware_fill",
|
|
12696
12863
|
title: "Content-Aware Fill",
|
|
12697
|
-
description: "Edit \u203A Content-Aware Fill: removes what is selected by filling it with texture and edges synthesised from around it (on a pixel layer, default the active one). Select the object with a small margin (expand 2\u20134 px) first. output current paints into the layer; new-layer puts the fill on its own layer above it, so it can be masked or removed (recommended). sampleRadius limits where it samples from. Deterministic for a seed. 8-bit documents. One undo step. Returns the layer id and filled bounds.",
|
|
12864
|
+
description: "Edit \u203A Content-Aware Fill: removes what is selected by filling it with texture and edges synthesised from around it (on a pixel layer, default the active one). Select the object with a small margin (expand 2\u20134 px) first. output current paints into the layer; new-layer puts the fill on its own layer above it, so it can be masked or removed (recommended). sampleRadius limits where it samples from; sampleRects (only these areas), samplingChannelId (a saved alpha channel) and excludeRects (never these, e.g. another object that would be copied in) set the sampling area as the Content-Aware Fill workspace does. Deterministic for a seed. 8-bit documents. One undo step. Returns the layer id and filled bounds.",
|
|
12698
12865
|
inputSchema: {
|
|
12699
12866
|
type: "object",
|
|
12700
12867
|
properties: {
|
|
12701
12868
|
output: { type: "string", enum: ["new-layer", "current"], description: "new-layer or current (default current)." },
|
|
12702
12869
|
sampleRadius: { type: "number", minimum: 32, maximum: 4e3, description: "Sample within this many pixels of the selection (default its larger side)." },
|
|
12703
12870
|
seed: { type: "integer", minimum: 0, description: "Random seed; another seed gives another fill to choose from (default 0)." },
|
|
12871
|
+
sampleRects: { type: "array", minItems: 1, items: rectSchemaStrict, description: "Sample only from these rectangles (natural image pixels), instead of the ring around the selection." },
|
|
12872
|
+
excludeRects: { type: "array", minItems: 1, items: rectSchemaStrict, description: "Never sample from these rectangles (natural image pixels)." },
|
|
12873
|
+
samplingChannelId: { type: "string", description: "Sample only where this alpha channel is selected (see list_channels)." },
|
|
12704
12874
|
layerId: layerIdSchema
|
|
12705
12875
|
},
|
|
12706
12876
|
additionalProperties: false
|
|
12707
12877
|
},
|
|
12708
12878
|
annotations: writeAnnotations("Content-Aware Fill"),
|
|
12709
|
-
handler: (args) => {
|
|
12879
|
+
handler: async (args, context) => {
|
|
12710
12880
|
if (!controller.getSelection()) throw new Error("Nothing is selected; select what to remove first.");
|
|
12711
|
-
|
|
12881
|
+
const rects = (v) => Array.isArray(v) ? v.map((r) => ({ x: num2(_optionalChain([r, 'optionalAccess', _494 => _494.x]), NaN), y: num2(_optionalChain([r, 'optionalAccess', _495 => _495.y]), NaN), width: num2(_optionalChain([r, 'optionalAccess', _496 => _496.width]), NaN), height: num2(_optionalChain([r, 'optionalAccess', _497 => _497.height]), NaN) })) : void 0;
|
|
12882
|
+
return controller.contentAwareFillAsync({
|
|
12712
12883
|
output: args.output,
|
|
12713
12884
|
sampleRadius: args.sampleRadius,
|
|
12714
12885
|
seed: args.seed,
|
|
12715
|
-
layerId: requireLayerId(args.layerId)
|
|
12886
|
+
layerId: requireLayerId(args.layerId),
|
|
12887
|
+
sampleRects: rects(args.sampleRects),
|
|
12888
|
+
excludeRects: rects(args.excludeRects),
|
|
12889
|
+
samplingChannelId: typeof args.samplingChannelId === "string" ? args.samplingChannelId : void 0,
|
|
12890
|
+
signal: _optionalChain([context, 'optionalAccess', _498 => _498.signal])
|
|
12716
12891
|
});
|
|
12717
12892
|
}
|
|
12718
12893
|
};
|
|
@@ -12990,13 +13165,13 @@ function createImageSubjectSelectionTool(controller) {
|
|
|
12990
13165
|
handler: async ({ target, maxSegments, mode, feather, enhanceEdge }, context) => {
|
|
12991
13166
|
if (target !== void 0 && typeof target !== "string") throw new Error("target must be a description in words.");
|
|
12992
13167
|
if (controller.segmentationProvider && !String(_nullishCoalesce(target, () => ( ""))).trim()) throw new Error("target must describe what to select (a model is set, and it selects by description).");
|
|
12993
|
-
const perform = _optionalChain([context, 'optionalAccess',
|
|
13168
|
+
const perform = _optionalChain([context, 'optionalAccess', _499 => _499.perform]);
|
|
12994
13169
|
const { segments, method, note } = await controller.selectSubject(String(_nullishCoalesce(target, () => ( ""))), {
|
|
12995
13170
|
mode: _chunkQYLWG22Ncjs.parseSelectionMode.call(void 0, mode),
|
|
12996
13171
|
feather: num2(feather, 0),
|
|
12997
13172
|
maxSegments: typeof maxSegments === "number" ? Math.max(1, Math.round(maxSegments)) : void 0,
|
|
12998
13173
|
enhanceEdge: enhanceEdge === true,
|
|
12999
|
-
signal: _optionalChain([context, 'optionalAccess',
|
|
13174
|
+
signal: _optionalChain([context, 'optionalAccess', _500 => _500.signal]),
|
|
13000
13175
|
// Under playback the cursor traces what the model found, as a lasso, before it is selected.
|
|
13001
13176
|
beforeApply: perform ? (outlines) => perform(planOutlineTrace(outlines)) : void 0
|
|
13002
13177
|
});
|
|
@@ -13074,7 +13249,7 @@ async function renderImageRegion(controller, request) {
|
|
|
13074
13249
|
const maskView = maskViewCanvas(controller, document);
|
|
13075
13250
|
if (maskView) context.drawImage(maskView, rect.x, rect.y, rect.width, rect.height, 0, 0, out.width, out.height);
|
|
13076
13251
|
const selection = state.selection;
|
|
13077
|
-
if (_optionalChain([selection, 'optionalAccess',
|
|
13252
|
+
if (_optionalChain([selection, 'optionalAccess', _501 => _501.bounds]) && selection.width === state.imageDimensions.width && selection.height === state.imageDimensions.height) {
|
|
13078
13253
|
const shade = selectionShade(selection, document);
|
|
13079
13254
|
if (shade) context.drawImage(shade, rect.x, rect.y, rect.width, rect.height, 0, 0, out.width, out.height);
|
|
13080
13255
|
}
|
|
@@ -13099,7 +13274,7 @@ function createImageCaptureSurface(controller) {
|
|
|
13099
13274
|
return {
|
|
13100
13275
|
units: "image pixels",
|
|
13101
13276
|
content: whole,
|
|
13102
|
-
selection: () => ({ rect: _nullishCoalesce(_optionalChain([controller, 'access',
|
|
13277
|
+
selection: () => ({ rect: _nullishCoalesce(_optionalChain([controller, 'access', _502 => _502.getState, 'call', _503 => _503(), 'access', _504 => _504.selection, 'optionalAccess', _505 => _505.bounds]), () => ( null)) }),
|
|
13103
13278
|
overlays: "a shade over unselected pixels, the crop box outline and a layer mask view (set_mask_view)",
|
|
13104
13279
|
maxScale: 8,
|
|
13105
13280
|
render: (request) => renderImageRegion(controller, request)
|
|
@@ -13433,7 +13608,7 @@ function describeLayer(layer, activeId, boundsOf) {
|
|
|
13433
13608
|
out.bounds = boundsOf(layer);
|
|
13434
13609
|
out.fillOpacity = round3(_nullishCoalesce(layer.fillOpacity, () => ( 1)));
|
|
13435
13610
|
out.shape = {
|
|
13436
|
-
components: layer.components.map((c) => ({ op: c.op, kind: _nullishCoalesce(_optionalChain([c, 'access',
|
|
13611
|
+
components: layer.components.map((c) => ({ op: c.op, kind: _nullishCoalesce(_optionalChain([c, 'access', _506 => _506.live, 'optionalAccess', _507 => _507.kind]), () => ( "path")) })),
|
|
13437
13612
|
fill: layer.fill ? layer.fill.type : null,
|
|
13438
13613
|
stroke: layer.stroke ? { width: layer.stroke.width, paint: layer.stroke.paint.type } : null
|
|
13439
13614
|
};
|
|
@@ -13456,8 +13631,8 @@ function describeLayer(layer, activeId, boundsOf) {
|
|
|
13456
13631
|
out.bounds = boundsOf(layer);
|
|
13457
13632
|
out.fillOpacity = round3(_nullishCoalesce(layer.fillOpacity, () => ( 1)));
|
|
13458
13633
|
out.contents = { id: layer.contents.id, name: layer.contents.name, kind: layer.contents.kind, width: layer.contents.width, height: layer.contents.height };
|
|
13459
|
-
out.smartFilters = (_nullishCoalesce(_optionalChain([layer, 'access',
|
|
13460
|
-
out.filterMask = maskSummary(_optionalChain([layer, 'access',
|
|
13634
|
+
out.smartFilters = (_nullishCoalesce(_optionalChain([layer, 'access', _508 => _508.smartFilters, 'optionalAccess', _509 => _509.filters]), () => ( []))).map((f) => ({ id: f.id, kind: f.kind, enabled: f.enabled }));
|
|
13635
|
+
out.filterMask = maskSummary(_optionalChain([layer, 'access', _510 => _510.smartFilters, 'optionalAccess', _511 => _511.mask]));
|
|
13461
13636
|
break;
|
|
13462
13637
|
}
|
|
13463
13638
|
return out;
|
|
@@ -13485,7 +13660,7 @@ function createImageLayerTools(controller) {
|
|
|
13485
13660
|
if (!loc) return null;
|
|
13486
13661
|
return {
|
|
13487
13662
|
...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)),
|
|
13488
|
-
parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
13663
|
+
parentId: _nullishCoalesce(_optionalChain([loc, 'access', _512 => _512.parent, 'optionalAccess', _513 => _513.id]), () => ( null)),
|
|
13489
13664
|
index: loc.index
|
|
13490
13665
|
};
|
|
13491
13666
|
};
|
|
@@ -13808,7 +13983,7 @@ function createImageLayerTools(controller) {
|
|
|
13808
13983
|
if (view !== "gray" && view !== "overlay" && view !== "off") throw new Error(`Unknown view "${String(view)}". Use gray, overlay or off.`);
|
|
13809
13984
|
const id = view === "off" || layerId === void 0 ? void 0 : exists(layerId);
|
|
13810
13985
|
const shown = controller.setMaskView(view, id);
|
|
13811
|
-
return { view: _nullishCoalesce(_optionalChain([shown, 'optionalAccess',
|
|
13986
|
+
return { view: _nullishCoalesce(_optionalChain([shown, 'optionalAccess', _514 => _514.mode]), () => ( "off")), layerId: _nullishCoalesce(_optionalChain([shown, 'optionalAccess', _515 => _515.layerId]), () => ( null)) };
|
|
13812
13987
|
}
|
|
13813
13988
|
};
|
|
13814
13989
|
const maskProps = {
|
|
@@ -14302,26 +14477,26 @@ function snapTo45(from, point) {
|
|
|
14302
14477
|
return { x: from.x + Math.cos(a) * len, y: from.y + Math.sin(a) * len };
|
|
14303
14478
|
}
|
|
14304
14479
|
var SelectionGesture = (_class13 = class {
|
|
14305
|
-
constructor(controller, getOptions) {;_class13.prototype.
|
|
14480
|
+
constructor(controller, getOptions) {;_class13.prototype.__init104.call(this);_class13.prototype.__init105.call(this);_class13.prototype.__init106.call(this);_class13.prototype.__init107.call(this);_class13.prototype.__init108.call(this);_class13.prototype.__init109.call(this);_class13.prototype.__init110.call(this);_class13.prototype.__init111.call(this);_class13.prototype.__init112.call(this);_class13.prototype.__init113.call(this);_class13.prototype.__init114.call(this);
|
|
14306
14481
|
this.controller = controller;
|
|
14307
14482
|
this.getOptions = getOptions;
|
|
14308
14483
|
}
|
|
14309
14484
|
|
|
14310
14485
|
|
|
14311
|
-
|
|
14312
|
-
|
|
14313
|
-
|
|
14314
|
-
|
|
14486
|
+
__init104() {this.start = null}
|
|
14487
|
+
__init105() {this.points = []}
|
|
14488
|
+
__init106() {this.current = null}
|
|
14489
|
+
__init107() {this.modifiers = {}}
|
|
14315
14490
|
/** Polygonal lasso corners while one is being drawn. */
|
|
14316
|
-
|
|
14317
|
-
|
|
14318
|
-
|
|
14319
|
-
|
|
14491
|
+
__init108() {this.polygon = null}
|
|
14492
|
+
__init109() {this.pressedAt = null}
|
|
14493
|
+
__init110() {this.freehand = false}
|
|
14494
|
+
__init111() {this.magnetic = null}
|
|
14320
14495
|
/** A click this close to the first corner (natural pixels) closes a polygonal lasso. */
|
|
14321
|
-
|
|
14496
|
+
__init112() {this.closeRadius = 8}
|
|
14322
14497
|
/** The last error (e.g. pixels unavailable for the wand), for the UI to show. */
|
|
14323
|
-
|
|
14324
|
-
|
|
14498
|
+
__init113() {this.error = null}
|
|
14499
|
+
__init114() {this.pending = Promise.resolve()}
|
|
14325
14500
|
get active() {
|
|
14326
14501
|
return this.start !== null || this.polygon !== null || this.magnetic !== null;
|
|
14327
14502
|
}
|
|
@@ -14341,14 +14516,14 @@ var SelectionGesture = (_class13 = class {
|
|
|
14341
14516
|
if (!this.start || !this.current) return null;
|
|
14342
14517
|
const { tool } = this.getOptions();
|
|
14343
14518
|
if (tool === "lasso" || tool === "quick") return this.points.length > 1 ? this.points.slice() : null;
|
|
14344
|
-
const rect =
|
|
14519
|
+
const rect = _chunkL52VMQZScjs.normalizeRect.call(void 0, {
|
|
14345
14520
|
x: this.start.x,
|
|
14346
14521
|
y: this.start.y,
|
|
14347
14522
|
width: this.current.x - this.start.x,
|
|
14348
14523
|
height: this.current.y - this.start.y
|
|
14349
14524
|
});
|
|
14350
14525
|
if (rect.width < 1 && rect.height < 1) return null;
|
|
14351
|
-
if (tool === "ellipse") return
|
|
14526
|
+
if (tool === "ellipse") return _chunkL52VMQZScjs.ellipsePoints.call(void 0, rect);
|
|
14352
14527
|
return [
|
|
14353
14528
|
{ x: rect.x, y: rect.y },
|
|
14354
14529
|
{ x: rect.x + rect.width, y: rect.y },
|
|
@@ -14496,7 +14671,7 @@ var SelectionGesture = (_class13 = class {
|
|
|
14496
14671
|
const options = this.getOptions();
|
|
14497
14672
|
const mode = selectionModeFromModifiers(_nullishCoalesce(modifiers, () => ( this.modifiers)), options.mode);
|
|
14498
14673
|
if (options.tool === "object") {
|
|
14499
|
-
const rect2 =
|
|
14674
|
+
const rect2 = _chunkL52VMQZScjs.normalizeRect.call(void 0, { x: this.start.x, y: this.start.y, width: this.current.x - this.start.x, height: this.current.y - this.start.y });
|
|
14500
14675
|
this.start = null;
|
|
14501
14676
|
this.current = null;
|
|
14502
14677
|
this.points = [];
|
|
@@ -14529,7 +14704,7 @@ var SelectionGesture = (_class13 = class {
|
|
|
14529
14704
|
return false;
|
|
14530
14705
|
}
|
|
14531
14706
|
const path = this.draftPath;
|
|
14532
|
-
const rect =
|
|
14707
|
+
const rect = _chunkL52VMQZScjs.normalizeRect.call(void 0, {
|
|
14533
14708
|
x: this.start.x,
|
|
14534
14709
|
y: this.start.y,
|
|
14535
14710
|
width: this.current.x - this.start.x,
|
|
@@ -14670,7 +14845,7 @@ function handleSelectionShortcut(controller, e, onError) {
|
|
|
14670
14845
|
try {
|
|
14671
14846
|
fn();
|
|
14672
14847
|
} catch (err) {
|
|
14673
|
-
_optionalChain([onError, 'optionalCall',
|
|
14848
|
+
_optionalChain([onError, 'optionalCall', _516 => _516(err instanceof Error ? err.message : String(err))]);
|
|
14674
14849
|
}
|
|
14675
14850
|
return true;
|
|
14676
14851
|
};
|
|
@@ -14685,9 +14860,9 @@ function handleMaskViewKey(controller, e) {
|
|
|
14685
14860
|
if (e.ctrlKey || e.metaKey || e.altKey || e.key !== "\\") return false;
|
|
14686
14861
|
const id = controller.getState().activeLayerId;
|
|
14687
14862
|
const layer = id ? controller.getLayer(id) : null;
|
|
14688
|
-
if (!_optionalChain([layer, 'optionalAccess',
|
|
14863
|
+
if (!_optionalChain([layer, 'optionalAccess', _517 => _517.mask]) || layer.mask.source) return false;
|
|
14689
14864
|
const view = controller.getMaskView();
|
|
14690
|
-
controller.setMaskView(_optionalChain([view, 'optionalAccess',
|
|
14865
|
+
controller.setMaskView(_optionalChain([view, 'optionalAccess', _518 => _518.layerId]) === layer.id && view.mode === "overlay" ? "off" : "overlay", layer.id);
|
|
14691
14866
|
return true;
|
|
14692
14867
|
}
|
|
14693
14868
|
function handleQuickMaskKey(controller, e) {
|
|
@@ -14882,14 +15057,14 @@ function handlePaintShortcut(controller, e) {
|
|
|
14882
15057
|
return false;
|
|
14883
15058
|
}
|
|
14884
15059
|
var PaintGesture = (_class14 = class {
|
|
14885
|
-
constructor(controller) {;_class14.prototype.
|
|
15060
|
+
constructor(controller) {;_class14.prototype.__init115.call(this);_class14.prototype.__init116.call(this);_class14.prototype.__init117.call(this);
|
|
14886
15061
|
this.controller = controller;
|
|
14887
15062
|
}
|
|
14888
15063
|
|
|
14889
|
-
|
|
14890
|
-
|
|
15064
|
+
__init115() {this.stroke = null}
|
|
15065
|
+
__init116() {this.move = null}
|
|
14891
15066
|
/** The last refusal (e.g. "layer is locked"), for the editor to show. */
|
|
14892
|
-
|
|
15067
|
+
__init117() {this.error = null}
|
|
14893
15068
|
get active() {
|
|
14894
15069
|
return Boolean(this.stroke || this.move);
|
|
14895
15070
|
}
|
|
@@ -14901,7 +15076,7 @@ var PaintGesture = (_class14 = class {
|
|
|
14901
15076
|
const layer = this.controller.getActiveLayer();
|
|
14902
15077
|
if (!layer) throw new Error("Select a layer to move in the Layers panel.");
|
|
14903
15078
|
if (layer.type !== "pixel" && layer.type !== "shape" && layer.type !== "smart") throw new Error(`Only pixel, shape and smart object layers move; "${layer.name}" is a ${layer.type} layer.`);
|
|
14904
|
-
if (_optionalChain([layer, 'access',
|
|
15079
|
+
if (_optionalChain([layer, 'access', _519 => _519.locks, 'optionalAccess', _520 => _520.all]) || _optionalChain([layer, 'access', _521 => _521.locks, 'optionalAccess', _522 => _522.position])) throw new Error(`Layer "${layer.name}" has its position locked.`);
|
|
14905
15080
|
const origin = layer.type === "pixel" ? { ...layer.offset } : layer.type === "smart" ? { ...layer.placement.corners[0] } : (() => {
|
|
14906
15081
|
const b = _chunkQE7D7TZRcjs.shapeGeometryBounds.call(void 0, layer);
|
|
14907
15082
|
return b ? { x: b.x, y: b.y } : { x: 0, y: 0 };
|
|
@@ -14958,7 +15133,7 @@ var PaintGesture = (_class14 = class {
|
|
|
14958
15133
|
this.move = null;
|
|
14959
15134
|
}
|
|
14960
15135
|
cancel() {
|
|
14961
|
-
_optionalChain([this, 'access',
|
|
15136
|
+
_optionalChain([this, 'access', _523 => _523.stroke, 'optionalAccess', _524 => _524.cancel, 'call', _525 => _525()]);
|
|
14962
15137
|
this.stroke = null;
|
|
14963
15138
|
this.move = null;
|
|
14964
15139
|
}
|
|
@@ -15368,7 +15543,7 @@ var TARGET2 = {
|
|
|
15368
15543
|
};
|
|
15369
15544
|
var SAMPLE = {
|
|
15370
15545
|
type: "string",
|
|
15371
|
-
enum: [...
|
|
15546
|
+
enum: [..._chunkYF3YZZ6Gcjs.RETOUCH_SAMPLES],
|
|
15372
15547
|
description: "What is sampled: current (default: the target layer), current-below (the composite of this layer and everything under it), or all (the composite of every layer). Sample current-below or all to retouch onto an empty layer above the image."
|
|
15373
15548
|
};
|
|
15374
15549
|
function readTarget2(args) {
|
|
@@ -15447,7 +15622,7 @@ function createImageRetouchTools(controller) {
|
|
|
15447
15622
|
type: "object",
|
|
15448
15623
|
properties: {
|
|
15449
15624
|
points: POINTS,
|
|
15450
|
-
type: { type: "string", enum: [...
|
|
15625
|
+
type: { type: "string", enum: [..._chunkYF3YZZ6Gcjs.SPOT_HEAL_TYPES], description: "proximity-match (default the current option), content-aware or smooth." },
|
|
15451
15626
|
sample: SAMPLE,
|
|
15452
15627
|
brush: BRUSH2,
|
|
15453
15628
|
...TARGET2
|
|
@@ -15480,7 +15655,7 @@ function createImageRetouchTools(controller) {
|
|
|
15480
15655
|
type: "object",
|
|
15481
15656
|
properties: {
|
|
15482
15657
|
points: POINTS,
|
|
15483
|
-
range: { type: "string", enum: [...
|
|
15658
|
+
range: { type: "string", enum: [..._chunkYF3YZZ6Gcjs.TONE_RANGES], description: `Which tones to ${verb} most: shadows, midtones (default the current option, midtones) or highlights.` },
|
|
15484
15659
|
exposure: { type: "number", minimum: 0, maximum: 1, description: "Strength 0..1 (default the current option, 0.5). Overlapping dabs in one stroke never go past it; another stroke builds on it." },
|
|
15485
15660
|
protectTones: { type: "boolean", description: "Change luma only, keeping hue and saturation (default true)." },
|
|
15486
15661
|
brush: BRUSH2,
|
|
@@ -15589,8 +15764,8 @@ function createImageRetouchTools(controller) {
|
|
|
15589
15764
|
properties: {
|
|
15590
15765
|
aligned: { type: "boolean", description: "Clone / heal: keep the offset from stroke to stroke (default true)." },
|
|
15591
15766
|
sample: SAMPLE,
|
|
15592
|
-
spotType: { type: "string", enum: [...
|
|
15593
|
-
range: { type: "string", enum: [...
|
|
15767
|
+
spotType: { type: "string", enum: [..._chunkYF3YZZ6Gcjs.SPOT_HEAL_TYPES], description: "Spot heal: proximity-match (default), content-aware or smooth." },
|
|
15768
|
+
range: { type: "string", enum: [..._chunkYF3YZZ6Gcjs.TONE_RANGES], description: "Dodge / burn: shadows, midtones (default) or highlights." },
|
|
15594
15769
|
exposure: { type: "number", minimum: 0, maximum: 1, description: "Dodge / burn strength 0..1 (default 0.5)." },
|
|
15595
15770
|
protectTones: { type: "boolean", description: "Dodge / burn: keep hue and saturation (default true)." },
|
|
15596
15771
|
spongeMode: { type: "string", enum: ["desaturate", "saturate"], description: "Sponge: desaturate (default) or saturate." },
|
|
@@ -16039,7 +16214,7 @@ function createImageSmartObjectTools(controller) {
|
|
|
16039
16214
|
const layerSummary = (id) => {
|
|
16040
16215
|
const s = controller.getState();
|
|
16041
16216
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, s.layers, id);
|
|
16042
|
-
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
16217
|
+
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access', _526 => _526.parent, 'optionalAccess', _527 => _527.id]), () => ( null)), index: loc.index } : null;
|
|
16043
16218
|
};
|
|
16044
16219
|
const getSmart = {
|
|
16045
16220
|
name: "get_smart_object",
|
|
@@ -16596,7 +16771,7 @@ function createImageShapeTools(controller) {
|
|
|
16596
16771
|
const layerSummary = (id) => {
|
|
16597
16772
|
const s = controller.getState();
|
|
16598
16773
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, s.layers, id);
|
|
16599
|
-
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
16774
|
+
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access', _528 => _528.parent, 'optionalAccess', _529 => _529.id]), () => ( null)), index: loc.index } : null;
|
|
16600
16775
|
};
|
|
16601
16776
|
const get = {
|
|
16602
16777
|
name: "get_shape_layer",
|
|
@@ -16813,7 +16988,7 @@ function createImageShapeTools(controller) {
|
|
|
16813
16988
|
const mode = args.mode;
|
|
16814
16989
|
controller.pathToSelection(pathSpec(args), { feather: args.feather, antiAlias: args.antiAlias, mode });
|
|
16815
16990
|
const sel = controller.getSelection();
|
|
16816
|
-
return { empty: !sel, bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
16991
|
+
return { empty: !sel, bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _530 => _530.bounds]), () => ( null)), area: Math.round(sel ? _chunkQYLWG22Ncjs.selectionArea.call(void 0, sel) : 0) };
|
|
16817
16992
|
}
|
|
16818
16993
|
};
|
|
16819
16994
|
const getVectorMask = {
|
|
@@ -16844,7 +17019,7 @@ function createImageShapeTools(controller) {
|
|
|
16844
17019
|
handler: (args) => {
|
|
16845
17020
|
const id = layerArg(args.layerId);
|
|
16846
17021
|
const spec = pathSpec(args);
|
|
16847
|
-
const hasPath = _optionalChain([spec, 'access',
|
|
17022
|
+
const hasPath = _optionalChain([spec, 'access', _531 => _531.components, 'optionalAccess', _532 => _532.length]) || spec.shape !== void 0 || spec.subpaths !== void 0;
|
|
16848
17023
|
const from = _nullishCoalesce(args.from, () => ( (hasPath ? "path" : "reveal-all")));
|
|
16849
17024
|
if (from !== "selection" && TRACE_KEYS.some((k) => args[k] !== void 0)) throw new Error("tolerance, cornerRoundness and minArea apply only to from selection.");
|
|
16850
17025
|
controller.addVectorMask(id, from, spec, traceOptions(args));
|
|
@@ -16964,7 +17139,7 @@ function createImageTypeTools(controller) {
|
|
|
16964
17139
|
const layerSummary = (id) => {
|
|
16965
17140
|
const s = controller.getState();
|
|
16966
17141
|
const loc = _chunkUOGKSVRQcjs.findLayer.call(void 0, s.layers, id);
|
|
16967
|
-
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access',
|
|
17142
|
+
return loc ? { ...describeLayer(loc.layer, s.activeLayerId, (x) => controller.getLayerBounds(x.id)), parentId: _nullishCoalesce(_optionalChain([loc, 'access', _533 => _533.parent, 'optionalAccess', _534 => _534.id]), () => ( null)), index: loc.index } : null;
|
|
16968
17143
|
};
|
|
16969
17144
|
const range = (args) => ({ start: args.start, end: args.end });
|
|
16970
17145
|
const listFonts = {
|
|
@@ -16973,7 +17148,7 @@ function createImageTypeTools(controller) {
|
|
|
16973
17148
|
description: "Returns the font families type layers can use here (generic families such as sans-serif always work). Changes nothing.",
|
|
16974
17149
|
inputSchema: { type: "object", properties: {}, additionalProperties: false },
|
|
16975
17150
|
annotations: { title: "List fonts", ...READ11 },
|
|
16976
|
-
handler: () => ({ families: controller.listFonts(), shaper: _nullishCoalesce(_optionalChain([controller, 'access',
|
|
17151
|
+
handler: () => ({ families: controller.listFonts(), shaper: _nullishCoalesce(_optionalChain([controller, 'access', _535 => _535.getTextShaper, 'call', _536 => _536(), 'optionalAccess', _537 => _537.id]), () => ( null)) })
|
|
16977
17152
|
};
|
|
16978
17153
|
const get = {
|
|
16979
17154
|
name: "get_text_layer",
|
|
@@ -17129,7 +17304,7 @@ function createImageTypeTools(controller) {
|
|
|
17129
17304
|
const init = pick2(args, ["text", "x", "y", "orientation", "box", "style", "paragraph", "rotation", "mode", "feather", "antiAlias"]);
|
|
17130
17305
|
controller.selectTextShape(init);
|
|
17131
17306
|
const sel = controller.getSelection();
|
|
17132
|
-
return { empty: !sel, bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess',
|
|
17307
|
+
return { empty: !sel, bounds: _nullishCoalesce(_optionalChain([sel, 'optionalAccess', _538 => _538.bounds]), () => ( null)), area: Math.round(sel ? _chunkQYLWG22Ncjs.selectionArea.call(void 0, sel) : 0) };
|
|
17133
17308
|
}
|
|
17134
17309
|
};
|
|
17135
17310
|
return [listFonts, get, add2, setText, setStyle, setParagraph, setFrame, setOrientation, toShape, typeMask];
|
|
@@ -17308,7 +17483,7 @@ function createImageEditorToolProvider(controller, options = {}) {
|
|
|
17308
17483
|
for (const ref of [aboveId, parentId]) {
|
|
17309
17484
|
if (ref !== void 0 && !controller.getLayer(ref)) throw new Error(`Unknown layer "${ref}". Call list_layers for ids.`);
|
|
17310
17485
|
}
|
|
17311
|
-
if (parentId !== void 0 && _optionalChain([controller, 'access',
|
|
17486
|
+
if (parentId !== void 0 && _optionalChain([controller, 'access', _539 => _539.getLayer, 'call', _540 => _540(parentId), 'optionalAccess', _541 => _541.type]) !== "group") throw new Error(`Layer "${parentId}" is not a group.`);
|
|
17312
17487
|
const id = controller.addAdjustmentLayer({ kind, params, opacity, blend, name, aboveId, parentId, useSelection: useSelection !== false });
|
|
17313
17488
|
const layer = controller.getAdjustmentLayer(id);
|
|
17314
17489
|
return { layer: JSON.parse(JSON.stringify(layer)), index: controller.getAdjustmentLayers().findIndex((l) => l.id === id), masked: Boolean(layer.mask) };
|
|
@@ -17497,7 +17672,7 @@ var SELECT_AND_MASK_TOOLS = [
|
|
|
17497
17672
|
{ id: "zoom", label: "Zoom", key: "z" }
|
|
17498
17673
|
];
|
|
17499
17674
|
var DEFAULT_SELECT_AND_MASK_SETTINGS = {
|
|
17500
|
-
params: { ...
|
|
17675
|
+
params: { ..._chunkL52VMQZScjs.DEFAULT_REFINE_EDGE_PARAMS },
|
|
17501
17676
|
output: "selection",
|
|
17502
17677
|
decontaminate: 0,
|
|
17503
17678
|
refineMode: "color",
|
|
@@ -17545,32 +17720,32 @@ function scaleParams(p, s) {
|
|
|
17545
17720
|
return { ...p, radius: p.radius * s, feather: p.feather * s };
|
|
17546
17721
|
}
|
|
17547
17722
|
var SelectAndMaskSession = (_class15 = class {
|
|
17548
|
-
constructor(controller) {;_class15.prototype.
|
|
17723
|
+
constructor(controller) {;_class15.prototype.__init118.call(this);_class15.prototype.__init119.call(this);_class15.prototype.__init120.call(this);_class15.prototype.__init121.call(this);_class15.prototype.__init122.call(this);_class15.prototype.__init123.call(this);_class15.prototype.__init124.call(this);_class15.prototype.__init125.call(this);_class15.prototype.__init126.call(this);_class15.prototype.__init127.call(this);_class15.prototype.__init128.call(this);_class15.prototype.__init129.call(this);_class15.prototype.__init130.call(this);
|
|
17549
17724
|
this.controller = controller;
|
|
17550
17725
|
this.base = controller.getSelection();
|
|
17551
17726
|
this.settingsValue = remembered ? { ...remembered, params: { ...remembered.params }, showOriginal: false } : { ...DEFAULT_SELECT_AND_MASK_SETTINGS, params: { ...DEFAULT_SELECT_AND_MASK_SETTINGS.params } };
|
|
17552
17727
|
}
|
|
17553
17728
|
|
|
17554
17729
|
|
|
17555
|
-
|
|
17730
|
+
__init118() {this.editsList = []}
|
|
17556
17731
|
/** The edit being painted, shown in the preview but not yet in `edits`. */
|
|
17557
|
-
|
|
17558
|
-
|
|
17559
|
-
|
|
17560
|
-
|
|
17732
|
+
__init119() {this.live = null}
|
|
17733
|
+
__init120() {this.dragStart = null}
|
|
17734
|
+
__init121() {this.pixels = null}
|
|
17735
|
+
__init122() {this.previewPixels = null}
|
|
17561
17736
|
|
|
17562
|
-
|
|
17563
|
-
|
|
17564
|
-
|
|
17737
|
+
__init123() {this.previewMask = null}
|
|
17738
|
+
__init124() {this.baseMask = null}
|
|
17739
|
+
__init125() {this.listeners = /* @__PURE__ */ new Set()}
|
|
17565
17740
|
/** Why the preview could not be made (no pixels), for the UI. */
|
|
17566
|
-
|
|
17741
|
+
__init126() {this.error = null}
|
|
17567
17742
|
/** A note for the UI, such as object aware refinement applying only on OK. */
|
|
17568
|
-
|
|
17743
|
+
__init127() {this.note = null}
|
|
17569
17744
|
/** Bumped each time the preview changes, so a UI can redraw. */
|
|
17570
|
-
|
|
17745
|
+
__init128() {this.revision = 0}
|
|
17571
17746
|
/** True while the worker computes a preview. */
|
|
17572
|
-
|
|
17573
|
-
|
|
17747
|
+
__init129() {this.computing = false}
|
|
17748
|
+
__init130() {this.dirty = false}
|
|
17574
17749
|
get settings() {
|
|
17575
17750
|
return this.settingsValue;
|
|
17576
17751
|
}
|
|
@@ -17625,7 +17800,7 @@ var SelectAndMaskSession = (_class15 = class {
|
|
|
17625
17800
|
const w = Math.max(1, Math.round(px2.width * s));
|
|
17626
17801
|
const h = Math.max(1, Math.round(px2.height * s));
|
|
17627
17802
|
this.previewPixels = scalePixels(px2, w, h);
|
|
17628
|
-
this.baseMask = _optionalChain([this, 'access',
|
|
17803
|
+
this.baseMask = _optionalChain([this, 'access', _542 => _542.base, 'optionalAccess', _543 => _543.bounds]) ? s === 1 ? this.base : _chunkQYLWG22Ncjs.resizeSelection.call(void 0, this.base, w, h) : null;
|
|
17629
17804
|
}
|
|
17630
17805
|
/**
|
|
17631
17806
|
* Recomputes the preview mask from the base selection, the strokes and the settings: at once on
|
|
@@ -17642,8 +17817,8 @@ var SelectAndMaskSession = (_class15 = class {
|
|
|
17642
17817
|
const { scale } = this.previewSize;
|
|
17643
17818
|
const edits = [...this.editsList, ...this.live ? [this.live] : []].map((e) => scaleEdit(e, scale));
|
|
17644
17819
|
try {
|
|
17645
|
-
const { selection, refineBrush } =
|
|
17646
|
-
this.previewMask = _optionalChain([selection, 'optionalAccess',
|
|
17820
|
+
const { selection, refineBrush } = _chunkL52VMQZScjs.applyRefineEdits.call(void 0, px2, this.baseMask, edits, px2.width, px2.height);
|
|
17821
|
+
this.previewMask = _optionalChain([selection, 'optionalAccess', _544 => _544.bounds]) ? _chunkL52VMQZScjs.refineSelection.call(void 0, px2, selection, scaleParams(this.settingsValue.params, scale), refineBrush) : null;
|
|
17647
17822
|
this.error = null;
|
|
17648
17823
|
} catch (err) {
|
|
17649
17824
|
this.previewMask = null;
|
|
@@ -17664,7 +17839,7 @@ var SelectAndMaskSession = (_class15 = class {
|
|
|
17664
17839
|
const edits = [...this.editsList, ...this.live ? [this.live] : []].map((e) => scaleEdit(e, scale));
|
|
17665
17840
|
try {
|
|
17666
17841
|
const { mask } = await this.controller.runSelectionJob(
|
|
17667
|
-
{ op: "refine-preview", base: this.baseMask ?
|
|
17842
|
+
{ op: "refine-preview", base: this.baseMask ? _chunkL52VMQZScjs.serializeMask.call(void 0, this.baseMask) : null, edits, params: scaleParams(this.settingsValue.params, scale) },
|
|
17668
17843
|
px2
|
|
17669
17844
|
);
|
|
17670
17845
|
this.previewMask = mask.bounds ? mask : null;
|
|
@@ -17877,7 +18052,7 @@ var SelectAndMaskSession = (_class15 = class {
|
|
|
17877
18052
|
remembered = s.remember ? { ...s, params: { ...s.params } } : null;
|
|
17878
18053
|
return this.controller.refineSelectionTo(s.params, s.output, {
|
|
17879
18054
|
edits: [...this.editsList],
|
|
17880
|
-
decontaminate: s.output === "
|
|
18055
|
+
decontaminate: s.output === "selection" || s.output === "layer-mask" ? 0 : s.decontaminate,
|
|
17881
18056
|
refineMode: s.refineMode
|
|
17882
18057
|
});
|
|
17883
18058
|
}
|
|
@@ -18031,7 +18206,7 @@ function maskThumbnailClick(controller, layer, e) {
|
|
|
18031
18206
|
} else if (e.altKey && !layer.mask.source) {
|
|
18032
18207
|
const mode = e.shiftKey ? "overlay" : "gray";
|
|
18033
18208
|
const view = controller.getMaskView();
|
|
18034
|
-
controller.setMaskView(_optionalChain([view, 'optionalAccess',
|
|
18209
|
+
controller.setMaskView(_optionalChain([view, 'optionalAccess', _545 => _545.layerId]) === layer.id && view.mode === mode ? "off" : mode, layer.id);
|
|
18035
18210
|
} else if (e.shiftKey) {
|
|
18036
18211
|
controller.setLayerMaskProps(layer.id, { enabled: layer.mask.enabled === false });
|
|
18037
18212
|
} else {
|
|
@@ -18095,7 +18270,7 @@ function layerHasThumbnail(layer) {
|
|
|
18095
18270
|
return layer.type === "pixel" || layer.type === "shape" || layer.type === "type";
|
|
18096
18271
|
}
|
|
18097
18272
|
function layerWarning(layer) {
|
|
18098
|
-
if (layer.type === "type" && _optionalChain([layer, 'access',
|
|
18273
|
+
if (layer.type === "type" && _optionalChain([layer, 'access', _546 => _546.missingFonts, 'optionalAccess', _547 => _547.length])) {
|
|
18099
18274
|
return `Missing ${layer.missingFonts.length === 1 ? "font" : "fonts"}: ${layer.missingFonts.join(", ")}. ${layer.rendering === "stored" ? "Showing the saved pixels until the text is edited." : "Drawn with a fallback font."}`;
|
|
18100
18275
|
}
|
|
18101
18276
|
return null;
|
|
@@ -18118,16 +18293,16 @@ function layerMenu(controller) {
|
|
|
18118
18293
|
const siblings = loc ? loc.parent ? loc.parent.children : s.layers : [];
|
|
18119
18294
|
const below = loc ? siblings[loc.index - 1] : void 0;
|
|
18120
18295
|
const hasSel = controller.hasSelection;
|
|
18121
|
-
const isPixel = _optionalChain([active, 'optionalAccess',
|
|
18122
|
-
const hasOwnPixels = _optionalChain([active, 'optionalAccess',
|
|
18296
|
+
const isPixel = _optionalChain([active, 'optionalAccess', _548 => _548.type]) === "pixel";
|
|
18297
|
+
const hasOwnPixels = _optionalChain([active, 'optionalAccess', _549 => _549.type]) === "pixel" || _optionalChain([active, 'optionalAccess', _550 => _550.type]) === "shape" || _optionalChain([active, 'optionalAccess', _551 => _551.type]) === "type" || _optionalChain([active, 'optionalAccess', _552 => _552.type]) === "smart";
|
|
18123
18298
|
return [
|
|
18124
18299
|
{ action: "new-layer", label: "New Layer", enabled: true },
|
|
18125
18300
|
{ action: "new-group", label: "New Group", enabled: true },
|
|
18126
18301
|
{ action: "duplicate", label: "Duplicate Layer", enabled: Boolean(active) },
|
|
18127
18302
|
{ action: "delete", label: "Delete Layer", enabled: Boolean(active) },
|
|
18128
18303
|
{ action: "group-selected", label: "Group Layer", enabled: Boolean(active) },
|
|
18129
|
-
{ action: "ungroup", label: "Ungroup", enabled: _optionalChain([active, 'optionalAccess',
|
|
18130
|
-
{ action: "merge-down", label: "Merge Down", enabled: Boolean(_optionalChain([active, 'optionalAccess',
|
|
18304
|
+
{ action: "ungroup", label: "Ungroup", enabled: _optionalChain([active, 'optionalAccess', _553 => _553.type]) === "group" },
|
|
18305
|
+
{ action: "merge-down", label: "Merge Down", enabled: Boolean(_optionalChain([active, 'optionalAccess', _554 => _554.visible]) && _optionalChain([below, 'optionalAccess', _555 => _555.type]) === "pixel") },
|
|
18131
18306
|
{ action: "merge-visible", label: "Merge Visible", enabled: s.layers.some((l) => l.visible) },
|
|
18132
18307
|
{ action: "flatten", label: "Flatten Image", enabled: s.layers.length > 0 },
|
|
18133
18308
|
{ action: "via-copy", label: "Layer via Copy", enabled: isPixel && hasSel },
|
|
@@ -18137,27 +18312,27 @@ function layerMenu(controller) {
|
|
|
18137
18312
|
{ action: "add-mask-hide-selection", label: "Add Mask Hiding Selection", enabled: Boolean(active) && hasSel },
|
|
18138
18313
|
{ action: "add-mask-transparency", label: "Add Mask from Transparency", enabled: hasOwnPixels },
|
|
18139
18314
|
{ action: "select-transparency", label: "Select Layer Pixels", enabled: hasOwnPixels },
|
|
18140
|
-
{ action: "apply-mask", label: "Apply Layer Mask", enabled: isPixel && Boolean(_optionalChain([active, 'optionalAccess',
|
|
18141
|
-
{ action: "delete-mask", label: "Delete Layer Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess',
|
|
18142
|
-
{ action: "toggle-mask", label: _optionalChain([active, 'optionalAccess',
|
|
18143
|
-
{ action: "toggle-mask-link", label: _optionalChain([active, 'optionalAccess',
|
|
18144
|
-
{ action: "add-vector-mask", label: "Add Vector Mask (Reveal All)", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access',
|
|
18145
|
-
{ action: "add-vector-mask-hide", label: "Add Vector Mask (Hide All)", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access',
|
|
18146
|
-
{ action: "add-vector-mask-selection", label: "Add Vector Mask from Selection", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access',
|
|
18147
|
-
{ action: "delete-vector-mask", label: "Delete Vector Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess',
|
|
18148
|
-
{ action: "toggle-vector-mask", label: _optionalChain([active, 'optionalAccess',
|
|
18149
|
-
{ action: "rasterize-vector-mask", label: "Rasterize Vector Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess',
|
|
18150
|
-
{ action: "rasterize", label: "Rasterize Layer", enabled: _optionalChain([active, 'optionalAccess',
|
|
18315
|
+
{ action: "apply-mask", label: "Apply Layer Mask", enabled: isPixel && Boolean(_optionalChain([active, 'optionalAccess', _556 => _556.mask])) },
|
|
18316
|
+
{ action: "delete-mask", label: "Delete Layer Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _557 => _557.mask])) },
|
|
18317
|
+
{ action: "toggle-mask", label: _optionalChain([active, 'optionalAccess', _558 => _558.mask, 'optionalAccess', _559 => _559.enabled]) === false ? "Enable Layer Mask" : "Disable Layer Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _560 => _560.mask])) },
|
|
18318
|
+
{ action: "toggle-mask-link", label: _optionalChain([active, 'optionalAccess', _561 => _561.mask, 'optionalAccess', _562 => _562.linked]) === false ? "Link Layer Mask" : "Unlink Layer Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _563 => _563.mask]) && !active.mask.source) },
|
|
18319
|
+
{ action: "add-vector-mask", label: "Add Vector Mask (Reveal All)", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access', _564 => _564.mask, 'optionalAccess', _565 => _565.source])) },
|
|
18320
|
+
{ action: "add-vector-mask-hide", label: "Add Vector Mask (Hide All)", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access', _566 => _566.mask, 'optionalAccess', _567 => _567.source])) },
|
|
18321
|
+
{ action: "add-vector-mask-selection", label: "Add Vector Mask from Selection", enabled: Boolean(active && active.type !== "shape" && !_optionalChain([active, 'access', _568 => _568.mask, 'optionalAccess', _569 => _569.source])) && hasSel },
|
|
18322
|
+
{ action: "delete-vector-mask", label: "Delete Vector Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _570 => _570.vectorMask])) },
|
|
18323
|
+
{ action: "toggle-vector-mask", label: _optionalChain([active, 'optionalAccess', _571 => _571.vectorMask, 'optionalAccess', _572 => _572.enabled]) === false ? "Enable Vector Mask" : "Disable Vector Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _573 => _573.vectorMask])) },
|
|
18324
|
+
{ action: "rasterize-vector-mask", label: "Rasterize Vector Mask", enabled: Boolean(_optionalChain([active, 'optionalAccess', _574 => _574.vectorMask])) },
|
|
18325
|
+
{ action: "rasterize", label: "Rasterize Layer", enabled: _optionalChain([active, 'optionalAccess', _575 => _575.type]) === "annotation" || _optionalChain([active, 'optionalAccess', _576 => _576.type]) === "smart" || _optionalChain([active, 'optionalAccess', _577 => _577.type]) === "shape" || _optionalChain([active, 'optionalAccess', _578 => _578.type]) === "type" || isPixel && Boolean(_optionalChain([active, 'optionalAccess', _579 => _579.type]) === "pixel" && _optionalChain([active, 'access', _580 => _580.filters, 'optionalAccess', _581 => _581.length])) },
|
|
18151
18326
|
{ action: "convert-smart", label: "Convert to Smart Object", enabled: Boolean(active && active.type !== "annotation") },
|
|
18152
|
-
{ action: "edit-contents", label: "Edit Contents", enabled: _optionalChain([active, 'optionalAccess',
|
|
18153
|
-
{ action: "smart-via-copy", label: "New Smart Object via Copy", enabled: _optionalChain([active, 'optionalAccess',
|
|
18154
|
-
{ action: "add-filter-mask", label: "Add Smart Filter Mask", enabled: _optionalChain([active, 'optionalAccess',
|
|
18155
|
-
{ action: "toggle-clip", label: _optionalChain([active, 'optionalAccess',
|
|
18327
|
+
{ action: "edit-contents", label: "Edit Contents", enabled: _optionalChain([active, 'optionalAccess', _582 => _582.type]) === "smart" },
|
|
18328
|
+
{ action: "smart-via-copy", label: "New Smart Object via Copy", enabled: _optionalChain([active, 'optionalAccess', _583 => _583.type]) === "smart" },
|
|
18329
|
+
{ action: "add-filter-mask", label: "Add Smart Filter Mask", enabled: _optionalChain([active, 'optionalAccess', _584 => _584.type]) === "smart" && !_optionalChain([active, 'access', _585 => _585.smartFilters, 'optionalAccess', _586 => _586.mask]) },
|
|
18330
|
+
{ action: "toggle-clip", label: _optionalChain([active, 'optionalAccess', _587 => _587.clipped]) ? "Release Clipping Mask" : "Create Clipping Mask", enabled: Boolean(loc && loc.index > 0) }
|
|
18156
18331
|
];
|
|
18157
18332
|
}
|
|
18158
18333
|
async function runLayerMenuAction(controller, action) {
|
|
18159
18334
|
const active = controller.getActiveLayer();
|
|
18160
|
-
const id = _optionalChain([active, 'optionalAccess',
|
|
18335
|
+
const id = _optionalChain([active, 'optionalAccess', _588 => _588.id]);
|
|
18161
18336
|
try {
|
|
18162
18337
|
switch (action) {
|
|
18163
18338
|
case "new-layer":
|
|
@@ -18213,10 +18388,10 @@ async function runLayerMenuAction(controller, action) {
|
|
|
18213
18388
|
if (id) controller.removeLayerMask(id);
|
|
18214
18389
|
break;
|
|
18215
18390
|
case "toggle-mask":
|
|
18216
|
-
if (id && _optionalChain([active, 'optionalAccess',
|
|
18391
|
+
if (id && _optionalChain([active, 'optionalAccess', _589 => _589.mask])) controller.setLayerMaskProps(id, { enabled: active.mask.enabled === false });
|
|
18217
18392
|
break;
|
|
18218
18393
|
case "toggle-mask-link":
|
|
18219
|
-
if (id && _optionalChain([active, 'optionalAccess',
|
|
18394
|
+
if (id && _optionalChain([active, 'optionalAccess', _590 => _590.mask])) controller.setLayerMaskProps(id, { linked: active.mask.linked === false });
|
|
18220
18395
|
break;
|
|
18221
18396
|
case "add-vector-mask":
|
|
18222
18397
|
case "add-vector-mask-hide":
|
|
@@ -18229,7 +18404,7 @@ async function runLayerMenuAction(controller, action) {
|
|
|
18229
18404
|
if (id) controller.removeVectorMask(id);
|
|
18230
18405
|
break;
|
|
18231
18406
|
case "toggle-vector-mask":
|
|
18232
|
-
if (id && _optionalChain([active, 'optionalAccess',
|
|
18407
|
+
if (id && _optionalChain([active, 'optionalAccess', _591 => _591.vectorMask])) controller.setVectorMaskProps(id, { enabled: active.vectorMask.enabled === false });
|
|
18233
18408
|
break;
|
|
18234
18409
|
case "rasterize-vector-mask":
|
|
18235
18410
|
if (id) controller.rasterizeVectorMask(id);
|
|
@@ -18250,7 +18425,7 @@ async function runLayerMenuAction(controller, action) {
|
|
|
18250
18425
|
if (id) controller.setSmartFilterMask(id, "reveal-all");
|
|
18251
18426
|
break;
|
|
18252
18427
|
case "toggle-clip":
|
|
18253
|
-
if (id) controller.setLayerProperties(id, { clipped: !_optionalChain([active, 'optionalAccess',
|
|
18428
|
+
if (id) controller.setLayerProperties(id, { clipped: !_optionalChain([active, 'optionalAccess', _592 => _592.clipped]) });
|
|
18254
18429
|
break;
|
|
18255
18430
|
}
|
|
18256
18431
|
return null;
|
|
@@ -18260,7 +18435,7 @@ async function runLayerMenuAction(controller, action) {
|
|
|
18260
18435
|
}
|
|
18261
18436
|
function smartFilterRows(layer) {
|
|
18262
18437
|
if (layer.type !== "smart") return [];
|
|
18263
|
-
const list = _nullishCoalesce(_optionalChain([layer, 'access',
|
|
18438
|
+
const list = _nullishCoalesce(_optionalChain([layer, 'access', _593 => _593.smartFilters, 'optionalAccess', _594 => _594.filters]), () => ( []));
|
|
18264
18439
|
const rows = list.map((f, index) => ({
|
|
18265
18440
|
filter: f,
|
|
18266
18441
|
index,
|
|
@@ -18286,8 +18461,8 @@ function extractNormalizedLayerItems(controller, fallbackImageUrl = "") {
|
|
|
18286
18461
|
};
|
|
18287
18462
|
collectSerialized(_nullishCoalesce(serialized.layers, () => ( [])));
|
|
18288
18463
|
const sLayerMap = new Map(allSerializedLayers.map((sl) => [sl.id, sl]));
|
|
18289
|
-
const imgW = _optionalChain([state, 'access',
|
|
18290
|
-
const imgH = _optionalChain([state, 'access',
|
|
18464
|
+
const imgW = _optionalChain([state, 'access', _595 => _595.imageDimensions, 'optionalAccess', _596 => _596.width]) || 1;
|
|
18465
|
+
const imgH = _optionalChain([state, 'access', _597 => _597.imageDimensions, 'optionalAccess', _598 => _598.height]) || 1;
|
|
18291
18466
|
return ctrlLayers.map((l) => {
|
|
18292
18467
|
const bounds = controller.getLayerBounds(l.id) || {
|
|
18293
18468
|
x: 0,
|
|
@@ -18296,8 +18471,8 @@ function extractNormalizedLayerItems(controller, fallbackImageUrl = "") {
|
|
|
18296
18471
|
height: imgH
|
|
18297
18472
|
};
|
|
18298
18473
|
const sLayer = sLayerMap.get(l.id);
|
|
18299
|
-
const assetKey = _optionalChain([sLayer, 'optionalAccess',
|
|
18300
|
-
const layerDataUrl = assetKey && assets[assetKey] || assets[l.id] || (_optionalChain([sLayer, 'optionalAccess',
|
|
18474
|
+
const assetKey = _optionalChain([sLayer, 'optionalAccess', _599 => _599.asset]);
|
|
18475
|
+
const layerDataUrl = assetKey && assets[assetKey] || assets[l.id] || (_optionalChain([sLayer, 'optionalAccess', _600 => _600.source]) === "document" ? fallbackImageUrl : "");
|
|
18301
18476
|
return {
|
|
18302
18477
|
id: l.id,
|
|
18303
18478
|
name: l.name || "Untitled Layer",
|
|
@@ -18351,9 +18526,9 @@ async function addLayerOfKind(controller, id, init) {
|
|
|
18351
18526
|
const cx = Math.round(canvas.width / 2);
|
|
18352
18527
|
const cy = Math.round(canvas.height / 2);
|
|
18353
18528
|
return controller.addTextLayer({
|
|
18354
|
-
text: _optionalChain([init, 'optionalAccess',
|
|
18355
|
-
x: typeof _optionalChain([init, 'optionalAccess',
|
|
18356
|
-
y: typeof _optionalChain([init, 'optionalAccess',
|
|
18529
|
+
text: _optionalChain([init, 'optionalAccess', _601 => _601.text]) || "New Text",
|
|
18530
|
+
x: typeof _optionalChain([init, 'optionalAccess', _602 => _602.x]) === "number" ? init.x : cx - 100,
|
|
18531
|
+
y: typeof _optionalChain([init, 'optionalAccess', _603 => _603.y]) === "number" ? init.y : cy,
|
|
18357
18532
|
...init
|
|
18358
18533
|
});
|
|
18359
18534
|
}
|
|
@@ -18366,10 +18541,10 @@ async function addLayerOfKind(controller, id, init) {
|
|
|
18366
18541
|
return controller.addShapeLayer({
|
|
18367
18542
|
shape: {
|
|
18368
18543
|
kind: "rect",
|
|
18369
|
-
x: typeof _optionalChain([init, 'optionalAccess',
|
|
18370
|
-
y: typeof _optionalChain([init, 'optionalAccess',
|
|
18371
|
-
width: typeof _optionalChain([init, 'optionalAccess',
|
|
18372
|
-
height: typeof _optionalChain([init, 'optionalAccess',
|
|
18544
|
+
x: typeof _optionalChain([init, 'optionalAccess', _604 => _604.x]) === "number" ? init.x : cx - Math.round(w / 2),
|
|
18545
|
+
y: typeof _optionalChain([init, 'optionalAccess', _605 => _605.y]) === "number" ? init.y : cy - Math.round(h / 2),
|
|
18546
|
+
width: typeof _optionalChain([init, 'optionalAccess', _606 => _606.width]) === "number" ? init.width : w,
|
|
18547
|
+
height: typeof _optionalChain([init, 'optionalAccess', _607 => _607.height]) === "number" ? init.height : h
|
|
18373
18548
|
},
|
|
18374
18549
|
name: "Rectangle",
|
|
18375
18550
|
...init
|
|
@@ -18384,10 +18559,10 @@ async function addLayerOfKind(controller, id, init) {
|
|
|
18384
18559
|
return controller.addShapeLayer({
|
|
18385
18560
|
shape: {
|
|
18386
18561
|
kind: "ellipse",
|
|
18387
|
-
x: typeof _optionalChain([init, 'optionalAccess',
|
|
18388
|
-
y: typeof _optionalChain([init, 'optionalAccess',
|
|
18389
|
-
width: typeof _optionalChain([init, 'optionalAccess',
|
|
18390
|
-
height: typeof _optionalChain([init, 'optionalAccess',
|
|
18562
|
+
x: typeof _optionalChain([init, 'optionalAccess', _608 => _608.x]) === "number" ? init.x : cx - Math.round(w / 2),
|
|
18563
|
+
y: typeof _optionalChain([init, 'optionalAccess', _609 => _609.y]) === "number" ? init.y : cy - Math.round(h / 2),
|
|
18564
|
+
width: typeof _optionalChain([init, 'optionalAccess', _610 => _610.width]) === "number" ? init.width : w,
|
|
18565
|
+
height: typeof _optionalChain([init, 'optionalAccess', _611 => _611.height]) === "number" ? init.height : h
|
|
18391
18566
|
},
|
|
18392
18567
|
name: "Ellipse",
|
|
18393
18568
|
...init
|
|
@@ -18448,18 +18623,18 @@ function layerEffectsPanel(layer) {
|
|
|
18448
18623
|
if (!layer) return { ...empty, available: false, reason: "Select a layer to add a layer style." };
|
|
18449
18624
|
if (layer.type === "adjustment") return { ...empty, available: false, reason: "Adjustment layers cannot have a layer style." };
|
|
18450
18625
|
const fx = layer.effects;
|
|
18451
|
-
const readOnly = Boolean(_optionalChain([layer, 'access',
|
|
18626
|
+
const readOnly = Boolean(_optionalChain([layer, 'access', _612 => _612.locks, 'optionalAccess', _613 => _613.all]));
|
|
18452
18627
|
return {
|
|
18453
18628
|
available: true,
|
|
18454
18629
|
readOnly,
|
|
18455
18630
|
reason: readOnly ? "The layer is locked; unlock it to change its layer style." : void 0,
|
|
18456
|
-
enabled: _nullishCoalesce(_optionalChain([fx, 'optionalAccess',
|
|
18457
|
-
scale: _nullishCoalesce(_optionalChain([fx, 'optionalAccess',
|
|
18458
|
-
rows: (_nullishCoalesce(_optionalChain([fx, 'optionalAccess',
|
|
18631
|
+
enabled: _nullishCoalesce(_optionalChain([fx, 'optionalAccess', _614 => _614.enabled]), () => ( true)),
|
|
18632
|
+
scale: _nullishCoalesce(_optionalChain([fx, 'optionalAccess', _615 => _615.scale]), () => ( 1)),
|
|
18633
|
+
rows: (_nullishCoalesce(_optionalChain([fx, 'optionalAccess', _616 => _616.items]), () => ( []))).map((e) => ({ id: e.id, kind: e.kind, label: _chunkUOGKSVRQcjs.layerEffectLabel.call(void 0, e.kind), enabled: e.enabled }))
|
|
18459
18634
|
};
|
|
18460
18635
|
}
|
|
18461
18636
|
function layerEffectsBadge(layer) {
|
|
18462
|
-
if (!_optionalChain([layer, 'access',
|
|
18637
|
+
if (!_optionalChain([layer, 'access', _617 => _617.effects, 'optionalAccess', _618 => _618.items, 'access', _619 => _619.length])) return null;
|
|
18463
18638
|
return _chunkUOGKSVRQcjs.hasActiveEffects.call(void 0, layer.effects) ? "on" : "off";
|
|
18464
18639
|
}
|
|
18465
18640
|
var LAYER_EFFECT_MENU = _chunkUOGKSVRQcjs.LAYER_EFFECT_KINDS.map((kind) => ({ kind, label: _chunkUOGKSVRQcjs.layerEffectLabel.call(void 0, kind) }));
|
|
@@ -18504,8 +18679,8 @@ function fillControls(f, allowPattern, patterns) {
|
|
|
18504
18679
|
}
|
|
18505
18680
|
function gradientControls(prefix, g) {
|
|
18506
18681
|
return [
|
|
18507
|
-
{ key: `${prefix}.stops.0.color`, label: "Start colour", type: "color", value: _nullishCoalesce(_optionalChain([g, 'access',
|
|
18508
|
-
{ key: `${prefix}.stops.last.color`, label: "End colour", type: "color", value: _nullishCoalesce(_optionalChain([g, 'access',
|
|
18682
|
+
{ key: `${prefix}.stops.0.color`, label: "Start colour", type: "color", value: _nullishCoalesce(_optionalChain([g, 'access', _620 => _620.stops, 'access', _621 => _621[0], 'optionalAccess', _622 => _622.color]), () => ( "#000000")) },
|
|
18683
|
+
{ key: `${prefix}.stops.last.color`, label: "End colour", type: "color", value: _nullishCoalesce(_optionalChain([g, 'access', _623 => _623.stops, 'access', _624 => _624[g.stops.length - 1], 'optionalAccess', _625 => _625.color]), () => ( "#ffffff")) },
|
|
18509
18684
|
{ key: `${prefix}.style`, label: "Style", type: "select", value: g.style, options: opt(["linear", "Linear"], ["radial", "Radial"], ["angle", "Angle"], ["reflected", "Reflected"], ["diamond", "Diamond"]) },
|
|
18510
18685
|
{ key: `${prefix}.angle`, label: "Angle", type: "range", min: -180, max: 180, step: 1, value: g.angle, unit: "\xB0" },
|
|
18511
18686
|
{ key: `${prefix}.scale`, label: "Scale", type: "range", min: 0.1, max: 1.5, step: 0.01, value: g.scale, percent: true, unit: "%" },
|
|
@@ -18597,19 +18772,19 @@ function layerEffectControls(e, patterns = []) {
|
|
|
18597
18772
|
}
|
|
18598
18773
|
function fillOfType(current, type, patterns) {
|
|
18599
18774
|
if (type === "gradient") return { type: "gradient", gradient: _chunkUOGKSVRQcjs.defaultEffectGradient.call(void 0, ) };
|
|
18600
|
-
if (type === "pattern") return { type: "pattern", patternId: _nullishCoalesce(_optionalChain([patterns, 'access',
|
|
18775
|
+
if (type === "pattern") return { type: "pattern", patternId: _nullishCoalesce(_optionalChain([patterns, 'access', _626 => _626[0], 'optionalAccess', _627 => _627.id]), () => ( "checker")), scale: 1 };
|
|
18601
18776
|
return { type: "color", color: current.type === "color" ? current.color : "#000000" };
|
|
18602
18777
|
}
|
|
18603
18778
|
function effectControlChange(effect, key, value, patterns = []) {
|
|
18604
18779
|
const [top, ...rest] = key.split(".");
|
|
18605
18780
|
if (top === "fill" && rest[0] === "type") return { fill: fillOfType(effect.fill, String(value), patterns) };
|
|
18606
18781
|
if (top === "patternId" && !rest.length) {
|
|
18607
|
-
const name = _optionalChain([patternOptions, 'call',
|
|
18782
|
+
const name = _optionalChain([patternOptions, 'call', _628 => _628(patterns), 'access', _629 => _629.find, 'call', _630 => _630((o) => o.value === value), 'optionalAccess', _631 => _631.label]);
|
|
18608
18783
|
return name ? { patternId: value, name } : { patternId: value };
|
|
18609
18784
|
}
|
|
18610
18785
|
if (!rest.length) return { [top]: value };
|
|
18611
18786
|
if (top === "fill" && rest[0] === "patternId") {
|
|
18612
|
-
const name = _optionalChain([patternOptions, 'call',
|
|
18787
|
+
const name = _optionalChain([patternOptions, 'call', _632 => _632(patterns), 'access', _633 => _633.find, 'call', _634 => _634((o) => o.value === value), 'optionalAccess', _635 => _635.label]);
|
|
18613
18788
|
return { fill: { ...effect.fill, patternId: value, ...name ? { name } : {} } };
|
|
18614
18789
|
}
|
|
18615
18790
|
return { [top]: setPath(getPath(effect, top), rest, value) };
|
|
@@ -18636,7 +18811,7 @@ function colorPanelView(controller) {
|
|
|
18636
18811
|
profileName: profile.name,
|
|
18637
18812
|
workingSpace: profile.builtin,
|
|
18638
18813
|
mode: profile.mode,
|
|
18639
|
-
cmykProfileName: _nullishCoalesce(_optionalChain([profile, 'access',
|
|
18814
|
+
cmykProfileName: _nullishCoalesce(_optionalChain([profile, 'access', _636 => _636.cmykProfile, 'optionalAccess', _637 => _637.name]), () => ( null)),
|
|
18640
18815
|
proof: proof ? { id: _nullishCoalesce(proof.profile.builtin, () => ( null)), name: proof.profile.name, intent: proof.intent, simulatePaper: proof.simulatePaper, gamutWarning: proof.gamutWarning, bpc: proof.bpc } : null
|
|
18641
18816
|
};
|
|
18642
18817
|
}
|
|
@@ -18819,32 +18994,32 @@ function boxFrameHit(overlay, p, tolerance, band) {
|
|
|
18819
18994
|
return null;
|
|
18820
18995
|
}
|
|
18821
18996
|
var FreeTransformTool = (_class16 = class {
|
|
18822
|
-
constructor(controller, options = {}) {;_class16.prototype.
|
|
18997
|
+
constructor(controller, options = {}) {;_class16.prototype.__init131.call(this);_class16.prototype.__init132.call(this);_class16.prototype.__init133.call(this);_class16.prototype.__init134.call(this);_class16.prototype.__init135.call(this);_class16.prototype.__init136.call(this);_class16.prototype.__init137.call(this);_class16.prototype.__init138.call(this);_class16.prototype.__init139.call(this);_class16.prototype.__init140.call(this);_class16.prototype.__init141.call(this);_class16.prototype.__init142.call(this);_class16.prototype.__init143.call(this);_class16.prototype.__init144.call(this);
|
|
18823
18998
|
this.controller = controller;
|
|
18824
18999
|
this.options = options;
|
|
18825
19000
|
}
|
|
18826
19001
|
|
|
18827
19002
|
|
|
18828
|
-
|
|
18829
|
-
|
|
19003
|
+
__init131() {this.sessionRef = null}
|
|
19004
|
+
__init132() {this.modeValue = "scale"}
|
|
18830
19005
|
/** The reference point in the untransformed frame's space (follows the transform). */
|
|
18831
|
-
|
|
18832
|
-
|
|
18833
|
-
|
|
19006
|
+
__init133() {this.refBox = { x: 0, y: 0 }}
|
|
19007
|
+
__init134() {this.corners = null}
|
|
19008
|
+
__init135() {this.drag = null}
|
|
18834
19009
|
/** The warp mesh in the frame's own space (null: no warp). */
|
|
18835
|
-
|
|
18836
|
-
|
|
18837
|
-
|
|
18838
|
-
|
|
19010
|
+
__init136() {this.mesh = null}
|
|
19011
|
+
__init137() {this.warpSettings = { style: "custom", bend: 50, horizontal: 0, vertical: 0, orientation: "horizontal", columns: 1, rows: 1 }}
|
|
19012
|
+
__init138() {this.pending = false}
|
|
19013
|
+
__init139() {this.viewScale = 1}
|
|
18839
19014
|
|
|
18840
19015
|
/** Values typed into the options bar since the last drag (V skew is not recovered from the shape). */
|
|
18841
|
-
|
|
19016
|
+
__init140() {this.typed = {}}
|
|
18842
19017
|
/** Width and height scale together when typed (the chain icon). */
|
|
18843
|
-
|
|
18844
|
-
|
|
18845
|
-
|
|
19018
|
+
__init141() {this.proportional = true}
|
|
19019
|
+
__init142() {this.error = null}
|
|
19020
|
+
__init143() {this.lastResult = null}
|
|
18846
19021
|
get active() {
|
|
18847
|
-
return Boolean(_optionalChain([this, 'access',
|
|
19022
|
+
return Boolean(_optionalChain([this, 'access', _638 => _638.sessionRef, 'optionalAccess', _639 => _639.isOpen]));
|
|
18848
19023
|
}
|
|
18849
19024
|
get session() {
|
|
18850
19025
|
return this.active ? this.sessionRef : null;
|
|
@@ -18853,7 +19028,7 @@ var FreeTransformTool = (_class16 = class {
|
|
|
18853
19028
|
return this.modeValue;
|
|
18854
19029
|
}
|
|
18855
19030
|
get interpolation() {
|
|
18856
|
-
return _nullishCoalesce(_optionalChain([this, 'access',
|
|
19031
|
+
return _nullishCoalesce(_optionalChain([this, 'access', _640 => _640.sessionRef, 'optionalAccess', _641 => _641.interpolation]), () => ( "bicubic"));
|
|
18857
19032
|
}
|
|
18858
19033
|
/** Whether the open transform has changed anything yet (a commit would add an undo step). */
|
|
18859
19034
|
get modified() {
|
|
@@ -18863,7 +19038,7 @@ var FreeTransformTool = (_class16 = class {
|
|
|
18863
19038
|
const start = s.startGeometry.corners;
|
|
18864
19039
|
return this.corners.some((p, i) => p.x !== start[i].x || p.y !== start[i].y);
|
|
18865
19040
|
}
|
|
18866
|
-
|
|
19041
|
+
__init144() {this.listeners = /* @__PURE__ */ new Set()}
|
|
18867
19042
|
/** Calls `listener` whenever the overlay, readout, mode or error changes. Returns the unsubscribe. */
|
|
18868
19043
|
subscribe(listener) {
|
|
18869
19044
|
this.listeners.add(listener);
|
|
@@ -18872,7 +19047,7 @@ var FreeTransformTool = (_class16 = class {
|
|
|
18872
19047
|
};
|
|
18873
19048
|
}
|
|
18874
19049
|
changed() {
|
|
18875
|
-
_optionalChain([this, 'access',
|
|
19050
|
+
_optionalChain([this, 'access', _642 => _642.options, 'access', _643 => _643.onChange, 'optionalCall', _644 => _644()]);
|
|
18876
19051
|
for (const l of this.listeners) l();
|
|
18877
19052
|
}
|
|
18878
19053
|
/** Opens a Free Transform (default: the selected pixels of the active layer, or the whole layer). Returns an error message or `null`. */
|
|
@@ -19265,7 +19440,7 @@ var FreeTransformTool = (_class16 = class {
|
|
|
19265
19440
|
}
|
|
19266
19441
|
/** Abandons the transform and restores everything. */
|
|
19267
19442
|
cancel() {
|
|
19268
|
-
_optionalChain([this, 'access',
|
|
19443
|
+
_optionalChain([this, 'access', _645 => _645.sessionRef, 'optionalAccess', _646 => _646.cancel, 'call', _647 => _647()]);
|
|
19269
19444
|
this.sessionRef = null;
|
|
19270
19445
|
this.corners = null;
|
|
19271
19446
|
this.mesh = null;
|
|
@@ -19321,7 +19496,7 @@ function imageLayerAppliedEffects(layer) {
|
|
|
19321
19496
|
const ref = (r) => ({ effect: r.effect, ...r.name ? { name: r.name } : {}, ...r.provider ? { provider: r.provider } : {} });
|
|
19322
19497
|
if (layer.type === "pixel" && layer.generator) out.push({ id: "generator", ...ref(layer.generator), role: "effect layer", enabled: true, values: layer.generator.values, ...layer.generator.time ? { time: layer.generator.time } : {}, ...layer.generator.animate ? { animate: layer.generator.animate } : {} });
|
|
19323
19498
|
if (layer.type === "smart")
|
|
19324
|
-
(_nullishCoalesce(_optionalChain([layer, 'access',
|
|
19499
|
+
(_nullishCoalesce(_optionalChain([layer, 'access', _648 => _648.smartFilters, 'optionalAccess', _649 => _649.filters]), () => ( []))).forEach((f, index) => {
|
|
19325
19500
|
if (f.kind === "effect") out.push({ id: f.id, ...ref(f), role: "smart filter", enabled: f.enabled && layer.smartFilters.enabled, opacity: f.opacity, blend: f.blend, values: f.values, index });
|
|
19326
19501
|
});
|
|
19327
19502
|
return out;
|
|
@@ -19473,7 +19648,7 @@ var OTHER_TOOL_LABELS = {
|
|
|
19473
19648
|
watermark: "Watermark"
|
|
19474
19649
|
};
|
|
19475
19650
|
function imageToolLabel(tool) {
|
|
19476
|
-
return _nullishCoalesce(_nullishCoalesce(_optionalChain([PAINT_TOOLS, 'access',
|
|
19651
|
+
return _nullishCoalesce(_nullishCoalesce(_optionalChain([PAINT_TOOLS, 'access', _650 => _650.find, 'call', _651 => _651((t) => t.id === tool), 'optionalAccess', _652 => _652.label]), () => ( OTHER_TOOL_LABELS[tool])), () => ( tool));
|
|
19477
19652
|
}
|
|
19478
19653
|
var IMAGE_TOOL_SHORTCUTS = {
|
|
19479
19654
|
...Object.fromEntries(PAINT_TOOLS.filter((t) => t.shortcut).map((t) => [t.id, t.shortcut])),
|
|
@@ -19540,6 +19715,282 @@ function createImageEditorDocument(controller, options = {}) {
|
|
|
19540
19715
|
});
|
|
19541
19716
|
}
|
|
19542
19717
|
|
|
19718
|
+
// src/image-editor/content-aware-fill-session.ts
|
|
19719
|
+
var CONTENT_AWARE_FILL_TOOLS = [
|
|
19720
|
+
{ id: "sampling-brush", label: "Sampling Brush", key: "b" },
|
|
19721
|
+
{ id: "hand", label: "Hand", key: "h" },
|
|
19722
|
+
{ id: "zoom", label: "Zoom", key: "z" }
|
|
19723
|
+
];
|
|
19724
|
+
var CONTENT_AWARE_FILL_SAMPLING = [
|
|
19725
|
+
{ id: "auto", label: "Auto" },
|
|
19726
|
+
{ id: "rectangular", label: "Rectangular" },
|
|
19727
|
+
{ id: "custom", label: "Custom" }
|
|
19728
|
+
];
|
|
19729
|
+
var DEFAULT_CONTENT_AWARE_FILL_SETTINGS = {
|
|
19730
|
+
sampling: "auto",
|
|
19731
|
+
showSampling: true,
|
|
19732
|
+
opacity: 0.5,
|
|
19733
|
+
tool: "sampling-brush",
|
|
19734
|
+
brushSize: 40,
|
|
19735
|
+
brushMode: "add",
|
|
19736
|
+
seed: 0,
|
|
19737
|
+
output: "new-layer",
|
|
19738
|
+
livePreview: true
|
|
19739
|
+
};
|
|
19740
|
+
var ContentAwareFillSession = (_class17 = class {
|
|
19741
|
+
constructor(controller) {;_class17.prototype.__init145.call(this);_class17.prototype.__init146.call(this);_class17.prototype.__init147.call(this);_class17.prototype.__init148.call(this);_class17.prototype.__init149.call(this);_class17.prototype.__init150.call(this);_class17.prototype.__init151.call(this);_class17.prototype.__init152.call(this);_class17.prototype.__init153.call(this);_class17.prototype.__init154.call(this);_class17.prototype.__init155.call(this);_class17.prototype.__init156.call(this);_class17.prototype.__init157.call(this);_class17.prototype.__init158.call(this);
|
|
19742
|
+
this.controller = controller;
|
|
19743
|
+
}
|
|
19744
|
+
|
|
19745
|
+
__init145() {this.settingsValue = { ...DEFAULT_CONTENT_AWARE_FILL_SETTINGS }}
|
|
19746
|
+
__init146() {this.plan = null}
|
|
19747
|
+
/** The source view's window (document pixels): the selection with room around it to sample. */
|
|
19748
|
+
__init147() {this.win = null}
|
|
19749
|
+
__init148() {this.before = null}
|
|
19750
|
+
__init149() {this.hole = null}
|
|
19751
|
+
/** 1 where the fill may copy from, per window pixel. */
|
|
19752
|
+
__init150() {this.area = null}
|
|
19753
|
+
__init151() {this.after = null}
|
|
19754
|
+
__init152() {this.lastPoint = null}
|
|
19755
|
+
__init153() {this.listeners = /* @__PURE__ */ new Set()}
|
|
19756
|
+
__init154() {this.dirty = false}
|
|
19757
|
+
/** Why the workspace can't fill (nothing selected, not a pixel layer), for the UI. */
|
|
19758
|
+
__init155() {this.error = null}
|
|
19759
|
+
__init156() {this.computing = false}
|
|
19760
|
+
__init157() {this.revision = 0}
|
|
19761
|
+
get settings() {
|
|
19762
|
+
return this.settingsValue;
|
|
19763
|
+
}
|
|
19764
|
+
/** The source view's window in document pixels (`null` until opened). */
|
|
19765
|
+
get window() {
|
|
19766
|
+
return this.win;
|
|
19767
|
+
}
|
|
19768
|
+
subscribe(listener) {
|
|
19769
|
+
this.listeners.add(listener);
|
|
19770
|
+
return () => this.listeners.delete(listener);
|
|
19771
|
+
}
|
|
19772
|
+
emit() {
|
|
19773
|
+
this.revision++;
|
|
19774
|
+
for (const l of this.listeners) l();
|
|
19775
|
+
}
|
|
19776
|
+
/**
|
|
19777
|
+
* Reads the layer around the selection and makes the first preview. The window holds the
|
|
19778
|
+
* selection and room around it to sample from (its larger side, at least 64 px, each way).
|
|
19779
|
+
*/
|
|
19780
|
+
async open() {
|
|
19781
|
+
try {
|
|
19782
|
+
const sel = this.controller.getSelection();
|
|
19783
|
+
const b = _optionalChain([sel, 'optionalAccess', _653 => _653.bounds]);
|
|
19784
|
+
const margin = b ? Math.max(64, Math.max(b.width, b.height)) : 64;
|
|
19785
|
+
this.plan = this.controller.prepareContentAwareFill({ sampleRadius: margin });
|
|
19786
|
+
} catch (err) {
|
|
19787
|
+
this.error = err instanceof Error ? err.message : String(err);
|
|
19788
|
+
this.emit();
|
|
19789
|
+
return false;
|
|
19790
|
+
}
|
|
19791
|
+
this.win = this.plan.window;
|
|
19792
|
+
this.before = this.plan.before;
|
|
19793
|
+
this.hole = this.plan.hole;
|
|
19794
|
+
this.applySampling("auto");
|
|
19795
|
+
this.emit();
|
|
19796
|
+
await this.refresh();
|
|
19797
|
+
return true;
|
|
19798
|
+
}
|
|
19799
|
+
/** Sets the area to a preset: Auto (a band around the selection), Rectangular (the whole window). */
|
|
19800
|
+
applySampling(mode) {
|
|
19801
|
+
const win = this.win;
|
|
19802
|
+
const hole = this.hole;
|
|
19803
|
+
const n = win.width * win.height;
|
|
19804
|
+
const area = this.area && mode === "custom" ? this.area : new Uint8Array(n);
|
|
19805
|
+
if (mode === "rectangular") {
|
|
19806
|
+
for (let i = 0; i < n; i++) area[i] = hole[i] ? 0 : 1;
|
|
19807
|
+
} else if (mode === "auto") {
|
|
19808
|
+
const b = this.plan.bounds;
|
|
19809
|
+
const reach = Math.max(24, Math.max(b.width, b.height) / 2);
|
|
19810
|
+
const d = _chunkQYLWG22Ncjs.distanceTransform.call(void 0, hole, win.width, win.height);
|
|
19811
|
+
for (let i = 0; i < n; i++) area[i] = !hole[i] && d[i] <= reach ? 1 : 0;
|
|
19812
|
+
}
|
|
19813
|
+
this.area = area;
|
|
19814
|
+
}
|
|
19815
|
+
/** Changes settings; a sampling preset replaces the area, and the preview follows when live. */
|
|
19816
|
+
update(changes) {
|
|
19817
|
+
const prev = this.settingsValue;
|
|
19818
|
+
this.settingsValue = { ...prev, ...changes };
|
|
19819
|
+
if (!this.win) {
|
|
19820
|
+
this.emit();
|
|
19821
|
+
return;
|
|
19822
|
+
}
|
|
19823
|
+
if (changes.sampling && changes.sampling !== prev.sampling && changes.sampling !== "custom") this.applySampling(changes.sampling);
|
|
19824
|
+
this.emit();
|
|
19825
|
+
const fillChanged = changes.sampling !== void 0 || changes.seed !== void 0;
|
|
19826
|
+
if (fillChanged && this.settingsValue.livePreview) void this.refresh();
|
|
19827
|
+
}
|
|
19828
|
+
/** The sampling area as a selection of the whole image (what OK samples from). */
|
|
19829
|
+
samplingMask() {
|
|
19830
|
+
if (!this.win || !this.area) return null;
|
|
19831
|
+
const { width, height } = this.controller.getState().imageDimensions;
|
|
19832
|
+
const bytes = new Uint8Array(this.area.length);
|
|
19833
|
+
for (let i = 0; i < bytes.length; i++) bytes[i] = this.area[i] ? 255 : 0;
|
|
19834
|
+
return _chunkQYLWG22Ncjs.selectionFromRegion.call(void 0, width, height, this.win, bytes);
|
|
19835
|
+
}
|
|
19836
|
+
/** Whether (x, y) in document pixels is in the sampling area. */
|
|
19837
|
+
samplesAt(x, y) {
|
|
19838
|
+
const win = this.win;
|
|
19839
|
+
if (!win || !this.area) return false;
|
|
19840
|
+
const xi = Math.floor(x - win.x);
|
|
19841
|
+
const yi = Math.floor(y - win.y);
|
|
19842
|
+
if (xi < 0 || yi < 0 || xi >= win.width || yi >= win.height) return false;
|
|
19843
|
+
return this.area[yi * win.width + xi] === 1;
|
|
19844
|
+
}
|
|
19845
|
+
/** Paints the sampling area with the brush along a stroke segment (document pixels). */
|
|
19846
|
+
paint(from, to, add2) {
|
|
19847
|
+
const win = this.win;
|
|
19848
|
+
const area = this.area;
|
|
19849
|
+
const hole = this.hole;
|
|
19850
|
+
const r = Math.max(0.5, this.settingsValue.brushSize / 2);
|
|
19851
|
+
const x0 = Math.max(0, Math.floor(Math.min(from.x, to.x) - r - win.x));
|
|
19852
|
+
const y0 = Math.max(0, Math.floor(Math.min(from.y, to.y) - r - win.y));
|
|
19853
|
+
const x1 = Math.min(win.width - 1, Math.ceil(Math.max(from.x, to.x) + r - win.x));
|
|
19854
|
+
const y1 = Math.min(win.height - 1, Math.ceil(Math.max(from.y, to.y) + r - win.y));
|
|
19855
|
+
const dx = to.x - from.x;
|
|
19856
|
+
const dy = to.y - from.y;
|
|
19857
|
+
const len2 = dx * dx + dy * dy;
|
|
19858
|
+
for (let y = y0; y <= y1; y++) {
|
|
19859
|
+
for (let x = x0; x <= x1; x++) {
|
|
19860
|
+
const px2 = win.x + x + 0.5 - from.x;
|
|
19861
|
+
const py = win.y + y + 0.5 - from.y;
|
|
19862
|
+
const t = len2 > 0 ? Math.min(1, Math.max(0, (px2 * dx + py * dy) / len2)) : 0;
|
|
19863
|
+
if ((px2 - t * dx) ** 2 + (py - t * dy) ** 2 > r * r) continue;
|
|
19864
|
+
const i = y * win.width + x;
|
|
19865
|
+
area[i] = add2 && !hole[i] ? 1 : 0;
|
|
19866
|
+
}
|
|
19867
|
+
}
|
|
19868
|
+
}
|
|
19869
|
+
/** Pointer down with the Sampling Brush (Alt flips add and subtract). Returns false for other tools. */
|
|
19870
|
+
begin(point, modifiers = {}) {
|
|
19871
|
+
if (this.settingsValue.tool !== "sampling-brush" || !this.win) return false;
|
|
19872
|
+
const add2 = this.settingsValue.brushMode === "add" !== Boolean(modifiers.altKey);
|
|
19873
|
+
this.settingsValue = { ...this.settingsValue, sampling: "custom" };
|
|
19874
|
+
this.lastPoint = point;
|
|
19875
|
+
this.strokeAdds = add2;
|
|
19876
|
+
this.paint(point, point, add2);
|
|
19877
|
+
this.emit();
|
|
19878
|
+
return true;
|
|
19879
|
+
}
|
|
19880
|
+
__init158() {this.strokeAdds = true}
|
|
19881
|
+
move(point) {
|
|
19882
|
+
if (!this.lastPoint) return;
|
|
19883
|
+
this.paint(this.lastPoint, point, this.strokeAdds);
|
|
19884
|
+
this.lastPoint = point;
|
|
19885
|
+
this.emit();
|
|
19886
|
+
}
|
|
19887
|
+
/** Pointer up: the preview follows the new area when live. */
|
|
19888
|
+
end() {
|
|
19889
|
+
if (!this.lastPoint) return;
|
|
19890
|
+
this.lastPoint = null;
|
|
19891
|
+
if (this.settingsValue.livePreview) void this.refresh();
|
|
19892
|
+
}
|
|
19893
|
+
/** Recomputes the preview: one at a time, the newest area following when one is running. */
|
|
19894
|
+
async refresh() {
|
|
19895
|
+
if (!this.win) return;
|
|
19896
|
+
if (this.computing) {
|
|
19897
|
+
this.dirty = true;
|
|
19898
|
+
return;
|
|
19899
|
+
}
|
|
19900
|
+
this.computing = true;
|
|
19901
|
+
this.emit();
|
|
19902
|
+
do {
|
|
19903
|
+
this.dirty = false;
|
|
19904
|
+
try {
|
|
19905
|
+
const area = this.samplingMask();
|
|
19906
|
+
if (!_optionalChain([area, 'optionalAccess', _654 => _654.bounds])) throw new Error("The sampling area is empty; paint where the fill may copy from.");
|
|
19907
|
+
const { plan, after } = await this.controller.previewContentAwareFill({ layerId: this.plan.layerId, samplingArea: area, seed: this.settingsValue.seed });
|
|
19908
|
+
const win = this.win;
|
|
19909
|
+
const out = Uint8ClampedArray.from(this.before);
|
|
19910
|
+
const pw = plan.window;
|
|
19911
|
+
for (let y = 0; y < pw.height; y++) {
|
|
19912
|
+
out.set(after.subarray(y * pw.width * 4, (y + 1) * pw.width * 4), ((pw.y - win.y + y) * win.width + (pw.x - win.x)) * 4);
|
|
19913
|
+
}
|
|
19914
|
+
this.after = out;
|
|
19915
|
+
this.error = null;
|
|
19916
|
+
} catch (err) {
|
|
19917
|
+
this.after = null;
|
|
19918
|
+
this.error = err instanceof Error ? err.message : String(err);
|
|
19919
|
+
}
|
|
19920
|
+
this.emit();
|
|
19921
|
+
} while (this.dirty);
|
|
19922
|
+
this.computing = false;
|
|
19923
|
+
this.emit();
|
|
19924
|
+
}
|
|
19925
|
+
/** Resolves once no preview is being computed. */
|
|
19926
|
+
async idle() {
|
|
19927
|
+
while (this.computing) await new Promise((r) => setTimeout(r, 5));
|
|
19928
|
+
}
|
|
19929
|
+
/** The source view: the layer's pixels, the selection tinted red, the sampling area green. RGBA at the window's size. */
|
|
19930
|
+
renderSource() {
|
|
19931
|
+
if (!this.before || !this.area || !this.hole) return new Uint8ClampedArray(0);
|
|
19932
|
+
const out = Uint8ClampedArray.from(this.before);
|
|
19933
|
+
const k = this.settingsValue.showSampling ? Math.min(1, Math.max(0, this.settingsValue.opacity)) : 0;
|
|
19934
|
+
for (let i = 0; i < this.area.length; i++) {
|
|
19935
|
+
const p = i * 4;
|
|
19936
|
+
if (this.hole[i]) {
|
|
19937
|
+
out[p] = out[p] + (220 - out[p]) * 0.5;
|
|
19938
|
+
out[p + 1] *= 0.5;
|
|
19939
|
+
out[p + 2] *= 0.5;
|
|
19940
|
+
} else if (this.area[i] && k) {
|
|
19941
|
+
out[p] *= 1 - k;
|
|
19942
|
+
out[p + 1] = out[p + 1] + (200 - out[p + 1]) * k;
|
|
19943
|
+
out[p + 2] *= 1 - k;
|
|
19944
|
+
}
|
|
19945
|
+
out[p + 3] = 255;
|
|
19946
|
+
}
|
|
19947
|
+
return out;
|
|
19948
|
+
}
|
|
19949
|
+
/** The preview: the window with the fill in place (the source until the first preview). */
|
|
19950
|
+
renderPreview() {
|
|
19951
|
+
const src = _nullishCoalesce(this.after, () => ( this.before));
|
|
19952
|
+
if (!src) return new Uint8ClampedArray(0);
|
|
19953
|
+
const out = Uint8ClampedArray.from(src);
|
|
19954
|
+
for (let i = 3; i < out.length; i += 4) out[i] = 255;
|
|
19955
|
+
return out;
|
|
19956
|
+
}
|
|
19957
|
+
/** Clears painting and goes back to Auto. */
|
|
19958
|
+
reset() {
|
|
19959
|
+
if (!this.win) return;
|
|
19960
|
+
this.settingsValue = { ...DEFAULT_CONTENT_AWARE_FILL_SETTINGS, tool: this.settingsValue.tool };
|
|
19961
|
+
this.applySampling("auto");
|
|
19962
|
+
this.emit();
|
|
19963
|
+
if (this.settingsValue.livePreview) void this.refresh();
|
|
19964
|
+
}
|
|
19965
|
+
/**
|
|
19966
|
+
* Keys: B, H, Z for the tools, [ and ] for the brush size. Returns true when the key was used.
|
|
19967
|
+
*/
|
|
19968
|
+
handleKey(key) {
|
|
19969
|
+
const k = key.toLowerCase();
|
|
19970
|
+
const tool = CONTENT_AWARE_FILL_TOOLS.find((t) => t.key === k);
|
|
19971
|
+
if (tool) {
|
|
19972
|
+
this.update({ tool: tool.id });
|
|
19973
|
+
return true;
|
|
19974
|
+
}
|
|
19975
|
+
if (k === "[" || k === "]") {
|
|
19976
|
+
const size = this.settingsValue.brushSize;
|
|
19977
|
+
this.update({ brushSize: Math.max(1, Math.round(k === "]" ? size * 1.25 : size / 1.25)) });
|
|
19978
|
+
return true;
|
|
19979
|
+
}
|
|
19980
|
+
return false;
|
|
19981
|
+
}
|
|
19982
|
+
/** OK: fills with this sampling area, seed and output as one undo step. */
|
|
19983
|
+
async commit(options = {}) {
|
|
19984
|
+
const area = this.samplingMask();
|
|
19985
|
+
if (!this.plan || !_optionalChain([area, 'optionalAccess', _655 => _655.bounds])) throw new Error(_nullishCoalesce(this.error, () => ( "The sampling area is empty; paint where the fill may copy from.")));
|
|
19986
|
+
return this.controller.contentAwareFillAsync({ layerId: this.plan.layerId, samplingArea: area, seed: this.settingsValue.seed, output: this.settingsValue.output, signal: options.signal });
|
|
19987
|
+
}
|
|
19988
|
+
}, _class17);
|
|
19989
|
+
|
|
19990
|
+
|
|
19991
|
+
|
|
19992
|
+
|
|
19993
|
+
|
|
19543
19994
|
|
|
19544
19995
|
|
|
19545
19996
|
|
|
@@ -20625,4 +21076,4 @@ function createImageEditorDocument(controller, options = {}) {
|
|
|
20625
21076
|
|
|
20626
21077
|
|
|
20627
21078
|
|
|
20628
|
-
exports.ADJUSTMENT_KEYS = _chunkQE7D7TZRcjs.ADJUSTMENT_KEYS; exports.ADJUSTMENT_KINDS = _chunkQE7D7TZRcjs.ADJUSTMENT_KINDS; exports.ADJUSTMENT_LAYER_CONTROLS = ADJUSTMENT_LAYER_CONTROLS; exports.ADJUSTMENT_LAYER_OPACITY_CONTROL = ADJUSTMENT_LAYER_OPACITY_CONTROL; exports.ADJUSTMENT_LUT_SIZE = _chunkQE7D7TZRcjs.ADJUSTMENT_LUT_SIZE; exports.ANCHOR_FRACTION = _chunkQE7D7TZRcjs.ANCHOR_FRACTION; exports.AS_SHOT_KELVIN = _chunkQE7D7TZRcjs.AS_SHOT_KELVIN; exports.BACKGROUND_LAYER_ID = _chunkQE7D7TZRcjs.BACKGROUND_LAYER_ID; exports.BACKGROUND_LAYER_NAME = _chunkQE7D7TZRcjs.BACKGROUND_LAYER_NAME; exports.BIT_DEPTHS = _chunkOLNIPTB3cjs.BIT_DEPTHS; exports.BIT_DEPTH_OPTIONS = BIT_DEPTH_OPTIONS; exports.BLEND_MODES = _chunkOLNIPTB3cjs.BLEND_MODES; exports.BLUR_FILTER_ID = _chunkQE7D7TZRcjs.BLUR_FILTER_ID; exports.BODY_SCATTER = _chunkKWNMBMKGcjs.BODY_SCATTER; exports.BRUSHSTROKE_MAX_SCALE = _chunkYQGCPL5Xcjs.BRUSHSTROKE_MAX_SCALE; exports.BRUSHSTROKE_MIN_SCALE = _chunkYQGCPL5Xcjs.BRUSHSTROKE_MIN_SCALE; exports.BRUSH_OPTION_CONTROLS = BRUSH_OPTION_CONTROLS; exports.BUILTIN_PROFILES = _chunkBROJYMWUcjs.BUILTIN_PROFILES; exports.BrushstrokeCache = _chunkPQ3H2AANcjs.BrushstrokeCache; exports.CANVAS_SIZE_PRESETS = CANVAS_SIZE_PRESETS; exports.CLONE_TRANSFORM_CONTROLS = CLONE_TRANSFORM_CONTROLS; exports.COLOR_MODE_OPTIONS = COLOR_MODE_OPTIONS; exports.COLOR_RANGE_PRESETS = COLOR_RANGE_PRESETS; exports.COLOR_RANGE_PRESET_LABELS = COLOR_RANGE_PRESET_LABELS; exports.ColorGmm = _chunkX4LUGTQXcjs.ColorGmm; exports.CoverageMap = _chunkPQ3H2AANcjs.CoverageMap; exports.D50 = _chunkQE7D7TZRcjs.D50; exports.D65 = _chunkQE7D7TZRcjs.D65; exports.DEFAULT_ADJUSTMENTS = DEFAULT_ADJUSTMENTS; exports.DEFAULT_AUTO_LEADING = _chunkQAUIZPYIcjs.DEFAULT_AUTO_LEADING; exports.DEFAULT_BLENDER = _chunkPQ3H2AANcjs.DEFAULT_BLENDER; exports.DEFAULT_BRUSH = _chunkPQ3H2AANcjs.DEFAULT_BRUSH; exports.DEFAULT_CANVAS_VIEWPORT = DEFAULT_CANVAS_VIEWPORT; exports.DEFAULT_CHANNEL_COLOR = DEFAULT_CHANNEL_COLOR; exports.DEFAULT_DEPTH_MASK = DEFAULT_DEPTH_MASK; exports.DEFAULT_FLOW = _chunkKWNMBMKGcjs.DEFAULT_FLOW; exports.DEFAULT_GLOBAL_LIGHT = _chunkUOGKSVRQcjs.DEFAULT_GLOBAL_LIGHT; exports.DEFAULT_MITER_LIMIT = _chunkQE7D7TZRcjs.DEFAULT_MITER_LIMIT; exports.DEFAULT_MIXER = _chunkPQ3H2AANcjs.DEFAULT_MIXER; exports.DEFAULT_PAINT_GRADIENT = _chunkPQ3H2AANcjs.DEFAULT_PAINT_GRADIENT; exports.DEFAULT_PAINT_GRADIENT_MAPPING = _chunkPQ3H2AANcjs.DEFAULT_PAINT_GRADIENT_MAPPING; exports.DEFAULT_PROOF = DEFAULT_PROOF; exports.DEFAULT_REFINE_EDGE_PARAMS = _chunkX4LUGTQXcjs.DEFAULT_REFINE_EDGE_PARAMS; exports.DEFAULT_RETOUCH = _chunk3EHPLDFQcjs.DEFAULT_RETOUCH; exports.DEFAULT_SELECTION_TOOL_OPTIONS = DEFAULT_SELECTION_TOOL_OPTIONS; exports.DEFAULT_SELECT_AND_MASK_SETTINGS = DEFAULT_SELECT_AND_MASK_SETTINGS; exports.DEFAULT_SHAPE_TOOL_OPTIONS = DEFAULT_SHAPE_TOOL_OPTIONS; exports.DEFAULT_SMUDGE = _chunkPQ3H2AANcjs.DEFAULT_SMUDGE; exports.DEFAULT_TEXT_STYLE = _chunkQAUIZPYIcjs.DEFAULT_TEXT_STYLE; exports.DEFAULT_TRANSFORM = DEFAULT_TRANSFORM; exports.DEFAULT_TYPE_TOOL_OPTIONS = DEFAULT_TYPE_TOOL_OPTIONS; exports.DEFAULT_WET_PAPER = _chunkKWNMBMKGcjs.DEFAULT_WET_PAPER; exports.DEFAULT_WET_PARAMS = _chunkKWNMBMKGcjs.DEFAULT_WET_PARAMS; exports.DEPTH_MASK_CONTROLS = DEPTH_MASK_CONTROLS; exports.DEVELOP_FILTER_ID = _chunkQE7D7TZRcjs.DEVELOP_FILTER_ID; exports.DIRECT_GAUSSIAN_MAX_SIGMA = _chunkK6PXS6DOcjs.DIRECT_GAUSSIAN_MAX_SIGMA; exports.DRY_EPS = _chunkKWNMBMKGcjs.DRY_EPS; exports.DabWalker = _chunkPQ3H2AANcjs.DabWalker; exports.EFFECT_LAYER_USES = EFFECT_LAYER_USES; exports.EMPTY_DISTANCE = _chunkQYLWG22Ncjs.EMPTY_DISTANCE; exports.EMPTY_MIXER_LOAD = _chunkPQ3H2AANcjs.EMPTY_MIXER_LOAD; exports.EX = _chunkKWNMBMKGcjs.EX; exports.EY = _chunkKWNMBMKGcjs.EY; exports.EdgeMap = EdgeMap; exports.FLAG_ALIVE = _chunkKWNMBMKGcjs.FLAG_ALIVE; exports.FLAG_BOTTOM = _chunkKWNMBMKGcjs.FLAG_BOTTOM; exports.FLAG_LEFT = _chunkKWNMBMKGcjs.FLAG_LEFT; exports.FLAG_RIGHT = _chunkKWNMBMKGcjs.FLAG_RIGHT; exports.FLAG_TOP = _chunkKWNMBMKGcjs.FLAG_TOP; exports.FLAG_WET = _chunkKWNMBMKGcjs.FLAG_WET; exports.FLAT = _chunkKWNMBMKGcjs.FLAT; exports.FREE_INTERVAL = _chunkKWNMBMKGcjs.FREE_INTERVAL; exports.FREE_TRANSFORM_CONTENTS = FREE_TRANSFORM_CONTENTS; exports.FREE_TRANSFORM_FIELDS = FREE_TRANSFORM_FIELDS; exports.FREE_TRANSFORM_MODES = _chunkQE7D7TZRcjs.FREE_TRANSFORM_MODES; exports.FREE_TRANSFORM_MODE_OPTIONS = FREE_TRANSFORM_MODE_OPTIONS; exports.FreeTransformSession = FreeTransformSession; exports.FreeTransformTool = FreeTransformTool; exports.GAMMA = _chunkX4LUGTQXcjs.GAMMA; exports.GRAIN_PATTERNS = _chunkPQ3H2AANcjs.GRAIN_PATTERNS; exports.GRAIN_TILE = _chunkPQ3H2AANcjs.GRAIN_TILE; exports.GUIDED_FILTER_EPS = _chunkX4LUGTQXcjs.GUIDED_FILTER_EPS; exports.GridGraph = _chunkX4LUGTQXcjs.GridGraph; exports.HIDE = _chunkKWNMBMKGcjs.HIDE; exports.HISTOGRAM_BINS = HISTOGRAM_BINS; exports.HUE_RANGE_LABELS = _chunkQE7D7TZRcjs.HUE_RANGE_LABELS; exports.HUE_RANGE_PRESETS = HUE_RANGE_PRESETS; exports.IDENTITY_CLONE_TRANSFORM = _chunk3EHPLDFQcjs.IDENTITY_CLONE_TRANSFORM; exports.IDENTITY_MATRIX3 = _chunkQE7D7TZRcjs.IDENTITY_MATRIX3; exports.IMAGE_ADJUSTMENT_CONTROLS = IMAGE_ADJUSTMENT_CONTROLS; exports.IMAGE_CROP_PRESETS = IMAGE_CROP_PRESETS; exports.IMAGE_EDITOR_SCHEMA_VERSION = IMAGE_EDITOR_SCHEMA_VERSION; exports.IMAGE_EDITOR_STATE_VERSION = IMAGE_EDITOR_STATE_VERSION; exports.IMAGE_EFFECT_PLACES = IMAGE_EFFECT_PLACES; exports.IMAGE_FILTER_PRESETS = IMAGE_FILTER_PRESETS; exports.IMAGE_PLAYBACK_KIND = IMAGE_PLAYBACK_KIND; exports.IMAGE_TOOL_GROUPS = IMAGE_TOOL_GROUPS; exports.IMAGE_TOOL_SHORTCUTS = IMAGE_TOOL_SHORTCUTS; exports.INTENTS = _chunkBROJYMWUcjs.INTENTS; exports.INTENT_OPTIONS = INTENT_OPTIONS; exports.INTERPOLATIONS = _chunkUOGKSVRQcjs.INTERPOLATIONS; exports.ImageEditorController = ImageEditorController; exports.ImageEditorRenderer = ImageEditorRenderer; exports.ImageEffectsEngine = ImageEffectsEngine; exports.LATEST_PROCESS_VERSION = _chunkQE7D7TZRcjs.LATEST_PROCESS_VERSION; exports.LAYERED_SCHEMA_VERSION = _chunkQE7D7TZRcjs.LAYERED_SCHEMA_VERSION; exports.LAYER_EFFECT_KINDS = _chunkUOGKSVRQcjs.LAYER_EFFECT_KINDS; exports.LAYER_EFFECT_MENU = LAYER_EFFECT_MENU; exports.LEGACY_PROCESS_VERSION = _chunkQE7D7TZRcjs.LEGACY_PROCESS_VERSION; exports.LIVE_SHAPE_KINDS = _chunkQE7D7TZRcjs.LIVE_SHAPE_KINDS; exports.LUMA_709 = _chunkQE7D7TZRcjs.LUMA_709; exports.LayerCompositor = _chunkQE7D7TZRcjs.LayerCompositor; exports.LayerEffectError = _chunkUOGKSVRQcjs.LayerEffectError; exports.LayerOperationError = _chunkQE7D7TZRcjs.LayerOperationError; exports.MARCHING_ANTS_STEP_MS = MARCHING_ANTS_STEP_MS; exports.MASK_FILE_ACCEPT = MASK_FILE_ACCEPT; exports.MAX_BATCH = _chunkKWNMBMKGcjs.MAX_BATCH; exports.MAX_BRUSH_SIZE = _chunkPQ3H2AANcjs.MAX_BRUSH_SIZE; exports.MAX_CANVAS_BACKING_SIDE = MAX_CANVAS_BACKING_SIDE; exports.MAX_EFFECT_ANIMATION_MS = _chunkQE7D7TZRcjs.MAX_EFFECT_ANIMATION_MS; exports.MAX_EFFECT_REACH = _chunkUOGKSVRQcjs.MAX_EFFECT_REACH; exports.MAX_KELVIN = _chunkQE7D7TZRcjs.MAX_KELVIN; exports.MAX_TILT_ACCEL = _chunkKWNMBMKGcjs.MAX_TILT_ACCEL; exports.MAX_TRANSFORM_PIXELS = _chunkUOGKSVRQcjs.MAX_TRANSFORM_PIXELS; exports.MAX_WET_LANES = _chunkKWNMBMKGcjs.MAX_WET_LANES; exports.MAX_WET_SLOTS = _chunkKWNMBMKGcjs.MAX_WET_SLOTS; exports.MIN_KELVIN = _chunkQE7D7TZRcjs.MIN_KELVIN; exports.MIRED_PER_TEMPERATURE_UNIT = _chunkQE7D7TZRcjs.MIRED_PER_TEMPERATURE_UNIT; exports.MIXER_DRAIN = _chunkPQ3H2AANcjs.MIXER_DRAIN; exports.MIXER_MIXING_OPTIONS = MIXER_MIXING_OPTIONS; exports.MIXER_OPTION_CONTROLS = MIXER_OPTION_CONTROLS; exports.MIXER_PICKUP_RATE = _chunkPQ3H2AANcjs.MIXER_PICKUP_RATE; exports.MIXING_MODELS = _chunkPQ3H2AANcjs.MIXING_MODELS; exports.MixerStroke = _chunkPQ3H2AANcjs.MixerStroke; exports.OPP = _chunkKWNMBMKGcjs.OPP; exports.PAINTERLY_BLEND_MODES = _chunkOLNIPTB3cjs.PAINTERLY_BLEND_MODES; exports.PAINT_COLOR_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_COLOR_JSON_SCHEMA; exports.PAINT_GRADIENT_FULL_SPEED = _chunkPQ3H2AANcjs.PAINT_GRADIENT_FULL_SPEED; exports.PAINT_GRADIENT_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_GRADIENT_JSON_SCHEMA; exports.PAINT_GRADIENT_KIT = _chunkPQ3H2AANcjs.PAINT_GRADIENT_KIT; exports.PAINT_GRADIENT_MAPPINGS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_MAPPINGS; exports.PAINT_GRADIENT_MAPPING_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_MAPPING_LABELS; exports.PAINT_GRADIENT_PRESETS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_PRESETS; exports.PAINT_GRADIENT_REPEATS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_REPEATS; exports.PAINT_GRADIENT_REPEAT_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_REPEAT_LABELS; exports.PAINT_GRADIENT_SPACES = _chunkPQ3H2AANcjs.PAINT_GRADIENT_SPACES; exports.PAINT_GRADIENT_SPACE_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_SPACE_LABELS; exports.PAINT_SOURCE_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_SOURCE_JSON_SCHEMA; exports.PAINT_TOOLS = PAINT_TOOLS; exports.PAPER_CAPACITY = _chunkKWNMBMKGcjs.PAPER_CAPACITY; exports.PARAGRAPH_STYLE_FIELDS = _chunkQE7D7TZRcjs.PARAGRAPH_STYLE_FIELDS; exports.PARAM = _chunkKWNMBMKGcjs.PARAM; exports.PARAM_FLOATS = _chunkKWNMBMKGcjs.PARAM_FLOATS; exports.PASTE_MODES = PASTE_MODES; exports.PATTERN_BLOCK_KEYS = _chunkQE7D7TZRcjs.PATTERN_BLOCK_KEYS; exports.PIGMENT_BANDS = _chunkOLNIPTB3cjs.PIGMENT_BANDS; exports.PIGMENT_CHANNELS = _chunkKWNMBMKGcjs.PIGMENT_CHANNELS; exports.PIGMENT_LAMBDA_MIN = _chunkOLNIPTB3cjs.PIGMENT_LAMBDA_MIN; exports.PIGMENT_LAMBDA_STEP = _chunkOLNIPTB3cjs.PIGMENT_LAMBDA_STEP; exports.PIGMENT_UNIT = _chunkKWNMBMKGcjs.PIGMENT_UNIT; exports.PIGMENT_WAVELENGTHS = _chunkOLNIPTB3cjs.PIGMENT_WAVELENGTHS; exports.PLANE = _chunkKWNMBMKGcjs.PLANE; exports.PLANE_BYTES = _chunkKWNMBMKGcjs.PLANE_BYTES; exports.PREVIEW_SIZE = PREVIEW_SIZE; exports.PROOF_PROFILE_OPTIONS = PROOF_PROFILE_OPTIONS; exports.PSD_BLEND_KEYS = _chunkQE7D7TZRcjs.PSD_BLEND_KEYS; exports.PSD_FILE_ACCEPT = PSD_FILE_ACCEPT; exports.P_D0 = _chunkKWNMBMKGcjs.P_D0; exports.P_EDGE = _chunkKWNMBMKGcjs.P_EDGE; exports.P_FX = _chunkKWNMBMKGcjs.P_FX; exports.P_FY = _chunkKWNMBMKGcjs.P_FY; exports.P_H = _chunkKWNMBMKGcjs.P_H; exports.P_P0 = _chunkKWNMBMKGcjs.P_P0; exports.P_RHO = _chunkKWNMBMKGcjs.P_RHO; exports.P_SW = _chunkKWNMBMKGcjs.P_SW; exports.P_UX = _chunkKWNMBMKGcjs.P_UX; exports.P_UY = _chunkKWNMBMKGcjs.P_UY; exports.PaintExchange = _chunkPQ3H2AANcjs.PaintExchange; exports.PaintGesture = PaintGesture; exports.PaintGradientSampler = _chunkPQ3H2AANcjs.PaintGradientSampler; exports.PaintSourceError = _chunkPQ3H2AANcjs.PaintSourceError; exports.PaintStrokeSession = PaintStrokeSession; exports.PaperGrain = _chunkPQ3H2AANcjs.PaperGrain; exports.PatternPlacement = _chunkUOGKSVRQcjs.PatternPlacement; exports.PatternTile = _chunkUOGKSVRQcjs.PatternTile; exports.PsdError = _chunkQE7D7TZRcjs.PsdError; exports.QUICK_MASK_TARGET = QUICK_MASK_TARGET; exports.REFINE_EDGE_CONTROLS = REFINE_EDGE_CONTROLS; exports.REFINE_EDIT_KINDS = _chunkX4LUGTQXcjs.REFINE_EDIT_KINDS; exports.REFINE_OUTPUTS = REFINE_OUTPUTS; exports.RETOUCH_CHOICES = RETOUCH_CHOICES; exports.RETOUCH_OPTION_CONTROLS = RETOUCH_OPTION_CONTROLS; exports.RETOUCH_SAMPLES = _chunk3EHPLDFQcjs.RETOUCH_SAMPLES; exports.RETOUCH_TOGGLES = RETOUCH_TOGGLES; exports.RETOUCH_TOOLS = RETOUCH_TOOLS; exports.RegionPixelSource = _chunk3EHPLDFQcjs.RegionPixelSource; exports.RetouchDabStroke = _chunk3EHPLDFQcjs.RetouchDabStroke; exports.SELECTION_MODES = _chunkQYLWG22Ncjs.SELECTION_MODES; exports.SELECTION_MODE_LABELS = SELECTION_MODE_LABELS; exports.SELECTION_MODIFY_OPS = _chunkQYLWG22Ncjs.SELECTION_MODIFY_OPS; exports.SELECTION_TOOLS = SELECTION_TOOLS; exports.SELECT_AND_MASK_TOOLS = SELECT_AND_MASK_TOOLS; exports.SELECT_AND_MASK_VIEWS = SELECT_AND_MASK_VIEWS; exports.SET_PLANES = _chunkKWNMBMKGcjs.SET_PLANES; exports.SHADOW_AMBIENT = _chunkOLNIPTB3cjs.SHADOW_AMBIENT; exports.SHAPE_KIND_LABELS = SHAPE_KIND_LABELS; exports.SHAPE_OPERATIONS = _chunkQE7D7TZRcjs.SHAPE_OPERATIONS; exports.SHAPE_RENDER_MARGIN = _chunkQE7D7TZRcjs.SHAPE_RENDER_MARGIN; exports.SLOT_BYTES = _chunkKWNMBMKGcjs.SLOT_BYTES; exports.SLOT_PLANES = _chunkKWNMBMKGcjs.SLOT_PLANES; exports.SLOT_SIDE = _chunkKWNMBMKGcjs.SLOT_SIDE; exports.SMART_RENDER_MARGIN = _chunkQE7D7TZRcjs.SMART_RENDER_MARGIN; exports.SPOT_HEAL_TYPES = _chunk3EHPLDFQcjs.SPOT_HEAL_TYPES; exports.SRGB_TO_LINEAR = _chunkKWNMBMKGcjs.SRGB_TO_LINEAR; exports.STRIP = _chunkKWNMBMKGcjs.STRIP; exports.SUPPORTED_ADJUSTMENT_KEYS = _chunkQE7D7TZRcjs.SUPPORTED_ADJUSTMENT_KEYS; exports.SelectAndMaskSession = SelectAndMaskSession; exports.SelectionGesture = SelectionGesture; exports.SelectionWorkerClient = _chunkX4LUGTQXcjs.SelectionWorkerClient; exports.ShapeDrawGesture = ShapeDrawGesture; exports.SmudgeTip = _chunkPQ3H2AANcjs.SmudgeTip; exports.StrokeCoverage = _chunkPQ3H2AANcjs.StrokeCoverage; exports.SurfaceDraft = _chunk474IQG74cjs.SurfaceDraft; exports.TEXT_ALIGNS = _chunkQE7D7TZRcjs.TEXT_ALIGNS; exports.TEXT_ORIENTATIONS = _chunkQE7D7TZRcjs.TEXT_ORIENTATIONS; exports.TEXT_RENDER_MARGIN = _chunkQE7D7TZRcjs.TEXT_RENDER_MARGIN; exports.TEXT_STYLE_FIELDS = _chunkQE7D7TZRcjs.TEXT_STYLE_FIELDS; exports.TILE = _chunk474IQG74cjs.TILE; exports.TILE_SHIFT = _chunk474IQG74cjs.TILE_SHIFT; exports.TINT_SCALE = _chunkQE7D7TZRcjs.TINT_SCALE; exports.TIP_GRADIENT_STEPS = _chunkPQ3H2AANcjs.TIP_GRADIENT_STEPS; exports.TONE_LUT_SIZE = _chunkQE7D7TZRcjs.TONE_LUT_SIZE; exports.TONE_RANGES = _chunk3EHPLDFQcjs.TONE_RANGES; exports.TONE_RANGE_PRESETS = TONE_RANGE_PRESETS; exports.TRANSFORM_ANCHORS = _chunkQE7D7TZRcjs.TRANSFORM_ANCHORS; exports.TRANSFORM_ROTATE_HANDLE_OFFSET = TRANSFORM_ROTATE_HANDLE_OFFSET; exports.TextEditSession = TextEditSession; exports.TileMedium = _chunkPQ3H2AANcjs.TileMedium; exports.TilePixelSource = _chunk3EHPLDFQcjs.TilePixelSource; exports.TileableNoise = _chunkPQ3H2AANcjs.TileableNoise; exports.TiledSurface = _chunk474IQG74cjs.TiledSurface; exports.TransformTooLargeError = _chunkUOGKSVRQcjs.TransformTooLargeError; exports.TransformedPixelSource = _chunk3EHPLDFQcjs.TransformedPixelSource; exports.TypeToolGesture = TypeToolGesture; exports.UNITS = _chunkX4LUGTQXcjs.UNITS; exports.U_MAX = _chunkKWNMBMKGcjs.U_MAX; exports.VIBRANCE_GREY = _chunkQE7D7TZRcjs.VIBRANCE_GREY; exports.W9 = _chunkKWNMBMKGcjs.W9; exports.WARP_GRID_OPTIONS = WARP_GRID_OPTIONS; exports.WARP_STYLES = _chunkQAUIZPYIcjs.WARP_STYLES; exports.WARP_STYLE_LABELS = _chunkQAUIZPYIcjs.WARP_STYLE_LABELS; exports.WARP_STYLE_OPTIONS = WARP_STYLE_OPTIONS; exports.WET_FLOW_KINDS = _chunkKWNMBMKGcjs.WET_FLOW_KINDS; exports.WET_PARAM_KEYS = _chunkKWNMBMKGcjs.WET_PARAM_KEYS; exports.WET_TILE = _chunkKWNMBMKGcjs.WET_TILE; exports.WGSL_HALO = _chunkKWNMBMKGcjs.WGSL_HALO; exports.WGSL_SHADE = _chunkKWNMBMKGcjs.WGSL_SHADE; exports.WGSL_STEP = _chunkKWNMBMKGcjs.WGSL_STEP; exports.WORKING_SPACE_OPTIONS = WORKING_SPACE_OPTIONS; exports.WORK_SIZE = _chunkX4LUGTQXcjs.WORK_SIZE; exports.WetGpuEngine = _chunkKWNMBMKGcjs.WetGpuEngine; exports.WetMedium = _chunkKWNMBMKGcjs.WetMedium; exports.WetWorkerPool = _chunkKWNMBMKGcjs.WetWorkerPool; exports.WetWorld = _chunkKWNMBMKGcjs.WetWorld; exports.WetWorldError = _chunkKWNMBMKGcjs.WetWorldError; exports.XYZ_D50_TO_SRGB = _chunkQE7D7TZRcjs.XYZ_D50_TO_SRGB; exports.ZlibError = _chunkXFM3OCHUcjs.ZlibError; exports.activeAdjustmentLayers = _chunkQE7D7TZRcjs.activeAdjustmentLayers; exports.activeEffectSmartFilters = _chunkQE7D7TZRcjs.activeEffectSmartFilters; exports.activeLayerAfterRemoval = _chunkQE7D7TZRcjs.activeLayerAfterRemoval; exports.activeSmartFilters = _chunkQE7D7TZRcjs.activeSmartFilters; exports.addLayerEffect = _chunkQE7D7TZRcjs.addLayerEffect; exports.addLayerFilter = _chunkQE7D7TZRcjs.addLayerFilter; exports.addLayerOfKind = addLayerOfKind; exports.addPaintGradientStop = _chunkPQ3H2AANcjs.addPaintGradientStop; exports.addSmartFilter = _chunkQE7D7TZRcjs.addSmartFilter; exports.addToHistogram = addToHistogram; exports.adjustmentKindLabel = _chunkQE7D7TZRcjs.adjustmentKindLabel; exports.adjustmentLayersKey = _chunkQE7D7TZRcjs.adjustmentLayersKey; exports.adjustmentNodeAsLayer = _chunkQE7D7TZRcjs.adjustmentNodeAsLayer; exports.adjustmentNodeFromLegacy = _chunkQE7D7TZRcjs.adjustmentNodeFromLegacy; exports.adler32 = _chunkXFM3OCHUcjs.adler32; exports.agentDragDraft = agentDragDraft; exports.anchorPoint = _chunkQE7D7TZRcjs.anchorPoint; exports.annotationBlend = _chunkQE7D7TZRcjs.annotationBlend; exports.annotationLayerFor = _chunkQE7D7TZRcjs.annotationLayerFor; exports.annotationLayerName = _chunkQE7D7TZRcjs.annotationLayerName; exports.annotationOfLayer = _chunkQE7D7TZRcjs.annotationOfLayer; exports.annotationOfShape = _chunkQE7D7TZRcjs.annotationOfShape; exports.annotationOfType = _chunkQE7D7TZRcjs.annotationOfType; exports.applyAdjustmentLayers = _chunkQE7D7TZRcjs.applyAdjustmentLayers; exports.applyAdjustmentLayersFloat = _chunkQE7D7TZRcjs.applyAdjustmentLayersFloat; exports.applyAdjustments = _chunkQE7D7TZRcjs.applyAdjustments; exports.applyBoxBlur = _chunkQE7D7TZRcjs.applyBoxBlur; exports.applyBoxBlurFloat = _chunkQE7D7TZRcjs.applyBoxBlurFloat; exports.applyDepthMask = _chunkQE7D7TZRcjs.applyDepthMask; exports.applyHomography = _chunkQT26RHKKcjs.applyHomography; exports.applyImageProjectionToContext = _chunkQE7D7TZRcjs.applyImageProjectionToContext; exports.applyLegacyAdjustments = _chunkQE7D7TZRcjs.applyLegacyAdjustments; exports.applyLegacyFloat = _chunkQE7D7TZRcjs.applyLegacyFloat; exports.applyMatrix3 = _chunkQE7D7TZRcjs.applyMatrix3; exports.applyOutputStage = applyOutputStage; exports.applyParams = _chunkQE7D7TZRcjs.applyParams; exports.applyProcess2Adjustments = _chunkQE7D7TZRcjs.applyProcess2Adjustments; exports.applyProcess2Float = _chunkQE7D7TZRcjs.applyProcess2Float; exports.applyRefineEdits = _chunkX4LUGTQXcjs.applyRefineEdits; exports.applyRegionBlur = applyRegionBlur; exports.applyRegionMosaic = applyRegionMosaic; exports.applyRetouchToTile = _chunk3EHPLDFQcjs.applyRetouchToTile; exports.applyShapeOptions = applyShapeOptions; exports.applySmartFilters = _chunkQE7D7TZRcjs.applySmartFilters; exports.applyStrokeToDeepTile = _chunkPQ3H2AANcjs.applyStrokeToDeepTile; exports.applyStrokeToTile = _chunkPQ3H2AANcjs.applyStrokeToTile; exports.applyToneToDeepTile = _chunk3EHPLDFQcjs.applyToneToDeepTile; exports.backgroundLayer = _chunkQE7D7TZRcjs.backgroundLayer; exports.base64ToBytes = _chunkOLNIPTB3cjs.base64ToBytes; exports.baseProjection = baseProjection; exports.bestOffset = _chunk3EHPLDFQcjs.bestOffset; exports.blackWhiteGray = _chunkQE7D7TZRcjs.blackWhiteGray; exports.blendChannel = _chunkOLNIPTB3cjs.blendChannel; exports.blendImageData = _chunkOLNIPTB3cjs.blendImageData; exports.blendLum = _chunkOLNIPTB3cjs.blendLum; exports.blendPixel = _chunkOLNIPTB3cjs.blendPixel; exports.blendRadius = _chunkPQ3H2AANcjs.blendRadius; exports.blendRgb = _chunkOLNIPTB3cjs.blendRgb; exports.blendTile = _chunkUOGKSVRQcjs.blendTile; exports.blenderDab = _chunkPQ3H2AANcjs.blenderDab; exports.blurFilter = _chunkQE7D7TZRcjs.blurFilter; exports.borderCoverage = _chunkQYLWG22Ncjs.borderCoverage; exports.boxBlur = _chunkX4LUGTQXcjs.boxBlur; exports.boxBlurPixels = _chunk3EHPLDFQcjs.boxBlurPixels; exports.boxFrameHit = boxFrameHit; exports.boxFrameOverlay = boxFrameOverlay; exports.boxMean = _chunkX4LUGTQXcjs.boxMean; exports.boxPointOf = _chunkQE7D7TZRcjs.boxPointOf; exports.boxQuad = _chunkQT26RHKKcjs.boxQuad; exports.boxToCurvePoint = boxToCurvePoint; exports.bradfordAdaptation = _chunkQE7D7TZRcjs.bradfordAdaptation; exports.brushStrokeMask = _chunkX4LUGTQXcjs.brushStrokeMask; exports.brushstrokeDataUrl = _chunkPQ3H2AANcjs.brushstrokeDataUrl; exports.brushstrokeKey = _chunkPQ3H2AANcjs.brushstrokeKey; exports.brushstrokeSamples = _chunkPQ3H2AANcjs.brushstrokeSamples; exports.brushstrokeScaleBucket = _chunkYQGCPL5Xcjs.brushstrokeScaleBucket; exports.brushstrokeStrokeOptions = _chunkPQ3H2AANcjs.brushstrokeStrokeOptions; exports.brushstrokeToCanvas = _chunkPQ3H2AANcjs.brushstrokeToCanvas; exports.buildLayerMaskPlanes = _chunkQE7D7TZRcjs.buildLayerMaskPlanes; exports.buildToneLut = _chunkQE7D7TZRcjs.buildToneLut; exports.builtinPattern = _chunkUOGKSVRQcjs.builtinPattern; exports.builtinPatternIds = _chunkUOGKSVRQcjs.builtinPatternIds; exports.bytesToBase64 = _chunkOLNIPTB3cjs.bytesToBase64; exports.calculateCropDrag = _chunkQE7D7TZRcjs.calculateCropDrag; exports.canShareMemory = _chunkKWNMBMKGcjs.canShareMemory; exports.canvasCompositeOperation = _chunkOLNIPTB3cjs.canvasCompositeOperation; exports.canvasToImagePoint = _chunkQE7D7TZRcjs.canvasToImagePoint; exports.caretAt = _chunkQAUIZPYIcjs.caretAt; exports.changedTiles = _chunkUOGKSVRQcjs.changedTiles; exports.channelThumbnail = channelThumbnail; exports.checkEffectAnimation = checkEffectAnimation; exports.checkEffectTime = checkEffectTime; exports.checkImageEffectPlace = checkImageEffectPlace; exports.clampControlValue = clampControlValue; exports.clampCropToImage = _chunkQE7D7TZRcjs.clampCropToImage; exports.cleanMixer = _chunkPQ3H2AANcjs.cleanMixer; exports.cloneSamplePoint = _chunk3EHPLDFQcjs.cloneSamplePoint; exports.cloneSourceLabel = cloneSourceLabel; exports.cloneTransformView = cloneTransformView; exports.collectTiles = _chunk474IQG74cjs.collectTiles; exports.colorBalanceChannel = _chunkQE7D7TZRcjs.colorBalanceChannel; exports.colorModePlanes = colorModePlanes; exports.colorModePlanes16 = colorModePlanes16; exports.colorPanelView = colorPanelView; exports.colorRange = colorRange; exports.colorRangePreset = colorRangePreset; exports.combineSelections = _chunkQYLWG22Ncjs.combineSelections; exports.compileAdjustmentLayer = _chunkQE7D7TZRcjs.compileAdjustmentLayer; exports.componentPath = _chunkQE7D7TZRcjs.componentPath; exports.componentsCoverage = _chunkQE7D7TZRcjs.componentsCoverage; exports.compositeDeep = _chunkQE7D7TZRcjs.compositeDeep; exports.compositeSurfaceOver = _chunkUOGKSVRQcjs.compositeSurfaceOver; exports.computeHistogram = computeHistogram; exports.computeSelectionBounds = _chunkQYLWG22Ncjs.computeSelectionBounds; exports.contentAwareFill = _chunk3EHPLDFQcjs.contentAwareFill; exports.contentBounds = _chunk474IQG74cjs.contentBounds; exports.contentsBox = _chunkQE7D7TZRcjs.contentsBox; exports.contentsSurface = _chunkQE7D7TZRcjs.contentsSurface; exports.contractCoverage = _chunkQYLWG22Ncjs.contractCoverage; exports.controlPosition = controlPosition; exports.controlTrackBackground = controlTrackBackground; exports.convertColorFields = convertColorFields; exports.convertHex = convertHex; exports.convertSurfaceColors = convertSurfaceColors; exports.convertSurfaceDepth = _chunkOLNIPTB3cjs.convertSurfaceDepth; exports.convertToSmartObject = _chunkQE7D7TZRcjs.convertToSmartObject; exports.copySmartObject = _chunkQE7D7TZRcjs.copySmartObject; exports.cornersFromMatrix = _chunkQE7D7TZRcjs.cornersFromMatrix; exports.coverageTileCoord = _chunkPQ3H2AANcjs.coverageTileCoord; exports.coverageToByte = _chunkQYLWG22Ncjs.coverageToByte; exports.coveringRect = coveringRect; exports.createAdjustmentLayer = _chunkQE7D7TZRcjs.createAdjustmentLayer; exports.createBlenderScratch = _chunkPQ3H2AANcjs.createBlenderScratch; exports.createCanvasTextShaper = _chunkQAUIZPYIcjs.createCanvasTextShaper; exports.createImageCaptureSurface = createImageCaptureSurface; exports.createImageColorTools = createImageColorTools; exports.createImageEditTools = createImageEditTools; exports.createImageEditorDocument = createImageEditorDocument; exports.createImageEditorToolProvider = createImageEditorToolProvider; exports.createImageEffectTools = createImageEffectTools; exports.createImageEffectsToolProvider = createImageEffectsToolProvider; exports.createImageLayerTools = createImageLayerTools; exports.createImagePaintTools = createImagePaintTools; exports.createImagePlaybackLocator = createImagePlaybackLocator; exports.createImagePsdTools = createImagePsdTools; exports.createImageRetouchTools = createImageRetouchTools; exports.createImageSegmentationToolProvider = createImageSegmentationToolProvider; exports.createImageSelectionTools = createImageSelectionTools; exports.createImageShapeTools = createImageShapeTools; exports.createImageSmartObjectTools = createImageSmartObjectTools; exports.createImageSubjectSelectionTool = createImageSubjectSelectionTool; exports.createImageTransformTools = createImageTransformTools; exports.createImageTypeTools = createImageTypeTools; exports.createMetricTextShaper = _chunkQAUIZPYIcjs.createMetricTextShaper; exports.createOutlineTextShaper = _chunkQAUIZPYIcjs.createOutlineTextShaper; exports.createPigment = _chunkOLNIPTB3cjs.createPigment; exports.createPigmentTools = _chunkKWNMBMKGcjs.createPigmentTools; exports.createSelectionMask = _chunkQYLWG22Ncjs.createSelectionMask; exports.createShapeLayer = _chunkQE7D7TZRcjs.createShapeLayer; exports.createTypeLayer = _chunkQE7D7TZRcjs.createTypeLayer; exports.createWetGpuEngine = _chunkKWNMBMKGcjs.createWetGpuEngine; exports.cssFont = _chunkQAUIZPYIcjs.cssFont; exports.cssFontFamily = _chunkQAUIZPYIcjs.cssFontFamily; exports.curveLut = _chunkUOGKSVRQcjs.curveLut; exports.curveLutFromLevels = _chunkQE7D7TZRcjs.curveLutFromLevels; exports.curvePointToBox = curvePointToBox; exports.curveSvgPath = curveSvgPath; exports.dabCoverage = _chunkPQ3H2AANcjs.dabCoverage; exports.dabRect = _chunkPQ3H2AANcjs.dabRect; exports.decodeDeepSurface = _chunkQE7D7TZRcjs.decodeDeepSurface; exports.decodeLayerChannel = _chunkQE7D7TZRcjs.decodeLayerChannel; exports.decodeLayerMask = _chunkQE7D7TZRcjs.decodeLayerMask; exports.decodeMergedImage = _chunkQE7D7TZRcjs.decodeMergedImage; exports.decodePlanes = _chunkQE7D7TZRcjs.decodePlanes; exports.decodePng = _chunkOLNIPTB3cjs.decodePng; exports.decodePngDataUrl = _chunkQE7D7TZRcjs.decodePngDataUrl; exports.decodeSelectionRle = _chunkQYLWG22Ncjs.decodeSelectionRle; exports.decontaminateColors = _chunkX4LUGTQXcjs.decontaminateColors; exports.deepBytes = _chunkOLNIPTB3cjs.deepBytes; exports.deepTile = _chunkOLNIPTB3cjs.deepTile; exports.defaultActiveLayerId = _chunkQE7D7TZRcjs.defaultActiveLayerId; exports.defaultAdjustmentParams = _chunkQE7D7TZRcjs.defaultAdjustmentParams; exports.defaultEffectGradient = _chunkUOGKSVRQcjs.defaultEffectGradient; exports.defaultLayerEffect = _chunkUOGKSVRQcjs.defaultLayerEffect; exports.defaultShapeName = _chunkQE7D7TZRcjs.defaultShapeName; exports.deflate = _chunkXFM3OCHUcjs.deflate; exports.deflateRaw = _chunkXFM3OCHUcjs.deflateRaw; exports.depthMaskAlpha = _chunkQE7D7TZRcjs.depthMaskAlpha; exports.depthOf = _chunkOLNIPTB3cjs.depthOf; exports.depthRasterMask = _chunkQE7D7TZRcjs.depthRasterMask; exports.describeChannel = describeChannel; exports.describeLayer = describeLayer; exports.describeLayerEffects = describeLayerEffects; exports.describeSelection = describeSelection; exports.describeTransform = _chunkQE7D7TZRcjs.describeTransform; exports.deserializeChannels = deserializeChannels; exports.deserializeColorMode = deserializeColorMode; exports.deserializeColorProfile = deserializeColorProfile; exports.deserializeEffects = _chunkQE7D7TZRcjs.deserializeEffects; exports.deserializeLayer = _chunkQE7D7TZRcjs.deserializeLayer; exports.deserializeLayers = _chunkQE7D7TZRcjs.deserializeLayers; exports.deserializeMask = _chunkX4LUGTQXcjs.deserializeMask; exports.deserializePatterns = _chunkQE7D7TZRcjs.deserializePatterns; exports.deserializeSelection = _chunkQYLWG22Ncjs.deserializeSelection; exports.developFilter = _chunkQE7D7TZRcjs.developFilter; exports.developFromAdjustments = _chunkQE7D7TZRcjs.developFromAdjustments; exports.developTarget = _chunkQE7D7TZRcjs.developTarget; exports.dexp = _chunkKWNMBMKGcjs.dexp; exports.dilateMask = _chunk3EHPLDFQcjs.dilateMask; exports.displayTransform = displayTransform; exports.distanceTransform = _chunkQYLWG22Ncjs.distanceTransform; exports.dlog = _chunkKWNMBMKGcjs.dlog; exports.documentContents = _chunkQE7D7TZRcjs.documentContents; exports.documentProfile = documentProfile; exports.dodgeBurn = _chunk3EHPLDFQcjs.dodgeBurn; exports.dodgeBurnCurve = _chunk3EHPLDFQcjs.dodgeBurnCurve; exports.downloadMaskImage = downloadMaskImage; exports.downloadPsd = downloadPsd; exports.dpow = _chunkKWNMBMKGcjs.dpow; exports.dragWarpMeshPoint = _chunkQAUIZPYIcjs.dragWarpMeshPoint; exports.dropPlacement = dropPlacement; exports.dropZone = dropZone; exports.dsincos = _chunkKWNMBMKGcjs.dsincos; exports.duplicateLayer = _chunkQE7D7TZRcjs.duplicateLayer; exports.edgeBits = _chunkKWNMBMKGcjs.edgeBits; exports.edgeWidth = _chunkX4LUGTQXcjs.edgeWidth; exports.effectColorHex = _chunkUOGKSVRQcjs.effectColorHex; exports.effectControlChange = effectControlChange; exports.effectLayerTiming = effectLayerTiming; exports.effectPixelsToSurface = effectPixelsToSurface; exports.effectReach = _chunkUOGKSVRQcjs.effectReach; exports.effectiveLayerMask = _chunkQE7D7TZRcjs.effectiveLayerMask; exports.effectiveProof = effectiveProof; exports.effectsFingerprint = _chunkUOGKSVRQcjs.effectsFingerprint; exports.effectsMargin = _chunkUOGKSVRQcjs.effectsMargin; exports.effectsScale = _chunkUOGKSVRQcjs.effectsScale; exports.ellipsePoints = _chunkX4LUGTQXcjs.ellipsePoints; exports.ellipseSelection = _chunkX4LUGTQXcjs.ellipseSelection; exports.emptyHistogram = emptyHistogram; exports.emptySurface = _chunk474IQG74cjs.emptySurface; exports.encodeDeepSurface = _chunkQE7D7TZRcjs.encodeDeepSurface; exports.encodePng = _chunkOLNIPTB3cjs.encodePng; exports.encodeRle = _chunkQE7D7TZRcjs.encodeRle; exports.encodeSelectionRle = _chunkQYLWG22Ncjs.encodeSelectionRle; exports.encodeSurface = _chunkQE7D7TZRcjs.encodeSurface; exports.evalWarpMesh = _chunkQAUIZPYIcjs.evalWarpMesh; exports.evaluateAdjustmentLayers = _chunkQE7D7TZRcjs.evaluateAdjustmentLayers; exports.exchangeRates = _chunkPQ3H2AANcjs.exchangeRates; exports.expNeg = _chunkKWNMBMKGcjs.expNeg; exports.expandCoverage = _chunkQYLWG22Ncjs.expandCoverage; exports.exportPsd = _chunkQE7D7TZRcjs.exportPsd; exports.extractNormalizedLayerItems = extractNormalizedLayerItems; exports.featherCoverage = _chunkQYLWG22Ncjs.featherCoverage; exports.fillRect = _chunk474IQG74cjs.fillRect; exports.filmPixel = _chunkKWNMBMKGcjs.filmPixel; exports.filmReflectance = _chunkKWNMBMKGcjs.filmReflectance; exports.filterMaskCoverage = _chunkQE7D7TZRcjs.filterMaskCoverage; exports.findAdjustmentControl = findAdjustmentControl; exports.findLayer = _chunkUOGKSVRQcjs.findLayer; exports.findLayerControl = findLayerControl; exports.findSky = _chunkX4LUGTQXcjs.findSky; exports.findSubject = _chunkX4LUGTQXcjs.findSubject; exports.findWebGpu = _chunkKWNMBMKGcjs.findWebGpu; exports.finishTile = _chunk474IQG74cjs.finishTile; exports.fitParagraphRuns = _chunkQAUIZPYIcjs.fitParagraphRuns; exports.fitRuns = _chunkQAUIZPYIcjs.fitRuns; exports.flattenLayers = _chunkUOGKSVRQcjs.flattenLayers; exports.flattenPath = _chunkQE7D7TZRcjs.flattenPath; exports.flipCorners = _chunkQE7D7TZRcjs.flipCorners; exports.flowField = _chunkKWNMBMKGcjs.flowField; exports.focusArea = _chunkX4LUGTQXcjs.focusArea; exports.followLayerMove = _chunkQE7D7TZRcjs.followLayerMove; exports.fontOf = _chunkQAUIZPYIcjs.fontOf; exports.forgetSelectAndMaskSettings = forgetSelectAndMaskSettings; exports.formatControlValue = formatControlValue; exports.fullSelection = _chunkQYLWG22Ncjs.fullSelection; exports.gaussianBlur = _chunkK6PXS6DOcjs.gaussianBlur; exports.geometryHomography = _chunkQE7D7TZRcjs.geometryHomography; exports.getAnnotationBounds = _chunkQE7D7TZRcjs.getAnnotationBounds; exports.getControlPath = getControlPath; exports.getCropCursor = _chunkQE7D7TZRcjs.getCropCursor; exports.getRotatedSize = _chunkQE7D7TZRcjs.getRotatedSize; exports.getViewportMetrics = _chunkQE7D7TZRcjs.getViewportMetrics; exports.getViewportProjection = _chunkQE7D7TZRcjs.getViewportProjection; exports.globalImageCache = globalImageCache; exports.grabCutLabels = _chunkX4LUGTQXcjs.grabCutLabels; exports.gradientDabColor = _chunkPQ3H2AANcjs.gradientDabColor; exports.grainCatch = _chunkPQ3H2AANcjs.grainCatch; exports.grainHeights = _chunkPQ3H2AANcjs.grainHeights; exports.greyMorphology = _chunkQYLWG22Ncjs.greyMorphology; exports.groupLayers = _chunkQE7D7TZRcjs.groupLayers; exports.growSelection = growSelection; exports.guidePlanes = _chunkX4LUGTQXcjs.guidePlanes; exports.guidedFilterColor = _chunkX4LUGTQXcjs.guidedFilterColor; exports.handleMaskViewKey = handleMaskViewKey; exports.handlePaintShortcut = handlePaintShortcut; exports.handleQuickMaskKey = handleQuickMaskKey; exports.handleSelectionShortcut = handleSelectionShortcut; exports.hasActiveEffects = _chunkUOGKSVRQcjs.hasActiveEffects; exports.hasLayersBelow = hasLayersBelow; exports.hasResampledLegacyMask = _chunkQE7D7TZRcjs.hasResampledLegacyMask; exports.hasSurface = _chunkQE7D7TZRcjs.hasSurface; exports.hasWarp = _chunkQE7D7TZRcjs.hasWarp; exports.hash2 = _chunkPQ3H2AANcjs.hash2; exports.hashMaskContent = _chunkQYLWG22Ncjs.hashMaskContent; exports.hashNoise = _chunkUOGKSVRQcjs.hashNoise; exports.healPixels = _chunk3EHPLDFQcjs.healPixels; exports.hexToPaintRgb = _chunkPQ3H2AANcjs.hexToPaintRgb; exports.hexToRgb = _chunkQE7D7TZRcjs.hexToRgb; exports.histogramPath = histogramPath; exports.hitTestAnnotation = _chunkQE7D7TZRcjs.hitTestAnnotation; exports.hitTestCrop = _chunkQE7D7TZRcjs.hitTestCrop; exports.hitTestCurvePoint = hitTestCurvePoint; exports.homographyFromAffine = _chunkQT26RHKKcjs.homographyFromAffine; exports.homographyFromPoints = _chunkQT26RHKKcjs.homographyFromPoints; exports.hslToRgb = _chunkQE7D7TZRcjs.hslToRgb; exports.hueRange = hueRange; exports.hueRangeTables = _chunkQE7D7TZRcjs.hueRangeTables; exports.hueRangeWeight = _chunkQE7D7TZRcjs.hueRangeWeight; exports.hueSaturation = _chunkQE7D7TZRcjs.hueSaturation; exports.identityCurve = _chunkQE7D7TZRcjs.identityCurve; exports.identityLevels = _chunkQE7D7TZRcjs.identityLevels; exports.identityTransform = _chunkQE7D7TZRcjs.identityTransform; exports.identityWarpMesh = _chunkQAUIZPYIcjs.identityWarpMesh; exports.imageEditorStateMigrations = imageEditorStateMigrations; exports.imageLayerAppliedEffects = imageLayerAppliedEffects; exports.imagePanelTool = imagePanelTool; exports.imagePlaybackPanel = imagePlaybackPanel; exports.imageToCanvasPoint = _chunkQE7D7TZRcjs.imageToCanvasPoint; exports.imageToolCanvasMode = imageToolCanvasMode; exports.imageToolForShortcut = imageToolForShortcut; exports.imageToolGroup = imageToolGroup; exports.imageToolLabel = imageToolLabel; exports.imageToolPanel = imageToolPanel; exports.importPsd = _chunkQE7D7TZRcjs.importPsd; exports.inflate = _chunkXFM3OCHUcjs.inflate; exports.inflateRaw = _chunkXFM3OCHUcjs.inflateRaw; exports.insertCurvePoint = insertCurvePoint; exports.insertLayer = _chunkUOGKSVRQcjs.insertLayer; exports.instancesOf = _chunkQE7D7TZRcjs.instancesOf; exports.invertHomography = _chunkQT26RHKKcjs.invertHomography; exports.invertMatrix3 = _chunkQE7D7TZRcjs.invertMatrix3; exports.invertSelection = _chunkQYLWG22Ncjs.invertSelection; exports.isActiveFilter = _chunkQE7D7TZRcjs.isActiveFilter; exports.isActiveVectorMask = _chunkQE7D7TZRcjs.isActiveVectorMask; exports.isAdjustmentKind = _chunkQE7D7TZRcjs.isAdjustmentKind; exports.isBitDepth = _chunkOLNIPTB3cjs.isBitDepth; exports.isBlendMode = _chunkOLNIPTB3cjs.isBlendMode; exports.isBrushstrokeBrush = _chunkPQ3H2AANcjs.isBrushstrokeBrush; exports.isColorRangePreset = isColorRangePreset; exports.isContentsDecoded = _chunkQE7D7TZRcjs.isContentsDecoded; exports.isDefaultDepthMask = _chunkQE7D7TZRcjs.isDefaultDepthMask; exports.isGradientPaint = _chunkPQ3H2AANcjs.isGradientPaint; exports.isIdentityCloneTransform = _chunk3EHPLDFQcjs.isIdentityCloneTransform; exports.isIdentityTransform = _chunkQE7D7TZRcjs.isIdentityTransform; exports.isInterpolation = _chunkUOGKSVRQcjs.isInterpolation; exports.isLayerEffectKind = _chunkUOGKSVRQcjs.isLayerEffectKind; exports.isLayerLocked = _chunkUOGKSVRQcjs.isLayerLocked; exports.isLegacyShape = _chunkQE7D7TZRcjs.isLegacyShape; exports.isPaintTool = isPaintTool; exports.isPaintableLayer = _chunkQE7D7TZRcjs.isPaintableLayer; exports.isPainterlyBlendMode = _chunkOLNIPTB3cjs.isPainterlyBlendMode; exports.isPng = _chunkOLNIPTB3cjs.isPng; exports.isQuarterTurn = isQuarterTurn; exports.isQuarterTurnSwapped = _chunkQE7D7TZRcjs.isQuarterTurnSwapped; exports.isRenderedLayer = _chunkQE7D7TZRcjs.isRenderedLayer; exports.isRetouchPaintTool = isRetouchPaintTool; exports.isRetouchTool = isRetouchTool; exports.isSelectionEmpty = _chunkQYLWG22Ncjs.isSelectionEmpty; exports.isSelectionMode = _chunkQYLWG22Ncjs.isSelectionMode; exports.isSeparableBlendMode = _chunkOLNIPTB3cjs.isSeparableBlendMode; exports.isSmartSurfaceIncomplete = _chunkQE7D7TZRcjs.isSmartSurfaceIncomplete; exports.isSpatialFilter = _chunkQE7D7TZRcjs.isSpatialFilter; exports.isSrgb = isSrgb; exports.isTransformAnchor = _chunkQE7D7TZRcjs.isTransformAnchor; exports.isValidWarp = _chunkQE7D7TZRcjs.isValidWarp; exports.keepDeepSamples = _chunkOLNIPTB3cjs.keepDeepSamples; exports.keepMainPieces = _chunkX4LUGTQXcjs.keepMainPieces; exports.kelvinToTemperature = _chunkQE7D7TZRcjs.kelvinToTemperature; exports.keysWeight = _chunkUOGKSVRQcjs.keysWeight; exports.latticeViscosity = _chunkKWNMBMKGcjs.latticeViscosity; exports.layerBadge = layerBadge; exports.layerEffectControls = layerEffectControls; exports.layerEffectFields = _chunkUOGKSVRQcjs.layerEffectFields; exports.layerEffectLabel = _chunkUOGKSVRQcjs.layerEffectLabel; exports.layerEffectsBadge = layerEffectsBadge; exports.layerEffectsOf = _chunkQE7D7TZRcjs.layerEffectsOf; exports.layerEffectsPanel = layerEffectsPanel; exports.layerHasThumbnail = layerHasThumbnail; exports.layerLabel = layerLabel; exports.layerMaskCoverage = _chunkQE7D7TZRcjs.layerMaskCoverage; exports.layerMaskFromSelection = _chunkQE7D7TZRcjs.layerMaskFromSelection; exports.layerMaskKey = _chunkQE7D7TZRcjs.layerMaskKey; exports.layerMaskSelection = _chunkQE7D7TZRcjs.layerMaskSelection; exports.layerMenu = layerMenu; exports.layerName = _chunkQE7D7TZRcjs.layerName; exports.layerPanelRows = layerPanelRows; exports.layerPanels = layerPanels; exports.layerThumbnailClick = layerThumbnailClick; exports.layerTree = _chunkQE7D7TZRcjs.layerTree; exports.layerTypeLabel = _chunkQE7D7TZRcjs.layerTypeLabel; exports.layerWarning = layerWarning; exports.layersFromLegacy = _chunkQE7D7TZRcjs.layersFromLegacy; exports.layoutText = _chunkQAUIZPYIcjs.layoutText; exports.legacyAdjustmentLayer = _chunkQE7D7TZRcjs.legacyAdjustmentLayer; exports.legacyMaskOf = _chunkQE7D7TZRcjs.legacyMaskOf; exports.legacyView = _chunkQE7D7TZRcjs.legacyView; exports.lerpPigment = _chunkOLNIPTB3cjs.lerpPigment; exports.lerpPigmentInto = _chunkOLNIPTB3cjs.lerpPigmentInto; exports.levelsValue = _chunkQE7D7TZRcjs.levelsValue; exports.linearSrgbToXy = _chunkQE7D7TZRcjs.linearSrgbToXy; exports.linearToSrgb = _chunkQE7D7TZRcjs.linearToSrgb; exports.linearToSrgb8 = _chunkKWNMBMKGcjs.linearToSrgb8; exports.liveComponent = _chunkQE7D7TZRcjs.liveComponent; exports.liveShapeForDrag = liveShapeForDrag; exports.liveShapeSubpaths = _chunkQE7D7TZRcjs.liveShapeSubpaths; exports.liveWire = liveWire; exports.loadImageEditorDocument = loadImageEditorDocument; exports.loadMixer = _chunkPQ3H2AANcjs.loadMixer; exports.loadOpenTypeFont = _chunk3T5VCDIVcjs.loadOpenTypeFont; exports.loadWetKernel = _chunkKWNMBMKGcjs.loadWetKernel; exports.luma = _chunk3EHPLDFQcjs.luma; exports.magicWand = magicWand; exports.magneticAnchorSpacing = magneticAnchorSpacing; exports.mapCropHandle = _chunkQE7D7TZRcjs.mapCropHandle; exports.mapLayer = _chunkUOGKSVRQcjs.mapLayer; exports.mapSubpaths = _chunkQE7D7TZRcjs.mapSubpaths; exports.maskBounds = _chunk3EHPLDFQcjs.maskBounds; exports.maskFileName = maskFileName; exports.maskNameFromFile = maskNameFromFile; exports.maskSummary = maskSummary; exports.maskThumbnailClick = maskThumbnailClick; exports.matrixFromCorners = _chunkQE7D7TZRcjs.matrixFromCorners; exports.matrixFromParams = _chunkQE7D7TZRcjs.matrixFromParams; exports.measureCanvasViewport = measureCanvasViewport; exports.membraneFill = _chunk3EHPLDFQcjs.membraneFill; exports.mergeLayerEffect = _chunkUOGKSVRQcjs.mergeLayerEffect; exports.mergeShapeComponents = _chunkQE7D7TZRcjs.mergeShapeComponents; exports.migrateSerializedImageEditorState = migrateSerializedImageEditorState; exports.migrateToLayeredState = migrateToLayeredState; exports.mix32 = _chunkPQ3H2AANcjs.mix32; exports.mixPigment8 = _chunkOLNIPTB3cjs.mixPigment8; exports.mixPigmentRgb = _chunkOLNIPTB3cjs.mixPigmentRgb; exports.mixPigments = _chunkOLNIPTB3cjs.mixPigments; exports.mixerLoadResult = mixerLoadResult; exports.mixerRates = _chunkPQ3H2AANcjs.mixerRates; exports.modifySelection = _chunkQYLWG22Ncjs.modifySelection; exports.moveCurvePoint = moveCurvePoint; exports.moveLayer = _chunkQE7D7TZRcjs.moveLayer; exports.moveSmartFilter = _chunkQE7D7TZRcjs.moveSmartFilter; exports.mulMatrix3 = _chunkQE7D7TZRcjs.mulMatrix3; exports.needsLegacyBase = needsLegacyBase; exports.neutralHueRange = _chunkQE7D7TZRcjs.neutralHueRange; exports.newContentsId = _chunkQE7D7TZRcjs.newContentsId; exports.newEffectId = _chunkUOGKSVRQcjs.newEffectId; exports.newLayerId = _chunkQE7D7TZRcjs.newLayerId; exports.newLayerOptions = newLayerOptions; exports.normalizeAdjustmentLayer = _chunkQE7D7TZRcjs.normalizeAdjustmentLayer; exports.normalizeAdjustmentLayers = _chunkQE7D7TZRcjs.normalizeAdjustmentLayers; exports.normalizeAngle = _chunkQE7D7TZRcjs.normalizeAngle; exports.normalizeBlendMode = _chunkOLNIPTB3cjs.normalizeBlendMode; exports.normalizeBlender = _chunkPQ3H2AANcjs.normalizeBlender; exports.normalizeBrush = _chunkPQ3H2AANcjs.normalizeBrush; exports.normalizeFilter = _chunkQE7D7TZRcjs.normalizeFilter; exports.normalizeFlow = _chunkKWNMBMKGcjs.normalizeFlow; exports.normalizeHexColor = _chunkPQ3H2AANcjs.normalizeHexColor; exports.normalizeLayerEffects = _chunkUOGKSVRQcjs.normalizeLayerEffects; exports.normalizeLayerMask = _chunkQE7D7TZRcjs.normalizeLayerMask; exports.normalizeLiveShape = _chunkQE7D7TZRcjs.normalizeLiveShape; exports.normalizeMixer = _chunkPQ3H2AANcjs.normalizeMixer; exports.normalizePlacement = _chunkQE7D7TZRcjs.normalizePlacement; exports.normalizeProcessVersion = _chunkQE7D7TZRcjs.normalizeProcessVersion; exports.normalizeRect = _chunkX4LUGTQXcjs.normalizeRect; exports.normalizeRefineEdgeParams = _chunkX4LUGTQXcjs.normalizeRefineEdgeParams; exports.normalizeRetouch = _chunk3EHPLDFQcjs.normalizeRetouch; exports.normalizeShapePaint = _chunkQE7D7TZRcjs.normalizeShapePaint; exports.normalizeShapeStroke = _chunkQE7D7TZRcjs.normalizeShapeStroke; exports.normalizeSmartFilter = _chunkQE7D7TZRcjs.normalizeSmartFilter; exports.normalizeSmudge = _chunkPQ3H2AANcjs.normalizeSmudge; exports.normalizeStoredAdjustments = normalizeStoredAdjustments; exports.normalizeSubpaths = _chunkQE7D7TZRcjs.normalizeSubpaths; exports.normalizeText = _chunkQE7D7TZRcjs.normalizeText; exports.normalizeTilt = _chunkKWNMBMKGcjs.normalizeTilt; exports.normalizeWetParams = _chunkKWNMBMKGcjs.normalizeWetParams; exports.offsetLayer = _chunkQE7D7TZRcjs.offsetLayer; exports.offsetShape = _chunkQE7D7TZRcjs.offsetShape; exports.offsetSmartObject = _chunkQE7D7TZRcjs.offsetSmartObject; exports.offsetVectorMask = _chunkQE7D7TZRcjs.offsetVectorMask; exports.openMaskFile = openMaskFile; exports.openPsdFile = openPsdFile; exports.otsuThreshold = _chunkX4LUGTQXcjs.otsuThreshold; exports.packRgba = _chunk474IQG74cjs.packRgba; exports.packWetParams = _chunkKWNMBMKGcjs.packWetParams; exports.paintGradientMappingFor = _chunkPQ3H2AANcjs.paintGradientMappingFor; exports.paintPathStroke = _chunkPQ3H2AANcjs.paintPathStroke; exports.paintSourceColor = _chunkPQ3H2AANcjs.paintSourceColor; exports.paintSourceCss = _chunkPQ3H2AANcjs.paintSourceCss; exports.paragraphRanges = _chunkQAUIZPYIcjs.paragraphRanges; exports.parseAdjustmentBlock = _chunkQE7D7TZRcjs.parseAdjustmentBlock; exports.parseBlend = _chunkQE7D7TZRcjs.parseBlend; exports.parseColor = parseColor; exports.parseCssColor = _chunkA2IS7EHEcjs.parseCssColor; exports.parseDataUrl = _chunkOLNIPTB3cjs.parseDataUrl; exports.parseEffectColor = _chunkUOGKSVRQcjs.parseEffectColor; exports.parseLfx2 = _chunkQE7D7TZRcjs.parseLfx2; exports.parseLrfx = _chunkQE7D7TZRcjs.parseLrfx; exports.parseOpenTypeFont = _chunk3T5VCDIVcjs.parseOpenTypeFont; exports.parsePaintSource = _chunkPQ3H2AANcjs.parsePaintSource; exports.parsePatternBlock = _chunkQE7D7TZRcjs.parsePatternBlock; exports.parseSelectionMode = _chunkQYLWG22Ncjs.parseSelectionMode; exports.parseVersionedDescriptor = _chunkQE7D7TZRcjs.parseVersionedDescriptor; exports.patchParagraphStyle = _chunkQE7D7TZRcjs.patchParagraphStyle; exports.patchTextStyle = _chunkQE7D7TZRcjs.patchTextStyle; exports.pathStrokeCoverage = _chunkPQ3H2AANcjs.pathStrokeCoverage; exports.pathStrokeDabs = _chunkPQ3H2AANcjs.pathStrokeDabs; exports.pathToSelection = pathToSelection; exports.perDabStrength = _chunk3EHPLDFQcjs.perDabStrength; exports.photoFilterMatrix = _chunkQE7D7TZRcjs.photoFilterMatrix; exports.pigment8 = _chunkOLNIPTB3cjs.pigment8; exports.pigmentColor = _chunkKWNMBMKGcjs.pigmentColor; exports.pigmentOf = _chunkKWNMBMKGcjs.pigmentOf; exports.pixelLayerBounds = _chunkQE7D7TZRcjs.pixelLayerBounds; exports.pixelLayers = _chunkQE7D7TZRcjs.pixelLayers; exports.pixelPigment = _chunkKWNMBMKGcjs.pixelPigment; exports.placeContents = _chunkQE7D7TZRcjs.placeContents; exports.placeLayer = _chunkQE7D7TZRcjs.placeLayer; exports.placementAt = _chunkQE7D7TZRcjs.placementAt; exports.placementBounds = _chunkQE7D7TZRcjs.placementBounds; exports.placementGeometry = _chunkQE7D7TZRcjs.placementGeometry; exports.planImageToolPlayback = planImageToolPlayback; exports.planOutlineTrace = planOutlineTrace; exports.pngDataUrl = _chunkOLNIPTB3cjs.pngDataUrl; exports.pointerPressure = _chunkKWNMBMKGcjs.pointerPressure; exports.pointerStrokeSample = _chunkKWNMBMKGcjs.pointerStrokeSample; exports.pointerStrokeSamples = _chunkKWNMBMKGcjs.pointerStrokeSamples; exports.polygonCoverage = _chunkX4LUGTQXcjs.polygonCoverage; exports.polygonCoverageBox = _chunkX4LUGTQXcjs.polygonCoverageBox; exports.polygonSelection = _chunkX4LUGTQXcjs.polygonSelection; exports.posterizeValue = _chunkQE7D7TZRcjs.posterizeValue; exports.presetWarp = _chunkQE7D7TZRcjs.presetWarp; exports.previewStep = previewStep; exports.profileBytes = profileBytes; exports.projectImagePoint = _chunkQE7D7TZRcjs.projectImagePoint; exports.projectImageRect = _chunkQE7D7TZRcjs.projectImageRect; exports.projectMaskCoverage = _chunkQE7D7TZRcjs.projectMaskCoverage; exports.projectQuarterTurn = projectQuarterTurn; exports.proxyOf = _chunkOLNIPTB3cjs.proxyOf; exports.psdBytesFromBase64 = psdBytesFromBase64; exports.psdFileName = psdFileName; exports.psdPatternToEffectPattern = _chunkQE7D7TZRcjs.psdPatternToEffectPattern; exports.psdToLayers = _chunkQE7D7TZRcjs.psdToLayers; exports.pullWarpMesh = _chunkQAUIZPYIcjs.pullWarpMesh; exports.put255 = _chunkPQ3H2AANcjs.put255; exports.quadFrameOverlay = quadFrameOverlay; exports.quickMaskPixels = quickMaskPixels; exports.quickSelectStroke = _chunkX4LUGTQXcjs.quickSelectStroke; exports.rand01 = _chunkPQ3H2AANcjs.rand01; exports.randSigned = _chunkPQ3H2AANcjs.randSigned; exports.rangeLightness = _chunkQE7D7TZRcjs.rangeLightness; exports.rasterContents = _chunkQE7D7TZRcjs.rasterContents; exports.rasterMaskFromLegacy = _chunkQE7D7TZRcjs.rasterMaskFromLegacy; exports.rasterizeCoverage = _chunkQE7D7TZRcjs.rasterizeCoverage; exports.rasterizeDab = _chunkPQ3H2AANcjs.rasterizeDab; exports.rasterizeSmartObject = _chunkQE7D7TZRcjs.rasterizeSmartObject; exports.readAdjustmentControls = readAdjustmentControls; exports.readDeepRegion = _chunkOLNIPTB3cjs.readDeepRegion; exports.readPaintSource = _chunkPQ3H2AANcjs.readPaintSource; exports.readPixel = _chunk474IQG74cjs.readPixel; exports.readPsd = _chunkQE7D7TZRcjs.readPsd; exports.readRegion = _chunk474IQG74cjs.readRegion; exports.readSourceRegion = _chunk3EHPLDFQcjs.readSourceRegion; exports.rectSelection = _chunkX4LUGTQXcjs.rectSelection; exports.rectToQuad = _chunkQT26RHKKcjs.rectToQuad; exports.reduceSurface = _chunkUOGKSVRQcjs.reduceSurface; exports.referencePoint = _chunkQE7D7TZRcjs.referencePoint; exports.refineCoverage = _chunkX4LUGTQXcjs.refineCoverage; exports.refineEdgeHalo = _chunkX4LUGTQXcjs.refineEdgeHalo; exports.refineSelection = _chunkX4LUGTQXcjs.refineSelection; exports.reflectanceToRgb = _chunkOLNIPTB3cjs.reflectanceToRgb; exports.removeAlpha = _chunkQE7D7TZRcjs.removeAlpha; exports.removeCurvePoint = removeCurvePoint; exports.removeLayer = _chunkQE7D7TZRcjs.removeLayer; exports.removeLayerEffect = _chunkQE7D7TZRcjs.removeLayerEffect; exports.removeLayerFilter = _chunkQE7D7TZRcjs.removeLayerFilter; exports.removePaintGradientStop = _chunkPQ3H2AANcjs.removePaintGradientStop; exports.removeSmartFilter = _chunkQE7D7TZRcjs.removeSmartFilter; exports.renderBrushstroke = _chunkPQ3H2AANcjs.renderBrushstroke; exports.renderLayerEffects = _chunkUOGKSVRQcjs.renderLayerEffects; exports.renderLayeredBase = renderLayeredBase; exports.renderShape = _chunkQE7D7TZRcjs.renderShape; exports.renderShapeRect = _chunkQE7D7TZRcjs.renderShapeRect; exports.renderSmartObject = _chunkQE7D7TZRcjs.renderSmartObject; exports.renderText = _chunkQE7D7TZRcjs.renderText; exports.replaceContents = _chunkQE7D7TZRcjs.replaceContents; exports.replaceTextRange = _chunkQE7D7TZRcjs.replaceTextRange; exports.requireLayer = _chunkQE7D7TZRcjs.requireLayer; exports.requireOperation = _chunkQE7D7TZRcjs.requireOperation; exports.requireShapeLayer = _chunkQE7D7TZRcjs.requireShapeLayer; exports.requireSmartObject = _chunkQE7D7TZRcjs.requireSmartObject; exports.requireTypeLayer = _chunkQE7D7TZRcjs.requireTypeLayer; exports.requireUnlocked = _chunkQE7D7TZRcjs.requireUnlocked; exports.rerender = _chunkQE7D7TZRcjs.rerender; exports.rerenderShape = _chunkQE7D7TZRcjs.rerenderShape; exports.rerenderText = _chunkQE7D7TZRcjs.rerenderText; exports.resizePixels = resizePixels; exports.resizeSelection = _chunkQYLWG22Ncjs.resizeSelection; exports.resizeWarpMesh = _chunkQAUIZPYIcjs.resizeWarpMesh; exports.resolveExternalAssets = _chunkQE7D7TZRcjs.resolveExternalAssets; exports.resolveMosaicRegionBounds = resolveMosaicRegionBounds; exports.resolvePaintGradient = _chunkPQ3H2AANcjs.resolvePaintGradient; exports.resolveProfile = resolveProfile; exports.resolveVectorMasks = _chunkQE7D7TZRcjs.resolveVectorMasks; exports.restyleRange = _chunkQAUIZPYIcjs.restyleRange; exports.retouchFilter = _chunk3EHPLDFQcjs.retouchFilter; exports.reversePaintGradient = _chunkPQ3H2AANcjs.reversePaintGradient; exports.rgbToGray = _chunkQE7D7TZRcjs.rgbToGray; exports.rgbToHsl = _chunkQE7D7TZRcjs.rgbToHsl; exports.rgbToReflectance = _chunkOLNIPTB3cjs.rgbToReflectance; exports.rgbUnitToHex = rgbUnitToHex; exports.rgbaViewOfGrey = _chunk3EHPLDFQcjs.rgbaViewOfGrey; exports.runLayerFilters = _chunkQE7D7TZRcjs.runLayerFilters; exports.runLayerFiltersFloat = _chunkQE7D7TZRcjs.runLayerFiltersFloat; exports.runLayerMenuAction = runLayerMenuAction; exports.runSelectionJob = _chunkX4LUGTQXcjs.runSelectionJob; exports.sameCanvasViewport = sameCanvasViewport; exports.sampleLut = _chunkQE7D7TZRcjs.sampleLut; exports.sampleToneLut = _chunkQE7D7TZRcjs.sampleToneLut; exports.saturationOf = _chunk3EHPLDFQcjs.saturationOf; exports.scaleLayerEffect = _chunkUOGKSVRQcjs.scaleLayerEffect; exports.scalePaintGradient = _chunkPQ3H2AANcjs.scalePaintGradient; exports.seamlessClone = _chunk3EHPLDFQcjs.seamlessClone; exports.seedFromString = _chunkPQ3H2AANcjs.seedFromString; exports.segmentToSelection = segmentToSelection; exports.segmentationOutlines = segmentationOutlines; exports.segmentsToSelection = segmentsToSelection; exports.selectObjectIn = _chunkX4LUGTQXcjs.selectObjectIn; exports.selectSimilar = selectSimilar; exports.selectionArea = _chunkQYLWG22Ncjs.selectionArea; exports.selectionFromCoverage = _chunkQYLWG22Ncjs.selectionFromCoverage; exports.selectionFromPixels = _chunkQYLWG22Ncjs.selectionFromPixels; exports.selectionFromRegion = _chunkQYLWG22Ncjs.selectionFromRegion; exports.selectionFromTiles = _chunkQYLWG22Ncjs.selectionFromTiles; exports.selectionModeFromModifiers = selectionModeFromModifiers; exports.selectionOutline = selectionOutline; exports.selectionRing = selectionRing; exports.selectionToCoverage = _chunkQYLWG22Ncjs.selectionToCoverage; exports.selectionToPixels = _chunkQYLWG22Ncjs.selectionToPixels; exports.selectionToSubpaths = selectionToSubpaths; exports.selectionValueAt = _chunkQYLWG22Ncjs.selectionValueAt; exports.serializeChannels = serializeChannels; exports.serializeColorMode = serializeColorMode; exports.serializeColorProfile = serializeColorProfile; exports.serializeContents = _chunkQE7D7TZRcjs.serializeContents; exports.serializeEffects = _chunkQE7D7TZRcjs.serializeEffects; exports.serializeLayer = _chunkQE7D7TZRcjs.serializeLayer; exports.serializeLayers = _chunkQE7D7TZRcjs.serializeLayers; exports.serializeLayersExternal = _chunkQE7D7TZRcjs.serializeLayersExternal; exports.serializeMask = _chunkX4LUGTQXcjs.serializeMask; exports.serializePatterns = _chunkQE7D7TZRcjs.serializePatterns; exports.serializeSelection = _chunkQYLWG22Ncjs.serializeSelection; exports.setCloneTransformValue = setCloneTransformValue; exports.setControlPath = setControlPath; exports.setLayerEffects = _chunkQE7D7TZRcjs.setLayerEffects; exports.setLayerEffectsEnabled = _chunkQE7D7TZRcjs.setLayerEffectsEnabled; exports.setLayerMask = _chunkQE7D7TZRcjs.setLayerMask; exports.setLayerProperties = _chunkQE7D7TZRcjs.setLayerProperties; exports.setLum = _chunkOLNIPTB3cjs.setLum; exports.setPigmentColor = _chunkOLNIPTB3cjs.setPigmentColor; exports.setRetouchChoice = setRetouchChoice; exports.setSmartFilterMask = _chunkQE7D7TZRcjs.setSmartFilterMask; exports.setSmartFiltersEnabled = _chunkQE7D7TZRcjs.setSmartFiltersEnabled; exports.setSmartPlacement = _chunkQE7D7TZRcjs.setSmartPlacement; exports.shadeTile = _chunkKWNMBMKGcjs.shadeTile; exports.shapeAsPixelLayer = _chunkQE7D7TZRcjs.shapeAsPixelLayer; exports.shapeFromAnnotation = _chunkQE7D7TZRcjs.shapeFromAnnotation; exports.shapeGeometryBounds = _chunkQE7D7TZRcjs.shapeGeometryBounds; exports.shapeLayers = _chunkQE7D7TZRcjs.shapeLayers; exports.shapeOutline = _chunkQE7D7TZRcjs.shapeOutline; exports.shapeRenderClip = _chunkQE7D7TZRcjs.shapeRenderClip; exports.shiftCoverage = _chunkQYLWG22Ncjs.shiftCoverage; exports.simplifyPixelPath = simplifyPixelPath; exports.skinToneRange = skinToneRange; exports.slicSuperpixels = _chunkX4LUGTQXcjs.slicSuperpixels; exports.smartFilterRows = smartFilterRows; exports.smartObjectLayers = _chunkQE7D7TZRcjs.smartObjectLayers; exports.smoothCoverage = _chunkQYLWG22Ncjs.smoothCoverage; exports.smoothPoints = _chunkPQ3H2AANcjs.smoothPoints; exports.smoothnessWeights = _chunkX4LUGTQXcjs.smoothnessWeights; exports.smudgeEffect = _chunk3EHPLDFQcjs.smudgeEffect; exports.snapPolygonToEdges = snapPolygonToEdges; exports.snapTo45 = snapTo45; exports.snapToEdge = snapToEdge; exports.softMaskToSelection = _chunkX4LUGTQXcjs.softMaskToSelection; exports.solidPaint = _chunkPQ3H2AANcjs.solidPaint; exports.solidSurface = _chunk474IQG74cjs.solidSurface; exports.solveMembrane = _chunk3EHPLDFQcjs.solveMembrane; exports.spliceRuns = _chunkQAUIZPYIcjs.spliceRuns; exports.splitOverlayAnnotations = splitOverlayAnnotations; exports.sponge = _chunk3EHPLDFQcjs.sponge; exports.spongeEffect = _chunk3EHPLDFQcjs.spongeEffect; exports.spotHealPixels = _chunk3EHPLDFQcjs.spotHealPixels; exports.spotHealWindow = _chunk3EHPLDFQcjs.spotHealWindow; exports.srgb8ToLab = srgb8ToLab; exports.srgbByteToLinear = _chunkKWNMBMKGcjs.srgbByteToLinear; exports.srgbDecode = _chunkOLNIPTB3cjs.srgbDecode; exports.srgbEncode = _chunkOLNIPTB3cjs.srgbEncode; exports.srgbToLinear = _chunkQE7D7TZRcjs.srgbToLinear; exports.standardBlendMode = _chunkOLNIPTB3cjs.standardBlendMode; exports.startMarchingAnts = startMarchingAnts; exports.startSelectionWorker = _chunkX4LUGTQXcjs.startSelectionWorker; exports.stepSlotTs = _chunkKWNMBMKGcjs.stepSlotTs; exports.strokeGrainCatch = _chunkPQ3H2AANcjs.strokeGrainCatch; exports.styleAt = _chunkQAUIZPYIcjs.styleAt; exports.subpathsToSvgPath = subpathsToSvgPath; exports.sumHistograms = sumHistograms; exports.superpixelSaliency = _chunkX4LUGTQXcjs.superpixelSaliency; exports.surfaceBytes = _chunk474IQG74cjs.surfaceBytes; exports.surfaceDepth = _chunkOLNIPTB3cjs.surfaceDepth; exports.surfaceFromDeepPixels = _chunkOLNIPTB3cjs.surfaceFromDeepPixels; exports.surfaceFromPixels = _chunk474IQG74cjs.surfaceFromPixels; exports.surfacesEqual = _chunk474IQG74cjs.surfacesEqual; exports.tempTintToXy = _chunkQE7D7TZRcjs.tempTintToXy; exports.temperatureToKelvin = _chunkQE7D7TZRcjs.temperatureToKelvin; exports.textIndexAt = _chunkQAUIZPYIcjs.textIndexAt; exports.textMatrix = _chunkQE7D7TZRcjs.textMatrix; exports.textOrientation = _chunkQE7D7TZRcjs.textOrientation; exports.textOutlines = _chunkQE7D7TZRcjs.textOutlines; exports.textRange = _chunkQE7D7TZRcjs.textRange; exports.tileCoord = _chunk474IQG74cjs.tileCoord; exports.tileKey = _chunk474IQG74cjs.tileKey; exports.tileRect = _chunk474IQG74cjs.tileRect; exports.tileSamples = _chunkOLNIPTB3cjs.tileSamples; exports.tileSamples16 = _chunkOLNIPTB3cjs.tileSamples16; exports.tileSamples32 = _chunkOLNIPTB3cjs.tileSamples32; exports.tilesInRect = _chunk474IQG74cjs.tilesInRect; exports.tipFalloff = _chunkPQ3H2AANcjs.tipFalloff; exports.tipReach = _chunkPQ3H2AANcjs.tipReach; exports.tipShape = _chunkPQ3H2AANcjs.tipShape; exports.to16From32 = _chunkOLNIPTB3cjs.to16From32; exports.to16From8 = _chunkOLNIPTB3cjs.to16From8; exports.to32From16 = _chunkOLNIPTB3cjs.to32From16; exports.to32From8 = _chunkOLNIPTB3cjs.to32From8; exports.to8From16 = _chunkOLNIPTB3cjs.to8From16; exports.to8From32 = _chunkOLNIPTB3cjs.to8From32; exports.toHex = toHex; exports.toTextSpace = _chunkQE7D7TZRcjs.toTextSpace; exports.toneCurve = _chunkQE7D7TZRcjs.toneCurve; exports.toneLuts = _chunkQE7D7TZRcjs.toneLuts; exports.toneOf = _chunk3EHPLDFQcjs.toneOf; exports.toneRange = toneRange; exports.transformHomography = _chunkQE7D7TZRcjs.transformHomography; exports.transformMap = _chunkQE7D7TZRcjs.transformMap; exports.transformShapeComponents = _chunkQE7D7TZRcjs.transformShapeComponents; exports.transformSurface = _chunkUOGKSVRQcjs.transformSurface; exports.transformTypeLayer = _chunkQE7D7TZRcjs.transformTypeLayer; exports.transformVectorMask = _chunkQE7D7TZRcjs.transformVectorMask; exports.transformedBounds = _chunkUOGKSVRQcjs.transformedBounds; exports.transformedBox = _chunkQE7D7TZRcjs.transformedBox; exports.transformedPoint = _chunkQE7D7TZRcjs.transformedPoint; exports.translateLayer = _chunkQE7D7TZRcjs.translateLayer; exports.translateSurface = _chunk474IQG74cjs.translateSurface; exports.typeAsPixelLayer = _chunkQE7D7TZRcjs.typeAsPixelLayer; exports.typeFrame = _chunkQE7D7TZRcjs.typeFrame; exports.typeFromAnnotation = _chunkQE7D7TZRcjs.typeFromAnnotation; exports.typeLayerAt = typeLayerAt; exports.typeLayerName = _chunkQE7D7TZRcjs.typeLayerName; exports.ungroupLayer = _chunkQE7D7TZRcjs.ungroupLayer; exports.uniformTile = _chunk474IQG74cjs.uniformTile; exports.unionRect = _chunkQE7D7TZRcjs.unionRect; exports.unprojectCanvasPoint = _chunkQE7D7TZRcjs.unprojectCanvasPoint; exports.updateLayerEffect = _chunkQE7D7TZRcjs.updateLayerEffect; exports.updateLayerFilter = _chunkQE7D7TZRcjs.updateLayerFilter; exports.updateLayerMaskProps = _chunkQE7D7TZRcjs.updateLayerMaskProps; exports.updatePaintGradientStop = _chunkPQ3H2AANcjs.updatePaintGradientStop; exports.updateShapeLayer = _chunkQE7D7TZRcjs.updateShapeLayer; exports.updateSmartFilter = _chunkQE7D7TZRcjs.updateSmartFilter; exports.updateTypeLayer = _chunkQE7D7TZRcjs.updateTypeLayer; exports.upscaleRegion = _chunkX4LUGTQXcjs.upscaleRegion; exports.userErrorMessage = _chunkQE7D7TZRcjs.userErrorMessage; exports.uvToXy = _chunkQE7D7TZRcjs.uvToXy; exports.validateEffectGradient = _chunkUOGKSVRQcjs.validateEffectGradient; exports.validateLayerEffect = _chunkUOGKSVRQcjs.validateLayerEffect; exports.validateLayerEffects = _chunkUOGKSVRQcjs.validateLayerEffects; exports.vectorMaskBounds = _chunkQE7D7TZRcjs.vectorMaskBounds; exports.vectorMaskCoverage = _chunkQE7D7TZRcjs.vectorMaskCoverage; exports.vectorMaskThumbnail = _chunkQE7D7TZRcjs.vectorMaskThumbnail; exports.vectorMaskThumbnailClick = vectorMaskThumbnailClick; exports.versionedDescriptorBytes = _chunkQE7D7TZRcjs.versionedDescriptorBytes; exports.vibranceLinear = _chunkQE7D7TZRcjs.vibranceLinear; exports.vibrancePixel = _chunkQE7D7TZRcjs.vibrancePixel; exports.walkDabs = _chunkPQ3H2AANcjs.walkDabs; exports.warpMeshEditPoints = _chunkQAUIZPYIcjs.warpMeshEditPoints; exports.warpMeshGridCurves = _chunkQAUIZPYIcjs.warpMeshGridCurves; exports.warpMeshParamAt = _chunkQAUIZPYIcjs.warpMeshParamAt; exports.warpPresetMesh = _chunkQAUIZPYIcjs.warpPresetMesh; exports.warpSurface = _chunkUOGKSVRQcjs.warpSurface; exports.watchCanvasViewport = watchCanvasViewport; exports.wbMatrix = _chunkQE7D7TZRcjs.wbMatrix; exports.wetGpuSupport = _chunkKWNMBMKGcjs.wetGpuSupport; exports.wetSimdSupported = _chunkKWNMBMKGcjs.wetSimdSupported; exports.wetSupport = _chunkKWNMBMKGcjs.wetSupport; exports.whiteBalanceFromSample = _chunkQE7D7TZRcjs.whiteBalanceFromSample; exports.whiteBalanceMatrix = _chunkQE7D7TZRcjs.whiteBalanceMatrix; exports.withBackgroundOpacity = withBackgroundOpacity; exports.withFilterMaskSurface = _chunkQE7D7TZRcjs.withFilterMaskSurface; exports.withImagePlayback = withImagePlayback; exports.withNewIds = _chunkQE7D7TZRcjs.withNewIds; exports.workImage = _chunkX4LUGTQXcjs.workImage; exports.workLuma = _chunkX4LUGTQXcjs.workLuma; exports.workPlanes = _chunkX4LUGTQXcjs.workPlanes; exports.writeAdjustmentBlock = _chunkQE7D7TZRcjs.writeAdjustmentBlock; exports.writeDeepRegion = _chunkOLNIPTB3cjs.writeDeepRegion; exports.writeLfx2 = _chunkQE7D7TZRcjs.writeLfx2; exports.writePatternBlock = _chunkQE7D7TZRcjs.writePatternBlock; exports.writePsd = _chunkQE7D7TZRcjs.writePsd; exports.writeRegion = _chunk474IQG74cjs.writeRegion; exports.xyToTempTint = _chunkQE7D7TZRcjs.xyToTempTint; exports.xyToUv = _chunkQE7D7TZRcjs.xyToUv;
|
|
21079
|
+
exports.ADJUSTMENT_KEYS = _chunkQE7D7TZRcjs.ADJUSTMENT_KEYS; exports.ADJUSTMENT_KINDS = _chunkQE7D7TZRcjs.ADJUSTMENT_KINDS; exports.ADJUSTMENT_LAYER_CONTROLS = ADJUSTMENT_LAYER_CONTROLS; exports.ADJUSTMENT_LAYER_OPACITY_CONTROL = ADJUSTMENT_LAYER_OPACITY_CONTROL; exports.ADJUSTMENT_LUT_SIZE = _chunkQE7D7TZRcjs.ADJUSTMENT_LUT_SIZE; exports.ANCHOR_FRACTION = _chunkQE7D7TZRcjs.ANCHOR_FRACTION; exports.AS_SHOT_KELVIN = _chunkQE7D7TZRcjs.AS_SHOT_KELVIN; exports.BACKGROUND_LAYER_ID = _chunkQE7D7TZRcjs.BACKGROUND_LAYER_ID; exports.BACKGROUND_LAYER_NAME = _chunkQE7D7TZRcjs.BACKGROUND_LAYER_NAME; exports.BIT_DEPTHS = _chunkOLNIPTB3cjs.BIT_DEPTHS; exports.BIT_DEPTH_OPTIONS = BIT_DEPTH_OPTIONS; exports.BLEND_MODES = _chunkOLNIPTB3cjs.BLEND_MODES; exports.BLUR_FILTER_ID = _chunkQE7D7TZRcjs.BLUR_FILTER_ID; exports.BODY_SCATTER = _chunkKWNMBMKGcjs.BODY_SCATTER; exports.BRUSHSTROKE_MAX_SCALE = _chunkYQGCPL5Xcjs.BRUSHSTROKE_MAX_SCALE; exports.BRUSHSTROKE_MIN_SCALE = _chunkYQGCPL5Xcjs.BRUSHSTROKE_MIN_SCALE; exports.BRUSH_OPTION_CONTROLS = BRUSH_OPTION_CONTROLS; exports.BUILTIN_PROFILES = _chunkBROJYMWUcjs.BUILTIN_PROFILES; exports.BrushstrokeCache = _chunkPQ3H2AANcjs.BrushstrokeCache; exports.CANVAS_SIZE_PRESETS = CANVAS_SIZE_PRESETS; exports.CLONE_TRANSFORM_CONTROLS = CLONE_TRANSFORM_CONTROLS; exports.COLOR_MODE_OPTIONS = COLOR_MODE_OPTIONS; exports.COLOR_RANGE_PRESETS = COLOR_RANGE_PRESETS; exports.COLOR_RANGE_PRESET_LABELS = COLOR_RANGE_PRESET_LABELS; exports.CONTENT_AWARE_FILL_SAMPLING = CONTENT_AWARE_FILL_SAMPLING; exports.CONTENT_AWARE_FILL_TOOLS = CONTENT_AWARE_FILL_TOOLS; exports.ColorGmm = _chunkL52VMQZScjs.ColorGmm; exports.ContentAwareFillSession = ContentAwareFillSession; exports.CoverageMap = _chunkPQ3H2AANcjs.CoverageMap; exports.D50 = _chunkQE7D7TZRcjs.D50; exports.D65 = _chunkQE7D7TZRcjs.D65; exports.DEFAULT_ADJUSTMENTS = DEFAULT_ADJUSTMENTS; exports.DEFAULT_AUTO_LEADING = _chunkQAUIZPYIcjs.DEFAULT_AUTO_LEADING; exports.DEFAULT_BLENDER = _chunkPQ3H2AANcjs.DEFAULT_BLENDER; exports.DEFAULT_BRUSH = _chunkPQ3H2AANcjs.DEFAULT_BRUSH; exports.DEFAULT_CANVAS_VIEWPORT = DEFAULT_CANVAS_VIEWPORT; exports.DEFAULT_CHANNEL_COLOR = DEFAULT_CHANNEL_COLOR; exports.DEFAULT_CONTENT_AWARE_FILL_SETTINGS = DEFAULT_CONTENT_AWARE_FILL_SETTINGS; exports.DEFAULT_DEPTH_MASK = DEFAULT_DEPTH_MASK; exports.DEFAULT_FLOW = _chunkKWNMBMKGcjs.DEFAULT_FLOW; exports.DEFAULT_GLOBAL_LIGHT = _chunkUOGKSVRQcjs.DEFAULT_GLOBAL_LIGHT; exports.DEFAULT_MITER_LIMIT = _chunkQE7D7TZRcjs.DEFAULT_MITER_LIMIT; exports.DEFAULT_MIXER = _chunkPQ3H2AANcjs.DEFAULT_MIXER; exports.DEFAULT_PAINT_GRADIENT = _chunkPQ3H2AANcjs.DEFAULT_PAINT_GRADIENT; exports.DEFAULT_PAINT_GRADIENT_MAPPING = _chunkPQ3H2AANcjs.DEFAULT_PAINT_GRADIENT_MAPPING; exports.DEFAULT_PROOF = DEFAULT_PROOF; exports.DEFAULT_REFINE_EDGE_PARAMS = _chunkL52VMQZScjs.DEFAULT_REFINE_EDGE_PARAMS; exports.DEFAULT_RETOUCH = _chunkYF3YZZ6Gcjs.DEFAULT_RETOUCH; exports.DEFAULT_SELECTION_TOOL_OPTIONS = DEFAULT_SELECTION_TOOL_OPTIONS; exports.DEFAULT_SELECT_AND_MASK_SETTINGS = DEFAULT_SELECT_AND_MASK_SETTINGS; exports.DEFAULT_SHAPE_TOOL_OPTIONS = DEFAULT_SHAPE_TOOL_OPTIONS; exports.DEFAULT_SMUDGE = _chunkPQ3H2AANcjs.DEFAULT_SMUDGE; exports.DEFAULT_TEXT_STYLE = _chunkQAUIZPYIcjs.DEFAULT_TEXT_STYLE; exports.DEFAULT_TRANSFORM = DEFAULT_TRANSFORM; exports.DEFAULT_TYPE_TOOL_OPTIONS = DEFAULT_TYPE_TOOL_OPTIONS; exports.DEFAULT_WET_PAPER = _chunkKWNMBMKGcjs.DEFAULT_WET_PAPER; exports.DEFAULT_WET_PARAMS = _chunkKWNMBMKGcjs.DEFAULT_WET_PARAMS; exports.DEPTH_MASK_CONTROLS = DEPTH_MASK_CONTROLS; exports.DEVELOP_FILTER_ID = _chunkQE7D7TZRcjs.DEVELOP_FILTER_ID; exports.DIRECT_GAUSSIAN_MAX_SIGMA = _chunkK6PXS6DOcjs.DIRECT_GAUSSIAN_MAX_SIGMA; exports.DRY_EPS = _chunkKWNMBMKGcjs.DRY_EPS; exports.DabWalker = _chunkPQ3H2AANcjs.DabWalker; exports.EFFECT_LAYER_USES = EFFECT_LAYER_USES; exports.EMPTY_DISTANCE = _chunkQYLWG22Ncjs.EMPTY_DISTANCE; exports.EMPTY_MIXER_LOAD = _chunkPQ3H2AANcjs.EMPTY_MIXER_LOAD; exports.EX = _chunkKWNMBMKGcjs.EX; exports.EY = _chunkKWNMBMKGcjs.EY; exports.EdgeMap = EdgeMap; exports.FLAG_ALIVE = _chunkKWNMBMKGcjs.FLAG_ALIVE; exports.FLAG_BOTTOM = _chunkKWNMBMKGcjs.FLAG_BOTTOM; exports.FLAG_LEFT = _chunkKWNMBMKGcjs.FLAG_LEFT; exports.FLAG_RIGHT = _chunkKWNMBMKGcjs.FLAG_RIGHT; exports.FLAG_TOP = _chunkKWNMBMKGcjs.FLAG_TOP; exports.FLAG_WET = _chunkKWNMBMKGcjs.FLAG_WET; exports.FLAT = _chunkKWNMBMKGcjs.FLAT; exports.FREE_INTERVAL = _chunkKWNMBMKGcjs.FREE_INTERVAL; exports.FREE_TRANSFORM_CONTENTS = FREE_TRANSFORM_CONTENTS; exports.FREE_TRANSFORM_FIELDS = FREE_TRANSFORM_FIELDS; exports.FREE_TRANSFORM_MODES = _chunkQE7D7TZRcjs.FREE_TRANSFORM_MODES; exports.FREE_TRANSFORM_MODE_OPTIONS = FREE_TRANSFORM_MODE_OPTIONS; exports.FreeTransformSession = FreeTransformSession; exports.FreeTransformTool = FreeTransformTool; exports.GAMMA = _chunkL52VMQZScjs.GAMMA; exports.GRAIN_PATTERNS = _chunkPQ3H2AANcjs.GRAIN_PATTERNS; exports.GRAIN_TILE = _chunkPQ3H2AANcjs.GRAIN_TILE; exports.GUIDED_FILTER_EPS = _chunkL52VMQZScjs.GUIDED_FILTER_EPS; exports.GridGraph = _chunkL52VMQZScjs.GridGraph; exports.HIDE = _chunkKWNMBMKGcjs.HIDE; exports.HISTOGRAM_BINS = HISTOGRAM_BINS; exports.HUE_RANGE_LABELS = _chunkQE7D7TZRcjs.HUE_RANGE_LABELS; exports.HUE_RANGE_PRESETS = HUE_RANGE_PRESETS; exports.IDENTITY_CLONE_TRANSFORM = _chunkYF3YZZ6Gcjs.IDENTITY_CLONE_TRANSFORM; exports.IDENTITY_MATRIX3 = _chunkQE7D7TZRcjs.IDENTITY_MATRIX3; exports.IMAGE_ADJUSTMENT_CONTROLS = IMAGE_ADJUSTMENT_CONTROLS; exports.IMAGE_CROP_PRESETS = IMAGE_CROP_PRESETS; exports.IMAGE_EDITOR_SCHEMA_VERSION = IMAGE_EDITOR_SCHEMA_VERSION; exports.IMAGE_EDITOR_STATE_VERSION = IMAGE_EDITOR_STATE_VERSION; exports.IMAGE_EFFECT_PLACES = IMAGE_EFFECT_PLACES; exports.IMAGE_FILTER_PRESETS = IMAGE_FILTER_PRESETS; exports.IMAGE_PLAYBACK_KIND = IMAGE_PLAYBACK_KIND; exports.IMAGE_TOOL_GROUPS = IMAGE_TOOL_GROUPS; exports.IMAGE_TOOL_SHORTCUTS = IMAGE_TOOL_SHORTCUTS; exports.INTENTS = _chunkBROJYMWUcjs.INTENTS; exports.INTENT_OPTIONS = INTENT_OPTIONS; exports.INTERPOLATIONS = _chunkUOGKSVRQcjs.INTERPOLATIONS; exports.ImageEditorController = ImageEditorController; exports.ImageEditorRenderer = ImageEditorRenderer; exports.ImageEffectsEngine = ImageEffectsEngine; exports.LATEST_PROCESS_VERSION = _chunkQE7D7TZRcjs.LATEST_PROCESS_VERSION; exports.LAYERED_SCHEMA_VERSION = _chunkQE7D7TZRcjs.LAYERED_SCHEMA_VERSION; exports.LAYER_EFFECT_KINDS = _chunkUOGKSVRQcjs.LAYER_EFFECT_KINDS; exports.LAYER_EFFECT_MENU = LAYER_EFFECT_MENU; exports.LEGACY_PROCESS_VERSION = _chunkQE7D7TZRcjs.LEGACY_PROCESS_VERSION; exports.LIVE_SHAPE_KINDS = _chunkQE7D7TZRcjs.LIVE_SHAPE_KINDS; exports.LUMA_709 = _chunkQE7D7TZRcjs.LUMA_709; exports.LayerCompositor = _chunkQE7D7TZRcjs.LayerCompositor; exports.LayerEffectError = _chunkUOGKSVRQcjs.LayerEffectError; exports.LayerOperationError = _chunkQE7D7TZRcjs.LayerOperationError; exports.MARCHING_ANTS_STEP_MS = MARCHING_ANTS_STEP_MS; exports.MASK_FILE_ACCEPT = MASK_FILE_ACCEPT; exports.MAX_BATCH = _chunkKWNMBMKGcjs.MAX_BATCH; exports.MAX_BRUSH_SIZE = _chunkPQ3H2AANcjs.MAX_BRUSH_SIZE; exports.MAX_CANVAS_BACKING_SIDE = MAX_CANVAS_BACKING_SIDE; exports.MAX_EFFECT_ANIMATION_MS = _chunkQE7D7TZRcjs.MAX_EFFECT_ANIMATION_MS; exports.MAX_EFFECT_REACH = _chunkUOGKSVRQcjs.MAX_EFFECT_REACH; exports.MAX_KELVIN = _chunkQE7D7TZRcjs.MAX_KELVIN; exports.MAX_TILT_ACCEL = _chunkKWNMBMKGcjs.MAX_TILT_ACCEL; exports.MAX_TRANSFORM_PIXELS = _chunkUOGKSVRQcjs.MAX_TRANSFORM_PIXELS; exports.MAX_WET_LANES = _chunkKWNMBMKGcjs.MAX_WET_LANES; exports.MAX_WET_SLOTS = _chunkKWNMBMKGcjs.MAX_WET_SLOTS; exports.MIN_KELVIN = _chunkQE7D7TZRcjs.MIN_KELVIN; exports.MIRED_PER_TEMPERATURE_UNIT = _chunkQE7D7TZRcjs.MIRED_PER_TEMPERATURE_UNIT; exports.MIXER_DRAIN = _chunkPQ3H2AANcjs.MIXER_DRAIN; exports.MIXER_MIXING_OPTIONS = MIXER_MIXING_OPTIONS; exports.MIXER_OPTION_CONTROLS = MIXER_OPTION_CONTROLS; exports.MIXER_PICKUP_RATE = _chunkPQ3H2AANcjs.MIXER_PICKUP_RATE; exports.MIXING_MODELS = _chunkPQ3H2AANcjs.MIXING_MODELS; exports.MixerStroke = _chunkPQ3H2AANcjs.MixerStroke; exports.OPP = _chunkKWNMBMKGcjs.OPP; exports.PAINTERLY_BLEND_MODES = _chunkOLNIPTB3cjs.PAINTERLY_BLEND_MODES; exports.PAINT_COLOR_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_COLOR_JSON_SCHEMA; exports.PAINT_GRADIENT_FULL_SPEED = _chunkPQ3H2AANcjs.PAINT_GRADIENT_FULL_SPEED; exports.PAINT_GRADIENT_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_GRADIENT_JSON_SCHEMA; exports.PAINT_GRADIENT_KIT = _chunkPQ3H2AANcjs.PAINT_GRADIENT_KIT; exports.PAINT_GRADIENT_MAPPINGS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_MAPPINGS; exports.PAINT_GRADIENT_MAPPING_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_MAPPING_LABELS; exports.PAINT_GRADIENT_PRESETS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_PRESETS; exports.PAINT_GRADIENT_REPEATS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_REPEATS; exports.PAINT_GRADIENT_REPEAT_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_REPEAT_LABELS; exports.PAINT_GRADIENT_SPACES = _chunkPQ3H2AANcjs.PAINT_GRADIENT_SPACES; exports.PAINT_GRADIENT_SPACE_LABELS = _chunkPQ3H2AANcjs.PAINT_GRADIENT_SPACE_LABELS; exports.PAINT_SOURCE_JSON_SCHEMA = _chunkPQ3H2AANcjs.PAINT_SOURCE_JSON_SCHEMA; exports.PAINT_TOOLS = PAINT_TOOLS; exports.PAPER_CAPACITY = _chunkKWNMBMKGcjs.PAPER_CAPACITY; exports.PARAGRAPH_STYLE_FIELDS = _chunkQE7D7TZRcjs.PARAGRAPH_STYLE_FIELDS; exports.PARAM = _chunkKWNMBMKGcjs.PARAM; exports.PARAM_FLOATS = _chunkKWNMBMKGcjs.PARAM_FLOATS; exports.PASTE_MODES = PASTE_MODES; exports.PATTERN_BLOCK_KEYS = _chunkQE7D7TZRcjs.PATTERN_BLOCK_KEYS; exports.PIGMENT_BANDS = _chunkOLNIPTB3cjs.PIGMENT_BANDS; exports.PIGMENT_CHANNELS = _chunkKWNMBMKGcjs.PIGMENT_CHANNELS; exports.PIGMENT_LAMBDA_MIN = _chunkOLNIPTB3cjs.PIGMENT_LAMBDA_MIN; exports.PIGMENT_LAMBDA_STEP = _chunkOLNIPTB3cjs.PIGMENT_LAMBDA_STEP; exports.PIGMENT_UNIT = _chunkKWNMBMKGcjs.PIGMENT_UNIT; exports.PIGMENT_WAVELENGTHS = _chunkOLNIPTB3cjs.PIGMENT_WAVELENGTHS; exports.PLANE = _chunkKWNMBMKGcjs.PLANE; exports.PLANE_BYTES = _chunkKWNMBMKGcjs.PLANE_BYTES; exports.PREVIEW_SIZE = PREVIEW_SIZE; exports.PROOF_PROFILE_OPTIONS = PROOF_PROFILE_OPTIONS; exports.PSD_BLEND_KEYS = _chunkQE7D7TZRcjs.PSD_BLEND_KEYS; exports.PSD_FILE_ACCEPT = PSD_FILE_ACCEPT; exports.P_D0 = _chunkKWNMBMKGcjs.P_D0; exports.P_EDGE = _chunkKWNMBMKGcjs.P_EDGE; exports.P_FX = _chunkKWNMBMKGcjs.P_FX; exports.P_FY = _chunkKWNMBMKGcjs.P_FY; exports.P_H = _chunkKWNMBMKGcjs.P_H; exports.P_P0 = _chunkKWNMBMKGcjs.P_P0; exports.P_RHO = _chunkKWNMBMKGcjs.P_RHO; exports.P_SW = _chunkKWNMBMKGcjs.P_SW; exports.P_UX = _chunkKWNMBMKGcjs.P_UX; exports.P_UY = _chunkKWNMBMKGcjs.P_UY; exports.PaintExchange = _chunkPQ3H2AANcjs.PaintExchange; exports.PaintGesture = PaintGesture; exports.PaintGradientSampler = _chunkPQ3H2AANcjs.PaintGradientSampler; exports.PaintSourceError = _chunkPQ3H2AANcjs.PaintSourceError; exports.PaintStrokeSession = PaintStrokeSession; exports.PaperGrain = _chunkPQ3H2AANcjs.PaperGrain; exports.PatternPlacement = _chunkUOGKSVRQcjs.PatternPlacement; exports.PatternTile = _chunkUOGKSVRQcjs.PatternTile; exports.PsdError = _chunkQE7D7TZRcjs.PsdError; exports.QUICK_MASK_TARGET = QUICK_MASK_TARGET; exports.REFINE_EDGE_CONTROLS = REFINE_EDGE_CONTROLS; exports.REFINE_EDIT_KINDS = _chunkL52VMQZScjs.REFINE_EDIT_KINDS; exports.REFINE_OUTPUTS = REFINE_OUTPUTS; exports.RETOUCH_CHOICES = RETOUCH_CHOICES; exports.RETOUCH_OPTION_CONTROLS = RETOUCH_OPTION_CONTROLS; exports.RETOUCH_SAMPLES = _chunkYF3YZZ6Gcjs.RETOUCH_SAMPLES; exports.RETOUCH_TOGGLES = RETOUCH_TOGGLES; exports.RETOUCH_TOOLS = RETOUCH_TOOLS; exports.RegionPixelSource = _chunkYF3YZZ6Gcjs.RegionPixelSource; exports.RetouchDabStroke = _chunkYF3YZZ6Gcjs.RetouchDabStroke; exports.SELECTION_MODES = _chunkQYLWG22Ncjs.SELECTION_MODES; exports.SELECTION_MODE_LABELS = SELECTION_MODE_LABELS; exports.SELECTION_MODIFY_OPS = _chunkQYLWG22Ncjs.SELECTION_MODIFY_OPS; exports.SELECTION_TOOLS = SELECTION_TOOLS; exports.SELECT_AND_MASK_TOOLS = SELECT_AND_MASK_TOOLS; exports.SELECT_AND_MASK_VIEWS = SELECT_AND_MASK_VIEWS; exports.SET_PLANES = _chunkKWNMBMKGcjs.SET_PLANES; exports.SHADOW_AMBIENT = _chunkOLNIPTB3cjs.SHADOW_AMBIENT; exports.SHAPE_KIND_LABELS = SHAPE_KIND_LABELS; exports.SHAPE_OPERATIONS = _chunkQE7D7TZRcjs.SHAPE_OPERATIONS; exports.SHAPE_RENDER_MARGIN = _chunkQE7D7TZRcjs.SHAPE_RENDER_MARGIN; exports.SLOT_BYTES = _chunkKWNMBMKGcjs.SLOT_BYTES; exports.SLOT_PLANES = _chunkKWNMBMKGcjs.SLOT_PLANES; exports.SLOT_SIDE = _chunkKWNMBMKGcjs.SLOT_SIDE; exports.SMART_RENDER_MARGIN = _chunkQE7D7TZRcjs.SMART_RENDER_MARGIN; exports.SPOT_HEAL_TYPES = _chunkYF3YZZ6Gcjs.SPOT_HEAL_TYPES; exports.SRGB_TO_LINEAR = _chunkKWNMBMKGcjs.SRGB_TO_LINEAR; exports.STRIP = _chunkKWNMBMKGcjs.STRIP; exports.SUPPORTED_ADJUSTMENT_KEYS = _chunkQE7D7TZRcjs.SUPPORTED_ADJUSTMENT_KEYS; exports.SelectAndMaskSession = SelectAndMaskSession; exports.SelectionGesture = SelectionGesture; exports.SelectionWorkerClient = _chunkL52VMQZScjs.SelectionWorkerClient; exports.ShapeDrawGesture = ShapeDrawGesture; exports.SmudgeTip = _chunkPQ3H2AANcjs.SmudgeTip; exports.StrokeCoverage = _chunkPQ3H2AANcjs.StrokeCoverage; exports.SurfaceDraft = _chunk474IQG74cjs.SurfaceDraft; exports.TEXT_ALIGNS = _chunkQE7D7TZRcjs.TEXT_ALIGNS; exports.TEXT_ORIENTATIONS = _chunkQE7D7TZRcjs.TEXT_ORIENTATIONS; exports.TEXT_RENDER_MARGIN = _chunkQE7D7TZRcjs.TEXT_RENDER_MARGIN; exports.TEXT_STYLE_FIELDS = _chunkQE7D7TZRcjs.TEXT_STYLE_FIELDS; exports.TILE = _chunk474IQG74cjs.TILE; exports.TILE_SHIFT = _chunk474IQG74cjs.TILE_SHIFT; exports.TINT_SCALE = _chunkQE7D7TZRcjs.TINT_SCALE; exports.TIP_GRADIENT_STEPS = _chunkPQ3H2AANcjs.TIP_GRADIENT_STEPS; exports.TONE_LUT_SIZE = _chunkQE7D7TZRcjs.TONE_LUT_SIZE; exports.TONE_RANGES = _chunkYF3YZZ6Gcjs.TONE_RANGES; exports.TONE_RANGE_PRESETS = TONE_RANGE_PRESETS; exports.TRANSFORM_ANCHORS = _chunkQE7D7TZRcjs.TRANSFORM_ANCHORS; exports.TRANSFORM_ROTATE_HANDLE_OFFSET = TRANSFORM_ROTATE_HANDLE_OFFSET; exports.TextEditSession = TextEditSession; exports.TileMedium = _chunkPQ3H2AANcjs.TileMedium; exports.TilePixelSource = _chunkYF3YZZ6Gcjs.TilePixelSource; exports.TileableNoise = _chunkPQ3H2AANcjs.TileableNoise; exports.TiledSurface = _chunk474IQG74cjs.TiledSurface; exports.TransformTooLargeError = _chunkUOGKSVRQcjs.TransformTooLargeError; exports.TransformedPixelSource = _chunkYF3YZZ6Gcjs.TransformedPixelSource; exports.TypeToolGesture = TypeToolGesture; exports.UNITS = _chunkL52VMQZScjs.UNITS; exports.U_MAX = _chunkKWNMBMKGcjs.U_MAX; exports.VIBRANCE_GREY = _chunkQE7D7TZRcjs.VIBRANCE_GREY; exports.W9 = _chunkKWNMBMKGcjs.W9; exports.WARP_GRID_OPTIONS = WARP_GRID_OPTIONS; exports.WARP_STYLES = _chunkQAUIZPYIcjs.WARP_STYLES; exports.WARP_STYLE_LABELS = _chunkQAUIZPYIcjs.WARP_STYLE_LABELS; exports.WARP_STYLE_OPTIONS = WARP_STYLE_OPTIONS; exports.WET_FLOW_KINDS = _chunkKWNMBMKGcjs.WET_FLOW_KINDS; exports.WET_PARAM_KEYS = _chunkKWNMBMKGcjs.WET_PARAM_KEYS; exports.WET_TILE = _chunkKWNMBMKGcjs.WET_TILE; exports.WGSL_HALO = _chunkKWNMBMKGcjs.WGSL_HALO; exports.WGSL_SHADE = _chunkKWNMBMKGcjs.WGSL_SHADE; exports.WGSL_STEP = _chunkKWNMBMKGcjs.WGSL_STEP; exports.WORKING_SPACE_OPTIONS = WORKING_SPACE_OPTIONS; exports.WORK_SIZE = _chunkL52VMQZScjs.WORK_SIZE; exports.WetGpuEngine = _chunkKWNMBMKGcjs.WetGpuEngine; exports.WetMedium = _chunkKWNMBMKGcjs.WetMedium; exports.WetWorkerPool = _chunkKWNMBMKGcjs.WetWorkerPool; exports.WetWorld = _chunkKWNMBMKGcjs.WetWorld; exports.WetWorldError = _chunkKWNMBMKGcjs.WetWorldError; exports.XYZ_D50_TO_SRGB = _chunkQE7D7TZRcjs.XYZ_D50_TO_SRGB; exports.ZlibError = _chunkXFM3OCHUcjs.ZlibError; exports.activeAdjustmentLayers = _chunkQE7D7TZRcjs.activeAdjustmentLayers; exports.activeEffectSmartFilters = _chunkQE7D7TZRcjs.activeEffectSmartFilters; exports.activeLayerAfterRemoval = _chunkQE7D7TZRcjs.activeLayerAfterRemoval; exports.activeSmartFilters = _chunkQE7D7TZRcjs.activeSmartFilters; exports.addLayerEffect = _chunkQE7D7TZRcjs.addLayerEffect; exports.addLayerFilter = _chunkQE7D7TZRcjs.addLayerFilter; exports.addLayerOfKind = addLayerOfKind; exports.addPaintGradientStop = _chunkPQ3H2AANcjs.addPaintGradientStop; exports.addSmartFilter = _chunkQE7D7TZRcjs.addSmartFilter; exports.addToHistogram = addToHistogram; exports.adjustmentKindLabel = _chunkQE7D7TZRcjs.adjustmentKindLabel; exports.adjustmentLayersKey = _chunkQE7D7TZRcjs.adjustmentLayersKey; exports.adjustmentNodeAsLayer = _chunkQE7D7TZRcjs.adjustmentNodeAsLayer; exports.adjustmentNodeFromLegacy = _chunkQE7D7TZRcjs.adjustmentNodeFromLegacy; exports.adler32 = _chunkXFM3OCHUcjs.adler32; exports.agentDragDraft = agentDragDraft; exports.anchorPoint = _chunkQE7D7TZRcjs.anchorPoint; exports.annotationBlend = _chunkQE7D7TZRcjs.annotationBlend; exports.annotationLayerFor = _chunkQE7D7TZRcjs.annotationLayerFor; exports.annotationLayerName = _chunkQE7D7TZRcjs.annotationLayerName; exports.annotationOfLayer = _chunkQE7D7TZRcjs.annotationOfLayer; exports.annotationOfShape = _chunkQE7D7TZRcjs.annotationOfShape; exports.annotationOfType = _chunkQE7D7TZRcjs.annotationOfType; exports.applyAdjustmentLayers = _chunkQE7D7TZRcjs.applyAdjustmentLayers; exports.applyAdjustmentLayersFloat = _chunkQE7D7TZRcjs.applyAdjustmentLayersFloat; exports.applyAdjustments = _chunkQE7D7TZRcjs.applyAdjustments; exports.applyBoxBlur = _chunkQE7D7TZRcjs.applyBoxBlur; exports.applyBoxBlurFloat = _chunkQE7D7TZRcjs.applyBoxBlurFloat; exports.applyDepthMask = _chunkQE7D7TZRcjs.applyDepthMask; exports.applyHomography = _chunkQT26RHKKcjs.applyHomography; exports.applyImageProjectionToContext = _chunkQE7D7TZRcjs.applyImageProjectionToContext; exports.applyLegacyAdjustments = _chunkQE7D7TZRcjs.applyLegacyAdjustments; exports.applyLegacyFloat = _chunkQE7D7TZRcjs.applyLegacyFloat; exports.applyMatrix3 = _chunkQE7D7TZRcjs.applyMatrix3; exports.applyOutputStage = applyOutputStage; exports.applyParams = _chunkQE7D7TZRcjs.applyParams; exports.applyProcess2Adjustments = _chunkQE7D7TZRcjs.applyProcess2Adjustments; exports.applyProcess2Float = _chunkQE7D7TZRcjs.applyProcess2Float; exports.applyRefineEdits = _chunkL52VMQZScjs.applyRefineEdits; exports.applyRegionBlur = applyRegionBlur; exports.applyRegionMosaic = applyRegionMosaic; exports.applyRetouchToTile = _chunkYF3YZZ6Gcjs.applyRetouchToTile; exports.applyShapeOptions = applyShapeOptions; exports.applySmartFilters = _chunkQE7D7TZRcjs.applySmartFilters; exports.applyStrokeToDeepTile = _chunkPQ3H2AANcjs.applyStrokeToDeepTile; exports.applyStrokeToTile = _chunkPQ3H2AANcjs.applyStrokeToTile; exports.applyToneToDeepTile = _chunkYF3YZZ6Gcjs.applyToneToDeepTile; exports.backgroundLayer = _chunkQE7D7TZRcjs.backgroundLayer; exports.base64ToBytes = _chunkOLNIPTB3cjs.base64ToBytes; exports.baseProjection = baseProjection; exports.bestOffset = _chunkMQDIP4CFcjs.bestOffset; exports.blackWhiteGray = _chunkQE7D7TZRcjs.blackWhiteGray; exports.blendChannel = _chunkOLNIPTB3cjs.blendChannel; exports.blendImageData = _chunkOLNIPTB3cjs.blendImageData; exports.blendLum = _chunkOLNIPTB3cjs.blendLum; exports.blendPixel = _chunkOLNIPTB3cjs.blendPixel; exports.blendRadius = _chunkPQ3H2AANcjs.blendRadius; exports.blendRgb = _chunkOLNIPTB3cjs.blendRgb; exports.blendTile = _chunkUOGKSVRQcjs.blendTile; exports.blenderDab = _chunkPQ3H2AANcjs.blenderDab; exports.blurFilter = _chunkQE7D7TZRcjs.blurFilter; exports.borderCoverage = _chunkQYLWG22Ncjs.borderCoverage; exports.boxBlur = _chunkL52VMQZScjs.boxBlur; exports.boxBlurPixels = _chunkYF3YZZ6Gcjs.boxBlurPixels; exports.boxFrameHit = boxFrameHit; exports.boxFrameOverlay = boxFrameOverlay; exports.boxMean = _chunkL52VMQZScjs.boxMean; exports.boxPointOf = _chunkQE7D7TZRcjs.boxPointOf; exports.boxQuad = _chunkQT26RHKKcjs.boxQuad; exports.boxToCurvePoint = boxToCurvePoint; exports.bradfordAdaptation = _chunkQE7D7TZRcjs.bradfordAdaptation; exports.brushStrokeMask = _chunkL52VMQZScjs.brushStrokeMask; exports.brushstrokeDataUrl = _chunkPQ3H2AANcjs.brushstrokeDataUrl; exports.brushstrokeKey = _chunkPQ3H2AANcjs.brushstrokeKey; exports.brushstrokeSamples = _chunkPQ3H2AANcjs.brushstrokeSamples; exports.brushstrokeScaleBucket = _chunkYQGCPL5Xcjs.brushstrokeScaleBucket; exports.brushstrokeStrokeOptions = _chunkPQ3H2AANcjs.brushstrokeStrokeOptions; exports.brushstrokeToCanvas = _chunkPQ3H2AANcjs.brushstrokeToCanvas; exports.buildLayerMaskPlanes = _chunkQE7D7TZRcjs.buildLayerMaskPlanes; exports.buildToneLut = _chunkQE7D7TZRcjs.buildToneLut; exports.builtinPattern = _chunkUOGKSVRQcjs.builtinPattern; exports.builtinPatternIds = _chunkUOGKSVRQcjs.builtinPatternIds; exports.bytesToBase64 = _chunkOLNIPTB3cjs.bytesToBase64; exports.calculateCropDrag = _chunkQE7D7TZRcjs.calculateCropDrag; exports.canShareMemory = _chunkKWNMBMKGcjs.canShareMemory; exports.canvasCompositeOperation = _chunkOLNIPTB3cjs.canvasCompositeOperation; exports.canvasToImagePoint = _chunkQE7D7TZRcjs.canvasToImagePoint; exports.caretAt = _chunkQAUIZPYIcjs.caretAt; exports.changedTiles = _chunkUOGKSVRQcjs.changedTiles; exports.channelThumbnail = channelThumbnail; exports.checkEffectAnimation = checkEffectAnimation; exports.checkEffectTime = checkEffectTime; exports.checkImageEffectPlace = checkImageEffectPlace; exports.clampControlValue = clampControlValue; exports.clampCropToImage = _chunkQE7D7TZRcjs.clampCropToImage; exports.cleanMixer = _chunkPQ3H2AANcjs.cleanMixer; exports.cloneSamplePoint = _chunkYF3YZZ6Gcjs.cloneSamplePoint; exports.cloneSourceLabel = cloneSourceLabel; exports.cloneTransformView = cloneTransformView; exports.collectTiles = _chunk474IQG74cjs.collectTiles; exports.colorBalanceChannel = _chunkQE7D7TZRcjs.colorBalanceChannel; exports.colorModePlanes = colorModePlanes; exports.colorModePlanes16 = colorModePlanes16; exports.colorPanelView = colorPanelView; exports.colorRange = colorRange; exports.colorRangePreset = colorRangePreset; exports.combineSelections = _chunkQYLWG22Ncjs.combineSelections; exports.compileAdjustmentLayer = _chunkQE7D7TZRcjs.compileAdjustmentLayer; exports.componentPath = _chunkQE7D7TZRcjs.componentPath; exports.componentsCoverage = _chunkQE7D7TZRcjs.componentsCoverage; exports.compositeDeep = _chunkQE7D7TZRcjs.compositeDeep; exports.compositeSurfaceOver = _chunkUOGKSVRQcjs.compositeSurfaceOver; exports.computeHistogram = computeHistogram; exports.computeSelectionBounds = _chunkQYLWG22Ncjs.computeSelectionBounds; exports.contentAwareFill = _chunkMQDIP4CFcjs.contentAwareFill; exports.contentBounds = _chunk474IQG74cjs.contentBounds; exports.contentsBox = _chunkQE7D7TZRcjs.contentsBox; exports.contentsSurface = _chunkQE7D7TZRcjs.contentsSurface; exports.contractCoverage = _chunkQYLWG22Ncjs.contractCoverage; exports.controlPosition = controlPosition; exports.controlTrackBackground = controlTrackBackground; exports.convertColorFields = convertColorFields; exports.convertHex = convertHex; exports.convertSurfaceColors = convertSurfaceColors; exports.convertSurfaceDepth = _chunkOLNIPTB3cjs.convertSurfaceDepth; exports.convertToSmartObject = _chunkQE7D7TZRcjs.convertToSmartObject; exports.copySmartObject = _chunkQE7D7TZRcjs.copySmartObject; exports.cornersFromMatrix = _chunkQE7D7TZRcjs.cornersFromMatrix; exports.coverageTileCoord = _chunkPQ3H2AANcjs.coverageTileCoord; exports.coverageToByte = _chunkQYLWG22Ncjs.coverageToByte; exports.coveringRect = coveringRect; exports.createAdjustmentLayer = _chunkQE7D7TZRcjs.createAdjustmentLayer; exports.createBlenderScratch = _chunkPQ3H2AANcjs.createBlenderScratch; exports.createCanvasTextShaper = _chunkQAUIZPYIcjs.createCanvasTextShaper; exports.createImageCaptureSurface = createImageCaptureSurface; exports.createImageColorTools = createImageColorTools; exports.createImageEditTools = createImageEditTools; exports.createImageEditorDocument = createImageEditorDocument; exports.createImageEditorToolProvider = createImageEditorToolProvider; exports.createImageEffectTools = createImageEffectTools; exports.createImageEffectsToolProvider = createImageEffectsToolProvider; exports.createImageLayerTools = createImageLayerTools; exports.createImagePaintTools = createImagePaintTools; exports.createImagePlaybackLocator = createImagePlaybackLocator; exports.createImagePsdTools = createImagePsdTools; exports.createImageRetouchTools = createImageRetouchTools; exports.createImageSegmentationToolProvider = createImageSegmentationToolProvider; exports.createImageSelectionTools = createImageSelectionTools; exports.createImageShapeTools = createImageShapeTools; exports.createImageSmartObjectTools = createImageSmartObjectTools; exports.createImageSubjectSelectionTool = createImageSubjectSelectionTool; exports.createImageTransformTools = createImageTransformTools; exports.createImageTypeTools = createImageTypeTools; exports.createMetricTextShaper = _chunkQAUIZPYIcjs.createMetricTextShaper; exports.createOutlineTextShaper = _chunkQAUIZPYIcjs.createOutlineTextShaper; exports.createPigment = _chunkOLNIPTB3cjs.createPigment; exports.createPigmentTools = _chunkKWNMBMKGcjs.createPigmentTools; exports.createSelectionMask = _chunkQYLWG22Ncjs.createSelectionMask; exports.createShapeLayer = _chunkQE7D7TZRcjs.createShapeLayer; exports.createTypeLayer = _chunkQE7D7TZRcjs.createTypeLayer; exports.createWetGpuEngine = _chunkKWNMBMKGcjs.createWetGpuEngine; exports.cssFont = _chunkQAUIZPYIcjs.cssFont; exports.cssFontFamily = _chunkQAUIZPYIcjs.cssFontFamily; exports.curveLut = _chunkUOGKSVRQcjs.curveLut; exports.curveLutFromLevels = _chunkQE7D7TZRcjs.curveLutFromLevels; exports.curvePointToBox = curvePointToBox; exports.curveSvgPath = curveSvgPath; exports.dabCoverage = _chunkPQ3H2AANcjs.dabCoverage; exports.dabRect = _chunkPQ3H2AANcjs.dabRect; exports.decodeDeepSurface = _chunkQE7D7TZRcjs.decodeDeepSurface; exports.decodeLayerChannel = _chunkQE7D7TZRcjs.decodeLayerChannel; exports.decodeLayerMask = _chunkQE7D7TZRcjs.decodeLayerMask; exports.decodeMergedImage = _chunkQE7D7TZRcjs.decodeMergedImage; exports.decodePlanes = _chunkQE7D7TZRcjs.decodePlanes; exports.decodePng = _chunkOLNIPTB3cjs.decodePng; exports.decodePngDataUrl = _chunkQE7D7TZRcjs.decodePngDataUrl; exports.decodeSelectionRle = _chunkQYLWG22Ncjs.decodeSelectionRle; exports.decontaminateColors = _chunkL52VMQZScjs.decontaminateColors; exports.deepBytes = _chunkOLNIPTB3cjs.deepBytes; exports.deepTile = _chunkOLNIPTB3cjs.deepTile; exports.defaultActiveLayerId = _chunkQE7D7TZRcjs.defaultActiveLayerId; exports.defaultAdjustmentParams = _chunkQE7D7TZRcjs.defaultAdjustmentParams; exports.defaultEffectGradient = _chunkUOGKSVRQcjs.defaultEffectGradient; exports.defaultLayerEffect = _chunkUOGKSVRQcjs.defaultLayerEffect; exports.defaultShapeName = _chunkQE7D7TZRcjs.defaultShapeName; exports.deflate = _chunkXFM3OCHUcjs.deflate; exports.deflateRaw = _chunkXFM3OCHUcjs.deflateRaw; exports.depthMaskAlpha = _chunkQE7D7TZRcjs.depthMaskAlpha; exports.depthOf = _chunkOLNIPTB3cjs.depthOf; exports.depthRasterMask = _chunkQE7D7TZRcjs.depthRasterMask; exports.describeChannel = describeChannel; exports.describeLayer = describeLayer; exports.describeLayerEffects = describeLayerEffects; exports.describeSelection = describeSelection; exports.describeTransform = _chunkQE7D7TZRcjs.describeTransform; exports.deserializeChannels = deserializeChannels; exports.deserializeColorMode = deserializeColorMode; exports.deserializeColorProfile = deserializeColorProfile; exports.deserializeEffects = _chunkQE7D7TZRcjs.deserializeEffects; exports.deserializeLayer = _chunkQE7D7TZRcjs.deserializeLayer; exports.deserializeLayers = _chunkQE7D7TZRcjs.deserializeLayers; exports.deserializeMask = _chunkL52VMQZScjs.deserializeMask; exports.deserializePatterns = _chunkQE7D7TZRcjs.deserializePatterns; exports.deserializeSelection = _chunkQYLWG22Ncjs.deserializeSelection; exports.developFilter = _chunkQE7D7TZRcjs.developFilter; exports.developFromAdjustments = _chunkQE7D7TZRcjs.developFromAdjustments; exports.developTarget = _chunkQE7D7TZRcjs.developTarget; exports.dexp = _chunkKWNMBMKGcjs.dexp; exports.dilateMask = _chunkMQDIP4CFcjs.dilateMask; exports.displayTransform = displayTransform; exports.distanceTransform = _chunkQYLWG22Ncjs.distanceTransform; exports.dlog = _chunkKWNMBMKGcjs.dlog; exports.documentContents = _chunkQE7D7TZRcjs.documentContents; exports.documentProfile = documentProfile; exports.dodgeBurn = _chunkYF3YZZ6Gcjs.dodgeBurn; exports.dodgeBurnCurve = _chunkYF3YZZ6Gcjs.dodgeBurnCurve; exports.downloadMaskImage = downloadMaskImage; exports.downloadPsd = downloadPsd; exports.dpow = _chunkKWNMBMKGcjs.dpow; exports.dragWarpMeshPoint = _chunkQAUIZPYIcjs.dragWarpMeshPoint; exports.dropPlacement = dropPlacement; exports.dropZone = dropZone; exports.dsincos = _chunkKWNMBMKGcjs.dsincos; exports.duplicateLayer = _chunkQE7D7TZRcjs.duplicateLayer; exports.edgeBits = _chunkKWNMBMKGcjs.edgeBits; exports.edgeWidth = _chunkL52VMQZScjs.edgeWidth; exports.effectColorHex = _chunkUOGKSVRQcjs.effectColorHex; exports.effectControlChange = effectControlChange; exports.effectLayerTiming = effectLayerTiming; exports.effectPixelsToSurface = effectPixelsToSurface; exports.effectReach = _chunkUOGKSVRQcjs.effectReach; exports.effectiveLayerMask = _chunkQE7D7TZRcjs.effectiveLayerMask; exports.effectiveProof = effectiveProof; exports.effectsFingerprint = _chunkUOGKSVRQcjs.effectsFingerprint; exports.effectsMargin = _chunkUOGKSVRQcjs.effectsMargin; exports.effectsScale = _chunkUOGKSVRQcjs.effectsScale; exports.ellipsePoints = _chunkL52VMQZScjs.ellipsePoints; exports.ellipseSelection = _chunkL52VMQZScjs.ellipseSelection; exports.emptyHistogram = emptyHistogram; exports.emptySurface = _chunk474IQG74cjs.emptySurface; exports.encodeDeepSurface = _chunkQE7D7TZRcjs.encodeDeepSurface; exports.encodePng = _chunkOLNIPTB3cjs.encodePng; exports.encodeRle = _chunkQE7D7TZRcjs.encodeRle; exports.encodeSelectionRle = _chunkQYLWG22Ncjs.encodeSelectionRle; exports.encodeSurface = _chunkQE7D7TZRcjs.encodeSurface; exports.evalWarpMesh = _chunkQAUIZPYIcjs.evalWarpMesh; exports.evaluateAdjustmentLayers = _chunkQE7D7TZRcjs.evaluateAdjustmentLayers; exports.exchangeRates = _chunkPQ3H2AANcjs.exchangeRates; exports.expNeg = _chunkKWNMBMKGcjs.expNeg; exports.expandCoverage = _chunkQYLWG22Ncjs.expandCoverage; exports.exportPsd = _chunkQE7D7TZRcjs.exportPsd; exports.extractNormalizedLayerItems = extractNormalizedLayerItems; exports.featherCoverage = _chunkQYLWG22Ncjs.featherCoverage; exports.fillRect = _chunk474IQG74cjs.fillRect; exports.filmPixel = _chunkKWNMBMKGcjs.filmPixel; exports.filmReflectance = _chunkKWNMBMKGcjs.filmReflectance; exports.filterMaskCoverage = _chunkQE7D7TZRcjs.filterMaskCoverage; exports.findAdjustmentControl = findAdjustmentControl; exports.findLayer = _chunkUOGKSVRQcjs.findLayer; exports.findLayerControl = findLayerControl; exports.findSky = _chunkL52VMQZScjs.findSky; exports.findSubject = _chunkL52VMQZScjs.findSubject; exports.findWebGpu = _chunkKWNMBMKGcjs.findWebGpu; exports.finishTile = _chunk474IQG74cjs.finishTile; exports.fitParagraphRuns = _chunkQAUIZPYIcjs.fitParagraphRuns; exports.fitRuns = _chunkQAUIZPYIcjs.fitRuns; exports.flattenLayers = _chunkUOGKSVRQcjs.flattenLayers; exports.flattenPath = _chunkQE7D7TZRcjs.flattenPath; exports.flipCorners = _chunkQE7D7TZRcjs.flipCorners; exports.flowField = _chunkKWNMBMKGcjs.flowField; exports.focusArea = _chunkL52VMQZScjs.focusArea; exports.followLayerMove = _chunkQE7D7TZRcjs.followLayerMove; exports.fontOf = _chunkQAUIZPYIcjs.fontOf; exports.forgetSelectAndMaskSettings = forgetSelectAndMaskSettings; exports.formatControlValue = formatControlValue; exports.fullSelection = _chunkQYLWG22Ncjs.fullSelection; exports.gaussianBlur = _chunkK6PXS6DOcjs.gaussianBlur; exports.geometryHomography = _chunkQE7D7TZRcjs.geometryHomography; exports.getAnnotationBounds = _chunkQE7D7TZRcjs.getAnnotationBounds; exports.getControlPath = getControlPath; exports.getCropCursor = _chunkQE7D7TZRcjs.getCropCursor; exports.getRotatedSize = _chunkQE7D7TZRcjs.getRotatedSize; exports.getViewportMetrics = _chunkQE7D7TZRcjs.getViewportMetrics; exports.getViewportProjection = _chunkQE7D7TZRcjs.getViewportProjection; exports.globalImageCache = globalImageCache; exports.grabCutLabels = _chunkL52VMQZScjs.grabCutLabels; exports.gradientDabColor = _chunkPQ3H2AANcjs.gradientDabColor; exports.grainCatch = _chunkPQ3H2AANcjs.grainCatch; exports.grainHeights = _chunkPQ3H2AANcjs.grainHeights; exports.greyMorphology = _chunkQYLWG22Ncjs.greyMorphology; exports.groupLayers = _chunkQE7D7TZRcjs.groupLayers; exports.growSelection = growSelection; exports.guidePlanes = _chunkL52VMQZScjs.guidePlanes; exports.guidedFilterColor = _chunkL52VMQZScjs.guidedFilterColor; exports.handleMaskViewKey = handleMaskViewKey; exports.handlePaintShortcut = handlePaintShortcut; exports.handleQuickMaskKey = handleQuickMaskKey; exports.handleSelectionShortcut = handleSelectionShortcut; exports.hasActiveEffects = _chunkUOGKSVRQcjs.hasActiveEffects; exports.hasLayersBelow = hasLayersBelow; exports.hasResampledLegacyMask = _chunkQE7D7TZRcjs.hasResampledLegacyMask; exports.hasSurface = _chunkQE7D7TZRcjs.hasSurface; exports.hasWarp = _chunkQE7D7TZRcjs.hasWarp; exports.hash2 = _chunkPQ3H2AANcjs.hash2; exports.hashMaskContent = _chunkQYLWG22Ncjs.hashMaskContent; exports.hashNoise = _chunkUOGKSVRQcjs.hashNoise; exports.healPixels = _chunkYF3YZZ6Gcjs.healPixels; exports.hexToPaintRgb = _chunkPQ3H2AANcjs.hexToPaintRgb; exports.hexToRgb = _chunkQE7D7TZRcjs.hexToRgb; exports.histogramPath = histogramPath; exports.hitTestAnnotation = _chunkQE7D7TZRcjs.hitTestAnnotation; exports.hitTestCrop = _chunkQE7D7TZRcjs.hitTestCrop; exports.hitTestCurvePoint = hitTestCurvePoint; exports.homographyFromAffine = _chunkQT26RHKKcjs.homographyFromAffine; exports.homographyFromPoints = _chunkQT26RHKKcjs.homographyFromPoints; exports.hslToRgb = _chunkQE7D7TZRcjs.hslToRgb; exports.hueRange = hueRange; exports.hueRangeTables = _chunkQE7D7TZRcjs.hueRangeTables; exports.hueRangeWeight = _chunkQE7D7TZRcjs.hueRangeWeight; exports.hueSaturation = _chunkQE7D7TZRcjs.hueSaturation; exports.identityCurve = _chunkQE7D7TZRcjs.identityCurve; exports.identityLevels = _chunkQE7D7TZRcjs.identityLevels; exports.identityTransform = _chunkQE7D7TZRcjs.identityTransform; exports.identityWarpMesh = _chunkQAUIZPYIcjs.identityWarpMesh; exports.imageEditorStateMigrations = imageEditorStateMigrations; exports.imageLayerAppliedEffects = imageLayerAppliedEffects; exports.imagePanelTool = imagePanelTool; exports.imagePlaybackPanel = imagePlaybackPanel; exports.imageToCanvasPoint = _chunkQE7D7TZRcjs.imageToCanvasPoint; exports.imageToolCanvasMode = imageToolCanvasMode; exports.imageToolForShortcut = imageToolForShortcut; exports.imageToolGroup = imageToolGroup; exports.imageToolLabel = imageToolLabel; exports.imageToolPanel = imageToolPanel; exports.importPsd = _chunkQE7D7TZRcjs.importPsd; exports.inflate = _chunkXFM3OCHUcjs.inflate; exports.inflateRaw = _chunkXFM3OCHUcjs.inflateRaw; exports.insertCurvePoint = insertCurvePoint; exports.insertLayer = _chunkUOGKSVRQcjs.insertLayer; exports.instancesOf = _chunkQE7D7TZRcjs.instancesOf; exports.invertHomography = _chunkQT26RHKKcjs.invertHomography; exports.invertMatrix3 = _chunkQE7D7TZRcjs.invertMatrix3; exports.invertSelection = _chunkQYLWG22Ncjs.invertSelection; exports.isActiveFilter = _chunkQE7D7TZRcjs.isActiveFilter; exports.isActiveVectorMask = _chunkQE7D7TZRcjs.isActiveVectorMask; exports.isAdjustmentKind = _chunkQE7D7TZRcjs.isAdjustmentKind; exports.isBitDepth = _chunkOLNIPTB3cjs.isBitDepth; exports.isBlendMode = _chunkOLNIPTB3cjs.isBlendMode; exports.isBrushstrokeBrush = _chunkPQ3H2AANcjs.isBrushstrokeBrush; exports.isColorRangePreset = isColorRangePreset; exports.isContentsDecoded = _chunkQE7D7TZRcjs.isContentsDecoded; exports.isDefaultDepthMask = _chunkQE7D7TZRcjs.isDefaultDepthMask; exports.isGradientPaint = _chunkPQ3H2AANcjs.isGradientPaint; exports.isIdentityCloneTransform = _chunkYF3YZZ6Gcjs.isIdentityCloneTransform; exports.isIdentityTransform = _chunkQE7D7TZRcjs.isIdentityTransform; exports.isInterpolation = _chunkUOGKSVRQcjs.isInterpolation; exports.isLayerEffectKind = _chunkUOGKSVRQcjs.isLayerEffectKind; exports.isLayerLocked = _chunkUOGKSVRQcjs.isLayerLocked; exports.isLegacyShape = _chunkQE7D7TZRcjs.isLegacyShape; exports.isPaintTool = isPaintTool; exports.isPaintableLayer = _chunkQE7D7TZRcjs.isPaintableLayer; exports.isPainterlyBlendMode = _chunkOLNIPTB3cjs.isPainterlyBlendMode; exports.isPng = _chunkOLNIPTB3cjs.isPng; exports.isQuarterTurn = isQuarterTurn; exports.isQuarterTurnSwapped = _chunkQE7D7TZRcjs.isQuarterTurnSwapped; exports.isRenderedLayer = _chunkQE7D7TZRcjs.isRenderedLayer; exports.isRetouchPaintTool = isRetouchPaintTool; exports.isRetouchTool = isRetouchTool; exports.isSelectionEmpty = _chunkQYLWG22Ncjs.isSelectionEmpty; exports.isSelectionMode = _chunkQYLWG22Ncjs.isSelectionMode; exports.isSeparableBlendMode = _chunkOLNIPTB3cjs.isSeparableBlendMode; exports.isSmartSurfaceIncomplete = _chunkQE7D7TZRcjs.isSmartSurfaceIncomplete; exports.isSpatialFilter = _chunkQE7D7TZRcjs.isSpatialFilter; exports.isSrgb = isSrgb; exports.isTransformAnchor = _chunkQE7D7TZRcjs.isTransformAnchor; exports.isValidWarp = _chunkQE7D7TZRcjs.isValidWarp; exports.keepDeepSamples = _chunkOLNIPTB3cjs.keepDeepSamples; exports.keepMainPieces = _chunkL52VMQZScjs.keepMainPieces; exports.kelvinToTemperature = _chunkQE7D7TZRcjs.kelvinToTemperature; exports.keysWeight = _chunkUOGKSVRQcjs.keysWeight; exports.latticeViscosity = _chunkKWNMBMKGcjs.latticeViscosity; exports.layerBadge = layerBadge; exports.layerEffectControls = layerEffectControls; exports.layerEffectFields = _chunkUOGKSVRQcjs.layerEffectFields; exports.layerEffectLabel = _chunkUOGKSVRQcjs.layerEffectLabel; exports.layerEffectsBadge = layerEffectsBadge; exports.layerEffectsOf = _chunkQE7D7TZRcjs.layerEffectsOf; exports.layerEffectsPanel = layerEffectsPanel; exports.layerHasThumbnail = layerHasThumbnail; exports.layerLabel = layerLabel; exports.layerMaskCoverage = _chunkQE7D7TZRcjs.layerMaskCoverage; exports.layerMaskFromSelection = _chunkQE7D7TZRcjs.layerMaskFromSelection; exports.layerMaskKey = _chunkQE7D7TZRcjs.layerMaskKey; exports.layerMaskSelection = _chunkQE7D7TZRcjs.layerMaskSelection; exports.layerMenu = layerMenu; exports.layerName = _chunkQE7D7TZRcjs.layerName; exports.layerPanelRows = layerPanelRows; exports.layerPanels = layerPanels; exports.layerThumbnailClick = layerThumbnailClick; exports.layerTree = _chunkQE7D7TZRcjs.layerTree; exports.layerTypeLabel = _chunkQE7D7TZRcjs.layerTypeLabel; exports.layerWarning = layerWarning; exports.layersFromLegacy = _chunkQE7D7TZRcjs.layersFromLegacy; exports.layoutText = _chunkQAUIZPYIcjs.layoutText; exports.legacyAdjustmentLayer = _chunkQE7D7TZRcjs.legacyAdjustmentLayer; exports.legacyMaskOf = _chunkQE7D7TZRcjs.legacyMaskOf; exports.legacyView = _chunkQE7D7TZRcjs.legacyView; exports.lerpPigment = _chunkOLNIPTB3cjs.lerpPigment; exports.lerpPigmentInto = _chunkOLNIPTB3cjs.lerpPigmentInto; exports.levelsValue = _chunkQE7D7TZRcjs.levelsValue; exports.linearSrgbToXy = _chunkQE7D7TZRcjs.linearSrgbToXy; exports.linearToSrgb = _chunkQE7D7TZRcjs.linearToSrgb; exports.linearToSrgb8 = _chunkKWNMBMKGcjs.linearToSrgb8; exports.liveComponent = _chunkQE7D7TZRcjs.liveComponent; exports.liveShapeForDrag = liveShapeForDrag; exports.liveShapeSubpaths = _chunkQE7D7TZRcjs.liveShapeSubpaths; exports.liveWire = liveWire; exports.loadImageEditorDocument = loadImageEditorDocument; exports.loadMixer = _chunkPQ3H2AANcjs.loadMixer; exports.loadOpenTypeFont = _chunk3T5VCDIVcjs.loadOpenTypeFont; exports.loadWetKernel = _chunkKWNMBMKGcjs.loadWetKernel; exports.luma = _chunkYF3YZZ6Gcjs.luma; exports.magicWand = magicWand; exports.magneticAnchorSpacing = magneticAnchorSpacing; exports.mapCropHandle = _chunkQE7D7TZRcjs.mapCropHandle; exports.mapLayer = _chunkUOGKSVRQcjs.mapLayer; exports.mapSubpaths = _chunkQE7D7TZRcjs.mapSubpaths; exports.maskBounds = _chunkMQDIP4CFcjs.maskBounds; exports.maskFileName = maskFileName; exports.maskNameFromFile = maskNameFromFile; exports.maskSummary = maskSummary; exports.maskThumbnailClick = maskThumbnailClick; exports.matrixFromCorners = _chunkQE7D7TZRcjs.matrixFromCorners; exports.matrixFromParams = _chunkQE7D7TZRcjs.matrixFromParams; exports.measureCanvasViewport = measureCanvasViewport; exports.membraneFill = _chunkMQDIP4CFcjs.membraneFill; exports.mergeLayerEffect = _chunkUOGKSVRQcjs.mergeLayerEffect; exports.mergeShapeComponents = _chunkQE7D7TZRcjs.mergeShapeComponents; exports.migrateSerializedImageEditorState = migrateSerializedImageEditorState; exports.migrateToLayeredState = migrateToLayeredState; exports.mix32 = _chunkPQ3H2AANcjs.mix32; exports.mixPigment8 = _chunkOLNIPTB3cjs.mixPigment8; exports.mixPigmentRgb = _chunkOLNIPTB3cjs.mixPigmentRgb; exports.mixPigments = _chunkOLNIPTB3cjs.mixPigments; exports.mixerLoadResult = mixerLoadResult; exports.mixerRates = _chunkPQ3H2AANcjs.mixerRates; exports.modifySelection = _chunkQYLWG22Ncjs.modifySelection; exports.moveCurvePoint = moveCurvePoint; exports.moveLayer = _chunkQE7D7TZRcjs.moveLayer; exports.moveSmartFilter = _chunkQE7D7TZRcjs.moveSmartFilter; exports.mulMatrix3 = _chunkQE7D7TZRcjs.mulMatrix3; exports.needsLegacyBase = needsLegacyBase; exports.neutralHueRange = _chunkQE7D7TZRcjs.neutralHueRange; exports.newContentsId = _chunkQE7D7TZRcjs.newContentsId; exports.newEffectId = _chunkUOGKSVRQcjs.newEffectId; exports.newLayerId = _chunkQE7D7TZRcjs.newLayerId; exports.newLayerOptions = newLayerOptions; exports.normalizeAdjustmentLayer = _chunkQE7D7TZRcjs.normalizeAdjustmentLayer; exports.normalizeAdjustmentLayers = _chunkQE7D7TZRcjs.normalizeAdjustmentLayers; exports.normalizeAngle = _chunkQE7D7TZRcjs.normalizeAngle; exports.normalizeBlendMode = _chunkOLNIPTB3cjs.normalizeBlendMode; exports.normalizeBlender = _chunkPQ3H2AANcjs.normalizeBlender; exports.normalizeBrush = _chunkPQ3H2AANcjs.normalizeBrush; exports.normalizeFilter = _chunkQE7D7TZRcjs.normalizeFilter; exports.normalizeFlow = _chunkKWNMBMKGcjs.normalizeFlow; exports.normalizeHexColor = _chunkPQ3H2AANcjs.normalizeHexColor; exports.normalizeLayerEffects = _chunkUOGKSVRQcjs.normalizeLayerEffects; exports.normalizeLayerMask = _chunkQE7D7TZRcjs.normalizeLayerMask; exports.normalizeLiveShape = _chunkQE7D7TZRcjs.normalizeLiveShape; exports.normalizeMixer = _chunkPQ3H2AANcjs.normalizeMixer; exports.normalizePlacement = _chunkQE7D7TZRcjs.normalizePlacement; exports.normalizeProcessVersion = _chunkQE7D7TZRcjs.normalizeProcessVersion; exports.normalizeRect = _chunkL52VMQZScjs.normalizeRect; exports.normalizeRefineEdgeParams = _chunkL52VMQZScjs.normalizeRefineEdgeParams; exports.normalizeRetouch = _chunkYF3YZZ6Gcjs.normalizeRetouch; exports.normalizeShapePaint = _chunkQE7D7TZRcjs.normalizeShapePaint; exports.normalizeShapeStroke = _chunkQE7D7TZRcjs.normalizeShapeStroke; exports.normalizeSmartFilter = _chunkQE7D7TZRcjs.normalizeSmartFilter; exports.normalizeSmudge = _chunkPQ3H2AANcjs.normalizeSmudge; exports.normalizeStoredAdjustments = normalizeStoredAdjustments; exports.normalizeSubpaths = _chunkQE7D7TZRcjs.normalizeSubpaths; exports.normalizeText = _chunkQE7D7TZRcjs.normalizeText; exports.normalizeTilt = _chunkKWNMBMKGcjs.normalizeTilt; exports.normalizeWetParams = _chunkKWNMBMKGcjs.normalizeWetParams; exports.offsetLayer = _chunkQE7D7TZRcjs.offsetLayer; exports.offsetShape = _chunkQE7D7TZRcjs.offsetShape; exports.offsetSmartObject = _chunkQE7D7TZRcjs.offsetSmartObject; exports.offsetVectorMask = _chunkQE7D7TZRcjs.offsetVectorMask; exports.openMaskFile = openMaskFile; exports.openPsdFile = openPsdFile; exports.otsuThreshold = _chunkL52VMQZScjs.otsuThreshold; exports.packRgba = _chunk474IQG74cjs.packRgba; exports.packWetParams = _chunkKWNMBMKGcjs.packWetParams; exports.paintGradientMappingFor = _chunkPQ3H2AANcjs.paintGradientMappingFor; exports.paintPathStroke = _chunkPQ3H2AANcjs.paintPathStroke; exports.paintSourceColor = _chunkPQ3H2AANcjs.paintSourceColor; exports.paintSourceCss = _chunkPQ3H2AANcjs.paintSourceCss; exports.paragraphRanges = _chunkQAUIZPYIcjs.paragraphRanges; exports.parseAdjustmentBlock = _chunkQE7D7TZRcjs.parseAdjustmentBlock; exports.parseBlend = _chunkQE7D7TZRcjs.parseBlend; exports.parseColor = parseColor; exports.parseCssColor = _chunkA2IS7EHEcjs.parseCssColor; exports.parseDataUrl = _chunkOLNIPTB3cjs.parseDataUrl; exports.parseEffectColor = _chunkUOGKSVRQcjs.parseEffectColor; exports.parseLfx2 = _chunkQE7D7TZRcjs.parseLfx2; exports.parseLrfx = _chunkQE7D7TZRcjs.parseLrfx; exports.parseOpenTypeFont = _chunk3T5VCDIVcjs.parseOpenTypeFont; exports.parsePaintSource = _chunkPQ3H2AANcjs.parsePaintSource; exports.parsePatternBlock = _chunkQE7D7TZRcjs.parsePatternBlock; exports.parseSelectionMode = _chunkQYLWG22Ncjs.parseSelectionMode; exports.parseVersionedDescriptor = _chunkQE7D7TZRcjs.parseVersionedDescriptor; exports.patchParagraphStyle = _chunkQE7D7TZRcjs.patchParagraphStyle; exports.patchTextStyle = _chunkQE7D7TZRcjs.patchTextStyle; exports.pathStrokeCoverage = _chunkPQ3H2AANcjs.pathStrokeCoverage; exports.pathStrokeDabs = _chunkPQ3H2AANcjs.pathStrokeDabs; exports.pathToSelection = pathToSelection; exports.perDabStrength = _chunkYF3YZZ6Gcjs.perDabStrength; exports.photoFilterMatrix = _chunkQE7D7TZRcjs.photoFilterMatrix; exports.pigment8 = _chunkOLNIPTB3cjs.pigment8; exports.pigmentColor = _chunkKWNMBMKGcjs.pigmentColor; exports.pigmentOf = _chunkKWNMBMKGcjs.pigmentOf; exports.pixelLayerBounds = _chunkQE7D7TZRcjs.pixelLayerBounds; exports.pixelLayers = _chunkQE7D7TZRcjs.pixelLayers; exports.pixelPigment = _chunkKWNMBMKGcjs.pixelPigment; exports.placeContents = _chunkQE7D7TZRcjs.placeContents; exports.placeLayer = _chunkQE7D7TZRcjs.placeLayer; exports.placementAt = _chunkQE7D7TZRcjs.placementAt; exports.placementBounds = _chunkQE7D7TZRcjs.placementBounds; exports.placementGeometry = _chunkQE7D7TZRcjs.placementGeometry; exports.planImageToolPlayback = planImageToolPlayback; exports.planOutlineTrace = planOutlineTrace; exports.pngDataUrl = _chunkOLNIPTB3cjs.pngDataUrl; exports.pointerPressure = _chunkKWNMBMKGcjs.pointerPressure; exports.pointerStrokeSample = _chunkKWNMBMKGcjs.pointerStrokeSample; exports.pointerStrokeSamples = _chunkKWNMBMKGcjs.pointerStrokeSamples; exports.polygonCoverage = _chunkL52VMQZScjs.polygonCoverage; exports.polygonCoverageBox = _chunkL52VMQZScjs.polygonCoverageBox; exports.polygonSelection = _chunkL52VMQZScjs.polygonSelection; exports.posterizeValue = _chunkQE7D7TZRcjs.posterizeValue; exports.presetWarp = _chunkQE7D7TZRcjs.presetWarp; exports.previewStep = previewStep; exports.profileBytes = profileBytes; exports.projectImagePoint = _chunkQE7D7TZRcjs.projectImagePoint; exports.projectImageRect = _chunkQE7D7TZRcjs.projectImageRect; exports.projectMaskCoverage = _chunkQE7D7TZRcjs.projectMaskCoverage; exports.projectQuarterTurn = projectQuarterTurn; exports.proxyOf = _chunkOLNIPTB3cjs.proxyOf; exports.psdBytesFromBase64 = psdBytesFromBase64; exports.psdFileName = psdFileName; exports.psdPatternToEffectPattern = _chunkQE7D7TZRcjs.psdPatternToEffectPattern; exports.psdToLayers = _chunkQE7D7TZRcjs.psdToLayers; exports.pullWarpMesh = _chunkQAUIZPYIcjs.pullWarpMesh; exports.put255 = _chunkPQ3H2AANcjs.put255; exports.quadFrameOverlay = quadFrameOverlay; exports.quickMaskPixels = quickMaskPixels; exports.quickSelectStroke = _chunkL52VMQZScjs.quickSelectStroke; exports.rand01 = _chunkPQ3H2AANcjs.rand01; exports.randSigned = _chunkPQ3H2AANcjs.randSigned; exports.rangeLightness = _chunkQE7D7TZRcjs.rangeLightness; exports.rasterContents = _chunkQE7D7TZRcjs.rasterContents; exports.rasterMaskFromLegacy = _chunkQE7D7TZRcjs.rasterMaskFromLegacy; exports.rasterizeCoverage = _chunkQE7D7TZRcjs.rasterizeCoverage; exports.rasterizeDab = _chunkPQ3H2AANcjs.rasterizeDab; exports.rasterizeSmartObject = _chunkQE7D7TZRcjs.rasterizeSmartObject; exports.readAdjustmentControls = readAdjustmentControls; exports.readDeepRegion = _chunkOLNIPTB3cjs.readDeepRegion; exports.readPaintSource = _chunkPQ3H2AANcjs.readPaintSource; exports.readPixel = _chunk474IQG74cjs.readPixel; exports.readPsd = _chunkQE7D7TZRcjs.readPsd; exports.readRegion = _chunk474IQG74cjs.readRegion; exports.readSourceRegion = _chunkYF3YZZ6Gcjs.readSourceRegion; exports.rectSelection = _chunkL52VMQZScjs.rectSelection; exports.rectToQuad = _chunkQT26RHKKcjs.rectToQuad; exports.reduceSurface = _chunkUOGKSVRQcjs.reduceSurface; exports.referencePoint = _chunkQE7D7TZRcjs.referencePoint; exports.refineCoverage = _chunkL52VMQZScjs.refineCoverage; exports.refineEdgeHalo = _chunkL52VMQZScjs.refineEdgeHalo; exports.refineSelection = _chunkL52VMQZScjs.refineSelection; exports.reflectanceToRgb = _chunkOLNIPTB3cjs.reflectanceToRgb; exports.removeAlpha = _chunkQE7D7TZRcjs.removeAlpha; exports.removeCurvePoint = removeCurvePoint; exports.removeLayer = _chunkQE7D7TZRcjs.removeLayer; exports.removeLayerEffect = _chunkQE7D7TZRcjs.removeLayerEffect; exports.removeLayerFilter = _chunkQE7D7TZRcjs.removeLayerFilter; exports.removePaintGradientStop = _chunkPQ3H2AANcjs.removePaintGradientStop; exports.removeSmartFilter = _chunkQE7D7TZRcjs.removeSmartFilter; exports.renderBrushstroke = _chunkPQ3H2AANcjs.renderBrushstroke; exports.renderLayerEffects = _chunkUOGKSVRQcjs.renderLayerEffects; exports.renderLayeredBase = renderLayeredBase; exports.renderShape = _chunkQE7D7TZRcjs.renderShape; exports.renderShapeRect = _chunkQE7D7TZRcjs.renderShapeRect; exports.renderSmartObject = _chunkQE7D7TZRcjs.renderSmartObject; exports.renderText = _chunkQE7D7TZRcjs.renderText; exports.replaceContents = _chunkQE7D7TZRcjs.replaceContents; exports.replaceTextRange = _chunkQE7D7TZRcjs.replaceTextRange; exports.requireLayer = _chunkQE7D7TZRcjs.requireLayer; exports.requireOperation = _chunkQE7D7TZRcjs.requireOperation; exports.requireShapeLayer = _chunkQE7D7TZRcjs.requireShapeLayer; exports.requireSmartObject = _chunkQE7D7TZRcjs.requireSmartObject; exports.requireTypeLayer = _chunkQE7D7TZRcjs.requireTypeLayer; exports.requireUnlocked = _chunkQE7D7TZRcjs.requireUnlocked; exports.rerender = _chunkQE7D7TZRcjs.rerender; exports.rerenderShape = _chunkQE7D7TZRcjs.rerenderShape; exports.rerenderText = _chunkQE7D7TZRcjs.rerenderText; exports.resizePixels = resizePixels; exports.resizeSelection = _chunkQYLWG22Ncjs.resizeSelection; exports.resizeWarpMesh = _chunkQAUIZPYIcjs.resizeWarpMesh; exports.resolveExternalAssets = _chunkQE7D7TZRcjs.resolveExternalAssets; exports.resolveMosaicRegionBounds = resolveMosaicRegionBounds; exports.resolvePaintGradient = _chunkPQ3H2AANcjs.resolvePaintGradient; exports.resolveProfile = resolveProfile; exports.resolveVectorMasks = _chunkQE7D7TZRcjs.resolveVectorMasks; exports.restyleRange = _chunkQAUIZPYIcjs.restyleRange; exports.retouchFilter = _chunkYF3YZZ6Gcjs.retouchFilter; exports.reversePaintGradient = _chunkPQ3H2AANcjs.reversePaintGradient; exports.rgbToGray = _chunkQE7D7TZRcjs.rgbToGray; exports.rgbToHsl = _chunkQE7D7TZRcjs.rgbToHsl; exports.rgbToReflectance = _chunkOLNIPTB3cjs.rgbToReflectance; exports.rgbUnitToHex = rgbUnitToHex; exports.rgbaViewOfGrey = _chunkYF3YZZ6Gcjs.rgbaViewOfGrey; exports.runLayerFilters = _chunkQE7D7TZRcjs.runLayerFilters; exports.runLayerFiltersFloat = _chunkQE7D7TZRcjs.runLayerFiltersFloat; exports.runLayerMenuAction = runLayerMenuAction; exports.runSelectionJob = _chunkL52VMQZScjs.runSelectionJob; exports.sameCanvasViewport = sameCanvasViewport; exports.sampleLut = _chunkQE7D7TZRcjs.sampleLut; exports.sampleToneLut = _chunkQE7D7TZRcjs.sampleToneLut; exports.saturationOf = _chunkYF3YZZ6Gcjs.saturationOf; exports.scaleLayerEffect = _chunkUOGKSVRQcjs.scaleLayerEffect; exports.scalePaintGradient = _chunkPQ3H2AANcjs.scalePaintGradient; exports.seamlessClone = _chunkMQDIP4CFcjs.seamlessClone; exports.seedFromString = _chunkPQ3H2AANcjs.seedFromString; exports.segmentToSelection = segmentToSelection; exports.segmentationOutlines = segmentationOutlines; exports.segmentsToSelection = segmentsToSelection; exports.selectObjectIn = _chunkL52VMQZScjs.selectObjectIn; exports.selectSimilar = selectSimilar; exports.selectionArea = _chunkQYLWG22Ncjs.selectionArea; exports.selectionFromCoverage = _chunkQYLWG22Ncjs.selectionFromCoverage; exports.selectionFromPixels = _chunkQYLWG22Ncjs.selectionFromPixels; exports.selectionFromRegion = _chunkQYLWG22Ncjs.selectionFromRegion; exports.selectionFromTiles = _chunkQYLWG22Ncjs.selectionFromTiles; exports.selectionModeFromModifiers = selectionModeFromModifiers; exports.selectionOutline = selectionOutline; exports.selectionRing = selectionRing; exports.selectionToCoverage = _chunkQYLWG22Ncjs.selectionToCoverage; exports.selectionToPixels = _chunkQYLWG22Ncjs.selectionToPixels; exports.selectionToSubpaths = selectionToSubpaths; exports.selectionValueAt = _chunkQYLWG22Ncjs.selectionValueAt; exports.serializeChannels = serializeChannels; exports.serializeColorMode = serializeColorMode; exports.serializeColorProfile = serializeColorProfile; exports.serializeContents = _chunkQE7D7TZRcjs.serializeContents; exports.serializeEffects = _chunkQE7D7TZRcjs.serializeEffects; exports.serializeLayer = _chunkQE7D7TZRcjs.serializeLayer; exports.serializeLayers = _chunkQE7D7TZRcjs.serializeLayers; exports.serializeLayersExternal = _chunkQE7D7TZRcjs.serializeLayersExternal; exports.serializeMask = _chunkL52VMQZScjs.serializeMask; exports.serializePatterns = _chunkQE7D7TZRcjs.serializePatterns; exports.serializeSelection = _chunkQYLWG22Ncjs.serializeSelection; exports.setCloneTransformValue = setCloneTransformValue; exports.setControlPath = setControlPath; exports.setLayerEffects = _chunkQE7D7TZRcjs.setLayerEffects; exports.setLayerEffectsEnabled = _chunkQE7D7TZRcjs.setLayerEffectsEnabled; exports.setLayerMask = _chunkQE7D7TZRcjs.setLayerMask; exports.setLayerProperties = _chunkQE7D7TZRcjs.setLayerProperties; exports.setLum = _chunkOLNIPTB3cjs.setLum; exports.setPigmentColor = _chunkOLNIPTB3cjs.setPigmentColor; exports.setRetouchChoice = setRetouchChoice; exports.setSmartFilterMask = _chunkQE7D7TZRcjs.setSmartFilterMask; exports.setSmartFiltersEnabled = _chunkQE7D7TZRcjs.setSmartFiltersEnabled; exports.setSmartPlacement = _chunkQE7D7TZRcjs.setSmartPlacement; exports.shadeTile = _chunkKWNMBMKGcjs.shadeTile; exports.shapeAsPixelLayer = _chunkQE7D7TZRcjs.shapeAsPixelLayer; exports.shapeFromAnnotation = _chunkQE7D7TZRcjs.shapeFromAnnotation; exports.shapeGeometryBounds = _chunkQE7D7TZRcjs.shapeGeometryBounds; exports.shapeLayers = _chunkQE7D7TZRcjs.shapeLayers; exports.shapeOutline = _chunkQE7D7TZRcjs.shapeOutline; exports.shapeRenderClip = _chunkQE7D7TZRcjs.shapeRenderClip; exports.shiftCoverage = _chunkQYLWG22Ncjs.shiftCoverage; exports.simplifyPixelPath = simplifyPixelPath; exports.skinToneRange = skinToneRange; exports.slicSuperpixels = _chunkL52VMQZScjs.slicSuperpixels; exports.smartFilterRows = smartFilterRows; exports.smartObjectLayers = _chunkQE7D7TZRcjs.smartObjectLayers; exports.smoothCoverage = _chunkQYLWG22Ncjs.smoothCoverage; exports.smoothPoints = _chunkPQ3H2AANcjs.smoothPoints; exports.smoothnessWeights = _chunkL52VMQZScjs.smoothnessWeights; exports.smudgeEffect = _chunkYF3YZZ6Gcjs.smudgeEffect; exports.snapPolygonToEdges = snapPolygonToEdges; exports.snapTo45 = snapTo45; exports.snapToEdge = snapToEdge; exports.softMaskToSelection = _chunkL52VMQZScjs.softMaskToSelection; exports.solidPaint = _chunkPQ3H2AANcjs.solidPaint; exports.solidSurface = _chunk474IQG74cjs.solidSurface; exports.solveMembrane = _chunkMQDIP4CFcjs.solveMembrane; exports.spliceRuns = _chunkQAUIZPYIcjs.spliceRuns; exports.splitOverlayAnnotations = splitOverlayAnnotations; exports.sponge = _chunkYF3YZZ6Gcjs.sponge; exports.spongeEffect = _chunkYF3YZZ6Gcjs.spongeEffect; exports.spotHealPixels = _chunkYF3YZZ6Gcjs.spotHealPixels; exports.spotHealWindow = _chunkYF3YZZ6Gcjs.spotHealWindow; exports.srgb8ToLab = srgb8ToLab; exports.srgbByteToLinear = _chunkKWNMBMKGcjs.srgbByteToLinear; exports.srgbDecode = _chunkOLNIPTB3cjs.srgbDecode; exports.srgbEncode = _chunkOLNIPTB3cjs.srgbEncode; exports.srgbToLinear = _chunkQE7D7TZRcjs.srgbToLinear; exports.standardBlendMode = _chunkOLNIPTB3cjs.standardBlendMode; exports.startMarchingAnts = startMarchingAnts; exports.startSelectionWorker = _chunkL52VMQZScjs.startSelectionWorker; exports.stepSlotTs = _chunkKWNMBMKGcjs.stepSlotTs; exports.strokeGrainCatch = _chunkPQ3H2AANcjs.strokeGrainCatch; exports.styleAt = _chunkQAUIZPYIcjs.styleAt; exports.subpathsToSvgPath = subpathsToSvgPath; exports.sumHistograms = sumHistograms; exports.superpixelSaliency = _chunkL52VMQZScjs.superpixelSaliency; exports.surfaceBytes = _chunk474IQG74cjs.surfaceBytes; exports.surfaceDepth = _chunkOLNIPTB3cjs.surfaceDepth; exports.surfaceFromDeepPixels = _chunkOLNIPTB3cjs.surfaceFromDeepPixels; exports.surfaceFromPixels = _chunk474IQG74cjs.surfaceFromPixels; exports.surfacesEqual = _chunk474IQG74cjs.surfacesEqual; exports.tempTintToXy = _chunkQE7D7TZRcjs.tempTintToXy; exports.temperatureToKelvin = _chunkQE7D7TZRcjs.temperatureToKelvin; exports.textIndexAt = _chunkQAUIZPYIcjs.textIndexAt; exports.textMatrix = _chunkQE7D7TZRcjs.textMatrix; exports.textOrientation = _chunkQE7D7TZRcjs.textOrientation; exports.textOutlines = _chunkQE7D7TZRcjs.textOutlines; exports.textRange = _chunkQE7D7TZRcjs.textRange; exports.tileCoord = _chunk474IQG74cjs.tileCoord; exports.tileKey = _chunk474IQG74cjs.tileKey; exports.tileRect = _chunk474IQG74cjs.tileRect; exports.tileSamples = _chunkOLNIPTB3cjs.tileSamples; exports.tileSamples16 = _chunkOLNIPTB3cjs.tileSamples16; exports.tileSamples32 = _chunkOLNIPTB3cjs.tileSamples32; exports.tilesInRect = _chunk474IQG74cjs.tilesInRect; exports.tipFalloff = _chunkPQ3H2AANcjs.tipFalloff; exports.tipReach = _chunkPQ3H2AANcjs.tipReach; exports.tipShape = _chunkPQ3H2AANcjs.tipShape; exports.to16From32 = _chunkOLNIPTB3cjs.to16From32; exports.to16From8 = _chunkOLNIPTB3cjs.to16From8; exports.to32From16 = _chunkOLNIPTB3cjs.to32From16; exports.to32From8 = _chunkOLNIPTB3cjs.to32From8; exports.to8From16 = _chunkOLNIPTB3cjs.to8From16; exports.to8From32 = _chunkOLNIPTB3cjs.to8From32; exports.toHex = toHex; exports.toTextSpace = _chunkQE7D7TZRcjs.toTextSpace; exports.toneCurve = _chunkQE7D7TZRcjs.toneCurve; exports.toneLuts = _chunkQE7D7TZRcjs.toneLuts; exports.toneOf = _chunkYF3YZZ6Gcjs.toneOf; exports.toneRange = toneRange; exports.transformHomography = _chunkQE7D7TZRcjs.transformHomography; exports.transformMap = _chunkQE7D7TZRcjs.transformMap; exports.transformShapeComponents = _chunkQE7D7TZRcjs.transformShapeComponents; exports.transformSurface = _chunkUOGKSVRQcjs.transformSurface; exports.transformTypeLayer = _chunkQE7D7TZRcjs.transformTypeLayer; exports.transformVectorMask = _chunkQE7D7TZRcjs.transformVectorMask; exports.transformedBounds = _chunkUOGKSVRQcjs.transformedBounds; exports.transformedBox = _chunkQE7D7TZRcjs.transformedBox; exports.transformedPoint = _chunkQE7D7TZRcjs.transformedPoint; exports.translateLayer = _chunkQE7D7TZRcjs.translateLayer; exports.translateSurface = _chunk474IQG74cjs.translateSurface; exports.typeAsPixelLayer = _chunkQE7D7TZRcjs.typeAsPixelLayer; exports.typeFrame = _chunkQE7D7TZRcjs.typeFrame; exports.typeFromAnnotation = _chunkQE7D7TZRcjs.typeFromAnnotation; exports.typeLayerAt = typeLayerAt; exports.typeLayerName = _chunkQE7D7TZRcjs.typeLayerName; exports.ungroupLayer = _chunkQE7D7TZRcjs.ungroupLayer; exports.uniformTile = _chunk474IQG74cjs.uniformTile; exports.unionRect = _chunkQE7D7TZRcjs.unionRect; exports.unprojectCanvasPoint = _chunkQE7D7TZRcjs.unprojectCanvasPoint; exports.updateLayerEffect = _chunkQE7D7TZRcjs.updateLayerEffect; exports.updateLayerFilter = _chunkQE7D7TZRcjs.updateLayerFilter; exports.updateLayerMaskProps = _chunkQE7D7TZRcjs.updateLayerMaskProps; exports.updatePaintGradientStop = _chunkPQ3H2AANcjs.updatePaintGradientStop; exports.updateShapeLayer = _chunkQE7D7TZRcjs.updateShapeLayer; exports.updateSmartFilter = _chunkQE7D7TZRcjs.updateSmartFilter; exports.updateTypeLayer = _chunkQE7D7TZRcjs.updateTypeLayer; exports.upscaleRegion = _chunkL52VMQZScjs.upscaleRegion; exports.userErrorMessage = _chunkQE7D7TZRcjs.userErrorMessage; exports.uvToXy = _chunkQE7D7TZRcjs.uvToXy; exports.validateEffectGradient = _chunkUOGKSVRQcjs.validateEffectGradient; exports.validateLayerEffect = _chunkUOGKSVRQcjs.validateLayerEffect; exports.validateLayerEffects = _chunkUOGKSVRQcjs.validateLayerEffects; exports.vectorMaskBounds = _chunkQE7D7TZRcjs.vectorMaskBounds; exports.vectorMaskCoverage = _chunkQE7D7TZRcjs.vectorMaskCoverage; exports.vectorMaskThumbnail = _chunkQE7D7TZRcjs.vectorMaskThumbnail; exports.vectorMaskThumbnailClick = vectorMaskThumbnailClick; exports.versionedDescriptorBytes = _chunkQE7D7TZRcjs.versionedDescriptorBytes; exports.vibranceLinear = _chunkQE7D7TZRcjs.vibranceLinear; exports.vibrancePixel = _chunkQE7D7TZRcjs.vibrancePixel; exports.walkDabs = _chunkPQ3H2AANcjs.walkDabs; exports.warpMeshEditPoints = _chunkQAUIZPYIcjs.warpMeshEditPoints; exports.warpMeshGridCurves = _chunkQAUIZPYIcjs.warpMeshGridCurves; exports.warpMeshParamAt = _chunkQAUIZPYIcjs.warpMeshParamAt; exports.warpPresetMesh = _chunkQAUIZPYIcjs.warpPresetMesh; exports.warpSurface = _chunkUOGKSVRQcjs.warpSurface; exports.watchCanvasViewport = watchCanvasViewport; exports.wbMatrix = _chunkQE7D7TZRcjs.wbMatrix; exports.wetGpuSupport = _chunkKWNMBMKGcjs.wetGpuSupport; exports.wetSimdSupported = _chunkKWNMBMKGcjs.wetSimdSupported; exports.wetSupport = _chunkKWNMBMKGcjs.wetSupport; exports.whiteBalanceFromSample = _chunkQE7D7TZRcjs.whiteBalanceFromSample; exports.whiteBalanceMatrix = _chunkQE7D7TZRcjs.whiteBalanceMatrix; exports.withBackgroundOpacity = withBackgroundOpacity; exports.withFilterMaskSurface = _chunkQE7D7TZRcjs.withFilterMaskSurface; exports.withImagePlayback = withImagePlayback; exports.withNewIds = _chunkQE7D7TZRcjs.withNewIds; exports.workImage = _chunkL52VMQZScjs.workImage; exports.workLuma = _chunkL52VMQZScjs.workLuma; exports.workPlanes = _chunkL52VMQZScjs.workPlanes; exports.writeAdjustmentBlock = _chunkQE7D7TZRcjs.writeAdjustmentBlock; exports.writeDeepRegion = _chunkOLNIPTB3cjs.writeDeepRegion; exports.writeLfx2 = _chunkQE7D7TZRcjs.writeLfx2; exports.writePatternBlock = _chunkQE7D7TZRcjs.writePatternBlock; exports.writePsd = _chunkQE7D7TZRcjs.writePsd; exports.writeRegion = _chunk474IQG74cjs.writeRegion; exports.xyToTempTint = _chunkQE7D7TZRcjs.xyToTempTint; exports.xyToUv = _chunkQE7D7TZRcjs.xyToUv;
|