mirror of
https://github.com/bevyengine/bevy
synced 2024-11-10 07:04:33 +00:00
5e63f6815b
# Objective - Fixes #12068 ## Solution - Split `bevy_render::color::colorspace` across the various space implementations in `bevy_color` as appropriate. - Moved `From` implementations involving `bevy_render::color::LegacyColor` into `bevy_render::color` ## Migration Guide ### `bevy_render::color::colorspace::SrgbColorSpace::<f32>::linear_to_nonlinear_srgb` Use `bevy_color::color::gamma_function_inverse` ### `bevy_render::color::colorspace::SrgbColorSpace::<f32>::nonlinear_to_linear_srgb` Use `bevy_color::color::gamma_function` ### `bevy_render::color::colorspace::SrgbColorSpace::<u8>::linear_to_nonlinear_srgb` Modify the `u8` value to instead be an `f32` (`|x| x as f32 / 255.`), use `bevy_color::color::gamma_function_inverse`, and back again. ### `bevy_render::color::colorspace::SrgbColorSpace::<u8>::nonlinear_to_linear_srgb` Modify the `u8` value to instead be an `f32` (`|x| x as f32 / 255.`), use `bevy_color::color::gamma_function`, and back again. ### `bevy_render::color::colorspace::HslRepresentation::hsl_to_nonlinear_srgb` Use `Hsla`'s implementation of `Into<Srgba>` ### `bevy_render::color::colorspace::HslRepresentation::nonlinear_srgb_to_hsl` Use `Srgba`'s implementation of `Into<Hsla>` ### `bevy_render::color::colorspace::LchRepresentation::lch_to_nonlinear_srgb` Use `Lcha`'s implementation of `Into<Srgba>` ### `bevy_render::color::colorspace::LchRepresentation::nonlinear_srgb_to_lch` Use `Srgba`'s implementation of `Into<Lcha>`
124 lines
4 KiB
TOML
124 lines
4 KiB
TOML
[package]
|
|
name = "bevy_render"
|
|
version = "0.14.0-dev"
|
|
edition = "2021"
|
|
description = "Provides rendering functionality for Bevy Engine"
|
|
homepage = "https://bevyengine.org"
|
|
repository = "https://github.com/bevyengine/bevy"
|
|
license = "MIT OR Apache-2.0"
|
|
keywords = ["bevy"]
|
|
|
|
[features]
|
|
png = ["image/png"]
|
|
exr = ["image/exr"]
|
|
hdr = ["image/hdr"]
|
|
tga = ["image/tga"]
|
|
jpeg = ["image/jpeg"]
|
|
bmp = ["image/bmp"]
|
|
webp = ["image/webp"]
|
|
dds = ["ddsfile"]
|
|
pnm = ["image/pnm"]
|
|
multi-threaded = ["bevy_tasks/multi-threaded"]
|
|
bevy_ci_testing = ["bevy_app/bevy_ci_testing"]
|
|
|
|
shader_format_glsl = ["naga/glsl-in", "naga/wgsl-out", "naga_oil/glsl"]
|
|
shader_format_spirv = ["wgpu/spirv", "naga/spv-in", "naga/spv-out"]
|
|
|
|
# For ktx2 supercompression
|
|
zlib = ["flate2"]
|
|
zstd = ["ruzstd"]
|
|
|
|
trace = ["profiling"]
|
|
tracing-tracy = []
|
|
wgpu_trace = ["wgpu/trace"]
|
|
ci_limits = []
|
|
webgl = ["wgpu/webgl"]
|
|
webgpu = ["wgpu/webgpu"]
|
|
ios_simulator = []
|
|
|
|
[dependencies]
|
|
# bevy
|
|
bevy_app = { path = "../bevy_app", version = "0.14.0-dev" }
|
|
bevy_asset = { path = "../bevy_asset", version = "0.14.0-dev" }
|
|
bevy_color = { path = "../bevy_color", version = "0.14.0-dev" }
|
|
bevy_core = { path = "../bevy_core", version = "0.14.0-dev" }
|
|
bevy_derive = { path = "../bevy_derive", version = "0.14.0-dev" }
|
|
bevy_ecs = { path = "../bevy_ecs", version = "0.14.0-dev" }
|
|
bevy_encase_derive = { path = "../bevy_encase_derive", version = "0.14.0-dev" }
|
|
bevy_hierarchy = { path = "../bevy_hierarchy", version = "0.14.0-dev" }
|
|
bevy_log = { path = "../bevy_log", version = "0.14.0-dev" }
|
|
bevy_math = { path = "../bevy_math", version = "0.14.0-dev" }
|
|
bevy_mikktspace = { path = "../bevy_mikktspace", version = "0.14.0-dev" }
|
|
bevy_reflect = { path = "../bevy_reflect", version = "0.14.0-dev", features = [
|
|
"bevy",
|
|
] }
|
|
bevy_render_macros = { path = "macros", version = "0.14.0-dev" }
|
|
bevy_time = { path = "../bevy_time", version = "0.14.0-dev" }
|
|
bevy_transform = { path = "../bevy_transform", version = "0.14.0-dev" }
|
|
bevy_window = { path = "../bevy_window", version = "0.14.0-dev" }
|
|
bevy_utils = { path = "../bevy_utils", version = "0.14.0-dev" }
|
|
bevy_tasks = { path = "../bevy_tasks", version = "0.14.0-dev" }
|
|
|
|
# rendering
|
|
image = { version = "0.24", default-features = false }
|
|
|
|
# misc
|
|
codespan-reporting = "0.11.0"
|
|
# `fragile-send-sync-non-atomic-wasm` feature means we can't use WASM threads for rendering
|
|
# It is enabled for now to avoid having to do a significant overhaul of the renderer just for wasm
|
|
wgpu = { version = "0.19.1", default-features = false, features = [
|
|
"wgsl",
|
|
"dx12",
|
|
"metal",
|
|
"naga",
|
|
"naga-ir",
|
|
"fragile-send-sync-non-atomic-wasm",
|
|
] }
|
|
naga = { version = "0.19", features = ["wgsl-in"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
bitflags = { version = "2.3", features = ["serde"] }
|
|
bytemuck = { version = "1.5", features = ["derive"] }
|
|
downcast-rs = "1.2.0"
|
|
thread_local = "1.1"
|
|
thiserror = "1.0"
|
|
futures-lite = "2.0.1"
|
|
hexasphere = "10.0"
|
|
ddsfile = { version = "0.5.0", optional = true }
|
|
ktx2 = { version = "0.3.0", optional = true }
|
|
# For ktx2 supercompression
|
|
flate2 = { version = "1.0.22", optional = true }
|
|
ruzstd = { version = "0.5.0", optional = true }
|
|
# For transcoding of UASTC/ETC1S universal formats, and for .basis file support
|
|
basis-universal = { version = "0.3.0", optional = true }
|
|
encase = { version = "0.7", features = ["glam"] }
|
|
# For wgpu profiling using tracing. Use `RUST_LOG=info` to also capture the wgpu spans.
|
|
profiling = { version = "1", features = [
|
|
"profile-with-tracing",
|
|
], optional = true }
|
|
async-channel = "2.2.0"
|
|
|
|
|
|
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
|
|
# Omit the `glsl` feature in non-WebAssembly by default.
|
|
naga_oil = { version = "0.13", default-features = false, features = [
|
|
"test_shader",
|
|
] }
|
|
|
|
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
|
naga_oil = "0.13"
|
|
js-sys = "0.3"
|
|
# web-sys doesn't follow semver for the WebGPU APIs as they are unstable
|
|
# Make sure that WebGPU builds work when changing this!
|
|
web-sys = { version = "=0.3.67", features = [
|
|
'Blob',
|
|
'Document',
|
|
'Element',
|
|
'HtmlElement',
|
|
'Node',
|
|
'Url',
|
|
'Window',
|
|
] }
|
|
wasm-bindgen = "0.2"
|
|
|
|
[lints]
|
|
workspace = true
|