Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix crash due to race condition #70

Merged
merged 1 commit into from
Apr 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/pipeline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,8 @@ impl Plugin for AtmospherePipelinePlugin {
Render,
(
event_update_system::<AtmosphereUpdateEvent>.in_set(RenderSet::Prepare),
prepare_atmosphere_assets.in_set(RenderSet::PrepareAssets),
queue_atmosphere_bind_group.in_set(RenderSet::Queue),
prepare_atmosphere_resources.in_set(RenderSet::PrepareResources),
prepare_atmosphere_bind_group.in_set(RenderSet::PrepareBindGroups),
),
);

Expand Down Expand Up @@ -323,7 +323,7 @@ pub const ATMOSPHERE_IMAGE_TEXTURE_DESCRIPTOR: fn(u32) -> TextureDescriptor<'sta
};

/// Whenever settings changed, the texture view needs to be updated to use the new texture.
fn prepare_atmosphere_assets(
fn prepare_atmosphere_resources(
mut update_events: ResMut<Events<AtmosphereUpdateEvent>>,
mut atmosphere_image: ResMut<AtmosphereImage>,
gpu_images: Res<RenderAssets<Image>>,
Expand Down Expand Up @@ -356,7 +356,7 @@ fn prepare_atmosphere_assets(

/// Queue the generated bind groups for the compute pipeline.
#[allow(clippy::too_many_arguments)]
fn queue_atmosphere_bind_group(
fn prepare_atmosphere_bind_group(
mut commands: Commands,
mut cached_metadata: ResMut<CachedAtmosphereModelMetadata>,
gpu_images: Res<RenderAssets<Image>>,
Expand Down