I see no one has answered this post, so I'll ask a different question - if I write the code to reproduce this (buggy) behavior, will any engineer at Google who's on this list take a look at it and tell me whether locking a portion of a canvas works or not, so I can at least stop trying to do this (otherwise quite important) optimization?
Cheers, Stoyan On Wed, Jan 21, 2009 at 1:06 AM, Stoyan Damov <stoyan.da...@gmail.com> wrote: > Has anyone ever tried to invalidate a portion of the screen > successfully without seeing flickering? > > I have a portion of the screen (on a SurfaceView) which changes rarely > and I don't want to draw this portion if possible because it saves > ~16% of all drawing code. > So I keep a flag whether I should lock the entire canvas (if this part > of the screen is dirty) or a part of it (if it's not). > Well, *something* surely happens, but not what I'd expect: > > 1. The non-dirty part of the screen starts flickering as I stop drawing it. > 2. Visually (i.e. I can't prove it by taking a screenshot via > Eclipse's DDMS plugin - everything looks fine), it appears that 2 > frames are drawn continuously one on top of the other - the current > one, and the previous. > > I appreciate *any* hints, even "don't do it, it doesn't work", so I > can concentrate on something more meaningful. > > Cheers, > Stoyan > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---