Skip to content

Commit

Permalink
Track the actual size of the buffer for memory init (#5014)
Browse files Browse the repository at this point in the history
  • Loading branch information
nical authored Jan 8, 2024
1 parent e7c7017 commit c6eea50
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wgpu-core/src/device/resource.rs
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ impl<A: HalApi> Device<A> {
device: self.clone(),
usage: desc.usage,
size: desc.size,
initialization_status: RwLock::new(BufferInitTracker::new(desc.size)),
initialization_status: RwLock::new(BufferInitTracker::new(aligned_size)),
sync_mapped_writes: Mutex::new(None),
map_state: Mutex::new(resource::BufferMapState::Idle),
info: ResourceInfo::new(desc.label.borrow_or_default()),
Expand Down

0 comments on commit c6eea50

Please sign in to comment.