hi, please you need to understand that we are talking here about two very different
approaches, i call it
-
paint job
i used a image “layer” bylayer = createGraphics(720,400);
where at mouse click the random colored circles are stored ( painted in ) -
draw job
while @Chrisir stores the mouseclicks ( position ) in a list ( and uses a JAVA program here you need to translate )
and atdraw()
thebackground()
cleans all
and a FOR loop draws all circles from the positions array.
i hope you see the very different ways to do it.
how to discuss the differences / advantages?
in a paint job you can clear all as show in my code,
but you would not be able “forget” single events ( like the delete the oldest when make a new circle )
what i very well possible with a array approach.
i not like that filled as i not see where i am painting over,
but that you see the random color already ( now i use it in stroke )
is a very good idea.
please check my ( revised ) link again