ARGB_4444 probably forces Skia to go through unoptimized code paths. This format is mostly useful to conserve memory but it kind of sucks if you care about quality. I tried to use it a few times in the Home application but I abandoned the idea because the loss of precision on each channel is way too important to be worth it (shadows turned into greenish halos and gradients looked awful.) It can definitely be useful if you're very careful about the sources you use but I would stick with 565 and 8888. Especially if we someday enable 2D hardware accelerated drawing. I highly doubt the 4444 format will work well in that case.
On Sun, May 17, 2009 at 11:20 PM, Robert Green <[email protected]> wrote: > > I'm doing performance tweaks for my new game and I seem to have come > across something that isn't discussed much but I think is strange. > > I have a static background bitmap loaded as RGB_565 and it draws > lightning fast to the SurfaceView. > > I then have all of the dynamic stuff, one of which is a full view > width/height bitmap and all of these things need transparency so they > are ARGB_8888. I thought that switching to ARGB_4444 for everything > would speed up drawing because that's half the number of bytes to > process but what I'm finding is that under no circumstances is 2D > drawing any faster with ARGB_4444. All my tests are showing that it's > actually twice as slow to draw an ARGB_4444 bitmap than a ARGB_8888 > one on to the default RGB_565 surface! > > Would any engineers care to enlighten me as to why this is? Is > ARGB_8888 the fastest way to draw bitmaps with transparency? > > My target platform is 1.0, btw. My friend just got a new phone and > out of the box it was 1.0, not even 1.1, so I want to make sure this > works as a first app on new phones. If there are 1.5-specific tweaks, > I will incorporate them in a few months but for now it's gotta run > well on 1.0. > > Thanks!! > > > -- 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 -~----------~----~----~----~------~----~------~--~---

