CairoContext
PHP Manual

CairoContext::copyPathFlat

cairo_copy_path_flat

(PECL cairo >= 0.1.0)

CairoContext::copyPathFlat -- cairo_copy_path_flatGets a flattened copy of the current path

Açıklama

Nesne yönelimli kullanım (method):

public CairoPath CairoContext::copyPathFlat ( void )

Yordamsal kullanım:

CairoPath cairo_copy_path_flat ( CairoContext $context )

Gets a flattened copy of the current path and returns it to the user as a CairoPath.

This function is like CairoContext::copyPath() except that any curves in the path will be approximated with piecewise-linear approximations, (accurate to within the current tolerance value). That is, the result is guaranteed to not have any elements of type CAIRO_PATH_CURVE_TO which will instead be replaced by a series of CAIRO_PATH_LINE_TO elements.

Değiştirgeler

context

A CairoContext object

Dönen Değerler

A copy of the current path

Örnekler

Örnek 1 Nesne yönelimli kullanım

<?php

$surface 
= new CairoImageSurface(CairoFormat::ARGB325050);

$context = new CairoContext($surface);

var_dump($context->copyPathFlat());

?>

Yukarıdaki örnek şuna benzer bir çıktı üretir:

object(CairoPath)#3 (0) {
}

Örnek 2 Yordamsal kullanım

<?php

$surface 
cairo_image_surface_create(CAIRO_FORMAT_ARGB325050);

$context cairo_create($surface);

var_dump(cairo_copy_path_flat($context));

?>

Yukarıdaki örnek şuna benzer bir çıktı üretir:

object(CairoPath)#3 (0) {
}

Ayrıca Bakınız


CairoContext
PHP Manual