public void updateBitmapShader ( ) { if ( image == null ) return ; shader = new BitmapShader ( image , Shader . TileMode . CLAMP , Shader . TileMode . CLAMP ) ; if ( canvasSize != image . getWidth ( ) || canvasSize != image . getHeight ( ) ) { Matrix matrix = new Matrix ( ) ; float scale = ( float ) canvasSize / ( float ) image . getWidth ( ) ; matrix . setScale ( scale , scale ) ; shader . setLocalMatrix ( matrix ) ; } }
Re - initializes the shader texture used to fill in the Circle upon drawing .