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

search for in the

SWFShape->drawGlyph> <SWFShape->drawCurve
Last updated: Fri, 14 Aug 2009

view this page in

SWFShape->drawCurveTo

(PHP 4 >= 4.0.5)

SWFShape->drawCurveToTrace une courbe

Description

int drawCurveTo ( float $controlx , float $controly , float $anchorx , float $anchory [, float $targetx ], float $targety )
Avertissement

Cette fonction est EXPERIMENTALE. Cela signifie que le comportement de cette fonction, son nom et, concrètement, TOUT ce qui est documenté ici peut changer dans un futur proche, SANS PREAVIS ! Soyez-en conscient, et utilisez cette fonction à vos risques et périls.

swfshape->drawcurveto() trace une courbe (en utilisant le style de la ligne courante, défini par la fonction swfshape->setline()) depuis la position courante du stylo vers (anchorx ,anchory ) en utilisant le point de contrôle (controlx ,controly ).

Avec 6 paramètres, elle trace une courbe de Bézier vers le point (targetx , targety ) avec les points de contrôle (controlx , controly ) et (anchorx , anchory ).



add a note add a note User Contributed Notes
SWFShape->drawCurveTo
Chris
30-Jun-2005 07:28
for those new this all this, "anchor" is where you want to end up and "control" is the point you would go to if you were drawing a square.

for example, this would draw a quarter circle
<?php
    $s
->movePenTo(100, 100);
   
$s->drawLineTo(200, 100);
   
$s->drawCurveTo(200, 200, 100, 200);
   
$s->drawLineTo(100, 100);
?>

SWFShape->drawGlyph> <SWFShape->drawCurve
Last updated: Fri, 14 Aug 2009
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites