imagepolygon

Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Draws a polygon
imagepolygon(GdImage $image, array $pointsint $color): bool
        if ($this->hasBorder()) {

            
$border_color = new Color($this->border_color);

            
imagesetthickness($image->getCore(), $this->border_width);

            
imagepolygon($image->getCore(), $this->pointsintval(count($this->points) / 2), $border_color->getInt());

        }

    

        return 
true;