Allow setImg() to resize image to canvas

Also fixed call to clearRect; it was clearing a rect width x width instead of width x height