ghostscript

Stamp PDF file with control for position of stamp file

心已入冬 提交于 2019-11-30 02:14:11
Does anyone know about stamping PDF file to PDF file and also controls for positioning PDF file stamp? I have a file orginal.pdf and logo.pdf . I want to stamp logo.pdf file to file orginal.pdf at the top left of file original.pdf . How can it be done with Ghostscript or pdftk ? It can be done with Ghostscript plus pdftk, but it requires at least 2 different steps. AFAIK, you cannot directly control pdftk 's stamp placement. By default it puts the stamp on the center of the page, and at the same time does a 'scale-to-fit' operation. So, you have to fix your stamp first so it is placed on an

Ghostscript command line parameters to convert EPS to PDF

99封情书 提交于 2019-11-29 22:55:04
Just installed Ghostscript 8.54 for Windows. Does anyone know of the minimum parameters to pass to gswin32c.exe to make it convert, say, someFile.eps to someFile.eps.pdf ? Since the question was about the "minimum parameters to pass to gswin32c.exe to make it convert, say, someFile.eps to someFile.eps.pdf" , let me give an answer: c:/path/to/gswin32c.exe ^ -sDEVICE=pdfwrite ^ -o c:/path/to/output.pdf ^ c:/path/to/input.eps or even shorter: gswin32c ^ -sDEVICE=pdfwrite ^ -o output.pdf ^ input.eps This will use the builtin, default parameters for Ghostscript. The most important of which, from

PDF compare on linux command line

孤街醉人 提交于 2019-11-29 20:22:16
I'm looking for a Linux command line tool to compare two PDF files and save the diffs to a PDF outfile. The tool should create diff-pdf's in a batch-process. The PDF files are construction plans, so pure text-compare doesn't work. Something like: <tool> file1.pdf file2.pdf -o diff-out.pdf Most of the tools I found convert the PDFs to images and compare them, but only with a GUI. Any other solution is also welcome. I've written my own script that does something similar to what you're asking for. The script uses 4 tools to achieve its goal: ImageMagick's compare command the pdftk utility (if you

Converting PDF without any images to CMYK

天涯浪子 提交于 2019-11-29 17:58:26
I read this post about how to convert PDF to CMYK, but when I try the accepted solution gs \ -o test-cmyk.pdf \ -sDEVICE=pdfwrite \ -sProcessColorModel=DeviceCMYK \ -sColorConversionStrategy=CMYK \ -sColorConversionStrategyForImages=CMYK \ test.pdf I does not get a pdf with CMYK color space, if my original pdf does not contain an image. If I add an image to it, I get the right result (checked with identify ). For example, if I create a svg with inskcape with one rectangle, export it to pdf, and then use the ghostscript command, it still gets a pdf in sRBG color space. But, if I add an image in

How to make Ghostscript's `ps2pdf14` stop subsetting fonts

瘦欲@ 提交于 2019-11-29 15:35:11
问题 I am using the ps2pdf14 utility that ships with Ghostscript, and I am having a problem with fonts. It does not seem to matter what instructions I pass to the command, it insists on subsetting any fonts it finds in the source document. e.g -dPDFSETTINGS#/prepress -dEmbedAllFonts#true -dSubsetFonts#false -dMaxSubsetPct#0 Note that the # is because the command is running on Windows, it is the same as =. If anyone has any idea how to tell ps2pdf not to subset fonts, I would be very grateful. ----

How to use Ghostscript for converting PDF to Image

和自甴很熟 提交于 2019-11-29 15:17:53
问题 I found that Ghostscript is able to convert PDF to Image format. I tried PDF to Image Converter but not able to understand it clearly. I have installed gs905w64.exe but when I tried to add reference to my web application I am getting this error. A reference to gsdll32.dll could not be added. No type libraries were found in the component. 回答1: You can use C# to run the GhostScript command line or use Platform Invoke (pInvoke) calls to call the GhostScript dll directly. GhostScript is primarily

How to change page orientation of PDF? (Ghostscript or PostScript solution needed)

两盒软妹~` 提交于 2019-11-29 11:10:35
问题 Given a PDF document, how do I change individual page orientation? I'm using latest version of Ghostscript. 回答1: Why do you require usage of Ghostscript? Would it be acceptable to use another Free, Open Source Software tool running on the commandline, such as pdftk ? Anyway, here is how to rotate pages with Ghostscript. However, this may not work for your intentions, because you cannot force a certain orientation for an individual page only. It relies on an internal Ghostscript algorithm that

Issue with Imagick and also with phmagick: Postscript delegate failed / No such file or directory

对着背影说爱祢 提交于 2019-11-29 09:17:31
问题 I'm using imagick 3.0.1 and also phmagick (http://www.francodacosta.com/phMagick/download). No matter what, both are giving me the same kind of error when I try to convert a PDF to JPEG. For example: Postscript delegate failed `/tmp/magick-bfxIrUJ5': No such file or directory @ error/pdf.c/ReadPDFImage/669 I'm using Ghostcript-9.05 (running on /usr/local/bin/gs). Also ImageMagick-6.7.6-8 (running on /usr/local/bin/convert). I already checked folder's permission (755). ImageMagick works

Can't add new Redirected Port in Windows 7 after installing RedMon

馋奶兔 提交于 2019-11-29 08:55:15
问题 My operating system is Windows 7 32bit. I installed RedMon1.7 , Ghostscript 8.71 and GSview 4.9 ; installations were successful. I went to Add New Local Printer in Windows Devices and Printers , clicked on Create A New Port , and selected Redirected Port from the Type of Port list. Clicked Next and in the Add New Port window I named RPT1: and clicked OK but it says Specified port cannot be added. Operation could not be completed (error 0x00000001) I tried giving different names to the port,

Converting a multiple-page PDF to a single image

半世苍凉 提交于 2019-11-29 07:30:29
问题 I'm attempting to convert a PDF into a single image using GhostScript. Only the first page is converted, while my intention is to generate a horrendously tall PNG/JPG image with all the pages concatenated together. These are the parameters I'm currently passing to the GhostScript DLL (via a .NET application): pdf2img \ -dNOPAUSE \ -dBATCH \ -dSAFER \ -sDEVICE=png256 \ -dGraphicsAlphaBits=4 \ -dTextAlphaBits=4 \ -dDOINTERPOLATE \ -dAlignToPixels=1 \ -r300x300 \ -sOutputFile=GLOSS.png \ GLOSS