@Override
    protected void onDraw(Canvas canvas) {
        if (!readyDraw) {
            super.onDraw(canvas);
        }
        if (width >= mRadius && height > mRadius) {
            if (isScreenshotSuccess) {
                canvas.drawColor(Color.BLACK);
            }
            Path path = new Path();
            path.moveTo(mRadius, 0);
            path.lineTo(width - mRadius, 0);
            path.quadTo(width, 0, width, mRadius);
            path.lineTo(width, height - mRadius);
            path.quadTo(width, height, width - mRadius, height);
            path.lineTo(mRadius, height);
            path.quadTo(0, height, 0, height - mRadius);
            path.lineTo(0, mRadius);
            path.quadTo(0, 0, mRadius, 0);

            canvas.clipPath(path);
        }
        canvas.drawColor(Color.WHITE);
        super.onDraw(canvas);
    }
@author: Kongzue
@github: https://github.com/kongzue/
@homepage: http://kongzue.com/
@mail: myzcxhh@live.cn
@createTime: 2019/11/17 23:53
DialogX/src/main/java/com/kongzue/dialogx/util/views/ActivityScreenShotImageView.java