The lines, circles, JPEG (top) and SVG (bottom) are first drawn in a 200x150 canvas. For the CSS resize the style.width and style.height are changed to 800x600. For the proper scale up the Processing.js scale() function is used.