allowing pre-existing context to be passed
fixing bug with canvas2d