Add watermark


As described in http://www.codeplex.com/PhotoHandler/Thread/View.aspx?ThreadId=11675.

Unless there is strong feedback in favor of that feature, I'd rather pass. The reason is that the high resolution version of the pictures is currently served by IIS directly. The handler doesn't modify it in any way and I'd like to keep it this way.

I'd suggest that you configure your photo editor so that it includes the watermark automatically as part of your workflow. Unless you publish your photos directly from the camera, that should work.


lenny76 wrote Sep 8, 2007 at 10:14 PM

I wrote a piece of code to implement a very simple watermark to the images (not the thumbnails)

just add it to the album.ashx code about at line 460, just before " g.dispose(); "
        if (! thumbnail)            {                //add watermark                StringFormat format = new StringFormat();                format.Alignment = StringAlignment.Far;                format.LineAlignment = StringAlignment.Far;                // draw string                g.DrawString("Lenny76 (c)",                    new Font("Verdana", 15, FontStyle.Bold),                    Brushes.Orange,                    new Rectangle(10, 10, width - 10, height - 10), format);            }
hope this is helpful to someone