开发者

How can I add a watermark to images at the left, not the right

HELLo开发者_运维知识库, i'm using this code and its work very good but it add the logo at the right and iam want in on the left


I see these lines:

21     // destination x and y
22     $imageWidth-$logoWidth, $imageHeight-$logoHeight,

That is probably the right (minus the width of the image) bottom (minus the height) point, from where the watermark is started to write.

Try and replace that with for instance this for left top:

21     // destination x and y
22     0 , 0,

Or if you want left bottom, try:

21     // destination x and y
22     0 , $imageHeight-$logoHeight,


In row 22:

0, $imageHeight - $logoHeight,
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜