Mechanical Music Digest  Archives
You Are Not Logged In Login/Get New Account
Please Log In. Accounts are free!
Logged In users are granted additional features including a more current version of the Archives and a simplified process for submitting articles.
Home Archives Calendar Gallery Store Links Info
MMD > Archives > January 2005 > 2005.01.09 > 05Prev  Next


Program "Maddalena" for Music Roll Image Files
By Julie Porter

I have not updated it in nearly a year, but I started to write a
software package for editing music rolls, similar to what Tony Decap
described.  I called this program "Maddalena", which probably sums up
how it makes one feel.

The idea behind Maddalena is to show the piano roll as it scrolls
across the tracker bar.  That part of the program is done.  The
pre-alpha version of Maddalena for Macintosh is at
http://www.delectra.com/rolltransport/

I have managed to run this as a "Classic" application in OSX, however,
the Mac OS9 directory must contain either QuickTime 4 or the latest
QuickTime, as some versions of QuickTime 5 and early versions of
QuickTime 6 cause the playback to stutter.

Currently the program will convert *.CIS roll image files to MIDI
and the graphical format.  I was working on the section that allows
for insertion and deletion and dragging of events.  The program got
a bit complicated, then Apple dropped the support for the standard
file, which broke the way I was opening files.

In my case I have stencil rolls representing 35 different tracker
scales, so one section of the program is a tracker bar editor.
That means the target file must have this information linked to it.
Another section of the code handles the time base conversion, since
different roll scanners have different resolutions, ranging between
80 dpi to 1200 dpi, so an image of the roll or book music must have
this information either linked or stored in the image.

Converting the image to event data is simple and straightforward.
In image processing this is called "template matching".  The hole is
defined as a template, then the edges are detected.  Ideally one should
locate the center of the hole.  Richard Stibbons did the foundation
work in this area.  Others have implemented statistical analysis to
achieve the "Holy-Grail" of roll scanning which is to recover the punch
step rate.

Maddalena uses the Stibbons edge detection method to create an absolute
time & duration map of the MIDI (which makes it possible to edit
events).  Once the events are located they are marked via an overlay,
which can be clicked on.  Currently events can be deleted.

The final stage converts the events to the Standard MIDI format.
I also was able to convert the events into the internal Apple format,
which is similar to the DirectX that Tony Decap was referring to.
Both the Macintosh and Windows operating systems provide buffered
playback of MIDI, and both have what is called a "Callback" so the
programmer can re-draw the image or tick a clock as the song plays.
In the case of Maddalena, when I play the song I set the "callback"
to the same routine that scrolls the window.

It would not be too much trouble to allow inserting lyrics into the
Maddalena program, as a lyric event in MIDI is no different than a note
event.  Since Maddalena uses the scanned image of the roll (or book),
one could click on the bitmapped lyric and type in the actual text.
Automatic recovery of the lyric is possible, but requires implementing
some state-of-the-art image processing techniques.

 [ Does an OCR (Optical Character Recognition) program exist yet
 [ which reliably recovers the "stencil" typeface of piano rolls?
 [ -- Robbie

Mostly I put the unfinished Maddalena program onto the web as a proof
of concept.  Currently I have not the economic resources to continue
with the development, or to convert Maddalena to other operating systems.

Julie Porter

PS: For older Macintosh computers, the shareware program MIDIGraphy
allows viewing the music as a left-right scroll, similar to Cakewalk.
MIDIGraphy also has a piano key view, with a mixer console, where the
user can slide the controllers or watch things like the pedals move up
and down.  Best of all, when connected to a MIDI-in port, MIDIGraphy
will convert the Mac into a synthesizer using the Roland soundfonts.

MIDIGraphy is on most shareware archives, but is an application
for older 68000 Macs.  Google will find it.


(Message sent Sun 9 Jan 2005, 08:11:09 GMT, from time zone GMT-0800.)

Key Words in Subject:  Files, Image, Maddalena, Music, Program, Roll

Home    Archives    Calendar    Gallery    Store    Links    Info   


Enter text below to search the MMD Website with Google



CONTACT FORM: Click HERE to write to the editor, or to post a message about Mechanical Musical Instruments to the MMD

Unless otherwise noted, all opinions are those of the individual authors and may not represent those of the editors. Compilation copyright 1995-2024 by Jody Kravitz.

Please read our Republication Policy before copying information from or creating links to this web site.

Click HERE to contact the webmaster regarding problems with the website.

Please support publication of the MMD by donating online

Please Support Publication of the MMD with your Generous Donation

Pay via PayPal

No PayPal account required

                                     
Translate This Page