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 Roberto Cahanap <rc...@BioReference.com> on 2011/05/02 17:12:41 UTC

PDF size reduction

Hello fop users!

Is there a way in FOP to reduce the size of the PDF?

We are embedding the PDF with a high resolution graphics which creates a huge PDF document.

One of the departments here at work would prefer a smaller PDF document, and they don't care about the quality of the graphics.

Is there a way we can do this?

Note, we are only using the batch file of FOP to generate the PDF.

Thank you for your response.

-Roberto

The information transmitted in this email and any of its attachments is intended only for the person or entity to which it is addressed and may contain BioReference Laboratories proprietary information, which is privileged, confidential, or subject to copyright belonging to BioReference Laboratories. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this in error, please contact the sender immediately and delete and destroy the communication and all of the attachments you have received and all copies thereof.

RE: PDF size reduction

Posted by Eric Douglas <ed...@blockhouse.com>.
It should depend on how the image is referenced, if it's embedding the
image once in the document, if it's referenced multiple times and
embedding it multiple times, or if it's an external link.
The obvious answer if you don't care about quality is to reduce the size
of the image before you try to embed it.  There are many programs which
can transform an image to a smaller file, which you could do with either
embedded code or a batch script.

________________________________

From: Roberto Cahanap [mailto:rcahanap@BioReference.com] 
Sent: Monday, May 02, 2011 11:13 AM
To: fop-users@xmlgraphics.apache.org
Subject: PDF size reduction



Hello fop users!

 

Is there a way in FOP to reduce the size of the PDF?

 

We are embedding the PDF with a high resolution graphics which creates a
huge PDF document.

 

One of the departments here at work would prefer a smaller PDF document,
and they don't care about the quality of the graphics.

 

Is there a way we can do this?

 

Note, we are only using the batch file of FOP to generate the PDF. 

 

Thank you for your response.

 

-Roberto

 

The information transmitted in this email and any of its attachments is
intended only for the person or entity to which it is addressed and may
contain BioReference Laboratories proprietary information, which is
privileged, confidential, or subject to copyright belonging to
BioReference Laboratories. Any review, retransmission, dissemination or
other use of, or taking of any action in reliance upon, this information
by persons or entities other than the intended recipient is prohibited
and may be unlawful. If you received this in error, please contact the
sender immediately and delete and destroy the communication and all of
the attachments you have received and all copies thereof.

RE: PDF size reduction

Posted by Roberto Cahanap <rc...@BioReference.com>.
Thank you everybody for responding.

So based on the responses, we need to change the quality of the JPG first and then create the PDF. I'll research around for an app that will allow me to do this programmatically.

Thank you again!

-Roberto


From: Giuseppe Briotti [mailto:g.briotti@gmail.com]
Sent: Tuesday, May 03, 2011 4:46 AM
To: fop-users@xmlgraphics.apache.org
Subject: Re: PDF size reduction


2011/5/3 Giuseppe Briotti <g....@gmail.com>>

2011/5/3 Michael Rubin <mr...@thunderhead.com>>

If you aren't bothered about image quality, then (albeit not knowing what format the image is currently) can you not use something like high JPEG compression on the graphics? This will dramatically reduce the image size and therefore the PDF size.

Thanks.

-Mike


Well, it seems that my message was sent without content. I agree with Pascal: you can avoid to load the color profile. If this is not enough, you can try to process all the images via batch. There are several tools that can allow that. Try for example Image Magick...

G.

--

Giuseppe Briotti
g.briotti@gmail.com<ma...@gmail.com>

"Alme Sol, curru nitido diem qui
promis et celas aliusque et idem
nasceris, possis nihil urbe Roma
visere maius."
(Orazio)
The information transmitted in this email and any of its attachments is intended only for the person or entity to which it is addressed and may contain BioReference Laboratories proprietary information, which is privileged, confidential, or subject to copyright belonging to BioReference Laboratories. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this in error, please contact the sender immediately and delete and destroy the communication and all of the attachments you have received and all copies thereof.

Re: PDF size reduction

Posted by TvT <tv...@nepatec.de>.
Hi,

i agree with Michael - reducing the image size is the key.
We had this problem once with huge TIFF files which can (after scanning)
easily have a size of 50MB or bigger.
With the java image io we converted those pics into TIFF-G4 standard which
are greatly reduced in size (kb level).

Afterwards also our pdfs were much smaller. If you own Adobe Acrobat you can
try the effect of reducing the image quality / adding compression. Go to
Advanced/PDF-Optimization ...

Regards,
ToM

2011/5/3 Giuseppe Briotti <g....@gmail.com>

>
>
> 2011/5/3 Giuseppe Briotti <g....@gmail.com>
>
>>
>>
>> 2011/5/3 Michael Rubin <mr...@thunderhead.com>
>>
>>>  If you aren't bothered about image quality, then (albeit not knowing
>>> what format the image is currently) can you not use something like high JPEG
>>> compression on the graphics? This will dramatically reduce the image size
>>> and therefore the PDF size.
>>>
>>> Thanks.
>>>
>>> -Mike
>>>
>>
>
> Well, it seems that my message was sent without content. I agree with
> Pascal: you can avoid to load the color profile. If this is not enough, you
> can try to process all the images via batch. There are several tools that
> can allow that. Try for example Image Magick...
>
>
> G.
>
> --
>
> Giuseppe Briotti
> g.briotti@gmail.com
>
> "Alme Sol, curru nitido diem qui
> promis et celas aliusque et idem
> nasceris, possis nihil urbe Roma
> visere maius."
> (Orazio)
>

Re: PDF size reduction

Posted by Giuseppe Briotti <g....@gmail.com>.
2011/5/3 Giuseppe Briotti <g....@gmail.com>

>
>
> 2011/5/3 Michael Rubin <mr...@thunderhead.com>
>
>>  If you aren't bothered about image quality, then (albeit not knowing
>> what format the image is currently) can you not use something like high JPEG
>> compression on the graphics? This will dramatically reduce the image size
>> and therefore the PDF size.
>>
>> Thanks.
>>
>> -Mike
>>
>

Well, it seems that my message was sent without content. I agree with
Pascal: you can avoid to load the color profile. If this is not enough, you
can try to process all the images via batch. There are several tools that
can allow that. Try for example Image Magick...

G.

-- 

Giuseppe Briotti
g.briotti@gmail.com

"Alme Sol, curru nitido diem qui
promis et celas aliusque et idem
nasceris, possis nihil urbe Roma
visere maius."
(Orazio)

Re: PDF size reduction

Posted by Giuseppe Briotti <g....@gmail.com>.
2011/5/3 Michael Rubin <mr...@thunderhead.com>

>  If you aren't bothered about image quality, then (albeit not knowing what
> format the image is currently) can you not use something like high JPEG
> compression on the graphics? This will dramatically reduce the image size
> and therefore the PDF size.
>
> Thanks.
>
> -Mike
>
>
> On 02/05/11 16:12, Roberto Cahanap wrote:
>
>  Hello fop users!
>
>
>
> Is there a way in FOP to reduce the size of the PDF?
>
>
>
> We are embedding the PDF with a high resolution graphics which creates a
> huge PDF document.
>
>
>
> One of the departments here at work would prefer a smaller PDF document,
> and they don’t care about the quality of the graphics.
>
>
>
> Is there a way we can do this?
>
>
>
> Note, we are only using the batch file of FOP to generate the PDF.
>
>
>
> Thank you for your response.
>
>
>
> -Roberto
>
>
>
> The information transmitted in this email and any of its attachments is intended only for the person or entity to which it is addressed and may contain BioReference Laboratories proprietary information, which is privileged, confidential, or subject to copyright belonging to BioReference Laboratories. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this in error, please contact the sender immediately and delete and destroy the communication and all of the attachments you have received and all copies thereof.
>
>
>
>      *Michael Rubin*
>
> Developer
>  [image: Thunderhead Logo] [image: Tagline] [image: Triangles]
>
>  *T*
>
>  *F*
>
>  *M*
>
>  *E*
>
>  *W*
>
> +44 20 8238 7400
>
> +44 20 8238 7401
>
>
>
> mrubin@Thunderhead.com
> www.thunderhead.com
>
>
>
> Thunderhead President, John McGee, discusses tackling the three toughest
> customer communication challenges. Click here<http://www.thunderhead.com/landing/three-toughest-customer-communication.php>to download the podcast transcript.
>  [image: LinkedIn] <http://www.linkedin.com/companies/25033/Thunderhead> [image:
> twitter] <http://twitter.com/Thunderheadon>[image: RSS]<http://www.thunderhead.com/rss/rss.php>[image:
> YouTube] <http://www.youtube.com/user/ThunderheadOn><http://thunderheadinnovate.wordpress.com/> [image:
> were-hiring] <http://thunderhead.com/about/careers.php>
>
> The contents of this e-mail are intended for the named addressee only. It
> contains information that may be confidential. Unless you are the named
> addressee or an authorized designee, you may not copy or use it, or disclose
> it to anyone else. If you received it in error please notify us immediately
> and then destroy it.
>
>


-- 

Giuseppe Briotti
g.briotti@gmail.com

"Alme Sol, curru nitido diem qui
promis et celas aliusque et idem
nasceris, possis nihil urbe Roma
visere maius."
(Orazio)

Re: PDF size reduction

Posted by Michael Rubin <mr...@thunderhead.com>.
If you aren't bothered about image quality, then (albeit not knowing what format the image is currently) can you not use something like high JPEG compression on the graphics? This will dramatically reduce the image size and therefore the PDF size.

Thanks.

-Mike

On 02/05/11 16:12, Roberto Cahanap wrote:
Hello fop users!

Is there a way in FOP to reduce the size of the PDF?

We are embedding the PDF with a high resolution graphics which creates a huge PDF document.

One of the departments here at work would prefer a smaller PDF document, and they don�t care about the quality of the graphics.

Is there a way we can do this?

Note, we are only using the batch file of FOP to generate the PDF.

Thank you for your response.

-Roberto


The information transmitted in this email and any of its attachments is intended only for the person or entity to which it is addressed and may contain BioReference Laboratories proprietary information, which is privileged, confidential, or subject to copyright belonging to BioReference Laboratories. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be unlawful. If you received this in error, please contact the sender immediately and delete and destroy the communication and all of the attachments you have received and all copies thereof.





Michael Rubin


Developer


[http://thunderhead.com/email_signature/images/Thunderhead-logo.png]    [http://thunderhead.com/email_signature/images/make-every-communication-count.png]      [http://thunderhead.com/email_signature/images/triangles.png]

 T

 F

 M

 E

 W


+44 20 8238 7400

+44 20 8238 7401



mrubin@Thunderhead.com<ma...@Thunderhead.com>

www.thunderhead.com<http://www.thunderhead.com>



Thunderhead President, John McGee, discusses tackling the three toughest customer communication challenges. Click here<http://www.thunderhead.com/landing/three-toughest-customer-communication.php> to download the podcast transcript.


[http://thunderhead.com/email_signature/images/linkedin.png]<http://www.linkedin.com/companies/25033/Thunderhead> [http://thunderhead.com/email_signature/images/twitter.png] <http://twitter.com/Thunderheadon> [http://thunderhead.com/email_signature/images/rss.png] <http://www.thunderhead.com/rss/rss.php> [http://thunderhead.com/email_signature/images/youtube.png] <http://www.youtube.com/user/ThunderheadOn> [http://thunderhead.com/email_signature/images/theblog.png] <http://thunderheadinnovate.wordpress.com/>  [http://thunderhead.com/email_signature/images/werehiring.png] <http://thunderhead.com/about/careers.php>

The contents of this e-mail are intended for the named addressee only. It contains information that may be confidential. Unless you are the named addressee or an authorized designee, you may not copy or use it, or disclose it to anyone else. If you received it in error please notify us immediately and then destroy it.





Re: PDF size reduction

Posted by Pascal Sancho <pa...@takoma.fr>.
What FOP version do you use?

until FOP 0.94 (IIRC), color profile was systematically included in PDF.
Now, when sRGB profile is used, it is not embedded in PDF. Removing
color profile will reduce PDF size.

Le 03/05/2011 09:09, Pascal Sancho a écrit :
> Hi,
> 
> There is no mechanism to reduce graphic size in FOP.
> You have to optimize it before running FOP.
> 
> You should find tools that can resample bitmap images in a batch process.
> 
> Le 02/05/2011 17:12, Roberto Cahanap a écrit :
>> Hello fop users!
>>
>> Is there a way in FOP to reduce the size of the PDF?
>> We are embedding the PDF with a high resolution graphics which creates a
>> huge PDF document.
>> One of the departments here at work would prefer a smaller PDF document,
>> and they don’t care about the quality of the graphics.
>> Is there a way we can do this?
>> Note, we are only using the batch file of FOP to generate the PDF.
>> Thank you for your response.
>>
>> -Roberto
> 

-- 
Pascal

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


Re: PDF size reduction

Posted by Pascal Sancho <pa...@takoma.fr>.
Hi,

There is no mechanism to reduce graphic size in FOP.
You have to optimize it before running FOP.

You should find tools that can resample bitmap images in a batch process.

Le 02/05/2011 17:12, Roberto Cahanap a écrit :
> Hello fop users!
> 
> Is there a way in FOP to reduce the size of the PDF?
> We are embedding the PDF with a high resolution graphics which creates a
> huge PDF document.
> One of the departments here at work would prefer a smaller PDF document,
> and they don’t care about the quality of the graphics.
> Is there a way we can do this?
> Note, we are only using the batch file of FOP to generate the PDF.
> Thank you for your response.
> 
> -Roberto

-- 
Pascal

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