2019-11-16 02:17:07 +00:00
|
|
|
[package]
|
|
|
|
name = "wgpu-core"
|
2024-04-28 22:06:35 +00:00
|
|
|
version = "0.20.0"
|
2023-10-27 04:15:51 +00:00
|
|
|
authors = ["gfx-rs developers"]
|
2022-12-15 20:46:28 +00:00
|
|
|
edition = "2021"
|
2021-10-01 17:50:19 +00:00
|
|
|
description = "WebGPU core logic on wgpu-hal"
|
2022-12-15 20:46:28 +00:00
|
|
|
homepage = "https://wgpu.rs/"
|
|
|
|
repository = "https://github.com/gfx-rs/wgpu"
|
|
|
|
keywords = ["graphics"]
|
|
|
|
license = "MIT OR Apache-2.0"
|
2019-11-16 02:17:07 +00:00
|
|
|
|
2023-10-04 01:03:32 +00:00
|
|
|
# Override the workspace's `rust-version` key. Firefox uses `cargo vendor` to
|
|
|
|
# copy the crates it actually uses out of the workspace, so it's meaningful for
|
|
|
|
# them to have less restrictive MSRVs individually than the workspace as a
|
|
|
|
# whole, if their code permits. See `../README.md` for details.
|
2024-03-14 17:00:43 +00:00
|
|
|
rust-version = "1.74"
|
2023-10-04 01:03:32 +00:00
|
|
|
|
2022-10-26 21:07:25 +00:00
|
|
|
[package.metadata.docs.rs]
|
|
|
|
all-features = true
|
|
|
|
rustdoc-args = ["--cfg", "docsrs"]
|
2023-02-09 20:38:40 +00:00
|
|
|
targets = [
|
|
|
|
"x86_64-unknown-linux-gnu",
|
|
|
|
"x86_64-apple-darwin",
|
|
|
|
"x86_64-pc-windows-msvc",
|
|
|
|
"wasm32-unknown-unknown",
|
|
|
|
]
|
2022-10-26 21:07:25 +00:00
|
|
|
|
2024-05-12 23:05:00 +00:00
|
|
|
[package.metadata.cargo-machete]
|
|
|
|
# Cargo machete can't check build.rs dependencies. See https://github.com/bnjbvr/cargo-machete/issues/100
|
|
|
|
ignored = ["cfg_aliases"]
|
|
|
|
|
2019-11-16 02:17:07 +00:00
|
|
|
[lib]
|
|
|
|
|
|
|
|
[features]
|
2024-06-24 09:20:10 +00:00
|
|
|
## Internally count resources and events for debugging purposes. If the counters
|
|
|
|
## feature is disabled, the counting infrastructure is removed from the build and
|
|
|
|
## the exposed counters always return 0.
|
|
|
|
counters = ["wgt/counters"]
|
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Log all API entry points at info instead of trace level.
|
2023-11-24 18:14:38 +00:00
|
|
|
api_log_info = []
|
2022-12-08 01:58:45 +00:00
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Log resource lifecycle management at info instead of trace level.
|
|
|
|
resource_log_info = []
|
2022-12-08 01:58:45 +00:00
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Support the Renderdoc graphics debugger:
|
|
|
|
## <https://renderdoc.org/>
|
2022-12-08 01:58:45 +00:00
|
|
|
renderdoc = ["hal/renderdoc"]
|
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Apply run-time checks, even in release builds. These are in addition
|
|
|
|
## to the validation carried out at public APIs in all builds.
|
2022-12-20 00:17:19 +00:00
|
|
|
strict_asserts = ["wgt/strict_asserts"]
|
2023-12-17 22:10:38 +00:00
|
|
|
|
2024-01-28 20:13:04 +00:00
|
|
|
## Enables serialization via `serde` on common wgpu types.
|
|
|
|
serde = ["dep:serde", "wgt/serde", "arrayvec/serde"]
|
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Enable API tracing.
|
2024-05-12 06:45:35 +00:00
|
|
|
trace = ["dep:ron", "serde", "naga/serialize"]
|
2023-12-17 22:10:38 +00:00
|
|
|
|
|
|
|
## Enable API replaying
|
2024-01-28 20:13:04 +00:00
|
|
|
replay = ["serde", "naga/deserialize"]
|
2023-12-17 22:10:38 +00:00
|
|
|
|
|
|
|
## Enable `ShaderModuleSource::Wgsl`
|
2022-10-08 05:12:50 +00:00
|
|
|
wgsl = ["naga/wgsl-in"]
|
2023-12-17 22:10:38 +00:00
|
|
|
|
2024-01-23 15:25:25 +00:00
|
|
|
## Enable `ShaderModuleSource::Glsl`
|
|
|
|
glsl = ["naga/glsl-in"]
|
|
|
|
|
|
|
|
## Enable `ShaderModuleSource::SpirV`
|
|
|
|
spirv = ["naga/spv-in", "dep:bytemuck"]
|
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
## Implement `Send` and `Sync` on Wasm, but only if atomics are not enabled.
|
|
|
|
##
|
|
|
|
## WebGL/WebGPU objects can not be shared between threads.
|
|
|
|
## However, it can be useful to artificially mark them as `Send` and `Sync`
|
|
|
|
## anyways to make it easier to write cross-platform code.
|
|
|
|
## This is technically *very* unsafe in a multithreaded environment,
|
|
|
|
## but on a wasm binary compiled without atomics we know we are definitely
|
|
|
|
## not in a multithreaded environment.
|
2023-10-25 17:53:22 +00:00
|
|
|
fragile-send-sync-non-atomic-wasm = [
|
|
|
|
"hal/fragile-send-sync-non-atomic-wasm",
|
|
|
|
"wgt/fragile-send-sync-non-atomic-wasm",
|
|
|
|
]
|
2019-11-16 02:17:07 +00:00
|
|
|
|
2023-12-17 22:10:38 +00:00
|
|
|
#! ### Backends, passed through to wgpu-hal
|
|
|
|
# --------------------------------------------------------------------
|
|
|
|
|
|
|
|
## Enable the `metal` backend.
|
|
|
|
metal = ["hal/metal"]
|
|
|
|
|
|
|
|
## Enable the `vulkan` backend.
|
|
|
|
vulkan = ["hal/vulkan"]
|
|
|
|
|
|
|
|
## Enable the `GLES` backend.
|
|
|
|
##
|
|
|
|
## This is used for all of GLES, OpenGL, and WebGL.
|
|
|
|
gles = ["hal/gles"]
|
|
|
|
|
|
|
|
## Enable the `dx12` backend.
|
|
|
|
dx12 = ["hal/dx12"]
|
|
|
|
|
2019-11-16 02:17:07 +00:00
|
|
|
[dependencies]
|
2022-12-15 20:46:28 +00:00
|
|
|
arrayvec = "0.7"
|
|
|
|
bit-vec = "0.6"
|
2023-12-17 22:10:38 +00:00
|
|
|
bitflags = "2"
|
2024-05-26 16:34:50 +00:00
|
|
|
bytemuck = { version = "1.16", optional = true }
|
2024-02-09 10:44:29 +00:00
|
|
|
document-features.workspace = true
|
2024-01-02 14:27:22 +00:00
|
|
|
indexmap = "2"
|
2022-12-15 20:46:28 +00:00
|
|
|
log = "0.4"
|
2024-01-02 14:27:22 +00:00
|
|
|
once_cell = "1"
|
2022-12-15 20:46:28 +00:00
|
|
|
# parking_lot 0.12 switches from `winapi` to `windows`; permit either
|
2024-06-03 07:20:29 +00:00
|
|
|
parking_lot = ">=0.11, <0.13"
|
2022-12-15 20:46:28 +00:00
|
|
|
profiling = { version = "1", default-features = false }
|
2023-10-27 05:24:46 +00:00
|
|
|
raw-window-handle = { version = "0.6", optional = true }
|
2022-12-15 20:46:28 +00:00
|
|
|
ron = { version = "0.8", optional = true }
|
2023-12-17 22:10:38 +00:00
|
|
|
rustc-hash = "1.1"
|
2022-12-15 20:46:28 +00:00
|
|
|
serde = { version = "1", features = ["serde_derive"], optional = true }
|
|
|
|
smallvec = "1"
|
|
|
|
thiserror = "1"
|
2020-12-21 19:24:52 +00:00
|
|
|
|
2020-05-09 16:55:10 +00:00
|
|
|
[dependencies.naga]
|
2023-10-25 20:51:36 +00:00
|
|
|
path = "../naga"
|
2024-04-28 22:06:35 +00:00
|
|
|
version = "0.20.0"
|
2020-05-09 16:55:10 +00:00
|
|
|
|
2020-03-11 01:06:23 +00:00
|
|
|
[dependencies.wgt]
|
2022-12-15 20:46:28 +00:00
|
|
|
package = "wgpu-types"
|
|
|
|
path = "../wgpu-types"
|
2024-04-28 22:06:35 +00:00
|
|
|
version = "0.20.0"
|
2020-03-11 01:06:23 +00:00
|
|
|
|
2021-06-04 05:19:36 +00:00
|
|
|
[dependencies.hal]
|
2022-12-15 20:46:28 +00:00
|
|
|
package = "wgpu-hal"
|
|
|
|
path = "../wgpu-hal"
|
2024-04-28 22:06:35 +00:00
|
|
|
version = "0.20.0"
|
2024-05-26 04:33:02 +00:00
|
|
|
default-features = false
|
2021-06-04 05:19:36 +00:00
|
|
|
|
2024-01-14 05:59:59 +00:00
|
|
|
[build-dependencies]
|
|
|
|
cfg_aliases.workspace = true
|