Skip to content

Commit

Permalink
Fix Presentation (#5312)
Browse files Browse the repository at this point in the history
  • Loading branch information
cwfitzgerald authored Feb 28, 2024
1 parent 744454b commit 330a860
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion wgpu-core/src/device/queue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1153,7 +1153,7 @@ impl Global {
for &cmb_id in command_buffer_ids {
// we reset the used surface textures every time we use
// it, so make sure to set_size on it.
used_surface_textures.set_size(hub.textures.read().len());
used_surface_textures.set_size(device.tracker_indices.textures.size());

#[allow(unused_mut)]
let mut cmdbuf = match command_buffer_guard.replace_with_error(cmb_id) {
Expand Down
5 changes: 4 additions & 1 deletion wgpu-core/src/present.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,10 @@ impl Global {
layers: 0..1,
mips: 0..1,
},
info: ResourceInfo::new("<Surface>", None),
info: ResourceInfo::new(
"<Surface Texture>",
Some(device.tracker_indices.textures.clone()),
),
clear_mode: RwLock::new(resource::TextureClearMode::Surface {
clear_view: Some(clear_view),
}),
Expand Down

0 comments on commit 330a860

Please sign in to comment.