Apache OpenOffice (AOO) Bugzilla – Issue 10388
PDF Export: JPG - bad image quality
Last modified: 2010-03-22 16:24:22 UTC
I use the PDF Export a lot in Build 643 of OpenOffice, but am dissapointed that pictures are all saved in the PDF using JPEG Compression, and I cannot seem to be able to use ZIP like compression instead. Although you can have higher quality pictures, by selecting "Press Optimized" in the PDF Export Dialog, they are still JPEG compressed. It would be nice, if you could prompt for ZIP/PNG like compression instead, so you don't lose quality in the pictures when exporting to PDF.
Reassigned to BH
Just my $0.02 worth as a user. I have also run into run into this issue, which is annoying as PDF export is such a useful feature. It doesn't really seem right to call something "Press Optimized" (or even "Print Optimized") if it is going to convert all the images to JPEGS. The best solution (I think) would be that at the highest quality level: - Images that were originally JPEGs remain as JPEGs, and the original file is used so as to avoid re-encoding the file. - All other images are stored as PNG images. Use grayscale, indexed, and lower colour depths when they do not reduce the quality. - All images are left in input resolution (lower qualities may want to scale them down). I'm not sure what the current behaviour is here.
Set to "NEW"
*** Issue 9541 has been marked as a duplicate of this issue. ***
*** Issue 13676 has been marked as a duplicate of this issue. ***
*** Issue 13906 has been marked as a duplicate of this issue. ***
*** Issue 12096 has been marked as a duplicate of this issue. ***
extended subject to avoid more duplicates...
*** Issue 14464 has been marked as a duplicate of this issue. ***
maybe setting a target-milestone is not a bad idea -> 1.1 OS -> All
moving to gsl (not reassinging)
Argh! MOving to gsl lost votes! Please resubmit your votes, Sorry for causing this inconvenience :-(
Hi, My images turn out all blured when I export to PDF. I am attaching two files. One sxw file with original image, the other a pdf file exported from original! Where is the "press optimized" setting ... I cannot see it? Sorry! Thanks, Cheryl.
Created attachment 6619 [details] Original sxw file with screen shot image
Created attachment 6620 [details] PDF Exported from the original sxw
to view the setting use File|Export to PDF, not the icon in the toolbar. (the same as with File|Print and the icon for printing)
Thank you! My images convert much better with the press optimized selected.
PDF supports filters like LZW (=zip) and DCT (=JPG), but does not support the algorithm, which is used by PNG.
Closed now.
Actually, that's not correct. PDF 1.2 does support zlib compression, via the FlateDecode filter. All common readers support this filter. Note that pdftex has supported PNG images for years, and seems to do a very good job with them. It uses the FlateDecode filter. I will attach a PDF file generated by pdflatex that contains a single 8-bit RGB PNG image. Please reconsider WONTFIX'ing this bug, as it can be fixed.
Created attachment 6815 [details] A PDF file containing a PNG image, generated by pdftex
Always reopen closed issues when adding comments! Otherwise they won't show up in default queries...
Hello Matthias, perhaps I got something wrong here. As you have specified the implemented PDF-export could you please take this one to your ownership, thank you.
summary changed
*** Issue 17838 has been marked as a duplicate of this issue. ***
*** Issue 18160 has been marked as a duplicate of this issue. ***
*** Issue 14494 has been marked as a duplicate of this issue. ***
Yes, cf. http://specs.openoffice.org/appwide/pdf_export/KickOffOct2003.sxw
Allowing "maximum" jpeg-quality would be good enough in most cases. The addition of a "quality-slider", like implemented in gimp/photoshop, would seem to be a sufficient solution.
Maximum quality jpeg images are not the best solution. I will attach two versions of the same screenshot saved from the GIMP, one a 100% quality jpeg, the other a png. The JPEG is still slightly burry (particularly around the title bar text), and the JPEG (at 23.8K) is 3.7 times *larger* than the lossless PNG file (at 6.4K).
Created attachment 12847 [details] Screenshot as a 100% quality JPEG
Created attachment 12848 [details] Same screenshot as a PNG
I just did a quick test in Photoshop with the images you provided. There is no visual difference between the png and the photoshop-generated jpeg-images. Looks like gimp is just bad at creating jpegs... What's the deal with the RGB-separation btw? Is that some XP-antialiasing or something? I attached an image with the gimp/photoshop-comparison.
Created attachment 12856 [details] jpeg/jpeg/png test (photoshop/gimp)
See also Issue 23575, Issue 20222. I am having problems with this too. Three things are very important for PDF export of images, as has been stated above: -- If exporting to JPEG, and the original image was already in JPEG format, the original JPEG should be re-used to avoid re-coding wherever possible. This should include both press and print optimized levels, IMHO, as well as screen optimized when the image is say lower than 120dpi in resolution, with the page zoomed to 100%. -- JPEG should *not* be used for everything. It is just a bad format for line art, low-colored images and images with lots of sharp edges, period. It even uses a different colorspace which can mess up the color of your images, no matter what quality setting it is on. PDF (as well as OOo) supports more than JPEG for a reason. Flate works very well -- it should be used. -- The image export settings definitely need an option to override the default quality (for JPEG) and resolution (for both JPEG and PNG) for any of the optimization settings. Also, it would be nice to have one more optimization setting, with sane defaults -- "Screen Optimized (high resolution)" which allows you to zoom a little without losing detail. There is currently a huge difference in dpi between screen and print optimization.
[Sorry, ignore Issue 23575, it is unrelated.]
MMP>CP: Thanks for taking over.
targeted for 8 according to http://specs.openoffice.org/appwide/pdf_export/PDFExport.sxw
Some comments on PDFExport.sxw (rev 0.2) ad 6.2: When downsampling images, OOo should take into account the scaling factor applied to an image: Usually when target resolution is 300dpi, an image with 1200dpi is to be resampled with 300dpi. But when an image is scaled eg. by 200%, resampling should be done with 600dpi (scaling factor * target resolution). Otherwise in our example the effective resolution of the resulting image in the pdf document would be 150dpi. (300dpi image scaled by 2) ad 6.10: The PDF-Options dialog is becoming complex enough to make me long for a sane set of factory presets (screen|printer|prepress like in 1.1) or user definable presets. I don't like "the monopolists way" of nesting dialogs, in the end you never know where you were coming from - so I'd rather see encryption (and maybe other features yet to come) in another tab page of the same dialog.
I put this on duplicate to #i20327#. We will improve on the image quality as described there. In fact the better image quality (default setting 90% jpeg, optionally losless compression) and the new dialog are already implemented in CWS pdf01. *** This issue has been marked as a duplicate of 20327 ***
closing this one as duplicate (see above)
*** Issue 33092 has been marked as a duplicate of this issue. ***
I searched for « export PDF » issues and found many issues dealing with the same problem : issue 17463, issue 37400 and issue 12693. Some other issues you might be interested in and not directly to JPEG export : issue 26952 and issue 13524. Maybe some of the three issues are duplicates of this one. We discuss this issue on OOoForum.org in the http://www.oooforum.org/forum/viewtopic.php?t=13804 topic.
Created attachment 20802 [details] Darwin PDF exportation : from Writer text document to PDF documents
I don't think this bug is duplicate of 20327. Are you sure?