Hi,
How to draw filled polygon ?
Thanks in advance.
Hi,
How to draw filled polygon ?
Thanks in advance.
You need to set the paint object to FILL
Paint paint = new Paint();
paint.setStyle(Paint.Style.FILL);
Then you can draw whatever you want, and it will be filled.
canvas.drawCircle(20, 20, 15, paint);
canvas.drawRectangle(60, 20, 15, paint);
etc.
For more complex shapes you need to use the PATH object.