If you need to draw (on canvas) a round rectangle with different radii for different angles, you can use this:
private void drawAsymmetricRoundRect(Canvas canvas, RectF rectF, float[] radii, Paint paint) { float topLeftX = rectF.left + radii[0]; float topLeftY = rectF.top + radii[0]; float topRightX = rectF.right - radii[1]; float topRightY = rectF.top + radii[1]; float bottomRightX = rectF.right - radii[2]; float bottomRightY = rectF.bottom - radii[2]; float bottomLeftY = rectF.bottom - radii[3]; float bottomLeftX = rectF.left + radii[3]; RectF topLeftCorner = new RectF(rectF.left, rectF.top, topLeftX + radii[0], topLeftY + radii[0]); RectF topRightCorner = new RectF(topRightX - radii[1], rectF.top, rectF.right, topRightY + radii[1]); RectF bottomRightCorner = new RectF(bottomRightX - radii[2], bottomRightY - radii[2], rectF.right, rectF.bottom); RectF bottomLeftCorner = new RectF(rectF.left, bottomLeftY - radii[3], bottomLeftX + radii[3], rectF.bottom); canvas.drawArc(topLeftCorner, 180, 90, true, paint); canvas.drawArc(topRightCorner, 270, 90, true, paint); canvas.drawArc(bottomRightCorner, 0, 90, true, paint); canvas.drawArc(bottomLeftCorner, 90, 90, true, paint); canvas.drawRect(topLeftX, rectF.top, topRightX, bottomLeftY < bottomRightY ? bottomLeftY : bottomRightY, paint);
float[] radii - an array with a floating point (length = 4), which stores the sizes of the radii of your corners (clockwise, starting from the top left corner => {topLeft, topRight, bottomRight, bottomLeft} ).
Basically this approach draws 4 arcs (corners) and fills everything between these corners with four rectangles.
IMPORTANT NOTE: I put RectFs corner RectFs in this method to reduce the complexity of the posted code. Because you are likely to call this method from your onDraw() method, you should extract this piece of code and place it where you run another Rects (unless you initialize them in onDraw() : P).