Skip to main content
Topic: Tool for layering?? (Read 11522 times) previous topic - next topic

Tool for layering??

   I have been transcribing about 6 songs a year for about 5 years for an annual choir (for rehearsal). I generally want it to look like the original music, which is often 2 staves, one with soprano and alto, one with tenor and bass. I use layering so I can make a version with one part on one channel, the other parts in the other. I would like to see a user tool to help with matching stem lengths between the layered staves. I've been doing it manually, which is a lot of work when the song has many eigth notes. Although I make my living programming, I am not familier with php. It seems that the "user tool" interface can only deal with one staff at a time. Is that correct? I also considered using the .nwctxt file, and running it through some kind of a program or macro to analyze it and create a new  modified file.
   It would have to compare corresponding notes in a pair of staves. If the stems were in the same direction (which may be set, or defaulted) it would make the adjust the stem length of one so the stem ends were in allignment. This is most important for eight notes or shorter, but would not hurt for other note values. It would also set the slur and tie directions for the upper note to upward, and the lower note to downward, unless the notes were tha same pitch. I'm sure there would be other things it could do, but that is what I would start with.
   Right now I need more help with the user interface: how do I get the needed elements to somewhere they can be parsed and edited. Do the "tool gurus" think this is even possible? If you think it's possible, I wouldn't mind someone pointing me to a template, or anything else which might help me get started.

Re: Tool for layering??

Reply #1
G'day fathafluff,
you are correct in your understanding that the user tool facility only works on one staff at a time, so export to .nwctxt will almost have to be the first step in any programmatic solution to your problem.

As for php et al, there is no absolute need to use php for writing tools.  RigkG regularly uses VBScript and has recently been playing with some java script ones.  In addition, the original tools, when the facility was first made available, were written in perl.  There have even been .exe and html tools!  So long as you can read STDIN and write STDOUT it doesn't matter what language you choose to use.  Even then, there have been some tools that required you to copy and paste the staff into the tool and paste the results back into your staff, functional but not as easy for the user as using STDIN and STDOUT.

STDIN is the source of the clip, STDOUT is the destination of the modified clip and STDERR is it's usual self :)

As an alternative approach, is there really any need to have all the stems in the same direction?  Given they are different voices wouldn't it be acceptable to have the Sopranos and Tenors stem up and the Altos and Basses stem down?  That way the Sopranos could be on their own staff, have ALL stems up and that staff layered on the the Alto staff which is all stem down.  No more problem...  Except of course if the original is written as single stem chords...

Another approach might be to use Andrew Purdams "Scratch" tool.  This tool isn't actually finished but it is largely functional and can be used to merge staves.  This way you could write your sounding staves independantly the way you are now, but then create staves that will be visible, copy one staff to it and "Scratch" merge the other staff so that you have proper chords on it.  Make the source staves invisible and mute the visible staff.  If you want to investigate scratch it is available on the Scripto (http://nwc-scriptorium.org)
I plays 'Bones, crumpets, coronets, floosgals, youfonymums 'n tubies.

 

Re: Tool for layering??

Reply #2
I am not familier[sic] with php.
You can use anything that can read STDIN and write to STDOUT.
Even batch (*.bat *.cmd) files can do that.

It is also useful to be able to write to STDERR and exit with an errorcode.
See: http://www.noteworthysoftware.com/nwc2/help/MNU_USERTOOLS.htm

If you install the starter kit from the NoteWorthy Composer 2 User Tools page, you can use PHP.

Nearly every Windows box will have WScript.exe and CScript.exe installed on it.
These support VBScript and JScript natively. I have posted tools on this board for both.
According to the docs (script56.chm) they also support PERLScript, PScript, and Python via Windows Script Components. I have not tested this.

It seems that the "user tool" interface can only deal with one staff at a time. Is that correct?
Alas, you are correct.

I need more help with the user interface: how do I get the needed elements to somewhere they can be parsed and edited.
For a User Tool, you read a Staff of them from STDIN. For a User Tool or a standalone program, you can read them from a(n) NWC Text File. You can also read a Staff's worth from the Clipboard.

Do the "tool gurus" think this is even possible? If you think it's possible, I wouldn't mind someone pointing me to a template, or anything else which might help me get started.
I do, and hopefully I just have.
Registered user since 1996