Motherwell, Elegy to the Spanish Republic No. 70

To process the Motherwell we wanted to do something different; instead of turning an image into MIDI notes, we turned an image into MIDI signals.

For previous images the output of the processing algorithm was a collection of notes. Here’s our Haskell data structure that defines a note:

data Note = Note { noteStartPosition :: Int
                 , noteValue :: Int
                 , noteLength :: Int
                 , noteVolume :: Int } deriving (Eq, Show)

The noteStartPosition defines where in the piece the note is played, the noteValue is a number between 0 (C) and 127 (G) that defines the pitch of the note to be played, the noteLength defines how long the note should be played for, and the noteVolume, a value between 0 (soft) and 100 (loud), defines how loud the note should be.

So a list of notes, forming a melody, might look like the following:

[ Note { noteStartPosition = 10
       , noteValue = 81
       , noteLength = 8
       , noteVolume = 14 }
, Note { noteStartPosition = 3
       , noteValue = 4
       , noteLength = 4
       , noteVolume = 7 }
, Note { noteStartPosition = 22
       , noteValue = 23
       , noteLength = 8
       , noteVolume = 26 } ]

For this piece we generated MIDI signals instead of notes so we needed to create a new data structure to represent a signal. Here’s how we defined a volume signal, for example:

data Volume = Volume { volumePosition :: Int
                     , volumeValue :: Int } deriving (Eq, Show)

The volumePosition, like noteStartPosition, defines where in the piece the volume is changed, and the volumeValue defines a volume, between 0 (soft) and 127 (loud), for the track.

We processed the image, left to right, taking the amount of black in each column, converting it to a MIDI signal. The X (horizontal) position in the image defined the volumePosition, and the amount of black in the column defined the volumeValue.

As usual the full source code is available at: https://bitbucket.org/gregorydavidlong/imagetosoundhaskell/src

I personally found this artwork to be very dynamic and somewhat visually aggressive, so I have reflected this with my choice of drums and noise.  I used the midi input Greg created to control aspects including volume and distortion levels of certain tracks.  

Here's an excerpt of the Motherwell track: