changed image deminsions to canvas.height and canvas.width