[Fix] (MG_State/ProgramState): Correct compiling flags in ShaderObject::Compile

This commit is contained in:
BZLZHH
2026-02-01 09:23:25 +08:00
committed by GitHub
parent 419ffb3b5e
commit 938b92277f
@@ -32,7 +32,7 @@ namespace MobileGL {
// like a real OpenGL driver at linking stage
// Will compile for other backends later.
ShaderAttrib attrib{
.shaderType = MG_Util::ConvertShaderStageToGLEnum(m_stage), .sourceStr = m_source, .flags = 0};
.shaderType = MG_Util::ConvertShaderStageToGLEnum(m_stage), .sourceStr = m_source, .flags = ShaderCompileBits::CompileForOpenGL};
auto result = ShaderCompiler::CompileShader(attrib);
if (result) {
@@ -52,4 +52,4 @@ namespace MobileGL {
}
} // namespace GLState
} // namespace MG_State
} // namespace MobileGL
} // namespace MobileGL