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

Updated to wgpu 0.16.0, wgpu-hal 0.16.0 and naga 0.12.0 #8446

Merged
merged 9 commits into from
Apr 26, 2023
Prev Previous commit
Next Next commit
Fix compilation error under basis-universal feature
  • Loading branch information
airingursb committed Apr 25, 2023
commit 5cbe08e455ebe77700819f26fa69bf4cff46aa99
9 changes: 5 additions & 4 deletions crates/bevy_render/src/texture/ktx2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,12 +154,13 @@ pub fn ktx2_buffer_to_image(
TranscodeFormat::Uastc(data_format) => {
let (transcode_block_format, texture_format) =
get_transcoded_formats(supported_compressed_formats, data_format, is_srgb);
let texture_format_info = texture_format.describe();
let texture_format_info = texture_format;
let (block_width_pixels, block_height_pixels) = (
texture_format_info.block_dimensions.0 as u32,
texture_format_info.block_dimensions.1 as u32,
texture_format_info.block_dimensions().0 as u32,
texture_format_info.block_dimensions().1 as u32,
);
let block_bytes = texture_format_info.block_size as u32;
// Texture is not a depth or stencil format, it is possible to pass `None` and unwrap
let block_bytes = texture_format_info.block_size(None).unwrap_or_default() as u32;

let transcoder = LowLevelUastcTranscoder::new();
for (level, level_data) in levels.iter().enumerate() {
Expand Down