|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-09-08 09:29 UTC] www dot query at gmail dot com
[2011-11-16 17:49 UTC] vito@php.net
[2011-11-16 17:49 UTC] vito@php.net
-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: vito
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 16:00:01 2025 UTC |
Description: ------------ Gmagick::compositeimage When placing smaller image on top of larger image, the 'x' parameter does not work. Whatever the value the result is x= 0. X is the width. X = 0, y = 0 is the top left corner. Trying to position in the bottom right corner results in the image appearing in the bottom left corner regardless of the value of 'x' being the 3rd parameter in $picin->compositeimage($pj,1,570,350); The larger image is 800 wide, 450 high, JPG. The smaller image is 222 wide by 98 high and is a PNG with a transparent background. Using the same instruction, $picin->compositeimage($pj,1,577,$height-98); ImageMagick positions correctly in bottom right corner. --------------------------------- Please supply any information that may be helpful in fixing the bug: * The version number of the PECL package or files you are using. HOW DO I GET THIS ???? ---------------------------- Reproduce code: --------------- PIC1 = 3840 wide x 2160 high. $picin = new Gmagick($pic1); $picin->scaleimage(800,0); $height = $picin->getimageheight(); $picin->setimagefilename($pic3); $picin->writeimage($pic3); $pj = new gmagick($dir2.'pj5.png'); $picin->compositeimage($pj,1,577,$height-98); # 222 x 98 / 800 x 450 $pic6 = $dir2.$ref.'-000.jpg'; $picin->writeimage($pic6); Expected result: ---------------- The smaller image positioned in the bottom right corner of the larger image. Actual result: -------------- The smaller image is position in the bottom left corner.