Draw behind existing shapes with "destination-over"
suggest changecontext.globalCompositeOperation = "destination-over"
“destination-over” compositing places new drawing under existing drawings.
context.drawImage(rainy,0,0);
context.globalCompositeOperation='destination-over'; // sunny UNDER rainy
context.drawImage(sunny,0,0);
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents