var canvas, context, clipart = []
function init() {
canvas = document.getElementsByTagName("canvas")[0]
context = canvas.getContext("2d")
}
function preload() {
  // populates clipart with five images from
// http://narwhalart.example/archives/[0-9]
  // all represented as HTML <img> elements
…
}
function draw(clipart) {
context.drawImage(clipart, …)
}
function save() {
  // get data out of <canvas> and process it
var data = canvas.toDataURL()
…
}