位置: 编程技术 - 正文

PHP:imagesetthickness()的用法_GD库图像处理函数

编辑:rootadmin
imagesetthickness

推荐整理分享PHP:imagesetthickness()的用法_GD库图像处理函数,希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:,内容如对您有帮助,希望把文章链接给更多的朋友!

(PHP 4 >= 4.0.6, PHP 5)

imagesetthickness — 设定画线的宽度

说明 bool imagesetthickness ( resource $image , int $thickness )

imagesetthickness() 把画矩形,多边形,椭圆等等时所用的线宽设为 thickness 个像素。成功时返回 TRUE, 或者在失败时返回 FALSE。

Note: 此函数需要 GD 2.0.1 或更高版本(推荐 2.0. 及更高版本)。

参数

imagePHP:imagesetthickness()的用法_GD库图像处理函数

由图象创建函数(例如imagecreatetruecolor())返回的图象资源。

thickness

Thickness, in pixels.

返回值

成功时返回 TRUE, 或者在失败时返回 FALSE。

范例

Example #1 imagesetthickness() example

<?php//Createaximage$im=imagecreatetruecolor(,);$white=imagecolorallocate($im,0xFF,0xFF,0xFF);$black=imagecolorallocate($im,0x,0x,0x);//Setthebackgroundtobewhiteimagefilledrectangle($im,0,0,,,$white);//Setthelinethicknessto5imagesetthickness($im,5);//Drawtherectangleimagerectangle($im,,,,,$black);//Outputimagetothebrowserheader('Content-Type:image/png');imagepng($im);imagedestroy($im);?>

以上例程的输出类似于:

注释

Note: 此函数需要 GD 2.0.1 或更高版本(推荐 2.0. 及更高版本)。

PHP:imagestringup()的用法_GD库图像处理函数 imagestringup(PHP4,PHP5)imagestringup垂直地画一行字符串说明boolimagestringup(resource$image,int$font,int$x,int$y,string$s,int$col)imagestring()用col颜色将字符串s垂直地画到image

PHP:imagesetpixel()的用法_GD库图像处理函数 imagesetpixel(PHP4,PHP5)imagesetpixel画一个单一像素说明boolimagesetpixel(resource$image,int$x,int$y,int$color)imagesetpixel()在image图像中用color颜色在x,y坐标(图像左上角为

PHP:imagesetinterpolation()的用法_GD库图像处理函数 imagesetinterpolation(PHP5=5.5.0)imagesetinterpolationSettheinterpolationmethod说明boolimagesetinterpolation(resource$image[,int$method=IMG_BILINEAR_FIXED])Setstheinterpolationmethod,settinganinterp

本文链接地址:https://www.jiuchutong.com/biancheng/284748.html 转载请保留说明!

上一篇:PHP:imagesetstyle()的用法_GD库图像处理函数

下一篇:PHP:imagestringup()的用法_GD库图像处理函数

免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

鄂ICP备2023003026号

网站地图: 企业信息 工商信息 财税知识 网络常识 编程技术

友情链接: 武汉网站建设 电脑维修 湖南楚通运网络