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 Frederick Evers <fe...@siebel.com> on 2001/09/25 13:10:30 UTC

Image sizing/sampling in FOP

Hi Everybody,

I have been building a style sheet to generate PDFs and am having trouble
with image quality in the pdf output. Here's the background:

	We have gifs of a given size, say 350mm(w) x 200mm(h) .
	When the XML is generated, we divide the original dimensions of the
gif by 4, so we get 87.5mm(w) x 50mm(h), because we want it to fit in the
page...
	We create the FO and put the image in as an <svg:image
xlink:href="fileName.gif" width="87.5mm" height="50mm"/> element. [We want
it as svg because we draw svg lines, etc on top of it.]
	We run it through FOP and get the image sized at 87.5 x 50, but the
image looks terrible. It appears that in rendering the image at a reduced
size, FOP resamples the original and discards the original graphic info,
which is actually needed to make the image display well when enlarged.

Is there a way to tell FOP to display an image at a given size but NOT
resample the original?

Any help or ideas would be appreciated.


Fred Evers