From:             
Operating system: Windows XP
PHP version:      5.3.2
Package:          GD related
Bug Type:         Bug
Bug description:imageellipse() draws incorrectly

Description:
------------
On a system of Window XP, PHP/5.3.0 and GD 2.0.34 the imageellipse()
function fails to draw a circle properly when dealing with large
dimensions.



Calling the function for a circle with radius over 1032 pixels (an ellipse
with equal width and height over 2064 pixels) creates a deformed circle
with bumps in four directions. Increasing the dimensions makes things
worse.



On a system of Linux, PHP/5.2.13 and GD 2.0.34 the issue does not appear.

Test script:
---------------
<?php



header ("Content-type: image/png");

$im = imagecreatetruecolor(2200, 2200) or die("Cannot Initialize new GD
image stream");

imagefill($im, 0, 0, imagecolorallocate($im, 255, 255, 255));

imageellipse($im, 1100, 1100, 2064, 2064, imagecolorallocate($im, 0, 0,
255));

imagepng($im);

imagedestroy($im);



?>

Expected result:
----------------
A relatively smooth circle is drawn.

Actual result:
--------------
The resulting circle has irregular bumps in it.

-- 
Edit bug report at http://bugs.php.net/bug.php?id=51593&edit=1
-- 
Try a snapshot (PHP 5.2):            
http://bugs.php.net/fix.php?id=51593&r=trysnapshot52
Try a snapshot (PHP 5.3):            
http://bugs.php.net/fix.php?id=51593&r=trysnapshot53
Try a snapshot (PHP 6.0):            
http://bugs.php.net/fix.php?id=51593&r=trysnapshot60
Fixed in SVN:                        
http://bugs.php.net/fix.php?id=51593&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=51593&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=51593&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=51593&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=51593&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=51593&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=51593&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=51593&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=51593&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=51593&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=51593&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=51593&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=51593&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=51593&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=51593&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=51593&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=51593&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=51593&r=mysqlcfg

Reply via email to