Prototype implementation of image loading and saving.

Encoding is not good. Bitmapdata to byte encoding can be much faster.