Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

User name as Watermark

Ok, I searched the internet and stackoverflow but I just can't seem to find an answer for my problem.

I need to watermark images uploaded by users dynamically, but I don't want just text applied on an image. I need a real watermark like this: alt text

The only way I can achieve this effect is by using Photoshop, adding shadow and decreasing the filling to 0%. But if my site is visited by 200 users who upload their images, I just can't make for everyone of them a new PNG file with their user name. That's why I'm looking for a dynamic solution for this problem.

I already found classes how to add a png file as a watermark to images, but like I said before this won't work if my site is visited by a lot of users.

I hope someone knows a way how to solve this and get the same effect on images dynamically.

Thank you very much.

like image 410
moonwalker Avatar asked Nov 14 '10 02:11

moonwalker


1 Answers

The documentation of the ImageMagick image processing library includes such a transparent watermark example. Even if you would like to use GD instead of ImageMagick, it might give you an idea of how to do it.

like image 176
PleaseStand Avatar answered Sep 17 '22 21:09

PleaseStand