Watermark to each village multi-page pdf

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
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Watermark to each village multi-page pdf

Post by morob »

Good day, dear developers! There is a problem - it is necessary to place a watermark on each page of multi-page pdf file, but when entering the command:
convert (obr.pdf [0] logo.jpg -gravity SouthEast -compose multiply -composite) obr.pdf -delete 1 result.pdf

It turns out that the watermark only appears on the first page, if you remove the "[0sch" that are superimposed on top of the last page of the document first. Tell me what to do.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Watermark to each village multi-page pdf

Post by snibgo »

"-layer composite" should help here. See http://imagemagick.org/script/command-l ... php#layers

Eg:

Code: Select all

convert obr.pdf null: logo.jpg -gravity SouthEast -compose multiply -layers composite result.pdf
[Mod note: I've removed your other post. Please don't multi-post.]
snibgo's IM pages: im.snibgo.com
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Re: Watermark to each village multi-page pdf

Post by morob »

Thank you very much, it worked out!
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Re: Watermark to each village multi-page pdf

Post by morob »

Good day! Tasked to make a translucent watermark with the inscription (opaque rectangle and label) on the pdf document with the command:

convert -density 100 obr.pdf null: ( convert logo_p0.png -fill grey -colorize 35 ) -fill grey -font Arial -pointsize 18 -gravity SouthEast -geometry +160+30 -compose multiply -layers composite -annotate +160+60 "Copyrigth of IRIS" result.pdf

A change in the size of the rectangle.

Tell me what to do?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Watermark to each village multi-page pdf

Post by fmw42 »

convert -density 100 obr.pdf null: ( convert logo_p0.png -fill grey -colorize 35 ) -fill grey -font Arial -pointsize 18 -gravity SouthEast -geometry +160+30 -compose multiply -layers composite -annotate +160+60 "Copyrigth of IRIS" result.pdf
Parenthesis processing does not use convert in the command.

try

Code: Select all

convert -density 100 obr.pdf null: ( logo_p0.png -fill grey -colorize 35 ) -fill grey -font Arial -pointsize 18 -gravity SouthEast -geometry +160+30 -compose multiply -layers composite -annotate +160+60 "Copyrigth of IRIS" result.pdf
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Re: Watermark to each village multi-page pdf

Post by morob »

Thank you very much for your reply, I will try.
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Re: Watermark to each village multi-page pdf

Post by morob »

Good day! Everything seems to happen, but how to make that picture no_copy.png was in the foreground pdf document?

convert -density 200 v8.pdf null: ( no_copy.png -fill grey80 -colorize 80 ) -fill grey10 -font c:\windows\fonts\arial.ttf -pointsize 10 -gravity Southwest -geometry +1830+50 -compose multiply -layers composite -annotate +1830+90 @stamp.txt result.pdf
morob
Posts: 8
Joined: 2014-09-03T23:17:19-07:00
Authentication code: 6789

Re: Watermark to each village multi-page pdf

Post by morob »

Good day! With the installation of the image in the foreground turned out, but in the one page document, tell me how to do it in a multi-page document? The code is as follows:

d:\imagemagick\convert -density 200 d:\imagemagick\v8.pdf null: ( d:\imagemagick\no_copy.png -fill grey80 -colorize 80 ) -fill grey10 -font c:\windows\fonts\arial.ttf -pointsize 10 -gravity Southwest -geometry +1830+50 -compose dst-out -matte -layers composite -annotate +1830+150 @d:\imagemagick\stamp.txt d:\imagemagick\result.pdf
Post Reply