@pixerate/editor 0.95.0 → 0.96.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/THIRD_PARTY_NOTICES.md +1 -0
- package/dist/{chunk-E2ILRYTJ.js → chunk-KFTQ2PKP.js} +18 -1
- package/dist/chunk-KFTQ2PKP.js.map +1 -0
- package/dist/{chunk-T6H3JDGA.cjs → chunk-T422YCHR.cjs} +18 -1
- package/dist/chunk-T422YCHR.cjs.map +1 -0
- package/dist/image-editor/index.cjs +1311 -315
- package/dist/image-editor/index.cjs.map +1 -1
- package/dist/image-editor/index.d.cts +98 -5
- package/dist/image-editor/index.d.ts +98 -5
- package/dist/image-editor/index.js +1081 -85
- package/dist/image-editor/index.js.map +1 -1
- package/dist/paint/index.d.cts +1 -1
- package/dist/paint/index.d.ts +1 -1
- package/dist/raster/index.cjs +2 -2
- package/dist/raster/index.d.cts +796 -5
- package/dist/raster/index.d.ts +796 -5
- package/dist/raster/index.js +1 -1
- package/dist/{surface-CgAiXVI3.d.cts → surface-DIA-XatS.d.cts} +1 -1
- package/dist/{surface-CgAiXVI3.d.ts → surface-DIA-XatS.d.ts} +1 -1
- package/package.json +1 -1
- package/skills/pixerate-image-editor/SKILL.md +13 -4
- package/dist/chunk-E2ILRYTJ.js.map +0 -1
- package/dist/chunk-T6H3JDGA.cjs.map +0 -1
- package/dist/zlib-B3LIoxF-.d.cts +0 -796
- package/dist/zlib-eiTEEj1z.d.ts +0 -796
package/THIRD_PARTY_NOTICES.md
CHANGED
|
@@ -191,6 +191,7 @@ GridCraft. Apache POI is © The Apache Software Foundation, licensed under the A
|
|
|
191
191
|
- `crates/io/src/psd_export.rs` and `crates/psd/src/builder.rs` (layer records with RLE channels, group divider and folder records, adjustment blocks, user masks with parameters, `luni` / `lyid` / `iOpa` / `lspf`, the resolution and version-info resources, PSB above 30 000 px) → `packages/core/src/image-editor/psd/export.ts`; 8-bit RGB only, with the merged image from our compositor
|
|
192
192
|
- `crates/doc/src/effects.rs` (the layer-style model: shadows, glows, strokes, satin, bevel & emboss with its Contour and Texture elements, colour / gradient / pattern overlays, the shared enabled / blend / opacity, Photoshop's defaults, the global light) → `packages/core/src/raster/effects/model.ts`; colours are `#rrggbb`, effects carry ids, and validation, merging and Scale Effects are our own
|
|
193
193
|
- `crates/compose/src/effects.rs` (render order and the per-kind maps: `margin`, `maps_are_local`, the Felzenszwalb–Huttenlocher `dt1` / `edt_nearest`, the 5 × 5 `chamfer_from`, `dist_outside` / `dist_inside` with coverage-placed edges, `local_coverage`, `dilate`, `spread_split`, the fractional `box_geom` / `box_line` / `tent_line` blur, `contour_lut` with corners, `ranged_lut`, `satin_lut`, `hash_noise` / `noise`, `shadow_map`, `glow_map`, `satin_map`, `bevel_geom`, `bevel_chisel_h`, `bevel_height`, `bevel_maps`, `gradient_units`, `gradient_t`, `paint_glow`, `stroke_widths`, the stroke frame and the outside-stroke shares, `knock_out_exterior`, `premerges_layer` and `composite_with_effects`), `crates/compose/src/fill_layout.rs` (`gradient_layout`) and `crates/compose/src/pattern.rs` (`Tile::sample`, `Placement`) → `packages/core/src/raster/effects/render.ts` and `patterns.ts`; single-threaded, without vector-shape outlines, text gamma, Transparency Shapes Layer or Blend Interior Effects as Group, with chiselled bevel edges measured to the coverage-gradient edge line instead of photocraft's sharp-edge refinement, and the maps built once per layer region and cropped per tile by our compositor; the built-in patterns are our own; test cases re-expressed → `packages/core/tests/raster-effects.test.ts`
|
|
194
|
+
- `crates/io/src/effects_map.rs` (`parse_lfx2` / `write_lfx2`: the per-kind descriptor keys, the single and `…Multi` instance keys, `present` / `enab`, blend ids as four-character codes or long string ids, contours with corner points, `parse_lrfx` for legacy effects), `crates/io/src/blocks.rs` (`color_from_desc` / `color_to_desc`, `gradient_style`, the `Grdn` colour and transparency stops, `pattern_ref`, `pattern_placement`), `crates/io/src/psd_import.rs` / `psd_export.rs` (`lmfx` over `lfx2` / `lfxs`, the block kept and written back while the effects are unchanged, odd-length blocks padded) and `crates/psd/src/patterns.rs` (`Patt` / `Pat2` / `Pat3` blocks: patterns, virtual memory array lists, written channels, padded channel rectangles) → `packages/core/src/image-editor/psd/effects.ts` and `patterns.ts`; gradient midpoints become extra stops and smoothness is drawn linearly (photocraft bakes Photoshop's interpolation), and patterns are written as 8-bit RGB; test cases re-expressed → `packages/core/tests/image-psd-effects.test.ts`
|
|
194
195
|
|
|
195
196
|
## soundcraft
|
|
196
197
|
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
isBlendMode,
|
|
7
7
|
isSeparableBlendMode,
|
|
8
8
|
mixPigment8,
|
|
9
|
+
mixPigmentRgb,
|
|
9
10
|
readRegion,
|
|
10
11
|
surfaceFromPixels,
|
|
11
12
|
tileKey,
|
|
@@ -372,6 +373,7 @@ function oneOf(r, key, path, values) {
|
|
|
372
373
|
}
|
|
373
374
|
function blend(r, key, path) {
|
|
374
375
|
if (!isBlendMode(r[key])) fail(`${path}.${key}`, `must be a blend mode such as normal, multiply or screen (got ${JSON.stringify(r[key])}).`);
|
|
376
|
+
if (r[key] === "pigment") fail(`${path}.${key}`, "pigment is a layer blend mode only; effects cannot use it.");
|
|
375
377
|
}
|
|
376
378
|
function contour(v, path) {
|
|
377
379
|
if (v === void 0) return;
|
|
@@ -1452,6 +1454,7 @@ function buildEffectMaps(items, shape, rect, ctx) {
|
|
|
1452
1454
|
}
|
|
1453
1455
|
var rgbScratchB = [0, 0, 0];
|
|
1454
1456
|
var rgbScratchS = [0, 0, 0];
|
|
1457
|
+
var rgbScratchM = [0, 0, 0];
|
|
1455
1458
|
function compositeAt(dst, i, mode, separable, sr, sg, sb, sa) {
|
|
1456
1459
|
if (!(sa > 0)) return;
|
|
1457
1460
|
const ab = dst[i + 3];
|
|
@@ -1463,6 +1466,20 @@ function compositeAt(dst, i, mode, separable, sr, sg, sb, sa) {
|
|
|
1463
1466
|
const b0 = dst[i];
|
|
1464
1467
|
const b1 = dst[i + 1];
|
|
1465
1468
|
const b2 = dst[i + 2];
|
|
1469
|
+
if (mode === "pigment") {
|
|
1470
|
+
rgbScratchB[0] = b0;
|
|
1471
|
+
rgbScratchB[1] = b1;
|
|
1472
|
+
rgbScratchB[2] = b2;
|
|
1473
|
+
rgbScratchS[0] = sr;
|
|
1474
|
+
rgbScratchS[1] = sg;
|
|
1475
|
+
rgbScratchS[2] = sb;
|
|
1476
|
+
mixPigmentRgb(rgbScratchB, rgbScratchS, sa / ao, rgbScratchM);
|
|
1477
|
+
dst[i] = rgbScratchM[0];
|
|
1478
|
+
dst[i + 1] = rgbScratchM[1];
|
|
1479
|
+
dst[i + 2] = rgbScratchM[2];
|
|
1480
|
+
dst[i + 3] = ao;
|
|
1481
|
+
return;
|
|
1482
|
+
}
|
|
1466
1483
|
let m0;
|
|
1467
1484
|
let m1;
|
|
1468
1485
|
let m2;
|
|
@@ -3692,4 +3709,4 @@ export {
|
|
|
3692
3709
|
parseDataUrl,
|
|
3693
3710
|
pngDataUrl
|
|
3694
3711
|
};
|
|
3695
|
-
//# sourceMappingURL=chunk-
|
|
3712
|
+
//# sourceMappingURL=chunk-KFTQ2PKP.js.map
|