On 05 Jun 2009, at 13:30, Nicolae Marasoiu wrote:

Hi Nicolae

Can you point me to an example of "rendering to Java2D"? The single AWT example coming with FOP is one that outputs to screen and it seems that it does that behind the sceene when receiving SAX endDocument I guess.

More or less, yes.

Alternatively whould I use AWT preview mime type, to an output stream and pipe that to ImageIO? How can I do that? Should I use such techniques as those presented at: http://ostermiller.org/convert_java_outputstream_inputstream.html or is it a more direct and natural way to it without inverting control?

I've never done it myself, but maybe it's even simpler. Java2D is also used behind the scenes for PNG and TIFF output. Perhaps the easiest way would be to use one of those formats, and feed the PNG/TIFF OutputStream to ImageIO. The techniques mentioned on the cited webpage are indeed usable for that.

HTH!


Andreas

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org

Reply via email to