douyanzan9145 2013-02-01 13:09
浏览 25
已采纳

用2坐标在PHP中裁剪图像[重复]

Possible Duplicate:
Crop image in PHP

How to crop a part of an image when i have the coordinates of the upper left corner and lower right corner? I can't use the imagecopyresampled function cause in only use the upper left corner as a staring point and the end of the rectangle is determined automatically not by the coordinates of the lower right corner . :( Can anyone help? pls

  • 写回答

2条回答 默认 最新

  • dongpan9760 2013-02-01 13:44
    关注

    First of all here's a tutorial that was recommended to me for a similar problem. If this doesn't help, your solution will be buried away in the GD library somewhere. Here is the API for it. Hope that's of some use to you!

    As Andrej correctly pointed out, imagecopyresampled() is probably the one you're looking for.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?