From: Christoph Schmidt-Hieber <c.schmidt-hieber@uc...> - 2009-11-08 13:56:01
I'm aware that there's some functionality to integrate PIL images into pyx drawings. What about the other way around? Currently, I'm using the following code to get a pyx vector drawing into a PIL image:
pyx_canvas.pipeGS(filename=fn, device="pngalpha", resolution=600,
gscommand="gs", gsoptions="-dSAFER -dBATCH -dNOPAUSE",
pyx_to_PIL = PIL.Image.open(fn)
Is there a way to avoid the overhead that arises from writing and re-opening the png file?
Thanks for your help