#!/usr/bin/perl -wT use strict; use GD::Simple; my ($width, $height) = $data =~ m!new($width,$height); $img->fgcolor('black'); # get all for(split/\n/,$data) { if($_ =~ m!!xms) { my ($x, $y, $label) = $_ =~ m!(.*)!xms; if (defined $label) { $img->moveTo(int $x,int $y); $img->string($label); } } } print CGI::header('image/png'), $img->png; exit;