Question

Hello: Here is the question:

I've got a custom view. It's shape is an rounded rectangle. (as drawn in its onDraw Method). I've got a Bitmap that I want to set it as background. I can use the method:

void drawBitmap (Bitmap bitmap, Rect src, Rect dst, Paint paint)

To scale the image to rectangle smaller thant the shape of my view but I would like for it to occupy the whole view. Is there any way to crop the image corners so the match a rounded rectangle?

Was it helpful?

Solution

To close the question, I am posting the comment with a bit more text.

The answer can be found in the following question:

How to make an ImageView with rounded corners?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top