downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

ImagickDraw::circle> <ImagickDraw::arc
[edit] Last updated: Sat, 25 May 2013

view this page in

ImagickDraw::bezier

(PECL imagick 2.0.0)

ImagickDraw::bezierDraws a bezier curve

Descrição

bool ImagickDraw::bezier ( array $coordinates )
Aviso

Esta função não está documentada; somente a lista de argumentos está disponível.

Draws a bezier curve through a set of points on the image.

Parâmetros

coordinates

Multidimensional array like array( array( 'x' => 1, 'y' => 2 ), array( 'x' => 3, 'y' => 4 ) )

Valor Retornado

Não há valor retornado.



add a note add a note User Contributed Notes ImagickDraw::bezier - [1 notes]
up
0
zombiebovine at gmail dot com
3 years ago
How to use:

<?php
    $width
200;
   
$height = 200;
   
$border = 2;
   
   
$img = new Imagick();
   
$img->newImage( $width, $height, new ImagickPixel( 'transparent' ) );
   
   
$draw = new ImagickDraw();
   
$draw->setStrokeColor( new ImagickPixel( 'black' ) );
   
$draw->setStrokeWidth( 2 );
   
$draw->setFillColor( new ImagickPixel( 'transparent' ) );

   
// will fail in an obscure manner if the input data is invalid
   
$points = array
    (
        array(
'x' => 0, 'y' => 200 ),
        array(
'x' => 0, 'y' => 0 ),
        array(
'x' => 200, 'y' => 200 ),
        array(
'x' => 200, 'y' => 0 )
    );
   
   
$draw->bezier($points);
           
   
$img->drawImage( $draw );
   
$img->setImageFormat( "png" );
   
   
header( "Content-Type: image/png" );
    echo
$img;
?>

 
show source | credits | sitemap | contact | advertising | mirror sites