I am trying to delete a path from a canvas or make it transparent, I am using the following method to do this:
Canvas canvas = new Canvas(bmap);
Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG);
paint.setColor(Color.TRANSPARENT);
Path path=new Path();
//Add lines/arcs to path...
paint.setXfermode(new PorterDuffXfermode(Mode.DST_IN));//tried SRC,CLEAR
canvas.drawPath(path, paint);
But the path is being filled with black color, I want to make that transparent, is that possible?