#!/usr/bin/env perl -w # Mon Aug 15 10:55:16 JST 2005 # Create image of 'ls -l' # Just read 'hoge' (^_^; # Copyright(C) 2005 Sato Makoto use strict; use Image::Magick; my ($image, $status, $background ); $image = Image::Magick -> new; $image -> Set(size => '500x350'); $background = 'xc:black'; $status = $image -> Read(filename => $background); warn "$status" if $status; $status = $image -> Annotate( text => '@hoge', font => '-adobe-courier-medium-r-normal--12-120-75-75-m-70-iso8859-1', fill => 'white', x => 10, y => 20, ); warn "$status" if $status; $status = $image -> Write('png:ls-l.png'); $image -> Zoom('40%'); $image -> Set(quality => 75); $status = $image -> Write('jpg:ls-l.jpg'); warn "$status" if $status; undef $image;