Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
bevyengine
GitHub Repository: bevyengine/bevy
Path: blob/main/Cargo.toml
6849 views
1
[package]
2
name = "bevy"
3
version = "0.18.0-dev"
4
edition = "2024"
5
categories = ["game-engines", "graphics", "gui", "rendering"]
6
description = "A refreshingly simple data-driven game engine and app framework"
7
exclude = ["assets/", "tools/", ".github/", "crates/", "examples/wasm/assets/"]
8
homepage = "https://bevy.org"
9
keywords = ["game", "engine", "gamedev", "graphics", "bevy"]
10
license = "MIT OR Apache-2.0"
11
repository = "https://github.com/bevyengine/bevy"
12
documentation = "https://docs.rs/bevy"
13
rust-version = "1.88.0"
14
15
[workspace]
16
resolver = "2"
17
members = [
18
# All of Bevy's official crates are within the `crates` folder!
19
"crates/*",
20
# Several crates with macros have "compile fail" tests nested inside them, also known as UI
21
# tests, that verify diagnostic output does not accidentally change.
22
# TODO: Use a glob pattern once they are fixed in `dependabot-core`
23
# TODO: See https://github.com/bevyengine/bevy/issues/17876 for context.
24
"crates/bevy_derive/compile_fail",
25
"crates/bevy_ecs/compile_fail",
26
"crates/bevy_reflect/compile_fail",
27
# Examples of compiling Bevy for mobile platforms.
28
"examples/mobile",
29
# Examples of using Bevy on no_std platforms.
30
"examples/no_std/*",
31
# Examples of compiling Bevy with automatic reflect type registration for platforms without `inventory` support.
32
"examples/reflection/auto_register_static",
33
# Benchmarks
34
"benches",
35
# Internal tools that are not published.
36
"tools/*",
37
# Bevy's error codes. This is a crate so we can automatically check all of the code blocks.
38
"errors",
39
]
40
exclude = [
41
# Integration tests are not part of the workspace
42
"tests-integration",
43
]
44
45
[workspace.lints.clippy]
46
doc_markdown = "warn"
47
manual_let_else = "warn"
48
match_same_arms = "warn"
49
redundant_closure_for_method_calls = "warn"
50
redundant_else = "warn"
51
semicolon_if_nothing_returned = "warn"
52
type_complexity = "allow"
53
undocumented_unsafe_blocks = "warn"
54
unwrap_or_default = "warn"
55
needless_lifetimes = "allow"
56
too_many_arguments = "allow"
57
nonstandard_macro_braces = "warn"
58
print_stdout = "warn"
59
print_stderr = "warn"
60
61
ptr_as_ptr = "warn"
62
ptr_cast_constness = "warn"
63
ref_as_ptr = "warn"
64
65
# see: https://github.com/bevyengine/bevy/pull/15375#issuecomment-2366966219
66
too_long_first_doc_paragraph = "allow"
67
68
std_instead_of_core = "warn"
69
std_instead_of_alloc = "warn"
70
alloc_instead_of_core = "warn"
71
72
allow_attributes = "warn"
73
allow_attributes_without_reason = "warn"
74
75
[workspace.lints.rust]
76
missing_docs = "warn"
77
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(docsrs_dep)'] }
78
unsafe_code = "deny"
79
unsafe_op_in_unsafe_fn = "warn"
80
unused_qualifications = "warn"
81
82
# Unfortunately, cargo does not currently support overriding workspace lints
83
# inside a particular crate. See https://github.com/rust-lang/cargo/issues/13157
84
#
85
# We require an override for cases like `std_instead_of_core`, which are intended
86
# for the library contributors and not for how users should consume Bevy.
87
# To ensure examples aren't subject to these lints, below is a duplication of the
88
# workspace lints, with the "overrides" applied.
89
#
90
# [lints]
91
# workspace = true
92
93
[lints.clippy]
94
doc_markdown = "warn"
95
manual_let_else = "warn"
96
match_same_arms = "warn"
97
redundant_closure_for_method_calls = "warn"
98
redundant_else = "warn"
99
semicolon_if_nothing_returned = "warn"
100
type_complexity = "allow"
101
undocumented_unsafe_blocks = "warn"
102
unwrap_or_default = "warn"
103
needless_lifetimes = "allow"
104
too_many_arguments = "allow"
105
nonstandard_macro_braces = "warn"
106
107
ptr_as_ptr = "warn"
108
ptr_cast_constness = "warn"
109
ref_as_ptr = "warn"
110
111
too_long_first_doc_paragraph = "allow"
112
113
std_instead_of_core = "allow"
114
std_instead_of_alloc = "allow"
115
alloc_instead_of_core = "allow"
116
117
allow_attributes = "warn"
118
allow_attributes_without_reason = "warn"
119
120
[lints.rust]
121
missing_docs = "warn"
122
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(docsrs_dep)'] }
123
unsafe_code = "deny"
124
unsafe_op_in_unsafe_fn = "warn"
125
unused_qualifications = "warn"
126
127
[features]
128
default = [
129
"std",
130
"async_executor",
131
"android-game-activity",
132
"android_shared_stdcxx",
133
"animation",
134
"bevy_asset",
135
"bevy_audio",
136
"bevy_color",
137
"bevy_core_pipeline",
138
"bevy_post_process",
139
"bevy_anti_alias",
140
"bevy_gilrs",
141
"bevy_gizmos",
142
"bevy_gltf",
143
"bevy_input_focus",
144
"bevy_log",
145
"bevy_mesh_picking_backend",
146
"bevy_pbr",
147
"bevy_picking",
148
"bevy_render",
149
"bevy_scene",
150
"bevy_image",
151
"bevy_mesh",
152
"bevy_camera",
153
"bevy_light",
154
"bevy_shader",
155
"bevy_sprite",
156
"bevy_sprite_picking_backend",
157
"bevy_sprite_render",
158
"bevy_state",
159
"bevy_text",
160
"bevy_ui",
161
"bevy_ui_picking_backend",
162
"bevy_ui_render",
163
"bevy_window",
164
"bevy_winit",
165
"custom_cursor",
166
"default_font",
167
"hdr",
168
"ktx2",
169
"multi_threaded",
170
"png",
171
"reflect_auto_register",
172
"smaa_luts",
173
"sysinfo_plugin",
174
"tonemapping_luts",
175
"vorbis",
176
"webgl2",
177
"x11",
178
"wayland",
179
"debug",
180
"zstd_rust",
181
]
182
183
# Recommended defaults for no_std applications
184
default_no_std = ["libm", "critical-section", "bevy_color", "bevy_state"]
185
186
# Provides an implementation for picking meshes
187
bevy_mesh_picking_backend = ["bevy_internal/bevy_mesh_picking_backend"]
188
189
# Provides an implementation for picking sprites
190
bevy_sprite_picking_backend = ["bevy_internal/bevy_sprite_picking_backend"]
191
192
# Provides an implementation for picking UI
193
bevy_ui_picking_backend = ["bevy_internal/bevy_ui_picking_backend"]
194
195
# Provides a debug overlay for bevy UI
196
bevy_ui_debug = ["bevy_internal/bevy_ui_debug"]
197
198
# Force dynamic linking, which improves iterative compile times
199
dynamic_linking = ["dep:bevy_dylib", "bevy_internal/dynamic_linking"]
200
201
# Enables system information diagnostic plugin
202
sysinfo_plugin = ["bevy_internal/sysinfo_plugin"]
203
204
# Provides animation functionality
205
bevy_animation = ["bevy_internal/bevy_animation"]
206
207
# Provides asset functionality
208
bevy_asset = ["bevy_internal/bevy_asset"]
209
210
# Provides audio functionality
211
bevy_audio = ["bevy_internal/bevy_audio"]
212
213
# Provides shared color types and operations
214
bevy_color = ["bevy_internal/bevy_color"]
215
216
# Provides cameras and other basic render pipeline features
217
bevy_core_pipeline = ["bevy_internal/bevy_core_pipeline"]
218
219
# Provides post process effects such as depth of field, bloom, chromatic aberration.
220
bevy_post_process = ["bevy_internal/bevy_post_process"]
221
222
# Provides various anti aliasing solutions
223
bevy_anti_alias = ["bevy_internal/bevy_anti_alias"]
224
225
# Adds gamepad support
226
bevy_gilrs = ["bevy_internal/bevy_gilrs"]
227
228
# [glTF](https://www.khronos.org/gltf/) support
229
bevy_gltf = ["bevy_internal/bevy_gltf"]
230
231
# Adds PBR rendering
232
bevy_pbr = ["bevy_internal/bevy_pbr"]
233
234
# Provides picking functionality
235
bevy_picking = ["bevy_internal/bevy_picking"]
236
237
# Provides rendering functionality
238
bevy_render = ["bevy_internal/bevy_render"]
239
240
# Provides scene functionality
241
bevy_scene = ["bevy_internal/bevy_scene"]
242
243
# Provides raytraced lighting (experimental)
244
bevy_solari = ["bevy_internal/bevy_solari"]
245
246
# Provides sprite functionality
247
bevy_sprite = ["bevy_internal/bevy_sprite"]
248
249
# Provides sprite rendering functionality
250
bevy_sprite_render = ["bevy_internal/bevy_sprite_render"]
251
252
# Provides text functionality
253
bevy_text = ["bevy_internal/bevy_text"]
254
255
# A custom ECS-driven UI framework
256
bevy_ui = ["bevy_internal/bevy_ui"]
257
258
# Provides rendering functionality for bevy_ui
259
bevy_ui_render = ["bevy_internal/bevy_ui_render"]
260
261
# Windowing layer
262
bevy_window = ["bevy_internal/bevy_window"]
263
264
# winit window and input backend
265
bevy_winit = ["bevy_internal/bevy_winit"]
266
267
# Load and access image data. Usually added by an image format
268
bevy_image = ["bevy_internal/bevy_image"]
269
270
# Provides a mesh format and some primitive meshing routines.
271
bevy_mesh = ["bevy_internal/bevy_mesh"]
272
273
# Provides camera and visibility types, as well as culling primitives.
274
bevy_camera = ["bevy_internal/bevy_camera"]
275
276
# Provides light types such as point lights, directional lights, spotlights.
277
bevy_light = ["bevy_internal/bevy_light"]
278
279
# Provides shaders usable through asset handles.
280
bevy_shader = ["bevy_internal/bevy_shader"]
281
282
# Adds support for rendering gizmos
283
bevy_gizmos = ["bevy_internal/bevy_gizmos"]
284
285
# Provides a collection of developer tools
286
bevy_dev_tools = ["bevy_internal/bevy_dev_tools"]
287
288
# Enable the Bevy Remote Protocol
289
bevy_remote = ["bevy_internal/bevy_remote"]
290
291
# Enable integration with `tracing` and `log`
292
bevy_log = ["bevy_internal/bevy_log"]
293
294
# Enable input focus subsystem
295
bevy_input_focus = ["bevy_internal/bevy_input_focus"]
296
297
# Experimental headless widget collection for Bevy UI.
298
experimental_bevy_ui_widgets = ["bevy_internal/bevy_ui_widgets"]
299
300
# Feathers widget collection.
301
experimental_bevy_feathers = [
302
"bevy_internal/bevy_feathers",
303
"experimental_bevy_ui_widgets",
304
]
305
306
# Enable passthrough loading for SPIR-V shaders (Only supported on Vulkan, shader capabilities and extensions must agree with the platform implementation)
307
spirv_shader_passthrough = ["bevy_internal/spirv_shader_passthrough"]
308
309
# Statically linked DXC shader compiler for DirectX 12
310
statically-linked-dxc = ["bevy_internal/statically-linked-dxc"]
311
312
# Forces the wgpu instance to be initialized using the raw Vulkan HAL, enabling additional configuration
313
raw_vulkan_init = ["bevy_internal/raw_vulkan_init"]
314
315
# Tracing support, saving a file in Chrome Tracing format
316
trace_chrome = ["trace", "bevy_internal/trace_chrome"]
317
318
# Tracing support, exposing a port for Tracy
319
trace_tracy = ["trace", "bevy_internal/trace_tracy"]
320
321
# Tracing support, with memory profiling, exposing a port for Tracy
322
trace_tracy_memory = ["bevy_internal/trace_tracy_memory"]
323
324
# Tracing support
325
trace = ["bevy_internal/trace", "dep:tracing"]
326
327
# Basis Universal compressed texture support
328
basis-universal = ["bevy_internal/basis-universal"]
329
330
# Enables compressed KTX2 UASTC texture output on the asset processor
331
compressed_image_saver = ["bevy_internal/compressed_image_saver"]
332
333
# BMP image format support
334
bmp = ["bevy_internal/bmp"]
335
336
# DDS compressed texture support
337
dds = ["bevy_internal/dds"]
338
339
# EXR image format support
340
exr = ["bevy_internal/exr"]
341
342
# Farbfeld image format support
343
ff = ["bevy_internal/ff"]
344
345
# GIF image format support
346
gif = ["bevy_internal/gif"]
347
348
# HDR image format support
349
hdr = ["bevy_internal/hdr"]
350
351
# KTX2 compressed texture support
352
ktx2 = ["bevy_internal/ktx2"]
353
354
# ICO image format support
355
ico = ["bevy_internal/ico"]
356
357
# JPEG image format support
358
jpeg = ["bevy_internal/jpeg"]
359
360
# PNG image format support
361
png = ["bevy_internal/png"]
362
363
# PNM image format support, includes pam, pbm, pgm and ppm
364
pnm = ["bevy_internal/pnm"]
365
366
# QOI image format support
367
qoi = ["bevy_internal/qoi"]
368
369
# TGA image format support
370
tga = ["bevy_internal/tga"]
371
372
# TIFF image format support
373
tiff = ["bevy_internal/tiff"]
374
375
# WebP image format support
376
webp = ["bevy_internal/webp"]
377
378
# For KTX2 supercompression
379
zlib = ["bevy_internal/zlib"]
380
381
# For KTX2 Zstandard decompression using pure rust [ruzstd](https://crates.io/crates/ruzstd). This is the safe default. For maximum performance, use "zstd_c".
382
zstd_rust = ["bevy_internal/zstd_rust"]
383
384
# For KTX2 Zstandard decompression using [zstd](https://crates.io/crates/zstd). This is a faster backend, but uses unsafe C bindings. For the safe option, stick to the default backend with "zstd_rust".
385
zstd_c = ["bevy_internal/zstd_c"]
386
387
# FLAC audio format support
388
flac = ["bevy_internal/flac"]
389
390
# MP3 audio format support
391
mp3 = ["bevy_internal/mp3"]
392
393
# OGG/VORBIS audio format support
394
vorbis = ["bevy_internal/vorbis"]
395
396
# WAV audio format support
397
wav = ["bevy_internal/wav"]
398
399
# AAC audio format support (through symphonia)
400
symphonia-aac = ["bevy_internal/symphonia-aac"]
401
402
# AAC, FLAC, MP3, MP4, OGG/VORBIS, and WAV audio formats support (through symphonia)
403
symphonia-all = ["bevy_internal/symphonia-all"]
404
405
# FLAC audio format support (through symphonia)
406
symphonia-flac = ["bevy_internal/symphonia-flac"]
407
408
# MP4 audio format support (through symphonia)
409
symphonia-isomp4 = ["bevy_internal/symphonia-isomp4"]
410
411
# OGG/VORBIS audio format support (through symphonia)
412
symphonia-vorbis = ["bevy_internal/symphonia-vorbis"]
413
414
# WAV audio format support (through symphonia)
415
symphonia-wav = ["bevy_internal/symphonia-wav"]
416
417
# Enable serialization support through serde
418
serialize = ["bevy_internal/serialize"]
419
420
# Enables multithreaded parallelism in the engine. Disabling it forces all engine tasks to run on a single thread.
421
multi_threaded = ["bevy_internal/multi_threaded"]
422
423
# Use async-io's implementation of block_on instead of futures-lite's implementation. This is preferred if your application uses async-io.
424
async-io = ["bevy_internal/async-io"]
425
426
# Wayland display server support
427
wayland = ["bevy_internal/wayland"]
428
429
# X11 display server support
430
x11 = ["bevy_internal/x11"]
431
432
# Android NativeActivity support. Legacy, should be avoided for most new Android games.
433
android-native-activity = ["bevy_internal/android-native-activity"]
434
435
# Android GameActivity support. Default, choose between this and `android-native-activity`.
436
android-game-activity = ["bevy_internal/android-game-activity"]
437
438
# Enable systems that allow for automated testing on CI
439
bevy_ci_testing = ["bevy_internal/bevy_ci_testing"]
440
441
# Enable animation support, and glTF animation loading
442
animation = ["bevy_internal/animation", "bevy_animation"]
443
444
# Enable using a shared stdlib for cxx on Android
445
android_shared_stdcxx = ["bevy_internal/android_shared_stdcxx"]
446
447
# Enable detailed trace event logging. These trace events are expensive even when off, thus they require compile time opt-in
448
detailed_trace = ["bevy_internal/detailed_trace"]
449
450
# Include tonemapping Look Up Tables KTX2 files. If everything is pink, you need to enable this feature or change the `Tonemapping` method for your `Camera2d` or `Camera3d`.
451
tonemapping_luts = ["bevy_internal/tonemapping_luts"]
452
453
# Include SMAA Look Up Tables KTX2 Files
454
smaa_luts = ["bevy_internal/smaa_luts"]
455
456
# Include spatio-temporal blue noise KTX2 file used by generated environment maps, Solari and atmosphere
457
bluenoise_texture = ["bevy_internal/bluenoise_texture"]
458
459
# NVIDIA Deep Learning Super Sampling
460
dlss = ["bevy_internal/dlss"]
461
462
# Forcibly disable DLSS so that cargo build --all-features works without the DLSS SDK being installed. Not meant for users.
463
force_disable_dlss = ["bevy_internal/force_disable_dlss"]
464
465
# Enable AccessKit on Unix backends (currently only works with experimental screen readers and forks.)
466
accesskit_unix = ["bevy_internal/accesskit_unix"]
467
468
# Enable assertions to check the validity of parameters passed to glam
469
glam_assert = ["bevy_internal/glam_assert"]
470
471
# Enable assertions in debug builds to check the validity of parameters passed to glam
472
debug_glam_assert = ["bevy_internal/debug_glam_assert"]
473
474
# Include a default font, containing only ASCII characters, at the cost of a 20kB binary size increase
475
default_font = ["bevy_internal/default_font"]
476
477
# Enable support for shaders in GLSL
478
shader_format_glsl = ["bevy_internal/shader_format_glsl"]
479
480
# Enable support for shaders in SPIR-V
481
shader_format_spirv = ["bevy_internal/shader_format_spirv"]
482
483
# Enable support for shaders in WESL
484
shader_format_wesl = ["bevy_internal/shader_format_wesl"]
485
486
# Enable support for transmission-related textures in the `StandardMaterial`, at the risk of blowing past the global, per-shader texture limit on older/lower-end GPUs
487
pbr_transmission_textures = ["bevy_internal/pbr_transmission_textures"]
488
489
# Enable support for Clustered Decals
490
pbr_clustered_decals = ["bevy_internal/pbr_clustered_decals"]
491
492
# Enable support for Light Textures
493
pbr_light_textures = ["bevy_internal/pbr_light_textures"]
494
495
# Enable support for multi-layer material textures in the `StandardMaterial`, at the risk of blowing past the global, per-shader texture limit on older/lower-end GPUs
496
pbr_multi_layer_material_textures = [
497
"bevy_internal/pbr_multi_layer_material_textures",
498
]
499
500
# Enable support for anisotropy texture in the `StandardMaterial`, at the risk of blowing past the global, per-shader texture limit on older/lower-end GPUs
501
pbr_anisotropy_texture = ["bevy_internal/pbr_anisotropy_texture"]
502
503
# Enable support for PCSS, at the risk of blowing past the global, per-shader sampler limit on older/lower-end GPUs
504
experimental_pbr_pcss = ["bevy_internal/experimental_pbr_pcss"]
505
506
# Enable support for specular textures in the `StandardMaterial`, at the risk of blowing past the global, per-shader texture limit on older/lower-end GPUs
507
pbr_specular_textures = ["bevy_internal/pbr_specular_textures"]
508
509
# Enable some limitations to be able to use WebGL2. Please refer to the [WebGL2 and WebGPU](https://github.com/bevyengine/bevy/tree/latest/examples#webgl2-and-webgpu) section of the examples README for more information on how to run Wasm builds with WebGPU.
510
webgl2 = ["bevy_internal/webgl"]
511
512
# Enable support for WebGPU in Wasm. When enabled, this feature will override the `webgl2` feature and you won't be able to run Wasm builds with WebGL2, only with WebGPU.
513
webgpu = ["bevy_internal/webgpu"]
514
515
# Enables the built-in asset processor for processed assets.
516
asset_processor = ["bevy_internal/asset_processor"]
517
518
# Enables watching the filesystem for Bevy Asset hot-reloading
519
file_watcher = ["bevy_internal/file_watcher"]
520
521
# Enables watching in memory asset providers for Bevy Asset hot-reloading
522
embedded_watcher = ["bevy_internal/embedded_watcher"]
523
524
# Enables downloading assets from HTTP sources. Warning: there are security implications. Read the docs on WebAssetPlugin.
525
http = ["bevy_internal/http"]
526
527
# Enables downloading assets from HTTPS sources. Warning: there are security implications. Read the docs on WebAssetPlugin.
528
https = ["bevy_internal/https"]
529
530
# Enable caching downloaded assets on the filesystem. NOTE: this cache currently never invalidates entries!
531
web_asset_cache = ["bevy_internal/web_asset_cache"]
532
533
# Enable stepping-based debugging of Bevy systems
534
bevy_debug_stepping = [
535
"bevy_internal/bevy_debug_stepping",
536
"bevy_internal/debug",
537
]
538
539
# Enables the meshlet renderer for dense high-poly scenes (experimental)
540
meshlet = ["bevy_internal/meshlet"]
541
542
# Enables processing meshes into meshlet meshes for bevy_pbr
543
meshlet_processor = ["bevy_internal/meshlet_processor"]
544
545
# Enable built in global state machines
546
bevy_state = ["bevy_internal/bevy_state"]
547
548
# Enables source location tracking for change detection and spawning/despawning, which can assist with debugging
549
track_location = ["bevy_internal/track_location"]
550
551
# Enable function reflection
552
reflect_functions = ["bevy_internal/reflect_functions"]
553
554
# Enable documentation reflection
555
reflect_documentation = ["bevy_internal/reflect_documentation"]
556
557
# Enable automatic reflect registration
558
reflect_auto_register = ["bevy_internal/reflect_auto_register"]
559
560
# Enable automatic reflect registration without inventory. See `reflect::load_type_registrations` for more info.
561
reflect_auto_register_static = ["bevy_internal/reflect_auto_register_static"]
562
563
# Enable winit custom cursor support
564
custom_cursor = ["bevy_internal/custom_cursor"]
565
566
# Experimental support for nodes that are ignored for UI layouting
567
ghost_nodes = ["bevy_internal/ghost_nodes"]
568
569
# Uses `async-executor` as a task execution backend.
570
async_executor = ["std", "bevy_internal/async_executor"]
571
572
# Allows access to the `std` crate.
573
std = ["bevy_internal/std"]
574
575
# `critical-section` provides the building blocks for synchronization primitives on all platforms, including `no_std`.
576
critical-section = ["bevy_internal/critical-section"]
577
578
# Uses the `libm` maths library instead of the one provided in `std` and `core`.
579
libm = ["bevy_internal/libm"]
580
581
# Enables use of browser APIs. Note this is currently only applicable on `wasm32` architectures.
582
web = ["bevy_internal/web"]
583
584
# Enable hotpatching of Bevy systems
585
hotpatching = ["bevy_internal/hotpatching"]
586
587
# Enable collecting debug information about systems and components to help with diagnostics
588
debug = ["bevy_internal/debug"]
589
590
[dependencies]
591
bevy_internal = { path = "crates/bevy_internal", version = "0.18.0-dev", default-features = false }
592
tracing = { version = "0.1", default-features = false, optional = true }
593
594
# Wasm does not support dynamic linking.
595
[target.'cfg(not(target_family = "wasm"))'.dependencies]
596
bevy_dylib = { path = "crates/bevy_dylib", version = "0.18.0-dev", default-features = false, optional = true }
597
598
[dev-dependencies]
599
rand = "0.9.0"
600
rand_chacha = "0.9.0"
601
ron = "0.10"
602
flate2 = "1.0"
603
serde = { version = "1", features = ["derive"] }
604
serde_json = "1.0.140"
605
bytemuck = "1"
606
# The following explicit dependencies are needed for proc macros to work inside of examples as they are part of the bevy crate itself.
607
bevy_animation = { path = "crates/bevy_animation", version = "0.18.0-dev", default-features = false }
608
bevy_asset = { path = "crates/bevy_asset", version = "0.18.0-dev", default-features = false }
609
bevy_ecs = { path = "crates/bevy_ecs", version = "0.18.0-dev", default-features = false }
610
bevy_gizmos = { path = "crates/bevy_gizmos", version = "0.18.0-dev", default-features = false }
611
bevy_image = { path = "crates/bevy_image", version = "0.18.0-dev", default-features = false }
612
bevy_reflect = { path = "crates/bevy_reflect", version = "0.18.0-dev", default-features = false }
613
bevy_render = { path = "crates/bevy_render", version = "0.18.0-dev", default-features = false }
614
bevy_state = { path = "crates/bevy_state", version = "0.18.0-dev", default-features = false }
615
# Needed to poll Task examples
616
futures-lite = "2.0.1"
617
futures-timer = { version = "3", features = ["wasm-bindgen", "gloo-timers"] }
618
crossbeam-channel = "0.5.0"
619
argh = "0.1.12"
620
thiserror = "2.0"
621
event-listener = "5.3.0"
622
anyhow = "1"
623
accesskit = "0.21"
624
nonmax = "0.5"
625
626
[target.'cfg(not(target_family = "wasm"))'.dev-dependencies]
627
ureq = { version = "3.0.8", features = ["json"] }
628
629
[target.'cfg(target_arch = "wasm32")'.dev-dependencies]
630
getrandom = { version = "0.3", default-features = false, features = [
631
"wasm_js",
632
] }
633
wasm-bindgen = { version = "0.2" }
634
web-sys = { version = "0.3", features = ["Window"] }
635
636
[[example]]
637
name = "context_menu"
638
path = "examples/usage/context_menu.rs"
639
doc-scrape-examples = true
640
641
[package.metadata.example.context_menu]
642
name = "Context Menu"
643
description = "Example of a context menu"
644
category = "Usage"
645
wasm = true
646
647
[[example]]
648
name = "hello_world"
649
path = "examples/hello_world.rs"
650
doc-scrape-examples = true
651
652
[package.metadata.example.hello_world]
653
hidden = true
654
655
# 2D Rendering
656
[[example]]
657
name = "bloom_2d"
658
path = "examples/2d/bloom_2d.rs"
659
doc-scrape-examples = true
660
661
[package.metadata.example.bloom_2d]
662
name = "2D Bloom"
663
description = "Illustrates bloom post-processing in 2d"
664
category = "2D Rendering"
665
wasm = true
666
667
[[example]]
668
name = "move_sprite"
669
path = "examples/2d/move_sprite.rs"
670
doc-scrape-examples = true
671
672
[package.metadata.example.move_sprite]
673
name = "Move Sprite"
674
description = "Changes the transform of a sprite"
675
category = "2D Rendering"
676
wasm = true
677
678
[[example]]
679
name = "2d_viewport_to_world"
680
path = "examples/2d/2d_viewport_to_world.rs"
681
doc-scrape-examples = true
682
683
[package.metadata.example.2d_viewport_to_world]
684
name = "2D Viewport To World"
685
description = "Demonstrates how to use the `Camera::viewport_to_world_2d` method with a dynamic viewport and camera."
686
category = "2D Rendering"
687
wasm = true
688
689
[[example]]
690
name = "rotation"
691
path = "examples/2d/rotation.rs"
692
doc-scrape-examples = true
693
694
[package.metadata.example.rotation]
695
name = "2D Rotation"
696
description = "Demonstrates rotating entities in 2D with quaternions"
697
category = "2D Rendering"
698
wasm = true
699
700
[[example]]
701
name = "mesh2d"
702
path = "examples/2d/mesh2d.rs"
703
doc-scrape-examples = true
704
705
[package.metadata.example.mesh2d]
706
name = "Mesh 2D"
707
description = "Renders a 2d mesh"
708
category = "2D Rendering"
709
wasm = true
710
711
[[example]]
712
name = "mesh2d_arcs"
713
path = "examples/2d/mesh2d_arcs.rs"
714
doc-scrape-examples = true
715
716
[package.metadata.example.mesh2d_arcs]
717
name = "Arc 2D Meshes"
718
description = "Demonstrates UV-mapping of the circular segment and sector primitives"
719
category = "2D Rendering"
720
wasm = true
721
722
[[example]]
723
name = "mesh2d_manual"
724
path = "examples/2d/mesh2d_manual.rs"
725
doc-scrape-examples = true
726
727
[package.metadata.example.mesh2d_manual]
728
name = "Manual Mesh 2D"
729
description = "Renders a custom mesh \"manually\" with \"mid-level\" renderer apis"
730
category = "2D Rendering"
731
wasm = true
732
733
[[example]]
734
name = "mesh2d_vertex_color_texture"
735
path = "examples/2d/mesh2d_vertex_color_texture.rs"
736
doc-scrape-examples = true
737
738
[package.metadata.example.mesh2d_vertex_color_texture]
739
name = "Mesh 2D With Vertex Colors"
740
description = "Renders a 2d mesh with vertex color attributes"
741
category = "2D Rendering"
742
wasm = true
743
744
[[example]]
745
name = "2d_shapes"
746
path = "examples/2d/2d_shapes.rs"
747
doc-scrape-examples = true
748
749
[package.metadata.example.2d_shapes]
750
name = "2D Shapes"
751
description = "Renders simple 2D primitive shapes like circles and polygons"
752
category = "2D Rendering"
753
wasm = true
754
755
[[example]]
756
name = "cpu_draw"
757
path = "examples/2d/cpu_draw.rs"
758
doc-scrape-examples = true
759
760
[package.metadata.example.cpu_draw]
761
name = "CPU Drawing"
762
description = "Manually read/write the pixels of a texture"
763
category = "2D Rendering"
764
wasm = true
765
766
[[example]]
767
name = "sprite"
768
path = "examples/2d/sprite.rs"
769
doc-scrape-examples = true
770
771
[package.metadata.example.sprite]
772
name = "Sprite"
773
description = "Renders a sprite"
774
category = "2D Rendering"
775
wasm = true
776
777
[[example]]
778
name = "sprite_animation"
779
path = "examples/2d/sprite_animation.rs"
780
doc-scrape-examples = true
781
782
[package.metadata.example.sprite_animation]
783
name = "Sprite Animation"
784
description = "Animates a sprite in response to an event"
785
category = "2D Rendering"
786
wasm = true
787
788
[[example]]
789
name = "sprite_scale"
790
path = "examples/2d/sprite_scale.rs"
791
doc-scrape-examples = true
792
793
[package.metadata.example.sprite_scale]
794
name = "Sprite Scale"
795
description = "Shows how a sprite can be scaled into a rectangle while keeping the aspect ratio"
796
category = "2D Rendering"
797
wasm = true
798
799
[[example]]
800
name = "sprite_flipping"
801
path = "examples/2d/sprite_flipping.rs"
802
doc-scrape-examples = true
803
804
[package.metadata.example.sprite_flipping]
805
name = "Sprite Flipping"
806
description = "Renders a sprite flipped along an axis"
807
category = "2D Rendering"
808
wasm = true
809
810
[[example]]
811
name = "sprite_sheet"
812
path = "examples/2d/sprite_sheet.rs"
813
doc-scrape-examples = true
814
815
[package.metadata.example.sprite_sheet]
816
name = "Sprite Sheet"
817
description = "Renders an animated sprite"
818
category = "2D Rendering"
819
wasm = true
820
821
[[example]]
822
name = "sprite_tile"
823
path = "examples/2d/sprite_tile.rs"
824
doc-scrape-examples = true
825
826
[package.metadata.example.sprite_tile]
827
name = "Sprite Tile"
828
description = "Renders a sprite tiled in a grid"
829
category = "2D Rendering"
830
wasm = true
831
832
[[example]]
833
name = "sprite_slice"
834
path = "examples/2d/sprite_slice.rs"
835
doc-scrape-examples = true
836
837
[package.metadata.example.sprite_slice]
838
name = "Sprite Slice"
839
description = "Showcases slicing sprites into sections that can be scaled independently via the 9-patch technique"
840
category = "2D Rendering"
841
wasm = true
842
843
[[example]]
844
name = "text2d"
845
path = "examples/2d/text2d.rs"
846
doc-scrape-examples = true
847
848
[package.metadata.example.text2d]
849
name = "Text 2D"
850
description = "Generates text in 2D"
851
category = "2D Rendering"
852
wasm = true
853
854
[[example]]
855
name = "multi_window_text"
856
path = "examples/window/multi_window_text.rs"
857
doc-scrape-examples = true
858
859
[package.metadata.example.multi_window_text]
860
name = "Multi-Window Text"
861
description = "Renders text to multiple windows with different scale factors using both Text and Text2d"
862
category = "2D Rendering"
863
wasm = true
864
865
[[example]]
866
name = "texture_atlas"
867
path = "examples/2d/texture_atlas.rs"
868
doc-scrape-examples = true
869
870
[package.metadata.example.texture_atlas]
871
name = "Texture Atlas"
872
description = "Generates a texture atlas (sprite sheet) from individual sprites"
873
category = "2D Rendering"
874
# Loading asset folders is not supported in Wasm, but required to create the atlas.
875
wasm = false
876
877
[[example]]
878
name = "tilemap_chunk"
879
path = "examples/2d/tilemap_chunk.rs"
880
doc-scrape-examples = true
881
882
[package.metadata.example.tilemap_chunk]
883
name = "Tilemap Chunk"
884
description = "Renders a tilemap chunk"
885
category = "2D Rendering"
886
wasm = true
887
888
[[example]]
889
name = "transparency_2d"
890
path = "examples/2d/transparency_2d.rs"
891
doc-scrape-examples = true
892
893
[package.metadata.example.transparency_2d]
894
name = "Transparency in 2D"
895
description = "Demonstrates transparency in 2d"
896
category = "2D Rendering"
897
wasm = true
898
899
[[example]]
900
name = "mesh2d_alpha_mode"
901
path = "examples/2d/mesh2d_alpha_mode.rs"
902
doc-scrape-examples = true
903
904
[package.metadata.example.mesh2d_alpha_mode]
905
name = "Mesh2d Alpha Mode"
906
description = "Used to test alpha modes with mesh2d"
907
category = "2D Rendering"
908
wasm = true
909
910
[[example]]
911
name = "mesh2d_repeated_texture"
912
path = "examples/2d/mesh2d_repeated_texture.rs"
913
doc-scrape-examples = true
914
915
[package.metadata.example.mesh2d_repeated_texture]
916
name = "Mesh2d Repeated Texture"
917
description = "Showcase of using `uv_transform` on the `ColorMaterial` of a `Mesh2d`"
918
category = "2D Rendering"
919
wasm = true
920
921
[[example]]
922
name = "pixel_grid_snap"
923
path = "examples/2d/pixel_grid_snap.rs"
924
doc-scrape-examples = true
925
926
[package.metadata.example.pixel_grid_snap]
927
name = "Pixel Grid Snapping"
928
description = "Shows how to create graphics that snap to the pixel grid by rendering to a texture in 2D"
929
category = "2D Rendering"
930
wasm = true
931
932
[[example]]
933
name = "bounding_2d"
934
path = "examples/math/bounding_2d.rs"
935
doc-scrape-examples = true
936
937
[package.metadata.example.bounding_2d]
938
name = "Bounding Volume Intersections (2D)"
939
description = "Showcases bounding volumes and intersection tests"
940
category = "Math"
941
wasm = true
942
943
[[example]]
944
name = "wireframe_2d"
945
path = "examples/2d/wireframe_2d.rs"
946
doc-scrape-examples = true
947
948
[package.metadata.example.wireframe_2d]
949
name = "2D Wireframe"
950
description = "Showcases wireframes for 2d meshes"
951
category = "2D Rendering"
952
# PolygonMode::Line wireframes are not supported by WebGL
953
wasm = false
954
955
# 3D Rendering
956
[[example]]
957
name = "3d_scene"
958
path = "examples/3d/3d_scene.rs"
959
doc-scrape-examples = true
960
961
[package.metadata.example.3d_scene]
962
name = "3D Scene"
963
description = "Simple 3D scene with basic shapes and lighting"
964
category = "3D Rendering"
965
wasm = true
966
967
[[example]]
968
name = "3d_shapes"
969
path = "examples/3d/3d_shapes.rs"
970
doc-scrape-examples = true
971
972
[package.metadata.example.3d_shapes]
973
name = "3D Shapes"
974
description = "A scene showcasing the built-in 3D shapes"
975
category = "3D Rendering"
976
wasm = true
977
978
[[example]]
979
name = "3d_viewport_to_world"
980
path = "examples/3d/3d_viewport_to_world.rs"
981
doc-scrape-examples = true
982
983
[package.metadata.example.3d_viewport_to_world]
984
name = "3D Viewport To World"
985
description = "Demonstrates how to use the `Camera::viewport_to_world` method"
986
category = "3D Rendering"
987
wasm = true
988
989
[[example]]
990
name = "animated_material"
991
path = "examples/3d/animated_material.rs"
992
doc-scrape-examples = true
993
994
[package.metadata.example.animated_material]
995
name = "Animated Material"
996
description = "Shows how to animate material properties"
997
category = "3D Rendering"
998
wasm = true
999
1000
[[example]]
1001
name = "generate_custom_mesh"
1002
path = "examples/3d/generate_custom_mesh.rs"
1003
doc-scrape-examples = true
1004
1005
[package.metadata.example.generate_custom_mesh]
1006
name = "Generate Custom Mesh"
1007
description = "Simple showcase of how to generate a custom mesh with a custom texture"
1008
category = "3D Rendering"
1009
wasm = true
1010
1011
[[example]]
1012
name = "anti_aliasing"
1013
path = "examples/3d/anti_aliasing.rs"
1014
doc-scrape-examples = true
1015
1016
[package.metadata.example.anti_aliasing]
1017
name = "Anti-aliasing"
1018
description = "Compares different anti-aliasing techniques supported by Bevy"
1019
category = "3D Rendering"
1020
# TAA not supported by WebGL
1021
wasm = false
1022
1023
[[example]]
1024
name = "atmospheric_fog"
1025
path = "examples/3d/atmospheric_fog.rs"
1026
doc-scrape-examples = true
1027
1028
[package.metadata.example.atmospheric_fog]
1029
name = "Atmospheric Fog"
1030
description = "A scene showcasing the atmospheric fog effect"
1031
category = "3D Rendering"
1032
wasm = true
1033
1034
[[example]]
1035
name = "atmosphere"
1036
path = "examples/3d/atmosphere.rs"
1037
doc-scrape-examples = true
1038
1039
[package.metadata.example.atmosphere]
1040
name = "Atmosphere"
1041
description = "A scene showcasing pbr atmospheric scattering"
1042
category = "3D Rendering"
1043
wasm = true
1044
1045
[[example]]
1046
name = "fog"
1047
path = "examples/3d/fog.rs"
1048
doc-scrape-examples = true
1049
1050
[package.metadata.example.fog]
1051
name = "Fog"
1052
description = "A scene showcasing the distance fog effect"
1053
category = "3D Rendering"
1054
wasm = true
1055
1056
[[example]]
1057
name = "auto_exposure"
1058
path = "examples/3d/auto_exposure.rs"
1059
doc-scrape-examples = true
1060
1061
[package.metadata.example.auto_exposure]
1062
name = "Auto Exposure"
1063
description = "A scene showcasing auto exposure"
1064
category = "3D Rendering"
1065
# Requires compute shaders, which are not supported by WebGL.
1066
wasm = false
1067
1068
[[example]]
1069
name = "blend_modes"
1070
path = "examples/3d/blend_modes.rs"
1071
doc-scrape-examples = true
1072
1073
[package.metadata.example.blend_modes]
1074
name = "Blend Modes"
1075
description = "Showcases different blend modes"
1076
category = "3D Rendering"
1077
wasm = true
1078
1079
[[example]]
1080
name = "manual_material"
1081
path = "examples/3d/manual_material.rs"
1082
doc-scrape-examples = true
1083
1084
[package.metadata.example.manual_material]
1085
name = "Manual Material Implementation"
1086
description = "Demonstrates how to implement a material manually using the mid-level render APIs"
1087
category = "3D Rendering"
1088
wasm = true
1089
1090
[[example]]
1091
name = "lighting"
1092
path = "examples/3d/lighting.rs"
1093
doc-scrape-examples = true
1094
1095
[package.metadata.example.lighting]
1096
name = "Lighting"
1097
description = "Illustrates various lighting options in a simple scene"
1098
category = "3D Rendering"
1099
wasm = true
1100
1101
[[example]]
1102
name = "lines"
1103
path = "examples/3d/lines.rs"
1104
doc-scrape-examples = true
1105
1106
[package.metadata.example.lines]
1107
name = "Lines"
1108
description = "Create a custom material to draw 3d lines"
1109
category = "3D Rendering"
1110
# Wasm does not support the `POLYGON_MODE_LINE` feature.
1111
wasm = false
1112
1113
[[example]]
1114
name = "ssao"
1115
path = "examples/3d/ssao.rs"
1116
doc-scrape-examples = true
1117
1118
[package.metadata.example.ssao]
1119
name = "Screen Space Ambient Occlusion"
1120
description = "A scene showcasing screen space ambient occlusion"
1121
category = "3D Rendering"
1122
# Requires compute shaders, which are not supported by WebGL.
1123
wasm = false
1124
1125
[[example]]
1126
name = "spotlight"
1127
path = "examples/3d/spotlight.rs"
1128
doc-scrape-examples = true
1129
1130
[package.metadata.example.spotlight]
1131
name = "Spotlight"
1132
description = "Illustrates spot lights"
1133
category = "3D Rendering"
1134
wasm = true
1135
1136
[[example]]
1137
name = "bloom_3d"
1138
path = "examples/3d/bloom_3d.rs"
1139
doc-scrape-examples = true
1140
1141
[package.metadata.example.bloom_3d]
1142
name = "3D Bloom"
1143
description = "Illustrates bloom configuration using HDR and emissive materials"
1144
category = "3D Rendering"
1145
wasm = true
1146
1147
[[example]]
1148
name = "decal"
1149
path = "examples/3d/decal.rs"
1150
doc-scrape-examples = true
1151
1152
[package.metadata.example.decal]
1153
name = "Decal"
1154
description = "Decal rendering"
1155
category = "3D Rendering"
1156
wasm = true
1157
1158
[[example]]
1159
name = "deferred_rendering"
1160
path = "examples/3d/deferred_rendering.rs"
1161
doc-scrape-examples = true
1162
1163
[package.metadata.example.deferred_rendering]
1164
name = "Deferred Rendering"
1165
description = "Renders meshes with both forward and deferred pipelines"
1166
category = "3D Rendering"
1167
wasm = true
1168
1169
[[example]]
1170
name = "motion_blur"
1171
path = "examples/3d/motion_blur.rs"
1172
doc-scrape-examples = true
1173
1174
[package.metadata.example.motion_blur]
1175
name = "Motion Blur"
1176
description = "Demonstrates per-pixel motion blur"
1177
category = "3D Rendering"
1178
wasm = true
1179
1180
[[example]]
1181
name = "order_independent_transparency"
1182
path = "examples/3d/order_independent_transparency.rs"
1183
doc-scrape-examples = true
1184
1185
[package.metadata.example.order_independent_transparency]
1186
name = "Order Independent Transparency"
1187
description = "Demonstrates how to use OIT"
1188
category = "3D Rendering"
1189
# Not supported by WebGL
1190
wasm = false
1191
1192
[[example]]
1193
name = "tonemapping"
1194
path = "examples/3d/tonemapping.rs"
1195
doc-scrape-examples = true
1196
1197
[package.metadata.example.tonemapping]
1198
name = "Tonemapping"
1199
description = "Compares tonemapping options"
1200
category = "3D Rendering"
1201
wasm = true
1202
1203
[[example]]
1204
name = "orthographic"
1205
path = "examples/3d/orthographic.rs"
1206
doc-scrape-examples = true
1207
1208
[package.metadata.example.orthographic]
1209
name = "Orthographic View"
1210
description = "Shows how to create a 3D orthographic view (for isometric-look in games or CAD applications)"
1211
category = "3D Rendering"
1212
wasm = true
1213
1214
[[example]]
1215
name = "parenting"
1216
path = "examples/3d/parenting.rs"
1217
doc-scrape-examples = true
1218
1219
[package.metadata.example.parenting]
1220
name = "Parenting"
1221
description = "Demonstrates parent->child relationships and relative transformations"
1222
category = "3D Rendering"
1223
wasm = true
1224
1225
[[example]]
1226
name = "pbr"
1227
path = "examples/3d/pbr.rs"
1228
doc-scrape-examples = true
1229
1230
[package.metadata.example.pbr]
1231
name = "Physically Based Rendering"
1232
description = "Demonstrates use of Physically Based Rendering (PBR) properties"
1233
category = "3D Rendering"
1234
wasm = true
1235
1236
[[example]]
1237
name = "parallax_mapping"
1238
path = "examples/3d/parallax_mapping.rs"
1239
doc-scrape-examples = true
1240
1241
[package.metadata.example.parallax_mapping]
1242
name = "Parallax Mapping"
1243
description = "Demonstrates use of a normal map and depth map for parallax mapping"
1244
category = "3D Rendering"
1245
wasm = true
1246
1247
[[example]]
1248
name = "render_to_texture"
1249
path = "examples/3d/render_to_texture.rs"
1250
doc-scrape-examples = true
1251
1252
[package.metadata.example.render_to_texture]
1253
name = "Render to Texture"
1254
description = "Shows how to render to a texture, useful for mirrors, UI, or exporting images"
1255
category = "3D Rendering"
1256
wasm = true
1257
1258
[[example]]
1259
name = "shadow_biases"
1260
path = "examples/3d/shadow_biases.rs"
1261
doc-scrape-examples = true
1262
1263
[package.metadata.example.shadow_biases]
1264
name = "Shadow Biases"
1265
description = "Demonstrates how shadow biases affect shadows in a 3d scene"
1266
category = "3D Rendering"
1267
wasm = true
1268
1269
[[example]]
1270
name = "shadow_caster_receiver"
1271
path = "examples/3d/shadow_caster_receiver.rs"
1272
doc-scrape-examples = true
1273
1274
[package.metadata.example.shadow_caster_receiver]
1275
name = "Shadow Caster and Receiver"
1276
description = "Demonstrates how to prevent meshes from casting/receiving shadows in a 3d scene"
1277
category = "3D Rendering"
1278
wasm = true
1279
1280
[[example]]
1281
name = "skybox"
1282
path = "examples/3d/skybox.rs"
1283
doc-scrape-examples = true
1284
1285
[package.metadata.example.skybox]
1286
name = "Skybox"
1287
description = "Load a cubemap texture onto a cube like a skybox and cycle through different compressed texture formats."
1288
category = "3D Rendering"
1289
wasm = true
1290
1291
[[example]]
1292
name = "solari"
1293
path = "examples/3d/solari.rs"
1294
doc-scrape-examples = true
1295
required-features = ["bevy_solari", "https"]
1296
1297
[package.metadata.example.solari]
1298
name = "Solari"
1299
description = "Demonstrates realtime dynamic raytraced lighting using Bevy Solari."
1300
category = "3D Rendering"
1301
wasm = false # Raytracing is not supported on the web
1302
1303
[[example]]
1304
name = "spherical_area_lights"
1305
path = "examples/3d/spherical_area_lights.rs"
1306
doc-scrape-examples = true
1307
1308
[package.metadata.example.spherical_area_lights]
1309
name = "Spherical Area Lights"
1310
description = "Demonstrates how point light radius values affect light behavior"
1311
category = "3D Rendering"
1312
wasm = true
1313
1314
[[example]]
1315
name = "split_screen"
1316
path = "examples/3d/split_screen.rs"
1317
doc-scrape-examples = true
1318
1319
[package.metadata.example.split_screen]
1320
name = "Split Screen"
1321
description = "Demonstrates how to render two cameras to the same window to accomplish \"split screen\""
1322
category = "3D Rendering"
1323
wasm = true
1324
1325
[[example]]
1326
name = "texture"
1327
path = "examples/3d/texture.rs"
1328
doc-scrape-examples = true
1329
1330
[package.metadata.example.texture]
1331
name = "Texture"
1332
description = "Shows configuration of texture materials"
1333
category = "3D Rendering"
1334
wasm = true
1335
1336
[[example]]
1337
name = "transparency_3d"
1338
path = "examples/3d/transparency_3d.rs"
1339
doc-scrape-examples = true
1340
1341
[package.metadata.example.transparency_3d]
1342
name = "Transparency in 3D"
1343
description = "Demonstrates transparency in 3d"
1344
category = "3D Rendering"
1345
wasm = true
1346
1347
[[example]]
1348
name = "transmission"
1349
path = "examples/3d/transmission.rs"
1350
doc-scrape-examples = true
1351
1352
[package.metadata.example.transmission]
1353
name = "Transmission"
1354
description = "Showcases light transmission in the PBR material"
1355
category = "3D Rendering"
1356
wasm = true
1357
1358
[[example]]
1359
name = "two_passes"
1360
path = "examples/3d/two_passes.rs"
1361
doc-scrape-examples = true
1362
1363
[package.metadata.example.two_passes]
1364
name = "Two Passes"
1365
description = "Renders two 3d passes to the same window from different perspectives"
1366
category = "3D Rendering"
1367
wasm = true
1368
1369
[[example]]
1370
name = "vertex_colors"
1371
path = "examples/3d/vertex_colors.rs"
1372
doc-scrape-examples = true
1373
1374
[package.metadata.example.vertex_colors]
1375
name = "Vertex Colors"
1376
description = "Shows the use of vertex colors"
1377
category = "3D Rendering"
1378
wasm = true
1379
1380
[[example]]
1381
name = "wireframe"
1382
path = "examples/3d/wireframe.rs"
1383
doc-scrape-examples = true
1384
1385
[package.metadata.example.wireframe]
1386
name = "Wireframe"
1387
description = "Showcases wireframe rendering"
1388
category = "3D Rendering"
1389
# Not supported on WebGL
1390
wasm = false
1391
1392
[[example]]
1393
name = "irradiance_volumes"
1394
path = "examples/3d/irradiance_volumes.rs"
1395
doc-scrape-examples = true
1396
1397
[package.metadata.example.irradiance_volumes]
1398
name = "Irradiance Volumes"
1399
description = "Demonstrates irradiance volumes"
1400
category = "3D Rendering"
1401
# On WebGL and WebGPU, the number of texture bindings is too low
1402
# See <https://github.com/bevyengine/bevy/issues/11885>
1403
wasm = false
1404
1405
[[example]]
1406
name = "meshlet"
1407
path = "examples/3d/meshlet.rs"
1408
doc-scrape-examples = true
1409
required-features = ["meshlet", "https"]
1410
1411
[package.metadata.example.meshlet]
1412
name = "Meshlet"
1413
description = "Meshlet rendering for dense high-poly scenes (experimental)"
1414
category = "3D Rendering"
1415
# Requires compute shaders and WGPU extensions, not supported by WebGL nor WebGPU.
1416
wasm = false
1417
1418
[[example]]
1419
name = "mesh_ray_cast"
1420
path = "examples/3d/mesh_ray_cast.rs"
1421
doc-scrape-examples = true
1422
1423
[package.metadata.example.mesh_ray_cast]
1424
name = "Mesh Ray Cast"
1425
description = "Demonstrates ray casting with the `MeshRayCast` system parameter"
1426
category = "3D Rendering"
1427
wasm = true
1428
1429
[[example]]
1430
name = "lightmaps"
1431
path = "examples/3d/lightmaps.rs"
1432
doc-scrape-examples = true
1433
1434
[package.metadata.example.lightmaps]
1435
name = "Lightmaps"
1436
description = "Rendering a scene with baked lightmaps"
1437
category = "3D Rendering"
1438
wasm = true
1439
1440
[[example]]
1441
name = "no_prepass"
1442
path = "tests/3d/no_prepass.rs"
1443
doc-scrape-examples = true
1444
1445
[package.metadata.example.no_prepass]
1446
hidden = true
1447
1448
# Animation
1449
[[example]]
1450
name = "animation_events"
1451
path = "examples/animation/animation_events.rs"
1452
doc-scrape-examples = true
1453
1454
[package.metadata.example.animation_events]
1455
name = "Animation Events"
1456
description = "Demonstrate how to use animation events"
1457
category = "Animation"
1458
wasm = true
1459
1460
[[example]]
1461
name = "animated_mesh"
1462
path = "examples/animation/animated_mesh.rs"
1463
doc-scrape-examples = true
1464
1465
[package.metadata.example.animated_mesh]
1466
name = "Animated Mesh"
1467
description = "Plays an animation on a skinned glTF model of a fox"
1468
category = "Animation"
1469
wasm = true
1470
1471
[[example]]
1472
name = "animated_mesh_control"
1473
path = "examples/animation/animated_mesh_control.rs"
1474
doc-scrape-examples = true
1475
1476
[package.metadata.example.animated_mesh_control]
1477
name = "Animated Mesh Control"
1478
description = "Plays an animation from a skinned glTF with keyboard controls"
1479
category = "Animation"
1480
wasm = true
1481
1482
[[example]]
1483
name = "animated_mesh_events"
1484
path = "examples/animation/animated_mesh_events.rs"
1485
doc-scrape-examples = true
1486
1487
[package.metadata.example.animated_mesh_events]
1488
name = "Animated Mesh Events"
1489
description = "Plays an animation from a skinned glTF with events"
1490
category = "Animation"
1491
wasm = true
1492
1493
[[example]]
1494
name = "animation_graph"
1495
path = "examples/animation/animation_graph.rs"
1496
doc-scrape-examples = true
1497
1498
[package.metadata.example.animation_graph]
1499
name = "Animation Graph"
1500
description = "Blends multiple animations together with a graph"
1501
category = "Animation"
1502
wasm = true
1503
1504
[[example]]
1505
name = "morph_targets"
1506
path = "examples/animation/morph_targets.rs"
1507
doc-scrape-examples = true
1508
1509
[package.metadata.example.morph_targets]
1510
name = "Morph Targets"
1511
description = "Plays an animation from a glTF file with meshes with morph targets"
1512
category = "Animation"
1513
wasm = true
1514
1515
[[example]]
1516
name = "animated_transform"
1517
path = "examples/animation/animated_transform.rs"
1518
doc-scrape-examples = true
1519
1520
[package.metadata.example.animated_transform]
1521
name = "Animated Transform"
1522
description = "Create and play an animation defined by code that operates on the `Transform` component"
1523
category = "Animation"
1524
wasm = true
1525
1526
[[example]]
1527
name = "color_animation"
1528
path = "examples/animation/color_animation.rs"
1529
doc-scrape-examples = true
1530
1531
[package.metadata.example.color_animation]
1532
name = "Color animation"
1533
description = "Demonstrates how to animate colors using mixing and splines in different color spaces"
1534
category = "Animation"
1535
wasm = true
1536
1537
[[example]]
1538
name = "eased_motion"
1539
path = "examples/animation/eased_motion.rs"
1540
doc-scrape-examples = true
1541
1542
[package.metadata.example.eased_motion]
1543
name = "Eased Motion"
1544
description = "Demonstrates the application of easing curves to animate an object"
1545
category = "Animation"
1546
wasm = true
1547
1548
[[example]]
1549
name = "easing_functions"
1550
path = "examples/animation/easing_functions.rs"
1551
doc-scrape-examples = true
1552
1553
[package.metadata.example.easing_functions]
1554
name = "Easing Functions"
1555
description = "Showcases the built-in easing functions"
1556
category = "Animation"
1557
wasm = true
1558
1559
[[example]]
1560
name = "custom_skinned_mesh"
1561
path = "examples/animation/custom_skinned_mesh.rs"
1562
doc-scrape-examples = true
1563
1564
[package.metadata.example.custom_skinned_mesh]
1565
name = "Custom Skinned Mesh"
1566
description = "Skinned mesh example with mesh and joints data defined in code"
1567
category = "Animation"
1568
wasm = true
1569
1570
# Application
1571
[[example]]
1572
name = "custom_loop"
1573
path = "examples/app/custom_loop.rs"
1574
doc-scrape-examples = true
1575
1576
[package.metadata.example.custom_loop]
1577
name = "Custom Loop"
1578
description = "Demonstrates how to create a custom runner (to update an app manually)"
1579
category = "Application"
1580
# Doesn't render anything, doesn't create a canvas
1581
wasm = false
1582
1583
[[example]]
1584
name = "drag_and_drop"
1585
path = "examples/app/drag_and_drop.rs"
1586
doc-scrape-examples = true
1587
1588
[package.metadata.example.drag_and_drop]
1589
name = "Drag and Drop"
1590
description = "An example that shows how to handle drag and drop in an app"
1591
category = "Application"
1592
# Browser drag and drop is not supported
1593
wasm = false
1594
1595
[[example]]
1596
name = "empty"
1597
path = "examples/app/empty.rs"
1598
doc-scrape-examples = true
1599
1600
[package.metadata.example.empty]
1601
name = "Empty"
1602
description = "An empty application (does nothing)"
1603
category = "Application"
1604
# Doesn't render anything, doesn't create a canvas
1605
wasm = false
1606
1607
[[example]]
1608
name = "empty_defaults"
1609
path = "examples/app/empty_defaults.rs"
1610
doc-scrape-examples = true
1611
1612
[package.metadata.example.empty_defaults]
1613
name = "Empty with Defaults"
1614
description = "An empty application with default plugins"
1615
category = "Application"
1616
wasm = true
1617
1618
[[example]]
1619
name = "headless"
1620
path = "examples/app/headless.rs"
1621
doc-scrape-examples = true
1622
required-features = ["bevy_log"]
1623
1624
[package.metadata.example.headless]
1625
name = "Headless"
1626
description = "An application that runs without default plugins"
1627
category = "Application"
1628
# Doesn't render anything, doesn't create a canvas
1629
wasm = false
1630
1631
[[example]]
1632
name = "logs"
1633
path = "examples/app/logs.rs"
1634
doc-scrape-examples = true
1635
1636
[package.metadata.example.logs]
1637
name = "Logs"
1638
description = "Illustrate how to use generate log output"
1639
category = "Application"
1640
wasm = true
1641
1642
[[example]]
1643
name = "log_layers"
1644
path = "examples/app/log_layers.rs"
1645
doc-scrape-examples = true
1646
1647
[package.metadata.example.log_layers]
1648
name = "Log layers"
1649
description = "Illustrate how to add custom log layers"
1650
category = "Application"
1651
# Accesses `time`, which is not available on the web
1652
# Also doesn't render anything
1653
wasm = false
1654
1655
[[example]]
1656
name = "log_layers_ecs"
1657
path = "examples/app/log_layers_ecs.rs"
1658
doc-scrape-examples = true
1659
1660
[package.metadata.example.log_layers_ecs]
1661
name = "Advanced log layers"
1662
description = "Illustrate how to transfer data between log layers and Bevy's ECS"
1663
category = "Application"
1664
# Doesn't render anything, doesn't create a canvas
1665
wasm = false
1666
1667
[[example]]
1668
name = "plugin"
1669
path = "examples/app/plugin.rs"
1670
doc-scrape-examples = true
1671
1672
[package.metadata.example.plugin]
1673
name = "Plugin"
1674
description = "Demonstrates the creation and registration of a custom plugin"
1675
category = "Application"
1676
wasm = true
1677
1678
[[example]]
1679
name = "plugin_group"
1680
path = "examples/app/plugin_group.rs"
1681
doc-scrape-examples = true
1682
1683
[package.metadata.example.plugin_group]
1684
name = "Plugin Group"
1685
description = "Demonstrates the creation and registration of a custom plugin group"
1686
category = "Application"
1687
wasm = true
1688
1689
[[example]]
1690
name = "return_after_run"
1691
path = "examples/app/return_after_run.rs"
1692
doc-scrape-examples = true
1693
1694
[package.metadata.example.return_after_run]
1695
name = "Return after Run"
1696
description = "Show how to return to main after the Bevy app has exited"
1697
category = "Application"
1698
wasm = false
1699
1700
[[example]]
1701
name = "thread_pool_resources"
1702
path = "examples/app/thread_pool_resources.rs"
1703
doc-scrape-examples = true
1704
1705
[package.metadata.example.thread_pool_resources]
1706
name = "Thread Pool Resources"
1707
description = "Creates and customizes the internal thread pool"
1708
category = "Application"
1709
wasm = false
1710
1711
[[example]]
1712
name = "no_renderer"
1713
path = "examples/app/no_renderer.rs"
1714
doc-scrape-examples = true
1715
1716
[package.metadata.example.no_renderer]
1717
name = "No Renderer"
1718
description = "An application that runs with default plugins and displays an empty window, but without an actual renderer"
1719
category = "Application"
1720
wasm = false
1721
1722
[[example]]
1723
name = "headless_renderer"
1724
path = "examples/app/headless_renderer.rs"
1725
doc-scrape-examples = true
1726
1727
[package.metadata.example.headless_renderer]
1728
name = "Headless Renderer"
1729
description = "An application that runs with no window, but renders into image file"
1730
category = "Application"
1731
wasm = false
1732
1733
[[example]]
1734
name = "without_winit"
1735
path = "examples/app/without_winit.rs"
1736
doc-scrape-examples = true
1737
1738
[package.metadata.example.without_winit]
1739
name = "Without Winit"
1740
description = "Create an application without winit (runs single time, no event loop)"
1741
category = "Application"
1742
wasm = false
1743
1744
# Assets
1745
[[example]]
1746
name = "alter_mesh"
1747
path = "examples/asset/alter_mesh.rs"
1748
doc-scrape-examples = true
1749
1750
[package.metadata.example.alter_mesh]
1751
name = "Alter Mesh"
1752
description = "Shows how to modify the underlying asset of a Mesh after spawning."
1753
category = "Assets"
1754
wasm = false
1755
1756
[[example]]
1757
name = "alter_sprite"
1758
path = "examples/asset/alter_sprite.rs"
1759
doc-scrape-examples = true
1760
1761
[package.metadata.example.alter_sprite]
1762
name = "Alter Sprite"
1763
description = "Shows how to modify texture assets after spawning."
1764
category = "Assets"
1765
wasm = false
1766
1767
[[example]]
1768
name = "asset_loading"
1769
path = "examples/asset/asset_loading.rs"
1770
doc-scrape-examples = true
1771
1772
[package.metadata.example.asset_loading]
1773
name = "Asset Loading"
1774
description = "Demonstrates various methods to load assets"
1775
category = "Assets"
1776
wasm = false
1777
1778
[[example]]
1779
name = "asset_settings"
1780
path = "examples/asset/asset_settings.rs"
1781
doc-scrape-examples = true
1782
1783
[package.metadata.example.asset_settings]
1784
name = "Asset Settings"
1785
description = "Demonstrates various methods of applying settings when loading an asset"
1786
category = "Assets"
1787
wasm = false
1788
1789
[[example]]
1790
name = "asset_decompression"
1791
path = "examples/asset/asset_decompression.rs"
1792
doc-scrape-examples = true
1793
1794
[package.metadata.example.asset_decompression]
1795
name = "Asset Decompression"
1796
description = "Demonstrates loading a compressed asset"
1797
category = "Assets"
1798
wasm = false
1799
1800
[[example]]
1801
name = "custom_asset"
1802
path = "examples/asset/custom_asset.rs"
1803
doc-scrape-examples = true
1804
1805
[package.metadata.example.custom_asset]
1806
name = "Custom Asset"
1807
description = "Implements a custom asset loader"
1808
category = "Assets"
1809
wasm = true
1810
1811
[[example]]
1812
name = "custom_asset_reader"
1813
path = "examples/asset/custom_asset_reader.rs"
1814
doc-scrape-examples = true
1815
1816
[package.metadata.example.custom_asset_reader]
1817
name = "Custom Asset IO"
1818
description = "Implements a custom AssetReader"
1819
category = "Assets"
1820
# Incompatible with the asset path patching of the example-showcase tool
1821
wasm = false
1822
1823
[[example]]
1824
name = "embedded_asset"
1825
path = "examples/asset/embedded_asset.rs"
1826
doc-scrape-examples = true
1827
1828
[package.metadata.example.embedded_asset]
1829
name = "Embedded Asset"
1830
description = "Embed an asset in the application binary and load it"
1831
category = "Assets"
1832
wasm = true
1833
1834
[[example]]
1835
name = "extra_asset_source"
1836
path = "examples/asset/extra_source.rs"
1837
doc-scrape-examples = true
1838
1839
[package.metadata.example.extra_asset_source]
1840
name = "Extra Asset Source"
1841
description = "Load an asset from a non-standard asset source"
1842
category = "Assets"
1843
# Uses non-standard asset path
1844
wasm = false
1845
1846
[[example]]
1847
name = "web_asset"
1848
path = "examples/asset/web_asset.rs"
1849
doc-scrape-examples = true
1850
required-features = ["https"]
1851
1852
[package.metadata.example.web_asset]
1853
name = "Web Asset"
1854
description = "Load an asset from the web"
1855
category = "Assets"
1856
wasm = true
1857
1858
[[example]]
1859
name = "hot_asset_reloading"
1860
path = "examples/asset/hot_asset_reloading.rs"
1861
doc-scrape-examples = true
1862
required-features = ["file_watcher"]
1863
1864
[package.metadata.example.hot_asset_reloading]
1865
name = "Hot Reloading of Assets"
1866
description = "Demonstrates automatic reloading of assets when modified on disk"
1867
category = "Assets"
1868
wasm = false
1869
1870
[[example]]
1871
name = "asset_processing"
1872
path = "examples/asset/processing/asset_processing.rs"
1873
doc-scrape-examples = true
1874
required-features = ["file_watcher", "asset_processor"]
1875
1876
[package.metadata.example.asset_processing]
1877
name = "Asset Processing"
1878
description = "Demonstrates how to process and load custom assets"
1879
category = "Assets"
1880
wasm = false
1881
1882
[[example]]
1883
name = "repeated_texture"
1884
path = "examples/asset/repeated_texture.rs"
1885
doc-scrape-examples = true
1886
1887
[package.metadata.example.repeated_texture]
1888
name = "Repeated texture configuration"
1889
description = "How to configure the texture to repeat instead of the default clamp to edges"
1890
category = "Assets"
1891
wasm = true
1892
1893
# Assets
1894
[[example]]
1895
name = "multi_asset_sync"
1896
path = "examples/asset/multi_asset_sync.rs"
1897
doc-scrape-examples = true
1898
1899
[package.metadata.example.multi_asset_sync]
1900
name = "Multi-asset synchronization"
1901
description = "Demonstrates how to wait for multiple assets to be loaded."
1902
category = "Assets"
1903
wasm = true
1904
1905
# Async Tasks
1906
[[example]]
1907
name = "async_compute"
1908
path = "examples/async_tasks/async_compute.rs"
1909
doc-scrape-examples = true
1910
1911
[package.metadata.example.async_compute]
1912
name = "Async Compute"
1913
description = "How to use `AsyncComputeTaskPool` to complete longer running tasks"
1914
category = "Async Tasks"
1915
wasm = false
1916
1917
[[example]]
1918
name = "external_source_external_thread"
1919
path = "examples/async_tasks/external_source_external_thread.rs"
1920
doc-scrape-examples = true
1921
1922
[package.metadata.example.external_source_external_thread]
1923
name = "External Source of Data on an External Thread"
1924
description = "How to use an external thread to run an infinite task and communicate with a channel"
1925
category = "Async Tasks"
1926
wasm = false
1927
1928
# Audio
1929
[[example]]
1930
name = "audio"
1931
path = "examples/audio/audio.rs"
1932
doc-scrape-examples = true
1933
1934
[package.metadata.example.audio]
1935
name = "Audio"
1936
description = "Shows how to load and play an audio file"
1937
category = "Audio"
1938
wasm = true
1939
1940
[[example]]
1941
name = "audio_control"
1942
path = "examples/audio/audio_control.rs"
1943
doc-scrape-examples = true
1944
1945
[package.metadata.example.audio_control]
1946
name = "Audio Control"
1947
description = "Shows how to load and play an audio file, and control how it's played"
1948
category = "Audio"
1949
wasm = true
1950
1951
[[example]]
1952
name = "decodable"
1953
path = "examples/audio/decodable.rs"
1954
doc-scrape-examples = true
1955
1956
[package.metadata.example.decodable]
1957
name = "Decodable"
1958
description = "Shows how to create and register a custom audio source by implementing the `Decodable` type."
1959
category = "Audio"
1960
wasm = true
1961
1962
[[example]]
1963
name = "soundtrack"
1964
path = "examples/audio/soundtrack.rs"
1965
doc-scrape-examples = true
1966
1967
[package.metadata.example.soundtrack]
1968
name = "Soundtrack"
1969
description = "Shows how to play different soundtracks based on game state"
1970
category = "Audio"
1971
wasm = true
1972
1973
[[example]]
1974
name = "spatial_audio_2d"
1975
path = "examples/audio/spatial_audio_2d.rs"
1976
doc-scrape-examples = true
1977
1978
[package.metadata.example.spatial_audio_2d]
1979
name = "Spatial Audio 2D"
1980
description = "Shows how to play spatial audio, and moving the emitter in 2D"
1981
category = "Audio"
1982
wasm = true
1983
1984
[[example]]
1985
name = "spatial_audio_3d"
1986
path = "examples/audio/spatial_audio_3d.rs"
1987
doc-scrape-examples = true
1988
1989
[package.metadata.example.spatial_audio_3d]
1990
name = "Spatial Audio 3D"
1991
description = "Shows how to play spatial audio, and moving the emitter in 3D"
1992
category = "Audio"
1993
wasm = true
1994
1995
[[example]]
1996
name = "pitch"
1997
path = "examples/audio/pitch.rs"
1998
doc-scrape-examples = true
1999
2000
[package.metadata.example.pitch]
2001
name = "Pitch"
2002
description = "Shows how to directly play a simple pitch"
2003
category = "Audio"
2004
wasm = true
2005
2006
# Diagnostics
2007
[[example]]
2008
name = "log_diagnostics"
2009
path = "examples/diagnostics/log_diagnostics.rs"
2010
doc-scrape-examples = true
2011
2012
[package.metadata.example.log_diagnostics]
2013
name = "Log Diagnostics"
2014
description = "Add a plugin that logs diagnostics, like frames per second (FPS), to the console"
2015
category = "Diagnostics"
2016
wasm = true
2017
2018
[[example]]
2019
name = "custom_diagnostic"
2020
path = "examples/diagnostics/custom_diagnostic.rs"
2021
doc-scrape-examples = true
2022
2023
[package.metadata.example.custom_diagnostic]
2024
name = "Custom Diagnostic"
2025
description = "Shows how to create a custom diagnostic"
2026
category = "Diagnostics"
2027
wasm = true
2028
2029
[[example]]
2030
name = "enabling_disabling_diagnostic"
2031
path = "examples/diagnostics/enabling_disabling_diagnostic.rs"
2032
doc-scrape-examples = true
2033
2034
[package.metadata.example.enabling_disabling_diagnostic]
2035
name = "Enabling/disabling diagnostic"
2036
description = "Shows how to disable/re-enable a Diagnostic during runtime"
2037
category = "Diagnostics"
2038
wasm = true
2039
2040
# ECS (Entity Component System)
2041
[[example]]
2042
name = "ecs_guide"
2043
path = "examples/ecs/ecs_guide.rs"
2044
doc-scrape-examples = true
2045
2046
[package.metadata.example.ecs_guide]
2047
name = "ECS Guide"
2048
description = "Full guide to Bevy's ECS"
2049
category = "ECS (Entity Component System)"
2050
wasm = false
2051
2052
[[example]]
2053
name = "change_detection"
2054
path = "examples/ecs/change_detection.rs"
2055
doc-scrape-examples = true
2056
required-features = ["track_location"]
2057
2058
[package.metadata.example.change_detection]
2059
name = "Change Detection"
2060
description = "Change detection on components and resources"
2061
category = "ECS (Entity Component System)"
2062
wasm = false
2063
2064
[[example]]
2065
name = "component_hooks"
2066
path = "examples/ecs/component_hooks.rs"
2067
doc-scrape-examples = true
2068
2069
[package.metadata.example.component_hooks]
2070
name = "Component Hooks"
2071
description = "Define component hooks to manage component lifecycle events"
2072
category = "ECS (Entity Component System)"
2073
wasm = false
2074
2075
[[example]]
2076
name = "custom_schedule"
2077
path = "examples/ecs/custom_schedule.rs"
2078
doc-scrape-examples = true
2079
2080
[package.metadata.example.custom_schedule]
2081
name = "Custom Schedule"
2082
description = "Demonstrates how to add custom schedules"
2083
category = "ECS (Entity Component System)"
2084
wasm = false
2085
2086
[[example]]
2087
name = "custom_query_param"
2088
path = "examples/ecs/custom_query_param.rs"
2089
doc-scrape-examples = true
2090
2091
[package.metadata.example.custom_query_param]
2092
name = "Custom Query Parameters"
2093
description = "Groups commonly used compound queries and query filters into a single type"
2094
category = "ECS (Entity Component System)"
2095
wasm = false
2096
2097
[[example]]
2098
name = "dynamic"
2099
path = "examples/ecs/dynamic.rs"
2100
doc-scrape-examples = true
2101
required-features = ["debug"]
2102
2103
[package.metadata.example.dynamic]
2104
name = "Dynamic ECS"
2105
description = "Dynamically create components, spawn entities with those components and query those components"
2106
category = "ECS (Entity Component System)"
2107
wasm = false
2108
2109
[[example]]
2110
name = "message"
2111
path = "examples/ecs/message.rs"
2112
doc-scrape-examples = true
2113
2114
[package.metadata.example.message]
2115
name = "Message"
2116
description = "Illustrates message creation, activation, and reception"
2117
category = "ECS (Entity Component System)"
2118
wasm = false
2119
2120
[[example]]
2121
name = "send_and_receive_messages"
2122
path = "examples/ecs/send_and_receive_messages.rs"
2123
doc-scrape-examples = true
2124
2125
[package.metadata.example.send_and_receive_messages]
2126
name = "Send and receive messages"
2127
description = "Demonstrates how to send and receive messages of the same type in a single system"
2128
category = "ECS (Entity Component System)"
2129
wasm = false
2130
2131
[[example]]
2132
name = "entity_disabling"
2133
path = "examples/ecs/entity_disabling.rs"
2134
doc-scrape-examples = true
2135
2136
[package.metadata.example.entity_disabling]
2137
name = "Entity disabling"
2138
description = "Demonstrates how to hide entities from the ECS without deleting them"
2139
category = "ECS (Entity Component System)"
2140
wasm = true
2141
2142
[[example]]
2143
name = "fixed_timestep"
2144
path = "examples/ecs/fixed_timestep.rs"
2145
doc-scrape-examples = true
2146
2147
[package.metadata.example.fixed_timestep]
2148
name = "Fixed Timestep"
2149
description = "Shows how to create systems that run every fixed timestep, rather than every tick"
2150
category = "ECS (Entity Component System)"
2151
wasm = false
2152
2153
[[example]]
2154
name = "generic_system"
2155
path = "examples/ecs/generic_system.rs"
2156
doc-scrape-examples = true
2157
2158
[package.metadata.example.generic_system]
2159
name = "Generic System"
2160
description = "Shows how to create systems that can be reused with different types"
2161
category = "ECS (Entity Component System)"
2162
wasm = false
2163
2164
[[example]]
2165
name = "hierarchy"
2166
path = "examples/ecs/hierarchy.rs"
2167
doc-scrape-examples = true
2168
2169
[package.metadata.example.hierarchy]
2170
name = "Hierarchy"
2171
description = "Creates a hierarchy of parents and children entities"
2172
category = "ECS (Entity Component System)"
2173
wasm = false
2174
2175
[[example]]
2176
name = "immutable_components"
2177
path = "examples/ecs/immutable_components.rs"
2178
doc-scrape-examples = true
2179
2180
[package.metadata.example.immutable_components]
2181
name = "Immutable Components"
2182
description = "Demonstrates the creation and utility of immutable components"
2183
category = "ECS (Entity Component System)"
2184
wasm = false
2185
2186
[[example]]
2187
name = "iter_combinations"
2188
path = "examples/ecs/iter_combinations.rs"
2189
doc-scrape-examples = true
2190
2191
[package.metadata.example.iter_combinations]
2192
name = "Iter Combinations"
2193
description = "Shows how to iterate over combinations of query results"
2194
category = "ECS (Entity Component System)"
2195
wasm = true
2196
2197
[[example]]
2198
name = "one_shot_systems"
2199
path = "examples/ecs/one_shot_systems.rs"
2200
doc-scrape-examples = true
2201
2202
[package.metadata.example.one_shot_systems]
2203
name = "One Shot Systems"
2204
description = "Shows how to flexibly run systems without scheduling them"
2205
category = "ECS (Entity Component System)"
2206
wasm = false
2207
2208
[[example]]
2209
name = "parallel_query"
2210
path = "examples/ecs/parallel_query.rs"
2211
doc-scrape-examples = true
2212
2213
[package.metadata.example.parallel_query]
2214
name = "Parallel Query"
2215
description = "Illustrates parallel queries with `ParallelIterator`"
2216
category = "ECS (Entity Component System)"
2217
wasm = false
2218
2219
[[example]]
2220
name = "relationships"
2221
path = "examples/ecs/relationships.rs"
2222
doc-scrape-examples = true
2223
2224
[package.metadata.example.relationships]
2225
name = "Relationships"
2226
description = "Define and work with custom relationships between entities"
2227
category = "ECS (Entity Component System)"
2228
wasm = false
2229
2230
[[example]]
2231
name = "removal_detection"
2232
path = "examples/ecs/removal_detection.rs"
2233
doc-scrape-examples = true
2234
2235
[package.metadata.example.removal_detection]
2236
name = "Removal Detection"
2237
description = "Query for entities that had a specific component removed earlier in the current frame"
2238
category = "ECS (Entity Component System)"
2239
wasm = false
2240
2241
[[example]]
2242
name = "run_conditions"
2243
path = "examples/ecs/run_conditions.rs"
2244
doc-scrape-examples = true
2245
2246
[package.metadata.example.run_conditions]
2247
name = "Run Conditions"
2248
description = "Run systems only when one or multiple conditions are met"
2249
category = "ECS (Entity Component System)"
2250
wasm = false
2251
2252
[[example]]
2253
name = "fallible_params"
2254
path = "examples/ecs/fallible_params.rs"
2255
doc-scrape-examples = true
2256
2257
[package.metadata.example.fallible_params]
2258
name = "Fallible System Parameters"
2259
description = "Systems are skipped if their parameters cannot be acquired"
2260
category = "ECS (Entity Component System)"
2261
wasm = false
2262
2263
[[example]]
2264
name = "error_handling"
2265
path = "examples/ecs/error_handling.rs"
2266
doc-scrape-examples = true
2267
required-features = ["bevy_mesh_picking_backend"]
2268
2269
[package.metadata.example.error_handling]
2270
name = "Error handling"
2271
description = "How to return and handle errors across the ECS"
2272
category = "ECS (Entity Component System)"
2273
wasm = false
2274
2275
[[example]]
2276
name = "startup_system"
2277
path = "examples/ecs/startup_system.rs"
2278
doc-scrape-examples = true
2279
2280
[package.metadata.example.startup_system]
2281
name = "Startup System"
2282
description = "Demonstrates a startup system (one that runs once when the app starts up)"
2283
category = "ECS (Entity Component System)"
2284
wasm = false
2285
2286
[[example]]
2287
name = "states"
2288
path = "examples/state/states.rs"
2289
doc-scrape-examples = true
2290
required-features = ["bevy_dev_tools"]
2291
2292
[package.metadata.example.states]
2293
name = "States"
2294
description = "Illustrates how to use States to control transitioning from a Menu state to an InGame state."
2295
category = "State"
2296
wasm = false
2297
2298
[[example]]
2299
name = "sub_states"
2300
path = "examples/state/sub_states.rs"
2301
doc-scrape-examples = true
2302
required-features = ["bevy_dev_tools"]
2303
2304
[package.metadata.example.sub_states]
2305
name = "Sub States"
2306
description = "Using Sub States for hierarchical state handling."
2307
category = "State"
2308
wasm = false
2309
2310
[[example]]
2311
name = "computed_states"
2312
path = "examples/state/computed_states.rs"
2313
doc-scrape-examples = true
2314
required-features = ["bevy_dev_tools"]
2315
2316
[package.metadata.example.computed_states]
2317
name = "Computed States"
2318
description = "Advanced state patterns using Computed States."
2319
category = "State"
2320
wasm = false
2321
2322
[[example]]
2323
name = "custom_transitions"
2324
path = "examples/state/custom_transitions.rs"
2325
doc-scrape-examples = true
2326
required-features = ["bevy_dev_tools"]
2327
2328
[package.metadata.example.custom_transitions]
2329
name = "Custom State Transition Behavior"
2330
description = "Creating and working with custom state transition schedules."
2331
category = "State"
2332
wasm = false
2333
2334
[[example]]
2335
name = "system_piping"
2336
path = "examples/ecs/system_piping.rs"
2337
doc-scrape-examples = true
2338
2339
[package.metadata.example.system_piping]
2340
name = "System Piping"
2341
description = "Pipe the output of one system into a second, allowing you to handle any errors gracefully"
2342
category = "ECS (Entity Component System)"
2343
wasm = false
2344
2345
[[example]]
2346
name = "state_scoped"
2347
path = "examples/ecs/state_scoped.rs"
2348
doc-scrape-examples = true
2349
2350
[package.metadata.example.state_scoped]
2351
name = "State Scoped"
2352
description = "Shows how to spawn entities that are automatically despawned either when entering or exiting specific game states."
2353
category = "ECS (Entity Component System)"
2354
wasm = false
2355
2356
[[example]]
2357
name = "system_closure"
2358
path = "examples/ecs/system_closure.rs"
2359
doc-scrape-examples = true
2360
2361
[package.metadata.example.system_closure]
2362
name = "System Closure"
2363
description = "Show how to use closures as systems, and how to configure `Local` variables by capturing external state"
2364
category = "ECS (Entity Component System)"
2365
wasm = false
2366
2367
[[example]]
2368
name = "system_param"
2369
path = "examples/ecs/system_param.rs"
2370
doc-scrape-examples = true
2371
2372
[package.metadata.example.system_param]
2373
name = "System Parameter"
2374
description = "Illustrates creating custom system parameters with `SystemParam`"
2375
category = "ECS (Entity Component System)"
2376
wasm = false
2377
2378
[[example]]
2379
name = "system_stepping"
2380
path = "examples/ecs/system_stepping.rs"
2381
doc-scrape-examples = true
2382
required-features = ["bevy_debug_stepping"]
2383
2384
[package.metadata.example.system_stepping]
2385
name = "System Stepping"
2386
description = "Demonstrate stepping through systems in order of execution."
2387
category = "ECS (Entity Component System)"
2388
wasm = false
2389
2390
# Time
2391
[[example]]
2392
name = "time"
2393
path = "examples/time/time.rs"
2394
doc-scrape-examples = true
2395
2396
[package.metadata.example.time]
2397
name = "Time handling"
2398
description = "Explains how Time is handled in ECS"
2399
category = "Time"
2400
wasm = false
2401
2402
[[example]]
2403
name = "virtual_time"
2404
path = "examples/time/virtual_time.rs"
2405
doc-scrape-examples = true
2406
2407
[package.metadata.example.virtual_time]
2408
name = "Virtual time"
2409
description = "Shows how `Time<Virtual>` can be used to pause, resume, slow down and speed up a game."
2410
category = "Time"
2411
wasm = false
2412
2413
[[example]]
2414
name = "timers"
2415
path = "examples/time/timers.rs"
2416
doc-scrape-examples = true
2417
2418
[package.metadata.example.timers]
2419
name = "Timers"
2420
description = "Illustrates ticking `Timer` resources inside systems and handling their state"
2421
category = "Time"
2422
wasm = false
2423
2424
2425
# Games
2426
[[example]]
2427
name = "alien_cake_addict"
2428
path = "examples/games/alien_cake_addict.rs"
2429
doc-scrape-examples = true
2430
2431
[package.metadata.example.alien_cake_addict]
2432
name = "Alien Cake Addict"
2433
description = "Eat the cakes. Eat them all. An example 3D game"
2434
category = "Games"
2435
wasm = true
2436
2437
[[example]]
2438
name = "breakout"
2439
path = "examples/games/breakout.rs"
2440
doc-scrape-examples = true
2441
2442
[package.metadata.example.breakout]
2443
name = "Breakout"
2444
description = "An implementation of the classic game \"Breakout\"."
2445
category = "Games"
2446
wasm = true
2447
2448
[[example]]
2449
name = "contributors"
2450
path = "examples/games/contributors.rs"
2451
doc-scrape-examples = true
2452
2453
[package.metadata.example.contributors]
2454
name = "Contributors"
2455
description = "Displays each contributor as a bouncy bevy-ball!"
2456
category = "Games"
2457
wasm = true
2458
2459
[[example]]
2460
name = "desk_toy"
2461
path = "examples/games/desk_toy.rs"
2462
doc-scrape-examples = true
2463
2464
[package.metadata.example.desk_toy]
2465
name = "Desk Toy"
2466
description = "Bevy logo as a desk toy using transparent windows! Now with Googly Eyes!"
2467
category = "Games"
2468
wasm = false
2469
2470
[[example]]
2471
name = "game_menu"
2472
path = "examples/games/game_menu.rs"
2473
doc-scrape-examples = true
2474
2475
[package.metadata.example.game_menu]
2476
name = "Game Menu"
2477
description = "A simple game menu"
2478
category = "Games"
2479
wasm = true
2480
2481
[[example]]
2482
name = "loading_screen"
2483
path = "examples/games/loading_screen.rs"
2484
doc-scrape-examples = true
2485
2486
[package.metadata.example.loading_screen]
2487
name = "Loading Screen"
2488
description = "Demonstrates how to create a loading screen that waits for all assets to be loaded and render pipelines to be compiled."
2489
category = "Games"
2490
wasm = true
2491
2492
# Input
2493
[[example]]
2494
name = "char_input_events"
2495
path = "examples/input/char_input_events.rs"
2496
doc-scrape-examples = true
2497
2498
[package.metadata.example.char_input_events]
2499
name = "Char Input Events"
2500
description = "Prints out all chars as they are inputted"
2501
category = "Input"
2502
wasm = false
2503
2504
[[example]]
2505
name = "gamepad_input"
2506
path = "examples/input/gamepad_input.rs"
2507
doc-scrape-examples = true
2508
2509
[package.metadata.example.gamepad_input]
2510
name = "Gamepad Input"
2511
description = "Shows handling of gamepad input, connections, and disconnections"
2512
category = "Input"
2513
wasm = false
2514
2515
[[example]]
2516
name = "gamepad_input_events"
2517
path = "examples/input/gamepad_input_events.rs"
2518
doc-scrape-examples = true
2519
2520
[package.metadata.example.gamepad_input_events]
2521
name = "Gamepad Input Events"
2522
description = "Iterates and prints gamepad input and connection events"
2523
category = "Input"
2524
wasm = false
2525
2526
[[example]]
2527
name = "gamepad_rumble"
2528
path = "examples/input/gamepad_rumble.rs"
2529
doc-scrape-examples = true
2530
2531
[package.metadata.example.gamepad_rumble]
2532
name = "Gamepad Rumble"
2533
description = "Shows how to rumble a gamepad using force feedback"
2534
category = "Input"
2535
wasm = false
2536
2537
[[example]]
2538
name = "keyboard_input"
2539
path = "examples/input/keyboard_input.rs"
2540
doc-scrape-examples = true
2541
2542
[package.metadata.example.keyboard_input]
2543
name = "Keyboard Input"
2544
description = "Demonstrates handling a key press/release"
2545
category = "Input"
2546
wasm = false
2547
2548
[[example]]
2549
name = "keyboard_modifiers"
2550
path = "examples/input/keyboard_modifiers.rs"
2551
doc-scrape-examples = true
2552
2553
[package.metadata.example.keyboard_modifiers]
2554
name = "Keyboard Modifiers"
2555
description = "Demonstrates using key modifiers (ctrl, shift)"
2556
category = "Input"
2557
wasm = false
2558
2559
[[example]]
2560
name = "keyboard_input_events"
2561
path = "examples/input/keyboard_input_events.rs"
2562
doc-scrape-examples = true
2563
2564
[package.metadata.example.keyboard_input_events]
2565
name = "Keyboard Input Events"
2566
description = "Prints out all keyboard events"
2567
category = "Input"
2568
wasm = false
2569
2570
[[example]]
2571
name = "mouse_input"
2572
path = "examples/input/mouse_input.rs"
2573
doc-scrape-examples = true
2574
2575
[package.metadata.example.mouse_input]
2576
name = "Mouse Input"
2577
description = "Demonstrates handling a mouse button press/release"
2578
category = "Input"
2579
wasm = false
2580
2581
[[example]]
2582
name = "mouse_input_events"
2583
path = "examples/input/mouse_input_events.rs"
2584
doc-scrape-examples = true
2585
2586
[package.metadata.example.mouse_input_events]
2587
name = "Mouse Input Events"
2588
description = "Prints out all mouse events (buttons, movement, etc.)"
2589
category = "Input"
2590
wasm = false
2591
2592
[[example]]
2593
name = "mouse_grab"
2594
path = "examples/input/mouse_grab.rs"
2595
doc-scrape-examples = true
2596
2597
[package.metadata.example.mouse_grab]
2598
name = "Mouse Grab"
2599
description = "Demonstrates how to grab the mouse, locking the cursor to the app's screen"
2600
category = "Input"
2601
wasm = false
2602
2603
[[example]]
2604
name = "touch_input"
2605
path = "examples/input/touch_input.rs"
2606
doc-scrape-examples = true
2607
2608
[package.metadata.example.touch_input]
2609
name = "Touch Input"
2610
description = "Displays touch presses, releases, and cancels"
2611
category = "Input"
2612
wasm = false
2613
2614
[[example]]
2615
name = "touch_input_events"
2616
path = "examples/input/touch_input_events.rs"
2617
doc-scrape-examples = true
2618
2619
[package.metadata.example.touch_input_events]
2620
name = "Touch Input Events"
2621
description = "Prints out all touch inputs"
2622
category = "Input"
2623
wasm = false
2624
2625
[[example]]
2626
name = "text_input"
2627
path = "examples/input/text_input.rs"
2628
doc-scrape-examples = true
2629
2630
[package.metadata.example.text_input]
2631
name = "Text Input"
2632
description = "Simple text input with IME support"
2633
category = "Input"
2634
wasm = false
2635
2636
# Reflection
2637
[[example]]
2638
name = "reflection"
2639
path = "examples/reflection/reflection.rs"
2640
doc-scrape-examples = true
2641
2642
[package.metadata.example.reflection]
2643
name = "Reflection"
2644
description = "Demonstrates how reflection in Bevy provides a way to dynamically interact with Rust types"
2645
category = "Reflection"
2646
wasm = false
2647
2648
[[example]]
2649
name = "serialization"
2650
path = "examples/reflection/serialization.rs"
2651
doc-scrape-examples = true
2652
2653
[package.metadata.example.serialization]
2654
name = "Serialization"
2655
description = "Demonstrates serialization and deserialization using reflection without serde's Serialize/Deserialize traits"
2656
category = "Reflection"
2657
wasm = false
2658
2659
[[example]]
2660
name = "custom_attributes"
2661
path = "examples/reflection/custom_attributes.rs"
2662
doc-scrape-examples = true
2663
2664
[package.metadata.example.custom_attributes]
2665
name = "Custom Attributes"
2666
description = "Registering and accessing custom attributes on reflected types"
2667
category = "Reflection"
2668
wasm = false
2669
2670
[[example]]
2671
name = "dynamic_types"
2672
path = "examples/reflection/dynamic_types.rs"
2673
doc-scrape-examples = true
2674
2675
[package.metadata.example.dynamic_types]
2676
name = "Dynamic Types"
2677
description = "How dynamic types are used with reflection"
2678
category = "Reflection"
2679
wasm = false
2680
2681
[[example]]
2682
name = "function_reflection"
2683
path = "examples/reflection/function_reflection.rs"
2684
doc-scrape-examples = true
2685
required-features = ["reflect_functions"]
2686
2687
[package.metadata.example.function_reflection]
2688
name = "Function Reflection"
2689
description = "Demonstrates how functions can be called dynamically using reflection"
2690
category = "Reflection"
2691
wasm = false
2692
2693
[[example]]
2694
name = "generic_reflection"
2695
path = "examples/reflection/generic_reflection.rs"
2696
doc-scrape-examples = true
2697
2698
[package.metadata.example.generic_reflection]
2699
name = "Generic Reflection"
2700
description = "Registers concrete instances of generic types that may be used with reflection"
2701
category = "Reflection"
2702
wasm = false
2703
2704
[[example]]
2705
name = "reflection_types"
2706
path = "examples/reflection/reflection_types.rs"
2707
doc-scrape-examples = true
2708
2709
[package.metadata.example.reflection_types]
2710
name = "Reflection Types"
2711
description = "Illustrates the various reflection types available"
2712
category = "Reflection"
2713
wasm = false
2714
2715
[[example]]
2716
name = "type_data"
2717
path = "examples/reflection/type_data.rs"
2718
doc-scrape-examples = true
2719
2720
[package.metadata.example.type_data]
2721
name = "Type Data"
2722
description = "Demonstrates how to create and use type data"
2723
category = "Reflection"
2724
wasm = false
2725
2726
[[example]]
2727
name = "auto_register_static"
2728
path = "examples/reflection/auto_register_static/src/lib.rs"
2729
doc-scrape-examples = true
2730
2731
[package.metadata.example.auto_register_static]
2732
name = "Automatic types registration"
2733
description = "Demonstrates how to set up automatic reflect types registration for platforms without `inventory` support"
2734
category = "Reflection"
2735
wasm = false
2736
2737
# Scene
2738
[[example]]
2739
name = "scene"
2740
path = "examples/scene/scene.rs"
2741
doc-scrape-examples = true
2742
2743
[package.metadata.example.scene]
2744
name = "Scene"
2745
description = "Demonstrates loading from and saving scenes to files"
2746
category = "Scene"
2747
wasm = false
2748
2749
# Shaders
2750
[[package.metadata.example_category]]
2751
name = "Shaders"
2752
description = """
2753
These examples demonstrate how to implement different shaders in user code.
2754
2755
A shader in its most common usage is a small program that is run by the GPU per-vertex in a mesh (a vertex shader) or per-affected-screen-fragment (a fragment shader.) The GPU executes these programs in a highly parallel way.
2756
2757
There are also compute shaders which are used for more general processing leveraging the GPU's parallelism.
2758
"""
2759
2760
[[example]]
2761
name = "shader_defs"
2762
path = "examples/shader/shader_defs.rs"
2763
doc-scrape-examples = true
2764
2765
[package.metadata.example.shader_defs]
2766
name = "Shader Defs"
2767
description = "A shader that uses \"shaders defs\" (a bevy tool to selectively toggle parts of a shader)"
2768
category = "Shaders"
2769
wasm = true
2770
2771
[[example]]
2772
name = "shader_material"
2773
path = "examples/shader/shader_material.rs"
2774
doc-scrape-examples = true
2775
2776
[package.metadata.example.shader_material]
2777
name = "Material"
2778
description = "A shader and a material that uses it"
2779
category = "Shaders"
2780
wasm = true
2781
2782
[[example]]
2783
name = "shader_material_2d"
2784
path = "examples/shader/shader_material_2d.rs"
2785
doc-scrape-examples = true
2786
2787
[package.metadata.example.shader_material_2d]
2788
name = "Material"
2789
description = "A shader and a material that uses it on a 2d mesh"
2790
category = "Shaders"
2791
wasm = true
2792
2793
[[example]]
2794
name = "extended_material"
2795
path = "examples/shader/extended_material.rs"
2796
doc-scrape-examples = true
2797
2798
[package.metadata.example.extended_material]
2799
name = "Extended Material"
2800
description = "A custom shader that builds on the standard material"
2801
category = "Shaders"
2802
wasm = true
2803
2804
[[example]]
2805
name = "shader_prepass"
2806
path = "examples/shader/shader_prepass.rs"
2807
doc-scrape-examples = true
2808
2809
[package.metadata.example.shader_prepass]
2810
name = "Material Prepass"
2811
description = "A shader that uses the various textures generated by the prepass"
2812
category = "Shaders"
2813
wasm = false
2814
2815
[[example]]
2816
name = "shader_material_screenspace_texture"
2817
path = "examples/shader/shader_material_screenspace_texture.rs"
2818
doc-scrape-examples = true
2819
2820
[package.metadata.example.shader_material_screenspace_texture]
2821
name = "Material - Screenspace Texture"
2822
description = "A shader that samples a texture with view-independent UV coordinates"
2823
category = "Shaders"
2824
wasm = true
2825
2826
[[example]]
2827
name = "shader_material_glsl"
2828
path = "examples/shader/shader_material_glsl.rs"
2829
doc-scrape-examples = true
2830
required-features = ["shader_format_glsl"]
2831
2832
[package.metadata.example.shader_material_glsl]
2833
name = "Material - GLSL"
2834
description = "A shader that uses the GLSL shading language"
2835
category = "Shaders"
2836
wasm = true
2837
2838
[[example]]
2839
name = "shader_material_wesl"
2840
path = "examples/shader/shader_material_wesl.rs"
2841
doc-scrape-examples = true
2842
required-features = ["shader_format_wesl"]
2843
2844
[package.metadata.example.shader_material_wesl]
2845
name = "Material - WESL"
2846
description = "A shader that uses WESL"
2847
category = "Shaders"
2848
wasm = true
2849
2850
[[example]]
2851
name = "automatic_instancing"
2852
path = "examples/shader/automatic_instancing.rs"
2853
doc-scrape-examples = true
2854
2855
[package.metadata.example.automatic_instancing]
2856
name = "Instancing"
2857
description = "Shows that multiple instances of a cube are automatically instanced in one draw call"
2858
category = "Shaders"
2859
wasm = true
2860
2861
[[example]]
2862
name = "animate_shader"
2863
path = "examples/shader/animate_shader.rs"
2864
doc-scrape-examples = true
2865
2866
[package.metadata.example.animate_shader]
2867
name = "Animated"
2868
description = "A shader that uses dynamic data like the time since startup"
2869
category = "Shaders"
2870
wasm = true
2871
2872
[[example]]
2873
name = "compute_shader_game_of_life"
2874
path = "examples/shader/compute_shader_game_of_life.rs"
2875
doc-scrape-examples = true
2876
2877
[package.metadata.example.compute_shader_game_of_life]
2878
name = "Compute - Game of Life"
2879
description = "A compute shader that simulates Conway's Game of Life"
2880
category = "Shaders"
2881
wasm = false
2882
2883
[[example]]
2884
name = "gpu_readback"
2885
path = "examples/shader/gpu_readback.rs"
2886
doc-scrape-examples = true
2887
2888
[package.metadata.example.gpu_readback]
2889
name = "GPU readback"
2890
description = "A very simple compute shader that writes to a buffer that is read by the cpu"
2891
category = "Shaders"
2892
wasm = false
2893
2894
[[example]]
2895
name = "array_texture"
2896
path = "examples/shader/array_texture.rs"
2897
doc-scrape-examples = true
2898
2899
[package.metadata.example.array_texture]
2900
name = "Array Texture"
2901
description = "A shader that shows how to reuse the core bevy PBR shading functionality in a custom material that obtains the base color from an array texture."
2902
category = "Shaders"
2903
wasm = true
2904
2905
[[example]]
2906
name = "storage_buffer"
2907
path = "examples/shader/storage_buffer.rs"
2908
doc-scrape-examples = true
2909
2910
[package.metadata.example.storage_buffer]
2911
name = "Storage Buffer"
2912
description = "A shader that shows how to bind a storage buffer using a custom material."
2913
category = "Shaders"
2914
wasm = true
2915
2916
# Shaders advanced
2917
[[package.metadata.example_category]]
2918
name = "Shaders - advanced"
2919
description = """
2920
These examples demonstrate how to use the lower level rendering apis exposed from bevy.
2921
2922
These are generally simplified examples of bevy's own rendering infrastructure.
2923
"""
2924
2925
[[example]]
2926
name = "custom_vertex_attribute"
2927
path = "examples/shader_advanced/custom_vertex_attribute.rs"
2928
doc-scrape-examples = true
2929
2930
[package.metadata.example.custom_vertex_attribute]
2931
name = "Custom Vertex Attribute"
2932
description = "A shader that reads a mesh's custom vertex attribute"
2933
category = "Shaders"
2934
wasm = true
2935
2936
[[example]]
2937
name = "custom_post_processing"
2938
path = "examples/shader_advanced/custom_post_processing.rs"
2939
doc-scrape-examples = true
2940
2941
[package.metadata.example.custom_post_processing]
2942
name = "Post Processing - Custom Render Pass"
2943
description = "A custom post processing effect, using a custom render pass that runs after the main pass"
2944
category = "Shaders"
2945
wasm = true
2946
2947
[[example]]
2948
name = "custom_shader_instancing"
2949
path = "examples/shader_advanced/custom_shader_instancing.rs"
2950
doc-scrape-examples = true
2951
2952
[package.metadata.example.custom_shader_instancing]
2953
name = "Instancing"
2954
description = "A shader that renders a mesh multiple times in one draw call using low level rendering api"
2955
category = "Shaders"
2956
wasm = true
2957
2958
[[example]]
2959
name = "custom_render_phase"
2960
path = "examples/shader_advanced/custom_render_phase.rs"
2961
doc-scrape-examples = true
2962
2963
[package.metadata.example.custom_render_phase]
2964
name = "Custom Render Phase"
2965
description = "Shows how to make a complete render phase"
2966
category = "Shaders"
2967
wasm = true
2968
2969
[[example]]
2970
name = "texture_binding_array"
2971
path = "examples/shader_advanced/texture_binding_array.rs"
2972
doc-scrape-examples = true
2973
2974
[package.metadata.example.texture_binding_array]
2975
name = "Texture Binding Array (Bindless Textures)"
2976
description = "A shader that shows how to bind and sample multiple textures as a binding array (a.k.a. bindless textures)."
2977
category = "Shaders"
2978
wasm = false
2979
2980
2981
[[example]]
2982
name = "specialized_mesh_pipeline"
2983
path = "examples/shader_advanced/specialized_mesh_pipeline.rs"
2984
doc-scrape-examples = true
2985
2986
[package.metadata.example.specialized_mesh_pipeline]
2987
name = "Specialized Mesh Pipeline"
2988
description = "Demonstrates how to write a specialized mesh pipeline"
2989
category = "Shaders"
2990
wasm = true
2991
2992
# Stress tests
2993
[[package.metadata.example_category]]
2994
name = "Stress Tests"
2995
description = """
2996
These examples are used to test the performance and stability of various parts of the engine in an isolated way.
2997
2998
Due to the focus on performance it's recommended to run the stress tests in release mode:
2999
3000
```sh
3001
cargo run --release --example <example name>
3002
```
3003
"""
3004
3005
[[example]]
3006
name = "bevymark"
3007
path = "examples/stress_tests/bevymark.rs"
3008
doc-scrape-examples = true
3009
3010
[package.metadata.example.bevymark]
3011
name = "Bevymark"
3012
description = "A heavy sprite rendering workload to benchmark your system with Bevy"
3013
category = "Stress Tests"
3014
wasm = true
3015
3016
[[example]]
3017
name = "many_animated_sprites"
3018
path = "examples/stress_tests/many_animated_sprites.rs"
3019
doc-scrape-examples = true
3020
3021
[package.metadata.example.many_animated_sprites]
3022
name = "Many Animated Sprites"
3023
description = "Displays many animated sprites in a grid arrangement with slight offsets to their animation timers. Used for performance testing."
3024
category = "Stress Tests"
3025
wasm = true
3026
3027
[[example]]
3028
name = "many_buttons"
3029
path = "examples/stress_tests/many_buttons.rs"
3030
doc-scrape-examples = true
3031
3032
[package.metadata.example.many_buttons]
3033
name = "Many Buttons"
3034
description = "Test rendering of many UI elements"
3035
category = "Stress Tests"
3036
wasm = true
3037
3038
[[example]]
3039
name = "many_gradients"
3040
path = "examples/stress_tests/many_gradients.rs"
3041
doc-scrape-examples = true
3042
3043
[package.metadata.example.many_gradients]
3044
name = "Many Gradients"
3045
description = "Stress test for gradient rendering performance"
3046
category = "Stress Tests"
3047
wasm = true
3048
3049
[[example]]
3050
name = "many_cameras_lights"
3051
path = "examples/stress_tests/many_cameras_lights.rs"
3052
doc-scrape-examples = true
3053
3054
[package.metadata.example.many_cameras_lights]
3055
name = "Many Cameras & Lights"
3056
description = "Test rendering of many cameras and lights"
3057
category = "Stress Tests"
3058
wasm = true
3059
3060
[[example]]
3061
name = "many_components"
3062
path = "examples/stress_tests/many_components.rs"
3063
doc-scrape-examples = true
3064
3065
[package.metadata.example.many_components]
3066
name = "Many Components (and Entities and Systems)"
3067
description = "Test large ECS systems"
3068
category = "Stress Tests"
3069
wasm = false
3070
3071
[[example]]
3072
name = "many_cubes"
3073
path = "examples/stress_tests/many_cubes.rs"
3074
doc-scrape-examples = true
3075
3076
[package.metadata.example.many_cubes]
3077
name = "Many Cubes"
3078
description = "Simple benchmark to test per-entity draw overhead. Run with the `sphere` argument to test frustum culling"
3079
category = "Stress Tests"
3080
wasm = true
3081
3082
[[example]]
3083
name = "many_gizmos"
3084
path = "examples/stress_tests/many_gizmos.rs"
3085
doc-scrape-examples = true
3086
3087
[package.metadata.example.many_gizmos]
3088
name = "Many Gizmos"
3089
description = "Test rendering of many gizmos"
3090
category = "Stress Tests"
3091
wasm = true
3092
3093
[[example]]
3094
name = "many_foxes"
3095
path = "examples/stress_tests/many_foxes.rs"
3096
doc-scrape-examples = true
3097
3098
[package.metadata.example.many_foxes]
3099
name = "Many Foxes"
3100
description = "Loads an animated fox model and spawns lots of them. Good for testing skinned mesh performance. Takes an unsigned integer argument for the number of foxes to spawn. Defaults to 1000"
3101
category = "Stress Tests"
3102
wasm = true
3103
3104
[[example]]
3105
name = "many_glyphs"
3106
path = "examples/stress_tests/many_glyphs.rs"
3107
doc-scrape-examples = true
3108
3109
[package.metadata.example.many_glyphs]
3110
name = "Many Glyphs"
3111
description = "Simple benchmark to test text rendering."
3112
category = "Stress Tests"
3113
wasm = true
3114
3115
[[example]]
3116
name = "many_lights"
3117
path = "examples/stress_tests/many_lights.rs"
3118
doc-scrape-examples = true
3119
3120
[package.metadata.example.many_lights]
3121
name = "Many Lights"
3122
description = "Simple benchmark to test rendering many point lights. Run with `WGPU_SETTINGS_PRIO=webgl2` to restrict to uniform buffers and max 256 lights"
3123
category = "Stress Tests"
3124
wasm = true
3125
3126
[[example]]
3127
name = "many_sprites"
3128
path = "examples/stress_tests/many_sprites.rs"
3129
doc-scrape-examples = true
3130
3131
[package.metadata.example.many_sprites]
3132
name = "Many Sprites"
3133
description = "Displays many sprites in a grid arrangement! Used for performance testing. Use `--colored` to enable color tinted sprites."
3134
category = "Stress Tests"
3135
wasm = true
3136
3137
[[example]]
3138
name = "many_text2d"
3139
path = "examples/stress_tests/many_text2d.rs"
3140
doc-scrape-examples = true
3141
3142
[package.metadata.example.many_text2d]
3143
name = "Many Text2d"
3144
description = "Displays many Text2d! Used for performance testing."
3145
category = "Stress Tests"
3146
wasm = true
3147
3148
[[example]]
3149
name = "many_materials"
3150
path = "examples/stress_tests/many_materials.rs"
3151
doc-scrape-examples = true
3152
3153
[package.metadata.example.many_materials]
3154
name = "Many Animated Materials"
3155
description = "Benchmark to test rendering many animated materials"
3156
category = "Stress Tests"
3157
wasm = true
3158
3159
[[example]]
3160
name = "transform_hierarchy"
3161
path = "examples/stress_tests/transform_hierarchy.rs"
3162
doc-scrape-examples = true
3163
3164
[package.metadata.example.transform_hierarchy]
3165
name = "Transform Hierarchy"
3166
description = "Various test cases for hierarchy and transform propagation performance"
3167
category = "Stress Tests"
3168
wasm = false
3169
3170
[[example]]
3171
name = "text_pipeline"
3172
path = "examples/stress_tests/text_pipeline.rs"
3173
doc-scrape-examples = true
3174
3175
[package.metadata.example.text_pipeline]
3176
name = "Text Pipeline"
3177
description = "Text Pipeline benchmark"
3178
category = "Stress Tests"
3179
wasm = false
3180
3181
# Tools
3182
[[example]]
3183
name = "scene_viewer"
3184
path = "examples/tools/scene_viewer/main.rs"
3185
doc-scrape-examples = true
3186
3187
[package.metadata.example.scene_viewer]
3188
name = "Scene Viewer"
3189
description = "A simple way to view glTF models with Bevy. Just run `cargo run --release --example scene_viewer /path/to/model.gltf#Scene0`, replacing the path as appropriate. With no arguments it will load the FieldHelmet glTF model from the repository assets subdirectory"
3190
category = "Tools"
3191
wasm = true
3192
3193
[[example]]
3194
name = "gamepad_viewer"
3195
path = "examples/tools/gamepad_viewer.rs"
3196
doc-scrape-examples = true
3197
3198
[package.metadata.example.gamepad_viewer]
3199
name = "Gamepad Viewer"
3200
description = "Shows a visualization of gamepad buttons, sticks, and triggers"
3201
category = "Tools"
3202
wasm = true
3203
3204
[[example]]
3205
name = "nondeterministic_system_order"
3206
path = "examples/ecs/nondeterministic_system_order.rs"
3207
doc-scrape-examples = true
3208
3209
[package.metadata.example.nondeterministic_system_order]
3210
name = "Nondeterministic System Order"
3211
description = "Systems run in parallel, but their order isn't always deterministic. Here's how to detect and fix this."
3212
category = "ECS (Entity Component System)"
3213
wasm = false
3214
3215
[[example]]
3216
name = "observers"
3217
path = "examples/ecs/observers.rs"
3218
doc-scrape-examples = true
3219
3220
[package.metadata.example.observers]
3221
name = "Observers"
3222
description = "Demonstrates observers that react to events (both built-in life-cycle events and custom events)"
3223
category = "ECS (Entity Component System)"
3224
wasm = true
3225
3226
[[example]]
3227
name = "observer_propagation"
3228
path = "examples/ecs/observer_propagation.rs"
3229
doc-scrape-examples = true
3230
3231
[package.metadata.example.observer_propagation]
3232
name = "Observer Propagation"
3233
description = "Demonstrates event propagation with observers"
3234
category = "ECS (Entity Component System)"
3235
wasm = true
3236
3237
[[example]]
3238
name = "3d_rotation"
3239
path = "examples/transforms/3d_rotation.rs"
3240
doc-scrape-examples = true
3241
3242
[package.metadata.example.3d_rotation]
3243
name = "3D Rotation"
3244
description = "Illustrates how to (constantly) rotate an object around an axis"
3245
category = "Transforms"
3246
wasm = true
3247
3248
[[example]]
3249
name = "align"
3250
path = "examples/transforms/align.rs"
3251
doc-scrape-examples = true
3252
3253
[package.metadata.example.align]
3254
name = "Alignment"
3255
description = "A demonstration of Transform's axis-alignment feature"
3256
category = "Transforms"
3257
wasm = true
3258
3259
[[example]]
3260
name = "scale"
3261
path = "examples/transforms/scale.rs"
3262
doc-scrape-examples = true
3263
3264
[package.metadata.example.scale]
3265
name = "Scale"
3266
description = "Illustrates how to scale an object in each direction"
3267
category = "Transforms"
3268
wasm = true
3269
3270
[[example]]
3271
name = "transform"
3272
path = "examples/transforms/transform.rs"
3273
doc-scrape-examples = true
3274
3275
[package.metadata.example.transform]
3276
name = "Transform"
3277
description = "Shows multiple transformations of objects"
3278
category = "Transforms"
3279
wasm = true
3280
3281
[[example]]
3282
name = "translation"
3283
path = "examples/transforms/translation.rs"
3284
doc-scrape-examples = true
3285
3286
[package.metadata.example.translation]
3287
name = "Translation"
3288
description = "Illustrates how to move an object along an axis"
3289
category = "Transforms"
3290
wasm = true
3291
3292
# UI (User Interface)
3293
[[example]]
3294
name = "borders"
3295
path = "examples/ui/borders.rs"
3296
doc-scrape-examples = true
3297
3298
[package.metadata.example.borders]
3299
name = "Borders"
3300
description = "Demonstrates how to create a node with a border"
3301
category = "UI (User Interface)"
3302
wasm = true
3303
3304
[[example]]
3305
name = "box_shadow"
3306
path = "examples/ui/box_shadow.rs"
3307
doc-scrape-examples = true
3308
3309
[package.metadata.example.box_shadow]
3310
name = "Box Shadow"
3311
description = "Demonstrates how to create a node with a shadow"
3312
category = "UI (User Interface)"
3313
wasm = true
3314
3315
[[example]]
3316
name = "button"
3317
path = "examples/ui/button.rs"
3318
doc-scrape-examples = true
3319
3320
[package.metadata.example.button]
3321
name = "Button"
3322
description = "Illustrates creating and updating a button"
3323
category = "UI (User Interface)"
3324
wasm = true
3325
3326
[[example]]
3327
name = "ui_drag_and_drop"
3328
path = "examples/ui/ui_drag_and_drop.rs"
3329
doc-scrape-examples = true
3330
3331
[package.metadata.example.ui_drag_and_drop]
3332
name = "UI Drag and Drop"
3333
description = "Demonstrates dragging and dropping UI nodes"
3334
category = "UI (User Interface)"
3335
wasm = true
3336
3337
[[example]]
3338
name = "display_and_visibility"
3339
path = "examples/ui/display_and_visibility.rs"
3340
doc-scrape-examples = true
3341
3342
[package.metadata.example.display_and_visibility]
3343
name = "Display and Visibility"
3344
description = "Demonstrates how Display and Visibility work in the UI."
3345
category = "UI (User Interface)"
3346
wasm = true
3347
3348
[[example]]
3349
name = "window_fallthrough"
3350
path = "examples/ui/window_fallthrough.rs"
3351
doc-scrape-examples = true
3352
3353
[package.metadata.example.window_fallthrough]
3354
name = "Window Fallthrough"
3355
description = "Illustrates how to access `winit::window::Window`'s `hittest` functionality."
3356
category = "UI (User Interface)"
3357
wasm = false
3358
3359
[[example]]
3360
name = "font_atlas_debug"
3361
path = "examples/ui/font_atlas_debug.rs"
3362
doc-scrape-examples = true
3363
3364
[package.metadata.example.font_atlas_debug]
3365
name = "Font Atlas Debug"
3366
description = "Illustrates how FontAtlases are populated (used to optimize text rendering internally)"
3367
category = "UI (User Interface)"
3368
wasm = true
3369
3370
[[example]]
3371
name = "overflow"
3372
path = "examples/ui/overflow.rs"
3373
doc-scrape-examples = true
3374
3375
[package.metadata.example.overflow]
3376
name = "Overflow"
3377
description = "Simple example demonstrating overflow behavior"
3378
category = "UI (User Interface)"
3379
wasm = true
3380
3381
[[example]]
3382
name = "overflow_clip_margin"
3383
path = "examples/ui/overflow_clip_margin.rs"
3384
doc-scrape-examples = true
3385
3386
[package.metadata.example.overflow_clip_margin]
3387
name = "Overflow Clip Margin"
3388
description = "Simple example demonstrating the OverflowClipMargin style property"
3389
category = "UI (User Interface)"
3390
wasm = true
3391
3392
3393
[[example]]
3394
name = "overflow_debug"
3395
path = "examples/ui/overflow_debug.rs"
3396
doc-scrape-examples = true
3397
3398
[package.metadata.example.overflow_debug]
3399
name = "Overflow and Clipping Debug"
3400
description = "An example to debug overflow and clipping behavior"
3401
category = "UI (User Interface)"
3402
wasm = true
3403
3404
[[example]]
3405
name = "relative_cursor_position"
3406
path = "examples/ui/relative_cursor_position.rs"
3407
doc-scrape-examples = true
3408
3409
[package.metadata.example.relative_cursor_position]
3410
name = "Relative Cursor Position"
3411
description = "Showcases the RelativeCursorPosition component"
3412
category = "UI (User Interface)"
3413
wasm = true
3414
3415
[[example]]
3416
name = "render_ui_to_texture"
3417
path = "examples/ui/render_ui_to_texture.rs"
3418
doc-scrape-examples = true
3419
3420
[package.metadata.example.render_ui_to_texture]
3421
name = "Render UI to Texture"
3422
description = "An example of rendering UI as a part of a 3D world"
3423
category = "UI (User Interface)"
3424
wasm = true
3425
3426
[[example]]
3427
name = "size_constraints"
3428
path = "examples/ui/size_constraints.rs"
3429
doc-scrape-examples = true
3430
3431
[package.metadata.example.size_constraints]
3432
name = "Size Constraints"
3433
description = "Demonstrates how the to use the size constraints to control the size of a UI node."
3434
category = "UI (User Interface)"
3435
wasm = true
3436
3437
[[example]]
3438
name = "text"
3439
path = "examples/ui/text.rs"
3440
doc-scrape-examples = true
3441
3442
[package.metadata.example.text]
3443
name = "Text"
3444
description = "Illustrates creating and updating text"
3445
category = "UI (User Interface)"
3446
wasm = true
3447
3448
[[example]]
3449
name = "text_background_colors"
3450
path = "examples/ui/text_background_colors.rs"
3451
doc-scrape-examples = true
3452
3453
[package.metadata.example.text_background_colors]
3454
name = "Text Background Colors"
3455
description = "Demonstrates text background colors"
3456
category = "UI (User Interface)"
3457
wasm = true
3458
3459
[[example]]
3460
name = "text_debug"
3461
path = "examples/ui/text_debug.rs"
3462
doc-scrape-examples = true
3463
3464
[package.metadata.example.text_debug]
3465
name = "Text Debug"
3466
description = "An example for debugging text layout"
3467
category = "UI (User Interface)"
3468
wasm = true
3469
3470
[[example]]
3471
name = "flex_layout"
3472
path = "examples/ui/flex_layout.rs"
3473
doc-scrape-examples = true
3474
3475
[package.metadata.example.flex_layout]
3476
name = "Flex Layout"
3477
description = "Demonstrates how the AlignItems and JustifyContent properties can be composed to layout nodes and position text"
3478
category = "UI (User Interface)"
3479
wasm = true
3480
3481
[[example]]
3482
name = "text_wrap_debug"
3483
path = "examples/ui/text_wrap_debug.rs"
3484
doc-scrape-examples = true
3485
3486
[package.metadata.example.text_wrap_debug]
3487
name = "Text Wrap Debug"
3488
description = "Demonstrates text wrapping"
3489
category = "UI (User Interface)"
3490
wasm = true
3491
3492
[[example]]
3493
name = "ghost_nodes"
3494
path = "examples/ui/ghost_nodes.rs"
3495
doc-scrape-examples = true
3496
required-features = ["ghost_nodes"]
3497
3498
[package.metadata.example.ghost_nodes]
3499
name = "Ghost Nodes"
3500
description = "Demonstrates the use of Ghost Nodes to skip entities in the UI layout hierarchy"
3501
category = "UI (User Interface)"
3502
wasm = true
3503
3504
[[example]]
3505
name = "grid"
3506
path = "examples/ui/grid.rs"
3507
doc-scrape-examples = true
3508
3509
[package.metadata.example.grid]
3510
name = "CSS Grid"
3511
description = "An example for CSS Grid layout"
3512
category = "UI (User Interface)"
3513
wasm = true
3514
3515
[[example]]
3516
name = "gradients"
3517
path = "examples/ui/gradients.rs"
3518
doc-scrape-examples = true
3519
3520
[package.metadata.example.gradients]
3521
name = "Gradients"
3522
description = "An example demonstrating gradients"
3523
category = "UI (User Interface)"
3524
wasm = true
3525
3526
[[example]]
3527
name = "stacked_gradients"
3528
path = "examples/ui/stacked_gradients.rs"
3529
doc-scrape-examples = true
3530
3531
[package.metadata.example.stacked_gradients]
3532
name = "Stacked Gradients"
3533
description = "An example demonstrating stacked gradients"
3534
category = "UI (User Interface)"
3535
wasm = true
3536
3537
[[example]]
3538
name = "scroll"
3539
path = "examples/ui/scroll.rs"
3540
doc-scrape-examples = true
3541
3542
[package.metadata.example.scroll]
3543
name = "Scroll"
3544
description = "Demonstrates scrolling UI containers"
3545
category = "UI (User Interface)"
3546
wasm = true
3547
3548
[[example]]
3549
name = "transparency_ui"
3550
path = "examples/ui/transparency_ui.rs"
3551
doc-scrape-examples = true
3552
3553
[package.metadata.example.transparency_ui]
3554
name = "Transparency UI"
3555
description = "Demonstrates transparency for UI"
3556
category = "UI (User Interface)"
3557
wasm = true
3558
3559
[[example]]
3560
name = "z_index"
3561
path = "examples/ui/z_index.rs"
3562
doc-scrape-examples = true
3563
3564
[package.metadata.example.z_index]
3565
name = "UI Z-Index"
3566
description = "Demonstrates how to control the relative depth (z-position) of UI elements"
3567
category = "UI (User Interface)"
3568
wasm = true
3569
3570
[[example]]
3571
name = "virtual_keyboard"
3572
path = "examples/ui/virtual_keyboard.rs"
3573
doc-scrape-examples = true
3574
required-features = ["experimental_bevy_feathers"]
3575
3576
[package.metadata.example.virtual_keyboard]
3577
name = "Virtual Keyboard"
3578
description = "Example demonstrating a virtual keyboard widget"
3579
category = "UI (User Interface)"
3580
wasm = true
3581
3582
[[example]]
3583
name = "ui_scaling"
3584
path = "examples/ui/ui_scaling.rs"
3585
doc-scrape-examples = true
3586
3587
[package.metadata.example.ui_scaling]
3588
name = "UI Scaling"
3589
description = "Illustrates how to scale the UI"
3590
category = "UI (User Interface)"
3591
wasm = true
3592
3593
[[example]]
3594
name = "ui_texture_atlas"
3595
path = "examples/ui/ui_texture_atlas.rs"
3596
doc-scrape-examples = true
3597
3598
[package.metadata.example.ui_texture_atlas]
3599
name = "UI Texture Atlas"
3600
description = "Illustrates how to use TextureAtlases in UI"
3601
category = "UI (User Interface)"
3602
wasm = true
3603
3604
[[example]]
3605
name = "ui_texture_slice"
3606
path = "examples/ui/ui_texture_slice.rs"
3607
doc-scrape-examples = true
3608
3609
[package.metadata.example.ui_texture_slice]
3610
name = "UI Texture Slice"
3611
description = "Illustrates how to use 9 Slicing in UI"
3612
category = "UI (User Interface)"
3613
wasm = true
3614
3615
[[example]]
3616
name = "ui_texture_slice_flip_and_tile"
3617
path = "examples/ui/ui_texture_slice_flip_and_tile.rs"
3618
doc-scrape-examples = true
3619
3620
[package.metadata.example.ui_texture_slice_flip_and_tile]
3621
name = "UI Texture Slice Flipping and Tiling"
3622
description = "Illustrates how to flip and tile images with 9 Slicing in UI"
3623
category = "UI (User Interface)"
3624
wasm = true
3625
3626
[[example]]
3627
name = "ui_texture_atlas_slice"
3628
path = "examples/ui/ui_texture_atlas_slice.rs"
3629
doc-scrape-examples = true
3630
3631
[package.metadata.example.ui_texture_atlas_slice]
3632
name = "UI Texture Atlas Slice"
3633
description = "Illustrates how to use 9 Slicing for TextureAtlases in UI"
3634
category = "UI (User Interface)"
3635
wasm = true
3636
3637
[[example]]
3638
name = "ui_transform"
3639
path = "examples/ui/ui_transform.rs"
3640
doc-scrape-examples = true
3641
3642
[package.metadata.example.ui_transform]
3643
name = "UI Transform"
3644
description = "An example demonstrating how to translate, rotate and scale UI elements."
3645
category = "UI (User Interface)"
3646
wasm = true
3647
3648
[[example]]
3649
name = "ui_target_camera"
3650
path = "examples/ui/ui_target_camera.rs"
3651
doc-scrape-examples = true
3652
3653
[package.metadata.example.ui_target_camera]
3654
name = "UI Target Camera"
3655
description = "Demonstrates how to use `UiTargetCamera` and camera ordering."
3656
category = "UI (User Interface)"
3657
wasm = true
3658
3659
[[example]]
3660
name = "viewport_debug"
3661
path = "examples/ui/viewport_debug.rs"
3662
doc-scrape-examples = true
3663
3664
[package.metadata.example.viewport_debug]
3665
name = "Viewport Debug"
3666
description = "An example for debugging viewport coordinates"
3667
category = "UI (User Interface)"
3668
wasm = true
3669
3670
[[example]]
3671
name = "viewport_node"
3672
path = "examples/ui/viewport_node.rs"
3673
doc-scrape-examples = true
3674
3675
[package.metadata.example.viewport_node]
3676
name = "Viewport Node"
3677
description = "Demonstrates how to create a viewport node with picking support"
3678
category = "UI (User Interface)"
3679
wasm = true
3680
3681
# Window
3682
[[example]]
3683
name = "clear_color"
3684
path = "examples/window/clear_color.rs"
3685
doc-scrape-examples = true
3686
3687
[package.metadata.example.clear_color]
3688
name = "Clear Color"
3689
description = "Creates a solid color window"
3690
category = "Window"
3691
wasm = true
3692
3693
[[example]]
3694
name = "custom_cursor_image"
3695
path = "examples/window/custom_cursor_image.rs"
3696
doc-scrape-examples = true
3697
required-features = ["custom_cursor"]
3698
3699
[package.metadata.example.custom_cursor_image]
3700
name = "Custom Cursor Image"
3701
description = "Demonstrates creating an animated custom cursor from an image"
3702
category = "Window"
3703
wasm = true
3704
3705
[[example]]
3706
name = "custom_user_event"
3707
path = "examples/window/custom_user_event.rs"
3708
doc-scrape-examples = true
3709
3710
[package.metadata.example.custom_user_event]
3711
name = "Custom User Event"
3712
description = "Handles custom user events within the event loop"
3713
category = "Window"
3714
wasm = true
3715
3716
[[example]]
3717
name = "low_power"
3718
path = "examples/window/low_power.rs"
3719
doc-scrape-examples = true
3720
3721
[package.metadata.example.low_power]
3722
name = "Low Power"
3723
description = "Demonstrates settings to reduce power use for bevy applications"
3724
category = "Window"
3725
wasm = true
3726
3727
[[example]]
3728
name = "multiple_windows"
3729
path = "examples/window/multiple_windows.rs"
3730
doc-scrape-examples = true
3731
3732
[package.metadata.example.multiple_windows]
3733
name = "Multiple Windows"
3734
description = "Demonstrates creating multiple windows, and rendering to them"
3735
category = "Window"
3736
wasm = false
3737
3738
[[example]]
3739
name = "scale_factor_override"
3740
path = "examples/window/scale_factor_override.rs"
3741
doc-scrape-examples = true
3742
3743
[package.metadata.example.scale_factor_override]
3744
name = "Scale Factor Override"
3745
description = "Illustrates how to customize the default window settings"
3746
category = "Window"
3747
wasm = true
3748
3749
[[example]]
3750
name = "screenshot"
3751
path = "examples/window/screenshot.rs"
3752
doc-scrape-examples = true
3753
3754
[package.metadata.example.screenshot]
3755
name = "Screenshot"
3756
description = "Shows how to save screenshots to disk"
3757
category = "Window"
3758
wasm = true
3759
3760
[[example]]
3761
name = "transparent_window"
3762
path = "examples/window/transparent_window.rs"
3763
doc-scrape-examples = true
3764
3765
[package.metadata.example.transparent_window]
3766
name = "Transparent Window"
3767
description = "Illustrates making the window transparent and hiding the window decoration"
3768
category = "Window"
3769
wasm = false
3770
3771
[[example]]
3772
name = "window_settings"
3773
path = "examples/window/window_settings.rs"
3774
doc-scrape-examples = true
3775
3776
[package.metadata.example.window_settings]
3777
name = "Window Settings"
3778
description = "Demonstrates customizing default window settings"
3779
category = "Window"
3780
wasm = true
3781
3782
[[example]]
3783
name = "window_drag_move"
3784
path = "examples/window/window_drag_move.rs"
3785
doc-scrape-examples = true
3786
3787
[package.metadata.example.window_drag_move]
3788
name = "Window Drag Move"
3789
description = "Demonstrates drag move and drag resize without window decoration"
3790
category = "Window"
3791
wasm = false
3792
3793
[[example]]
3794
name = "ambiguity_detection"
3795
path = "tests/ecs/ambiguity_detection.rs"
3796
doc-scrape-examples = true
3797
3798
[package.metadata.example.ambiguity_detection]
3799
hidden = true
3800
3801
[[example]]
3802
name = "resizing"
3803
path = "tests/window/resizing.rs"
3804
doc-scrape-examples = true
3805
3806
[package.metadata.example.resizing]
3807
hidden = true
3808
3809
[[example]]
3810
name = "minimizing"
3811
path = "tests/window/minimizing.rs"
3812
doc-scrape-examples = true
3813
3814
[package.metadata.example.minimizing]
3815
hidden = true
3816
3817
[[example]]
3818
name = "desktop_request_redraw"
3819
path = "tests/window/desktop_request_redraw.rs"
3820
doc-scrape-examples = true
3821
required-features = ["bevy_dev_tools"]
3822
3823
[package.metadata.example.desktop_request_redraw]
3824
hidden = true
3825
3826
[[example]]
3827
name = "window_resizing"
3828
path = "examples/window/window_resizing.rs"
3829
doc-scrape-examples = true
3830
3831
[[example]]
3832
name = "fallback_image"
3833
path = "examples/shader/fallback_image.rs"
3834
doc-scrape-examples = true
3835
3836
[[example]]
3837
name = "reflection_probes"
3838
path = "examples/3d/reflection_probes.rs"
3839
doc-scrape-examples = true
3840
3841
[package.metadata.example.reflection_probes]
3842
name = "Reflection Probes"
3843
description = "Demonstrates reflection probes"
3844
category = "3D Rendering"
3845
wasm = false
3846
3847
[package.metadata.example.fallback_image]
3848
hidden = true
3849
3850
[package.metadata.example.window_resizing]
3851
name = "Window Resizing"
3852
description = "Demonstrates resizing and responding to resizing a window"
3853
category = "Window"
3854
wasm = true
3855
3856
[[example]]
3857
name = "drag_to_scroll"
3858
path = "examples/ui/drag_to_scroll.rs"
3859
doc-scrape-examples = true
3860
3861
[package.metadata.example.drag_to_scroll]
3862
name = "Drag to Scroll"
3863
description = "This example tests scale factor, dragging and scrolling"
3864
category = "UI (User Interface)"
3865
wasm = true
3866
3867
[[example]]
3868
name = "ui_material"
3869
path = "examples/ui/ui_material.rs"
3870
doc-scrape-examples = true
3871
3872
[package.metadata.example.ui_material]
3873
name = "UI Material"
3874
description = "Demonstrates creating and using custom Ui materials"
3875
category = "UI (User Interface)"
3876
wasm = true
3877
3878
[[example]]
3879
name = "cubic_splines"
3880
path = "examples/math/cubic_splines.rs"
3881
doc-scrape-examples = true
3882
3883
[package.metadata.example.cubic_splines]
3884
name = "Cubic Splines"
3885
description = "Exhibits different modes of constructing cubic curves using splines"
3886
category = "Math"
3887
wasm = true
3888
3889
[[example]]
3890
name = "render_primitives"
3891
path = "examples/math/render_primitives.rs"
3892
doc-scrape-examples = true
3893
3894
[package.metadata.example.render_primitives]
3895
name = "Rendering Primitives"
3896
description = "Shows off rendering for all math primitives as both Meshes and Gizmos"
3897
category = "Math"
3898
wasm = true
3899
3900
# Math
3901
[[example]]
3902
name = "sampling_primitives"
3903
path = "examples/math/sampling_primitives.rs"
3904
doc-scrape-examples = true
3905
3906
[package.metadata.example.sampling_primitives]
3907
name = "Sampling Primitives"
3908
description = "Demonstrates all the primitives which can be sampled."
3909
category = "Math"
3910
wasm = true
3911
3912
[[example]]
3913
name = "custom_primitives"
3914
path = "examples/math/custom_primitives.rs"
3915
doc-scrape-examples = true
3916
3917
[package.metadata.example.custom_primitives]
3918
name = "Custom Primitives"
3919
description = "Demonstrates how to add custom primitives and useful traits for them."
3920
category = "Math"
3921
wasm = true
3922
3923
[[example]]
3924
name = "random_sampling"
3925
path = "examples/math/random_sampling.rs"
3926
doc-scrape-examples = true
3927
3928
[package.metadata.example.random_sampling]
3929
name = "Random Sampling"
3930
description = "Demonstrates how to sample random points from mathematical primitives"
3931
category = "Math"
3932
wasm = true
3933
3934
[[example]]
3935
name = "smooth_follow"
3936
path = "examples/movement/smooth_follow.rs"
3937
doc-scrape-examples = true
3938
3939
[package.metadata.example.smooth_follow]
3940
name = "Smooth Follow"
3941
description = "Demonstrates how to make an entity smoothly follow another using interpolation"
3942
category = "Math"
3943
wasm = true
3944
3945
# Gizmos
3946
[[example]]
3947
name = "2d_gizmos"
3948
path = "examples/gizmos/2d_gizmos.rs"
3949
doc-scrape-examples = true
3950
3951
[package.metadata.example.2d_gizmos]
3952
name = "2D Gizmos"
3953
description = "A scene showcasing 2D gizmos"
3954
category = "Gizmos"
3955
wasm = true
3956
3957
[[example]]
3958
name = "3d_gizmos"
3959
path = "examples/gizmos/3d_gizmos.rs"
3960
doc-scrape-examples = true
3961
3962
[package.metadata.example.3d_gizmos]
3963
name = "3D Gizmos"
3964
description = "A scene showcasing 3D gizmos"
3965
category = "Gizmos"
3966
wasm = true
3967
3968
[[example]]
3969
name = "axes"
3970
path = "examples/gizmos/axes.rs"
3971
doc-scrape-examples = true
3972
3973
[package.metadata.example.axes]
3974
name = "Axes"
3975
description = "Demonstrates the function of axes gizmos"
3976
category = "Gizmos"
3977
wasm = true
3978
3979
[[example]]
3980
name = "light_gizmos"
3981
path = "examples/gizmos/light_gizmos.rs"
3982
doc-scrape-examples = true
3983
3984
[package.metadata.example.light_gizmos]
3985
name = "Light Gizmos"
3986
description = "A scene showcasing light gizmos"
3987
category = "Gizmos"
3988
wasm = true
3989
3990
[[example]]
3991
name = "custom_gltf_vertex_attribute"
3992
path = "examples/gltf/custom_gltf_vertex_attribute.rs"
3993
doc-scrape-examples = true
3994
3995
[package.metadata.example.custom_gltf_vertex_attribute]
3996
name = "Custom glTF vertex attribute 2D"
3997
description = "Renders a glTF mesh in 2D with a custom vertex attribute"
3998
category = "glTF"
3999
wasm = true
4000
4001
[[example]]
4002
name = "edit_material_on_gltf"
4003
path = "examples/gltf/edit_material_on_gltf.rs"
4004
doc-scrape-examples = true
4005
4006
[package.metadata.example.edit_material_on_gltf]
4007
name = "Edit glTF Material"
4008
description = "Showcases changing materials of a glTF after Scene spawn"
4009
category = "glTF"
4010
wasm = true
4011
4012
[[example]]
4013
name = "gltf_skinned_mesh"
4014
path = "examples/gltf/gltf_skinned_mesh.rs"
4015
doc-scrape-examples = true
4016
4017
[package.metadata.example.gltf_skinned_mesh]
4018
name = "glTF Skinned Mesh"
4019
description = "Skinned mesh example with mesh and joints data loaded from a glTF file"
4020
category = "glTF"
4021
wasm = true
4022
4023
[[example]]
4024
name = "load_gltf"
4025
path = "examples/gltf/load_gltf.rs"
4026
doc-scrape-examples = true
4027
4028
[package.metadata.example.load_gltf]
4029
name = "Load glTF"
4030
description = "Loads and renders a glTF file as a scene"
4031
category = "glTF"
4032
wasm = true
4033
4034
[[example]]
4035
name = "load_gltf_extras"
4036
path = "examples/gltf/load_gltf_extras.rs"
4037
doc-scrape-examples = true
4038
4039
[package.metadata.example.load_gltf_extras]
4040
name = "Load glTF extras"
4041
description = "Loads and renders a glTF file as a scene, including the gltf extras"
4042
category = "glTF"
4043
wasm = true
4044
4045
[[example]]
4046
name = "query_gltf_primitives"
4047
path = "examples/gltf/query_gltf_primitives.rs"
4048
doc-scrape-examples = true
4049
4050
[package.metadata.example.query_gltf_primitives]
4051
name = "Query glTF primitives"
4052
description = "Query primitives in a glTF scene"
4053
category = "glTF"
4054
wasm = true
4055
4056
[[example]]
4057
name = "update_gltf_scene"
4058
path = "examples/gltf/update_gltf_scene.rs"
4059
doc-scrape-examples = true
4060
4061
[package.metadata.example.update_gltf_scene]
4062
name = "Update glTF Scene"
4063
description = "Update a scene from a glTF file, either by spawning the scene as a child of another entity, or by accessing the entities of the scene"
4064
category = "glTF"
4065
wasm = true
4066
4067
[[example]]
4068
name = "fps_overlay"
4069
path = "examples/dev_tools/fps_overlay.rs"
4070
doc-scrape-examples = true
4071
required-features = ["bevy_dev_tools"]
4072
4073
[[example]]
4074
name = "2d_top_down_camera"
4075
path = "examples/camera/2d_top_down_camera.rs"
4076
doc-scrape-examples = true
4077
4078
[package.metadata.example.2d_top_down_camera]
4079
name = "2D top-down camera"
4080
description = "A 2D top-down camera smoothly following player movements"
4081
category = "Camera"
4082
wasm = true
4083
4084
[[example]]
4085
name = "custom_projection"
4086
path = "examples/camera/custom_projection.rs"
4087
doc-scrape-examples = true
4088
4089
[package.metadata.example.custom_projection]
4090
name = "Custom Projection"
4091
description = "Shows how to create custom camera projections."
4092
category = "Camera"
4093
wasm = true
4094
4095
[[example]]
4096
name = "first_person_view_model"
4097
path = "examples/camera/first_person_view_model.rs"
4098
doc-scrape-examples = true
4099
4100
[package.metadata.example.first_person_view_model]
4101
name = "First person view model"
4102
description = "A first-person camera that uses a world model and a view model with different field of views (FOV)"
4103
category = "Camera"
4104
wasm = true
4105
4106
[[example]]
4107
name = "projection_zoom"
4108
path = "examples/camera/projection_zoom.rs"
4109
doc-scrape-examples = true
4110
4111
[package.metadata.example.projection_zoom]
4112
name = "Projection Zoom"
4113
description = "Shows how to zoom orthographic and perspective projection cameras."
4114
category = "Camera"
4115
wasm = true
4116
4117
[[example]]
4118
name = "camera_orbit"
4119
path = "examples/camera/camera_orbit.rs"
4120
doc-scrape-examples = true
4121
4122
[package.metadata.example.camera_orbit]
4123
name = "Camera Orbit"
4124
description = "Shows how to orbit a static scene using pitch, yaw, and roll."
4125
category = "Camera"
4126
wasm = true
4127
4128
[[example]]
4129
name = "2d_screen_shake"
4130
path = "examples/camera/2d_screen_shake.rs"
4131
doc-scrape-examples = true
4132
4133
[package.metadata.example.2d_screen_shake]
4134
name = "Screen Shake"
4135
description = "A simple 2D screen shake effect"
4136
category = "Camera"
4137
wasm = true
4138
4139
[[example]]
4140
name = "2d_on_ui"
4141
path = "examples/camera/2d_on_ui.rs"
4142
doc-scrape-examples = true
4143
4144
[package.metadata.example.2d_on_ui]
4145
name = "2D on Bevy UI"
4146
description = "Shows how to render 2D objects on top of Bevy UI"
4147
category = "Camera"
4148
wasm = true
4149
4150
[package.metadata.example.fps_overlay]
4151
name = "FPS overlay"
4152
description = "Demonstrates FPS overlay"
4153
category = "Dev tools"
4154
wasm = true
4155
4156
[[example]]
4157
name = "visibility_range"
4158
path = "examples/3d/visibility_range.rs"
4159
doc-scrape-examples = true
4160
4161
[package.metadata.example.visibility_range]
4162
name = "Visibility range"
4163
description = "Demonstrates visibility ranges"
4164
category = "3D Rendering"
4165
wasm = true
4166
4167
[[example]]
4168
name = "ssr"
4169
path = "examples/3d/ssr.rs"
4170
doc-scrape-examples = true
4171
4172
[package.metadata.example.ssr]
4173
name = "Screen Space Reflections"
4174
description = "Demonstrates screen space reflections with water ripples"
4175
category = "3D Rendering"
4176
wasm = false
4177
4178
[[example]]
4179
name = "camera_sub_view"
4180
path = "examples/3d/camera_sub_view.rs"
4181
doc-scrape-examples = true
4182
4183
[package.metadata.example.camera_sub_view]
4184
name = "Camera sub view"
4185
description = "Demonstrates using different sub view effects on a camera"
4186
category = "3D Rendering"
4187
wasm = true
4188
4189
[[example]]
4190
name = "color_grading"
4191
path = "examples/3d/color_grading.rs"
4192
doc-scrape-examples = true
4193
4194
[package.metadata.example.color_grading]
4195
name = "Color grading"
4196
description = "Demonstrates color grading"
4197
category = "3D Rendering"
4198
wasm = true
4199
4200
[[example]]
4201
name = "clearcoat"
4202
path = "examples/3d/clearcoat.rs"
4203
doc-scrape-examples = true
4204
required-features = ["pbr_multi_layer_material_textures"]
4205
4206
[package.metadata.example.clearcoat]
4207
name = "Clearcoat"
4208
description = "Demonstrates the clearcoat PBR feature"
4209
category = "3D Rendering"
4210
wasm = false
4211
4212
[[example]]
4213
name = "depth_of_field"
4214
path = "examples/3d/depth_of_field.rs"
4215
doc-scrape-examples = true
4216
4217
[package.metadata.example.depth_of_field]
4218
name = "Depth of field"
4219
description = "Demonstrates depth of field"
4220
category = "3D Rendering"
4221
wasm = false
4222
4223
[[example]]
4224
name = "volumetric_fog"
4225
path = "examples/3d/volumetric_fog.rs"
4226
doc-scrape-examples = true
4227
4228
[package.metadata.example.volumetric_fog]
4229
name = "Volumetric fog"
4230
description = "Demonstrates volumetric fog and lighting"
4231
category = "3D Rendering"
4232
wasm = true
4233
4234
[[example]]
4235
name = "client"
4236
path = "examples/remote/client.rs"
4237
doc-scrape-examples = true
4238
required-features = ["bevy_remote"]
4239
4240
[package.metadata.example.client]
4241
name = "client"
4242
description = "A simple command line client that can control Bevy apps via the BRP"
4243
category = "Remote Protocol"
4244
wasm = false
4245
4246
[[example]]
4247
name = "server"
4248
path = "examples/remote/server.rs"
4249
doc-scrape-examples = true
4250
required-features = ["bevy_remote"]
4251
4252
[package.metadata.example.server]
4253
name = "server"
4254
description = "A Bevy app that you can connect to with the BRP and edit"
4255
category = "Remote Protocol"
4256
wasm = false
4257
4258
[[example]]
4259
name = "anisotropy"
4260
path = "examples/3d/anisotropy.rs"
4261
doc-scrape-examples = true
4262
required-features = ["jpeg", "pbr_anisotropy_texture"]
4263
4264
[package.metadata.example.anisotropy]
4265
name = "Anisotropy"
4266
description = "Displays an example model with anisotropy"
4267
category = "3D Rendering"
4268
wasm = false
4269
4270
[[example]]
4271
name = "custom_phase_item"
4272
path = "examples/shader_advanced/custom_phase_item.rs"
4273
doc-scrape-examples = true
4274
4275
[package.metadata.example.custom_phase_item]
4276
name = "Custom phase item"
4277
description = "Demonstrates how to enqueue custom draw commands in a render phase"
4278
category = "Shaders"
4279
wasm = true
4280
4281
[[example]]
4282
name = "fog_volumes"
4283
path = "examples/3d/fog_volumes.rs"
4284
doc-scrape-examples = true
4285
4286
[package.metadata.example.fog_volumes]
4287
name = "Fog volumes"
4288
description = "Demonstrates fog volumes"
4289
category = "3D Rendering"
4290
wasm = false
4291
4292
[[example]]
4293
name = "scrolling_fog"
4294
path = "examples/3d/scrolling_fog.rs"
4295
doc-scrape-examples = true
4296
4297
[package.metadata.example.scrolling_fog]
4298
name = "Scrolling fog"
4299
description = "Demonstrates how to create the effect of fog moving in the wind"
4300
category = "3D Rendering"
4301
wasm = false
4302
4303
[[example]]
4304
name = "physics_in_fixed_timestep"
4305
path = "examples/movement/physics_in_fixed_timestep.rs"
4306
doc-scrape-examples = true
4307
4308
[package.metadata.example.physics_in_fixed_timestep]
4309
name = "Run physics in a fixed timestep"
4310
description = "Handles input, physics, and rendering in an industry-standard way by using a fixed timestep"
4311
category = "Movement"
4312
wasm = true
4313
4314
[[example]]
4315
name = "post_processing"
4316
path = "examples/3d/post_processing.rs"
4317
doc-scrape-examples = true
4318
4319
[package.metadata.example.post_processing]
4320
name = "Built-in postprocessing"
4321
description = "Demonstrates the built-in postprocessing features"
4322
category = "3D Rendering"
4323
wasm = true
4324
4325
[[example]]
4326
name = "rotate_environment_map"
4327
path = "examples/3d/rotate_environment_map.rs"
4328
doc-scrape-examples = true
4329
required-features = ["pbr_multi_layer_material_textures"]
4330
4331
[package.metadata.example.rotate_environment_map]
4332
name = "Rotate Environment Map"
4333
description = "Demonstrates how to rotate the skybox and the environment map simultaneously"
4334
category = "3D Rendering"
4335
wasm = false
4336
4337
[[example]]
4338
name = "mesh_picking"
4339
path = "examples/picking/mesh_picking.rs"
4340
doc-scrape-examples = true
4341
required-features = ["bevy_mesh_picking_backend"]
4342
4343
[package.metadata.example.mesh_picking]
4344
name = "Mesh Picking"
4345
description = "Demonstrates picking meshes"
4346
category = "Picking"
4347
wasm = true
4348
4349
[[example]]
4350
name = "simple_picking"
4351
path = "examples/picking/simple_picking.rs"
4352
doc-scrape-examples = true
4353
required-features = ["bevy_picking"]
4354
4355
[package.metadata.example.simple_picking]
4356
name = "Showcases simple picking events and usage"
4357
description = "Demonstrates how to use picking events to spawn simple objects"
4358
category = "Picking"
4359
wasm = true
4360
4361
[[example]]
4362
name = "sprite_picking"
4363
path = "examples/picking/sprite_picking.rs"
4364
doc-scrape-examples = true
4365
required-features = ["bevy_sprite_picking_backend"]
4366
4367
[package.metadata.example.sprite_picking]
4368
name = "Sprite Picking"
4369
description = "Demonstrates picking sprites and sprite atlases"
4370
category = "Picking"
4371
wasm = true
4372
4373
[[example]]
4374
name = "debug_picking"
4375
path = "examples/picking/debug_picking.rs"
4376
doc-scrape-examples = true
4377
required-features = ["bevy_dev_tools"]
4378
4379
[package.metadata.example.debug_picking]
4380
name = "Picking Debug Tools"
4381
description = "Demonstrates picking debug overlay"
4382
category = "Picking"
4383
wasm = true
4384
4385
[[example]]
4386
name = "animation_masks"
4387
path = "examples/animation/animation_masks.rs"
4388
doc-scrape-examples = true
4389
4390
[package.metadata.example.animation_masks]
4391
name = "Animation Masks"
4392
description = "Demonstrates animation masks"
4393
category = "Animation"
4394
wasm = true
4395
4396
[[example]]
4397
name = "pcss"
4398
path = "examples/3d/pcss.rs"
4399
doc-scrape-examples = true
4400
required-features = ["experimental_pbr_pcss"]
4401
4402
[package.metadata.example.pcss]
4403
name = "Percentage-closer soft shadows"
4404
description = "Demonstrates percentage-closer soft shadows (PCSS)"
4405
category = "3D Rendering"
4406
wasm = false
4407
4408
[[example]]
4409
name = "mixed_lighting"
4410
path = "examples/3d/mixed_lighting.rs"
4411
doc-scrape-examples = true
4412
required-features = ["jpeg"]
4413
4414
[package.metadata.example.mixed_lighting]
4415
name = "Mixed lighting"
4416
description = "Demonstrates how to combine baked and dynamic lighting"
4417
category = "3D Rendering"
4418
wasm = true
4419
4420
[[example]]
4421
name = "animated_ui"
4422
path = "examples/animation/animated_ui.rs"
4423
doc-scrape-examples = true
4424
4425
[package.metadata.example.animated_ui]
4426
name = "Animated UI"
4427
description = "Shows how to use animation clips to animate UI properties"
4428
category = "Animation"
4429
wasm = true
4430
4431
[[example]]
4432
name = "shader_material_bindless"
4433
path = "examples/shader/shader_material_bindless.rs"
4434
doc-scrape-examples = true
4435
4436
[package.metadata.example.shader_material_bindless]
4437
name = "Material - Bindless"
4438
description = "Demonstrates how to make materials that use bindless textures"
4439
category = "Shaders"
4440
wasm = true
4441
4442
[[example]]
4443
name = "specular_tint"
4444
path = "examples/3d/specular_tint.rs"
4445
doc-scrape-examples = true
4446
required-features = ["pbr_specular_textures"]
4447
4448
[package.metadata.example.specular_tint]
4449
name = "Specular Tint"
4450
description = "Demonstrates specular tints and maps"
4451
category = "3D Rendering"
4452
wasm = true
4453
4454
[[example]]
4455
name = "test_invalid_skinned_mesh"
4456
path = "tests/3d/test_invalid_skinned_mesh.rs"
4457
doc-scrape-examples = true
4458
4459
[package.metadata.example.test_invalid_skinned_mesh]
4460
hidden = true
4461
4462
[profile.wasm-release]
4463
inherits = "release"
4464
opt-level = "z"
4465
lto = "fat"
4466
codegen-units = 1
4467
4468
[profile.stress-test]
4469
inherits = "release"
4470
lto = "fat"
4471
panic = "abort"
4472
4473
[package.metadata.docs.rs]
4474
# This cfg is needed so that #[doc(fake_variadic)] is correctly propagated for
4475
# impls for re-exported traits. See https://github.com/rust-lang/cargo/issues/8811
4476
# for details on why this is needed. Since dependencies don't expect to be built
4477
# with `--cfg docsrs` (and thus fail to compile) we use a different cfg.
4478
rustc-args = ["--cfg", "docsrs_dep"]
4479
rustdoc-args = [
4480
"-Zunstable-options",
4481
"--generate-link-to-definition",
4482
# Embed tags to the top of documentation pages for common Bevy traits
4483
# that are implemented by the current type, like `Component` or `Resource`.
4484
# This makes it easier to see at a glance what types are used for.
4485
"--html-after-content",
4486
"docs-rs/trait-tags.html",
4487
]
4488
all-features = true
4489
cargo-args = ["-Zunstable-options", "-Zrustdoc-scrape-examples"]
4490
4491
[[example]]
4492
name = "monitor_info"
4493
path = "examples/window/monitor_info.rs"
4494
doc-scrape-examples = true
4495
4496
[package.metadata.example.monitor_info]
4497
name = "Monitor info"
4498
description = "Displays information about available monitors (displays)."
4499
category = "Window"
4500
wasm = false
4501
4502
# Testbed
4503
[[example]]
4504
name = "testbed_2d"
4505
path = "examples/testbed/2d.rs"
4506
doc-scrape-examples = true
4507
4508
[package.metadata.example.testbed_2d]
4509
hidden = true
4510
4511
[[example]]
4512
name = "testbed_3d"
4513
path = "examples/testbed/3d.rs"
4514
doc-scrape-examples = true
4515
4516
[package.metadata.example.testbed_3d]
4517
hidden = true
4518
4519
[[example]]
4520
name = "testbed_ui"
4521
path = "examples/testbed/ui.rs"
4522
doc-scrape-examples = true
4523
4524
[package.metadata.example.testbed_ui]
4525
hidden = true
4526
4527
[[example]]
4528
name = "testbed_full_ui"
4529
path = "examples/testbed/full_ui.rs"
4530
doc-scrape-examples = true
4531
required-features = ["experimental_bevy_ui_widgets"]
4532
4533
[package.metadata.example.testbed_full_ui]
4534
hidden = true
4535
4536
[[example]]
4537
name = "tab_navigation"
4538
path = "examples/ui/tab_navigation.rs"
4539
doc-scrape-examples = true
4540
4541
[package.metadata.example.tab_navigation]
4542
name = "Tab Navigation"
4543
description = "Demonstration of Tab Navigation between UI elements"
4544
category = "UI (User Interface)"
4545
wasm = true
4546
4547
[[example]]
4548
name = "directional_navigation"
4549
path = "examples/ui/directional_navigation.rs"
4550
doc-scrape-examples = true
4551
4552
[package.metadata.example.directional_navigation]
4553
name = "Directional Navigation"
4554
description = "Demonstration of Directional Navigation between UI elements"
4555
category = "UI (User Interface)"
4556
wasm = true
4557
4558
[[example]]
4559
name = "clustered_decals"
4560
path = "examples/3d/clustered_decals.rs"
4561
doc-scrape-examples = true
4562
required-features = ["pbr_clustered_decals"]
4563
4564
[package.metadata.example.clustered_decals]
4565
name = "Clustered Decals"
4566
description = "Demonstrates clustered decals"
4567
category = "3D Rendering"
4568
wasm = false
4569
4570
[[example]]
4571
name = "light_textures"
4572
path = "examples/3d/light_textures.rs"
4573
doc-scrape-examples = true
4574
required-features = ["pbr_light_textures"]
4575
4576
[package.metadata.example.light_textures]
4577
name = "Light Textures"
4578
description = "Demonstrates light textures"
4579
category = "3D Rendering"
4580
wasm = false
4581
4582
[[example]]
4583
name = "occlusion_culling"
4584
path = "examples/3d/occlusion_culling.rs"
4585
doc-scrape-examples = true
4586
4587
[package.metadata.example.occlusion_culling]
4588
name = "Occlusion Culling"
4589
description = "Demonstration of Occlusion Culling"
4590
category = "3D Rendering"
4591
wasm = false
4592
4593
[[example]]
4594
name = "camera_controller"
4595
path = "examples/helpers/camera_controller.rs"
4596
doc-scrape-examples = true
4597
crate-type = ["lib"]
4598
4599
[package.metadata.example.camera_controller]
4600
name = "Camera Controller"
4601
description = "Example Free-Cam Styled Camera Controller"
4602
category = "Helpers"
4603
wasm = true
4604
4605
[[example]]
4606
name = "widgets"
4607
path = "examples/helpers/widgets.rs"
4608
doc-scrape-examples = true
4609
crate-type = ["lib"]
4610
4611
[package.metadata.example.widgets]
4612
name = "Widgets"
4613
description = "Example UI Widgets"
4614
category = "Helpers"
4615
wasm = true
4616
4617
[[example]]
4618
name = "no_std_library"
4619
path = "examples/no_std/library/src/lib.rs"
4620
doc-scrape-examples = true
4621
crate-type = ["lib"]
4622
4623
[package.metadata.example.no_std_library]
4624
name = "`no_std` Compatible Library"
4625
description = "Example library compatible with `std` and `no_std` targets"
4626
category = "Embedded"
4627
wasm = true
4628
4629
[[example]]
4630
name = "extended_material_bindless"
4631
path = "examples/shader/extended_material_bindless.rs"
4632
doc-scrape-examples = true
4633
4634
[package.metadata.example.extended_material_bindless]
4635
name = "Extended Bindless Material"
4636
description = "Demonstrates bindless `ExtendedMaterial`"
4637
category = "Shaders"
4638
wasm = false
4639
4640
[[example]]
4641
name = "cooldown"
4642
path = "examples/usage/cooldown.rs"
4643
doc-scrape-examples = true
4644
4645
[package.metadata.example.cooldown]
4646
name = "Cooldown"
4647
description = "Example for cooldown on button clicks"
4648
category = "Usage"
4649
wasm = true
4650
4651
[[example]]
4652
name = "hotpatching_systems"
4653
path = "examples/ecs/hotpatching_systems.rs"
4654
doc-scrape-examples = true
4655
required-features = ["hotpatching"]
4656
4657
[package.metadata.example.hotpatching_systems]
4658
name = "Hotpatching Systems"
4659
description = "Demonstrates how to hotpatch systems"
4660
category = "ECS (Entity Component System)"
4661
wasm = false
4662
4663
[[example]]
4664
name = "standard_widgets"
4665
path = "examples/ui/standard_widgets.rs"
4666
doc-scrape-examples = true
4667
required-features = ["experimental_bevy_ui_widgets"]
4668
4669
[package.metadata.example.standard_widgets]
4670
name = "Standard Widgets"
4671
description = "Demonstrates use of core (headless) widgets in Bevy UI"
4672
category = "UI (User Interface)"
4673
wasm = true
4674
4675
[[example]]
4676
name = "standard_widgets_observers"
4677
path = "examples/ui/standard_widgets_observers.rs"
4678
doc-scrape-examples = true
4679
required-features = ["experimental_bevy_ui_widgets"]
4680
4681
[package.metadata.example.standard_widgets_observers]
4682
name = "Standard Widgets (w/Observers)"
4683
description = "Demonstrates use of core (headless) widgets in Bevy UI, with Observers"
4684
category = "UI (User Interface)"
4685
wasm = true
4686
4687
[[example]]
4688
name = "scrollbars"
4689
path = "examples/ui/scrollbars.rs"
4690
doc-scrape-examples = true
4691
required-features = ["experimental_bevy_ui_widgets"]
4692
4693
[package.metadata.example.scrollbars]
4694
name = "Scrollbars"
4695
description = "Demonstrates use of core scrollbar in Bevy UI"
4696
category = "UI (User Interface)"
4697
wasm = true
4698
4699
[[example]]
4700
name = "feathers"
4701
path = "examples/ui/feathers.rs"
4702
doc-scrape-examples = true
4703
required-features = ["experimental_bevy_feathers"]
4704
4705
[package.metadata.example.feathers]
4706
name = "Feathers Widgets"
4707
description = "Gallery of Feathers Widgets"
4708
category = "UI (User Interface)"
4709
wasm = true
4710
hidden = true
4711
4712
[[example]]
4713
name = "render_depth_to_texture"
4714
path = "examples/shader_advanced/render_depth_to_texture.rs"
4715
doc-scrape-examples = true
4716
4717
[package.metadata.example.render_depth_to_texture]
4718
name = "Render Depth to Texture"
4719
description = "Demonstrates how to use depth-only cameras"
4720
category = "Shaders"
4721
wasm = true
4722
4723