December 31, 2009

MuseScore and ScoreRender

By Nate LaClaire

A friend recently told me about open source music composition and notation software called MuseScore. I’m impressed! I’ve used a few closed source (and generally expensive) products and this one provides all of the features that I need with none of the cost. Although some functions could be easier or more readily apparent, I’m learning quickly and the basic stuff is easily understood. Very nice! It can open many formats (including MIDI and MusicXML) and saves to many formats (including MIDI, PDF, various image formats, and even audio files). It comes bundled with a piano SoundFont (meaning that the audio output is far better than the standard MIDI output of the lower-end notation software that I’ve used) and allows the user to supply other SoundFonts. Yes, you can compose music using a WYSIWYG editor, print the sheet music, and provide an audio demo (which can be burned to an audio CD using separate software) from within this free product.

This evening I came across something else that’s pretty neat: ScoreRender, a WordPress plugin for rendering sheet music fragments into images. Although some special set-up was required (installing a binary on my blog’s web server), the install still took less than 15 minutes. Now that the hard part is done, I can display music fragments within blog posts by typing or pasting special markup (I’ve chosen to only use LilyPond markup) into a blog post, enclosed in special WordPress tags. Nice!

What I find really cool is that MuseScore will save into LilyPond format. So, anything that I write in MuseScore can be displayed inside a blog post very easily. To try it out, I opened Net Hymnal‘s MIDI version of Silent Night in MuseScore, made some adjustments, and saved the result in LilyPond format. Then I opened the resulting file in a text editor and pasted it below. Very easy (at least for a geek like me)! Perhaps an entire carol is a bit much to display in a blog post, but I think it demonstrates the software nicely.

[lilypond]
AvoiceAA = \relative c'{
\clef treble
%staffkeysig
\key bes \major
%bartimesig:
\time 6/8
8. 16 8 4. | % 1
8. 16 8 4. | % 2
4 8 4. | % 3
4 8 4. | % 4
4 8 8. 16 8 | % 5
8. 16 8 4. | % 6
4 8 8. 16 8 | % 7
8. 16 8 4. | % 8
4 8 8. 16 8 | % 9
4~ ~ | % 10
8.~ 16 8 8. 16
8 | % 11
bes2 r4 \bar “|.”
}% end of last bar in partorvoice

AvoiceCA = \relative c{
\clef bass
%staffkeysig
\key bes \major
%bartimesig:
\time 6/8
4 8 4. | % 1
4 8 4. | % 2
4 8 f4. | % 3
4 8 4. | % 4
4 8 8. 16 8 | % 5
8. 16 8 4. | % 6
4 8 8. 16 8 | % 7
8. 16 8 4. | % 8
4 8 8. 16 f8 | % 9
4~ ~ | % 10
f8 8. 16 8 | % 11
2 r4 \bar “|.”
}% end of last bar in partorvoice

\score {
\relative << \context Staff = OApartAG << \context Voice = OApartAG \AvoiceAA >>
\context Staff = OApartCG << \context Voice = OApartCG \AvoiceCA >>
\set Score.skipBars = ##t
\set Score.melismaBusyProperties = #'()
\override Score.BarNumber #’break-visibility = #end-of-line-invisible %%every bar is numbered.!!!
%% remove previous line to get barnumbers only at beginning of system.
#(set-accidental-style ‘modern-cautionary)
\set Score.markFormatter = #format-mark-box-letters %%boxed rehearsal-marks
\override Score.TimeSignature #’style = #'() %%makes timesigs always numerical
%% remove previous line to get cut-time/alla breve or common time
>>
}
[/lilypond]

True, I could have saved the sheet music to an image file from within MuseScore and then uploaded it to display in my post, but by using ScoreRender I don’t end up with an entire page of sheet music (including margins) in my post, plus I can make slight adjustments to the sheet music from within WordPress by editing the LilyPond markup, rather than having to go back to MuseScore, make my changes, save as an image, re-upload, etc.

MuseScore is definitely something I’ll use on a regular basis and I imagine I’ll find uses for ScoreRender as well. Thanks, Ray, for the tip!

Let me know your thoughts on these applications and/or other open source music composition and notation software.