Casualty 14 -18 ~ The making of a generative artwork by Richard Bolam – Part 3 #bolamat50 #casualty1418 #WW1

Screen shot 2014-07-28 at 15.11.28

For this iteration of the script, I have added the functionality to create 30 discrete PNG images, each with a human-readable label comprising title, date and serial number, and saved with an alpha-numeric-sortable filename. I decided to work with PNGs because they support transparency where as JPEGs do not. Also, flattened PNGs used lossless compression which both preserves the hard edges of the graphics and also produces very small files due to the low colour depth in the images.

Rendering to 72dpi produces noticeable anti-aliasing on the text but it seems appropriate for this work.

For the first day, the software does not vary the graphics, just the labels.You can see the first day’s pages here. The next iteration will add subtle colourisation to blocks of the figures.

#!/bin/bash
#casualty make script v2

for i in {1..30}
do

#pad figure
convert casualty.png -gravity center -extent 20×38 casualtypad.png

#create tiled image of figures
convert -size 400×646 xc:white -composite tile:casualtypad.png casualtytiled.png
convert casualtytiled.png -bordercolor white -border 99×90 casualtypage.png

#create page dimensions
convert casualtypage.png -gravity north -extent 598×850 casualtypage.png

#create label
convert -background white -font Gill-Sans -pointsize 10 -size 598×20 -gravity center label:’Casualty 14-18 ~ 28/07/14 – ‘$(printf %02d $i) Casualtylabel.png

#composite page & label
convert casualtypage.png -page +0+760 casualtylabel.png -layers flatten ‘Casualty1418-14_07_28-‘$(printf %02d $i).png

done

At some point, I will publish an exhaustive deconstruction of the code, but that will probably be on the casualty1418.net site.

The next stage will need to include colourising the figures, meta-tagging the pages and emailing the images to the WordPress blog.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s