Bug 694848 - Converting PDF to PNG hangs
Summary: Converting PDF to PNG hangs
Status: RESOLVED FIXED
Alias: None
Product: Ghostscript
Classification: Unclassified
Component: General (show other bugs)
Version: 9.10
Hardware: PC Windows 7
: P4 normal
Assignee: Michael Vrhel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-16 07:12 UTC by jakob.pousard
Modified: 2013-12-16 08:35 UTC (History)
0 users

See Also:
Customer:
Word Size: ---


Attachments
Test input file (1.06 MB, application/pdf)
2013-12-16 07:12 UTC, jakob.pousard
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jakob.pousard 2013-12-16 07:12:39 UTC
Created attachment 10463 [details]
Test input file

Converting PDF to png hangs (or extremely slow) using following command line:

"C:\Program Files (x86)\gs\gs9.10\bin\gswin32c.exe" -dSAFER -dBATCH -dNOPROMPT -dNOPAUSE -sDEVICE=png16m -dTextAlphaBits=4 -dGraphicsAlphaBits=4 "-r150x150" -dFirstPage=1 -dLastPage=1 -dUseTrimBox "-sOutputFile=poster.png" "magazine_p1.pdf"

Using the same command line with gs9.05 completes in about 3 seconds with no errors.
Comment 1 Ken Sharp 2013-12-16 07:29:23 UTC
This seems to me to be the same problem I pointed out before the staff meeting. In gdevp14.c, pdf14_copy_alpha_color() at line 2411 in my code I see:

                            for (k = 0; k < num_comp; ++i) {

Which I believe should be:

                            for (k = 0; k < num_comp; ++k) {


See also bug #694811
Comment 2 jakob.pousard 2013-12-16 07:43:40 UTC
(In reply to comment #1)
> This seems to me to be the same problem I pointed out before the staff
> meeting. In gdevp14.c, pdf14_copy_alpha_color() at line 2411 in my code I
> see:
> 
>                             for (k = 0; k < num_comp; ++i) {
> 
> Which I believe should be:
> 
>                             for (k = 0; k < num_comp; ++k) {
> 
> 
> See also bug #694811

The comments on bug #694811 says it is only for the pngalpha device. But I'm using the png16m device, mayby it affects all png devices.
Comment 3 Ken Sharp 2013-12-16 07:49:24 UTC
(In reply to comment #2)

> > See also bug #694811
> 
> The comments on bug #694811 says it is only for the pngalpha device. But I'm
> using the png16m device, mayby it affects all png devices.

The comments say it can be reproduced with the pngalpha device, not that it only affects the pngalpha device. The same effect can be reproduced using the display device and probably any device using an additive colour space.