xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Prabhakar Lal" <Prabhakar_...@mindtree.com>
Subject Problem with conversion from raster to svg using batik
Date Fri, 16 Jan 2004 10:49:37 GMT

Hi All,
Help Required.

Problem Description :

I am trying to convert a png image to svg format using batik API.
If I do not use any ImageHandler in the java code, the image is encoded as
base64 and dumped into the converted svg file.

<image x="20" y="20" width="100"

When I use a image handler such as ImageHandlerPNGEncoder it creates an SVG
file which has link to a png image which is created in the folder which I
<!-- extract of svg --->

<image x="20" y="20" width="100"
xlink:href="file:/F:/WTK20/res/images//pngImage13.png" height="150"
preserveAspectRatio="none" />

In both the cases, I am getting an image tag in the SVG file.
My requirement is to display the svg using batik API in the format given
<!-- Sample
 <g style="fill:#c1c1bf;">
   <path d="M 329.336 727.552 
            C 315.224 726.328 304.136 715.816 303.128 694.936 
            C 306.368 639.496 309.608 582.112 271.232 545.104 
	    C 265.256 499.024 244.016 482.104 234.008 452.512 
	    L 218.24 441.208 
	    L 237.104 411.688 
	    L 245.168 411.904 
	    L 323.936 571.168 
	    L 340.424 651.448 
	    L 329.336 727.552 
	    z" />
How can I achieve the same using batik API? 

Thanks in advance.

Prabhakar Lal

This message (including attachment if any) is confidential and may be privileged. Before opening
attachments please check them for viruses and defects. MindTree Consulting Private Limited
(MindTree) will not be responsible for any viruses or defects or any forwarded attachments
emanating either from within MindTree or outside. If you have received this message by mistake
please notify the sender by return  e-mail and delete this message from your system. Any unauthorized
use or dissemination of this message in whole or in part is strictly prohibited.  Please note
that e-mails are susceptible to change and MindTree shall not be liable for any improper,
untimely or incomplete transmission.

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

View raw message