Draw a hexagon and fill it with color using Imager
Draw a hexagon and fill it with color using Imager
Source code.
use strict; use warnings;use Imager;
use Imager::Color;
use Imager::Fill;my $xsize = 500;
my $ysize = 250;my $img = Imager->new(xsize => $xsize, ysize => $ysize, channels => 4);
# Background white
$img->box(color => Imager::Color->new(255, 255, 255), xm…