From: info at frankdegraaf dot net Operating system: Debian Lenny amd64 PHP version: 5.2.11 PHP Bug Type: GD related Bug description: imagettfbbox gives unexpected results.
Description: ------------ The return results for imagettfbbox are way off. The function gives a large negative values for [1] (lower left corner, Y position), [2] (lower right corner, X position), [4](upper right corner, X position), [7](upper left corner, Y position). The changelog shows a solved bug regarding this function (#48555), perhaps it is related. The font can be downloaded here: http://www.fonts4free.net/dsplus/m.php?p=bn_machine.zip Reproduce code: --------------- <?php print_r(imagettfbbox(37, 11, '/var/www/fonts/BNMachine.ttf', 'T')); ?> Expected result: ---------------- Result from PHP 5.2.10: Array ( [0] => -1 [1] => 0 [2] => 25 [3] => -4 [4] => 18 [5] => -42 [6] => -9 [7] => -37 ) Actual result: -------------- Result from PHP 5.2.11: Array ( [0] => -1 [1] => -2147483648 [2] => -2147483648 [3] => -4 [4] => -2147483648 [5] => -42 [6] => -9 [7] => -2147483648 ) -- Edit bug report at http://bugs.php.net/?id=50014&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=50014&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=50014&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=50014&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=50014&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=50014&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=50014&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=50014&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=50014&r=needscript Try newer version: http://bugs.php.net/fix.php?id=50014&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=50014&r=support Expected behavior: http://bugs.php.net/fix.php?id=50014&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=50014&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=50014&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=50014&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=50014&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=50014&r=dst IIS Stability: http://bugs.php.net/fix.php?id=50014&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=50014&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=50014&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=50014&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=50014&r=mysqlcfg