[Fix] (MG_State/Program): add more prints in PostLink() to debug

This commit is contained in:
2025-08-14 22:06:47 +08:00
parent c1966c5f04
commit f4ec3c3997
2 changed files with 5 additions and 1 deletions
@@ -155,6 +155,10 @@ namespace MobileGL {
m_uboScratch.resize(m_metadata.uboSize, 0);
auto& types = m_metadata.plainUniformMemberTypes;
printf("types.size() = %u\n", types.size());
printf("m_uniformOffsets.size() = %u\n", m_uniformOffsets.size());
fflush(stdout);
assert(types.size() == m_uniformOffsets.size());
m_uniformTypes.resize(m_uniformOffsets.size());
for (const auto& [name, type] : types) {
+1 -1
View File
@@ -111,7 +111,7 @@ TEST_F(ProgramTest, CompileAndLink) {
AttachShader(program, fs);
printf("Linking program...\n");
LinkProgram(program);
printf("Program linked...\n");
printf("Program linked.\n");
EXPECT_EQ(GetUniformLocation(program, "ProjMat"), 0);
EXPECT_EQ(GetUniformLocation(program, "Gray"), 1);