#!/bin/bash # Script to help reproduce OpenOffice.org issue 71748. # # This script generates an arbitrary number of unique JPEGs from # one JPEG. # # REQUIREMENTS # - Bash, ImageMagick, wget # # # INSTRUCTIONS # 0. If necessary, adjust font path. (Any font will do!) # 1. Run this script # 2. Install the Photo Album Creator http://ooomacros.org/user.php#95976 # 3. Run the PAC on the directory of files created by this script # 4. Try to save in PowerPoint format FONT=/usr/share/fonts/msttcorefonts/arial.ttf if [ ! -f "full.jpg" ] then wget http://www.nasa.gov/images/content/171965main_image_feature_784_ys_full.jpg mv 171965main_image_feature_784_ys_full.jpg full.jpg fi for n in `seq 1 150` do # convert -font /usr/share/fonts/msttcorefonts/arial.ttf -pointsize 72 label:$n $n.png # composite #http://www.pcmag.com/article2/0,1759,1601585,00.asp echo "generating image $n..." convert full.jpg -fill white -gravity southwest \ -font $FONT -pointsize 300 -draw "text 2,20 '$n'" -border 5x5 full_$n.jpg done