ImagickDraw::pathStart

(PECL imagick 2, PECL imagick 3)

ImagickDraw::pathStartBir hat çizim listesinin başlangıcını bildirir

Açıklama

public ImagickDraw::pathStart(): bool
Uyarı

Bu işlev hala belgelendirilmemiştir; sadece değiştirge listesi mevcuttur.

Bir ImagickDraw::pathFinish() yönergesi ile sonlandırılana kadar ImagickDraw::path yönergeleri ile çizilecek bir hattın başlangıcını bildirir. Çizim için kullanılan ImagickDraw::path yönergeleri tek başlarına işlevsel olmadıklarından daima ImagickDraw::pathStart() ile ImagickDraw::pathFinish() yönergeleri arasında kullanılmalıdırlar.

Dönen Değerler

Hiçbir değer dönmez.

Örnekler

Örnek 1 - ImagickDraw::pathStart() örneği

<?php
function pathStart($strokeColor$fillColor$backgroundColor) {

    
$draw = new \ImagickDraw();

    
$draw->setStrokeOpacity(1);
    
$draw->setStrokeColor($strokeColor);
    
$draw->setFillColor($fillColor);

    
$draw->setStrokeWidth(2);
    
$draw->setFontSize(72);

    
$draw->pathStart();
    
$draw->pathMoveToAbsolute(5050);
    
$draw->pathLineToAbsolute(10050);
    
$draw->pathLineToRelative(050);
    
$draw->pathLineToHorizontalRelative(-50);
    
$draw->pathFinish();

    
$draw->pathStart();
    
$draw->pathMoveToAbsolute(5050);
    
$draw->pathMoveToRelative(3000);
    
$draw->pathLineToRelative(500);
    
$draw->pathLineToVerticalRelative(50);
    
$draw->pathLineToHorizontalAbsolute(350);
    
$draw->pathclose();
    
$draw->pathFinish();

    
$draw->pathStart();
    
$draw->pathMoveToAbsolute(50300);
    
$draw->pathCurveToAbsolute(50300100200300300);
    
$draw->pathLineToVerticalAbsolute(350);
    
$draw->pathFinish();

    
$imagick = new \Imagick();
    
$imagick->newImage(500500$backgroundColor);
    
$imagick->setImageFormat("png");

    
$imagick->drawImage($draw);

    
header("Content-Type: image/png");
    echo 
$imagick->getImageBlob();
}

?>

add a note add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top