Crates.io | bevy_render_layers_manager |
lib.rs | bevy_render_layers_manager |
version | 0.1.0 |
source | src |
created_at | 2024-09-05 14:08:52.505369 |
updated_at | 2024-09-05 14:08:52.505369 |
description | Manager for Bevy RenderLayers |
homepage | |
repository | https://github.com/SET001/bevy_render_layers_manager |
max_upload_size | |
id | 1364688 |
size | 109,174 |
This plugin tracks usage of RenderLayers in app and provide method to get first free layer for your needs.
Add RenderLayersManagerPlugin
in your app. This plugin adds RenderLayerManager
resource with .get
method to get first free layer.
You can also use .pick
method that will return free layer and mark it as used.
use bevy::prelude::*;
use bevy_render_layers_manager::*;
fn main() {
let mut app = App::new();
app
.add_plugins(RenderLayersManagerPlugin)
.add_systems(Startup, startup);
app.run();
}
fn startup(layers_manager: Res<RenderLayerManager>) {
println!("Current free layer is: {}", layers_manager.get());
}
bevy | bevy_render_layers_manager |
---|---|
0.14.0 | 0.1.* |