|
|
 |
imageellipse (PHP 4 >= 4.0.6, PHP 5) imageellipse -- 画一个椭圆 说明int imageellipse ( resource image, int cx, int cy, int w, int h, int color)
imageellipse() 在 image
所代表的图像中画一个中心为
cx,cy(图像左上角为
0, 0)的椭圆。w 和 h
分别指定了椭圆的宽度和高度,椭圆的颜色由 color 指定。
参见 imagearc()。
agentyoungsoo at hanmail dot net
05-Dec-2002 12:56
When you wana use "ImageEllipse" function in under GD 2.0.2
version, you can use "ImageArc" like
bellow
---------------------------------------------------- $file_name
= "test.png";
$screen_x = 300; $screen_y =
200;
$x1 = $screen_x / 2; $y1 = $screen_y / 2;
$radius =
30;
$image = ImageCreate($screen_x, $screen_y); $black =
ImageColorAllocate($image, 0,0,0);
ImageArc($image, $x1, $y1,
$radius , $radius , 0, 360, $black);
ImagePng($image, $file_name);
ImageDestroy($image);
----------------------------------------------------
| |