Using PVRFrame 2.9.29.0649, OpenGL ES 2.0, on Windows (libGLESv2.dll)…
GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS return 32, but glActiveTexture starts failing with texture unit >= GL_TEXTURE0 + 8.
Code to reproduce the issue:
GLuint nTexUnits = 8;
glGetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, (GLint*)&nTexUnits); // nTexUnits=32, err=GL_NO_ERROR
for (GLuint i = 0; i < nTexUnits; i++)
glActiveTexture(GL_TEXTURE0 + i); //err=GL_INVALID_ENUM when i >= 8 !!!
// PVRVFrame: “In glActiveTexture error: 500 (GL_INVALID_ENUM) : texture number is out of range (min: GL_TEXTURE0), max: GL_TEXTURE0 + 7, given: GL_TEXTURE0 + 8)”
[/CODE]
This bugs was not present in PVRFrame 2.8 .*.
<br>GLuint nTexUnits = 8;<br>glGetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, (GLint*)&nTexUnits); <font color="#006600">// nTexUnits=32, err=GL_NO_ERROR</font><br>for (GLuint i = 0; i < nTexUnits; i++)<br> glActiveTexture(GL_TEXTURE0 + i); <font color="#006600">//err=GL_INVALID_ENUM when i >= 8 !!!</font><br><font color="#006600">// PVRVFrame: "In glActiveTexture error: 500 (GL_INVALID_ENUM) : texture number is out of range (min: GL_TEXTURE0), max: GL_TEXTURE0 + 7, given: GL_TEXTURE0 + 8)"</font></font><font face="Courier New, Courier, mono" size="1"><br></font><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><font face="Courier New, Courier, mono" size="1">
This bugs was not present in PVRFrame 2.8 .*.