title: What is the OpenGl format of Bitmap.getPixels() in Android?
body: <p><code>Bitmap.getPixels()</code> returns an integer array, with pixel values returned in a "Packed Integer" format, described in the documentation for <code>Color</code>.</p>
  
  <p>This format is A, R, G, B.</p>
  
  <p>I want to pass this array to <code>GLES10.glTexImage2D()</code>. I have tried specifying both <code>internalFormat</code> and <code>format</code> as <code>GL_RGBA</code>. But this causes the the Blue and Red channels to be swapped.</p>
  
  <p>I couldn't find an Opengl equivalent which describes this format.</p>
  
  <hr/>
  
  <p>Aside, I can swap the R and B channels using bitwise operations to conform to GL_RGBA, but would rather prefer if OpenGl could recognize the format natively.</p>
  
  <p><hr/>
  <strong>Update:</strong>
  I know I can use the Bitmap directly with <code>TexImage2D()</code>, but I need to call <code>getPixels()</code> because I need to manipulate the pixel data before using it as a texture. I can convert the pixels back to a Bitmap, but like I said, I would prefer if I could use the pixels directly as a texture.</p>