This is part of the
Canvas, images and pixels
tutorial