mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-16 00:21:33 +00:00
Image Trace: Abutting traces draw seam fills under their paths
An Abutting trace with Fills now holds a "Seam Fills" group under its paths. For each color it has one stroke, 1.5 image pixels wide, along the edges where a filled path of that color meets a filled path drawn after it, in that color. A renderer that anti-aliases each path on its own no longer shows a light hairline along those edges. The traced paths and their shared edges do not change, and edges against the image's border, a transparent area or a color left out get no stroke. - vectorcraft-trace: `seam_fills` finds the segments two filled paths share and strokes them in the lower path's color (one stroke per gradient path). Overlapping, traces without Fills and Flat Logo get none. - Image Trace commands: the group comes under every path (right above the hidden image in a live trace). Expand keeps it, Expand by color leaves it under the color groups, and a trace whose paths have more than half of the anchor limit gets no seam fills. Docs: docs/mcp.md, the params text, docs/target-app-parity.md.
This commit is contained in:
+10
@@ -3691,6 +3691,16 @@ already walks Image Trace. Short agent entry points:
|
||||
black ring around a white disc around a black dot, black gets two groups. `layer.releaseToLayers` on the expanded group then
|
||||
gives each group a sublayer. A trace made with `autoGrouping` is refused. Expanding by color also refuses a trace
|
||||
with a live Pathfinder effect.
|
||||
An Abutting trace with Fills (not Flat Logo) also holds a group named `Seam Fills` under its paths: for each color, a
|
||||
stroke 1.5 image pixels wide (at the image's larger scale, when it is stretched more one way) with butt caps and round joins along the edges where a filled path of that color meets a
|
||||
filled path drawn after it, in that color (a gradient path's stroke takes its gradient). Without it, a renderer that
|
||||
anti-aliases each path on its own shows a light hairline along every shared edge. The traced paths and their shared
|
||||
edges are the same with or without it, and edges against the image's border, a transparent area or a color left out
|
||||
get no stroke. A trace whose paths have more than half of the trace's anchor limit (8,000,000, 2,000,000 on the web)
|
||||
has no seam fills, so that paths and seam fills together stay within the limit. Both Expand commands keep the group, and `byColor` leaves it under every color's group. The strokes
|
||||
are separate objects: after Expand, recoloring, moving or deleting a traced path leaves them as they are, and deleting
|
||||
the group removes them. The reply's
|
||||
`paths` and `anchors` count the traced paths only.
|
||||
With `keepColors` in `params`, the reply's `warnings` name each listed color that no traced color matches, and say
|
||||
when nothing was traced.
|
||||
`imageTrace.presets.save {name?, newName?, preset?, enhanced?, params?}` saves tracing settings as a preset kept with
|
||||
|
||||
@@ -1476,6 +1476,7 @@ Moved from the ROADMAP's "Shipped so far" on 2026-10-10. Update it when a featur
|
||||
- **Image Trace, Document Library color groups:** with Document Swatches, the panel's Colors menu and `"colorGroup"` trace with one color group's colors instead of every swatch, as the public panel documentation describes Document Library; code-drawn tests in `crates/engine` and the panel.
|
||||
- **Image Trace, Document Library colors:** with Document Swatches, traced fills and strokes use the displayed colors of process, global, spot and tint swatches without links, so editing a swatch leaves the trace unchanged; swatch-library colors are also unlinked; code-drawn tests in `crates/engine`.
|
||||
- **Image Trace, flattened slivers:** in a Color, Grayscale or Black and White trace with Fills, a traced region whose outline straightens onto one line (a single pixel, or a one-pixel row along an edge, its pieces shared with the regions beside it) is left out instead of becoming a selectable path with no area, which paints nothing. Snap Curves To Lines straightens more outlines, so it leaves out more of these. Without Fills, the region's 1 px stroke draws it, and it is kept. Code-drawn tests in `crates/trace`.
|
||||
- **Image Trace, Abutting seam fills:** an Abutting trace with Fills holds a `Seam Fills` group under its paths, with 1.5 px strokes along the edges two filled paths share, in the lower path's color (VectorCraft's own width), so renderers that anti-alias each path on its own show no light hairline along those edges. The paths and their shared edges are unchanged. Tests: `seam::tests` in `crates/trace`, `image_trace_abutting_seam_fills_sit_under_the_paths` in `crates/engine`. Scores and hours unchanged.
|
||||
- **Image Trace, Auto Color rare colours:** the Automatic palette keeps colours too rare for its area count when they are distinct (Oklab) and drawn as coherent regions, at most six, protected from mixed-colour merging and Noise; code-drawn stem, highlight, low-contrast and scattered-noise tests (see [quality notes](image-trace-quality.md#auto-color-keeps-rare-colours)).
|
||||
- **Image Trace, nearly flat dark grounds:** with a Limited palette of 9 to 16 colors (16 Colors, and Document Library without swatches), by VectorCraft's own rule, a cut whose two sides both have a dark gray mean (Oklab lightness under 0.30, chroma under 0.03) and lie less than 0.03 apart in Oklab has its gain scaled by (distance / 0.03)². A near-black ground with faint noise then traces in one color, and the color it would have taken goes to another cut. Code-drawn tests `a_nearly_flat_dark_ground_keeps_one_color`, `only_a_limited_palette_of_nine_to_sixteen_colors_weighs_alike_sides` and `a_dark_colored_figure_on_a_nearly_flat_dark_ground_keeps_its_color` in `crates/trace`.
|
||||
- **Image Trace, Document Library keeps neutral tones neutral:** each pixel takes the library color nearest in Oklab with differences in hue and chroma counted three times, so a gray or a muted brown traces as a neutral library color instead of a saturated one of similar lightness; a code-drawn test of gray and brown patches with a black, light and blue library in `crates/trace`.
|
||||
|
||||
Reference in New Issue
Block a user