Alright, with the help of a little bit of Earl Grey, I'm feeling ready for my weekly #bevymergetrain. A little sleep deprivation won't stop me from doing a final pass on the community approved #opensource #rust PRs for Bevy!

Follow along, as we review the 11 PRs in our backlog :)

1. https://github.com/bevyengine/bevy/pull/18031

Very nice, I've been looking forward to landing light textures (mmm cookies!) for a couple months. A simple effect (create a mask over a light), but really useful artistically.

Pleased with the quality and reviews, but needs merge conflict resolution. Pinging.

Light Textures by robtfm · Pull Request #18031 · bevyengine/bevy

Objective add support for light textures (also known as light cookies, light functions, and light projectors) Solution add components: /// Add to a [`PointLight`] to add a light texture effect. ...

GitHub
There was some interesting debate in the thread here about "what should we call this". Light cookies is classic, but it's also not a particularly clear term. Light functions, light projectors, even "gobos" have been used. But in the end, this is just "apply texture to light", so we went with that.

The history of the term "light cookie" is actually really interesting. This comes from "cucoloris", which is an old film trick of literally cutting out objects made of plywood or other materials to block lights! The Wikipedia page is quite fun: https://en.wikipedia.org/wiki/Cucoloris

Bad name still though!

Cucoloris - Wikipedia

2. https://github.com/bevyengine/bevy/pull/19196

Improved example descriptions for our fog example :) Straightforward and clear; I really love this work.

Module docs in examples are a really nice #rust patern; you can give a lot of helpful context and motivation. With a review from Charlotte, it's time to merge!

Explanation for the 'classic' fog example by fallible-algebra · Pull Request #19196 · bevyengine/bevy

This is a bit of a test case in writing the explanation for an example whose subject (DistanceFog as a component on cameras) is the focus, but isn't that complicated either. Not certain if this...

GitHub

3. https://github.com/bevyengine/bevy/pull/19414

Networking folks are up to their nonsense again: they really push Bevy's ability to operate generically to its limit. This time, we're taking a look at how to improve ergonomics for entity mapping, used to reconstruct webs of entities across a serialization boundary.

Let Component::map_entities defer to MapEntities by Testare · Pull Request #19414 · bevyengine/bevy

Objective The objective of this PR is to enable Components to use their MapEntities implementation for Component::map_entities. With the improvements to the entity mapping system, there is definite...

GitHub

Oh boy, we're at solution D?! This needs a bit of chewing. Thankfully, this is pretty well-scoped, and we have collaboration across the networking authors, which are the primary consumers right now.

Code is clean, docs are excellent, solution is simple and consistent. I'm happy with this: merging.

Okay, major diversion of meeting-with-Cart complete, it's time to get back to the merge train. Lots of fun #bevy stuff there; search "Notes on" from me on the Bevy Discord to spot updates on BSN, bevy_feathers, ECS advancements, first-party camera controllers and more.

4. https://github.com/bevyengine/bevy/pull/19192

Okay, apparently tilemap chunk rendering has been approved by our SME-Rendering?? Was not expecting this today, but I'll take it! The core ideas here are a) Bevy should really be shipping with tilemap support for 2D games and b) efficient rendering is hard.

Update doc about Windows CursorGrabMode support by jf908 · Pull Request #19192 · bevyengine/bevy

Objective Windows now supports CursorGrabMode::Locked in Winit 0.30.10 which is automatically pulled in by cargo. Solution Remove the doc that says its unsupported.

GitHub
So we're splitting out the work, and starting with a shockingly modest (+566) performance-compatible rendering backend, and then slowly adding frontends and integrations with stuff like LDTK as they mature. For now though, this should reduce the really painful maintenance of rendering integration.

Hmm. So we're living in bevy_sprite for now: I suppose that's a fine-enough spot for now. Rendering crates are a mess. I would *prefer* clearer / strong ECS design, and I've left some suggestions on how to do that, but I think that's fine in follow-up.

I trust the SMEs-Rendering here: merging.

If you're interested in helping out, join the Tilemap working group on Discord: https://discord.com/channels/691052431525675048/1367261228459884604

I think we can land something significantly more advanced than this in 0.17 if folks pitch in. Lots of prior art and expertise: the trick is getting folks to move stuff along ;)

Discord - Group Chat That’s All Fun & Games

Discord is great for playing games and chilling with friends, or even building a worldwide community. Customize your own space to talk, play, and hang out.

Discord

5. https://github.com/bevyengine/bevy/pull/19192

Ah window grabbing :( I know a bunch of jammers struggled with this, since the behavior on web is not great. Looks like it's better on Windows now though, so we should update the docs. Great, merging!

Update doc about Windows CursorGrabMode support by jf908 · Pull Request #19192 · bevyengine/bevy

Objective Windows now supports CursorGrabMode::Locked in Winit 0.30.10 which is automatically pulled in by cargo. Solution Remove the doc that says its unsupported.

GitHub

6. https://github.com/bevyengine/bevy/pull/19426

Nice, another step towards always-strong-handles and general rendering cleanup. This time, making the fullscreen shader patterns cleaner. Good, I'm happy with that :) Last I heard we were blocked on assets-as-entities for a full fix, but this progress matters too. Merge!

Replace `FULLSCREEN_SHADER_HANDLE` with a `FullscreenShader` resource. by andriyDev · Pull Request #19426 · bevyengine/bevy

Objective Related to "Always Strong" Asset Handles / Remove asset weak handles #19024. Solution Remove the FULLSCREEN_SHADER_HANDLE weak_handle with a resource holding the shader handl...

GitHub
My goodness I love the in-repo release notes / migration guides. Look at the quality on that thing! The pride! The collaboration! It really helps to have the PR authors writing these: they have way better context than I do at the end of each cycle. What a lovely #opensource #programming practice.

7. https://github.com/bevyengine/bevy/pull/19462

A simple enough bug fix for resizing images while on the GPU, a functionality that we introduced earlier this cycle. To fix it, we need to pass in the old asset, which apparently is broadly useful. Neat! Happy to merge this, especially since then we never ship the bug.

Allow images to be resized on the GPU without losing data by tychedelia · Pull Request #19462 · bevyengine/bevy

Objective #19410 added support for resizing images "in place" meaning that their data was copied into the new texture allocation on the CPU. However, there are some scenarios where an ima...

GitHub

8. https://github.com/bevyengine/bevy/pull/19649

Oh good, the EntityCloneBuilder stuff is ready :) I think we hit this last week but something was slightly off? Anyways, Eugineerd has done an awesome job mentoring this work: the overall design and polish are much improved thanks to that. Merging!

Split `EntityClonerBuilder` in `OptOut` and `OptIn` variants by urben1680 · Pull Request #19649 · bevyengine/bevy

Objective Further tests after #19326 showed that configuring EntityCloner with required components is bug prone and the current design has several weaknesses in it's API: Mixing EntityClonerBu...

GitHub

9. https://github.com/bevyengine/bevy/pull/19685

Man, really just hammering me with X-Contentious stuff today. I guess "making decisions" is a huge part of the job. This is a follow-up for the GLTF coordinate conversion stuff, allowing a global setting. Definitely useful. Did it get contextualized properly?

Allow setting correct glTF coordinate conversions globally by janhohenheim · Pull Request #19685 · bevyengine/bevy

Objective Followup to Allow users to fix glTF coordinate system imports #19633 As discussed, it's a bit cumbersome to specify that you want the correct orientation every single time Also, glTF...

GitHub
Okay good, it's just a setting on the plugin: perfect and simple. I don't see any reason to require runtime control over this, so it doesn't need to be exposed as a resource. The default remains unchanged, the release notes are updated and clear. This is as clean as we can get IMO: let's merge.

10. https://github.com/bevyengine/bevy/pull/19723

Oh interesting, Cart's extremely preliminary reactive systems PR got a second approval. Sure, might as well move that can down the road :) It doesn't do much yet, but it's the direction we want to move, and it's not a big maintenance burden. Merging to keep it moving.

Reactive Systems / SystemParams and Resource impl by cart · Pull Request #19723 · bevyengine/bevy

Objective We increasingly would like to write "reactive systems" that can detect when their inputs have been changed. This would enable things like "reactive UI" patterns. Relat...

GitHub
This is an interesting example of convergent thinking though: I was poking at flecs's observers (which act when queries change), and realized that we could do something very similar via `SystemParam`. Cart saw the issue, and spun out a tiny bit of his prototypes, where he had the same idea. Neat!

11. https://github.com/bevyengine/bevy/pull/19743

Whee contentious PRs! This time, it's mesh serialization! There's been a whole bunch of back-and-forth about how we should do this: it's immediately useful, but our mesh format is overdue for changes, and handle serialization is a huge can of worms.

Looks like the rendering folks finally hashed out a compromise with the BRP / tooling folks who wanted this: create a dedicated `SerializableMesh` struct and cast to / from that. Okay, I'm down.

Very clear docs on limitations, clean impl. Great conclusion to the debates; let's merge :)

12. https://github.com/bevyengine/bevy/pull/19775

Ah good, another PR for "our weird rendering data structures need more utility methods". I bet this came up at work for IceSentry :) Uncontroversial, cleanly implemented, nicely documented, and I trust that this is helpful. Merging.

13. https://github.com/bevyengine/bevy/pull/19778

My job really is to make the final call, huh... Today, we have another simple widget (!): radio buttons. Generally clean, and very nice to have but ickshonpe is displeased that there's no built-in mechanism for enforcing mutual exclusion.

Core radio button and radio group by viridia · Pull Request #19778 · bevyengine/bevy

Objective Core Radio Button and Radio Group widgets. Part of #19236

GitHub
Good critique! That's a core part of what it *means* to be a radio button. I don't immediately see a better general-purpose design though, and no one has offered one. The relatively bespoke enforcement shown in the examples works for now, and maybe reactivity (or a clever contributor) will save us.
I'm going to go ahead and merge: we're very much going to be marketing and teaching this as "experimental Work-in-Progress". This sort of flaw is not foundational or critical, and fixes are going to be much easier to review and debate in follow-up PRs, without blocking other work. Please chime in!

Phew! That's it for the merge train: this ended up being a fuller day than I was hoping for. Don't stay up until 2 am kids. At least, not if you're Old™.

Anyways, I'm feeling really pleased about the progress on a lot of controversial features today, between the merge train and the meeting!

#bevy 0.17 is shaping up to be a really exciting release: hot patching, widgets, observers, tilemaps, light textures, transform overhaul... :) Community-driven open source is really wild like that: folks just come along and upset all your plans. Mostly for the better even!