Replace pywal with a new ImageMagick color extraction, and custom algorithm.#20
Conversation
There was a problem hiding this comment.
Pull Request Overview
This pull request removes the dependency on pywal for color extraction and replaces it with a custom ImageMagick-based color extraction system. The new algorithm provides intelligent image classification, adaptive palette generation, and improved caching.
- Introduces a comprehensive ImageMagick-based color extraction utility with automatic image type detection and adaptive palette strategies
- Updates the UI workflow to use the new extraction method with improved button labeling and tooltips
- Removes all pywal dependencies and references throughout the codebase and documentation
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/utils/imagemagick-color-extraction.js | New comprehensive color extraction utility with intelligent algorithms and caching |
| src/utils/image-filter-utils.js | Updated comments to reflect new color extraction system |
| src/services/wallpaper-service.js | Removed entire pywal integration service |
| src/main.js | Added blueprint service initialization check |
| src/components/PaletteGenerator.js | Updated to use new ImageMagick extraction method |
| README.md | Updated installation instructions and workflow descriptions |
| CLAUDE.md | Updated project documentation to reflect new extraction system |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| const hsl = getColorHSL(hexColor); | ||
| const newLightness = Math.min(100, hsl.l + BRIGHT_COLOR_LIGHTNESS_BOOST); | ||
| const newSaturation = Math.min(100, hsl.s * BRIGHT_COLOR_SATURATION_BOOST); | ||
| return hslToHex(hsl.h, newSaturation, newLightness); |
There was a problem hiding this comment.
Repeated calls to getColorHSL() in the same function could be optimized by caching the HSL conversion result, especially in functions like generateBrightVersion() where the same color is processed multiple times.
| } | ||
|
|
||
| this._extractButton.set_visible(true); | ||
| // this._extractButton.set_visible(true); // Pywal button commented out |
There was a problem hiding this comment.
Remove commented-out pywal code rather than leaving it in the codebase. The old implementation is preserved in version control history if needed.
You might ask the question why, and it is easy to answer.
The reason for throwing away pywal, regardless of how great it works, is to get full control. It can be tweaked as I want to, and it is quicker, more stable, and handles edge cases where pywal will just throw.
Always challenge the status quo.
Copilot
This pull request removes all dependencies on
pywalfor color extraction and fully migrates the application to an advanced ImageMagick-based color extraction system. The documentation, UI, and service layer have been updated to reflect this major architectural change. Additionally, the user workflow and palette generation have been improved with smarter, adaptive algorithms and new wallpaper browsing features.Color Extraction System Overhaul
pywalwith an intelligent ImageMagick-based color extraction algorithm, including automatic image classification, adaptive palette generation, brightness normalization, and caching for fast re-extraction. (CLAUDE.md[1] [2] [3] [4] [5] [6] [7] src/components/PaletteGenerator.js [8] [9] [10] [11] [12] src/services/wallpaper-service.js [13] src/utils/image-filter-utils.js [14] [15] CLAUDE.md [16] [17] [18] [19] [20]UI and Workflow Improvements
CLAUDE.md[1] src/components/PaletteGenerator.js [2] [3] [4] [5]Documentation and Dependency Updates
pywaland require only ImageMagick for both color extraction and wallpaper filtering. (README.md[1] [2] [3] [4] [5] CLAUDE.md [6] [7] [8]Codebase Cleanup
src/services/wallpaper-service.js(pywal integration) and all related logic. (src/services/wallpaper-service.jssrc/services/wallpaper-service.jsL1-L107)Resilience and Caching
src/utils/image-filter-utils.js[1] [2] CLAUDE.md [3] [4]These changes modernize the application's color extraction capabilities, simplify dependencies, and provide a smarter, more flexible theming experience for users.