dolphin/Source/Core
Dentomologist 83f307ec7e D3D12: Only use framebuffer integer descriptor if allocated
Verify that DXFramebuffer's integer RTV descriptor's cpu_handle has been
allocated before using it, and if it hasn't use the non-integer RTV
descriptor instead. This fixes a Dolphin crash in Twilight Princess, and
possibly other games (Issue 13312).

As an optimization to save space in the descriptor heap, DXFramebuffer's
integer descriptor is only initialized if the given abstract texture
format has different integer and non-integer RTV formats. This
previously wasn't accounted for by GetIntRTVDescriptorArray, which could
cause DX12::Gfx::BindFramebuffer to call OMSetRenderTargets with an
invalid descriptor which would lead to a crash.

Triggering the bug was fortunately rare because integer formats are only
used when blending is disabled and logic ops are enabled. Furthermore,
the standard integer abstract format is RGBA8 which has different
integer and non-integer RTV formats, causing the integer descriptor to
be initialized and avoiding the bug.

The crash started appearing in a2702c6 because it changed the
swapchain's abstract texture format from RGBA8 to RGB10_A2. Unlike
RGBA8, RGB10_A2 has the same integer and non-integer RTV formats and so
the bug can be triggered if the other requirements are met.
2023-08-04 13:17:33 -07:00
..
AudioCommon cubeb: Change name to "Dolphin Emulator" 2023-07-22 23:12:34 +02:00
Common Merge pull request #12073 from AdmiralCurtiss/wiimote-win32error 2023-07-29 18:54:10 +02:00
Core Merge pull request #12047 from AdmiralCurtiss/nand-stats-user 2023-07-30 21:51:07 +02:00
DiscIO Merge pull request #11955 from TellowKrinkle/CMakeDependencies 2023-06-30 19:06:04 +02:00
DolphinNoGUI Merge pull request #11873 from AdmiralCurtiss/pause-and-lock-host 2023-06-06 13:50:20 +02:00
DolphinQt Merge pull request #12047 from AdmiralCurtiss/nand-stats-user 2023-07-30 21:51:07 +02:00
DolphinTool Merge pull request #11960 from Minty-Meeo/dolphin-tool-code-review-4 2023-06-17 14:18:21 +02:00
InputCommon Switch libusb_config_descriptor to RAII type 2023-07-05 20:38:22 -07:00
MacUpdater CMake: Fix storyboard copying 2023-04-29 16:10:38 -05:00
UICommon Merge pull request #11955 from TellowKrinkle/CMakeDependencies 2023-06-30 19:06:04 +02:00
UpdaterCommon CMake: Use targets for all optionally-external dependencies 2023-06-15 01:41:41 -05:00
VideoBackends D3D12: Only use framebuffer integer descriptor if allocated 2023-08-04 13:17:33 -07:00
VideoCommon VideoCommon: update NetplayChatUI's chat message input to use a hidden label. This avoids an error thrown by imgui 2023-07-29 00:27:07 -05:00
WinUpdater StringUtil: Move CommandLineToUtf8Argv() into Common namespace 2023-05-16 14:23:21 -04:00
CMakeLists.txt CMakeLists: Add option to disable automatic update support 2022-03-18 03:04:51 -04:00
DolphinLib.ARM64.props msbuild: use default Project attrs 2022-04-27 15:26:43 -07:00
DolphinLib.props VideoCommon: add material asset. A material is similar to other graphics engines where it provides data to be used in conjunction with a shader asset to generate a runtime AbstractShader 2023-07-09 12:21:34 -05:00
DolphinLib.vcxproj Added rcheevos to Externals 2023-04-02 08:28:23 -04:00
DolphinLib.vcxproj.user msbuild: use default Project attrs 2022-04-27 15:26:43 -07:00
DolphinLib.x64.props Move x64 DSP JIT into DolphinLib.x64.props 2023-01-06 22:42:21 -08:00