Tag Archives: imagine

Submediant: Imagine – A work in progress

This past weekend, I worked more on Submediant.  This time through included both an internal refactor as well as a few new features:

  • Instruments have a chord notation
  • Instruments can have individually adjusted volume
  • Notes can now be tied together

To help demonstrate the new features, I’ve called upon one of my inspirations, John Lennon.  This is about a quarter of the song, Imagine rendered with Submediant…

Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

Here is source code for the song…

@SONGTITLE:Imagine
@ALBUMNAME:Let Them Eat Test
@ARTIST:Little Robots
@YEAR:2011
@GENRE:other

@bpm:80
@volume:1000

&righthand volume:1000
D4,E4,G4:1/8:tie C4:1/8 D4,E4,G4:1/8 C4:1/8:untie D4,E4,G4:1/8:tie C4:1/8:untie D4,E4,G4:1/4
D4,F4,A4:1/8:tie C4:1/8 D4,F4,A4:1/8 C4:1/8:untie D4,F4,A4:1/8:tie C4:1/8:untie D4,F4,A4:1/4

&lefthand volume:1000
C2,G3:1/2. C2,B3:1/8:tie C2,C4:1/8:untie
F2,A3:1/2. F2,A3:1/16:tie A#3:1/16 B3:1/16 C4:1/16:untie

&vocals volume:4000
_:whole
_:whole

&righthand
D4,E4,G4:1/8:tie C4:1/8 D4,E4,G4:1/8 C4:1/8:untie D4,E4,G4:1/8:tie C4:1/8:untie D4,E4,G4:1/4
D4,F4,A4:1/8:tie C4:1/8 D4,F4,A4:1/8 C4:1/8:untie D4,F4,A4:1/8:tie C4:1/8:untie D4,F4,A4:1/4
D4,E4,G4:1/8:tie C4:1/8 D4,E4,G4:1/8 C4:1/8:untie D4,E4,G4:1/8:tie C4:1/8:untie D4,E4,G4:1/4

&lefthand
C2,G3:1/2. C2,B3:1/8:tie C2,C4:1/8:untie
F2,A3:1/2. F2,A3:1/16:tie A#3:1/16 B3:1/16 C4:1/16:untie
C2,G3:1/2. C2,B3:1/8:tie C2,C4:1/8:untie

&vocals
# Imagine there's no hea-
G4:1/8 G4:1/8 G4:1/8 G4:1/4 B4:1/8 B4:1/8:tie
# ven--
B4:1/8 A4:1/8 A4:1/4:untie _:half
#     It's easy if you
_:1/8 G4:1/8 G4:1/8 G4:1/8 G4:1/4 B4:1/4

&righthand
D4,F4,A4:1/8:tie C4:1/8 D4,F4,A4:1/8 C4:1/8:untie D4,F4,A4:1/8:tie C4:1/8:untie D4,F4,A4:1/4
D4,E4,G4:1/8:tie C4:1/8 D4,E4,G4:1/8 C4:1/8:untie D4,E4,G4:1/8:tie C4:1/8:untie D4,E4,G4:1/4
D4,F4,A4:1/8:tie C4:1/8 D4,F4,A4:1/8 C4:1/8:untie D4,F4,A4:1/8:tie C4:1/8:untie D4,F4,A4:1/4

&lefthand
F2,A3:1/2. F2,A3:1/16:tie A#3:1/16 B3:1/16 C4:1/16:untie
C2,G3:1/2. C2,B3:1/8:tie C2,C4:1/8:untie
F2,A3:1/2. F2,A3:1/16:tie A#3:1/16 B3:1/16 C4:1/16:untie

&vocals
# try...
B4:1/8:tie A4:1/8 A4:1/2:untie _:1/4
#     No hell below-
_:1/4 G4:1/8 G4:1/8:tie G4:1/4:untie B4:1/8 B4:1/8:tie
# us--
B4:1/8:untie A4:1/8 A4:1/4 _:half

You can see that chords are simply notes that specify multiple frequencies… for example, C4,E4:1/4 is a quarter note that rings as both middle C and the E a step above it. You can also see the notation for tied notes:  C4:1/8:tie C4:1/8 C4:1/8:untie are three 8th notes tied together. Whether a note is tied or not tells the instrument rendering the sound how to handle the attack/decay aspects of the sound generated…

You can see that each of the instruments in the source sets a custom volume.  One thing that I want to work on in the future is allowing the volume of an instrument to change.  Even though you can set the volume on any of the lefthand designators, only the last one is applied to the whole song.

There are a few aspects of the code that bother me… it needs more refactoring… but I’ve gotten it to the point where I need it.  I can now use Submediant as a framework to give Little Robots the ability to speak.