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 Jonathan Levinson <Jo...@intersystems.com> on 2009/10/19 23:33:14 UTC

Unable to display jpeg or PNG files in fop document

I'm using FOP 0.95 and I'm unable to display jpeg or PNG images. 

 

The errors I get are like the following:

 

SEVERE: Image not available: No ImagePreloader found for
file:///perforce/Users/levinson/B47157/2009-usa-125x125.png

 

Best Regards,

Jonathan Levinson

 


RE: Unable to display jpeg or PNG files in fop document

Posted by Jonathan Levinson <Jo...@intersystems.com>.
Thank you!!!

Best Regards,
Jonathan Levinson


-----Original Message-----
From: Jeremias Maerki [mailto:dev@jeremias-maerki.ch] 
Sent: Thursday, October 22, 2009 2:57 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Unable to display jpeg or PNG files in fop document

I've been able to reproduce this, thanks to your details. Apparently,
the problem was an empty string returned by URL.getHost() which caused
an additional backslash in the file name and that in turn probably
caused
a network access since the filename was interpreted as UNC path:

\\perforce\Users\levinson.......

(it would access a host called "perforce" which obviously doesn't
exist).

Fixed in XML Graphics Commons Trunk:
http://svn.apache.org/viewvc?rev=828814&view=rev

On 20.10.2009 18:58:46 Jonathan Levinson wrote:
> Using your example, I was able to discover what caused the "slowness"
> and the inability to render the image.
> 
> I used the following url:
> 
> url(file:///perforce/Users/levinson/B47157/2009-usa-125x125.png)" />
> 
> If I change it to the following:
> 
> url(file:///c:/perforce/Users/levinson/B47157/2009-usa-125x125.png)"
/>
> 
> then the image renders in less than a second.
> 
> I believe both should work so it is a bug.
> 
> The latter works in the trunk but takes 30 seconds or more to render,
> but less than a second in trunk when c:/ is added. 
> 
> Best Regards,
> Jonathan Levinson
> 
> 
> -----Original Message-----
> From: Venkat Reddy [mailto:vanukuri.venkat@googlemail.com] 
> Sent: Tuesday, October 20, 2009 9:39 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: Re: Unable to display jpeg or PNG files in fop document
> 
> I am able to view PNG image with both fop-0.95 and fop-trunk as well,
I
> just downloaded fop-0.95 binary, extracted... just used the fop.bat to
> run
> 
> like from the command prompt....
> 
> fop -c C:\fop.xconf -fo hello.fo -pdf hello.pdf
> 
> It worked in both 0.95 and trunk versions.... I am attaching the
sample
> with this mail....
> 
> I have used the following java version on windows environment...
> 
> C:\mywork\FOP\fop-0.95>java -version
> java version "1.6.0_05"
> Java(TM) SE Runtime Environment (build 1.6.0_05-b13) Java HotSpot(TM)
> Client VM (build 10.0-b19, mixed mode, sharing)
> 
> Cheers,
> Venkat.
> 
> Jonathan Levinson wrote:
> >
> > I'm using fop.bat and I reinstalled fop-0.95 just to make sure my 
> > installation was not corrupted.
> >
> > xmlgraphics-commons-1.3.1 is in my classpath.
> >
> > Here is the Java I'm suing:
> >
> > java version "1.6.0_10"
> >
> > Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
> >
> > Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)
> >
> > Best Regards,
> >
> > Jonathan Levinson
> >
> > *From:* Griffin,Sean [mailto:SGRIFFIN@CERNER.COM]
> > *Sent:* Monday, October 19, 2009 5:58 PM
> > *To:* fop-users@xmlgraphics.apache.org
> > *Subject:* RE: Unable to display jpeg or PNG files in fop document
> >
> > Have you tried it from the fop.bat or are you embedding FOP in your 
> > own service? I tried with fop.bat and it works just fine using the 
> > dependencies added to the classpath in that script. In particular 
> > ensure you're running xmlgraphics-commons-1.3.1.
> >
> > *From:* Jonathan Levinson
[mailto:Jonathan.Levinson@intersystems.com]
> > *Sent:* Monday, October 19, 2009 4:33 PM
> > *To:* fop-users@xmlgraphics.apache.org
> > *Subject:* Unable to display jpeg or PNG files in fop document
> >
> > I'm using FOP 0.95 and I'm unable to display jpeg or PNG images.
> >
> > The errors I get are like the following:
> >
> > SEVERE: Image not available: No ImagePreloader found for 
> > file:///perforce/Users/levinson/B47157/2009-usa-125x125.png
> >
> > Best Regards,
> >
> > Jonathan Levinson
> >
> >
----------------------------------------------------------------------
> > --
> >
> > CONFIDENTIALITY NOTICE This message and any included attachments are

> > from Cerner Corporation and are intended only for the addressee. The

> > information contained in this message is confidential and may 
> > constitute inside or non-public information under international, 
> > federal, or state securities laws. Unauthorized forwarding,
printing, 
> > copying, distribution, or use of such information is strictly 
> > prohibited and may be unlawful. If you are not the addressee, please

> > promptly delete this message and notify the sender of the delivery 
> > error by e-mail or you may call Cerner's corporate offices in Kansas

> > City, Missouri, U.S.A at (+1) (816)221-1024.
> >
> 
> 



Jeremias Maerki


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


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


Re: Unable to display jpeg or PNG files in fop document

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
I've been able to reproduce this, thanks to your details. Apparently,
the problem was an empty string returned by URL.getHost() which caused
an additional backslash in the file name and that in turn probably caused
a network access since the filename was interpreted as UNC path:

\\perforce\Users\levinson.......

(it would access a host called "perforce" which obviously doesn't exist).

Fixed in XML Graphics Commons Trunk:
http://svn.apache.org/viewvc?rev=828814&view=rev

On 20.10.2009 18:58:46 Jonathan Levinson wrote:
> Using your example, I was able to discover what caused the "slowness"
> and the inability to render the image.
> 
> I used the following url:
> 
> url(file:///perforce/Users/levinson/B47157/2009-usa-125x125.png)" />
> 
> If I change it to the following:
> 
> url(file:///c:/perforce/Users/levinson/B47157/2009-usa-125x125.png)" />
> 
> then the image renders in less than a second.
> 
> I believe both should work so it is a bug.
> 
> The latter works in the trunk but takes 30 seconds or more to render,
> but less than a second in trunk when c:/ is added. 
> 
> Best Regards,
> Jonathan Levinson
> 
> 
> -----Original Message-----
> From: Venkat Reddy [mailto:vanukuri.venkat@googlemail.com] 
> Sent: Tuesday, October 20, 2009 9:39 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: Re: Unable to display jpeg or PNG files in fop document
> 
> I am able to view PNG image with both fop-0.95 and fop-trunk as well, I
> just downloaded fop-0.95 binary, extracted... just used the fop.bat to
> run
> 
> like from the command prompt....
> 
> fop -c C:\fop.xconf -fo hello.fo -pdf hello.pdf
> 
> It worked in both 0.95 and trunk versions.... I am attaching the sample
> with this mail....
> 
> I have used the following java version on windows environment...
> 
> C:\mywork\FOP\fop-0.95>java -version
> java version "1.6.0_05"
> Java(TM) SE Runtime Environment (build 1.6.0_05-b13) Java HotSpot(TM)
> Client VM (build 10.0-b19, mixed mode, sharing)
> 
> Cheers,
> Venkat.
> 
> Jonathan Levinson wrote:
> >
> > I'm using fop.bat and I reinstalled fop-0.95 just to make sure my 
> > installation was not corrupted.
> >
> > xmlgraphics-commons-1.3.1 is in my classpath.
> >
> > Here is the Java I'm suing:
> >
> > java version "1.6.0_10"
> >
> > Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
> >
> > Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)
> >
> > Best Regards,
> >
> > Jonathan Levinson
> >
> > *From:* Griffin,Sean [mailto:SGRIFFIN@CERNER.COM]
> > *Sent:* Monday, October 19, 2009 5:58 PM
> > *To:* fop-users@xmlgraphics.apache.org
> > *Subject:* RE: Unable to display jpeg or PNG files in fop document
> >
> > Have you tried it from the fop.bat or are you embedding FOP in your 
> > own service? I tried with fop.bat and it works just fine using the 
> > dependencies added to the classpath in that script. In particular 
> > ensure you're running xmlgraphics-commons-1.3.1.
> >
> > *From:* Jonathan Levinson [mailto:Jonathan.Levinson@intersystems.com]
> > *Sent:* Monday, October 19, 2009 4:33 PM
> > *To:* fop-users@xmlgraphics.apache.org
> > *Subject:* Unable to display jpeg or PNG files in fop document
> >
> > I'm using FOP 0.95 and I'm unable to display jpeg or PNG images.
> >
> > The errors I get are like the following:
> >
> > SEVERE: Image not available: No ImagePreloader found for 
> > file:///perforce/Users/levinson/B47157/2009-usa-125x125.png
> >
> > Best Regards,
> >
> > Jonathan Levinson
> >
> > ----------------------------------------------------------------------
> > --
> >
> > CONFIDENTIALITY NOTICE This message and any included attachments are 
> > from Cerner Corporation and are intended only for the addressee. The 
> > information contained in this message is confidential and may 
> > constitute inside or non-public information under international, 
> > federal, or state securities laws. Unauthorized forwarding, printing, 
> > copying, distribution, or use of such information is strictly 
> > prohibited and may be unlawful. If you are not the addressee, please 
> > promptly delete this message and notify the sender of the delivery 
> > error by e-mail or you may call Cerner's corporate offices in Kansas 
> > City, Missouri, U.S.A at (+1) (816)221-1024.
> >
> 
> 



Jeremias Maerki


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


RE: Unable to display jpeg or PNG files in fop document

Posted by Jonathan Levinson <Jo...@intersystems.com>.
Using your example, I was able to discover what caused the "slowness"
and the inability to render the image.

I used the following url:

url(file:///perforce/Users/levinson/B47157/2009-usa-125x125.png)" />

If I change it to the following:

url(file:///c:/perforce/Users/levinson/B47157/2009-usa-125x125.png)" />

then the image renders in less than a second.

I believe both should work so it is a bug.

The latter works in the trunk but takes 30 seconds or more to render,
but less than a second in trunk when c:/ is added. 

Best Regards,
Jonathan Levinson


-----Original Message-----
From: Venkat Reddy [mailto:vanukuri.venkat@googlemail.com] 
Sent: Tuesday, October 20, 2009 9:39 AM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Unable to display jpeg or PNG files in fop document

I am able to view PNG image with both fop-0.95 and fop-trunk as well, I
just downloaded fop-0.95 binary, extracted... just used the fop.bat to
run

like from the command prompt....

fop -c C:\fop.xconf -fo hello.fo -pdf hello.pdf

It worked in both 0.95 and trunk versions.... I am attaching the sample
with this mail....

I have used the following java version on windows environment...

C:\mywork\FOP\fop-0.95>java -version
java version "1.6.0_05"
Java(TM) SE Runtime Environment (build 1.6.0_05-b13) Java HotSpot(TM)
Client VM (build 10.0-b19, mixed mode, sharing)

Cheers,
Venkat.

Jonathan Levinson wrote:
>
> I'm using fop.bat and I reinstalled fop-0.95 just to make sure my 
> installation was not corrupted.
>
> xmlgraphics-commons-1.3.1 is in my classpath.
>
> Here is the Java I'm suing:
>
> java version "1.6.0_10"
>
> Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
>
> Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)
>
> Best Regards,
>
> Jonathan Levinson
>
> *From:* Griffin,Sean [mailto:SGRIFFIN@CERNER.COM]
> *Sent:* Monday, October 19, 2009 5:58 PM
> *To:* fop-users@xmlgraphics.apache.org
> *Subject:* RE: Unable to display jpeg or PNG files in fop document
>
> Have you tried it from the fop.bat or are you embedding FOP in your 
> own service? I tried with fop.bat and it works just fine using the 
> dependencies added to the classpath in that script. In particular 
> ensure you're running xmlgraphics-commons-1.3.1.
>
> *From:* Jonathan Levinson [mailto:Jonathan.Levinson@intersystems.com]
> *Sent:* Monday, October 19, 2009 4:33 PM
> *To:* fop-users@xmlgraphics.apache.org
> *Subject:* Unable to display jpeg or PNG files in fop document
>
> I'm using FOP 0.95 and I'm unable to display jpeg or PNG images.
>
> The errors I get are like the following:
>
> SEVERE: Image not available: No ImagePreloader found for 
> file:///perforce/Users/levinson/B47157/2009-usa-125x125.png
>
> Best Regards,
>
> Jonathan Levinson
>
> ----------------------------------------------------------------------
> --
>
> CONFIDENTIALITY NOTICE This message and any included attachments are 
> from Cerner Corporation and are intended only for the addressee. The 
> information contained in this message is confidential and may 
> constitute inside or non-public information under international, 
> federal, or state securities laws. Unauthorized forwarding, printing, 
> copying, distribution, or use of such information is strictly 
> prohibited and may be unlawful. If you are not the addressee, please 
> promptly delete this message and notify the sender of the delivery 
> error by e-mail or you may call Cerner's corporate offices in Kansas 
> City, Missouri, U.S.A at (+1) (816)221-1024.
>


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


Re: Unable to display jpeg or PNG files in fop document

Posted by Venkat Reddy <va...@googlemail.com>.
I am able to view PNG image with both fop-0.95 and fop-trunk as well, I 
just downloaded fop-0.95 binary, extracted... just used the fop.bat to run

like from the command prompt....

fop -c C:\fop.xconf -fo hello.fo -pdf hello.pdf

It worked in both 0.95 and trunk versions.... I am attaching the sample 
with this mail....

I have used the following java version on windows environment...

C:\mywork\FOP\fop-0.95>java -version
java version "1.6.0_05"
Java(TM) SE Runtime Environment (build 1.6.0_05-b13)
Java HotSpot(TM) Client VM (build 10.0-b19, mixed mode, sharing)

Cheers,
Venkat.

Jonathan Levinson wrote:
>
> I’m using fop.bat and I reinstalled fop-0.95 just to make sure my 
> installation was not corrupted.
>
> xmlgraphics-commons-1.3.1 is in my classpath.
>
> Here is the Java I’m suing:
>
> java version "1.6.0_10"
>
> Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
>
> Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)
>
> Best Regards,
>
> Jonathan Levinson
>
> *From:* Griffin,Sean [mailto:SGRIFFIN@CERNER.COM]
> *Sent:* Monday, October 19, 2009 5:58 PM
> *To:* fop-users@xmlgraphics.apache.org
> *Subject:* RE: Unable to display jpeg or PNG files in fop document
>
> Have you tried it from the fop.bat or are you embedding FOP in your 
> own service? I tried with fop.bat and it works just fine using the 
> dependencies added to the classpath in that script. In particular 
> ensure you’re running xmlgraphics-commons-1.3.1.
>
> *From:* Jonathan Levinson [mailto:Jonathan.Levinson@intersystems.com]
> *Sent:* Monday, October 19, 2009 4:33 PM
> *To:* fop-users@xmlgraphics.apache.org
> *Subject:* Unable to display jpeg or PNG files in fop document
>
> I’m using FOP 0.95 and I’m unable to display jpeg or PNG images.
>
> The errors I get are like the following:
>
> SEVERE: Image not available: No ImagePreloader found for 
> file:///perforce/Users/levinson/B47157/2009-usa-125x125.png
>
> Best Regards,
>
> Jonathan Levinson
>
> ------------------------------------------------------------------------
>
> CONFIDENTIALITY NOTICE This message and any included attachments are 
> from Cerner Corporation and are intended only for the addressee. The 
> information contained in this message is confidential and may 
> constitute inside or non-public information under international, 
> federal, or state securities laws. Unauthorized forwarding, printing, 
> copying, distribution, or use of such information is strictly 
> prohibited and may be unlawful. If you are not the addressee, please 
> promptly delete this message and notify the sender of the delivery 
> error by e-mail or you may call Cerner's corporate offices in Kansas 
> City, Missouri, U.S.A at (+1) (816)221-1024.
>


RE: Unable to display jpeg or PNG files in fop document

Posted by Jonathan Levinson <Jo...@intersystems.com>.
I'm using fop.bat and I reinstalled fop-0.95 just to make sure my
installation was not corrupted.

 

xmlgraphics-commons-1.3.1 is in my classpath.

 

Here is the Java I'm suing:

 

java version "1.6.0_10"

Java(TM) SE Runtime Environment (build 1.6.0_10-b33)

Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)

 

Best Regards,

Jonathan Levinson

 

From: Griffin,Sean [mailto:SGRIFFIN@CERNER.COM] 
Sent: Monday, October 19, 2009 5:58 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: Unable to display jpeg or PNG files in fop document

 

Have you tried it from the fop.bat or are you embedding FOP in your own
service?  I tried with fop.bat and it works just fine using the
dependencies added to the classpath in that script.  In particular
ensure you're running xmlgraphics-commons-1.3.1.

 

From: Jonathan Levinson [mailto:Jonathan.Levinson@intersystems.com] 
Sent: Monday, October 19, 2009 4:33 PM
To: fop-users@xmlgraphics.apache.org
Subject: Unable to display jpeg or PNG files in fop document

 

I'm using FOP 0.95 and I'm unable to display jpeg or PNG images. 

 

The errors I get are like the following:

 

SEVERE: Image not available: No ImagePreloader found for
file:///perforce/Users/levinson/B47157/2009-usa-125x125.png

 

Best Regards,

Jonathan Levinson

 

________________________________

CONFIDENTIALITY NOTICE This message and any included attachments are
from Cerner Corporation and are intended only for the addressee. The
information contained in this message is confidential and may constitute
inside or non-public information under international, federal, or state
securities laws. Unauthorized forwarding, printing, copying,
distribution, or use of such information is strictly prohibited and may
be unlawful. If you are not the addressee, please promptly delete this
message and notify the sender of the delivery error by e-mail or you may
call Cerner's corporate offices in Kansas City, Missouri, U.S.A at (+1)
(816)221-1024.


RE: Unable to display jpeg or PNG files in fop document

Posted by "Griffin,Sean" <SG...@CERNER.COM>.
Have you tried it from the fop.bat or are you embedding FOP in your own service?  I tried with fop.bat and it works just fine using the dependencies added to the classpath in that script.  In particular ensure you're running xmlgraphics-commons-1.3.1.

 

From: Jonathan Levinson [mailto:Jonathan.Levinson@intersystems.com] 
Sent: Monday, October 19, 2009 4:33 PM
To: fop-users@xmlgraphics.apache.org
Subject: Unable to display jpeg or PNG files in fop document

 

I'm using FOP 0.95 and I'm unable to display jpeg or PNG images. 

 

The errors I get are like the following:

 

SEVERE: Image not available: No ImagePreloader found for file:///perforce/Users/levinson/B47157/2009-usa-125x125.png

 

Best Regards,

Jonathan Levinson

 

----------------------------------------------------------------------
CONFIDENTIALITY NOTICE This message and any included attachments are from Cerner Corporation and are intended only for the addressee. The information contained in this message is confidential and may constitute inside or non-public information under international, federal, or state securities laws. Unauthorized forwarding, printing, copying, distribution, or use of such information is strictly prohibited and may be unlawful. If you are not the addressee, please promptly delete this message and notify the sender of the delivery error by e-mail or you may call Cerner's corporate offices in Kansas City, Missouri, U.S.A at (+1) (816)221-1024.