Use a different Thread that draws on the SurfaceView directly. You can draw as fast and as immediate as your Thread allows.
http://developer.android.com/reference/android/view/SurfaceView.html - Get the SurfaceHolder of the SurfaceView. - Every time you want to draw, begin by calling the SurfaceHolder's lockCanvas. - This will give you a Canvas to draw on directly. - End this by calling unlockCanvasAndPost You should be able to find some examples when you google SurfaceHolder. Here is one such result: http://www.anddev.org/2d_tutorial-t3120.html On Mar 19, 5:31 pm, mcmc <manni...@gmail.com> wrote: > Hello, > > I'm trying to use java and android's 2D drawing APIs (no openGL) to > draw to a canvas instantly. > > Right now, I am using the SurfaceView class (surfaceCreated, > surfaceChanged, and surfaceDestroyed functions) to draw to a canvas, > but it does not get called at the time I want it to. > > I understand that SurfaceChanged is called "immediately after any > structural changes (format or size) have been made to the surface." If > this is the case, how would I explicitly change the size or format of > the surface to call SurfaceChanged instantly? > > If there is a better method to draw to a canvas instantly, such as not > using the SurfaceView class (surfaceCreated, surfaceChanged, and > surfaceDestroyed functions) or View class (onDraw function) entirely, > that would be ideal. > > Can anyone help? this is urgent... and I've been stuck here for a very > long time! :( > > Thanks! :) --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---