小白教程
所有教程
关于
Search
172.71.254.144
172.71.254.144
参数设置
贡献
退出
操作
编辑
移动
保护
信息
历史
删除
查看“Php imagearc”的源代码
本页内容
上一节:
Php_imageantialias
下一节:
Php_imagechar
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
{{DISPLAYTITLE:imagearc()}}[[Category:PHP GD 图形处理函数参考手册|12]] = PHP imagearc - 画椭圆弧 = [[:Category:PHP GD 图形处理函数参考手册]] imagearc — 用于画椭圆弧。 === 语法 === <sample title="" desc="" lang="php" hererun="1"> bool imagearc ( resource $image , int $cx , int $cy , int $w , int $h , int $s , int $e , int $color ) </sample> imagearc() 以 cx,cy(图像左上角为 0, 0)为中心在 image 所代表的图像中画一个椭圆弧。 w 和 h 分别指定了椭圆的宽度和高度,起始和结束点以 s 和 e 参数以角度指定。0°位于三点钟位置,以顺时针方向绘画。 == <sample title="" desc="" lang="php" hererun="1"> <?php $img = imagecreatetruecolor(200, 200);// 创建一个 200*200 图片 $white = imagecolorallocate($img, 255, 255, 255); // 颜色 // 画椭圆弧 imagearc($img, 140, 75, 50, 50, 0, 360, $white); // 浏览器输出图片 header("Content-type: image/png"); imagepng($img); imagedestroy($img); ?> </sample> 以上实例输出结果的图片如下: [[:Category:PHP GD 图形处理函数参考手册]]
返回至“
Php imagearc
”。
上一节:
Php_imageantialias
下一节:
Php_imagechar