[Feat] (MG_State/ProgramObject, MG_Backend/DirectGLES): bind texture to uniform in backend

This commit is contained in:
2025-10-27 15:45:36 +08:00
parent 460b7a6eb3
commit 56c6d73185
4 changed files with 13 additions and 5 deletions
@@ -92,7 +92,7 @@ namespace MobileGL {
// Be aware, there could be gaps in between these vectors
// Locations can be not sequential
m_uniformIndexInTProgram.resize(m_maxUniformLocation + 1, 4095);
m_uniformSamplerOrImageUnitIndex.resize(m_maxUniformLocation + 1, 0);
m_uniformSamplerOrImageUnitIndex.resize(m_maxUniformLocation + 1, -1);
Vector<int> unallocatedUniformIndex;
@@ -66,7 +66,7 @@ namespace MobileGL {
m_uniformSamplerOrImageUnitIndex[location] = unit;
}
Int SetUniformSamplerOrImageUnitIndex(Uint location) const {
Int GetUniformSamplerOrImageUnitIndex(Uint location) const {
return m_uniformSamplerOrImageUnitIndex[location];
}