Skip to content

Commit

Permalink
Rebased on main
Browse files Browse the repository at this point in the history
  • Loading branch information
ManevilleF committed Aug 9, 2022
1 parent 344e435 commit 7c27d92
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions crates/bevy_sprite/src/render/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,20 @@ pub fn extract_sprite_events(
pub fn extract_sprites(
mut extracted_sprites: ResMut<ExtractedSprites>,
texture_atlases: Extract<Res<Assets<TextureAtlas>>>,
sprite_query: Extract<Query<(Entity, &ComputedVisibility, &Sprite, &GlobalTransform, &Handle<Image>, Option<&TextureSheet>)>>,
sprite_query: Extract<
Query<(
Entity,
&ComputedVisibility,
&Sprite,
&GlobalTransform,
&Handle<Image>,
Option<&TextureSheet>,
)>,
>,
) {
extracted_sprites.sprites.clear();
for (entity, visibility, sprite, transform, handle, sheet) in sprite_query.iter() {
if !visibility.is_visible {
if !visibility.is_visible() {
continue;
}
let rect = sheet.and_then(|s| s.texture_rect(&texture_atlases));
Expand Down

0 comments on commit 7c27d92

Please sign in to comment.