bevy/examples/window
Zicklag 3faca93f7b Add ClearColor Resource to Pipelined Renderer (#2631)
# Objective

- Allow the user to set the clear color when using the pipelined renderer

## Solution

- Add a `ClearColor` resource that can be added to the world to configure the clear color

## Remaining Issues

Currently the `ClearColor` resource is cloned from the app world to the render world every frame. There are two ways I can think of around this:

1. Figure out why `app_world.is_resource_changed::<ClearColor>()` always returns `true` in the `extract` step and fix it so that we are only updating the resource when it changes
2. Require the users to add the `ClearColor` resource to the render sub-app instead of the parent app. This is currently sub-optimal until we have labled sub-apps, and probably a helper funciton on `App` such as `app.with_sub_app(RenderApp, |app| { ... })`. Even if we had that, I think it would be more than we want the user to have to think about. They shouldn't have to know about the render sub-app I don't think.

I think the first option is the best, but I could really use some help figuring out the nuance of why `is_resource_changed` is always returning true in that context.
2021-08-19 20:34:31 +00:00
..
clear_color.rs pipelined rendering proof of concept 2021-07-24 16:43:37 -07:00
clear_color_pipelined.rs Add ClearColor Resource to Pipelined Renderer (#2631) 2021-08-19 20:34:31 +00:00
multiple_windows.rs pipelined rendering proof of concept 2021-07-24 16:43:37 -07:00
scale_factor_override.rs pipelined rendering proof of concept 2021-07-24 16:43:37 -07:00
window_settings.rs pipelined rendering proof of concept 2021-07-24 16:43:37 -07:00