bevy/crates/bevy_core_pipeline/src
Alice Cecile 8ec65525ab
Port bevy_core_pipeline to LinearRgba (#12116)
# Objective

- We should move towards a consistent use of the new `bevy_color` crate.
- As discussed in #12089, splitting this work up into small pieces makes
it easier to review.

## Solution

- Port all uses of `LegacyColor` in the `bevy_core_pipeline` to
`LinearRgba`
- `LinearRgba` is the correct type to use for internal rendering types
- Added `LinearRgba::BLACK` and `WHITE` (used during migration)
- Add `LinearRgba::grey` to more easily construct balanced grey colors
(used during migration)
- Add a conversion from `LinearRgba` to `wgpu::Color`. The converse was
not done at this time, as this is typically a user error.

I did not change the field type of the clear color on the cameras: as
this is user-facing, this should be done in concert with the other
configurable fields.

## Migration Guide

`ColorAttachment` now stores a `LinearRgba` color, rather than a Bevy
0.13 `Color`.
`set_blend_constant` now takes a `LinearRgba` argument, rather than a
Bevy 0.13 `Color`.

---------

Co-authored-by: Alice Cecile <alice.i.cecil@gmail.com>
2024-02-26 12:25:11 +00:00
..
blit resolve all internal ambiguities (#10411) 2024-01-09 19:08:15 +00:00
bloom Port bevy_core_pipeline to LinearRgba (#12116) 2024-02-26 12:25:11 +00:00
contrast_adaptive_sharpening Check cfg during CI and fix feature typos (#12103) 2024-02-25 15:19:27 +00:00
core_2d fix some typos (#12038) 2024-02-22 18:55:22 +00:00
core_3d Port bevy_core_pipeline to LinearRgba (#12116) 2024-02-26 12:25:11 +00:00
deferred sort alpha masked pipelines by pipeline & mesh instead of by distance (#12117) 2024-02-26 11:14:59 +00:00
fullscreen_vertex_shader Bevy Asset V2 (#8624) 2023-09-07 02:07:27 +00:00
fxaa Rename Core Render Graph Labels (#11882) 2024-02-15 23:15:16 +00:00
prepass sort alpha masked pipelines by pipeline & mesh instead of by distance (#12117) 2024-02-26 11:14:59 +00:00
skybox Pad SkyUniforms to 16 bytes for WASM (#12078) 2024-02-24 07:46:00 +00:00
taa Rename Core Render Graph Labels (#11882) 2024-02-15 23:15:16 +00:00
tonemapping mipmap levels can be 0 and they should be interpreted as 1 (#11767) 2024-02-11 22:00:07 +00:00
upscaling Async pipeline compilation (#10812) 2024-02-05 13:50:50 +00:00
lib.rs Inverse missing_docs logic (#11676) 2024-02-03 21:40:55 +00:00
msaa_writeback.rs Port bevy_core_pipeline to LinearRgba (#12116) 2024-02-26 12:25:11 +00:00