protected void reset ( final int width , final int height ) { Bitmap bitmap = this . bitmap ; // recycle old buffer if ( bitmap != null ) { bitmap . recycle ( ) ; } bitmap = Bitmap . createBitmap ( width , height , Bitmap . Config . ARGB_8888 ) ; // high quality this . bitmap = bitmap ; this . bitmapCanvas = new Canvas ( bitmap ) ; }
Prepare for new width and hight .