#!/usr/bin/perl use strict; use warnings; use Image::Magick; use MIME::Base64; my $infile='in.jpg.base64'; my $blob=eval{local($/,@ARGV)=(undef,$infile); <>}; $blob = decode_base64($blob); my $image = Image::Magick->new(); $image->BlobToImage($blob); $image->Display();