//! Colour, and the one place it changes space.
//!
//! Colours are *authored* in sRGB -- `Color::srgb(0.95, 0.55, 0.20)` is what a
//! colour picker hands you -- and *rendered* in linear, because light adds up
//! linearly and shading maths on sRGB numbers is shading maths on the wrong
//! numbers. Everything the GPU sees goes through [`linear_rgba`] or
//! [`wgpu_color`], so the boundary between the two spaces is this file.
//!
//! The frame is encoded back to sRGB once, on the way out: today by the sRGB
//! surface format, later by the tonemapping pass that will sit in front of it.
/// `Alpha` and `Mix` come along because a colour is not much use without
/// them: `with_alpha` to thin one, `mix` to blend two -- and blending is a
/// thing to do in linear, so call it on `to_linear()` rather than on the
/// authored sRGB.
pub use ;
use ColorToComponents;
/// A colour as the shaders want it: linear, premultiplied by nothing, RGBA.
/// The same conversion for a clear value. `bevy_color` ships `From` impls for
/// `wgpu_types::Color`, but only from the concrete spaces and only against its
/// own `wgpu-types` major, which is a version behind ours.