xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ionut Ciocirlan" <ionut.ciocir...@avandor.com>
Subject Re: Converting svg to png/jpg inline.
Date Wed, 28 Dec 2005 13:09:07 GMT
The rasterizer is just a command-line application using Batik's Transcoder, 
which you'll need to use as well.

See the Transcoder API and the example there --  
http://xml.apache.org/batik/rasterizerTutorial.html#createImage

Simply feed an io.StringReader as TranscoderInput, and an 
io.ByteArrayOutputStream as TranscoderOutput.
You'll get the binary image from output.toByteArray().

Ionut

----- Original Message ----- 
From: "Jonathan Powell" <jpowell@jpowell.co.uk>
To: <batik-users@xmlgraphics.apache.org>
Sent: Wednesday, December 28, 2005 2:41 PM
Subject: Converting svg to png/jpg inline.


| Hi,
|
| Ideally I would like to use the Rasterizer to convert svg on stdin to
| png on stdout for use in a webapplication that will dynamically generate
| png's from svg code itself dynamically generated from user input. As it
| stands the Rasterizer works on files saved on the filesystem.
|
| Have any other users found a solution for a problem like this, if so I
| would appreciate any help.
|
| Regards,
|
| Jonathan Powell
|
| ---------------------------------------------------------------------
| To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
| For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org 


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


Mime
View raw message