From 0ed45629fd825389504a512ca783c320a6ce3a5a Mon Sep 17 00:00:00 2001 From: BlueCube3310 <53150244+BlueCube3310@users.noreply.github.com> Date: Sun, 21 Jul 2024 21:06:14 +0200 Subject: Support 64-bit image sizes for VRAM compression --- modules/basis_universal/image_compress_basisu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/basis_universal') diff --git a/modules/basis_universal/image_compress_basisu.cpp b/modules/basis_universal/image_compress_basisu.cpp index fc1f01ae50..8167fe8c73 100644 --- a/modules/basis_universal/image_compress_basisu.cpp +++ b/modules/basis_universal/image_compress_basisu.cpp @@ -307,7 +307,7 @@ Ref basis_universal_unpacker_ptr(const uint8_t *p_data, int p_size) { transcoder.get_image_level_info(src_ptr, src_size, basisu_level, 0, i); uint32_t mip_block_or_pixel_count = Image::is_format_compressed(image_format) ? basisu_level.m_total_blocks : basisu_level.m_orig_width * basisu_level.m_orig_height; - int ofs = Image::get_image_mipmap_offset(basisu_info.m_width, basisu_info.m_height, image_format, i); + int64_t ofs = Image::get_image_mipmap_offset(basisu_info.m_width, basisu_info.m_height, image_format, i); bool result = transcoder.transcode_image_level(src_ptr, src_size, 0, i, dst + ofs, mip_block_or_pixel_count, basisu_format); -- cgit v1.2.3