Skip to content

Commit c3e8721

Browse files
IIIvan37Ivan Duchauffour
andauthored
Dev (#296)
* feat(info-bar): display Mode R status and unique pairs count * fix(raster): auto-switch to compatible dithering mode when enabling raster * feat: allow drag-drop to replace existing source image - Add dropzone wrapper around ImageSelector in source-section.tsx - Reset adjustments and selection when replacing image via drop - Add data-testid to ImageUpload for testing - Add tests for drop functionality (image processing and non-image rejection) * fix(source-selector): allow selection drag outside container bounds - Replace react-dropzone with native drop events in source-section to avoid conflicts with ImageSelector's internal drag operations - Use window mousemove/mouseup events during drag to track cursor position even when it moves outside the selector container - Add containerRef to SourceSelectorView for coordinate calculations - Fixes issue where selection rectangle couldn't be positioned at image edges * perf: optimize CPC Plus color analysis with O(1) lookup - Add getCPCPlusPaletteIndex() for direct palette index lookup - Reduces frequency analysis from 744ms to 0.4ms (~1800x faster) - Clean up verbose debug logs in color selection helpers - Add targeted timing logs for workingImageAtom and dithering - Refactor useImageAdjustement with refs to reduce rerenders * feat(dithering): add Ostromoukhov and Blue Noise algorithms - Add Ostromoukhov error diffusion with variable coefficients (256 levels) - Implement serpentine scan pattern for better artifact reduction - Add EGX support for Ostromoukhov dithering - Add Mode R support for Ostromoukhov and Blue Noise - Add 64x64 Blue Noise texture for threshold-based dithering - Fix missing Ostromoukhov coefficients (indices 126-127) - Add fallback protection for undefined coefficients * chore: fix linting warnings - Replace Object.assign with spread operator - Replace Array() with new Array() - Replace window with globalThis for SSR compatibility - Replace global with globalThis - Extract nested ternary operations into helper functions - Fix negated conditions (swap branches) - Remove unnecessary type assertions - Use CpcMode type alias instead of inline union - Fix inverted condition in optimize-line-palettes - Use 1 instead of 1.0 for integer values --------- Co-authored-by: Ivan Duchauffour <iduchauffour@welcomr.com>
1 parent 06d27ac commit c3e8721

File tree

0 file changed

+0
-0
lines changed

    0 file changed

    +0
    -0
    lines changed

    0 commit comments

    Comments
     (0)