Browse Source

Revert "[engines, maxwell] Added GetDirtyFlagsForMethod"

pull/3322/head
CamilleLaVey 3 weeks ago
parent
commit
bb0e64caf5
  1. 7
      src/video_core/dirty_flags.h
  2. 5
      src/video_core/engines/maxwell_3d.cpp

7
src/video_core/dirty_flags.h

@ -1,6 +1,3 @@
// SDPX-FileCopyrightText: Copyright 2025 Eden Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project // SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later // SPDX-License-Identifier: GPL-2.0-or-later
@ -85,8 +82,8 @@ constexpr std::pair<u8, u8> GetDirtyFlagsForMethod(u32 method) {
return {Descriptors, NullEntry}; return {Descriptors, NullEntry};
} }
if (method >= OFF_RT && method < OFF_RT + 32) {
const u32 rt_idx = (method - OFF_RT) / 4;
if (method >= OFF_RT && method < OFF_RT + 64) {
const u32 rt_idx = (method - OFF_RT) / 8;
return {static_cast<u8>(ColorBuffer0 + rt_idx), RenderTargets}; return {static_cast<u8>(ColorBuffer0 + rt_idx), RenderTargets};
} }

5
src/video_core/engines/maxwell_3d.cpp

@ -324,7 +324,10 @@ void Maxwell3D::ProcessDirtyRegisters(u32 method, u32 argument) {
} }
regs.reg_array[method] = argument; regs.reg_array[method] = argument;
const auto [flag0, flag1] = GetDirtyFlagsForMethod(method);
const auto& table0 = dirty.tables[0];
const auto& table1 = dirty.tables[1];
const u8 flag0 = table0[method];
const u8 flag1 = table1[method];
dirty.flags[flag0] = true; dirty.flags[flag0] = true;
if (flag1 != flag0) { if (flag1 != flag0) {
dirty.flags[flag1] = true; dirty.flags[flag1] = true;

Loading…
Cancel
Save