CorvusC Posted February 11, 2021 Share Posted February 11, 2021 I'm unsure whether to report this as a bug, so I thought I'd post a question here first and see if anyone has a similar experience. I've just produced a 17-page document which, on export, was over 18MB. This seemed ridiculously large for the number of images and settings used, so I had a look with Acrobat's Audit Space Usage, to find that 15MB of this was accounted for by colour spaces. Using Acrobat's optimize function to discard objects and user data and clean up the file got rid of these, and left a 3MB file without any recompression of the images. The attached files show the export settings in Publisher and Acrobat's audit of the colour spaces. Experimenting with various settings I found that turning off "Allow advanced features" reduced the size of the colour spaces by about half, leaving a file just under 11MB file. That still included nearly 8MB of extraneous colour spaces, though. Two placed PDFs with simple vector content remained unrasterised in the resulting file, so presumably had been passed through or converted to curves, but one that had an opacity setting was missing entirely. Such huge amounts of space being taken up by colour spaces can't be correct. If "Convert image colour spaces" is selected, the document should require only its main profile. And why would turning off advanced features halve this overhead? I suspect this is a candidate for a bug report, but would be interested to hear if anyone's had similar problems. Quote Link to comment Share on other sites More sharing options...
loukash Posted February 12, 2021 Share Posted February 12, 2021 Can you upload an example document? Quote MacBookAir 15": MacOS Ventura > Affinity v1, v2, v2 beta // MacBookPro 15" mid-2012: MacOS El Capitan > Affinity v1 / MacOS Catalina > Affinity v1, v2, v2 beta // iPad 8th: iPadOS 16 > Affinity v2 Link to comment Share on other sites More sharing options...
CorvusC Posted February 15, 2021 Author Share Posted February 15, 2021 OK, there is some very odd behaviour going on here. I identified the core problem using Acrobat's Preflight inventory feature - there's a hideous gotcha in PDF passthrough: if you have a logo on every page, for example, that PDF will be passed through to the exported PDF every time it appears in the document. So if you have 20 pages, you'll have 20 embedded logos. With 20 associated colour profiles. Acrobat's PDF optimizer recognises them as the same object and strips all but one of the copies, massively reducing the file size. But - this only happens with PDFs that are linked in the Publisher document, or PDFs that are embedded but the source PDF is still available in its original location. Moving the source file for the placed PDF to the trash immediately results in a reduction of the estimated file size in the export dialog, and Acrobat's inventory shows only one copy of it in the resulting PDF. I've attached a sample .afpub file and the logo PDF that's placed in it. You should be able to replicate my findings - an export with the standard "PDF (for print)" preset will be 966kB (you may need to change the PDF Passthrough setting in the Preflight profile to PDF 1.5 for it to export correctly). Change the linked file to embedded in resource manager and export again - same size. Now delete the logo PDF file - the exported file reduced to about 550kB, as it has only one copy of the passed-through logo. This does not seem like it should be the intended behaviour. The colour spaces associated with each placed PDF take up far more space than the vector image data, hence them appearing to be the culprit for the file bloat. PDF passthrough test.afpub Logo.pdf Quote Link to comment Share on other sites More sharing options...
loukash Posted February 16, 2021 Share Posted February 16, 2021 I can't open the Afpub file. APu beta 1.9.1 starts to load it but never finishes opening it. You may want to reupload it zipped. Quote MacBookAir 15": MacOS Ventura > Affinity v1, v2, v2 beta // MacBookPro 15" mid-2012: MacOS El Capitan > Affinity v1 / MacOS Catalina > Affinity v1, v2, v2 beta // iPad 8th: iPadOS 16 > Affinity v2 Link to comment Share on other sites More sharing options...
CorvusC Posted February 16, 2021 Author Share Posted February 16, 2021 Strange - I just downloaded it and it opened fine in Publisher 1.9.0 (Mac). Here's a zipped version. PDF passthrough test.afpub.zip Quote Link to comment Share on other sites More sharing options...
loukash Posted February 16, 2021 Share Posted February 16, 2021 Still stuck on "loading 1 document", burning CPU core cycles at 100%…APu can only be force quitted because dialog "At least one file is currently being opened. Please wait for files to load before quitting the application." only has an "OK" button… I've never seen this before. Quote MacBookAir 15": MacOS Ventura > Affinity v1, v2, v2 beta // MacBookPro 15" mid-2012: MacOS El Capitan > Affinity v1 / MacOS Catalina > Affinity v1, v2, v2 beta // iPad 8th: iPadOS 16 > Affinity v2 Link to comment Share on other sites More sharing options...
CorvusC Posted February 16, 2021 Author Share Posted February 16, 2021 Very strange. Thanks for trying. The file simply has the PDF logo placed on a master page, and two pages created from that master, so it's very easy to recreate. Quote Link to comment Share on other sites More sharing options...
erchdk Posted February 18, 2021 Share Posted February 18, 2021 I also experienced extremely large PDF export with bad compression and quality in the file compared to exporting printing to a third party software PDF printer. Unfortunately links will not not included in print PDF function but only in export function. Any insights in a work around would be appreciated... Quote Link to comment Share on other sites More sharing options...
CorvusC Posted February 19, 2021 Author Share Posted February 19, 2021 On 2/18/2021 at 1:33 PM, erchdk said: I also experienced extremely large PDF export with bad compression and quality in the file compared to exporting printing to a third party software PDF printer. Unfortunately links will not not included in print PDF function but only in export function. Any insights in a work around would be appreciated... I have found the quality of the export to be fine, apart from the file bloat caused by multiple copies of placed PDFs. Trying to mitigate this by increasing compression of bitmapped images will cause poor quality, though. If you're using a Mac you could try Panic's free tool ShrinkIt, which removes much of the unnecessary information without any recompression. Otherwise the only way I can find to get a reasonably sized export directly from Publisher is as I described above - use the Resources Manager to set placed PDFs to be embedded rather than linked, then move the originals from to a different location on your hard drive (you might want to copy any PDFs you're placing to a temporary location before placing them to make this less hassle). Quote Link to comment Share on other sites More sharing options...
mjb Posted February 20, 2021 Share Posted February 20, 2021 I use Affinity to produce our village news magazine. With this upgrade I have seen the PDF file go from 10Mb to 30Mb with the afpub file size going from 30Mb to 50Mb. Any advice on reducing the file size would be welcomed. Quote Link to comment Share on other sites More sharing options...
erchdk Posted February 21, 2021 Share Posted February 21, 2021 On 2/19/2021 at 4:30 PM, CorvusC said: I have found the quality of the export to be fine, apart from the file bloat caused by multiple copies of placed PDFs. Trying to mitigate this by increasing compression of bitmapped images will cause poor quality, though. If you're using a Mac you could try Panic's free tool ShrinkIt, which removes much of the unnecessary information without any recompression. Otherwise the only way I can find to get a reasonably sized export directly from Publisher is as I described above - use the Resources Manager to set placed PDFs to be embedded rather than linked, then move the originals from to a different location on your hard drive (you might want to copy any PDFs you're placing to a temporary location before placing them to make this less hassle). I have discovered a rather cumbersome workaround. I print the PDF through a third party PDF software printer. I get really nice quality and go from files size 120mb to roughly 5mb. But I loose the hyperlinks added to images. Then I open the PDF in publisher which it does really nice and smooth, add the links to the pages that I need, and then export the document using APu PDF export function and I get the good quality images and hyperlinks and the small file size... Tedious, but it's necessary as this is a portfolio I want to email to people/customers so small size is necessary and good image quality equally so. Quote Link to comment Share on other sites More sharing options...
mjb Posted February 22, 2021 Share Posted February 22, 2021 Thanks for the pointer, I still have Serif Page plus. I opened each PDF in Page Plus and converted to a PNG. Once inserted into the Affinity Document the afpub size came down to about 2.5Mb from 60Mb and the exported PDF came down to 6MB from 30 Mb. OA little loss of definition if the exported PDF is viewed at greater than 125%. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.