diff options
| author | TellowKrinkle <tellowkrinkle@gmail.com> | 2023-01-29 14:36:28 -0600 |
|---|---|---|
| committer | TellowKrinkle <tellowkrinkle@gmail.com> | 2023-01-29 14:36:28 -0600 |
| commit | e4e425b93038aa485b4432ada5626c2f8e8ccc02 (patch) | |
| tree | c81e29fdd5d9e3424fe083a7c77530b0b7a722ad /Source/Core/VideoBackends | |
| parent | 1119a9ba327fb86cb03f303539ce5b9697158379 (diff) | |
VideoBackends:Metal: Assert on pipelines with no render targets
This only actually fails on specific Metal drivers, this way doing it will actually fail the CI and we'll notice
Diffstat (limited to 'Source/Core/VideoBackends')
| -rw-r--r-- | Source/Core/VideoBackends/Metal/MTLObjectCache.mm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/Core/VideoBackends/Metal/MTLObjectCache.mm b/Source/Core/VideoBackends/Metal/MTLObjectCache.mm index 48a8ad7dae..979c1b7627 100644 --- a/Source/Core/VideoBackends/Metal/MTLObjectCache.mm +++ b/Source/Core/VideoBackends/Metal/MTLObjectCache.mm @@ -418,6 +418,12 @@ public: // clang-format on } FramebufferState fs = config.framebuffer_state; + if (fs.color_texture_format == AbstractTextureFormat::Undefined && + fs.depth_texture_format == AbstractTextureFormat::Undefined) + { + // Intel HD 4000's Metal driver asserts if you try to make one of these + PanicAlertFmt("Attempted to create pipeline with no render targets!"); + } [desc setRasterSampleCount:fs.samples]; [color0 setPixelFormat:Util::FromAbstract(fs.color_texture_format)]; [desc setDepthAttachmentPixelFormat:Util::FromAbstract(fs.depth_texture_format)]; |
