0

Applying a BitmapShader using relative coordinates when using canvas.drawBitmap

view story
linux-howto

http://stackoverflow.com – I'm trying to Use a BitmapShader to draw on a Canvas. I have 2 images of the same dimensions (one for the alfa channel and one for RGB), that I want to draw on a canvas that was created with the same size. The problem is that it seem as though canvas.drawBitmap users absolute coordinates for the paint. is there a way to draw with relative coordinates. public class MaskedImageDrawable extends Drawable { private final Bitmap mMask; private final Paint mPaint = new Paint(); public MaskedImageDrawable(Bitmap mask, Bitmap image) { mMask = mask; Shader targetShader = (HowTos)