From f7df69f50c17bfc80fdd73f6db58aebbed3818fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Sun, 1 Jan 2023 15:17:26 +0100 Subject: [PATCH] Change a Crash() to an _assert_msg_ --- Common/GPU/OpenGL/GLQueueRunner.cpp | 7 ++++--- Common/GPU/OpenGL/GLQueueRunner.h | 1 - 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Common/GPU/OpenGL/GLQueueRunner.cpp b/Common/GPU/OpenGL/GLQueueRunner.cpp index 0191f57b50..c01eb0425b 100644 --- a/Common/GPU/OpenGL/GLQueueRunner.cpp +++ b/Common/GPU/OpenGL/GLQueueRunner.cpp @@ -386,7 +386,8 @@ void GLQueueRunner::RunInitSteps(const std::vector &steps, bool ski boundTexture = tex->texture; } if (!step.texture_image.data && step.texture_image.allocType != GLRAllocType::NONE) - Crash(); + _assert_msg_(false, "missing texture data"); + // For things to show in RenderDoc, need to split into glTexImage2D(..., nullptr) and glTexSubImage. GLenum internalFormat, format, type; @@ -444,7 +445,7 @@ void GLQueueRunner::RunInitSteps(const std::vector &steps, bool ski } default: CHECK_GL_ERROR_IF_DEBUG(); - Crash(); + _assert_msg_(false, "Bad GLRInitStepType: %d", (int)step.stepType); break; } } @@ -1348,7 +1349,7 @@ void GLQueueRunner::PerformRenderPass(const GLRStep &step, bool first, bool last CHECK_GL_ERROR_IF_DEBUG(); break; default: - Crash(); + _assert_msg_(false, "Bad GLRRenderCommand: %d", (int)c.cmd); break; } } diff --git a/Common/GPU/OpenGL/GLQueueRunner.h b/Common/GPU/OpenGL/GLQueueRunner.h index e9ad214eb4..593e00f97b 100644 --- a/Common/GPU/OpenGL/GLQueueRunner.h +++ b/Common/GPU/OpenGL/GLQueueRunner.h @@ -63,7 +63,6 @@ enum class GLRRenderCommand : uint8_t { GENMIPS, DRAW, DRAW_INDEXED, - PUSH_CONSTANTS, TEXTURE_SUBIMAGE, };