mirror of
https://github.com/bevyengine/bevy
synced 2024-11-13 00:17:27 +00:00
f939c09f2c
# Objective - Improve compatibility with CSS Module 4 - Simplify `Hsla` conversion functions ## Solution - Added `Hsva` which implements the HSV color model. - Added `Hwba` which implements the HWB color model. - Updated `Color` and `LegacyColor` accordingly. ## Migration Guide - Convert `Hsva` / `Hwba` to either `Hsla` or `Srgba` using the provided `From` implementations and then handle accordingly. ## Notes While the HSL color space is older than HWB, the formulation for HWB is more directly related to RGB. Likewise, HSV is more closely related to HWB than HSL. This makes the conversion of HSL to/from RGB more naturally represented as the compound operation HSL <-> HSV <-> HWB <-> RGB. All `From` implementations for HSL, HSV, and HWB have been designed to take the shortest path between itself and the target space. --------- Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com> |
||
---|---|---|
.. | ||
crates/gen_tests | ||
src | ||
Cargo.toml |