Added a WriteBytes function (WriteMem)

WriteBytes is a wrapper around WriteMem that lets you use
leptonica to change formats without persisting to disk.

I am not 100% certain I got this one right, but I gave it a shot...

I use it to convert tiff (format 4, unsupported by go.image) to png in memory.