[video_core] Increase MAX_MIP_LEVELS to 16 according to specs (#2965)
This increases MAX_MIP_LEVELS from 14 to 16, according to specs. Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2965 Reviewed-by: Maufeat <sahyno1996@gmail.com> Co-authored-by: MaranBr <maranbr@outlook.com> Co-committed-by: MaranBr <maranbr@outlook.com>
This commit is contained in:
parent
8412e64bb0
commit
569dbfe8c0
|
|
@ -1,3 +1,6 @@
|
|||
// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
|
|
@ -10,7 +13,7 @@
|
|||
namespace VideoCommon {
|
||||
|
||||
constexpr size_t NUM_RT = 8;
|
||||
constexpr size_t MAX_MIP_LEVELS = 14;
|
||||
constexpr size_t MAX_MIP_LEVELS = 16;
|
||||
|
||||
constexpr Common::SlotId CORRUPT_ID{0xfffffffe};
|
||||
|
||||
|
|
|
|||
|
|
@ -646,9 +646,10 @@ LevelArray CalculateMipLevelOffsets(const ImageInfo& info) noexcept {
|
|||
if (info.type == ImageType::Linear) {
|
||||
return {};
|
||||
}
|
||||
ASSERT(info.resources.levels <= static_cast<s32>(MAX_MIP_LEVELS));
|
||||
if (info.resources.levels > static_cast<s32>(MAX_MIP_LEVELS))
|
||||
if (info.resources.levels > static_cast<s32>(MAX_MIP_LEVELS)) {
|
||||
LOG_ERROR(HW_GPU, "Image has too many mip levels={}, maximum supported is={}", info.resources.levels, MAX_MIP_LEVELS);
|
||||
return {};
|
||||
}
|
||||
const LevelInfo level_info = MakeLevelInfo(info);
|
||||
LevelArray offsets{};
|
||||
u32 offset = 0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue