I'm having the same problem running API12, and using bmp.getGenerationId() shows these bitmaps are always the same ID, even after reloading them with the new pixel data. It seems that the generationID is supposed to change when these bitmaps are modified...but they aren't. Perhaps a bug?
In any case my current workaround is to do view.setLayerType(1, null), essentially, as you mentioned, I'm just not using hardware acceleration. Sadly, it does slow down what I'm doing, but it seems to be manageable and it avoids that garbage collection. Let me know if you find another way to keep HW accel. On Oct 8, 3:36 am, Selueco <seleuco.nica...@gmail.com> wrote: > Hi, > > I am blitting a byte buffer to an Object Bitmap using a HW accelerated > Canvas. To avoid garbage collector i would like to reuse the bitmap > doing a bmp.copyPixelsFromBuffer(bf). > > The problem here is that Android 3.0 canvas HW accelerated seems to > not reupload bitmap texture unless it is a different object... > > My workround was to use drawBitmap(int[] colors ... previusly i had > to do a bmp.getPixels( ... this is slow... since involves an RGB565 to > RGB8888 conversion by frame > > any ideas why Android 3.0 HW accelerated not reupload bitmap textures > which bytes are internally changed? > > is this a bug? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en