I've tried the 8888 mode as well, but the 4444 mode was the one used in the sprite text example.
On Feb 18, 12:05 am, Romain Guy <[email protected]> wrote: > Why are you using the ARGB_4444 mode? > > > > On Tue, Feb 17, 2009 at 10:03 PM, Rye <[email protected]> wrote: > > > All the textures I create from my resource files are fine, but when I > > create a texture in the following way... > > > <code> > > > mOverlay = Bitmap.createBitmap((int)mWidth, (int)mHeight, > > Bitmap.Config.ARGB_4444); > > mOverlay.eraseColor(0); > > mOverlayCanvas = new Canvas(mOverlay); > > > ... > > > Canvas c = mOverlayCanvas; > > c.drawColor(Color.argb(0, 0, 0, 0)); > > Paint p = new Paint(); > > p.setColor(Color.RED); > > c.drawCircle(160, 240, 10, p); > > > ... > > > int[] texture = new int[1]; > > gl.glGenTextures(1, texture, 0); > > mOverlayID = texture[0]; > > gl.glBindTexture(GL10.GL_TEXTURE_2D, mOverlayID); > > gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MIN_FILTER, > > GL10.GL_LINEAR); > > gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MAG_FILTER, > > GL10.GL_LINEAR); > > gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S, > > GL10.GL_REPEAT); > > gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T, > > GL10.GL_REPEAT); > > gl.glTexEnvx(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE, > > GL10.GL_REPLACE); > > GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, mOverlay, 0); > > > </code> > > > It is drawn in solid white when I draw it with... > > > <code> > > > gl.glActiveTexture(GL10.GL_TEXTURE0); > > gl.glBindTexture(GL10.GL_TEXTURE_2D, mOverlayID); > > gl.glVertexPointer(3, GL10.GL_FLOAT, 0, mOverlayVB); > > gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, mOverlayTB); > > gl.glDrawArrays(GL10.GL_TRIANGLES, 0, 6); > > > </code> > > > All of my textures loaded from files work just fine, with all the same > > gl.glEnable/Disable settings the same. This one comes out white. Any > > hints? > > -- > Romain Guy > Android framework engineer > [email protected] > > Note: please don't send private questions to me, as I don't have time > to provide private support. All such questions should be posted on > public forums, where I and others can see and answer them --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

