mirror of
https://github.com/MobileGL-Dev/MobileGL
synced 2026-09-12 14:18:31 +09:00
[Fix] (MG_Util/GLSLTool): get rid of unnecessary whitespace removal
This commit is contained in:
@@ -281,7 +281,11 @@ namespace MG_GL::GL {
|
||||
void LinkProgram(GLuint program) {
|
||||
MG_Util::Debug::LogD("glLinkProgram, program: %u", program);
|
||||
GLenum result = MG_State::FinalizeProgramPipeline(program);
|
||||
if (result == GL_NO_ERROR) {
|
||||
if (result != GL_NO_ERROR) {
|
||||
MG_State::SetError(result);
|
||||
MG_Util::Debug::LogE("Error linking program: %s", MG_Util::Debug::GLEnumToString(result));
|
||||
return;
|
||||
}
|
||||
auto& programInfo = MG_Diligent::g_ProgramMap[program];
|
||||
auto& programObj = MG_State_T::programState->programs_[program];
|
||||
|
||||
@@ -447,10 +451,6 @@ namespace MG_GL::GL {
|
||||
|
||||
programObj.linked = true;
|
||||
programObj.linkStatus = GL_TRUE;
|
||||
return;
|
||||
}
|
||||
MG_State::SetError(result);
|
||||
MG_Util::Debug::LogE("Error linking program: %s", MG_Util::Debug::GLEnumToString(result));
|
||||
}
|
||||
|
||||
void UseProgram(GLuint program) {
|
||||
|
||||
@@ -558,11 +558,6 @@ namespace MG_Util::Program {
|
||||
for (auto& span : removalSpans) {
|
||||
source.erase(span.first, span.second);
|
||||
}
|
||||
source = std::regex_replace(
|
||||
source,
|
||||
std::regex(R"((\r\n|\n|\r){2,})"),
|
||||
"$1"
|
||||
);
|
||||
}
|
||||
|
||||
std::string uboBlock = "\nlayout(std140) uniform MG_DEFAULT_UBO\n{\n";
|
||||
|
||||
Reference in New Issue
Block a user