I find it very unlikely that your camera is providing a 720 pixel wide and
1280 pixel high image as you tell to OpenGL here:
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, 720,1280, // <---- HERE 0, GL_RGB, GL_UNSIGNED_BYTE, image)
It seems you just mixed up those two parametes, so the data is reinterpreted
as such, resulting in the output you got.
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)