Cleanup object URLs in gfx.js

Fix for issue #694.
- Always convert images to canvases
- Cleanup object URL after conversion
This might have been faster before, but it was probably a bug (because it assumed nativeImageData was an image)