[thelist] Fancy text blending with PHP/GD

Brooking, John John.Brooking at sappi.com
Mon Jul 31 11:01:36 CDT 2006

Does anyone have any experience creating doing fancy text and image
blending using PHP/GD? My wife and I are currently using Paint Shop Pro
9 to prepare images for her online art gallery, and I'm wondering if I
can automate it more using GD.

What we do is create kind of a "watermark" on each image with the
copyright notice, for example, see [1]. In PSP, the steps to get that
effect are to put the text on a new layer as black on white, and fill in
the rest of the layer as white, then apply the Emboss effect to that
layer, and set the layer blend mode to Soft Light. I don't completely
understand what the Soft Light filter does (something about the
background shining through depending on the gray value of the layer
pixel), but we found this procedure documented on the 'net somewhere and
it works great.

I've just written some software to allow her to upload the images
herself through a form, and the software will create an initial
thumbnail and full-size image, as well as allow her to tweak the size
once it's uploaded. I'd like to eliminate the manual PSP step of putting
on the copyright notice, but I can't tell from my reading yet if GD can
do this, specifically the Emboss effect and the Soft Light blending. I
haven't found anything definitive by searching the net yet, and I also
have not been able to find any mailing lists dedicated just to GD, even
by looking on the PHP or GD sites. Before I spend a lot of time
experimenting, I though I'd see if anyone here had any knowledge of

So, ideas, anyone? Thanks in advance! (BTW, any client-side fanciness
like JavaScript is not sufficient, because the whole idea of the
copyright notice is that if anyone downloads the image, it will still
contain the notice. [Unless they intentionally crop it out themselves,
which I think would allow for legal action.])

 - John

[1] http://www.mainebrook.com/art/picture.php?imageID=45&page=1


This message may contain information which is private, privileged or confidential and is intended solely for the use of the individual or entity named in the message. If you are not the intended recipient of this message, please notify the sender thereof and destroy / delete the message. Neither the sender nor Sappi Limited (including its subsidiaries and associated companies) shall incur any liability resulting directly or indirectly from accessing any of the attached files which may contain a virus or the like.

More information about the thelist mailing list