A Rust library for creating and manipulating color gradients for data visualization, generative art, and UI design.
colorgrad-rs is a Rust library for generating and manipulating color gradients. It provides a flexible API for creating custom gradients with support for various color formats, interpolation modes, and blending options, and includes preset gradients for common use cases. The library is designed for applications in data visualization, charts, games, maps, and generative art.
Rust developers working on visual applications such as data visualization tools, game engines, map rendering systems, and generative art projects who need precise control over color gradients.
Developers choose colorgrad-rs for its comprehensive feature set, including support for multiple color formats (CSS, hex, RGB, HSL), advanced interpolation modes (linear, smoothstep, Catmull-Rom, basis), and unique capabilities like GIMP gradient parsing and hard-edged gradient creation, all with a simple and intuitive API.
Rust color scales library
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
The GradientBuilder pattern enables intuitive creation of custom gradients with methods for colors, domains, and modes, detailed in numerous code examples like .html_colors() and .domain().
Supports multiple web color formats including named colors, hex, RGB, HSL, and CSS gradient strings, allowing seamless integration with existing design assets, as shown in the README examples.
Offers linear, smoothstep, Catmull-Rom, and basis interpolation for smooth color transitions, with visual examples provided for each mode to guide customization.
Can parse GIMP .ggr files, enabling reuse of existing gradient assets, and includes hard-edged gradient conversion for segmented visual effects, demonstrated in the documentation.
Relies on Rust's std by default; disabling it with 'default-features = false' may limit functionality and complicate no-std usage, which isn't fully addressed in core features.
As a Rust crate, it cannot be used in projects written in other languages, restricting its applicability to Rust-based development only.
Lacks integrated color blindness simulation or accessibility tools, requiring developers to rely on external resources, which adds overhead for inclusive design.