Watermarking + file size

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
pagmed
Posts: 1
Joined: 2016-06-14T07:24:24-07:00
Authentication code: 1151

Watermarking + file size

Post by pagmed »

Trying to watermark a PDF with this command
composite -dissolve 25% -gravity center -density 150 "Watermark.png" "Input.pdf" "Output.pdf"

I get the desired output with density 150.
When the density is reduced, it distorts the output but the file size is acceptable
When the density is 150, output is acceptable but the file size is not acceptable. 30 MB files converted to a 160 MB file.

Any thoughts will be appreciated.

Peeyush
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Watermarking + file size

Post by snibgo »

If your input PDF file contains vector data (eg ordinary text), IM will rasterize it (convert it to dots). This will increase the filesize.

If you want to keep the PDF as vector, IM is the wrong tool.
snibgo's IM pages: im.snibgo.com
Post Reply