mogrify icon indicating copy to clipboard operation
mogrify copied to clipboard

Adding a watermark

Open Pjino opened this issue 7 years ago • 5 comments

I think it is not possible yet to add another picture with an watermark on top of an image. Are you considering that? Thank you.

Pjino avatar Jul 09 '17 23:07 Pjino

What ImageMagick command are you trying to use?

talklittle avatar Jul 10 '17 06:07 talklittle

I was thinking composite.

Pjino avatar Jul 10 '17 08:07 Pjino

You could try something like https://github.com/route/mogrify/issues/39#issuecomment-287486610

image_operator(image, "convert -size:  1200x1200 #{image_path} \ #{image_to_combine_path}  -geometry  +0+10  -composite") 
|> create(in_place: true)

talklittle avatar Jul 10 '17 17:07 talklittle

Thank you! Maybe if you would put this in README you wouldn't be bothered anymore by someone asking for composite feature... :)

Pjino avatar Jul 10 '17 18:07 Pjino

Well, after a few attempts I wasn't able to make any image_operator() commands work. For example,

image = open(Path.absname("priv/static/uploads/45992.png"))
image_operator(image, "convert -resize:  50% ") |> create(in_place: true)

doesn't output nothing although I get no errors...

Pjino avatar Jul 10 '17 21:07 Pjino