diff --git a/content/news/2024-02-17-bevy-0.13/2d_shapes.png b/content/news/2024-02-17-bevy-0.13/2d_shapes.png new file mode 100644 index 0000000000..b7df70c1b4 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/2d_shapes.png differ diff --git a/content/news/2024-02-17-bevy-0.13/3d_shapes.png b/content/news/2024-02-17-bevy-0.13/3d_shapes.png new file mode 100644 index 0000000000..6bd4a8ac3c Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/3d_shapes.png differ diff --git a/content/news/2024-02-17-bevy-0.13/San_Miguel_13.jpg b/content/news/2024-02-17-bevy-0.13/San_Miguel_13.jpg new file mode 100644 index 0000000000..08a023cac3 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/San_Miguel_13.jpg differ diff --git a/content/news/2024-02-17-bevy-0.13/better_batching.svg b/content/news/2024-02-17-bevy-0.13/better_batching.svg new file mode 100644 index 0000000000..753c569fef --- /dev/null +++ b/content/news/2024-02-17-bevy-0.13/better_batching.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/content/news/2024-02-17-bevy-0.13/bevy_components.jpg b/content/news/2024-02-17-bevy-0.13/bevy_components.jpg new file mode 100644 index 0000000000..f7b5ca1587 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/bevy_components.jpg differ diff --git a/content/news/2024-02-17-bevy-0.13/bounding_intersections.mp4 b/content/news/2024-02-17-bevy-0.13/bounding_intersections.mp4 new file mode 100644 index 0000000000..be0878911f Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/bounding_intersections.mp4 differ diff --git a/content/news/2024-02-17-bevy-0.13/cuboids.png b/content/news/2024-02-17-bevy-0.13/cuboids.png new file mode 100644 index 0000000000..f0a4ba3685 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/cuboids.png differ diff --git a/content/news/2024-02-17-bevy-0.13/editor_mockup.png b/content/news/2024-02-17-bevy-0.13/editor_mockup.png new file mode 100644 index 0000000000..16331abac9 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/editor_mockup.png differ diff --git a/content/news/2024-02-17-bevy-0.13/entity_hash_optimsation_benches.png b/content/news/2024-02-17-bevy-0.13/entity_hash_optimsation_benches.png new file mode 100644 index 0000000000..28348255d3 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/entity_hash_optimsation_benches.png differ diff --git a/content/news/2024-02-17-bevy-0.13/exposure_15.jpg b/content/news/2024-02-17-bevy-0.13/exposure_15.jpg new file mode 100644 index 0000000000..336dd0b932 Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/exposure_15.jpg differ diff --git a/content/news/2024-02-17-bevy-0.13/exposure_97.jpg b/content/news/2024-02-17-bevy-0.13/exposure_97.jpg new file mode 100644 index 0000000000..07d57d172c Binary files /dev/null and b/content/news/2024-02-17-bevy-0.13/exposure_97.jpg differ diff --git a/content/news/2024-02-17-bevy-0.13/index.md b/content/news/2024-02-17-bevy-0.13/index.md new file mode 100644 index 0000000000..cb6e0e1867 --- /dev/null +++ b/content/news/2024-02-17-bevy-0.13/index.md @@ -0,0 +1,3214 @@ ++++ +title = "Bevy 0.13" +date = 2024-02-17 +[extra] +author = "Bevy Contributors" +image = "jarl.webp" +show_image = true +image_subtitle = "Gameplay from Jarl, an in-production fantasy colony builder made with Bevy" +image_subtitle_link = "https://www.jarl-game.com/" + ++++ + +Thanks to **198** contributors, **672** pull requests, community reviewers, and our [**generous sponsors**](/community/donate), we're happy to announce the **Bevy 0.13** release on [crates.io](https://crates.io/crates/bevy)! + +For those who don't know, Bevy is a refreshingly simple data-driven game engine built in Rust. You can check out our [Quick Start Guide](/learn/book/getting-started/) to try it today. It's free and open source forever! You can grab the full [source code](https://github.com/bevyengine/bevy) on GitHub. Check out [Bevy Assets](https://bevyengine.org/assets) for a collection of community-developed plugins, games, and learning resources. +And to see what the engine has to offer hands-on, check out the entries in the [latest Bevy Jam](https://itch.io/jam/bevy-jam-4/entries), including the winner [That's a LOT of beeeeees](https://andrewb330.itch.io/thats-a-lot-of-beeeeees). + +To update an existing Bevy App or Plugin to **Bevy 0.13**, check out our [0.12 to 0.13 Migration Guide](/learn/migration-guides/0.12-0.13/). + +Since our last release a few months ago we've added a _ton_ of new features, bug fixes, and quality of life tweaks, but here are some of the highlights: + + + +* **Lightmaps:** A fast, popular baked global illumination technique for static geometry (baked externally in programs like The Lightmapper). +* **Irradiance Volumes / Voxel Global Illumination:** A baked form of global illumination that samples light at the centers of voxels within a cuboid (baked externally in programs like Blender). +* **Approximate Indirect Specular Occlusion**: Improved lighting realism by reducing specular light leaking via specular occlusion. +* **Reflection Probes**: A baked form of axis aligned environment map that allows for realistic reflections for static geometry (baked externally in programs like Blender) +* **Primitive shapes:** Basic shapes are a core building block of both game engines and video games: we've added a polished, ready-to-use collection of them! +* **System stepping:** Completely pause and advance through your game frame-by-frame or system-by-system to interactively debug game logic, all while rendering continues to update. +* **Dynamic queries:** Refining queries from within systems is extremely expressive, and is the last big puzzle piece for runtime-defined types and third-party modding and scripting integration. +* **Automatically inferred command flush points:** Tired of reasoning about where to put `apply_deferred` and confused about why your commands weren't being applied? Us too! Now, Bevy's scheduler uses ordinary `.before` and `.after` constraints and inspects the system parameters to automatically infer (and deduplicate) synchronization points. +* **Slicing, tiling and nine-patch 2D images:** Ninepatch layout is a popular tool for smoothly scaling stylized tilesets and UIs. Now in Bevy! +* **Camera-Driven UI**: UI entity trees can now be selectively added to _any_ camera, rather than being globally applied to all cameras, enabling things like split screen UIs! +* **Camera Exposure**: Realistic / "real world" control over camera exposure via EV100, f-stops, shutter speed, and ISO sensitivity. Lights have also been adjusted to make their units more realistic. +* **Animation interpolation modes:** Bevy now supports non-linear interpolation modes in exported glTF animations. + +## Initial Baked Lighting + +Computing lighting in real time is expensive; +but for elements of a scene that never move (like rooms or terrain), +we can get prettier lighting and shadows for cheaper by computing it ahead of time using **global illumination**, +then storing the results in a "baked" form that never changes. +Global illumination is a more realistic (and expensive) approach to lighting that often uses ray tracing. +Unlike Bevy's default rendering, it takes light bouncing off of other objects into account, +producing more realistic effects through the inclusion of indirect light. + +### Lightmaps + +
+ +![lightmaps](lightmap.jpg) + +**Lightmaps** are textures that store pre-computed global illumination results. They have been a mainstay of real-time graphics for decades. **Bevy 0.13** adds initial support for rendering lightmaps computed in other programs, such as [The Lightmapper]. Ultimately we would like to add support for baking lightmaps directly in Bevy, but this first step unlocks lightmap workflows! + +Like the [lightmaps example] shows, just load in your baked lightmap image, and then insert a [`Lightmap`] component on the corresponding mesh. + +[`Lightmap`]: https://docs.rs/bevy/0.13.0/bevy/pbr/struct.Lightmap.html +[lightmaps example]: https://github.com/bevyengine/bevy/blob/main/examples/3d/lightmaps.rs +[The Lightmapper]: https://github.com/Naxela/The_Lightmapper + +### Irradiance Volumes / Voxel Global Illumination + + + +![irradiance volume](irradiance_volume.jpg) + +**Irradiance volumes** (or voxel global illumination) is a technique used for approximating indirect light by first dividing +a scene into cubes (voxels), then sampling the amount of light present at the center of each of those voxels. +This light is then added to objects within that space as they move through it, changing the ambient light level on those objects appropriately. + +We've chosen to use the ambient cubes algorithm for this, based on Half Life 2. +This allows us to match Blender's [Eevee renderer], giving users a simple and free path to creating nice-looking irradiance volumes for their own scenes. + +Notice how this sphere subtly picks up the colors of the environment as it moves around, thanks to irradiance volumes: + + + +For now, you need to use external tools such as Blender to bake irradiance volumes, but in the future we would like to support baking irradiance volumes directly in Bevy! + +[Eevee renderer]: https://docs.blender.org/manual/en/latest/render/eevee/index.html + +## Minimal Reflection Probes + + + +**Environment maps** are 2D textures used to simulate lighting, reflection, and skyboxes in a 3D scene. +**Reflection probes** generalize environment maps to allow for multiple environment maps in the same scene, each of which has its own axis-aligned bounding box. +This is a standard feature of physically-based renderers and was inspired by the [corresponding feature in Blender's Eevee renderer]. + +In the [reflection probes PR], we've added basic support for these, laying the groundwork for pretty, high-performance reflections in Bevy games. +Like with the baked global illumination work discussed above, these must currently be precomputed externally, then imported into Bevy. +As discussed in the PR, there are quite a few caveats: WebGL2 support is effectively non-existent, sharp and sudden transitions will be observed because there's no blending, +and all cubemaps in the world of a given type (diffuse or specular) must have the same size, format, and mipmap count. + +![reflection probes](reflection_probes.jpg) + +[reflection probes PR]: https://github.com/bevyengine/bevy/pull/11366 +[corresponding feature in Blender's Eevee renderer]: https://docs.blender.org/manual/en/latest/render/eevee/light_probes/reflection_cubemaps.html + +## Approximate Indirect Specular Occlusion + + + +Bevy's current PBR renderer over-brightens the image, especially at grazing angles where the fresnel +effect tends to make surfaces behave like mirrors. This over-brightening happens because the +surfaces must reflect _something_, but without path traced or screen-space reflections, the renderer +has to guess _what_ is being reflected. The best guess it can make is to sample the environment cube +map, even if light would've hit something else before reaching the environment light. This artifact, +where light occlusion is ignored, is called specular light leaking. + +Consider a car tire; though the rubber might be shiny, you wouldn't expect it to have bright +specular highlights inside a wheel well, because the car itself is blocking (occluding) the light +that would otherwise cause these reflections. Fully checking for occlusion can be computationally +expensive. + +**Bevy 0.13** adds support for **Approximate Indirect Specular Occlusion**, which uses our existing [Screen Space Ambient Occlusion](/news/bevy-0-11/#screen-space-ambient-occlusion) to _approximate_ specular occlusion, which can run efficiently in real time while still producing reasonably high quality results: + +Drag this image to compare + +