Your texture definition is wrong. In glTexImage2D is a error. You pass 3bytes, 24bits per pixel (3), but Your data has 4bytes, 32 bits per pixel (GL_RGBA):

Qt Code:
  1. glTexImage2D(GL_TEXTURE_2D, 0, 3, GLFormatImage.width(), GLFormatImage.height(), 0, GL_RGBA, GL_UNSIGNED_BYTE, GLFormatImage.bits());
To copy to clipboard, switch view to plain text mode 
it should be either:
Qt Code:
  1. glTexImage2D(GL_TEXTURE_2D, 0, 4, GLFormatImage.width(), GLFormatImage.height(), 0, GL_RGBA, GL_UNSIGNED_BYTE, GLFormatImage.bits());
  2. // or
  3. glTexImage2D(GL_TEXTURE_2D, 0, 3, GLFormatImage.width(), GLFormatImage.height(), 0, GL_RGB, GL_UNSIGNED_BYTE, GLFormatImage.bits());
To copy to clipboard, switch view to plain text mode