From 51f021c70ae129aca0620c98c3a4e4b1fca325fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?charlotte=20=F0=9F=8C=B8?= Date: Mon, 16 Nov 2026 13:11:55 -0800 Subject: [PATCH] Upgrade to Bevy main. --- Cargo.lock | 2044 +++++++---------- Cargo.toml | 15 +- assets/shaders/custom_vertex.wesl | 4 +- crates/processing_midi/Cargo.toml | 2 +- .../examples/Demos/Tests/first_frame.py | 14 +- crates/processing_pyo3/src/color.rs | 6 + crates/processing_render/Cargo.toml | 4 +- crates/processing_render/build.rs | 164 +- .../processing_render/shaders/processing.wesl | 11 +- .../shaders/processing/mesh.wesl | 228 +- crates/processing_render/src/compute.rs | 29 +- crates/processing_render/src/graphics.rs | 7 +- crates/processing_render/src/image.rs | 2 + crates/processing_render/src/lib.rs | 14 +- .../processing_render/src/material/custom.rs | 480 ++-- .../material/{fragment.wgsl => fragment.wesl} | 0 crates/processing_render/src/material/mod.rs | 9 +- .../src/material/vertex.wesl | 7 + .../src/material/vertex.wgsl | 176 -- .../src/particles/material.rs | 2 +- crates/processing_render/src/particles/mod.rs | 4 +- .../processing_render/src/particles/pack.rs | 74 +- .../processing_render/src/particles/pack.wesl | 82 + .../processing_render/src/particles/pack.wgsl | 113 - .../src/particles/particles.wesl | 65 + .../src/particles/particles.wgsl | 65 - .../src/particles/{point.wgsl => point.wesl} | 43 +- .../src/particles/point_render.rs | 5 +- crates/processing_render/src/render/line.rs | 2 +- .../src/render/{line.wgsl => line.wesl} | 19 +- crates/processing_render/src/render/mod.rs | 3 +- crates/processing_render/src/render/pool.rs | 4 +- .../src/render/primitive/shape3d.rs | 18 +- crates/processing_webcam/Cargo.toml | 2 +- 34 files changed, 1839 insertions(+), 1878 deletions(-) rename crates/processing_render/src/material/{fragment.wgsl => fragment.wesl} (100%) create mode 100644 crates/processing_render/src/material/vertex.wesl delete mode 100644 crates/processing_render/src/material/vertex.wgsl create mode 100644 crates/processing_render/src/particles/pack.wesl delete mode 100644 crates/processing_render/src/particles/pack.wgsl create mode 100644 crates/processing_render/src/particles/particles.wesl delete mode 100644 crates/processing_render/src/particles/particles.wgsl rename crates/processing_render/src/particles/{point.wgsl => point.wesl} (59%) rename crates/processing_render/src/render/{line.wgsl => line.wesl} (94%) diff --git a/Cargo.lock b/Cargo.lock index 53b5f09e..99d71672 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -20,42 +20,46 @@ checksum = "366ffbaa4442f4684d91e2cd7c5ea7c4ed8add41959a31447066e279e432b618" [[package]] name = "accesskit" -version = "0.24.1" +version = "0.25.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b7f7f85a7e5f68090000ed7622545829afd484d210358702ae4cb97dd0c320" +checksum = "4e883d1d28c5fd5568c79ed2d2bd48d9f2fd3945c8974ed0f53690ceddb051be" dependencies = [ "uuid", ] [[package]] name = "accesskit_consumer" -version = "0.35.0" +version = "0.39.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53cf47daed85312e763fbf85ceca136e0d7abc68e0a7e12abe11f48172bc3b10" +checksum = "f3da8f27636015191b2264ee1df681503170a632cafd832fdc1edfdd4e3a2fd3" dependencies = [ "accesskit", - "hashbrown 0.16.1", + "hashbrown 0.17.1", ] [[package]] -name = "accesskit_consumer" -version = "0.38.0" +name = "accesskit_ios" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d10a236f96f87d70732e44520046785431ef01d5bcd6b041317bfadd2f88245" +checksum = "a5280724673bbfa8b30a838c013500b719392989be3b97c5a9964062c252c232" dependencies = [ "accesskit", - "hashbrown 0.16.1", + "accesskit_consumer", + "hashbrown 0.17.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", + "objc2-ui-kit", ] [[package]] name = "accesskit_macos" -version = "0.26.3" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce02dc63b43f0c9296af9ac946312a2dc8814427d7a64d2d600971dac55b6076" +checksum = "123828ceeec755b05255e3976cb0852993202de98a0626c97dd8d34246991f84" dependencies = [ "accesskit", - "accesskit_consumer 0.38.0", - "hashbrown 0.16.1", + "accesskit_consumer", + "hashbrown 0.17.1", "objc2 0.5.2", "objc2-app-kit 0.2.2", "objc2-foundation 0.2.2", @@ -63,13 +67,13 @@ dependencies = [ [[package]] name = "accesskit_windows" -version = "0.32.1" +version = "0.35.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eff7009f1a532e917d66970a1e80c965140c6cfbbabbdde3d64e5431e6c78e21" +checksum = "498668b90da9995302a0055aaecad4756932333da2ddef6baee1c00844c430fc" dependencies = [ "accesskit", - "accesskit_consumer 0.35.0", - "hashbrown 0.16.1", + "accesskit_consumer", + "hashbrown 0.17.1", "static_assertions", "windows 0.62.2", "windows-core 0.62.2", @@ -77,11 +81,12 @@ dependencies = [ [[package]] name = "accesskit_winit" -version = "0.32.2" +version = "0.34.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fe9a94394896352cc4660ca2288bd4ef883d83238853c038b44070c8f134313" +checksum = "cd4ab4437b520ff03088fbe48676a11e7d44a929535e64b31432c1073e48dbcc" dependencies = [ "accesskit", + "accesskit_ios", "accesskit_macos", "accesskit_windows", "raw-window-handle", @@ -294,6 +299,24 @@ version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3d036a3c4ab069c7b410a2ce876bd74808d2d0888a82667669f8e783a898bf1" +[[package]] +name = "arboard" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aeb9553e62312c8756a5979254fc6d7da8bbeb5986a1e17037fab932f7037917" +dependencies = [ + "clipboard-win", + "log", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-foundation 0.3.2", + "parking_lot", + "percent-encoding", + "windows-sys 0.61.2", + "wl-clipboard-rs", + "x11rb", +] + [[package]] name = "arg_enum_proc_macro" version = "0.3.4" @@ -332,15 +355,6 @@ dependencies = [ "stable_deref_trait", ] -[[package]] -name = "ascii-canvas" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef1e3e699d84ab1b0911a1010c5c106aa34ae89aeac103be5ce0c3859db1e891" -dependencies = [ - "term", -] - [[package]] name = "ash" version = "0.38.0+1.3.281" @@ -467,43 +481,6 @@ dependencies = [ "portable-atomic-util", ] -[[package]] -name = "audio-core" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f93ebbf82d06013f4c41fe71303feb980cddd78496d904d06be627972de51a24" - -[[package]] -name = "audioadapter" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c75c3943c6c7279bb25a449a8d1727480730ab2efd7b6fd5d6ca51927096e6e4" -dependencies = [ - "audio-core", - "num-traits", -] - -[[package]] -name = "audioadapter-buffers" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ece3390b6eb40379094843a1da5aaccc34bc0d85a8cbf68d09fe092fee6de29e" -dependencies = [ - "audioadapter", - "audioadapter-sample", - "num-traits", -] - -[[package]] -name = "audioadapter-sample" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1592f90413568e259413c21a41a3d571feb1774255c209e7966d98f9db708c90" -dependencies = [ - "audio-core", - "num-traits", -] - [[package]] name = "autocfg" version = "1.5.1" @@ -555,22 +532,22 @@ dependencies = [ [[package]] name = "base64" -version = "0.22.1" +version = "0.23.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" +checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5" [[package]] name = "bevy" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_internal", ] [[package]] name = "bevy_a11y" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "accesskit", "bevy_app", @@ -581,21 +558,22 @@ dependencies = [ [[package]] name = "bevy_android" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "android-activity", ] [[package]] name = "bevy_animation" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_animation_macros", "bevy_app", "bevy_asset", "bevy_color", + "bevy_curve", "bevy_derive", "bevy_ecs", "bevy_math", @@ -605,11 +583,12 @@ dependencies = [ "bevy_time", "bevy_transform", "bevy_utils", + "bitvec", "blake3", "derive_more", "downcast-rs 2.0.2", "either", - "petgraph 0.8.3", + "petgraph", "ron", "serde", "smallvec", @@ -621,18 +600,23 @@ dependencies = [ [[package]] name = "bevy_animation_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "quote", - "syn 2.0.119", + "syn 3.0.3", ] +[[package]] +name = "bevy_annotations" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" + [[package]] name = "bevy_anti_alias" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -641,6 +625,7 @@ dependencies = [ "bevy_derive", "bevy_diagnostic", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_math", "bevy_reflect", @@ -652,8 +637,8 @@ dependencies = [ [[package]] name = "bevy_app" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_derive", "bevy_ecs", @@ -673,8 +658,8 @@ dependencies = [ [[package]] name = "bevy_asset" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "async-broadcast", "async-channel", @@ -716,19 +701,19 @@ dependencies = [ [[package]] name = "bevy_asset_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_audio" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -742,8 +727,8 @@ dependencies = [ [[package]] name = "bevy_camera" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -754,6 +739,7 @@ dependencies = [ "bevy_math", "bevy_mesh", "bevy_reflect", + "bevy_shape", "bevy_transform", "bevy_utils", "bevy_window", @@ -762,21 +748,27 @@ dependencies = [ "serde", "smallvec", "thiserror 2.0.20", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_camera_controller" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_camera", + "bevy_color", + "bevy_curve", + "bevy_derive", "bevy_ecs", + "bevy_image", "bevy_input", "bevy_log", "bevy_math", "bevy_picking", + "bevy_platform", + "bevy_render", "bevy_time", "bevy_transform", "bevy_window", @@ -784,9 +776,10 @@ dependencies = [ [[package]] name = "bevy_clipboard" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ + "arboard", "bevy_app", "bevy_ecs", "bevy_log", @@ -798,9 +791,10 @@ dependencies = [ [[package]] name = "bevy_color" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ + "bevy_curve", "bevy_math", "bevy_reflect", "bytemuck", @@ -808,13 +802,13 @@ dependencies = [ "encase", "serde", "thiserror 2.0.20", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_core_pipeline" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -823,6 +817,7 @@ dependencies = [ "bevy_derive", "bevy_diagnostic", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_light", "bevy_log", @@ -848,56 +843,78 @@ dependencies = [ "bevy", "cudarc", "thiserror 2.0.20", - "wgpu", - "wgpu-hal", + "wgpu 29.0.4", + "wgpu-hal 29.0.4", "windows 0.58.0", ] +[[package]] +name = "bevy_curve" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" +dependencies = [ + "approx", + "bevy_math", + "bevy_reflect", + "itertools 0.15.0", + "serde", + "thiserror 2.0.20", + "variadics_please", +] + [[package]] name = "bevy_derive" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_dev_tools" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ + "bevy_animation", "bevy_app", "bevy_asset", + "bevy_audio", "bevy_camera", "bevy_color", - "bevy_core_pipeline", "bevy_diagnostic", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_input", + "bevy_light", "bevy_log", "bevy_math", - "bevy_pbr", + "bevy_mesh", "bevy_picking", + "bevy_platform", "bevy_reflect", "bevy_render", "bevy_shader", + "bevy_sprite", "bevy_state", "bevy_text", "bevy_time", "bevy_transform", "bevy_ui", - "bevy_ui_render", + "bevy_ui_widgets", + "bevy_utils", "bevy_window", + "bevy_world_serialization", + "strsim", "tracing", ] [[package]] name = "bevy_diagnostic" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "atomic-waker", "bevy_app", @@ -913,8 +930,8 @@ dependencies = [ [[package]] name = "bevy_ecs" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "arrayvec", "bevy_ecs_macros", @@ -940,40 +957,68 @@ dependencies = [ [[package]] name = "bevy_ecs_macro_logic" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_ecs_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_ecs_macro_logic", - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_encase_derive" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "encase_derive_impl", ] +[[package]] +name = "bevy_extract" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" +dependencies = [ + "bevy_app", + "bevy_camera", + "bevy_derive", + "bevy_ecs", + "bevy_extract_macros", + "bevy_log", + "bevy_platform", + "bevy_reflect", + "bevy_time", + "bevy_utils", +] + +[[package]] +name = "bevy_extract_macros" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" +dependencies = [ + "bevy_macro_utils", + "proc-macro2", + "quote", + "syn 3.0.3", +] + [[package]] name = "bevy_feathers" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "accesskit", "bevy_a11y", @@ -1001,10 +1046,15 @@ dependencies = [ "smol_str", ] +[[package]] +name = "bevy_fuzzy" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" + [[package]] name = "bevy_gilrs" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_ecs", @@ -1018,13 +1068,14 @@ dependencies = [ [[package]] name = "bevy_gizmos" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", "bevy_camera", "bevy_color", + "bevy_curve", "bevy_ecs", "bevy_gizmos_macros", "bevy_input", @@ -1032,6 +1083,7 @@ dependencies = [ "bevy_math", "bevy_mesh", "bevy_reflect", + "bevy_shape", "bevy_time", "bevy_transform", "bevy_utils", @@ -1040,18 +1092,18 @@ dependencies = [ [[package]] name = "bevy_gizmos_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_gizmos_render" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1059,6 +1111,7 @@ dependencies = [ "bevy_color", "bevy_core_pipeline", "bevy_ecs", + "bevy_extract", "bevy_gizmos", "bevy_image", "bevy_log", @@ -1069,6 +1122,7 @@ dependencies = [ "bevy_reflect", "bevy_render", "bevy_shader", + "bevy_shape", "bevy_sprite_render", "bevy_transform", "bevy_utils", @@ -1078,8 +1132,8 @@ dependencies = [ [[package]] name = "bevy_gltf" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "async-lock", "base64", @@ -1088,6 +1142,7 @@ dependencies = [ "bevy_asset", "bevy_camera", "bevy_color", + "bevy_curve", "bevy_ecs", "bevy_image", "bevy_light", @@ -1101,20 +1156,20 @@ dependencies = [ "bevy_world_serialization", "fixedbitset", "gltf", - "itertools", + "itertools 0.15.0", "percent-encoding", "serde", "serde_json", "smallvec", "thiserror 2.0.20", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_image" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1136,13 +1191,13 @@ dependencies = [ "serde", "thiserror 2.0.20", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_input" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_ecs", @@ -1157,10 +1212,11 @@ dependencies = [ [[package]] name = "bevy_input_focus" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", + "bevy_camera", "bevy_ecs", "bevy_input", "bevy_math", @@ -1173,12 +1229,13 @@ dependencies = [ [[package]] name = "bevy_internal" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_a11y", "bevy_android", "bevy_animation", + "bevy_annotations", "bevy_anti_alias", "bevy_app", "bevy_asset", @@ -1188,11 +1245,14 @@ dependencies = [ "bevy_clipboard", "bevy_color", "bevy_core_pipeline", + "bevy_curve", "bevy_derive", "bevy_dev_tools", "bevy_diagnostic", "bevy_ecs", + "bevy_extract", "bevy_feathers", + "bevy_fuzzy", "bevy_gilrs", "bevy_gizmos", "bevy_gizmos_render", @@ -1214,6 +1274,7 @@ dependencies = [ "bevy_render", "bevy_scene", "bevy_shader", + "bevy_shape", "bevy_sprite", "bevy_sprite_render", "bevy_state", @@ -1232,13 +1293,14 @@ dependencies = [ [[package]] name = "bevy_light" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", "bevy_camera", "bevy_color", + "bevy_curve", "bevy_ecs", "bevy_gizmos", "bevy_image", @@ -1247,18 +1309,19 @@ dependencies = [ "bevy_mesh", "bevy_platform", "bevy_reflect", + "bevy_shape", "bevy_transform", "bevy_utils", "half", "smallvec", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_log" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "android_log-sys", "bevy_app", @@ -1274,31 +1337,19 @@ dependencies = [ [[package]] name = "bevy_macro_utils" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", - "toml_edit 0.25.13+spec-1.1.0", -] - -[[package]] -name = "bevy_macro_utils" -version = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7164fe229422295bba15f1885048f34f4660db069aacb895208f996b0c7784fb" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.119", - "toml_edit 0.25.13+spec-1.1.0", + "syn 3.0.3", + "toml_edit", ] [[package]] name = "bevy_material" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_asset", "bevy_derive", @@ -1314,33 +1365,30 @@ dependencies = [ "thiserror 2.0.20", "tracing", "variadics_please", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_material_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_math" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "approx", - "arrayvec", "bevy_reflect", "derive_more", - "glam 0.32.1", - "itertools", + "glam", "libm", "rand 0.10.2", - "rand_distr", "serde", "thiserror 2.0.20", "variadics_please", @@ -1348,29 +1396,30 @@ dependencies = [ [[package]] name = "bevy_mesh" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", "bevy_derive", "bevy_ecs", - "bevy_encase_derive", "bevy_math", "bevy_mikktspace", "bevy_platform", "bevy_reflect", + "bevy_shape", "bevy_transform", "bitflags 2.13.1", "bytemuck", "derive_more", "encase", - "glam 0.32.1", + "glam", "half", "hexasphere", + "serde", "thiserror 2.0.20", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] @@ -1382,16 +1431,16 @@ checksum = "bff34eb29ff4b8a8688bc7299f14fb6b597461ca80fec03ed7d22939ab33e48f" [[package]] name = "bevy_naga_reflect" version = "0.2.0" -source = "git+https://github.com/tychedelia/bevy_naga_reflect#3e59d3698281fcf6c56a6478be3ee12049737218" +source = "git+https://github.com/tychedelia/bevy_naga_reflect?branch=bevy-020-fixes#8c50ac2dc36eb0aa463ad7b29a8d979ea5a8adae" dependencies = [ "bevy", - "naga", + "naga 29.0.4", ] [[package]] name = "bevy_pbr" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "arrayvec", "bevy_app", @@ -1402,6 +1451,7 @@ dependencies = [ "bevy_derive", "bevy_diagnostic", "bevy_ecs", + "bevy_extract", "bevy_gltf", "bevy_image", "bevy_light", @@ -1413,6 +1463,7 @@ dependencies = [ "bevy_reflect", "bevy_render", "bevy_shader", + "bevy_shape", "bevy_tasks", "bevy_transform", "bevy_utils", @@ -1427,13 +1478,13 @@ dependencies = [ "static_assertions", "thiserror 2.0.20", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_picking" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1445,6 +1496,7 @@ dependencies = [ "bevy_mesh", "bevy_platform", "bevy_reflect", + "bevy_shape", "bevy_time", "bevy_transform", "bevy_window", @@ -1455,37 +1507,40 @@ dependencies = [ [[package]] name = "bevy_platform" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ + "bytemuck", "critical-section", "foldhash 0.2.0", "futures-channel", "futures-lite", - "hashbrown 0.16.1", + "hashbrown 0.17.1", "js-sys", "portable-atomic", "portable-atomic-util", "serde", - "spin 0.10.1", + "spin 0.12.3", "wasm-bindgen", "wasm-bindgen-futures", "web-time", - "windows-sys 0.61.2", + "windows-sys 0.59.0", ] [[package]] name = "bevy_post_process" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", "bevy_camera", "bevy_color", "bevy_core_pipeline", + "bevy_curve", "bevy_derive", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_math", "bevy_platform", @@ -1500,15 +1555,16 @@ dependencies = [ [[package]] name = "bevy_ptr" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" [[package]] name = "bevy_reflect" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "assert_type_match", + "bevy_annotations", "bevy_platform", "bevy_ptr", "bevy_reflect_derive", @@ -1518,36 +1574,36 @@ dependencies = [ "downcast-rs 2.0.2", "erased-serde", "foldhash 0.2.0", - "glam 0.32.1", + "glam", "indexmap", "inventory", - "petgraph 0.8.3", + "petgraph", "serde", "smallvec", "smol_str", "thiserror 2.0.20", "uuid", "variadics_please", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_reflect_derive" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "indexmap", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", "uuid", ] [[package]] name = "bevy_render" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "async-channel", "bevy_app", @@ -1558,6 +1614,8 @@ dependencies = [ "bevy_diagnostic", "bevy_ecs", "bevy_encase_derive", + "bevy_extract", + "bevy_extract_macros", "bevy_image", "bevy_log", "bevy_material", @@ -1568,6 +1626,7 @@ dependencies = [ "bevy_reflect", "bevy_render_macros", "bevy_shader", + "bevy_shape", "bevy_tasks", "bevy_time", "bevy_transform", @@ -1578,46 +1637,48 @@ dependencies = [ "derive_more", "downcast-rs 2.0.2", "encase", - "glam 0.32.1", + "glam", "image", "indexmap", - "itertools", + "itertools 0.15.0", "js-sys", - "naga", "nonmax", "offset-allocator", "send_wrapper", "smallvec", + "spin_sleep", + "static_assertions", "thiserror 2.0.20", + "tracing", "variadics_please", "wasm-bindgen", "weak-table", "web-sys", - "wgpu", - "wgpu-types", + "wgpu 30.0.2", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_render_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_extract_macros", + "bevy_macro_utils", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_scene" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", "bevy_derive", "bevy_ecs", - "bevy_log", "bevy_platform", "bevy_reflect", "bevy_scene_macros", @@ -1630,76 +1691,51 @@ dependencies = [ [[package]] name = "bevy_scene_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_ecs_macro_logic", - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] -name = "bevy_seedling" -version = "0.8.0" -source = "git+https://github.com/CorvusPrudens/bevy_seedling?branch=master#ab4a88b430d216e8614549926e3532bcec5ce2db" +name = "bevy_shader" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_app", "bevy_asset", - "bevy_diagnostic", - "bevy_ecs", - "bevy_log", - "bevy_math", "bevy_platform", "bevy_reflect", - "bevy_seedling_macros", - "bevy_time", - "bevy_transform", "bevy_utils", - "cpal 0.18.1", - "firewheel", - "firewheel-ircam-hrtf", - "rand 0.10.2", - "smallvec", - "symphonia", - "symphonium", -] - -[[package]] -name = "bevy_seedling_macros" -version = "0.8.0" -source = "git+https://github.com/CorvusPrudens/bevy_seedling?branch=master#ab4a88b430d216e8614549926e3532bcec5ce2db" -dependencies = [ - "bevy_macro_utils 0.19.1", - "proc-macro2", - "quote", - "syn 2.0.119", + "serde", + "thiserror 2.0.20", + "tracing", + "wesl", + "wgpu-types 30.0.2", ] [[package]] -name = "bevy_shader" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +name = "bevy_shape" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_asset", - "bevy_platform", + "arrayvec", + "bevy_math", "bevy_reflect", - "bevy_utils", - "naga", - "naga_oil", + "derive_more", + "rand 0.10.2", + "rand_distr", "serde", "thiserror 2.0.20", - "tracing", - "wesl", - "wgpu-naga-bridge", - "wgpu-types", ] [[package]] name = "bevy_sprite" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1718,13 +1754,13 @@ dependencies = [ "bevy_window", "radsort", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_sprite_render" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1733,6 +1769,7 @@ dependencies = [ "bevy_core_pipeline", "bevy_derive", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_material", "bevy_math", @@ -1741,6 +1778,7 @@ dependencies = [ "bevy_reflect", "bevy_render", "bevy_shader", + "bevy_shape", "bevy_sprite", "bevy_text", "bevy_transform", @@ -1750,13 +1788,15 @@ dependencies = [ "derive_more", "fixedbitset", "nonmax", + "smallvec", + "static_assertions", "tracing", ] [[package]] name = "bevy_state" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_ecs", @@ -1770,18 +1810,18 @@ dependencies = [ [[package]] name = "bevy_state_macros" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ - "bevy_macro_utils 0.19.0", + "bevy_macro_utils", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] name = "bevy_tasks" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "async-channel", "async-executor", @@ -1798,8 +1838,8 @@ dependencies = [ [[package]] name = "bevy_text" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -1813,21 +1853,20 @@ dependencies = [ "bevy_platform", "bevy_reflect", "bevy_utils", - "parley 0.9.0", + "parley 0.11.1", "serde", "smallvec", "smol_str", "swash", - "sys-locale", "thiserror 2.0.20", "tracing", - "wgpu-types", + "wgpu-types 30.0.2", ] [[package]] name = "bevy_time" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_ecs", @@ -1840,8 +1879,8 @@ dependencies = [ [[package]] name = "bevy_transform" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_ecs", @@ -1856,8 +1895,8 @@ dependencies = [ [[package]] name = "bevy_ui" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "accesskit", "bevy_a11y", @@ -1882,7 +1921,7 @@ dependencies = [ "bevy_utils", "bevy_window", "derive_more", - "parley 0.9.0", + "parley 0.11.1", "smallvec", "swash", "taffy", @@ -1893,9 +1932,10 @@ dependencies = [ [[package]] name = "bevy_ui_render" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ + "bevy_a11y", "bevy_app", "bevy_asset", "bevy_camera", @@ -1903,6 +1943,7 @@ dependencies = [ "bevy_core_pipeline", "bevy_derive", "bevy_ecs", + "bevy_extract", "bevy_image", "bevy_input_focus", "bevy_math", @@ -1920,13 +1961,14 @@ dependencies = [ "bytemuck", "derive_more", "indexmap", + "smallvec", "tracing", ] [[package]] name = "bevy_ui_widgets" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "accesskit", "bevy_a11y", @@ -1938,18 +1980,22 @@ dependencies = [ "bevy_log", "bevy_math", "bevy_picking", + "bevy_platform", "bevy_reflect", "bevy_text", + "bevy_time", "bevy_ui", "bevy_window", - "parley 0.9.0", + "parley 0.11.1", "smol_str", + "thiserror 2.0.20", + "web-sys", ] [[package]] name = "bevy_utils" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "async-channel", "bevy_platform", @@ -1960,11 +2006,12 @@ dependencies = [ [[package]] name = "bevy_window" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", + "bevy_color", "bevy_ecs", "bevy_image", "bevy_input", @@ -1978,8 +2025,8 @@ dependencies = [ [[package]] name = "bevy_winit" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "accesskit", "accesskit_winit", @@ -2004,14 +2051,14 @@ dependencies = [ "tracing", "wasm-bindgen", "web-sys", - "wgpu-types", + "wgpu-types 30.0.2", "winit", ] [[package]] name = "bevy_world_serialization" -version = "0.19.0" -source = "git+https://github.com/processing/bevy?branch=main#6717bb35291b66ff1925e4387c48e0499e351423" +version = "0.20.0-dev" +source = "git+https://github.com/processing/bevy?branch=main#f65b12082e0322f0a498b2958fb0712ff5c73bd6" dependencies = [ "bevy_app", "bevy_asset", @@ -2054,28 +2101,22 @@ dependencies = [ [[package]] name = "bit-set" -version = "0.8.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3" +checksum = "34ddef2995421ab6a5c779542c81ee77c115206f4ad9d5a8e05f4ff49716a3dd" dependencies = [ - "bit-vec 0.8.0", + "bit-vec", ] [[package]] name = "bit-set" -version = "0.9.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34ddef2995421ab6a5c779542c81ee77c115206f4ad9d5a8e05f4ff49716a3dd" +checksum = "09ec2f926cc3060f09db9ebc5b52823d85268d24bb917e472c0c4bea35780a7d" dependencies = [ - "bit-vec 0.9.1", + "bit-vec", ] -[[package]] -name = "bit-vec" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" - [[package]] name = "bit-vec" version = "0.9.1" @@ -2113,6 +2154,18 @@ dependencies = [ "no_std_io2", ] +[[package]] +name = "bitvec" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddcec3d12c579d40898fe0a9a358a803c23e9c52ca3c425707f81c9436211837" +dependencies = [ + "funty", + "radium", + "tap", + "wyz", +] + [[package]] name = "blake3" version = "1.8.6" @@ -2124,7 +2177,7 @@ dependencies = [ "cc", "cfg-if 1.0.4", "constant_time_eq", - "cpufeatures 0.3.0", + "cpufeatures", ] [[package]] @@ -2133,15 +2186,6 @@ version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - [[package]] name = "block2" version = "0.5.1" @@ -2265,7 +2309,7 @@ dependencies = [ "serde_json", "syn 2.0.119", "tempfile", - "toml", + "toml 0.9.12+spec-1.1.0", ] [[package]] @@ -2320,7 +2364,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d524456ba66e72eb8b115ff89e01e497f8e6d11d78b70b1aa13c0fbd97540a81" dependencies = [ "cfg-if 1.0.4", - "cpufeatures 0.3.0", + "cpufeatures", "rand_core 0.10.1", ] @@ -2363,12 +2407,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c8d4a3bb8b1e0c1050499d1815f5ab16d04f0959b233085fb31653fbfc9d98f9" [[package]] -name = "cmake" -version = "0.1.58" +name = "clipboard-win" +version = "5.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0f78a02292a74a88ac736019ab962ece0bc380e3f977bf72e376c5d78ff0678" +checksum = "052af7878466feccda12ba7a6a67d019d712f296809559b47c12c8cc196d3a9a" dependencies = [ - "cc", + "error-code", ] [[package]] @@ -2399,17 +2443,6 @@ dependencies = [ "objc", ] -[[package]] -name = "codespan-reporting" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe6d2e5af09e8c8ad56c969f2157a3d4238cebc7c55f0a517728c38f7b200f81" -dependencies = [ - "serde", - "termcolor", - "unicode-width", -] - [[package]] name = "codespan-reporting" version = "0.13.1" @@ -2677,17 +2710,20 @@ dependencies = [ [[package]] name = "cpal" -version = "0.17.3" +version = "0.18.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8942da362c0f0d895d7cac616263f2f9424edc5687364dfd1d25ef7eba506d7" +checksum = "6f02e8d0327b42d3e2e4ab2119af397344eb9fc54a34bf0ddeaa1277af8681f1" dependencies = [ "alsa", + "block2 0.6.2", "coreaudio-rs", "dasp_sample", - "jni 0.21.1", + "futures-channel", + "futures-util", + "jni 0.22.4", "js-sys", "libc", - "mach2 0.5.0", + "mach2", "ndk", "ndk-context", "num-derive", @@ -2703,54 +2739,14 @@ dependencies = [ "wasm-bindgen-futures", "web-sys", "windows 0.62.2", + "windows-core 0.62.2", ] [[package]] -name = "cpal" -version = "0.18.1" +name = "cpufeatures" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f77b11176c37874be37e8d691c946e31b2b8c357abce9526f6a99eb469e1028" -dependencies = [ - "alsa", - "block2 0.6.2", - "coreaudio-rs", - "dasp_sample", - "jni 0.22.4", - "js-sys", - "libc", - "mach2 0.6.0", - "ndk", - "ndk-context", - "num-derive", - "num-traits", - "objc2 0.6.4", - "objc2-audio-toolbox", - "objc2-avf-audio", - "objc2-core-audio", - "objc2-core-audio-types", - "objc2-core-foundation", - "objc2-foundation 0.3.2", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "windows 0.62.2", - "windows-core 0.62.2", -] - -[[package]] -name = "cpufeatures" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" -dependencies = [ - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201" +checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201" dependencies = [ "libc", ] @@ -2819,16 +2815,6 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5" -[[package]] -name = "crypto-common" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" -dependencies = [ - "generic-array", - "typenum", -] - [[package]] name = "ctor" version = "1.0.13" @@ -2867,12 +2853,6 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c87e182de0887fd5361989c677c4e8f5000cd9491d6d563161a8f3a5519fc7f" -[[package]] -name = "data-encoding" -version = "2.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4583a4551df46e2792f82ceeac45e850d2e2d5debba0b91f102385cda5b11f06" - [[package]] name = "derive_more" version = "2.1.1" @@ -2896,16 +2876,6 @@ dependencies = [ "unicode-xid", ] -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "crypto-common", -] - [[package]] name = "dispatch" version = "0.2.0" @@ -2999,20 +2969,11 @@ version = "1.17.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e5e8f6c15a24b9a3ee5efec809ccd006d3b30e8b3bb63c39af737c7f87daa1d" -[[package]] -name = "ena" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eabffdaee24bd1bf95c5ef7cec31260444317e72ea56c4c91750e8b7ee58d5f1" -dependencies = [ - "log", -] - [[package]] name = "encase" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e3e0ff2ee0b7aa97428308dd9e1e42369cb22f5fb8dc1c55546637443a60f1e" +checksum = "fdf6312703f02e0625e1750eadf556054b6da5e44960a3a771e9127cb357dbd8" dependencies = [ "const_panic", "encase_derive", @@ -3021,22 +2982,22 @@ dependencies = [ [[package]] name = "encase_derive" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4d90c5d7d527c6cb8a3b114efd26a6304d9ab772656e73d8f4e32b1f3d601a2" +checksum = "8429e24f02acf09b0fb3c4560c329a1a79fab14bbb9c2d632c073d0a61b0816a" dependencies = [ "encase_derive_impl", ] [[package]] name = "encase_derive_impl" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8bad72d8308f7a382de2391ec978ddd736e0103846b965d7e2a63a75768af30" +checksum = "3ac3bf06563c72a9b64bc4d8da00ebcabd1d776ea4526c3b1461697142fe340f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] @@ -3086,6 +3047,12 @@ dependencies = [ "windows-sys 0.61.2", ] +[[package]] +name = "error-code" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b5343afd4a8365a643ac588dab4cf234a190c7f6c88c9f6dd6ffe00837661b7" + [[package]] name = "euclid" version = "0.22.14" @@ -3132,12 +3099,6 @@ dependencies = [ "zune-inflate", ] -[[package]] -name = "extended" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af9673d8203fcb076b19dfd17e38b3d4ae9f44959416ea532ce72415a6020365" - [[package]] name = "fastrand" version = "2.5.0" @@ -3174,166 +3135,6 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "26b73573e6edcd2af0cdf47bd6cb58f0b3839491263c314eaad1ccf24430e1de" -[[package]] -name = "firewheel" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cce6a0e2684404563f22daf00caa3672a9fd1503af5c58cd79a544a8221cec6e" -dependencies = [ - "firewheel-core", - "firewheel-cpal", - "firewheel-graph", - "firewheel-nodes", - "firewheel-rtaudio", - "firewheel-symphonium", - "thiserror 2.0.20", -] - -[[package]] -name = "firewheel-core" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c793ba83a0c4861d467af68844970bd063249189790f00c7feda5019732466b" -dependencies = [ - "arrayvec", - "audioadapter", - "audioadapter-buffers", - "audioadapter-sample", - "bevy_ecs", - "bevy_platform", - "bevy_reflect", - "bitflags 2.13.1", - "firewheel-macros", - "glam 0.29.3", - "glam 0.30.10", - "glam 0.31.1", - "glam 0.32.1", - "num-traits", - "portable-atomic", - "ringbuf", - "smallvec", - "thiserror 2.0.20", - "thunderdome", - "wmidi", -] - -[[package]] -name = "firewheel-cpal" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6cf893a68d8b89fbb6eeca6deb5166fd342cc827bf4ad37d31a973bc861bf038" -dependencies = [ - "audioadapter-buffers", - "bevy_platform", - "cpal 0.18.1", - "firewheel-core", - "firewheel-graph", - "fixed-resample", - "thiserror 2.0.20", - "tracing", -] - -[[package]] -name = "firewheel-graph" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00257afdba7edc48ce1667fc144d453f7bd17674a78450207507ca286e818b82" -dependencies = [ - "arrayvec", - "audioadapter", - "bevy_platform", - "bevy_reflect", - "bitflags 2.13.1", - "firewheel-core", - "num-traits", - "ringbuf", - "smallvec", - "thiserror 2.0.20", - "thunderdome", - "tracing", - "triple_buffer", - "wasm-bindgen", -] - -[[package]] -name = "firewheel-ircam-hrtf" -version = "0.5.0" -source = "git+https://github.com/CorvusPrudens/bevy_seedling?branch=master#ab4a88b430d216e8614549926e3532bcec5ce2db" -dependencies = [ - "bevy_ecs", - "bevy_reflect", - "firewheel", - "glam 0.32.1", - "hrtf", -] - -[[package]] -name = "firewheel-macros" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e19ca164d0116746e81d86266ad78d0d57e1be18437439ca6c4c8a97160bec2f" -dependencies = [ - "bevy_macro_utils 0.19.1", - "proc-macro2", - "quote", - "syn 2.0.119", - "toml_edit 0.23.10+spec-1.0.0", -] - -[[package]] -name = "firewheel-nodes" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32f4d58cfbb1c65d19e4490ed81b2e16153ab5e355535ef79aef044583adfcba" -dependencies = [ - "bevy_ecs", - "bevy_platform", - "bevy_reflect", - "firewheel-core", - "num-traits", - "smallvec", - "thiserror 2.0.20", - "triple_buffer", -] - -[[package]] -name = "firewheel-rtaudio" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a136e3893d1c1b691f355ba7b535e0a7df16ad49b7788aa88805bf473105a755" -dependencies = [ - "audioadapter-buffers", - "bevy_platform", - "firewheel-core", - "firewheel-graph", - "rtaudio", - "thiserror 2.0.20", - "tracing", -] - -[[package]] -name = "firewheel-symphonium" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8261282ec848bcd8e64c715fb6d3778e2208819b1c5c015f04bc8709ac5465f" -dependencies = [ - "bevy_platform", - "firewheel-core", - "symphonium", -] - -[[package]] -name = "fixed-resample" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3505607cc0adc388ce98f59707477c02fbd05a2fa0c1b8c4cf42b71a3cb9c34" -dependencies = [ - "audioadapter", - "audioadapter-buffers", - "ringbuf", - "rubato 4.0.0", -] - [[package]] name = "fixedbitset" version = "0.5.7" @@ -3404,6 +3205,15 @@ dependencies = [ "bytemuck", ] +[[package]] +name = "font-types" +version = "0.12.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "835ae9d781464a79026cde387f9cbc650c9a4909d7cf7e658b127e3c35d2f35d" +dependencies = [ + "bytemuck", +] + [[package]] name = "fontique" version = "0.7.0" @@ -3429,15 +3239,15 @@ dependencies = [ [[package]] name = "fontique" -version = "0.9.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c20b425addb8661e97fe1d51c4d8bcec3ec29ed6ad0db983976a7521276b8f7" +checksum = "6688bc1294fe7117d788937b6c53480169b29c566954af490830d4c09da9516a" dependencies = [ "hashbrown 0.17.1", "linebender_resource_handle", "memmap2", "parlance", - "read-fonts 0.39.2", + "read-fonts 0.41.0", "smallvec", ] @@ -3492,6 +3302,12 @@ dependencies = [ "libc", ] +[[package]] +name = "funty" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" + [[package]] name = "futures" version = "0.3.34" @@ -3600,16 +3416,6 @@ dependencies = [ "pyo3-introspection", ] -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - [[package]] name = "gethostname" version = "1.1.0" @@ -3718,28 +3524,11 @@ dependencies = [ [[package]] name = "glam" -version = "0.29.3" +version = "0.34.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8babf46d4c1c9d92deac9f7be466f76dfc4482b6452fc5024b5e8daf6ffeb3ee" - -[[package]] -name = "glam" -version = "0.30.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19fc433e8437a212d1b6f1e68c7824af3aed907da60afa994e7f542d18d12aa9" - -[[package]] -name = "glam" -version = "0.31.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "556f6b2ea90b8d15a74e0e7bb41671c9bdf38cd9f78c284d750b9ce58a2b5be7" - -[[package]] -name = "glam" -version = "0.32.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f70749695b063ecbf6b62949ccccde2e733ec3ecbbd71d467dca4e5c6c97cca0" +checksum = "627003914c6057c9c8f0832ee4f870b5a4f599d0cfa83f4072675114860cd0ff" dependencies = [ + "approx", "bytemuck", "encase", "libm", @@ -3879,20 +3668,13 @@ dependencies = [ "bitflags 2.13.1", ] -[[package]] -name = "grid" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b40ca9252762c466af32d0b1002e91e4e1bc5398f77455e55474deb466355ff5" - [[package]] name = "guillotiere" -version = "0.6.2" +version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b62d5865c036cb1393e23c50693df631d3f5d7bcca4c04fe4cc0fd592e74a782" +checksum = "6b17e70c989c36bad147b27a58d148c0741c51448aa5653436547323e524d0ab" dependencies = [ "euclid", - "svg_fmt", ] [[package]] @@ -3924,14 +3706,13 @@ dependencies = [ [[package]] name = "harfrust" -version = "0.6.2" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "551ed25397e4b444e89686602877d5cf3a7f6e3d548dcac37a8357d1e195f4df" +checksum = "c03d949a14aa089bbb282f7dd76a498a7f684428e4257202efc119ec010376f9" dependencies = [ "bitflags 2.13.1", "bytemuck", - "core_maths", - "read-fonts 0.39.2", + "read-fonts 0.41.0", "smallvec", ] @@ -3972,7 +3753,10 @@ version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" dependencies = [ + "equivalent", "foldhash 0.2.0", + "serde", + "serde_core", ] [[package]] @@ -4000,12 +3784,12 @@ checksum = "fc0fef456e4baa96da950455cd02c081ca953b141298e41db3fc7e36b1da849c" [[package]] name = "hexasphere" -version = "18.0.0" +version = "20.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "177ea6330876de4ef08e184f827b98acc037614a4ce409902c5b0d53a9c2e951" +checksum = "982158ac107d91d1a45fe1d3be9a1b4414e6724cdb12a183cf06365cc972a0a1" dependencies = [ "constgebra", - "glam 0.32.1", + "glam", "tinyvec", ] @@ -4024,17 +3808,6 @@ dependencies = [ "windows-sys 0.61.2", ] -[[package]] -name = "hrtf" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f4de47a84fd55fa33aa5ef337016814fdc869fdad23e7898b5322fa290248e6" -dependencies = [ - "byteorder", - "rubato 0.14.1", - "rustfft", -] - [[package]] name = "icu_collections" version = "2.3.0" @@ -4276,6 +4049,15 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b4baf93f58d4425749ca49a51c50ebab072c5df6994d08fed93541c331481dc" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "1.0.18" @@ -4403,15 +4185,6 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "keccak" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb26cec98cce3a3d96cbb7bced3c4b16e3d13f27ec56dbd62cbc8f39cfb9d653" -dependencies = [ - "cpufeatures 0.2.17", -] - [[package]] name = "khronos-egl" version = "6.0.0" @@ -4458,35 +4231,13 @@ dependencies = [ "bitflags 2.13.1", ] -[[package]] -name = "lalrpop" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4ebbd48ce411c1d10fb35185f5a51a7bfa3d8b24b4e330d30c9e3a34129501" -dependencies = [ - "ascii-canvas", - "bit-set 0.8.0", - "ena", - "itertools", - "lalrpop-util", - "petgraph 0.7.1", - "regex", - "regex-syntax", - "sha3", - "string_cache", - "term", - "unicode-xid", - "walkdir", -] - [[package]] name = "lalrpop-util" -version = "0.22.2" +version = "0.23.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5baa5e9ff84f1aefd264e6869907646538a52147a755d494517a8007fb48733" +checksum = "364b49d1c98c07972e16fe1346463becc08bcd663da04e6e37ab1bea068dce6a" dependencies = [ "regex-automata", - "rustversion", ] [[package]] @@ -4586,9 +4337,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.189" +version = "0.2.191" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2" +checksum = "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a" [[package]] name = "libfuzzer-sys" @@ -4796,15 +4547,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "mach2" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a1b95cd5421ec55b445b5ae102f5ea0e768de1f82bd3001e11f426c269c3aea" -dependencies = [ - "libc", -] - [[package]] name = "mach2" version = "0.6.0" @@ -4953,6 +4695,12 @@ dependencies = [ "nasm-rs", ] +[[package]] +name = "mutants" +version = "0.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bc0287524726960e07b119cebd01678f852f147742ae0d925e6a520dca956126" + [[package]] name = "naga" version = "29.0.4" @@ -4964,7 +4712,7 @@ dependencies = [ "bitflags 2.13.1", "cfg-if 1.0.4", "cfg_aliases", - "codespan-reporting 0.13.1", + "codespan-reporting", "half", "hashbrown 0.16.1", "hexf-parse", @@ -4973,7 +4721,6 @@ dependencies = [ "log", "num-traits", "once_cell", - "pp-rs", "rustc-hash 1.1.0", "serde", "spirv", @@ -4982,26 +4729,48 @@ dependencies = [ ] [[package]] -name = "naga_oil" -version = "0.22.0" +name = "naga" +version = "30.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "319f03062940ed85c03da020042618356bb8ca5263020322930883b05e30208e" +checksum = "fd0dd362bf26c0ffdd143df6da66a25d287e196eff482f117771010b207ad163" dependencies = [ - "codespan-reporting 0.12.0", - "data-encoding", + "arrayvec", + "bit-set 0.10.0", + "bitflags 2.13.1", + "cfg-if 1.0.4", + "cfg_aliases", + "codespan-reporting", + "half", + "hashbrown 0.17.1", "indexmap", - "naga", - "regex", - "rustc-hash 1.1.0", - "thiserror 2.0.20", - "tracing", + "libm", + "log", + "naga-types", + "num-traits", + "once_cell", + "rustc-hash 1.1.0", + "spirv", + "thiserror 2.0.20", "unicode-ident", ] +[[package]] +name = "naga-types" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14474170feb673cfb18b3565111a9869797cc1d290fb9ec969c53f5e1e231c6d" +dependencies = [ + "hashbrown 0.17.1", + "indexmap", + "rustc-hash 1.1.0", + "serde", + "thiserror 2.0.20", +] + [[package]] name = "nannou_midi" -version = "0.1.0" -source = "git+https://github.com/nannou-org/nannou?branch=bevy-refactor#f713c439c03b4e4614c2ef8ff899932efd0a1c44" +version = "0.20.0" +source = "git+https://github.com/tychedelia/nannou?branch=bevy-020#ab3cacc8eed0bc0436fd87d0bf7932c9e81c9ffc" dependencies = [ "bevy", "crossbeam-channel", @@ -5010,13 +4779,13 @@ dependencies = [ [[package]] name = "nannou_webcam" -version = "0.1.0" -source = "git+https://github.com/nannou-org/nannou?branch=bevy-refactor#f713c439c03b4e4614c2ef8ff899932efd0a1c44" +version = "0.20.0" +source = "git+https://github.com/tychedelia/nannou?branch=bevy-020#ab3cacc8eed0bc0436fd87d0bf7932c9e81c9ffc" dependencies = [ "bevy", "console_error_panic_hook", "flume", - "getrandom 0.3.4", + "getrandom 0.4.3", "nokhwa", "wasm-bindgen", "web-sys", @@ -5783,6 +5552,7 @@ dependencies = [ "bitflags 2.13.1", "objc2 0.6.4", "objc2-core-foundation", + "objc2-core-graphics", "objc2-foundation 0.3.2", "objc2-metal 0.3.2", ] @@ -5901,6 +5671,16 @@ dependencies = [ "num-traits", ] +[[package]] +name = "os_pipe" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d8fae84b431384b68627d0f9b3b1245fcf9f46f6c0e3dc902e9dce64edd1967" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + [[package]] name = "owned_ttf_parser" version = "0.25.1" @@ -5961,12 +5741,12 @@ dependencies = [ [[package]] name = "parley" -version = "0.9.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fad031076f48f0d4d85ce1aea9b94b4e715a4d636a030a123038f8f5b5e4343" +checksum = "22d2ff88bd3f7d68d1d9b09c7e6209f9a8e8c05088295140a2bcf2e9b17038c5" dependencies = [ - "fontique 0.9.0", - "harfrust 0.6.2", + "fontique 0.11.1", + "harfrust 0.12.0", "hashbrown 0.17.1", "icu_normalizer", "icu_properties", @@ -5974,14 +5754,14 @@ dependencies = [ "linebender_resource_handle", "parlance", "parley_data", - "skrifa 0.42.1", + "skrifa 0.44.0", ] [[package]] name = "parley_data" -version = "0.9.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19ab9ace3fad1b9ed603ddac5b595e69931fc50263d7e04e4055015b77b02da5" +checksum = "1567535334d6ba2d3cde19221ba9a7bd0fabb3cbd99046ddfb10ae061cfcc889" dependencies = [ "icu_properties", ] @@ -6010,16 +5790,6 @@ version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" -[[package]] -name = "petgraph" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3672b37090dbd86368a4145bc067582552b29c27377cad4e0a306c97f9bd7772" -dependencies = [ - "fixedbitset", - "indexmap", -] - [[package]] name = "petgraph" version = "0.8.3" @@ -6033,15 +5803,6 @@ dependencies = [ "serde_derive", ] -[[package]] -name = "phf_shared" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67eabc2ef2a60eb7faa00097bd1ffdb5bd28e62bf39990626a582201b7a754e5" -dependencies = [ - "siphasher", -] - [[package]] name = "pin-project" version = "1.1.13" @@ -6144,15 +5905,6 @@ dependencies = [ "zerovec", ] -[[package]] -name = "pp-rs" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb458bb7f6e250e6eb79d5026badc10a3ebb8f9a15d1fff0f13d17c71f4d6dee" -dependencies = [ - "unicode-xid", -] - [[package]] name = "ppv-lite86" version = "0.2.21" @@ -6162,12 +5914,6 @@ dependencies = [ "zerocopy", ] -[[package]] -name = "precomputed-hash" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" - [[package]] name = "presser" version = "0.3.1" @@ -6184,22 +5930,13 @@ dependencies = [ "syn 2.0.119", ] -[[package]] -name = "primal-check" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc0d895b311e3af9902528fbb8f928688abbd95872819320517cc24ca6b2bd08" -dependencies = [ - "num-integer", -] - [[package]] name = "proc-macro-crate" version = "3.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" dependencies = [ - "toml_edit 0.25.13+spec-1.1.0", + "toml_edit", ] [[package]] @@ -6227,7 +5964,6 @@ version = "0.4.0" dependencies = [ "bevy", "js-sys", - "processing_audio", "processing_core", "processing_cuda", "processing_glfw", @@ -6242,14 +5978,6 @@ dependencies = [ "web-sys", ] -[[package]] -name = "processing_audio" -version = "0.4.0" -dependencies = [ - "bevy", - "bevy_seedling", -] - [[package]] name = "processing_core" version = "0.4.0" @@ -6352,7 +6080,7 @@ dependencies = [ "half", "js-sys", "lyon", - "naga", + "naga 29.0.4", "notosans", "objc2 0.6.4", "objc2-app-kit 0.3.2", @@ -6360,12 +6088,13 @@ dependencies = [ "png", "processing_core", "raw-window-handle", + "serde_json", "skrifa 0.37.0", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", "wesl", - "wgpu", + "wgpu 30.0.2", "windows 0.58.0", ] @@ -6552,6 +6281,12 @@ version = "6.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" +[[package]] +name = "radium" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" + [[package]] name = "radsort" version = "0.1.1" @@ -6636,7 +6371,7 @@ dependencies = [ "built", "cfg-if 1.0.4", "interpolate_name", - "itertools", + "itertools 0.14.0", "libc", "libfuzzer-sys", "log", @@ -6739,12 +6474,14 @@ dependencies = [ ] [[package]] -name = "realfft" -version = "3.5.0" +name = "read-fonts" +version = "0.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f821338fddb99d089116342c46e9f1fbf3828dba077674613e734e01d6ea8677" +checksum = "046a7d674daf459825b32f5062056d6882db0d2f5a479fbd76ccfc870ac18709" dependencies = [ - "rustfft", + "bytemuck", + "font-types 0.12.7", + "once_cell", ] [[package]] @@ -6809,12 +6546,6 @@ dependencies = [ "regex-syntax", ] -[[package]] -name = "regex-lite" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cab834c73d247e67f4fae452806d17d3c7501756d98c8808d7c9c7aa7d18f973" - [[package]] name = "regex-syntax" version = "0.8.11" @@ -6836,24 +6567,13 @@ dependencies = [ "bytemuck", ] -[[package]] -name = "ringbuf" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a158e09ede21a14b172ca6cdd6208386c6ae2cb6acef58d774368ef8c450dfa7" -dependencies = [ - "crossbeam-utils", - "portable-atomic", - "portable-atomic-util", -] - [[package]] name = "rodio" -version = "0.22.2" +version = "0.23.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0a536bb79db59098ef71a4dd4246c02eb87b316deceb1b68e0cde7167ec01eb" +checksum = "36e3ee0a5ca418bac59a15d5506e498ab138359edbb67257a6b8a3b93d411f39" dependencies = [ - "cpal 0.17.3", + "cpal", "dasp_sample", "lewton", "num-rational", @@ -6884,56 +6604,6 @@ dependencies = [ "memchr", ] -[[package]] -name = "rtaudio" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7384a8837efe4abea0e53f3887b5072cbbd1ee95c298cff4fbd7a9f3ff23a48b" -dependencies = [ - "bitflags 2.13.1", - "rtaudio-sys", - "thiserror 2.0.20", - "tracing", -] - -[[package]] -name = "rtaudio-sys" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "931ec9a72c48e96e8e2f9868aef1d4e452723354779d01159f7399647427b57b" -dependencies = [ - "cmake", - "pkg-config", -] - -[[package]] -name = "rubato" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6dd52e80cfc21894deadf554a5673002938ae4625f7a283e536f9cf7c17b0d5" -dependencies = [ - "num-complex", - "num-integer", - "num-traits", - "realfft", -] - -[[package]] -name = "rubato" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f57c655d11e929f05a8663b323ff553f8d9773be05dfdc087795955bedeb8d92" -dependencies = [ - "audioadapter", - "audioadapter-buffers", - "num-complex", - "num-integer", - "num-traits", - "realfft", - "visibility", - "windowfunctions", -] - [[package]] name = "rustc-hash" version = "1.1.0" @@ -6955,20 +6625,6 @@ dependencies = [ "semver", ] -[[package]] -name = "rustfft" -version = "6.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21db5f9893e91f41798c88680037dba611ca6674703c1a18601b01a72c8adb89" -dependencies = [ - "num-complex", - "num-integer", - "num-traits", - "primal-check", - "strength_reduce", - "transpose", -] - [[package]] name = "rustix" version = "0.38.44" @@ -7003,9 +6659,9 @@ checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" [[package]] name = "ruzstd" -version = "0.8.3" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7c1c839d570d835527c9a5e4db7cb2198683a988cb9d7293fc8674e6bd58fc8" +checksum = "69e4ce4a039f42bf25920b95667e4d789e98749ab11bbb8d2c2936f788421bb5" dependencies = [ "twox-hash", ] @@ -7121,23 +6777,13 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "1.1.1" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26" +checksum = "9c187e0a369471c550af028cba56d4f4fa2a489ad28151ae95a4d340a2a8b782" dependencies = [ "serde_core", ] -[[package]] -name = "sha3" -version = "0.10.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77fd7028345d415a4034cf8777cd4f8ab1851274233b45f84e3d955502d93874" -dependencies = [ - "digest", - "keccak", -] - [[package]] name = "sharded-slab" version = "0.1.7" @@ -7190,12 +6836,6 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e" -[[package]] -name = "siphasher" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649" - [[package]] name = "skrifa" version = "0.37.0" @@ -7216,6 +6856,16 @@ dependencies = [ "read-fonts 0.39.2", ] +[[package]] +name = "skrifa" +version = "0.44.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "819ab7d62b1d3e72d9d9dea5650bac30424f9111364bb94928dbf5ecad1baa68" +dependencies = [ + "bytemuck", + "read-fonts 0.41.0", +] + [[package]] name = "slab" version = "0.4.12" @@ -7282,13 +6932,22 @@ dependencies = [ [[package]] name = "spin" -version = "0.10.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "023a211cb3138dbc438680b32560ad89f699977624c9f8dbb95a47d5b4c07dd3" +checksum = "0134f9043ed38b087ac4f7d4af44c79e2c9e5094421fe3164f435ce585953b10" dependencies = [ "portable-atomic", ] +[[package]] +name = "spin_sleep" +version = "1.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c07347b7c0301b9adba4350bdcf09c039d0e7160922050db0439b3c6723c8ab" +dependencies = [ + "windows-sys 0.61.2", +] + [[package]] name = "spirv" version = "0.4.0+sdk-1.4.341.0" @@ -7319,42 +6978,18 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "strength_reduce" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe895eb47f22e2ddd4dabc02bce419d2e643c8e3b585c78158b349195bc24d82" - [[package]] name = "strict-num" version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6637bab7722d379c8b41ba849228d680cc12d0a45ba1fa2b48f2a30577a06731" -[[package]] -name = "string_cache" -version = "0.8.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf776ba3fa74f83bf4b63c3dcbbf82173db2632ed8452cb2d891d33f459de70f" -dependencies = [ - "new_debug_unreachable", - "parking_lot", - "phf_shared", - "precomputed-hash", -] - [[package]] name = "strsim" version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" -[[package]] -name = "svg_fmt" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0193cc4331cfd2f3d2011ef287590868599a2f33c3e69bc22c1a3d3acf9e02fb" - [[package]] name = "swash" version = "0.2.10" @@ -7366,116 +7001,6 @@ dependencies = [ "zeno", ] -[[package]] -name = "symphonia" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7edef6a96b696d4e0cab5ee9ebb7ca155ed95f30a6b45bbb8b97d2727f02424" -dependencies = [ - "lazy_static", - "symphonia-codec-pcm", - "symphonia-codec-vorbis", - "symphonia-core", - "symphonia-format-ogg", - "symphonia-format-riff", - "symphonia-metadata", -] - -[[package]] -name = "symphonia-codec-pcm" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e04ba75686acbe43542fdd374571195f0530c0b7785ca25cc6840e9c6c4b6eea" -dependencies = [ - "log", - "symphonia-core", -] - -[[package]] -name = "symphonia-codec-vorbis" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73d90b4fcf796137cc683c538282804ff9629f8ad9dbfd881fcbba331ac4e986" -dependencies = [ - "log", - "symphonia-common", - "symphonia-core", -] - -[[package]] -name = "symphonia-common" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2acc3fcc18ec9b8cdd48614e259c4cf0d27b71d41e5d9b120b42c5adab12d7c4" -dependencies = [ - "log", - "symphonia-core", - "symphonia-metadata", -] - -[[package]] -name = "symphonia-core" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01c412864d599d4750d0c3d684d7e093ec05e5309681ef5252cc1096a437f6e0" -dependencies = [ - "bitflags 2.13.1", - "bytemuck", - "lazy_static", - "log", - "num-complex", - "rustfft", - "smallvec", -] - -[[package]] -name = "symphonia-format-ogg" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b5495e7f7e3c7035328d82b6d6e377eef289bb0c4105bdeb557fc93a833f994" -dependencies = [ - "log", - "symphonia-common", - "symphonia-core", - "symphonia-metadata", -] - -[[package]] -name = "symphonia-format-riff" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ff70929083a8c1a5f6cd7c904b6071c7914ad04739b510c2f7239dfc9b7dabe" -dependencies = [ - "extended", - "log", - "symphonia-core", - "symphonia-metadata", -] - -[[package]] -name = "symphonia-metadata" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83713a97705d77bdef7cdbc0768fd6e5a54e4cd7e48d60a806ae85639e2c87c6" -dependencies = [ - "lazy_static", - "log", - "regex-lite", - "smallvec", - "symphonia-core", -] - -[[package]] -name = "symphonium" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6cc514081a8a6eb44a4ee5e68d981bf11d976876d0612082121969b31e7d53a8" -dependencies = [ - "fixed-resample", - "symphonia", - "tracing", -] - [[package]] name = "syn" version = "2.0.119" @@ -7509,20 +7034,11 @@ dependencies = [ "syn 2.0.119", ] -[[package]] -name = "sys-locale" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eab9a99a024a169fe8a903cf9d4a3b3601109bcc13bd9e3c6fff259138626c4" -dependencies = [ - "libc", -] - [[package]] name = "sysinfo" -version = "0.38.4" +version = "0.40.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92ab6a2f8bfe508deb3c6406578252e491d299cbbf3bc0529ecc3313aee4a52f" +checksum = "3e80749408e2d8bec0ffa303012cf4e1b3b355f4a09087b4fdf7473680f6a2de" dependencies = [ "libc", "memchr", @@ -7534,16 +7050,21 @@ dependencies = [ [[package]] name = "taffy" -version = "0.10.1" +version = "0.15.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aea22054047c16c3f34d3ac473a2170be1424b1115b2a3adcf28cfb067c88859" +checksum = "31f7bd2d97198df05186f93a3a3c306845f40e8b3c22bf9279cdd7e5cf5fea7d" dependencies = [ - "arrayvec", - "grid", "serde", "slotmap", + "smallvec", ] +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + [[package]] name = "target-lexicon" version = "0.13.5" @@ -7563,15 +7084,6 @@ dependencies = [ "windows-sys 0.61.2", ] -[[package]] -name = "term" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8c27177b12a6399ffc08b98f76f7c9a1f4fe9fc967c784c5a071fa8d93cf7e1" -dependencies = [ - "windows-sys 0.61.2", -] - [[package]] name = "termcolor" version = "1.4.1" @@ -7630,12 +7142,6 @@ dependencies = [ "cfg-if 1.0.4", ] -[[package]] -name = "thunderdome" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92e170f93360bf9ae6fe3c31116bbf27adb1d054cedd6bc3d7857e34f2d98d0b" - [[package]] name = "tiff" version = "0.11.3" @@ -7717,33 +7223,36 @@ dependencies = [ ] [[package]] -name = "toml_datetime" -version = "0.7.5+spec-1.1.0" +name = "toml" +version = "1.2.1+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92e1cfed4a3038bc5a127e35a2d360f145e1f4b971b551a2ba5fd7aedf7e1347" +checksum = "d5755c51863cdac711f1956baf8eb9588e060755f7d3c4c979e70ea1e1f32cd7" dependencies = [ + "indexmap", "serde_core", + "serde_spanned", + "toml_datetime 1.1.3+spec-1.1.0", + "toml_parser", + "toml_writer", + "winnow 1.0.4", ] [[package]] name = "toml_datetime" -version = "1.1.1+spec-1.1.0" +version = "0.7.5+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" +checksum = "92e1cfed4a3038bc5a127e35a2d360f145e1f4b971b551a2ba5fd7aedf7e1347" dependencies = [ "serde_core", ] [[package]] -name = "toml_edit" -version = "0.23.10+spec-1.0.0" +name = "toml_datetime" +version = "1.1.3+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84c8b9f757e028cee9fa244aea147aab2a9ec09d5325a9b01e0a49730c2b5269" +checksum = "173f25c883cd2176a2d8212155638c0a60d484a9d84546d270866f40f56b6e49" dependencies = [ - "indexmap", - "toml_datetime 0.7.5+spec-1.1.0", - "toml_parser", - "winnow 0.7.15", + "serde_core", ] [[package]] @@ -7753,25 +7262,25 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6975367e4d2ef766d86af01ffad14b622fecc8d4357a998fbc4deb6e9bacaf9b" dependencies = [ "indexmap", - "toml_datetime 1.1.1+spec-1.1.0", + "toml_datetime 1.1.3+spec-1.1.0", "toml_parser", "winnow 1.0.4", ] [[package]] name = "toml_parser" -version = "1.1.3+spec-1.1.0" +version = "1.1.5+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d38ac1cf9b95face32296c0a3ede1fdc270627c9d9c02a7274dd6d960dc4d56" +checksum = "baa693a8032d7e1cada7d0041e96126df243179ff061456783ac7f12bda4744c" dependencies = [ "winnow 1.0.4", ] [[package]] name = "toml_writer" -version = "1.1.2+spec-1.1.0" +version = "1.2.0+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d56353a2a665ad0f41a421187180aab746c8c325620617ad883a99a1cbe66d2" +checksum = "009dbb7700f11c55ef83aebbe4c0e9cf1f1ac0844bd8d6f00dc38f302026e13a" [[package]] name = "tracing" @@ -7858,22 +7367,14 @@ dependencies = [ ] [[package]] -name = "transpose" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad61aed86bc3faea4300c7aee358b4c6d0c8d6ccc36524c96e4c92ccf26e77e" -dependencies = [ - "num-integer", - "strength_reduce", -] - -[[package]] -name = "triple_buffer" -version = "9.0.0" +name = "tree_magic_mini" +version = "3.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e875ab7068a75b74f419da453927e05527c36f0001b3c7aad3ce443640683487" +checksum = "b8765b90061cba6c22b5831f675da109ae5561588290f9fa2317adab2714d5a6" dependencies = [ - "crossbeam-utils", + "memchr", + "nom 8.0.0", + "petgraph", ] [[package]] @@ -7894,12 +7395,6 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c" -[[package]] -name = "typenum" -version = "1.20.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" - [[package]] name = "typewit" version = "1.15.2" @@ -7930,6 +7425,17 @@ version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853" +[[package]] +name = "unsynn" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "501a7adf1a4bd9951501e5c66621e972ef8874d787628b7f90e64f936ef7ec0a" +dependencies = [ + "mutants", + "proc-macro2", + "rustc-hash 2.1.3", +] + [[package]] name = "utf8_iter" version = "1.0.4" @@ -7993,13 +7499,12 @@ checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" [[package]] name = "variadics_please" -version = "1.1.0" +version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41b6d82be61465f97d42bd1d15bf20f3b0a3a0905018f38f9d6f6962055b0b5c" +checksum = "b53d0f7f2d0182759a549f1f313ce16b07d8f9ba93098157b5fa10ee3e61117f" dependencies = [ - "proc-macro2", "quote", - "syn 2.0.119", + "unsynn", ] [[package]] @@ -8014,17 +7519,6 @@ version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" -[[package]] -name = "visibility" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d674d135b4a8c1d7e813e2f8d1c9a58308aee4a680323066025e53132218bd91" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.119", -] - [[package]] name = "walkdir" version = "2.5.0" @@ -8216,9 +7710,13 @@ dependencies = [ [[package]] name = "weak-table" -version = "0.3.2" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "323f4da9523e9a669e1eaf9c6e763892769b1d38c623913647bfdc1532fe4549" +checksum = "5eba2ec791141b0bf4db542f6b038a8f9310cee33e076cb181245780b09a24ff" +dependencies = [ + "cfg-if 1.0.4", + "hashbrown 0.16.1", +] [[package]] name = "web-sys" @@ -8260,33 +7758,42 @@ checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88" [[package]] name = "wesl" -version = "0.3.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be113b462f90d3e303324739a4431bc63dfd0b463d7582cc76c1fd2093b5d470" +checksum = "fdd8f9619baa4c7bde4df0899d6f626b70ee92d6e9c18c5f74473419b5bb6fa6" dependencies = [ "annotate-snippets", + "anstream", "derive_more", + "glob", "half", - "itertools", + "itertools 0.15.0", "num-traits", - "proc-macro2", - "quote", + "serde", "thiserror 2.0.20", + "toml 1.2.1+spec-1.1.0", + "wesl-core", "wesl-macros", "wgsl-parse", "wgsl-types", ] +[[package]] +name = "wesl-core" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84dd3e600497eda0b47afcd21bd84c8953a9dfce7e93ed27a38ba97ac0747e03" + [[package]] name = "wesl-macros" -version = "0.3.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d321ea9e1cc0a2e3de41c02e3a7586695a9c03beccb5460e938a7ccf00cb612" +checksum = "ac8767ec26e75262a8e581d5f188b1f63a288baaf885bb33c9f4f73a693e06fc" dependencies = [ - "itertools", + "itertools 0.15.0", "proc-macro2", "quote", - "syn 2.0.119", + "syn 3.0.3", ] [[package]] @@ -8304,7 +7811,37 @@ dependencies = [ "hashbrown 0.16.1", "js-sys", "log", - "naga", + "naga 29.0.4", + "parking_lot", + "portable-atomic", + "profiling", + "raw-window-handle", + "smallvec", + "static_assertions", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "wgpu-core 29.0.4", + "wgpu-hal 29.0.4", + "wgpu-types 29.0.4", +] + +[[package]] +name = "wgpu" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "146fc3d654250e6207921a66c87534c621bc886c70df83dcf466c1d66813810e" +dependencies = [ + "arrayvec", + "bitflags 2.13.1", + "bytemuck", + "cfg-if 1.0.4", + "cfg_aliases", + "document-features", + "hashbrown 0.17.1", + "js-sys", + "log", + "naga 30.0.2", "parking_lot", "portable-atomic", "profiling", @@ -8314,9 +7851,9 @@ dependencies = [ "wasm-bindgen", "wasm-bindgen-futures", "web-sys", - "wgpu-core", - "wgpu-hal", - "wgpu-types", + "wgpu-core 30.0.2", + "wgpu-hal 30.0.2", + "wgpu-types 30.0.2", ] [[package]] @@ -8327,7 +7864,7 @@ checksum = "2f519832254e56965a9940c4af57dcb75f702b6f6fa4a0b172f685395843a4d7" dependencies = [ "arrayvec", "bit-set 0.9.1", - "bit-vec 0.9.1", + "bit-vec", "bitflags 2.13.1", "bytemuck", "cfg_aliases", @@ -8335,7 +7872,7 @@ dependencies = [ "hashbrown 0.16.1", "indexmap", "log", - "naga", + "naga 29.0.4", "once_cell", "parking_lot", "portable-atomic", @@ -8344,13 +7881,47 @@ dependencies = [ "rustc-hash 1.1.0", "smallvec", "thiserror 2.0.20", - "wgpu-core-deps-apple", - "wgpu-core-deps-emscripten", + "wgpu-core-deps-apple 29.0.4", + "wgpu-core-deps-emscripten 29.0.4", + "wgpu-core-deps-windows-linux-android 29.0.4", + "wgpu-hal 29.0.4", + "wgpu-naga-bridge 29.0.4", + "wgpu-types 29.0.4", +] + +[[package]] +name = "wgpu-core" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad661da2ee99f208c30090b585284b2ab5b8bf2358ddf2d2215592808ec62f1a" +dependencies = [ + "arrayvec", + "bit-set 0.10.0", + "bit-vec", + "bitflags 2.13.1", + "bytemuck", + "cfg_aliases", + "document-features", + "hashbrown 0.17.1", + "indexmap", + "log", + "naga 30.0.2", + "naga-types", + "once_cell", + "parking_lot", + "portable-atomic", + "profiling", + "raw-window-handle", + "rustc-hash 1.1.0", + "smallvec", + "thiserror 2.0.20", + "wgpu-core-deps-apple 30.0.2", + "wgpu-core-deps-emscripten 30.0.2", "wgpu-core-deps-wasm", - "wgpu-core-deps-windows-linux-android", - "wgpu-hal", - "wgpu-naga-bridge", - "wgpu-types", + "wgpu-core-deps-windows-linux-android 30.0.2", + "wgpu-hal 30.0.2", + "wgpu-naga-bridge 30.0.2", + "wgpu-types 30.0.2", ] [[package]] @@ -8359,7 +7930,16 @@ version = "29.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f5e39e26c4c0e07589e67d18546cf79ff45383659fc72fca4dd293358a0347f3" dependencies = [ - "wgpu-hal", + "wgpu-hal 29.0.4", +] + +[[package]] +name = "wgpu-core-deps-apple" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d3f2f24aee039ffe9ef527300daf6b7428c58edeefdaa1700f4fa0fd754df16" +dependencies = [ + "wgpu-hal 30.0.2", ] [[package]] @@ -8368,16 +7948,25 @@ version = "29.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "01e09be551dc939498bdd5f6b2c66e55ab275dad25825267a08605a80fc9f0af" dependencies = [ - "wgpu-hal", + "wgpu-hal 29.0.4", +] + +[[package]] +name = "wgpu-core-deps-emscripten" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55ccf093bd215ae9dc4f96df293e675513ac1f2569f8293a2911cc34ca3505d1" +dependencies = [ + "wgpu-hal 30.0.2", ] [[package]] name = "wgpu-core-deps-wasm" -version = "29.0.4" +version = "30.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af1fb1798be2a912497d4c224f72d39bb0cb34af50e8bcc29865bc339c943059" +checksum = "b20f43aeb9962d05e61e3ccb717e2e27ba1b04e979d4ca7e361384f8ee03db56" dependencies = [ - "wgpu-hal", + "wgpu-hal 30.0.2", ] [[package]] @@ -8386,7 +7975,16 @@ version = "29.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4e592c1bbef6ad047647ae6e666ebd8cee7a32bb4544d9700ec96cbf73230257" dependencies = [ - "wgpu-hal", + "wgpu-hal 29.0.4", +] + +[[package]] +name = "wgpu-core-deps-windows-linux-android" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1331b08fa2362c5d454eccc4448e6e4f01eccfea569a00e310adbfc4415f2bdc" +dependencies = [ + "wgpu-hal 30.0.2", ] [[package]] @@ -8414,7 +8012,7 @@ dependencies = [ "libc", "libloading 0.8.9", "log", - "naga", + "naga 29.0.4", "ndk-sys", "objc2 0.6.4", "objc2-core-foundation", @@ -8436,8 +8034,64 @@ dependencies = [ "wasm-bindgen", "wayland-sys", "web-sys", - "wgpu-naga-bridge", - "wgpu-types", + "wgpu-naga-bridge 29.0.4", + "wgpu-types 29.0.4", + "windows 0.62.2", + "windows-core 0.62.2", + "windows-result 0.4.1", +] + +[[package]] +name = "wgpu-hal" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a57452fe453658e141aafdb09de1028afa498805fab518238ddf372a518813ff" +dependencies = [ + "android_system_properties", + "arrayvec", + "ash", + "bit-set 0.10.0", + "bitflags 2.13.1", + "block2 0.6.2", + "bytemuck", + "cfg-if 1.0.4", + "cfg_aliases", + "glow", + "glutin_wgl_sys", + "gpu-allocator", + "hashbrown 0.17.1", + "js-sys", + "khronos-egl", + "libc", + "libloading 0.8.9", + "log", + "naga 30.0.2", + "naga-types", + "ndk-sys", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation 0.3.2", + "objc2-metal 0.3.2", + "objc2-quartz-core 0.3.2", + "once_cell", + "ordered-float", + "parking_lot", + "portable-atomic", + "portable-atomic-util", + "profiling", + "range-alloc", + "raw-window-handle", + "raw-window-metal", + "renderdoc-sys", + "smallvec", + "static_assertions", + "thiserror 2.0.20", + "wasm-bindgen", + "wayland-sys", + "web-sys", + "wgpu-naga-bridge 30.0.2", + "wgpu-types 30.0.2", "windows 0.62.2", "windows-core 0.62.2", "windows-result 0.4.1", @@ -8449,8 +8103,18 @@ version = "29.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95226013f547544b223281cd16a4fb549aa9dcb562adbda0faae4c73ffbbc161" dependencies = [ - "naga", - "wgpu-types", + "naga 29.0.4", + "wgpu-types 29.0.4", +] + +[[package]] +name = "wgpu-naga-bridge" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44a62ead68aad7cd40ac9e2cd2b8ec64f32dfbad2765f429b9fb74b8b735869f" +dependencies = [ + "naga 30.0.2", + "wgpu-types 30.0.2", ] [[package]] @@ -8464,20 +8128,35 @@ dependencies = [ "js-sys", "log", "raw-window-handle", + "web-sys", +] + +[[package]] +name = "wgpu-types" +version = "30.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9f6ee0bd50f5ab79fb8c25e3f33afb27126f034af4ba5909c7a0967058659e6" +dependencies = [ + "bitflags 2.13.1", + "bytemuck", + "js-sys", + "log", + "naga-types", + "raw-window-handle", "serde", + "static_assertions", "web-sys", ] [[package]] name = "wgsl-parse" -version = "0.3.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "946419efa46664a8070c512fb358ac4acfc6e6215c2396ae5afeb9b72dd6ca7d" +checksum = "37cee524ba5cfabfd65d10a316b646f8a4c50f3663e7e787471f21b783261f47" dependencies = [ "annotate-snippets", "derive_more", - "itertools", - "lalrpop", + "itertools 0.15.0", "lalrpop-util", "lexical", "logos", @@ -8487,12 +8166,12 @@ dependencies = [ [[package]] name = "wgsl-types" -version = "0.3.2" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7aed068ca1dc8fb182f574c9f2ace45ec988c71ba050f6dd334883fe3b8a88e2" +checksum = "e119dd12e57d937397535201959ddddb5dbf26505402db5ef305ebb1ca9a7e5f" dependencies = [ "half", - "itertools", + "itertools 0.15.0", "num-traits", ] @@ -8539,15 +8218,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" -[[package]] -name = "windowfunctions" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90628d739333b7c5d2ee0b70210b97b8cddc38440c682c96fd9e2c24c2db5f3a" -dependencies = [ - "num-traits", -] - [[package]] name = "windows" version = "0.58.0" @@ -9010,9 +8680,6 @@ name = "winnow" version = "0.7.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945" -dependencies = [ - "memchr", -] [[package]] name = "winnow" @@ -9030,10 +8697,22 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" [[package]] -name = "wmidi" -version = "4.0.11" +name = "wl-clipboard-rs" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b1b1e28ac6301b1c097d21c11130090f7ecc5db9d5ef4e52595ab942f8d76d5" +checksum = "959c7ac3b8afde864f7a7448ac16f29b2b83350b7eccbf77fb781c3999aa6848" +dependencies = [ + "libc", + "log", + "os_pipe", + "rustix 1.1.4", + "thiserror 2.0.20", + "tree_magic_mini", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-protocols-wlr", +] [[package]] name = "writeable" @@ -9041,6 +8720,15 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc" +[[package]] +name = "wyz" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" +dependencies = [ + "tap", +] + [[package]] name = "x11" version = "2.21.0" diff --git a/Cargo.toml b/Cargo.toml index 5ef3f465..a1af2e05 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,9 +18,11 @@ cuda = ["dep:processing_cuda", "processing_cuda/cuda"] [workspace] resolver = "3" members = ["crates/*", "tools/*"] +# TEMP(bevy-020): bevy_seedling pins bevy 0.19 +exclude = ["crates/processing_audio"] [workspace.package] -rust-version = "1.95" +rust-version = "1.100" [workspace.lints.clippy] type_complexity = "allow" @@ -52,17 +54,16 @@ bevy = { git = "https://github.com/processing/bevy", branch = "main", default-fe "wayland", "webgl2", "x11", - "shader_format_wesl", "free_camera", "pan_camera", # image formats Processing loads "jpeg", ] } -bevy_naga_reflect = { git = "https://github.com/tychedelia/bevy_naga_reflect" } +bevy_naga_reflect = { git = "https://github.com/tychedelia/bevy_naga_reflect", branch = "bevy-020-fixes" } bevy_cuda = { git = "https://github.com/tychedelia/bevy_cuda" } naga = { version = "29", features = ["wgsl-in"] } -wesl = { version = "0.3", default-features = false } +wesl = { version = "0.6", features = ["naga-ext"] } pyo3 = { git = "https://github.com/PyO3/pyo3", branch = "main" } pyo3-introspection = { git = "https://github.com/PyO3/pyo3", branch = "main" } processing = { path = "." } @@ -71,7 +72,8 @@ processing_cuda = { path = "crates/processing_cuda" } processing_pyo3 = { path = "crates/processing_pyo3" } processing_render = { path = "crates/processing_render" } processing_midi = { path = "crates/processing_midi" } -processing_audio = { path = "crates/processing_audio" } +# TEMP(bevy-020): bevy_seedling pins bevy 0.19 +# processing_audio = { path = "crates/processing_audio" } processing_input = { path = "crates/processing_input" } processing_glfw = { path = "crates/processing_glfw" } processing_webcam = { path = "crates/processing_webcam" } @@ -83,7 +85,8 @@ bevy = { workspace = true } processing_core = { workspace = true } processing_render = { workspace = true } processing_midi = { workspace = true } -processing_audio = { workspace = true } +# TEMP(bevy-020): bevy_seedling pins bevy 0.19 +# processing_audio = { workspace = true } processing_input = { workspace = true } processing_webcam = { workspace = true, optional = true } processing_cuda = { workspace = true, optional = true } diff --git a/assets/shaders/custom_vertex.wesl b/assets/shaders/custom_vertex.wesl index 7f332a3e..02c39d44 100644 --- a/assets/shaders/custom_vertex.wesl +++ b/assets/shaders/custom_vertex.wesl @@ -1,11 +1,11 @@ import { processing::VertexOutput }; -import { processing::mesh::{Vertex, vertex_output} }; +import { processing::mesh::{Vertex, vertex_input, vertex_output} }; @group(3) @binding(0) var bulge: f32; @vertex fn vertex(vertex_in: Vertex) -> VertexOutput { - var vertex = vertex_in; + var vertex = vertex_input(vertex_in); // `sphere()` draws a unit sphere scaled by its transform vertex.position += vertex.normal * bulge * sin(vertex.position.y * 12.0); return vertex_output(vertex); diff --git a/crates/processing_midi/Cargo.toml b/crates/processing_midi/Cargo.toml index 66d86ac9..61f426ca 100644 --- a/crates/processing_midi/Cargo.toml +++ b/crates/processing_midi/Cargo.toml @@ -7,7 +7,7 @@ rust-version.workspace = true [dependencies] bevy = { workspace = true } processing_core = { workspace = true } -nannou_midi = { git = "https://github.com/nannou-org/nannou", branch = "bevy-refactor" } +nannou_midi = { git = "https://github.com/tychedelia/nannou", branch = "bevy-020" } [target.'cfg(target_os = "macos")'.dependencies] midir = { version = "0.11", features = ["coremidi_send_timestamped"] } diff --git a/crates/processing_pyo3/examples/Demos/Tests/first_frame.py b/crates/processing_pyo3/examples/Demos/Tests/first_frame.py index b94cb009..4c368522 100644 --- a/crates/processing_pyo3/examples/Demos/Tests/first_frame.py +++ b/crates/processing_pyo3/examples/Demos/Tests/first_frame.py @@ -7,11 +7,13 @@ from random import seed, uniform points = None +instances = None +instance = None mat = None def setup(): - global points, mat + global points, instances, instance, mat size(800, 600) mode_3d() @@ -25,6 +27,13 @@ def setup(): positions.append([220 + uniform(-60, 60), 120 + uniform(-60, 60), uniform(-60, 60)]) points.buffer("position").write(positions) + instances = create_particles(7, attributes=[Attribute.position()]) + positions = [] + for i in range(7): + positions.append([-150 + i * 50, -30, 0]) + instances.buffer("position").write(positions) + instance = Geometry.sphere(16, 12, 8) + def draw(): camera_position(0.0, 0.0, 500.0) @@ -71,5 +80,8 @@ def draw(): # particle points particles(points) + # instanced particles + particles(instances, instance) + run() diff --git a/crates/processing_pyo3/src/color.rs b/crates/processing_pyo3/src/color.rs index baad62b0..a47ab274 100644 --- a/crates/processing_pyo3/src/color.rs +++ b/crates/processing_pyo3/src/color.rs @@ -132,6 +132,9 @@ fn components(color: &Color) -> [f32; 4] { Color::Lcha(c) => c.to_f32_array(), Color::Oklaba(c) => c.to_f32_array(), Color::Oklcha(c) => c.to_f32_array(), + Color::Okhsla(c) => c.to_f32_array(), + Color::Okhsva(c) => c.to_f32_array(), + Color::Okhwba(c) => c.to_f32_array(), Color::Xyza(c) => c.to_f32_array(), } } @@ -148,6 +151,9 @@ fn components_no_alpha(color: &Color) -> [f32; 3] { Color::Lcha(c) => c.to_f32_array_no_alpha(), Color::Oklaba(c) => c.to_f32_array_no_alpha(), Color::Oklcha(c) => c.to_f32_array_no_alpha(), + Color::Okhsla(c) => c.to_f32_array_no_alpha(), + Color::Okhsva(c) => c.to_f32_array_no_alpha(), + Color::Okhwba(c) => c.to_f32_array_no_alpha(), Color::Xyza(c) => c.to_f32_array_no_alpha(), } } diff --git a/crates/processing_render/Cargo.toml b/crates/processing_render/Cargo.toml index 97475164..48a02b79 100644 --- a/crates/processing_render/Cargo.toml +++ b/crates/processing_render/Cargo.toml @@ -16,7 +16,7 @@ x11 = ["bevy/x11"] bevy = { workspace = true } bevy_naga_reflect = { workspace = true } # direct wgpu dep to reach `wgpu::util::TextureBlitter` (unifies to bevy's wgpu) -wgpu = "29" +wgpu = "30" naga = { workspace = true } wesl = { workspace = true } lyon = "1.0" @@ -32,7 +32,7 @@ png = "0.18" processing_core = { workspace = true } [build-dependencies] -wesl = { workspace = true, features = ["package"] } +serde_json = "1" [target.'cfg(not(target_arch = "wasm32"))'.dependencies] bevy = { workspace = true, features = ["file_watcher"] } diff --git a/crates/processing_render/build.rs b/crates/processing_render/build.rs index 715507c8..257828a5 100644 --- a/crates/processing_render/build.rs +++ b/crates/processing_render/build.rs @@ -1,35 +1,147 @@ +use std::fmt::Write; use std::path::Path; -// packages wesl libraries for processing and lygia -// note that bevy does not (as of yet) understand how to use these packages -// they are, instead, used by us as part of shader pre-processing in the -// processing_render crate +// Embeds the `processing` and `lygia` WESL packages as tables of module sources; they are +// registered with bevy at startup, so any shader can import them. fn main() { - wesl::PkgBuilder::new("processing") - .scan_root("shaders/processing") - .expect("failed to scan processing WESL files") - .build_artifact() - .expect("failed to build processing package artifact"); + let mut code = String::new(); + package( + &mut code, + "PROCESSING", + "processing", + Path::new("shaders/processing"), + ); + package(&mut code, "LYGIA", "lygia", Path::new("../../lygia")); + engine(&mut code); + let out = Path::new(&std::env::var_os("OUT_DIR").unwrap()).join("shader_modules.rs"); + std::fs::write(out, code).unwrap(); +} + +// Bevy's own shader modules that ours import, for editors to resolve those imports. A bevy +// module is named after its crate and its path under `src`. +fn engine(code: &mut String) { + let metadata = std::process::Command::new(std::env::var_os("CARGO").unwrap()) + .args(["metadata", "--format-version", "1", "--locked", "--offline"]) + .output() + .expect("cargo metadata"); + assert!( + metadata.status.success(), + "cargo metadata failed: {}", + String::from_utf8_lossy(&metadata.stderr) + ); + let metadata: serde_json::Value = serde_json::from_slice(&metadata.stdout).unwrap(); + let crates: std::collections::BTreeMap = metadata["packages"] + .as_array() + .unwrap() + .iter() + .filter_map(|package| { + let name = package["name"].as_str()?; + let manifest = Path::new(package["manifest_path"].as_str()?); + name.starts_with("bevy_") + .then(|| (name.to_string(), manifest.parent().unwrap().join("src"))) + }) + .collect(); + + // the crates our packages import, and the crates those import + let mut wanted: Vec = Vec::new(); + let mut sources: Vec = ["shaders/processing.wesl", "shaders/processing"] + .iter() + .flat_map(|path| wesl_files(Path::new(path))) + .map(|path| std::fs::read_to_string(path).unwrap()) + .collect(); + let mut modules = Vec::new(); + while let Some(source) = sources.pop() { + for name in crates.keys() { + if source.contains(&format!("{name}::")) && !wanted.contains(name) { + wanted.push(name.clone()); + let mut found = Vec::new(); + walk(&crates[name], name, "", &mut found); + for (_, _, path) in &found { + sources.push(std::fs::read_to_string(path).unwrap()); + } + modules.extend(found); + } + } + } + modules.sort(); + table(code, "ENGINE", modules); +} + +fn wesl_files(path: &Path) -> Vec { + if path.is_file() { + return vec![path.to_path_buf()]; + } + let mut files = Vec::new(); + for entry in std::fs::read_dir(path).into_iter().flatten().flatten() { + let path = entry.path(); + if path.is_dir() || path.extension().is_some_and(|ext| ext == "wesl") { + files.extend(wesl_files(&path)); + } + } + files +} - let mut lygia = wesl::PkgBuilder::new("lygia") - .scan_root("../../lygia") - .expect("failed to scan Lygia WESL files"); - wesl_only(&mut lygia.root, Path::new("../../lygia")); - lygia.root.submodules.retain(|sub| sub.name != "test"); - lygia - .build_artifact() - .expect("failed to build Lygia package artifact"); +// A package is a directory of modules; its root module is the `.wesl` file beside it. +fn package(code: &mut String, table_name: &str, name: &str, dir: &Path) { + println!("cargo::rerun-if-changed={}", dir.display()); + let mut modules = Vec::new(); + let root = dir.with_extension("wesl"); + if root.is_file() { + println!("cargo::rerun-if-changed={}", root.display()); + modules.push((name.to_string(), "package.wesl".to_string(), root)); + } + walk(dir, name, "", &mut modules); + modules.sort(); + table(code, table_name, modules); } -// lygia's manifest includes `**/*.wesl` only; the scan also picks up its legacy `.wgsl` -fn wesl_only(module: &mut wesl::Module, path: &Path) { - if !path.with_extension("wesl").is_file() { - module.source.clear(); +fn table(code: &mut String, table: &str, modules: Vec<(String, String, std::path::PathBuf)>) { + writeln!(code, "pub static {table}: &[ShaderModule] = &[").unwrap(); + for (path, file, source) in modules { + let source = std::fs::canonicalize(source).unwrap(); + writeln!( + code, + " ShaderModule {{ path: {path:?}, file: {file:?}, source: include_str!({source:?}) }}," + ) + .unwrap(); } - for sub in &mut module.submodules { - wesl_only(sub, &path.join(&sub.name)); + writeln!(code, "];").unwrap(); +} + +fn walk( + dir: &Path, + module: &str, + file: &str, + modules: &mut Vec<(String, String, std::path::PathBuf)>, +) { + for entry in std::fs::read_dir(dir).unwrap().flatten() { + let path = entry.path(); + let Some(stem) = path.file_stem().and_then(|stem| stem.to_str()) else { + continue; + }; + // a module name has to be an identifier + let ident = stem.chars().all(|c| c.is_ascii_alphanumeric() || c == '_') + && !stem.starts_with(|c: char| c.is_ascii_digit()); + if !ident { + continue; + } + if path.is_dir() { + // lygia's own tests are not part of the package + if module == "lygia" && stem == "test" { + continue; + } + walk( + &path, + &format!("{module}::{stem}"), + &format!("{file}{stem}/"), + modules, + ); + } else if path.extension().is_some_and(|ext| ext == "wesl") { + modules.push(( + format!("{module}::{stem}"), + format!("{file}{stem}.wesl"), + path, + )); + } } - module - .submodules - .retain(|sub| !sub.source.is_empty() || !sub.submodules.is_empty()); } diff --git a/crates/processing_render/shaders/processing.wesl b/crates/processing_render/shaders/processing.wesl index 04ba620a..0039011d 100644 --- a/crates/processing_render/shaders/processing.wesl +++ b/crates/processing_render/shaders/processing.wesl @@ -4,12 +4,7 @@ struct Globals { frame_count: u32, } -@group(0) @binding(11) var globals: Globals; +@group(0) @binding(8) var globals: Globals; -struct VertexOutput { - @builtin(position) position: vec4, - @location(0) world_position: vec4, - @location(1) world_normal: vec3, - @location(2) uv: vec2, - @location(5) color: vec4, -} +// what a custom fragment stage receives: `world_position`, `world_normal`, `uv`, `color` +alias VertexOutput = bevy_pbr::render::forward_io::VertexOutput; diff --git a/crates/processing_render/shaders/processing/mesh.wesl b/crates/processing_render/shaders/processing/mesh.wesl index 72bf2275..67d634e6 100644 --- a/crates/processing_render/shaders/processing/mesh.wesl +++ b/crates/processing_render/shaders/processing/mesh.wesl @@ -1,62 +1,106 @@ -// what a custom vertex stage needs from the mesh; the layouts mirror bevy_pbr's -import package::VertexOutput; +// The vertex stage every mesh draw runs, in pieces a custom vertex shader can reuse: +// +// @vertex +// fn vertex(vertex_in: Vertex) -> VertexOutput { +// var vertex = vertex_input(vertex_in); +// vertex.position.y += 1.0; +// return vertex_output(vertex); +// } +import bevy_pbr::render::{ + mesh_bindings::mesh, + mesh_functions, + mesh_types::MESH_FLAGS_SKIN_INSTANCE_COMPOSE_BIT, + skinning, + morph::{morph_position, morph_normal, morph_tangent}, + forward_io, + view_transformations::position_world_to_clip, +}; +// a vertex as the stage works on it: `position`, `normal`, `uv`, `color` +alias MeshVertex = forward_io::UncompressedVertex; +alias VertexOutput = forward_io::VertexOutput; + +// a vertex as the mesh stores it: forward_io's Vertex, without the attributes a mesh lacks struct Vertex { @builtin(instance_index) instance_index: u32, + @if(VERTEX_POSITIONS && VERTEX_POSITIONS_COMPRESSED) + @location(0) compressed_position: vec4, + @if(VERTEX_POSITIONS && !VERTEX_POSITIONS_COMPRESSED) @location(0) position: vec3, + @if(VERTEX_NORMALS && VERTEX_NORMALS_COMPRESSED) + @location(1) compressed_normal: vec2, + @if(VERTEX_NORMALS && !VERTEX_NORMALS_COMPRESSED) @location(1) normal: vec3, + @if(VERTEX_UVS_A && VERTEX_UVS_A_COMPRESSED && !MESH_UVS_MISSING) + @location(2) compressed_uv: vec2, + @if(VERTEX_UVS_A && !VERTEX_UVS_A_COMPRESSED && !MESH_UVS_MISSING) @location(2) uv: vec2, + @if(VERTEX_UVS_B && VERTEX_UVS_B_COMPRESSED) + @location(3) compressed_uv_b: vec2, + @if(VERTEX_UVS_B && !VERTEX_UVS_B_COMPRESSED) + @location(3) uv_b: vec2, + @if(VERTEX_TANGENTS && VERTEX_TANGENTS_COMPRESSED) + @location(4) compressed_tangent: vec2, + @if(VERTEX_TANGENTS && !VERTEX_TANGENTS_COMPRESSED) + @location(4) tangent: vec4, + @if(VERTEX_COLORS && !MESH_COLORS_MISSING) @location(5) color: vec4, -} + @if(SKINNED) + @location(6) joint_indices: vec4, + @if(SKINNED) + @location(7) joint_weights: vec4, + @if(MORPH_TARGETS) + @builtin(vertex_index) index: u32, +}; -// the leading field of bevy_render::view::View -struct View { - clip_from_world: mat4x4, +// forward_io's decompress_vertex, for the `Vertex` above +fn decompress_vertex(vertex_in: Vertex, instance_index: u32) -> MeshVertex { + let mesh_metadata = mesh_functions::get_metadata(instance_index); + var uncompressed_vertex: MeshVertex; + uncompressed_vertex.instance_index = instance_index; +@if(VERTEX_POSITIONS && VERTEX_POSITIONS_COMPRESSED) + uncompressed_vertex.position = bevy_render::utils::decompress_vertex_position(vertex_in.compressed_position, mesh_metadata.aabb_center, mesh_metadata.aabb_half_extents); +@if(VERTEX_POSITIONS && !VERTEX_POSITIONS_COMPRESSED) + uncompressed_vertex.position = vertex_in.position; +@if(VERTEX_NORMALS && VERTEX_NORMALS_COMPRESSED) + uncompressed_vertex.normal = bevy_render::utils::decompress_vertex_normal(vertex_in.compressed_normal); +@if(VERTEX_NORMALS && !VERTEX_NORMALS_COMPRESSED) + uncompressed_vertex.normal = vertex_in.normal; +@if(VERTEX_UVS_A && MESH_UVS_MISSING) + uncompressed_vertex.uv = vec2(0.0); +@if(VERTEX_UVS_A && VERTEX_UVS_A_COMPRESSED && !MESH_UVS_MISSING) { + let uv_min_and_extents_a = mesh_metadata.uv_channels_min_and_extents[0]; + uncompressed_vertex.uv = bevy_render::utils::decompress_vertex_uv(vertex_in.compressed_uv, uv_min_and_extents_a); } - -@group(0) @binding(0) var view: View; - -// bevy_pbr::mesh_types::Mesh -struct Mesh { - world_from_local: mat3x4, - previous_world_from_local: mat3x4, - local_from_world_transpose_a: mat2x4, - local_from_world_transpose_b: f32, - flags: u32, - lightmap_uv_rect: vec2, - first_vertex_index: u32, - current_skin_index: u32, - material_and_lightmap_bind_group_slot: u32, - tag: u32, - morph_descriptor_index: u32, +@if(VERTEX_UVS_A && !VERTEX_UVS_A_COMPRESSED && !MESH_UVS_MISSING) + uncompressed_vertex.uv = vertex_in.uv; +@if(VERTEX_UVS_B && VERTEX_UVS_B_COMPRESSED) { + let uv_min_and_extents_b = mesh_metadata.uv_channels_min_and_extents[1]; + uncompressed_vertex.uv_b = bevy_render::utils::decompress_vertex_uv(vertex_in.compressed_uv_b, uv_min_and_extents_b); } - -@group(2) @binding(0) var mesh: array; - -fn world_from_local(instance_index: u32) -> mat4x4 { - let m = transpose(mesh[instance_index].world_from_local); - return mat4x4(vec4(m[0], 0.0), vec4(m[1], 0.0), vec4(m[2], 0.0), vec4(m[3], 1.0)); +@if(VERTEX_UVS_B && !VERTEX_UVS_B_COMPRESSED) + uncompressed_vertex.uv_b = vertex_in.uv_b; +@if(VERTEX_TANGENTS && VERTEX_TANGENTS_COMPRESSED) + uncompressed_vertex.tangent = bevy_render::utils::decompress_vertex_tangent(vertex_in.compressed_tangent); +@if(VERTEX_TANGENTS && !VERTEX_TANGENTS_COMPRESSED) + uncompressed_vertex.tangent = vertex_in.tangent; +@if(VERTEX_COLORS && MESH_COLORS_MISSING) + uncompressed_vertex.color = vec4(1.0); +@if(VERTEX_COLORS && !MESH_COLORS_MISSING) + uncompressed_vertex.color = vertex_in.color; +@if(SKINNED) { + uncompressed_vertex.joint_indices = vertex_in.joint_indices; + uncompressed_vertex.joint_weights = vertex_in.joint_weights; } - -fn world_normal(normal: vec3, instance_index: u32) -> vec3 { - let a = mesh[instance_index].local_from_world_transpose_a; - let b = mesh[instance_index].local_from_world_transpose_b; - let m = mat3x3(a[0].xyz, vec3(a[0].w, a[1].xy), vec3(a[1].zw, b)); - // a zero normal stays zero instead of becoming NaN - if all(normal == vec3(0.0)) { - return normal; - } - return normalize(m * normal); +@if(MORPH_TARGETS) + uncompressed_vertex.index = vertex_in.index; + return uncompressed_vertex; } -fn clip_from_world(world_position: vec3) -> vec4 { - return view.clip_from_world * vec4(world_position, 1.0); -} - -// the fill of this instance, linear rgba -@if(tag_is_fill) +// the fill of this instance, linear rgba; r is in the low byte of the tag +@if(INSTANCE_FILL) fn instance_fill(instance_index: u32) -> vec4 { - let tag = mesh[instance_index].tag; + let tag = mesh_functions::get_tag(instance_index); let srgb = vec4( f32(tag & 0xffu), f32((tag >> 8u) & 0xffu), @@ -72,23 +116,103 @@ fn instance_fill(instance_index: u32) -> vec4 { } // a particle's tag is its index, not a fill -@if(!tag_is_fill) +@else fn instance_fill(instance_index: u32) -> vec4 { return vec4(1.0); } // the color a vertex is drawn in: its own color times the fill -fn fill_color(vertex: Vertex) -> vec4 { +@if(VERTEX_COLORS) +fn fill_color(vertex: MeshVertex) -> vec4 { return vertex.color * instance_fill(vertex.instance_index); } -// the `VertexOutput` of an untouched `vertex` -fn vertex_output(vertex: Vertex) -> VertexOutput { +@if(MORPH_TARGETS) +/// The instance_index parameter must match vertex_in.instance_index. This is a work around for a wgpu dx12 bug. +/// See https://github.com/gfx-rs/naga/issues/2416 +fn morph_vertex(vertex_in: MeshVertex, instance_index: u32) -> MeshVertex { + var vertex = vertex_in; + let first_vertex = mesh[instance_index].first_vertex_index; + let vertex_index = vertex.index - first_vertex; + let morph_descriptor_index = mesh[instance_index].morph_descriptor_index; + + let weight_count = bevy_pbr::render::morph::layer_count(morph_descriptor_index); + for (var i: u32 = 0u; i < weight_count; i ++) { + let weight = bevy_pbr::render::morph::weight_at(i, morph_descriptor_index); + if weight == 0.0 { + continue; + } + vertex.position += weight * morph_position(vertex_index, i, morph_descriptor_index); + @if(VERTEX_NORMALS) + vertex.normal += weight * morph_normal(vertex_index, i, morph_descriptor_index); + @if(VERTEX_TANGENTS) + vertex.tangent += vec4(weight * morph_tangent(vertex_index, i, morph_descriptor_index), 0.0); + } + return vertex; +} + +// the vertex ready to be changed: decompressed, with its morph targets applied +fn vertex_input(vertex_in: Vertex) -> MeshVertex { + let vertex = decompress_vertex(vertex_in, vertex_in.instance_index); +@if(MORPH_TARGETS) + return morph_vertex(vertex, vertex_in.instance_index); +@else + return vertex; +} + +// what the fragment stage receives for `vertex` +fn vertex_output(vertex: MeshVertex) -> VertexOutput { var out: VertexOutput; - out.world_position = world_from_local(vertex.instance_index) * vec4(vertex.position, 1.0); - out.position = clip_from_world(out.world_position.xyz); - out.world_normal = world_normal(vertex.normal, vertex.instance_index); + + let mesh_world_from_local = mesh_functions::get_world_from_local(vertex.instance_index); + +@if(SKINNED) + var world_from_local = skinning::skin_model( + vertex.joint_indices, + vertex.joint_weights, + vertex.instance_index + ); +@else + var world_from_local = mesh_world_from_local; +@if(SKINNED) + if (mesh[vertex.instance_index].flags & MESH_FLAGS_SKIN_INSTANCE_COMPOSE_BIT) != 0u { + world_from_local = mesh_world_from_local * world_from_local; + } + +@if(VERTEX_NORMALS && SKINNED) + out.world_normal = skinning::skin_normals(world_from_local, vertex.normal); +@if(VERTEX_NORMALS && !SKINNED) + out.world_normal = mesh_functions::mesh_normal_local_to_world( + vertex.normal, + vertex.instance_index + ); + +@if(VERTEX_POSITIONS) + out.world_position = mesh_functions::mesh_position_local_to_world(world_from_local, vec4(vertex.position, 1.0)); +@if(VERTEX_POSITIONS) + out.position = position_world_to_clip(out.world_position.xyz); + +@if(VERTEX_UVS_A) out.uv = vertex.uv; +@if(VERTEX_UVS_B) + out.uv_b = vertex.uv_b; + +@if(VERTEX_TANGENTS) + out.world_tangent = mesh_functions::mesh_tangent_local_to_world( + world_from_local, + vertex.tangent, + vertex.instance_index + ); + +@if(VERTEX_COLORS) out.color = fill_color(vertex); + +@if(VERTEX_OUTPUT_INSTANCE_INDEX) + out.instance_index = vertex.instance_index; + +@if(VISIBILITY_RANGE_DITHER) + out.visibility_range_dither = mesh_functions::get_visibility_range_dither_level( + vertex.instance_index, mesh_world_from_local[3]); + return out; } diff --git a/crates/processing_render/src/compute.rs b/crates/processing_render/src/compute.rs index ff7b2790..ab200d29 100644 --- a/crates/processing_render/src/compute.rs +++ b/crates/processing_render/src/compute.rs @@ -15,7 +15,7 @@ use bevy::{ PipelineCache, PollType, }, renderer::{RenderDevice, RenderQueue}, - storage::{GpuShaderBuffer, ShaderBuffer}, + storage::{GpuShaderBuffer, ShaderBuffer, ShaderBufferData}, texture::GpuImage, }, }; @@ -60,7 +60,7 @@ pub fn create_buffer( render_device: Res, ) -> Entity { let handle = buffers.add(ShaderBuffer::new( - &vec![0u8; size as usize], + vec![0u8; size as usize], RenderAssetUsages::all(), )); commands @@ -80,8 +80,8 @@ pub fn create_buffer_with_usage( mut buffers: ResMut>, render_device: Res, ) -> Entity { - let mut shader_buffer = ShaderBuffer::new(&vec![0u8; size as usize], RenderAssetUsages::all()); - shader_buffer.buffer_description.usage |= extra_usage; + let mut shader_buffer = ShaderBuffer::new(vec![0u8; size as usize], RenderAssetUsages::all()); + shader_buffer.buffer_usage |= extra_usage; let handle = buffers.add(shader_buffer); commands .spawn(Buffer { @@ -101,7 +101,7 @@ pub fn create_buffer_with_data( render_device: Res, ) -> Entity { let size = data.len() as u64; - let handle = buffers.add(ShaderBuffer::new(&data, RenderAssetUsages::all())); + let handle = buffers.add(ShaderBuffer::new(data, RenderAssetUsages::all())); commands .spawn(Buffer { handle, @@ -143,8 +143,19 @@ pub fn write_buffer_asset( patched.ok_or(ProcessingError::BufferNotFound)? } +/// The CPU copy of a buffer's contents, if it has one. +pub fn shader_buffer_bytes(asset: &ShaderBuffer) -> Option<&[u8]> { + match &asset.data { + ShaderBufferData::Initialized { data, .. } => Some(data.as_slice()), + ShaderBufferData::Uninitialized(_) => None, + } +} + fn patch_asset(asset: &mut ShaderBuffer, offset: u64, data: &[u8]) -> Result<()> { - let dst = asset.data.as_mut().ok_or(ProcessingError::BufferNotFound)?; + let ShaderBufferData::Initialized { data: dst, .. } = &mut asset.data else { + return Err(ProcessingError::BufferNotFound); + }; + let dst = dst.as_mut_slice(); let start = offset as usize; dst[start..start + data.len()].copy_from_slice(data); Ok(()) @@ -179,7 +190,10 @@ pub fn read_buffer_gpu( .map_err(|e| ProcessingError::BufferMapError(format!("map channel closed: {e}")))? .map_err(|e| ProcessingError::BufferMapError(format!("map failed: {e}")))?; - let bytes = buffer_slice.get_mapped_range().to_vec(); + let bytes = buffer_slice + .get_mapped_range() + .map_err(|e| ProcessingError::BufferMapError(format!("map range failed: {e}")))? + .to_vec(); readback_buffer.unmap(); Ok(bytes) } @@ -305,6 +319,7 @@ pub fn create_compute(app: &mut App, shader_entity: Entity) -> Result { shader: shader_handle.clone(), shader_defs: Vec::new(), entry_point: Some(entry_point.clone().into()), + constants: Vec::new(), zero_initialize_workgroup_memory: true, }; diff --git a/crates/processing_render/src/graphics.rs b/crates/processing_render/src/graphics.rs index fb27d8be..6e40c271 100644 --- a/crates/processing_render/src/graphics.rs +++ b/crates/processing_render/src/graphics.rs @@ -188,7 +188,7 @@ impl CameraProjection for ProcessingProjection { fn get_clip_from_view(&self) -> Mat4 { // far/near swapped for reverse-z, which the depth compare (GreaterEqual) assumes Y_FLIP - * Mat4::orthographic_rh( + * bevy::math::proj::orthographic( self.left, self.right, self.bottom, @@ -1124,7 +1124,10 @@ pub fn readback_raw( r.recv().expect("Failed to receive the map_async message"); - let data = buffer_slice.get_mapped_range().to_vec(); + let data = buffer_slice + .get_mapped_range() + .expect("Failed to get mapped range for readback") + .to_vec(); graphics.readback_buffer.unmap(); diff --git a/crates/processing_render/src/image.rs b/crates/processing_render/src/image.rs index 74a3d847..be7d1ff0 100644 --- a/crates/processing_render/src/image.rs +++ b/crates/processing_render/src/image.rs @@ -46,6 +46,7 @@ impl Plugin for ImagePlugin { /// The image a `background(img)` paints over this camera's target before its next pass #[derive(Component, Clone, Default, ExtractComponent)] +#[extract_app(RenderApp)] pub struct BackgroundBlit(pub Option>); /// `background(img)` applies to one pass only @@ -618,6 +619,7 @@ pub fn readback( let bytes_per_row = p_image.size.width as usize * px_size; let data: Vec = buffer_slice .get_mapped_range() + .expect("Failed to get mapped range for readback") .chunks_exact(padded_bytes_per_row) .take(p_image.size.height as usize) .flat_map(|row| row[..bytes_per_row].iter().copied()) diff --git a/crates/processing_render/src/lib.rs b/crates/processing_render/src/lib.rs index a3c97714..c8b8fc61 100644 --- a/crates/processing_render/src/lib.rs +++ b/crates/processing_render/src/lib.rs @@ -77,7 +77,11 @@ macro_rules! internal_shader { .resource_mut::>() .insert( $handle.id(), - bevy::shader::Shader::from_wgsl(include_str!($path), concat!(file!(), "/", $path)), + bevy::shader::Shader::from_wesl( + include_str!($path), + // named as an embedded asset, so the module resolves as `crate::module::file` + format!("embedded://{}/{}", module_path!().replace("::", "/"), $path), + ), ); }}; } @@ -2514,7 +2518,11 @@ fn ensure_buffer_synced(app: &mut App, entity: Entity) -> error::Result<()> { let asset = buffers .get_mut_untracked(handle.id()) .ok_or(error::ProcessingError::BufferNotFound)?; - asset.data = Some(bytes); + let buffer_size = bytes.len() as u64; + asset.data = bevy::render::storage::ShaderBufferData::Initialized { + data: bytes.into(), + buffer_size, + }; } let mut buf = world @@ -2611,7 +2619,7 @@ fn buffer_read_range(entity: Entity, offset: u64, len: u64) -> error::Result>(); let data = buffers .get(&handle) - .and_then(|a| a.data.as_ref()) + .and_then(compute::shader_buffer_bytes) .ok_or(error::ProcessingError::BufferNotFound)?; Ok(data[offset as usize..(offset + len) as usize].to_vec()) }) diff --git a/crates/processing_render/src/material/custom.rs b/crates/processing_render/src/material/custom.rs index 043b0118..0af1b657 100644 --- a/crates/processing_render/src/material/custom.rs +++ b/crates/processing_render/src/material/custom.rs @@ -4,11 +4,18 @@ use std::collections::HashMap; use std::sync::Arc; use bevy::platform::collections::hash_map::Entry; -use wesl::PkgResolver; use wesl::syntax::{ModulePath, PathOrigin}; -wesl::wesl_pkg!(processing); -wesl::wesl_pkg!(lygia); +/// A module of a built-in WESL package. +pub struct ShaderModule { + /// e.g. `processing::mesh` + pub path: &'static str, + /// its file, relative to the package root + pub file: &'static str, + pub source: &'static str, +} + +include!(concat!(env!("OUT_DIR"), "/shader_modules.rs")); use bevy::{ asset::{AsAssetId, AssetEventSystems}, @@ -26,10 +33,9 @@ use bevy::{ mesh::{MeshVertexAttribute, MeshVertexBufferLayoutRef}, pbr::{ DrawMaterial, EntitiesNeedingSpecialization, MainPassAlphaMaskDrawFunction, - MainPassOpaqueDrawFunction, MainPassTransparentDrawFunction, MaterialBindGroupAllocator, - MaterialBindGroupAllocators, MaterialFragmentShader, MaterialVertexShader, MeshPipelineKey, - PreparedMaterial, RenderMaterialBindings, RenderMaterialInstance, RenderMaterialInstances, - base_specialize, + MainPassOpaqueDrawFunction, MainPassTransparentDrawFunction, MaterialFragmentShader, + MaterialVertexShader, MeshPipelineKey, PreparedMaterial, RenderMaterialInstance, + RenderMaterialInstances, base_specialize, }, prelude::*, reflect::{PartialReflect, ReflectMut, ReflectRef, structs::Struct}, @@ -37,10 +43,14 @@ use bevy::{ Extract, RenderApp, RenderStartup, camera::{DirtySpecializationSystems, DirtySpecializations}, erased_render_asset::{ErasedRenderAsset, ErasedRenderAssetPlugin, PrepareAssetError}, + material_bind_groups::{ + MaterialBindGroupAllocator, MaterialBindGroupAllocators, RenderMaterialBindings, + }, render_asset::RenderAssets, render_phase::DrawFunctions, render_resource::{ - BindGroupLayoutDescriptor, BindingResources, BlendState, Face, UnpreparedBindGroup, + BindGroupBuilder, BindGroupLayoutDescriptor, BlendState, Face, OwnedBindingResource, + UnpreparedBindingResource, }, renderer::RenderDevice, storage::GpuShaderBuffer, @@ -96,19 +106,18 @@ fn specialize( Some(false) => Some(Face::Back), _ => None, }; - if crate::material::uses_processing_vertex(descriptor) { - if key.instance_fill { - descriptor.vertex.shader_defs.push("INSTANCE_FILL".into()); - } - // a fragment stage reads a uv and a color whether or not the mesh has them - if !layout.0.contains(Mesh::ATTRIBUTE_COLOR) { - crate::material::output_missing_colors(descriptor); - } - if !layout.0.contains(Mesh::ATTRIBUTE_UV_0) { - crate::material::output_missing_uvs(descriptor); - } - } else { - // the mesh must have every attribute the vertex stage reads + if key.instance_fill { + descriptor.vertex.shader_defs.push("INSTANCE_FILL".into()); + } + // both stages have a uv and a color whether or not the mesh has them + if !layout.0.contains(Mesh::ATTRIBUTE_COLOR) { + crate::material::output_missing_colors(descriptor); + } + if !layout.0.contains(Mesh::ATTRIBUTE_UV_0) { + crate::material::output_missing_uvs(descriptor); + } + if !crate::material::uses_processing_vertex(descriptor) { + // the mesh must have every attribute the vertex stage cannot do without let read: Vec<_> = vertex_attributes() .into_iter() .enumerate() @@ -123,12 +132,13 @@ fn specialize( #[derive(Asset, TypePath, Clone)] pub struct CustomMaterial { pub shader: DynamicShader, + /// the source, which bevy compiles for each pipeline pub shader_handle: Handle, - /// the shader that reads the mesh tag as a particle index - pub particles_shader_handle: Handle, + /// the shader compiled on its own, which a file reload replaces + pub compiled: AssetId, pub has_vertex: bool, pub has_fragment: bool, - /// the vertex input locations the vertex stage reads, as bits + /// the vertex input locations the vertex stage cannot do without, as bits pub vertex_inputs: u32, pub blend_state: Option, /// no blend mode of its own, so it follows the current one when drawn @@ -227,8 +237,10 @@ impl CustomMaterial { pub struct Shader { pub module: naga::Module, pub shader_handle: Handle, - /// the shader that reads the mesh tag as a particle index - pub particles_handle: Handle, + /// the source, which bevy compiles for each pipeline a material needs + pub material_handle: Handle, + /// the vertex input locations the vertex stage cannot do without, as bits + pub vertex_inputs: u32, } /// A compiled shader and the file it was loaded from, kept so edits to the file reload it. @@ -251,35 +263,75 @@ impl AsAssetId for CustomMaterial3d { } } +/// The module a shader being compiled is. +const ENTRY: &str = "sketch::shader"; + +/// The modules a shader can import, by path (`processing::mesh`). +pub(crate) type ModuleSources = HashMap>; + +/// The built-in packages' modules. +fn package_modules() -> impl Iterator { + PROCESSING.iter().chain(LYGIA) +} + +/// Resolves the shader being compiled, the built-in packages and bevy's own modules. struct ProcessingResolver<'a> { entry_source: &'a str, - pkg_resolver: PkgResolver, + /// bevy's shader modules + engine: &'a ModuleSources, + /// the virtual `constants` module + constants: &'a str, +} + +/// `package::module::item` for a module path, naming the package wesl imported it into. +fn module_name(path: &ModulePath) -> Option { + let PathOrigin::Package(package) = &path.origin else { + return None; + }; + // a cross-package import arrives as a synthetic "parent/child" origin + let package = package.rsplit('/').next().unwrap(); + Some( + std::iter::once(package) + .chain(path.components.iter().map(String::as_str)) + .collect::>() + .join("::"), + ) } impl wesl::Resolver for ProcessingResolver<'_> { fn resolve_source<'a>( &'a self, path: &ModulePath, - ) -> std::result::Result, wesl::ResolveError> { - // check for the entry module first (its parsed path has Package origin) - if path.to_string() == "entry" { + ) -> std::result::Result, wesl::error::ResolveError> { + let not_found = || { + wesl::error::ResolveError::ModuleNotFound( + path.clone(), + format!("unknown module: {path}"), + ) + }; + let name = module_name(path).ok_or_else(not_found)?; + if name == ENTRY { return Ok(Cow::Borrowed(self.entry_source)); } + if name == "constants" { + return Ok(Cow::Borrowed(self.constants)); + } + if let Some(module) = package_modules().find(|module| module.path == name) { + return Ok(Cow::Borrowed(module.source)); + } + self.engine + .get(&name) + .map(|source| Cow::Borrowed(source.as_ref())) + .ok_or_else(not_found) + } + fn canonical_path(&self, path: &ModulePath) -> ModulePath { match &path.origin { - PathOrigin::Package(pkg) => { - // wesl encodes a cross-package import as a synthetic "parent/child" - // origin (e.g. importing processing from the entry module yields - // "entry/processing"). The real package is the leaf. - let leaf = pkg.rsplit('/').next().unwrap(); - let mut fixed = path.clone(); - fixed.origin = PathOrigin::Package(leaf.to_string()); - self.pkg_resolver.resolve_source(&fixed) - } - _ => Err(wesl::ResolveError::ModuleNotFound( - path.clone(), - format!("unknown module: {}", path), - )), + PathOrigin::Package(package) if package.contains('/') => ModulePath { + origin: PathOrigin::Package(package.rsplit('/').next().unwrap().to_string()), + components: path.components.clone(), + }, + _ => path.clone(), } } } @@ -291,75 +343,100 @@ const PACKAGE_MANIFEST: &str = "edition = \"2026_pre\"\nroot = \".\"\n"; pub struct ShaderPackage { pub name: &'static str, /// `(path relative to the package root, contents)` - pub files: Vec<(String, &'static str)>, + pub files: Vec<(String, Cow<'static, str>)>, } -fn package_files(pkg: &'static wesl::CodegenPkg, extra: &[(&str, &'static str)]) -> ShaderPackage { - fn walk( - module: &'static wesl::CodegenModule, - dir: &str, - files: &mut Vec<(String, &'static str)>, - ) { - for sub in module.submodules { - // a directory module has no source of its own - if !sub.source.is_empty() || sub.submodules.is_empty() { - files.push((format!("{dir}{}.wesl", sub.name), sub.source)); - } - walk(sub, &format!("{dir}{}/", sub.name), files); - } - } - let mut files = vec![ - ("wesl.toml".to_string(), PACKAGE_MANIFEST), - ("package.wesl".to_string(), pkg.root.source), - ]; - files.extend( - extra - .iter() - .map(|(path, contents)| (path.to_string(), *contents)), - ); - walk(pkg.root, "", &mut files); - ShaderPackage { - name: pkg.root.name, - files, - } +/// The package a module belongs to. +fn package_of(module: &ShaderModule) -> &'static str { + module.path.split("::").next().unwrap() } -/// The WESL packages every shader can import, exactly as the runtime resolves them. +/// The WESL packages every shader can import, exactly as the runtime resolves them: ours, +/// and the bevy ones ours import. pub fn shader_packages() -> Vec { - vec![ - package_files(&processing::PACKAGE, &[]), - package_files( - &lygia::PACKAGE, - &[("LICENSE.md", include_str!("../../../../lygia/LICENSE.md"))], - ), - ] + let modules = || package_modules().chain(ENGINE); + let mut names: Vec<&'static str> = Vec::new(); + for module in modules() { + if !names.contains(&package_of(module)) { + names.push(package_of(module)); + } + } + names + .iter() + .map(|&name| { + let own = || modules().filter(move |module| package_of(module) == name); + // the sibling packages this one imports + let dependencies: String = names + .iter() + .filter(|&&other| { + other != name && own().any(|m| m.source.contains(&format!("{other}::"))) + }) + .map(|other| format!("{other} = {{ path = \"../{other}\" }}\n")) + .collect(); + let mut manifest = PACKAGE_MANIFEST.to_string(); + if !dependencies.is_empty() { + manifest += "\n[dependencies]\n"; + manifest += &dependencies; + } + let mut files = vec![("wesl.toml".to_string(), Cow::Owned(manifest))]; + // a package with no root module still has the file + if own().all(|module| module.file != "package.wesl") { + files.push(("package.wesl".to_string(), Cow::Borrowed(""))); + } + if name == "lygia" { + let license = include_str!("../../../../lygia/LICENSE.md"); + files.push(("LICENSE.md".to_string(), Cow::Borrowed(license))); + } + files.extend(own().map(|m| (m.file.to_string(), Cow::Borrowed(m.source)))); + ShaderPackage { name, files } + }) + .collect() } +/// The shader defs a mesh draw has, for compiling a shader outside a pipeline. +const MESH_FEATURES: [&str; 7] = [ + "VERTEX_POSITIONS", + "VERTEX_NORMALS", + "VERTEX_UVS", + "VERTEX_UVS_A", + "VERTEX_COLORS", + "VERTEX_OUTPUT_INSTANCE_INDEX", + "INSTANCE_FILL", +]; + +/// Compiles a shader to WGSL on its own, as its uniforms are reflected from. pub(crate) fn compile_shader_with_features( source: &str, features: &[(&str, bool)], + engine: &ModuleSources, ) -> Result<(String, naga::Module)> { - let mut pkg_resolver = PkgResolver::new(); - pkg_resolver.add_package(&processing::PACKAGE); - pkg_resolver.add_package(&lygia::PACKAGE); - let resolver = ProcessingResolver { entry_source: source, - pkg_resolver, + engine, + constants: "const MATERIAL_BIND_GROUP = 3;\n", }; - let module_path: ModulePath = "entry".parse().unwrap(); + let (package, module) = ENTRY.split_once("::").unwrap(); + let module_path = ModulePath::new( + PathOrigin::Package(package.to_string()), + vec![module.to_string()], + ); let mut options = wesl::CompileOptions { - imports: true, - strip: false, + // only what the shader reaches is loaded, but its own uniforms are all kept + strip: true, + keep_main: true, + // naga validates the result + validate: false, + visibility: false, ..Default::default() }; - for (name, enabled) in [(TAG_IS_FILL, true)].iter().chain(features) { + let defaults = MESH_FEATURES.iter().map(|name| (*name, true)); + for (name, enabled) in defaults.chain(features.iter().copied()) { options .features .flags - .insert((*name).to_string(), (*enabled).into()); + .insert(name.to_string(), enabled.into()); } - let compiled = wesl::compile(&module_path, &resolver, &wesl::EscapeMangler, &options) + let compiled = wesl::compile(&module_path, &options, &resolver) .map_err(|e| ProcessingError::ShaderCompilationError(e.to_string()))?; let wgsl = compiled.to_string(); let module = naga::front::wgsl::parse_str(&wgsl) @@ -367,46 +444,92 @@ pub(crate) fn compile_shader_with_features( Ok((wgsl, module)) } -/// The feature `processing::mesh` reads the mesh tag as a fill under. -const TAG_IS_FILL: &str = "tag_is_fill"; +/// The modules bevy has registered, for compiling a shader outside a pipeline. +pub(crate) fn engine_modules(shaders: &Assets) -> ModuleSources { + shaders + .iter() + .filter_map(|(_, shader)| match (&shader.import_path, &shader.source) { + (bevy::shader::ShaderImport::Custom(name), bevy::shader::Source::Wesl(source)) => { + Some((name.clone(), source.clone())) + } + _ => None, + }) + .collect() +} + +/// Registers the built-in packages with bevy, so any shader it compiles can import them. +fn register_packages(shaders: &mut Assets) -> Vec> { + package_modules() + .map(|module| { + // an embedded path makes the module importable as `package::module` + let path = format!("embedded://{}.wesl", module.path.replace("::", "/")); + shaders.add(ShaderAsset::from_wesl(module.source, path)) + }) + .collect() +} -/// A compiled shader, and the variant for particles when it differs. +/// Keeps the built-in packages registered. +#[derive(Resource)] +struct PackageShaders( + #[expect(dead_code, reason = "held to keep the assets alive")] Vec>, +); + +/// A shader compiled on its own, with the source bevy compiles per pipeline. struct Compiled { + source: String, + features: Vec<(String, bool)>, wgsl: String, module: naga::Module, - particles_wgsl: Option, + vertex_inputs: u32, } +/// The features a mesh with no uv or color attribute is drawn under. +const MISSING_FEATURES: [(&str, bool); 2] = + [("MESH_UVS_MISSING", true), ("MESH_COLORS_MISSING", true)]; + impl Compiled { - fn new(source: &str, features: &[(&str, bool)]) -> Result { - let (wgsl, module) = compile_shader_with_features(source, features)?; + fn new(source: &str, features: &[(&str, bool)], shaders: &Assets) -> Result { + let engine = engine_modules(shaders); + let (wgsl, module) = compile_shader_with_features(source, features, &engine)?; check_stages(&module)?; - // only a vertex stage can read the tag - let particles_wgsl = if has_stage(&module, naga::ShaderStage::Vertex) { - let mut features = features.to_vec(); - features.push((TAG_IS_FILL, false)); - let (particles_wgsl, _) = compile_shader_with_features(source, &features)?; - (particles_wgsl != wgsl).then_some(particles_wgsl) + // what the vertex stage still reads when `processing::mesh` defaults all it can + let vertex_inputs = if has_stage(&module, naga::ShaderStage::Vertex) { + let features: Vec<_> = features.iter().copied().chain(MISSING_FEATURES).collect(); + let (_, module) = compile_shader_with_features(source, &features, &engine)?; + stage_locations(&module, naga::ShaderStage::Vertex, false) } else { - None + 0 }; Ok(Self { + vertex_inputs, + source: source.to_string(), + features: features + .iter() + .map(|(name, enabled)| (name.to_string(), *enabled)) + .collect(), wgsl, module, - particles_wgsl, }) } fn add(self, shaders: &mut Assets) -> Shader { let shader_handle = shaders.add(ShaderAsset::from_wgsl(self.wgsl, "custom_material")); - let particles_handle = match self.particles_wgsl { - Some(wgsl) => shaders.add(ShaderAsset::from_wgsl(wgsl, "custom_material")), - None => shader_handle.clone(), + // a module of its own, named after the asset + let AssetId::Index { index, .. } = shader_handle.id() else { + unreachable!("an added asset has an index id"); }; + let path = format!("embedded://sketch/shader_{}.wesl", index.to_bits()); + let mut material = ShaderAsset::from_wesl(self.source, path); + material.shader_defs = self + .features + .into_iter() + .map(|(name, enabled)| bevy::shader::ShaderDefVal::Bool(name.into(), enabled)) + .collect(); Shader { module: self.module, shader_handle, - particles_handle, + material_handle: shaders.add(material), + vertex_inputs: self.vertex_inputs, } } } @@ -462,7 +585,7 @@ pub fn create_shader( mut commands: Commands, mut shaders: ResMut>, ) -> Result { - let shader = Compiled::new(&source, &[])?.add(&mut shaders); + let shader = Compiled::new(&source, &[], &shaders)?.add(&mut shaders); Ok(commands.spawn(shader).id()) } @@ -472,7 +595,7 @@ pub fn create_shader_with_features( mut shaders: ResMut>, ) -> Result { let feats: Vec<(&str, bool)> = features.iter().map(|(k, v)| (k.as_str(), *v)).collect(); - let shader = Compiled::new(&source, &feats)?.add(&mut shaders); + let shader = Compiled::new(&source, &feats, &shaders)?.add(&mut shaders); Ok(commands.spawn(shader).id()) } @@ -505,7 +628,8 @@ pub fn load_shader(In(path): In, world: &mut World) -> Result { } let source = shader_file_source(world.resource::>(), handle.id())?; - let shader = Compiled::new(&source, &[])?.add(&mut world.resource_mut::>()); + let mut shaders = world.resource_mut::>(); + let shader = Compiled::new(&source, &[], &shaders)?.add(&mut shaders); world .get_resource_or_insert_with(ShaderFiles::default) @@ -557,7 +681,7 @@ fn reload_shaders( if source == entry.source { continue; } - let compiled = Compiled::new(&source, &[]); + let compiled = Compiled::new(&source, &[], &shaders); entry.source = source; let compiled = match compiled { Ok(compiled) => compiled, @@ -571,19 +695,21 @@ fn reload_shaders( // bindings would otherwise be recompiled against the new shader let new = compiled.add(&mut shaders); let module = new.module.clone(); - let old = std::mem::replace(&mut entry.compiled, new.shader_handle.id()); + let compiled = new.shader_handle.id(); + let old = std::mem::replace(&mut entry.compiled, compiled); for mut program in &mut programs { if program.shader_handle.id() == old { program.module = module.clone(); program.shader_handle = new.shader_handle.clone(); - program.particles_handle = new.particles_handle.clone(); + program.material_handle = new.material_handle.clone(); + program.vertex_inputs = new.vertex_inputs; } } let using: Vec<_> = materials .iter() - .filter(|(_, m)| m.shader_handle.id() == old) + .filter(|(_, m)| m.compiled == old) .map(|(id, _)| id) .collect(); for material_id in using { @@ -604,11 +730,11 @@ fn reload_shaders( } } material.shader = shader; - material.shader_handle = new.shader_handle.clone(); - material.particles_shader_handle = new.particles_handle.clone(); + material.shader_handle = new.material_handle.clone(); + material.compiled = compiled; material.has_vertex = has_stage(&module, naga::ShaderStage::Vertex); material.has_fragment = has_stage(&module, naga::ShaderStage::Fragment); - material.vertex_inputs = stage_locations(&module, naga::ShaderStage::Vertex, false); + material.vertex_inputs = new.vertex_inputs; } } } @@ -654,11 +780,11 @@ pub fn create_custom( let material = CustomMaterial { shader, - shader_handle: program.shader_handle.clone(), - particles_shader_handle: program.particles_handle.clone(), + shader_handle: program.material_handle.clone(), + compiled: program.shader_handle.id(), has_vertex, has_fragment, - vertex_inputs: stage_locations(&program.module, naga::ShaderStage::Vertex, false), + vertex_inputs: program.vertex_inputs, blend_state: None, inherit_blend: true, mask: None, @@ -910,6 +1036,9 @@ pub struct CustomMaterialPlugin; impl Plugin for CustomMaterialPlugin { fn build(&self, app: &mut App) { + let packages = + register_packages(&mut app.world_mut().resource_mut::>()); + app.insert_resource(PackageShaders(packages)); app.init_asset::() .add_plugins(ErasedRenderAssetPlugin::::default()) .init_resource::() @@ -1005,9 +1134,27 @@ impl ErasedRenderAsset for CustomMaterial { gpu_buffers, ); - let unprepared = UnpreparedBindGroup { - bindings: BindingResources(bindings), - }; + let mut unprepared = BindGroupBuilder::default(); + for (index, resource) in bindings { + let resource = match resource { + OwnedBindingResource::Buffer(buffer) => UnpreparedBindingResource::Buffer(buffer), + OwnedBindingResource::ShaderBuffer(handle) => { + UnpreparedBindingResource::ShaderBuffer(handle) + } + OwnedBindingResource::TextureView(dimension, view) => { + UnpreparedBindingResource::TextureView(dimension, view) + } + OwnedBindingResource::Sampler(kind, sampler) => { + UnpreparedBindingResource::Sampler(kind, sampler) + } + OwnedBindingResource::Data(data) => { + let start = unprepared.data_buffer.len() as u32; + unprepared.data_buffer.extend_from_slice(&data.0); + UnpreparedBindingResource::Data(start..unprepared.data_buffer.len() as u32) + } + }; + unprepared.binding_resources.push((index, resource)); + } let bind_group_allocator = bind_group_allocators .get_mut(&TypeId::of::()) @@ -1017,12 +1164,13 @@ impl ErasedRenderAsset for CustomMaterial { Entry::Occupied(mut occupied_entry) => { bind_group_allocator.free(*occupied_entry.get()); let new_binding = - bind_group_allocator.allocate_unprepared(unprepared, &bind_group_layout); + bind_group_allocator.allocate_unprepared(&mut unprepared, &bind_group_layout); *occupied_entry.get_mut() = new_binding; new_binding } - Entry::Vacant(vacant_entry) => *vacant_entry - .insert(bind_group_allocator.allocate_unprepared(unprepared, &bind_group_layout)), + Entry::Vacant(vacant_entry) => *vacant_entry.insert( + bind_group_allocator.allocate_unprepared(&mut unprepared, &bind_group_layout), + ), }; // a draw function id only means something in its own phase @@ -1031,11 +1179,7 @@ impl ErasedRenderAsset for CustomMaterial { let transparent_draw = transparent_draw_functions.read().id::(); let blend_state = source_asset.blend_state; - let shader_handle = if source_asset.instance_fill { - &source_asset.shader_handle - } else { - &source_asset.particles_shader_handle - }; + let shader_handle = &source_asset.shader_handle; // A custom blend forces the sorted transparent phase (an arbitrary // blend equation can't be assumed commutative); otherwise honor the // explicitly-set alpha mode. @@ -1186,13 +1330,13 @@ mod tests { "; fn material() -> CustomMaterial { - let (_, module) = compile_shader_with_features(SOURCE, &[]).unwrap(); + let (_, module) = compile_shader_with_features(SOURCE, &[], &ModuleSources::new()).unwrap(); let mut shader = DynamicShader::new(module).unwrap(); init_material_fields(&mut shader); CustomMaterial { shader, shader_handle: Handle::default(), - particles_shader_handle: Handle::default(), + compiled: AssetId::default(), has_vertex: false, has_fragment: true, vertex_inputs: 0, @@ -1211,6 +1355,72 @@ mod tests { instance_fill: false, }; + /// Bevy's modules as shipped to editors, which is all an import can reach. + fn exported_engine() -> ModuleSources { + ENGINE + .iter() + .map(|module| (module.path.to_string(), Cow::Borrowed(module.source))) + .collect() + } + + #[test] + fn the_example_shaders_resolve_against_the_exported_packages() { + let engine = exported_engine(); + for source in [ + include_str!("../../../../assets/shaders/custom_material.wesl"), + include_str!("../../../../assets/shaders/custom_vertex.wesl"), + ] { + let (_, module) = compile_shader_with_features(source, &[], &engine).unwrap(); + assert!(has_stage(&module, naga::ShaderStage::Fragment)); + } + } + + #[test] + fn only_a_hand_declared_vertex_struct_needs_the_color_attribute() { + let engine = exported_engine(); + let needs_color = |source: &str| { + let (_, module) = + compile_shader_with_features(source, &MISSING_FEATURES, &engine).unwrap(); + let inputs = stage_locations(&module, naga::ShaderStage::Vertex, false); + inputs & (1 << COLOR_LOCATION) != 0 + }; + let ours = include_str!("../../../../assets/shaders/custom_vertex.wesl"); + assert!(!needs_color(ours), "`processing::mesh::Vertex` defaults it"); + + let hand_declared = " + import processing::mesh::VertexOutput; + struct MyVertex { + @location(0) position: vec3, + @location(5) color: vec4, + } + @vertex + fn vertex(vertex: MyVertex) -> VertexOutput { + var out: VertexOutput; + out.position = vec4(vertex.position, 1.0); + out.color = vertex.color; + return out; + } + "; + assert!(needs_color(hand_declared)); + } + + #[test] + fn an_exported_package_declares_what_it_imports() { + let packages = shader_packages(); + let manifest = |name: &str| { + let package = packages.iter().find(|p| p.name == name).unwrap(); + let (_, manifest) = package + .files + .iter() + .find(|(f, _)| f == "wesl.toml") + .unwrap(); + manifest.to_string() + }; + assert!(manifest("processing").contains("bevy_pbr = { path = \"../bevy_pbr\" }")); + assert!(manifest("bevy_pbr").contains("bevy_render")); + assert!(!manifest("lygia").contains("[dependencies]")); + } + #[test] fn a_variant_is_reused_until_a_material_changes() { let mut materials = Assets::::default(); diff --git a/crates/processing_render/src/material/fragment.wgsl b/crates/processing_render/src/material/fragment.wesl similarity index 100% rename from crates/processing_render/src/material/fragment.wgsl rename to crates/processing_render/src/material/fragment.wesl diff --git a/crates/processing_render/src/material/mod.rs b/crates/processing_render/src/material/mod.rs index 1f8dbac7..a6908cc2 100644 --- a/crates/processing_render/src/material/mod.rs +++ b/crates/processing_render/src/material/mod.rs @@ -29,8 +29,8 @@ pub struct ProcessingMaterialPlugin; impl Plugin for ProcessingMaterialPlugin { fn build(&self, app: &mut App) { - crate::internal_shader!(app, PROCESSING_VERTEX_SHADER, "vertex.wgsl"); - crate::internal_shader!(app, PROCESSING_FRAGMENT_SHADER, "fragment.wgsl"); + crate::internal_shader!(app, PROCESSING_VERTEX_SHADER, "vertex.wesl"); + crate::internal_shader!(app, PROCESSING_FRAGMENT_SHADER, "fragment.wesl"); app.init_resource::>(); app.add_plugins(bevy::pbr::MaterialPlugin::< ExtendedMaterial, @@ -481,6 +481,11 @@ pub(crate) fn output_missing_uvs(descriptor: &mut RenderPipelineDescriptor) { "VERTEX_UVS_A".into(), "MESH_UVS_MISSING".into(), ]); + if let Some(fragment) = &mut descriptor.fragment { + fragment + .shader_defs + .extend(["VERTEX_UVS".into(), "VERTEX_UVS_A".into()]); + } } /// The projection's y flip (`graphics::Y_FLIP`) mirrors triangle winding, so clockwise is the diff --git a/crates/processing_render/src/material/vertex.wesl b/crates/processing_render/src/material/vertex.wesl new file mode 100644 index 00000000..7a5af3af --- /dev/null +++ b/crates/processing_render/src/material/vertex.wesl @@ -0,0 +1,7 @@ +// the vertex stage of the built-in material, and of a custom material that has none +import processing::mesh::{Vertex, VertexOutput, vertex_input, vertex_output}; + +@vertex +fn vertex(vertex: Vertex) -> VertexOutput { + return vertex_output(vertex_input(vertex)); +} diff --git a/crates/processing_render/src/material/vertex.wgsl b/crates/processing_render/src/material/vertex.wgsl deleted file mode 100644 index 5b3fc976..00000000 --- a/crates/processing_render/src/material/vertex.wgsl +++ /dev/null @@ -1,176 +0,0 @@ -// bevy_pbr's mesh vertex stage, with the per-instance fill multiplied into the vertex color -// and defaults for the uv and color a mesh lacks -#import bevy_pbr::{ - mesh_bindings::mesh, - mesh_functions, - skinning, - morph::{morph_position, morph_normal, morph_tangent}, - forward_io::VertexOutput, - view_transformations::position_world_to_clip, -} - -// forward_io's Vertex, without the attributes a mesh lacks -struct Vertex { - @builtin(instance_index) instance_index: u32, -#ifdef VERTEX_POSITIONS - @location(0) position: vec3, -#endif -#ifdef VERTEX_NORMALS - @location(1) normal: vec3, -#endif -#ifdef VERTEX_UVS_A -#ifndef MESH_UVS_MISSING - @location(2) uv: vec2, -#endif -#endif -#ifdef VERTEX_UVS_B - @location(3) uv_b: vec2, -#endif -#ifdef VERTEX_TANGENTS - @location(4) tangent: vec4, -#endif -#ifdef VERTEX_COLORS -#ifndef MESH_COLORS_MISSING - @location(5) color: vec4, -#endif -#endif -#ifdef SKINNED - @location(6) joint_indices: vec4, - @location(7) joint_weights: vec4, -#endif -#ifdef MORPH_TARGETS - @builtin(vertex_index) index: u32, -#endif -}; - -#ifdef INSTANCE_FILL -// r in the low byte, as `instance_fill` packs it -fn unpack_instance_fill(tag: u32) -> vec4 { - let srgb = vec4( - f32(tag & 0xffu), - f32((tag >> 8u) & 0xffu), - f32((tag >> 16u) & 0xffu), - f32(tag >> 24u), - ) / 255.0; - let linear = select( - pow((srgb.rgb + 0.055) / 1.055, vec3(2.4)), - srgb.rgb / 12.92, - srgb.rgb <= vec3(0.04045), - ); - return vec4(linear, srgb.a); -} -#endif - -#ifdef MORPH_TARGETS -// The instance_index parameter must match vertex_in.instance_index. This is a work around for a wgpu dx12 bug. -// See https://github.com/gfx-rs/naga/issues/2416 -fn morph_vertex(vertex_in: Vertex, instance_index: u32) -> Vertex { - var vertex = vertex_in; - let first_vertex = mesh[instance_index].first_vertex_index; - let vertex_index = vertex.index - first_vertex; - - let weight_count = bevy_pbr::morph::layer_count(instance_index); - for (var i: u32 = 0u; i < weight_count; i ++) { - let weight = bevy_pbr::morph::weight_at(i, instance_index); - if weight == 0.0 { - continue; - } - vertex.position += weight * morph_position(vertex_index, i, instance_index); -#ifdef VERTEX_NORMALS - vertex.normal += weight * morph_normal(vertex_index, i, instance_index); -#endif -#ifdef VERTEX_TANGENTS - vertex.tangent += vec4(weight * morph_tangent(vertex_index, i, instance_index), 0.0); -#endif - } - return vertex; -} -#endif - -@vertex -fn vertex(vertex_no_morph: Vertex) -> VertexOutput { - var out: VertexOutput; - -#ifdef MORPH_TARGETS - var vertex = morph_vertex(vertex_no_morph, vertex_no_morph.instance_index); -#else - var vertex = vertex_no_morph; -#endif - - let mesh_world_from_local = mesh_functions::get_world_from_local(vertex_no_morph.instance_index); - -#ifdef SKINNED - // Use vertex_no_morph.instance_index instead of vertex.instance_index to work around a wgpu dx12 bug. - // See https://github.com/gfx-rs/naga/issues/2416 . - var world_from_local = skinning::skin_model( - vertex.joint_indices, - vertex.joint_weights, - vertex_no_morph.instance_index - ); -#else - var world_from_local = mesh_world_from_local; -#endif - -#ifdef VERTEX_NORMALS -#ifdef SKINNED - out.world_normal = skinning::skin_normals(world_from_local, vertex.normal); -#else - out.world_normal = mesh_functions::mesh_normal_local_to_world( - vertex.normal, - // Use vertex_no_morph.instance_index instead of vertex.instance_index to work around a wgpu dx12 bug. - // See https://github.com/gfx-rs/naga/issues/2416 - vertex_no_morph.instance_index - ); -#endif -#endif - -#ifdef VERTEX_POSITIONS - out.world_position = mesh_functions::mesh_position_local_to_world(world_from_local, vec4(vertex.position, 1.0)); - out.position = position_world_to_clip(out.world_position.xyz); -#endif - -#ifdef VERTEX_UVS_A -#ifdef MESH_UVS_MISSING - out.uv = vec2(0.0); -#else - out.uv = vertex.uv; -#endif -#endif -#ifdef VERTEX_UVS_B - out.uv_b = vertex.uv_b; -#endif - -#ifdef VERTEX_TANGENTS - out.world_tangent = mesh_functions::mesh_tangent_local_to_world( - world_from_local, - vertex.tangent, - // Use vertex_no_morph.instance_index instead of vertex.instance_index to work around a wgpu dx12 bug. - // See https://github.com/gfx-rs/naga/issues/2416 - vertex_no_morph.instance_index - ); -#endif - -#ifdef VERTEX_COLORS -#ifdef MESH_COLORS_MISSING - out.color = vec4(1.0); -#else - out.color = vertex.color; -#endif -#ifdef INSTANCE_FILL - out.color *= unpack_instance_fill(mesh_functions::get_tag(vertex_no_morph.instance_index)); -#endif -#endif - -#ifdef VERTEX_OUTPUT_INSTANCE_INDEX - // Use vertex_no_morph.instance_index instead of vertex.instance_index to work around a wgpu dx12 bug. - // See https://github.com/gfx-rs/naga/issues/2416 - out.instance_index = vertex_no_morph.instance_index; -#endif - -#ifdef VISIBILITY_RANGE_DITHER - out.visibility_range_dither = mesh_functions::get_visibility_range_dither_level( - vertex_no_morph.instance_index, mesh_world_from_local[3]); -#endif - - return out; -} diff --git a/crates/processing_render/src/particles/material.rs b/crates/processing_render/src/particles/material.rs index ca8d0f4e..9cb53bb7 100644 --- a/crates/processing_render/src/particles/material.rs +++ b/crates/processing_render/src/particles/material.rs @@ -21,7 +21,7 @@ pub struct ParticlesMaterialPlugin; impl Plugin for ParticlesMaterialPlugin { fn build(&self, app: &mut App) { - crate::internal_shader!(app, SHADER, "particles.wgsl"); + crate::internal_shader!(app, SHADER, "particles.wesl"); app.add_plugins(MaterialPlugin::::default()); } } diff --git a/crates/processing_render/src/particles/mod.rs b/crates/processing_render/src/particles/mod.rs index 99ccfc3b..6a5ca4dd 100644 --- a/crates/processing_render/src/particles/mod.rs +++ b/crates/processing_render/src/particles/mod.rs @@ -329,8 +329,8 @@ fn make_buffer_with_usage( extra_usage: BufferUsages, ) -> Entity { let byte_size = initial.len() as u64; - let mut shader_buffer = ShaderBuffer::new(initial, RenderAssetUsages::all()); - shader_buffer.buffer_description.usage |= extra_usage; + let mut shader_buffer = ShaderBuffer::new(initial.to_vec(), RenderAssetUsages::all()); + shader_buffer.buffer_usage |= extra_usage; let handle = shader_buffers.add(shader_buffer); let readback = render_device.create_buffer(&BufferDescriptor { label: Some("Particles Buffer Readback"), diff --git a/crates/processing_render/src/particles/pack.rs b/crates/processing_render/src/particles/pack.rs index 2c77313e..f81d15bd 100644 --- a/crates/processing_render/src/particles/pack.rs +++ b/crates/processing_render/src/particles/pack.rs @@ -1,22 +1,17 @@ use std::num::NonZeroU64; -use bevy::core_pipeline::Core3d; -use bevy::pbr::{ - MeshCullingDataBuffer, MeshInputUniform, MeshUniform, early_gpu_preprocess, - gpu_instance_batch::GpuInstanceBatchReservations, -}; +use bevy::pbr::gpu_instance_batch::{GpuInstanceBatchReservations, GpuInstanceBatchSystems}; use bevy::platform::collections::HashMap; use bevy::prelude::*; use bevy::render::{ Extract, ExtractSchedule, Render, RenderApp, RenderSystems, - batching::gpu_preprocessing::BatchedInstanceBuffers, render_asset::RenderAssets, render_resource::{ BindGroup, BindGroupEntry, BindGroupLayoutDescriptor, BindGroupLayoutEntry, BindingType, BufferBindingType, CachedComputePipelineId, CachedPipelineState, ComputePassDescriptor, ComputePipelineDescriptor, PipelineCache, ShaderStages, ShaderType, UniformBuffer, }, - renderer::{RenderContext, RenderDevice, RenderQueue}, + renderer::{RenderContext, RenderDevice, RenderGraph, RenderQueue}, storage::{GpuShaderBuffer, ShaderBuffer}, sync_world::{MainEntity, MainEntityHashMap}, }; @@ -35,9 +30,9 @@ impl Plugin for ParticlesPackPlugin { fn build(&self, app: &mut App) { let shader = { let mut shaders = app.world_mut().resource_mut::>(); - shaders.add(Shader::from_wgsl( - include_str!("pack.wgsl"), - "processing_render/particles/pack.wgsl", + shaders.add(Shader::from_wesl( + include_str!("pack.wesl"), + "processing_render/particles/pack.wesl", )) }; app.insert_resource(ParticlesPackShader(shader.clone())); @@ -55,7 +50,12 @@ impl Plugin for ParticlesPackPlugin { Render, prepare_pack_bind_groups.in_set(RenderSystems::PrepareBindGroups), ) - .add_systems(Core3d, dispatch_pack.before(early_gpu_preprocess)); + // Publish into each draw's persistent `GpuMeshInstance` output; the + // renderer materializes those into mesh inputs before any view. + .add_systems( + RenderGraph, + dispatch_pack.in_set(GpuInstanceBatchSystems::Publish), + ); } } @@ -81,10 +81,10 @@ pub struct ParticlesPackPipelines { #[derive(Copy, Clone, Default, ShaderType)] struct ParticlesPackParams { - base_input_index: u32, count: u32, _pad0: u32, _pad1: u32, + _pad2: u32, } pub struct ExtractedParticlesData { @@ -128,21 +128,18 @@ fn pack_layout_entries(key: PackPipelineKey) -> Vec { min_binding_size: NonZeroU64::new(16), }; - let mut entries = vec![ - layout_entry(0, storage_rw), - layout_entry(1, storage_rw), - layout_entry(2, storage_r), - ]; + // 0: the draw's `GpuMeshInstance` output, 1..: particle attributes, last: params. + let mut entries = vec![layout_entry(0, storage_rw), layout_entry(1, storage_r)]; if key.has_rotation { - entries.push(layout_entry(3, storage_r)); + entries.push(layout_entry(2, storage_r)); } if key.has_scale { - entries.push(layout_entry(4, storage_r)); + entries.push(layout_entry(3, storage_r)); } if key.has_life { - entries.push(layout_entry(5, storage_r)); + entries.push(layout_entry(4, storage_r)); } - entries.push(layout_entry(6, uniform)); + entries.push(layout_entry(5, uniform)); entries } @@ -266,28 +263,16 @@ fn prepare_pack_bind_groups( mut pipeline_cache: ResMut, extracted: Res, reservations: Res, - batched_instance_buffers: Res>, - culling_data_buffer: Res, gpu_buffers: Res>, render_device: Res, render_queue: Res, mut bind_groups: ResMut, ) { + // Rebuilt every frame: a resized reservation replaces its output buffer. bind_groups.per_batch.clear(); - let Some(input_buffer) = batched_instance_buffers - .current_input_buffer - .buffer() - .buffer() - else { - return; - }; - let Some(culling_buffer) = culling_data_buffer.buffer() else { - return; - }; - for (main_entity, data) in extracted.by_main.iter() { - let Some(reservation) = reservations.by_entity.get(main_entity) else { + let Some(reservation) = reservations.get(*main_entity) else { continue; }; let Some(gpu_position) = gpu_buffers.get(&data.position) else { @@ -317,8 +302,7 @@ fn prepare_pack_bind_groups( let cached = pipelines.by_key.get(&data.key).unwrap(); let params = ParticlesPackParams { - base_input_index: reservation.input_buffer_base, - count: reservation.max_capacity, + count: reservation.max_capacity(), ..default() }; let mut uniform = UniformBuffer::from(params); @@ -327,37 +311,33 @@ fn prepare_pack_bind_groups( let mut entries: Vec = vec![ BindGroupEntry { binding: 0, - resource: input_buffer.as_entire_binding(), + resource: reservation.output_buffer().as_entire_binding(), }, BindGroupEntry { binding: 1, - resource: culling_buffer.as_entire_binding(), - }, - BindGroupEntry { - binding: 2, resource: gpu_position.buffer.as_entire_binding(), }, ]; if let Some(gpu_rotation) = gpu_rotation { entries.push(BindGroupEntry { - binding: 3, + binding: 2, resource: gpu_rotation.buffer.as_entire_binding(), }); } if let Some(gpu_scale) = gpu_scale { entries.push(BindGroupEntry { - binding: 4, + binding: 3, resource: gpu_scale.buffer.as_entire_binding(), }); } if let Some(gpu_life) = gpu_life { entries.push(BindGroupEntry { - binding: 5, + binding: 4, resource: gpu_life.buffer.as_entire_binding(), }); } entries.push(BindGroupEntry { - binding: 6, + binding: 5, resource: uniform.binding().unwrap(), }); @@ -367,7 +347,7 @@ fn prepare_pack_bind_groups( &entries, ); - let dispatch_count = reservation.max_capacity.div_ceil(WORKGROUP_SIZE); + let dispatch_count = reservation.max_capacity().div_ceil(WORKGROUP_SIZE); bind_groups.per_batch.insert( *main_entity, PerBatchBindGroup { diff --git a/crates/processing_render/src/particles/pack.wesl b/crates/processing_render/src/particles/pack.wesl new file mode 100644 index 00000000..660b25aa --- /dev/null +++ b/crates/processing_render/src/particles/pack.wesl @@ -0,0 +1,82 @@ +// Packs particle attributes into the draw's persistent `GpuMeshInstance` +// output (one slot per particle, slot i = particle i). The renderer +// materializes mesh inputs from it; culling uses the mesh's own bounds. +import bevy_pbr::gpu_instance_batch::gpu_instance::GpuMeshInstance; + +struct PackParams { + count: u32, + _pad0: u32, + _pad1: u32, + _pad2: u32, +} + +@group(0) @binding(0) var instances: array; +@group(0) @binding(1) var position: array; +@if(HAS_ROTATION) +@group(0) @binding(2) var rotation: array; +@if(HAS_SCALE) +@group(0) @binding(3) var scale: array; +@if(HAS_LIFE) +@group(0) @binding(4) var life: array; +@group(0) @binding(5) var params: PackParams; + +fn quat_to_basis(q: vec4) -> mat3x3 { + let x = q.x; let y = q.y; let z = q.z; let w = q.w; + let xx = x * x; let yy = y * y; let zz = z * z; + let xy = x * y; let xz = x * z; let yz = y * z; + let wx = w * x; let wy = w * y; let wz = w * z; + return mat3x3( + vec3(1.0 - 2.0 * (yy + zz), 2.0 * (xy + wz), 2.0 * (xz - wy)), + vec3(2.0 * (xy - wz), 1.0 - 2.0 * (xx + zz), 2.0 * (yz + wx)), + vec3(2.0 * (xz + wy), 2.0 * (yz - wx), 1.0 - 2.0 * (xx + yy)), + ); +} + +@compute @workgroup_size(64) +fn pack(@builtin(global_invocation_id) gid: vec3) { + let i = gid.x; + if i >= params.count { + return; + } + let slot = i; + + let pos = vec3( + position[i * 3u + 0u], + position[i * 3u + 1u], + position[i * 3u + 2u], + ); + + var basis = mat3x3( + vec3(1.0, 0.0, 0.0), + vec3(0.0, 1.0, 0.0), + vec3(0.0, 0.0, 1.0), + ); + @if(HAS_ROTATION) { + basis = quat_to_basis(vec4( + rotation[i * 4u + 0u], + rotation[i * 4u + 1u], + rotation[i * 4u + 2u], + rotation[i * 4u + 3u], + )); + } + + var s = vec3(1.0, 1.0, 1.0); + @if(HAS_SCALE) { + s = vec3(scale[i * 3u + 0u], scale[i * 3u + 1u], scale[i * 3u + 2u]); + } + + let c0 = basis[0] * s.x; + let c1 = basis[1] * s.y; + let c2 = basis[2] * s.z; + instances[slot].world_from_local = mat3x4( + vec4(c0.x, c1.x, c2.x, pos.x), + vec4(c0.y, c1.y, c2.y, pos.y), + vec4(c0.z, c1.z, c2.z, pos.z), + ); + instances[slot].tag = i; + // A dead particle (life <= 0) is an inactive slot and draws nothing. + instances[slot].is_active = 1u; + @if(HAS_LIFE) { + instances[slot].is_active = select(0u, 1u, life[i] > 0.0); + } +} diff --git a/crates/processing_render/src/particles/pack.wgsl b/crates/processing_render/src/particles/pack.wgsl deleted file mode 100644 index c1b0e460..00000000 --- a/crates/processing_render/src/particles/pack.wgsl +++ /dev/null @@ -1,113 +0,0 @@ -struct MeshInput { - world_from_local: mat3x4, - lightmap_uv_rect: vec2, - flags: u32, - previous_input_index: u32, - first_vertex_index: u32, - first_index_index: u32, - index_count: u32, - current_skin_index: u32, - material_and_lightmap_bind_group_slot: u32, - timestamp: u32, - tag: u32, - morph_descriptor_index: u32, -} - -struct MeshCullingData { - aabb_center: vec3, - _pad: f32, - aabb_half_extents: vec3, - life: f32, -} - -struct PackParams { - base_input_index: u32, - count: u32, - _pad0: u32, - _pad1: u32, -} - -@group(0) @binding(0) var mesh_input_buffer: array; -@group(0) @binding(1) var mesh_culling_buffer: array; -@group(0) @binding(2) var position: array; -#ifdef HAS_ROTATION -@group(0) @binding(3) var rotation: array; -#endif -#ifdef HAS_SCALE -@group(0) @binding(4) var scale: array; -#endif -#ifdef HAS_LIFE -@group(0) @binding(5) var life: array; -#endif -@group(0) @binding(6) var params: PackParams; - -fn quat_to_basis(q: vec4) -> mat3x3 { - let x = q.x; let y = q.y; let z = q.z; let w = q.w; - let xx = x * x; let yy = y * y; let zz = z * z; - let xy = x * y; let xz = x * z; let yz = y * z; - let wx = w * x; let wy = w * y; let wz = w * z; - return mat3x3( - vec3(1.0 - 2.0 * (yy + zz), 2.0 * (xy + wz), 2.0 * (xz - wy)), - vec3(2.0 * (xy - wz), 1.0 - 2.0 * (xx + zz), 2.0 * (yz + wx)), - vec3(2.0 * (xz + wy), 2.0 * (yz - wx), 1.0 - 2.0 * (xx + yy)), - ); -} - -@compute @workgroup_size(64) -fn pack(@builtin(global_invocation_id) gid: vec3) { - let i = gid.x; - if i >= params.count { - return; - } - let slot = params.base_input_index + i; - - let pos = vec3( - position[i * 3u + 0u], - position[i * 3u + 1u], - position[i * 3u + 2u], - ); - -#ifdef HAS_ROTATION - let q = vec4( - rotation[i * 4u + 0u], - rotation[i * 4u + 1u], - rotation[i * 4u + 2u], - rotation[i * 4u + 3u], - ); - let basis = quat_to_basis(q); -#else - let basis = mat3x3( - vec3(1.0, 0.0, 0.0), - vec3(0.0, 1.0, 0.0), - vec3(0.0, 0.0, 1.0), - ); -#endif - -#ifdef HAS_SCALE - let s = vec3( - scale[i * 3u + 0u], - scale[i * 3u + 1u], - scale[i * 3u + 2u], - ); -#else - let s = vec3(1.0, 1.0, 1.0); -#endif - - let c0 = basis[0] * s.x; - let c1 = basis[1] * s.y; - let c2 = basis[2] * s.z; - mesh_input_buffer[slot].world_from_local = mat3x4( - vec4(c0.x, c1.x, c2.x, pos.x), - vec4(c0.y, c1.y, c2.y, pos.y), - vec4(c0.z, c1.z, c2.z, pos.z), - ); - mesh_input_buffer[slot].tag = i; - - mesh_culling_buffer[slot].aabb_center = vec3(0.0, 0.0, 0.0); - mesh_culling_buffer[slot].aabb_half_extents = vec3(1.0, 1.0, 1.0); -#ifdef HAS_LIFE - mesh_culling_buffer[slot].life = life[i]; -#else - mesh_culling_buffer[slot].life = 1.0; -#endif -} diff --git a/crates/processing_render/src/particles/particles.wesl b/crates/processing_render/src/particles/particles.wesl new file mode 100644 index 00000000..e61f1afb --- /dev/null +++ b/crates/processing_render/src/particles/particles.wesl @@ -0,0 +1,65 @@ +import bevy_pbr::render::{ + pbr_fragment::pbr_input_from_standard_material, + pbr_functions::alpha_discard, + mesh_functions, +}; + +@if(PREPASS_PIPELINE) +import bevy_pbr::{ + prepass::io::{VertexOutput, FragmentOutput}, + deferred::functions::deferred_output, +}; +@else +import bevy_pbr::render::{ + forward_io::{VertexOutput, FragmentOutput}, + pbr_functions::{apply_pbr_lighting, main_pass_post_lighting_processing}, pbr_types::STANDARD_MATERIAL_FLAGS_UNLIT_BIT, +}; + +@if(HAS_COLORS) +@group(constants::MATERIAL_BIND_GROUP) @binding(100) +var particle_colors: array>; + +@if(HAS_EMISSIVE_COLORS) +@group(constants::MATERIAL_BIND_GROUP) @binding(101) +var particle_emissive_colors: array>; + +@fragment +fn fragment( + in: VertexOutput, + @builtin(front_facing) is_front: bool, +) -> FragmentOutput { + var pbr_input = pbr_input_from_standard_material(in, is_front); + + let tag = mesh_functions::get_tag(in.instance_index); + + @if(HAS_COLORS) { + pbr_input.material.base_color = pbr_input.material.base_color * particle_colors[tag]; + } + + @if(HAS_EMISSIVE_COLORS) { + pbr_input.material.emissive = vec4( + pbr_input.material.emissive.rgb + particle_emissive_colors[tag].rgb, + pbr_input.material.emissive.a + ); + } + + pbr_input.material.base_color = alpha_discard( + pbr_input.material.flags, + pbr_input.material.alpha_cutoff, + pbr_input.material.base_color + ); + + var out: FragmentOutput; +@if(PREPASS_PIPELINE) { + out = deferred_output(in, pbr_input); +} @else { + if (pbr_input.material.flags & STANDARD_MATERIAL_FLAGS_UNLIT_BIT) == 0u { + out.color = apply_pbr_lighting(pbr_input); + } else { + out.color = pbr_input.material.base_color; + } + out.color = main_pass_post_lighting_processing(pbr_input, out.color); +} + + return out; +} diff --git a/crates/processing_render/src/particles/particles.wgsl b/crates/processing_render/src/particles/particles.wgsl deleted file mode 100644 index 8c67be7f..00000000 --- a/crates/processing_render/src/particles/particles.wgsl +++ /dev/null @@ -1,65 +0,0 @@ -#import bevy_pbr::{ - pbr_fragment::pbr_input_from_standard_material, - pbr_functions::alpha_discard, - pbr_types::STANDARD_MATERIAL_FLAGS_UNLIT_BIT, - mesh_functions, -} - -#ifdef PREPASS_PIPELINE -#import bevy_pbr::{ - prepass_io::{VertexOutput, FragmentOutput}, - pbr_deferred_functions::deferred_output, -} -#else -#import bevy_pbr::{ - forward_io::{VertexOutput, FragmentOutput}, - pbr_functions::{apply_pbr_lighting, main_pass_post_lighting_processing}, -} -#endif - -#ifdef HAS_COLORS -@group(#{MATERIAL_BIND_GROUP}) @binding(100) -var particle_colors: array>; -#endif - -#ifdef HAS_EMISSIVE_COLORS -@group(#{MATERIAL_BIND_GROUP}) @binding(101) -var particle_emissive_colors: array>; -#endif - -@fragment -fn fragment( - in: VertexOutput, - @builtin(front_facing) is_front: bool, -) -> FragmentOutput { - var pbr_input = pbr_input_from_standard_material(in, is_front); - - let tag = mesh_functions::get_tag(in.instance_index); - -#ifdef HAS_COLORS - pbr_input.material.base_color = pbr_input.material.base_color * particle_colors[tag]; -#endif - -#ifdef HAS_EMISSIVE_COLORS - pbr_input.material.emissive = vec4( - pbr_input.material.emissive.rgb + particle_emissive_colors[tag].rgb, - pbr_input.material.emissive.a - ); -#endif - - pbr_input.material.base_color = alpha_discard(pbr_input.material, pbr_input.material.base_color); - -#ifdef PREPASS_PIPELINE - let out = deferred_output(in, pbr_input); -#else - var out: FragmentOutput; - if (pbr_input.material.flags & STANDARD_MATERIAL_FLAGS_UNLIT_BIT) == 0u { - out.color = apply_pbr_lighting(pbr_input); - } else { - out.color = pbr_input.material.base_color; - } - out.color = main_pass_post_lighting_processing(pbr_input, out.color); -#endif - - return out; -} diff --git a/crates/processing_render/src/particles/point.wgsl b/crates/processing_render/src/particles/point.wesl similarity index 59% rename from crates/processing_render/src/particles/point.wgsl rename to crates/processing_render/src/particles/point.wesl index 14d418ed..bb57df72 100644 --- a/crates/processing_render/src/particles/point.wgsl +++ b/crates/processing_render/src/particles/point.wesl @@ -1,13 +1,11 @@ -#import bevy_render::view::View +import bevy_render::view::View; @group(0) @binding(0) var view: View; @group(1) @binding(0) var positions: array; -#ifdef HAS_COLORS +@if(HAS_COLORS) @group(1) @binding(1) var colors: array; -#endif -#ifdef HAS_NORMALS +@if(HAS_NORMALS) @group(1) @binding(2) var normals: array; -#endif struct VertexOutput { @builtin(position) clip_position: vec4, @@ -24,32 +22,29 @@ fn vertex(@builtin(vertex_index) vertex_index: u32) -> VertexOutput { var out: VertexOutput; out.world = world; out.clip_position = view.clip_from_world * vec4(world, 1.0); -#ifdef HAS_COLORS - out.color = vec4( - colors[i * 4u], colors[i * 4u + 1u], colors[i * 4u + 2u], colors[i * 4u + 3u]); -#else out.color = vec4(1.0, 1.0, 1.0, 1.0); -#endif -#ifdef HAS_NORMALS - out.normal = vec3(normals[i * 3u], normals[i * 3u + 1u], normals[i * 3u + 2u]); -#else + @if(HAS_COLORS) { + out.color = vec4( + colors[i * 4u], colors[i * 4u + 1u], colors[i * 4u + 2u], colors[i * 4u + 3u]); + } out.normal = vec3(0.0, 0.0, 0.0); -#endif + @if(HAS_NORMALS) { + out.normal = vec3(normals[i * 3u], normals[i * 3u + 1u], normals[i * 3u + 2u]); + } return out; } @fragment fn fragment(frag: VertexOutput) -> @location(0) vec4 { var rgb = frag.color.rgb; -#ifdef SHADED - #ifdef HAS_NORMALS - let normal = normalize(frag.normal); - #else - let normal = normalize(cross(dpdx(frag.world), dpdy(frag.world))); - #endif - let light = normalize(vec3(0.4, 0.85, 0.35)); - let diffuse = abs(dot(normal, light)); - rgb = rgb * (0.2 + 0.8 * diffuse); -#endif + @if(SHADED) { + var normal = normalize(cross(dpdx(frag.world), dpdy(frag.world))); + @if(HAS_NORMALS) { + normal = normalize(frag.normal); + } + let light = normalize(vec3(0.4, 0.85, 0.35)); + let diffuse = abs(dot(normal, light)); + rgb = rgb * (0.2 + 0.8 * diffuse); + } return vec4(rgb, frag.color.a); } diff --git a/crates/processing_render/src/particles/point_render.rs b/crates/processing_render/src/particles/point_render.rs index 79f10bd2..a87e28af 100644 --- a/crates/processing_render/src/particles/point_render.rs +++ b/crates/processing_render/src/particles/point_render.rs @@ -47,7 +47,7 @@ pub struct ParticlesPointRenderPlugin; impl Plugin for ParticlesPointRenderPlugin { fn build(&self, app: &mut App) { - crate::internal_shader!(app, SHADER, "point.wgsl"); + crate::internal_shader!(app, SHADER, "point.wesl"); app.add_plugins(ExtractComponentPlugin::::default()); let Some(render_app) = app.get_sub_app_mut(RenderApp) else { @@ -74,6 +74,7 @@ impl Plugin for ParticlesPointRenderPlugin { #[derive(Component, Clone, ExtractComponent)] #[require(VisibilityClass)] #[component(on_add = visibility::add_visibility_class::)] +#[extract_app(RenderApp)] pub struct ParticleRasterDraw { pub position: Handle, pub count: u32, @@ -394,7 +395,7 @@ fn queue_particle_raster( slabs: MeshSlabs::default(), }, Opaque3dBinKey { - asset_id: AssetId::::invalid().untyped(), + asset_id: AssetId::::default().untyped(), }, (*render_entity, *main_entity), InputUniformIndex::default(), diff --git a/crates/processing_render/src/render/line.rs b/crates/processing_render/src/render/line.rs index 8e2779d4..1a15c84c 100644 --- a/crates/processing_render/src/render/line.rs +++ b/crates/processing_render/src/render/line.rs @@ -28,7 +28,7 @@ pub struct LineMaterialPlugin; impl Plugin for LineMaterialPlugin { fn build(&self, app: &mut App) { - crate::internal_shader!(app, SHADER, "line.wgsl"); + crate::internal_shader!(app, SHADER, "line.wesl"); app.add_plugins(MaterialPlugin::::default()); let mut materials = app.world_mut().resource_mut::>(); diff --git a/crates/processing_render/src/render/line.wgsl b/crates/processing_render/src/render/line.wesl similarity index 94% rename from crates/processing_render/src/render/line.wgsl rename to crates/processing_render/src/render/line.wesl index 550b4c4d..3bd6d5ab 100644 --- a/crates/processing_render/src/render/line.wgsl +++ b/crates/processing_render/src/render/line.wesl @@ -1,6 +1,8 @@ // stroke segments drawn as camera-facing capsules, widened in screen space with round ends -#import bevy_pbr::mesh_functions::get_world_from_local -#import bevy_pbr::mesh_view_bindings::view +import bevy_pbr::render::{ + mesh_functions::get_world_from_local, + mesh_view_bindings::view, +}; struct LineMaterial { // 0 keeps the weight in pixels; 1 scales it with distance @@ -8,7 +10,7 @@ struct LineMaterial { // the fraction of its distance a stroke is pulled toward the camera depth_bias: f32, }; -@group(#{MATERIAL_BIND_GROUP}) @binding(0) var material: LineMaterial; +@group(constants::MATERIAL_BIND_GROUP) @binding(0) var material: LineMaterial; struct Vertex { @builtin(instance_index) instance_index: u32, @@ -125,9 +127,8 @@ fn vertex(vertex: Vertex) -> VertexOutput { struct FragmentOutput { @location(0) color: vec4, -#ifndef LINE_BLENDED + @if(!LINE_BLENDED) @builtin(sample_mask) sample_mask: u32, -#endif }; @fragment @@ -146,19 +147,19 @@ fn fragment(in: VertexOutput) -> FragmentOutput { let coverage = 1.0 - smoothstep(half_width - 0.5, half_width + 0.5, distance); var out: FragmentOutput; -#ifdef LINE_BLENDED + @if(LINE_BLENDED) { if coverage <= 0.0 { discard; } out.color = vec4(in.color.rgb, in.color.a * coverage); -#else + } @else { // coverage becomes an MSAA sample mask - let samples = u32(round(coverage * f32(#{MSAA_SAMPLES}))); + let samples = u32(round(coverage * f32(constants::MSAA_SAMPLES))); if samples == 0u { discard; } out.color = in.color; out.sample_mask = (1u << samples) - 1u; -#endif + } return out; } diff --git a/crates/processing_render/src/render/mod.rs b/crates/processing_render/src/render/mod.rs index e436bbf2..354332f5 100644 --- a/crates/processing_render/src/render/mod.rs +++ b/crates/processing_render/src/render/mod.rs @@ -1657,7 +1657,7 @@ fn spawn_mesh( )); if custom_shader { // the vertices carry the fill - entity.insert(MeshTag(WHITE_FILL)); + entity.insert(MeshTag::new(WHITE_FILL)); } } @@ -2310,6 +2310,7 @@ fn draw_mesh3d( color, line_width, topology, + xray_mode: false, }) }) }); diff --git a/crates/processing_render/src/render/pool.rs b/crates/processing_render/src/render/pool.rs index 8e29eb50..08ae5f28 100644 --- a/crates/processing_render/src/render/pool.rs +++ b/crates/processing_render/src/render/pool.rs @@ -90,7 +90,7 @@ impl DrawPool { entity.insert(UntypedMaterial(material)); } if let Some(tag) = draw.tag { - entity.insert(MeshTag(tag)); + entity.insert(MeshTag::new(tag)); } if let Some(wireframe) = draw.wireframe { entity.insert((Wireframe, Mesh3dWireframe(wireframe))); @@ -128,7 +128,7 @@ impl DrawPool { if slot.tag != draw.tag { slot.tag = draw.tag; match draw.tag { - Some(tag) => entity.insert(MeshTag(tag)), + Some(tag) => entity.insert(MeshTag::new(tag)), None => entity.remove::(), }; } diff --git a/crates/processing_render/src/render/primitive/shape3d.rs b/crates/processing_render/src/render/primitive/shape3d.rs index a7c5b45c..6b9367b7 100644 --- a/crates/processing_render/src/render/primitive/shape3d.rs +++ b/crates/processing_render/src/render/primitive/shape3d.rs @@ -23,35 +23,35 @@ fn finish(mesh: &mut Mesh) { } pub fn box_mesh(width: f32, height: f32, depth: f32) -> Mesh { - let cuboid = bevy::math::primitives::Cuboid::new(width, height, depth); + let cuboid = bevy::shape::Cuboid::new(width, height, depth); let mut mesh = Mesh::from(cuboid); finish(&mut mesh); mesh } pub fn sphere_mesh(radius: f32, sectors: u32, stacks: u32) -> Mesh { - let sphere = bevy::math::primitives::Sphere::new(radius); + let sphere = bevy::shape::Sphere::new(radius); let mut mesh = sphere.mesh().uv(sectors, stacks); finish(&mut mesh); mesh } pub fn cylinder_mesh(radius: f32, height: f32, detail: u32) -> Mesh { - let cylinder = bevy::math::primitives::Cylinder::new(radius, height); + let cylinder = bevy::shape::Cylinder::new(radius, height); let mut mesh = cylinder.mesh().resolution(detail).build(); finish(&mut mesh); mesh } pub fn cone_mesh(radius: f32, height: f32, detail: u32) -> Mesh { - let cone = bevy::math::primitives::Cone::new(radius, height); + let cone = bevy::shape::Cone::new(radius, height); let mut mesh = cone.mesh().resolution(detail).build(); finish(&mut mesh); mesh } pub fn torus_mesh(radius: f32, tube_radius: f32, major_segments: u32, minor_segments: u32) -> Mesh { - let torus = bevy::math::primitives::Torus::new(tube_radius, radius); + let torus = bevy::shape::Torus::new(tube_radius, radius); let mut mesh = torus .mesh() .major_resolution(major_segments as usize) @@ -62,7 +62,7 @@ pub fn torus_mesh(radius: f32, tube_radius: f32, major_segments: u32, minor_segm } pub fn capsule_mesh(radius: f32, length: f32, detail: u32) -> Mesh { - let capsule = bevy::math::primitives::Capsule3d::new(radius, length); + let capsule = bevy::shape::Capsule3d::new(radius, length); let mut mesh = capsule .mesh() .longitudes(detail) @@ -73,7 +73,7 @@ pub fn capsule_mesh(radius: f32, length: f32, detail: u32) -> Mesh { } pub fn conical_frustum_mesh(radius_top: f32, radius_bottom: f32, height: f32, detail: u32) -> Mesh { - let frustum = bevy::math::primitives::ConicalFrustum { + let frustum = bevy::shape::ConicalFrustum { radius_top, radius_bottom, height, @@ -85,7 +85,7 @@ pub fn conical_frustum_mesh(radius_top: f32, radius_bottom: f32, height: f32, de pub fn tetrahedron_mesh(radius: f32) -> Mesh { let r = radius; - let tetrahedron = bevy::math::primitives::Tetrahedron::new( + let tetrahedron = bevy::shape::Tetrahedron::new( bevy::math::Vec3::new(r, r, r), bevy::math::Vec3::new(r, -r, -r), bevy::math::Vec3::new(-r, r, -r), @@ -128,7 +128,7 @@ pub fn grid_mesh(nx: u32, ny: u32, nz: u32, spacing: f32) -> Mesh { } pub fn plane_mesh(width: f32, height: f32) -> Mesh { - let plane = bevy::math::primitives::Plane3d::default(); + let plane = bevy::shape::Plane3d::default(); let mut mesh = plane.mesh().size(width, height).build(); finish(&mut mesh); mesh diff --git a/crates/processing_webcam/Cargo.toml b/crates/processing_webcam/Cargo.toml index 8f1afd96..af00c325 100644 --- a/crates/processing_webcam/Cargo.toml +++ b/crates/processing_webcam/Cargo.toml @@ -9,6 +9,6 @@ workspace = true [dependencies] bevy = { workspace = true } -nannou_webcam = { git = "https://github.com/nannou-org/nannou", branch = "bevy-refactor" } +nannou_webcam = { git = "https://github.com/tychedelia/nannou", branch = "bevy-020" } processing_core = { workspace = true } processing_render = { workspace = true }