You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Hans Stoessel <hs...@pm-medici.ch> on 2003/02/04 13:49:04 UTC

Converting SVG files to different file formats

Hi

I have a Java (JDK 1.4.1) standalone application which generates SVG files
(Charts with JFreeChart). This charts should be converted into different
file formats like JPG, PDF and maybe EPS. The converted files must be high
quality files for printing media. I try to do that on different ways, f.e.
with Batik, FOP and Image Magick, but the results are bad. I use Windows
2000 as OS.

- How can I do that?
- Does anybody know a good way to convert files form SVG into different
formats with a high quality?
- Has anybody sample code how to improve the quality when I use Image Magick
or Batik?
- Has anybody sample code how I can convert an SVG file into high quality
PDF using FOP?
- Is there an another good tool or Java library to do that?

Thanks a lot

Regards

Hans


PM Medici AG
Hans St�ssel
Maihofstrasse 63
CH-6006 Luzern




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


Re: Converting SVG files to different file formats

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Hans Stoessel wrote:
> - Has anybody sample code how I can convert an SVG file into high quality
> PDF using FOP?

FOP uses Batik for rendering SVG, and there isn't much FOP
can do for quality besides
   http://xml.apache.org/fop/faq.html#faq-N1036C
(well, the PDF transcoder is part of FOP, but because PDF is
vector graphics too, I can only imagine very small roundoff
problems (1/1000 pt) and blantant bugs influencing quality).
How do you define "high quality", and why do you thing you
aren't getting enough quality now?

BTW: Please don't crosspost.

J.Pietschmann


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


Re: Converting SVG files to different file formats

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Hans Stoessel wrote:
> Bad quality means that the text (fonts) is bad looking (rasterd, gray not
> black, ...). It seems to be the resolution or something like that.

FAQ. See
  http://xml.apache.org/fop/faq.html#faq-N1036C


> Do you have a code example how I can convert SVG to PDF using Batik/FOP?

Waht do you mean with "code example"?
There are examples in the FOP distribution, under docs/examples/fo/svg.
You can refer to an SVG file in a fo:external-graphic, or you can embed
a SVG within the FO document using fo:instream-foreign-object. See also
  http://xml.apache.org/fop/svg.html

Perhaps also
  http://marc.theaimsgroup.com/?l=fop-dev&m=103047736819724&w=2
just for the fun of it.

J.Pietschmann



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


Re: Converting SVG files to different file formats

Posted by Hans Stoessel <hs...@pm-medici.ch>.
"Thomas E Deweese" <th...@kodak.com> schrieb im Newsbeitrag
news:15937.1624.206669.612510@frog.rl.kodak.com...
> >>>>> "HS" == Hans Stoessel <hs...@pm-medici.ch> writes:
>
> HS> I try to do that on different ways, f.e.  with Batik, FOP
> HS> and Image Magick, but the results are bad.
>
>     I guess we need to understand what 'results are bad' means, please
> elaborate, what specifically is bad about them?
>

Bad quality means that the text (fonts) is bad looking (rasterd, gray not
black, ...). It seems to be the resolution or something like that.

>     The latest versions of FOP should do a good job of PDF generation.

Do you have a code example how I can convert SVG to PDF using Batik/FOP?

Thanks

Hans




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


Re: [magick-users] RE: Converting SVG files to different file formats

Posted by Arnaud Hrycak <ar...@noos.fr>.
Under Linux, you can get high quality images from SVG files using the
convert utility:

convert -size new_widthxnew_height! file.svg file.jpg

(jpg can replaced by whatever file format you want)

Unfortunatly I have never managed to make this command work under
Windows2000 : the generated image keeps its original size !

Is it a bug ? If not, does anyone can help us ?


Le mer 05/02/2003 à 13:40, Thomas E Deweese a écrit :
> >>>>> "HS" == Hans Stoessel <hs...@pm-medici.ch> writes:
> 
> HS> Hi I have a Java (JDK 1.4.1) standalone application which
> HS> generates SVG files (Charts with JFreeChart). This charts should
> HS> be converted into different file formats like JPG, PDF and maybe
> HS> EPS. The converted files must be high quality files for printing
> HS> media. I try to do that on different ways, f.e.  with Batik, FOP
> HS> and Image Magick, but the results are bad. I use Windows 2000 as
> HS> OS.
> 
>     I guess we need to understand what 'results are bad' means, please
> elaborate, what specifically is bad about them?
> 
>     The latest versions of FOP should do a good job of PDF generation.
> 
> HS> - How can I do that?  - Does anybody know a good way to convert
> HS> files form SVG into different formats with a high quality?  - Has
> HS> anybody sample code how to improve the quality when I use Image
> HS> Magick or Batik?  - Has anybody sample code how I can convert an
> HS> SVG file into high quality PDF using FOP?  - Is there an another
> HS> good tool or Java library to do that?
> _______________________________________________
> Magick-users mailing list
> Magick-users@imagemagick.org
> http://studio.imagemagick.org/mailman/listinfo/magick-users
-- 
Arnaud Hrycak <ar...@noos.fr>


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


RE: Converting SVG files to different file formats

Posted by Thomas E Deweese <th...@kodak.com>.
>>>>> "HS" == Hans Stoessel <hs...@pm-medici.ch> writes:

HS> Hi I have a Java (JDK 1.4.1) standalone application which
HS> generates SVG files (Charts with JFreeChart). This charts should
HS> be converted into different file formats like JPG, PDF and maybe
HS> EPS. The converted files must be high quality files for printing
HS> media. I try to do that on different ways, f.e.  with Batik, FOP
HS> and Image Magick, but the results are bad. I use Windows 2000 as
HS> OS.

    I guess we need to understand what 'results are bad' means, please
elaborate, what specifically is bad about them?

    The latest versions of FOP should do a good job of PDF generation.

HS> - How can I do that?  - Does anybody know a good way to convert
HS> files form SVG into different formats with a high quality?  - Has
HS> anybody sample code how to improve the quality when I use Image
HS> Magick or Batik?  - Has anybody sample code how I can convert an
HS> SVG file into high quality PDF using FOP?  - Is there an another
HS> good tool or Java library to do that?

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


RE: Converting SVG files to different file formats

Posted by Victor Mote <vi...@outfitr.com>.
Hans Stoessel wrote:

> I have a Java (JDK 1.4.1) standalone application which generates SVG files
> (Charts with JFreeChart). This charts should be converted into different
> file formats like JPG, PDF and maybe EPS. The converted files must be high
> quality files for printing media. I try to do that on different ways, f.e.
> with Batik, FOP and Image Magick, but the results are bad. I use Windows
> 2000 as OS.
>
> - How can I do that?
> - Does anybody know a good way to convert files form SVG into different
> formats with a high quality?
> - Has anybody sample code how to improve the quality when I use
> Image Magick
> or Batik?
> - Has anybody sample code how I can convert an SVG file into high quality
> PDF using FOP?
> - Is there an another good tool or Java library to do that?

Since you are in a Windows environment, I would take a look at Adobe
Illustrator. Whether this can be used in a batch-oriented environment, I
don't know, but I think most of the Adobe products now have some of their
API exposed in scripting of one sort or another. If you don't need
on-the-fly batch work done, it would definitely be a good choice (but not
open source).

Victor Mote


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