From 81a80ae8182360619b1dd4b74a6d0d850db45ca1 Mon Sep 17 00:00:00 2001 From: Darryl Pogue Date: Fri, 30 Dec 2022 12:59:58 -0800 Subject: [PATCH] Fix GL pipeline crash opening the KI --- .../Plasma/FeatureLib/pfGLPipeline/plGLMaterialShaderRef.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/Plasma/FeatureLib/pfGLPipeline/plGLMaterialShaderRef.cpp b/Sources/Plasma/FeatureLib/pfGLPipeline/plGLMaterialShaderRef.cpp index 70946fed21..674a464a06 100644 --- a/Sources/Plasma/FeatureLib/pfGLPipeline/plGLMaterialShaderRef.cpp +++ b/Sources/Plasma/FeatureLib/pfGLPipeline/plGLMaterialShaderRef.cpp @@ -284,6 +284,8 @@ void plGLMaterialShaderRef::SetupTextureRefs() continue; } + fPipeline->CheckTextureRef(layer); + plGLTextureRef* texRef = static_cast(img->GetDeviceRef()); if (!texRef->fRef) { @@ -291,8 +293,6 @@ void plGLMaterialShaderRef::SetupTextureRefs() continue; } - fPipeline->CheckTextureRef(layer); - LOG_GL_ERROR_CHECK("PRE-Active Texture failed") glActiveTexture(GL_TEXTURE0 + numTextures);