|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2003-03-03 03:03 UTC] jeremy at nirvani dot net
I have read these two bugs and this does not seem to be related: 17261 http://bugs.php.net/bug.php?id=17261 17192 http://bugs.php.net/bug.php?id=17192 To verify it is not one of the above bugs: (Notice only a big black box and no text) http://www.nirvani.org/not_bug_17192_or_17261.php http://www.nirvani.org/not_bug_17192_or_17261.phps To be sure, I even went so far as to put the GDFONRPATH in my global environment. (snip from phpinfo() _ENV["GDFONTPATH"] /home/httpd/clients/nirvani.org/ ) This shows the problem of the array elements having bogus values: http://www.nirvani.org/imagettfbbox_bug.php http://www.nirvani.org/imagettfbbox_bug.phps A strange oddity, refresh this above page and watch array[7] change - that should not happen, it should be the upper left corner, Y position, which IMO should stay the same, no matter how bogus the data is. fontfile (for sanity's sake): http://www.nirvani.org/times.ttf The array values returned seem to be a bug compared to what is expected from here: http://php.net/imagettfbbox Paste of the output array: array(8) { [0]=> int(5) [1]=> int(-1610627808) [2]=> int(-1610628216) [3]=> int(134958127) [4]=> int(136904992) [5]=> int(12) [6]=> int(-1610628152) [7]=> int(1075156968) } my configure line: './configure' '--disable-cli' '--disable-cgi' '--with-zlib' '--with-bz2' '--without-pear' '--with-gd' '--with-ttf' '--with-freetype' '--enable-gd-native-ttf' '--enable-bcmath' '--with-thttpd=/usr/src/thttpd-2.21b' phpinfo(): http://www.nirvani.org/php.html The same bug seemed to happend yesterday on a previous compile also. I added --with-ttf and --enable-gd-native-ttf, but that made no difference. Other GD stuff works. Looks like configure picked up on the bundled GD (2.0 compatible). It seems like anything GD-font-related does not work, and so this might be a deeper bug than just in imagettfbbox(). Jeremy PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Nov 03 12:00:02 2025 UTC |
Can you show that is the 'expected' output of this function? On my system it returns array(8) { [0]=> int(-3) [1]=> int(1) [2]=> int(79) [3]=> int(1) [4]=> int(79) [5]=> int(-34) [6]=> int(-3) [7]=> int(-34) } But since no position for the text is provided the positioning is completely random. What matters is the difference between the various numbers, which you can use to determine the how much space the text will occupy.ok I am getting these strange values, on php4.3.2 with apache 1.3.28. on redhat 7.2, with imagettfbbox here is some example dump: width -1073758320 : height -5379645430array(8) { [0]=> int(60) [1]=> int(-1073758256) [2]=> int(-1073758264) [3]=> int(1077688217) [4]=> int(48) [5]=> int(0) [6]=> int(11288) [7]=> int(1078099916) } here is a url that will reproduce: http://test.earth.itomic.com/build_text_image.php?imgStr=PRODUCT%20SPOTLIGHT&fontSize=14&font=v5loxicar the source is here: http://test.earth.itomic.com/build_text_image.php.txt If this has been fixed in CVS, is there a version that works? or is there one that will be coming soon?