Open Source command line tool for optimizing PDF












10














Are there any open-source command line tool for optimizing PDF in Ubuntu. I have used Ghost Script and i am able to convert the PDF into 72 dpi,



gs -sDEVICE=pdfwrite 
-dCompatibilityLevel=1.4
-dPDFSETTINGS=/screen
-dNOPAUSE -dQUIET -dBATCH
-sOutputFile=myOutput.pdf myInput.pdf


But what i would like to do is mention what dpi i want to convert the PDF to, like a 300 dpi PDF file to 90 dpi PDF file.










share|improve this question















migrated from stackoverflow.com Sep 28 '11 at 12:17


This question came from our site for professional and enthusiast programmers.















  • Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
    – N.N.
    Sep 28 '11 at 12:26










  • Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
    – N.N.
    Sep 28 '11 at 12:27










  • Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
    – Glutanimate
    Apr 11 '13 at 21:37
















10














Are there any open-source command line tool for optimizing PDF in Ubuntu. I have used Ghost Script and i am able to convert the PDF into 72 dpi,



gs -sDEVICE=pdfwrite 
-dCompatibilityLevel=1.4
-dPDFSETTINGS=/screen
-dNOPAUSE -dQUIET -dBATCH
-sOutputFile=myOutput.pdf myInput.pdf


But what i would like to do is mention what dpi i want to convert the PDF to, like a 300 dpi PDF file to 90 dpi PDF file.










share|improve this question















migrated from stackoverflow.com Sep 28 '11 at 12:17


This question came from our site for professional and enthusiast programmers.















  • Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
    – N.N.
    Sep 28 '11 at 12:26










  • Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
    – N.N.
    Sep 28 '11 at 12:27










  • Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
    – Glutanimate
    Apr 11 '13 at 21:37














10












10








10


3





Are there any open-source command line tool for optimizing PDF in Ubuntu. I have used Ghost Script and i am able to convert the PDF into 72 dpi,



gs -sDEVICE=pdfwrite 
-dCompatibilityLevel=1.4
-dPDFSETTINGS=/screen
-dNOPAUSE -dQUIET -dBATCH
-sOutputFile=myOutput.pdf myInput.pdf


But what i would like to do is mention what dpi i want to convert the PDF to, like a 300 dpi PDF file to 90 dpi PDF file.










share|improve this question















Are there any open-source command line tool for optimizing PDF in Ubuntu. I have used Ghost Script and i am able to convert the PDF into 72 dpi,



gs -sDEVICE=pdfwrite 
-dCompatibilityLevel=1.4
-dPDFSETTINGS=/screen
-dNOPAUSE -dQUIET -dBATCH
-sOutputFile=myOutput.pdf myInput.pdf


But what i would like to do is mention what dpi i want to convert the PDF to, like a 300 dpi PDF file to 90 dpi PDF file.







command-line pdf open-source optimization






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Dec 26 at 3:17









Pablo Bianchi

2,3571528




2,3571528










asked Sep 28 '11 at 11:57









Rakesh

5981710




5981710




migrated from stackoverflow.com Sep 28 '11 at 12:17


This question came from our site for professional and enthusiast programmers.






migrated from stackoverflow.com Sep 28 '11 at 12:17


This question came from our site for professional and enthusiast programmers.














  • Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
    – N.N.
    Sep 28 '11 at 12:26










  • Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
    – N.N.
    Sep 28 '11 at 12:27










  • Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
    – Glutanimate
    Apr 11 '13 at 21:37


















  • Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
    – N.N.
    Sep 28 '11 at 12:26










  • Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
    – N.N.
    Sep 28 '11 at 12:27










  • Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
    – Glutanimate
    Apr 11 '13 at 21:37
















Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
– N.N.
Sep 28 '11 at 12:26




Welcome to Ask Ubuntu! Your question was migrated here from Stack Overflow. Please register on this site, too, and make sure that both accounts are associated with each other, otherwise you won't be able to comment on or accept answers or edit your question.
– N.N.
Sep 28 '11 at 12:26












Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
– N.N.
Sep 28 '11 at 12:27




Maybe you should rephrase your question since optimizing pdfs might be confused with linearizing them which is not what you're asking for.
– N.N.
Sep 28 '11 at 12:27












Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
– Glutanimate
Apr 11 '13 at 21:37




Please see this related Q&A for a number of GUI tools that can help you with optimizing your PDF files.
– Glutanimate
Apr 11 '13 at 21:37










1 Answer
1






active

oldest

votes


















7














I'll quote zweifel's comment on http://www.ubuntugeek.com/ubuntu-tiphowto-reduce-adobe-acrobat-file-size-from-command-line.html:






  • dPDFSETTINGS=/screen (screen-view-only quality, 72 dpi images)


  • dPDFSETTINGS=/ebook (low quality, 150 dpi images)


  • dPDFSETTINGS=/printer (high quality, 300 dpi images)


  • dPDFSETTINGS=/prepress (high quality, color preserving, 300 dpi
    imgs)


  • dPDFSETTINGS=/default (almost identical to /screen)


More options and fine tunning on the site:
http://milan.kupcevic.net/ghostscript-ps-pdf/




Thus you should use either the option dPDFSETTINGS=/printer or the option dPDFSETTINGS=/prepress to get 300 dpi.






share|improve this answer























  • Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
    – vy32
    Nov 6 '13 at 22:27











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f63384%2fopen-source-command-line-tool-for-optimizing-pdf%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









7














I'll quote zweifel's comment on http://www.ubuntugeek.com/ubuntu-tiphowto-reduce-adobe-acrobat-file-size-from-command-line.html:






  • dPDFSETTINGS=/screen (screen-view-only quality, 72 dpi images)


  • dPDFSETTINGS=/ebook (low quality, 150 dpi images)


  • dPDFSETTINGS=/printer (high quality, 300 dpi images)


  • dPDFSETTINGS=/prepress (high quality, color preserving, 300 dpi
    imgs)


  • dPDFSETTINGS=/default (almost identical to /screen)


More options and fine tunning on the site:
http://milan.kupcevic.net/ghostscript-ps-pdf/




Thus you should use either the option dPDFSETTINGS=/printer or the option dPDFSETTINGS=/prepress to get 300 dpi.






share|improve this answer























  • Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
    – vy32
    Nov 6 '13 at 22:27
















7














I'll quote zweifel's comment on http://www.ubuntugeek.com/ubuntu-tiphowto-reduce-adobe-acrobat-file-size-from-command-line.html:






  • dPDFSETTINGS=/screen (screen-view-only quality, 72 dpi images)


  • dPDFSETTINGS=/ebook (low quality, 150 dpi images)


  • dPDFSETTINGS=/printer (high quality, 300 dpi images)


  • dPDFSETTINGS=/prepress (high quality, color preserving, 300 dpi
    imgs)


  • dPDFSETTINGS=/default (almost identical to /screen)


More options and fine tunning on the site:
http://milan.kupcevic.net/ghostscript-ps-pdf/




Thus you should use either the option dPDFSETTINGS=/printer or the option dPDFSETTINGS=/prepress to get 300 dpi.






share|improve this answer























  • Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
    – vy32
    Nov 6 '13 at 22:27














7












7








7






I'll quote zweifel's comment on http://www.ubuntugeek.com/ubuntu-tiphowto-reduce-adobe-acrobat-file-size-from-command-line.html:






  • dPDFSETTINGS=/screen (screen-view-only quality, 72 dpi images)


  • dPDFSETTINGS=/ebook (low quality, 150 dpi images)


  • dPDFSETTINGS=/printer (high quality, 300 dpi images)


  • dPDFSETTINGS=/prepress (high quality, color preserving, 300 dpi
    imgs)


  • dPDFSETTINGS=/default (almost identical to /screen)


More options and fine tunning on the site:
http://milan.kupcevic.net/ghostscript-ps-pdf/




Thus you should use either the option dPDFSETTINGS=/printer or the option dPDFSETTINGS=/prepress to get 300 dpi.






share|improve this answer














I'll quote zweifel's comment on http://www.ubuntugeek.com/ubuntu-tiphowto-reduce-adobe-acrobat-file-size-from-command-line.html:






  • dPDFSETTINGS=/screen (screen-view-only quality, 72 dpi images)


  • dPDFSETTINGS=/ebook (low quality, 150 dpi images)


  • dPDFSETTINGS=/printer (high quality, 300 dpi images)


  • dPDFSETTINGS=/prepress (high quality, color preserving, 300 dpi
    imgs)


  • dPDFSETTINGS=/default (almost identical to /screen)


More options and fine tunning on the site:
http://milan.kupcevic.net/ghostscript-ps-pdf/




Thus you should use either the option dPDFSETTINGS=/printer or the option dPDFSETTINGS=/prepress to get 300 dpi.







share|improve this answer














share|improve this answer



share|improve this answer








edited Sep 28 '11 at 13:30

























answered Sep 28 '11 at 12:25









N.N.

8,259144986




8,259144986












  • Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
    – vy32
    Nov 6 '13 at 22:27


















  • Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
    – vy32
    Nov 6 '13 at 22:27
















Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
– vy32
Nov 6 '13 at 22:27




Unfortunately, this will not replace multiple instances of the same graphic with a single reference.
– vy32
Nov 6 '13 at 22:27


















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f63384%2fopen-source-command-line-tool-for-optimizing-pdf%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

數位音樂下載

When can things happen in Etherscan, such as the picture below?

格利澤436b