diff --git a/wgpu-hal/src/gles/queue.rs b/wgpu-hal/src/gles/queue.rs index 124a0c40930..31c837cdbbc 100644 --- a/wgpu-hal/src/gles/queue.rs +++ b/wgpu-hal/src/gles/queue.rs @@ -463,8 +463,9 @@ impl super::Queue { .map_or(copy.size.width * format_info.block_size as u32, |bpr| { bpr.get() }); - let minimum_rows_per_image = - u32::max(1, copy.size.height / format_info.block_dimensions.1 as u32); + let block_height = format_info.block_dimensions.1 as u32; + let minimum_rows_per_image = (copy.size.height + block_height - 1) + / format_info.block_dimensions.1 as u32; let rows_per_image = copy .buffer_layout .rows_per_image