我们的代码在Canvas上执行非常简单的操作(完全在UI线程中):drawText,translate,save,restore。
偶尔,我们得到这个(在Nexus 4上运行4.3):
W/Adreno200-ES20(22118): <gl_draw_error_checks:550>: GL_INVALID_OPERATION
D/OpenGLRenderer(22118): GL error from OpenGLRenderer: 0x502
E/OpenGLRenderer(22118): GL_INVALID_OPERATION
并且相应的文本未绘制到画布上。
一个问题是它是随机发生的。代码将在没有错误的情况下工作,可能会有10-20个调用,然后会出现此错误,然后再返回正常工作,再次在错误发生前再进行10-20次调用。
编辑:这是跟踪:
glEnable(cap = GL_BLEND)
glViewport(x = 0, y = 0, width = 768, height = 1184)
glStartTilingQCOM(x = 0, y = 0, width = 768, height = 1134, preserveMask = 0)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 37)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 2048)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 1400, yoffset = 61, width = 448, height = 239, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x768d1d80)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glEnable(cap = GL_SCISSOR_TEST)
glScissor(x = 0, y = 0, width = 768, height = 1134)
glDisable(cap = GL_BLEND)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 2)
glBindBuffer(target = GL_ARRAY_BUFFER, buffer = 3)
glVertexAttribPointer(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x0)
glVertexAttribPointer(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x8)
glDrawArrays(mode = GL_MAP_INVALIDATE_RANGE_BIT, first = 0, count = 6)
glDisable(cap = GL_SCISSOR_TEST)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 50.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 3)
glBindBuffer(target = GL_ARRAY_BUFFER, buffer = 4)
glVertexAttribPointer(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x0)
glVertexAttribPointer(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x8)
glDrawArrays(mode = GL_MAP_INVALIDATE_RANGE_BIT, first = 0, count = 54)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 1088.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 21)
glDrawArrays(mode = GL_MAP_INVALIDATE_RANGE_BIT, first = 0, count = 54)
glEnable(cap = GL_SCISSOR_TEST)
glScissor(x = 264, y = 644, width = 240, height = 378)
glEnable(cap = GL_BLEND)
glUseProgram(program = 6)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.392157, y = 0.705882, z = 1.000000, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 0, yoffset = 0, width = 218, height = 220, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d008)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindBuffer(target = GL_ELEMENT_ARRAY_BUFFER, buffer = 2)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointer(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x74d1f008)
glVertexAttribPointer(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x74d1f010)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 6, type = GL_UNSIGNED_SHORT, indices = 0x0)
glScissor(x = 16, y = 96, width = 736, height = 480)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.196078, y = 0.196078, z = 0.196078, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 0, width = 15, height = 17, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d0e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindBuffer(target = GL_ARRAY_BUFFER, buffer = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointer(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x74d1f008)
glVertexAttribPointer(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x74d1f010)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 4)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 4)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 6, type = GL_UNSIGNED_SHORT, indices = 0x0)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.196078, y = 0.196078, z = 0.196078, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 0, width = 46, height = 36, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d0e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 12)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 12)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 18, type = GL_UNSIGNED_SHORT, indices = 0x0)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.196078, y = 0.196078, z = 0.196078, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 35, width = 16, height = 17, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c15ce4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 4)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 4)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 6, type = GL_UNSIGNED_SHORT, indices = 0x0)
glDisable(cap = GL_SCISSOR_TEST)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.196078, y = 0.196078, z = 0.196078, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 0, width = 80, height = 226, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d0e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 148)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 148)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 222, type = GL_UNSIGNED_SHORT, indices = 0x0)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.752941, y = 0.188235, z = 0.188235, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 0, width = 140, height = 319, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d0e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 108)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 108)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 162, type = GL_UNSIGNED_SHORT, indices = 0x0)
glEnable(cap = GL_SCISSOR_TEST)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.752941, y = 0.188235, z = 0.188235, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 74, width = 78, height = 316, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c1f8e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 52)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 52)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 78, type = GL_UNSIGNED_SHORT, indices = 0x0)
glDisable(cap = GL_SCISSOR_TEST)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.501961, y = 0.690196, z = 1.000000, w = 1.000000)
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 220, yoffset = 89, width = 138, height = 328, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c234e4)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 60)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 60)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 90, type = GL_UNSIGNED_SHORT, indices = 0x0)
glEnable(cap = GL_SCISSOR_TEST)
glScissor(x = 264, y = 644, width = 240, height = 378)
glUseProgram(program = 3)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0])
glPixelStorei(pname = GL_UNPACK_ALIGNMENT, param = 1)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 1024)
glTexSubImage2D(target = GL_TEXTURE_2D, level = 0, xoffset = 300, yoffset = 0, width = 99, height = 209, format = GL_ALPHA, type = GL_UNSIGNED_BYTE, pixels = 0x74c0d134)
glPixelStorei(pname = GL_UNPACK_ROW_LENGTH, param = 0)
glBindTexture(target = GL_TEXTURE_2D, texture = 1)
glVertexAttribPointerData(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 12)
glVertexAttribPointerData(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x??, minIndex = 0, maxIndex = 12)
glDrawElements(mode = GL_MAP_INVALIDATE_RANGE_BIT, count = 18, type = GL_UNSIGNED_SHORT, indices = 0x0)
glDisable(cap = GL_SCISSOR_TEST)
glDisableVertexAttribArray(index = 1)
glDisable(cap = GL_BLEND)
glUseProgram(program = 9)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [16.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 128.0, 573.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.376471, y = 0.376471, z = 0.376471, w = 1.000000)
glBindBuffer(target = GL_ARRAY_BUFFER, buffer = 1)
glVertexAttribPointer(indx = 0, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x0)
glBindBuffer(target = GL_ELEMENT_ARRAY_BUFFER, buffer = 0)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [16.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 624.0, 573.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.376471, y = 0.376471, z = 0.376471, w = 1.000000)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [480.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 144.0, 573.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.376471, y = 0.376471, z = 0.376471, w = 1.000000)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 2, count = 1, transpose = false, value = [480.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 144.0, 573.0, 0.0, 1.0])
glUniform4f(location = 0, x = 0.376471, y = 0.376471, z = 0.376471, w = 1.000000)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glEnable(cap = GL_BLEND)
glUseProgram(program = 3)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 672.0, 542.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 22)
glEnableVertexAttribArray(index = 1)
glVertexAttribPointer(indx = 1, size = 2, type = GL_FLOAT, normalized = false, stride = 16, ptr = 0x8)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 25.0, 66.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 4)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [72.0, 0.0, 0.0, 0.0, 0.0, 72.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 492.0, 62.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 23)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 592.0, 66.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 32)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 688.0, 66.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 25)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 32.0, 1103.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 26)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 160.0, 1104.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 27)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 288.0, 1104.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 28)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 416.0, 1104.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 29)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 544.0, 1104.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 30)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glUniformMatrix4fv(location = 0, count = 1, transpose = false, value = [0.0026041667, 0.0, 0.0, 0.0, 0.0, -0.0016891892, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -1.0, 1.0, -0.0, 1.0])
glUniformMatrix4fv(location = 1, count = 1, transpose = false, value = [64.0, 0.0, 0.0, 0.0, 0.0, 64.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 672.0, 1104.0, 0.0, 1.0])
glBindTexture(target = GL_TEXTURE_2D, texture = 14)
glDrawArrays(mode = GL_TRIANGLE_STRIP, first = 0, count = 4)
glEndTilingQCOM(preserveMask = 1)
glGetError(void) = (GLenum) GL_INVALID_OPERATION
glGetError(void) = (GLenum) GL_NO_ERROR
eglSwapBuffers
答案 0 :(得分:1)
如果关闭硬件加速,则不会发生此错误。
在自定义视图的构造函数中:
setLayerType(View.LAYER_TYPE_SOFTWARE, null);
注意:我不会接受这个答案(因为它更像是一种解决方法而不是一个正确的解决方案)。希望有更明确的东西...