They copy no rotation, so the crop's turn isn't left out of their result; only Match Rotation
and Match All report the crop-adjusted value they copy.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
egui's `matches_logically(Modifiers::NONE)` ignores Alt as well as Shift, so Alt+H, Alt+P and
Alt+I toggled Show Cropped Area, Classic Mode and Front Image; they are now left for later
handlers.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A bicubic shrink of both axes stores the image between its two passes
with one axis still at its old size, larger than the result. The hidden
pixel budget now checks the largest rectangle of each surface's pass plan
(algo::resample::largest_resize_rect), masks, channels and the selection
with their Bilinear filter.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The canvas ends the gesture before `ensure_frame` (which dropped the untouched default frame
under the box being drawn, and the Hand never reached `tool_event`), keeping the pen eraser
exception. A press inside the default frame that never moves is no edit, so leaving still drops
a selection-derived default frame.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* perf(algo): row-parallel local_sharpen with fast-path protect_detail (#5426)
Refs #5426. Follow-up to #5499.
Cause:
While #5499 parallelized local_blur and the per-dab mix in DabTool::Focus,
local_sharpen in crates/algo/src/retouch.rs remained single-threaded.
In addition, protect_detail redundantly evaluated coordinate clamping
and strided memory lookups across 8 neighbors inside the per-channel
inner loop for every pixel in the dab. On large brush sizes (e.g. 1000–2500 px),
strokes took seconds and stalled the application.
Change:
- Process local_sharpen window rows in parallel with Rayon across threads,
with wasm32 serial fallback matching local_blur.
- Hoist protect_detail 3x3 neighborhood offset calculations outside the
channel loop.
- Fast-path interior pixels (x > 0 && x + 1 < w && y > 0 && y + 1 < h)
with direct stride offsets, skipping boundary clamping entirely for >99.9%
of pixels in large brush dabs.
- Add retouch_sharpen_exact integration test verifying bit-for-bit parity
against the frozen scalar implementation across layouts, edges, and channels.
* bench(engine): add bench_sharpen_tool example
resvg renders a pattern's root under Transform::from_scale(get_scale()) of
the path transform times patternTransform, so a skewed patternTransform
with slim full-affine bounds drew a much larger filter region than the
estimate charged (1.06e9 vs about 1.9e11 reads).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main's #7530 draws marching ants as a pixel mesh plus white base segments for slanted edges, so the
rotated Move-tool marquee is no longer one white closed path.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An earlier merge (f35107a8ea, snap_ui.rs moved into canvas/) applied the
guard's hunk to the Move branch, whose context lines match the Up branch's.
A click has no Move, so its release still snapped the frame and the test
a_click_on_the_frame_or_a_handle_never_snaps_it failed. The guard is back
on Up, where a release at the press point leaves the frame alone.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main moved crates/ui-egui/src/panels.rs into panels/*.rs, so the color_field entry now names
panels/color.rs (scorecard note too), and main's cognitive_complexity deny split lex()'s block
comment and string skipping into helpers.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Conflicts: svg.rs (main's bufread inflate and shared render helper, kept
with the PR's bounded raster path), psd_import.rs (the PR's vector
preview moved into main's smart_content), menus/invoke.rs (the SVG
intercept moved into main's split invoke_unguarded), rendering.rs and
the ui-egui import lists (main's explicit imports), Cargo.lock, docs
status lines (unions).
* perf(algo): reuse Reduce Noise guide statistics
* fix(algo): use fixed-size chunks for guide statistics
* Reduce Noise: test that the caller routes the cleaned luma guide and both chroma planes
Review follow-up: compares reduce_noise's output (Lab, so planes pass through) with the
independent guided filters run in order.
* test(algo): assert bit-identical output in Reduce Noise routing test
Their params doc mentions path.toSelection, so the automation filesystem-path
classifier test flagged them; they take a document path name.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`is_empty_pixel_layer` took any layer without stored tiles for empty, so a
layer opaque only through its default pixel (as KRA imports it,
`Surface::with_default`) or a blank video layer became the Pattern Fill
(and the Stamp Visible target) instead of getting one above. It now
needs a transparent default pixel (alpha only: a mode or profile
conversion gives an empty layer's default pixel other colour bytes) and
no video.
Co-authored-by: Hodd <32705043+hodd1444@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The new keys went straight to the engine with the Paths-panel path name
injected in PhotocraftApp::run, skipping the route Ctrl+Enter takes
(vector_ui::path_to_selection). So a Pen path still being drawn was not
finished and used: Pen, three clicks, Ctrl+Shift+Enter combined the old
work path (or failed with "no work path") and left the Pen path open,
and the loaded path stayed selected. Both ids now go through the same
route with the mode forced to add/subtract, and the injection is gone.
Also removes crates/ui-egui/src/vector_cmds.rs, an uncompiled byte-for-
byte copy of the old engine file, and makes the add test check that both
areas end up selected.
Co-authored-by: mahefanante <42338306+mahefanante@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>