English | 简体中文 | 繁體中文
查询

ps_begin_pattern()函数—用法及示例

「 开创新模式 」


适用PHP版本(PECL ps >= 1.2.0)

ps_begin_pattern — 开创新模式

说明

ps_begin_pattern(
    resource $psdoc,
    float $width,
    float $height,
    float $xstep,
    float $ystep,
    int $painttype
): int|false

开始一种新的模式。一个模式就像一个页面,其中包含可以用来填充区域的绘图。通过调用ps_setcolor()并将颜色空间设置为pattern,可以像使用颜色一样使用它。


参数
psdoc
postscript文件的资源标识符,由ps_new()返回。

width
图案的宽度,以像素为单位。

height
图案的高度(以像素为单位)。

x-step
图案在水平方向上放置的像素距离。

y-step
图案在垂直方向上放置的像素距离。

painttype
Must be 1 or 2.

返回值
The identifier of the pattern 或者在失败时返回 false.

补充纠错
上一个函数: ps_begin_template()函数
下一个函数: ps_begin_page()函数
热门PHP函数
分享链接