You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by Casey Cole <cc...@caseycole.com> on 2000/09/05 18:18:35 UTC

Re: HELP! My images don't work in Acrobat and I don't know why...

I had the same problem using xalan.  I would generate on a linux machine, no
errors, but the pdf would have the err when invoked from Windows.  What I found
was that the markup I used was not quite what fop wanted. This worked:

<fo:external-graphic src="file:///full_path/image.jpg" />

I had to use the full path with the file specifier.

Art Welch wrote:

> Hey, all you PDF experts out there...
>
> I can not seem to get my images to work with Acrobat. When I load a PDF
> created with FOP in Acrobat I get an error message "Acrobat Reader - There
> was an error while trying to parse an image." the rest of the PDF looks OK,
> just no images (there are holes where the images should be). This is using
> my BmpImage class which should provide image support in a JDK 1.1
> environment (currently for monochrome and 24 bit color BMP files - if I get
> it working this far I may add support for the other BMP formats). The
> BmpImage class builds the FOPImage.m_bitmaps the same as GifJpegImage and
> JimiImage. If I print the output from my PCLRenderer the images come out
> correctly. Also when I run FOP on a machine with JDK 1.3 and convert the
> BMPs to GIFs the PCLRenderer prints the images correctly. So I am fairly
> certain that my PCLRenderer is interpreting the FOP bitmap correctly and
> since it prints FOP bitmaps generated by both BmpImage and GifJpegImage I am
> confident that BmpImage is creating the bitmap in the same form as
> GifJpegImage. When I produce PDF files they are very close in size
> (unfortunately my stylesheet calls an Xalan extension function that does not
> work on my PC so they are not identical - I will try to address this
> tomorrow).
>
> Any thoughts, hints, tips, guesses.
>
> Attached is my BmpImage class.
>  <<BmpImage.java>>
> Thank You,
> Art (who knows almost nothing about PDF)
>
>   ------------------------------------------------------------------------
>                     Name: BmpImage.java
>    BmpImage.java    Type: unspecified type (application/octet-stream)
>                 Encoding: quoted-printable