open F, TMP_GIF_FNAME; my $im = GD::Image->newFromGif( F ); close F;