Skip to main content

Messages

This section allows you to view all Messages made by this member. Note that you can only see Messages made in areas you currently have access to.

Messages - hmmueller

452
General Discussion / Re: String section misses their cue at the end of piano roll
Yes - soundcard. The many piano notes that do not stop immediately use up too many of the "polyphonic voices" of the synthesizer.

This is what it sounds like when I run it from NWC through Reaper with (free) Sonatina Symphonic Orchestra soundfonts* - that's why I stopped using that Microsoft thingy altogether a few years ago.

* with a small change: I removed the staccato ticks on the strings' chord - it was too short with them.

H.M.

// Edit:
I think that in measure 8, there's a small error in the cellos and bass: The eighth pause and f seem reversed ...
453
General Discussion / Re: My (new, and long) NWC wishlist
Over the last weeks, I have tried to write a set of plugins and user tools that provides some of the features I wish NWC had "out of the box". This posting is an update that links my additions with the wish list I posted here some time ago.

Score creation

Not possible with plugins / tools (except for very specific purposes - see e.g. my "Copy corresponding parts" tool, but also others - I'd be happy to include links to other solutions here!.

C-2. Moving sets of layered staffs up and down together.
Probably possible as user tool - not yet attempted.

In a way supported with user tools Extend staff below with rests to cursorand Remove following rests of same length.

C-4. Extend all staffs (or all visible staffs) with invisible whole rests to the cursor position on some other staff.
See C-3. above.

C-5. Staff splitting and combining
Using the C-3. tools and the adp_parts tool, I would no longer think that this is urgently needed.

Probably possible as user tool - not yet attempted.

C-7. Factory templates with useful Staffsig plugins:
Not a tool functionality.

I have not looked at it (although I needed to check a MIDI file I got - almost impossible with NWC ...).

After reading a few articles - especially OMR Evaluation and Prospects for Improved OMR via Multiple Recognizers by Donald Byrd et.al. -, I won't look at this anymore.

Graphic elements

My attempts discussed in Do we need a "CueStaff" plugin? make me believe that it can be done "somewhat acceptably", but the effort is right now too high for me. If someone (me or other) craves for it one day, I'll complete on or the other version.

G-2. Beams between staffs for keyed instruments are not too rarely used. Not having them is, unfortunately, a "missing feature".
A somewhat complex, but - I think - usable user plugin is shown under Beam.hmm.

A somewhat complex, but - I think - usable user plugin is shown under Breve.hmm.

G-4. Placing arbitrary images into a score.
This would have to be implemented natively by NWC.

G-5. Correct sizing of accidentals and performance marks for cue notes (this probably would mean to have cue heads as a built-in feature).
The experiments with cuestaff (G-1) show some possibilities - but if it is possible at all, it would be much work and certainly cover not all possibilities. A built-in solution is to be much preferred.

Scanning through "Behind Bars" will probably unearth a few more features that are expected of a modern score editor (like the small rectangle notation of multi-rests...
The XText.hmm user plugin makes this possible, albeit it is not really nice to use, as one must, for some symbols, enter the hexadecimal number of the symbol to be shown.

... or numbered simile marks as used in brass band voices).
The RepeatMark.test user plugin, with code from Mike and me, supports this.

Playing

P-1. An option to indicate that accidentals are not significant on other octaves ...

P-2. ... and an option to treat double bars like single bars for flow control.
Both these need to be NWC built-ins.

P-3. A builtin option when grace notes start to sound (before the beat or on the beat).
The Acciaccatura.ms object (which adds a slash to an eigth grace note) has support for this.

P-4. Explicit control about how the playing duration of notes is computed.
I am thinking a little bit about this, but it will take some time.

P-5. An "artificial player" ...
... and yes, I continue to dream ...

H.M.

454
User Tools / "Remove following rests of same length" user tool (0.1)
This is a companion user tool to the "Extend staff below with rests to cursor" user tool: If one adds new notation into the rest sequence, all elements behind are shoved back (as NWC does not have an overwrite mode). This tool allows the quick deletion of following rests of the same length as a selection.

Here is a short description:

This simple tool removes all rests and the "duration-less" objects between them after the selection for a duration that is equal to the selection's length.
This is helpful if you have added a stretch of notation in a run of rests, but actually did not want to move back everything behind your insertion; think of it as a remedy for NWC's missing "overwrite mode".
If the tool encounters an object with duration during its removal that is not a rest, it stops - it does not want to destroy parts of the score.
Finally, if the removed rests do not sum up to the exact length of the selection, the tool inserts a few small rests for compensation.

To install, download the attached lua file (wherever you want to store user tools), open some NWC score (e.g. a new one), go to "Tools --> User Tools", click "New" and add the following:
  • Group: Whatever you want to keep your user tools organized
  • Name: "Remove following rests of selection length"
  • Command: Browse to location where you saved the downloaded file
  • Input Type: File Text
  • Options: Returns File Text

I have also attached a weird test file to play around with this tool. For a first experiment, select the red notes (which are assumed to be a previous addition) and run the user tool - the following part of the staff should "move up" so that the bars, endings etc. again align nicely. Note that a new sixteenth rest had to be added after the red notes for this alignment.

H.M.
455
User Tools / "Extend staff below with rests to cursor" user tool (0.3)
I have written a small user tool that extends a staff with invisible rests - this is e.g. useful if a staff needs a layered staff late in the score.

Here is a short description:
This simple tool fills the staff below the active staff with invisible rests up to the cursor position.
The following items are copied down from the active staff while filling: All sorts of bars, flow controls, endings, time signatures, and keys. These copied objects keep the visibility from the active staff.
This is e.g helpful when a staff split for layering is necessary later in the score.
Right now, the tool never creates dotted rests.
If the staff below the active staff extends past the cursor position, or there is no staff below the active staff, the score is not altered.

To install, download the attached lua file (wherever you want to store user tools), open some NWC score (e.g. a new one), go to "Tools --> User Tools", click "New" and add the following:
  • Group: Whatever you want to keep your user tools organized
  • Name: "Extend staff below with rests to cursor"
  • Command: Browse to location where you saved the downloaded file
  • Input Type: File Text
  • Options: Returns File Text

I have also attached a weird test file to play around with this tool.

A companion tool "Remove following rests of same length" can help you if you want to insert new notation in the rest stretches, but want to re-align parts after the inserted pieces (NWC has no "overwrite mode", so inserting notation without disturbing the position of staff parts to the right is not possible "out of the box").

(I have not researched whether there are already other tools that can be used for this purpose ... I wanted a very simple tool, both from the viewpoint of usage - no options - and code - as short as possible, and I need to learn to write user tools in Lua anyway, so I took this as a first example).

H.M.
456
User Tools / Bug or wrong documentation at nwcItem:HasDuration()
The documentation says:

Quote
Hint: grace notes do not have duration.

But the following tool,
Code: [Select · Download]
local f = nwcut.loadFile()
for i = 1, #f.Staff do
  for j = 1, #f.Staff[i].Items do
    local item = f.Staff[i].Items[j]
    nwcut.warn(i ..'/'..j ..' --> '..(item:HasDuration() and 'true' or 'false')..'\n')
  end
end
nwcut.status = nwcut.const.rc_Report
when called on a new staff with two grace notes, outputs
Code: [Select · Download]
1/1 --> true
1/2 --> true

I'll use
Code: [Select · Download]
item:HasDuration() and not item.Opts.Dur.Grace
instead - I think this is what the documentation means ...

H.M.
457
General Discussion / Re: Do we need a "CueStaff" plugin?
I had another idea, that is much more feasible - I'll describe it in the next days -- right now I'm too exhausted from a day of trying to make it work, and ... well ... I got pulled two teeth two days ago, and it hurts.
Anyway, in the attachment is
  • an example printout, which shows that some things look as they should (this is from a C.Ph.E.Bach organ sonata),
  • the score,
  • and the current code.
The latter two are not for the faint of heart, I fear ... especially, of course, as long as I don't explain concepts and details ...

I think this is the nearest one can get with current NWC features to a cue staff; one learns that a potential user would need a detailed "how-to" guide to produce such cue staff bars, because it's honestly trickery; even rests are non-obvious.

Also, there are hard limitations: No chords with two stems, no restchords, and I think I will fail at the linebreaks, and maybe even at cue staffs that include staff signatures (clefs and keys) on the left side. I'll probably force this idea through until I run out of ideas ... but it's more of a programmer's riddle than, probably, a feature that could be sold to anyone.

H.M.
458
Object Plugins / EditMark.hmm (0.2)
I'm afraid of ... no, not Virginia Woolf, but invisible NWC objects - really invisible objects that I would not see in the editor. There are at least two of them: Transparent bars; and whole notes with a blank head. So, I wanted a marker that shows where they are, and maybe also shows some text why I put in these invisibles. But of course, I do not want all this to show up in the printed staff. Thus, I wrote this ...

The EditMark.hmm can be used to add text and dashed marks that only show up in edit mode. This may be especially useful for invisible objects (like transparent bars), almost invisible objects (very small symbols), or just as remarks needed only during editing. The dashed marks are located at the next (presumably invisible) item. Of course, the plugin itself will never be invisible - if the text is empty, a standard symbol (derived from the following item) is shown.

The attached example file shows different uses of the plugin. You might want to check out its interesting print preview.

H.M.
459
Object Plugins / Re: RepeatMark.test (0.4)
Version 0.5 has a third style "Double with 2", according to David's and my observations that this is a typical notation.
In the user tool, this style is automatically used if (a) action "Double" is selected and (b) Label is set to 0.

(In principle, one could have the 2 and, additionally, a counting label ... this would definitely be strange, but it can be selected - the label will have to move mightly upwards ... ).

If I understand it correctly, all the tool does is insert a nicely placed single or double measure repeat sign, with or without a label.  It doesn't reset the visibility of the pasted bars, nor does the label increment if the user wants to use labels.  The tool is useful,for sure, but am I missing something?

It does all of that - see the three animated GIFs: notes become invisible, and the labels over the bars are (e.g.) 2, 3, 4 after a single <enter> hit. Or don't I understand your remark?
// Edit: What it does not do is that it takes over a previous label + 1 if one starts it anew. But I do not see that as an important usecase - usually, you would always select all bars together and add the signs in a single user tool execution; if you want to "continue counting", you can just type in the next number label (as in the line break example, i.e., the first animated GIF).

A comping slash (  / ) choice with this tool would be a nice enhancement ...
Yes - this is the logical next step. However, the logic is quite distinct, as this is not a "per bar(s)" thing, but "per beat" or something like that. Also, I have never seen numbers with this. Me thinks that this would be another plugin ...

(your RepeatMarkExample3FromBehindBars.nwctxt illustrates the tremolo rather than repeat marks.)
I (and B.B.) also subsume any repeat counters above any repeated thing, even without the marks, under this, mostly because placement of such a label is "already there". However, I see that the name RepeatMark is really misleading here - "RepeatIndicator"? seems too convoluted ... "SimileHint"? ... any other ideas?

H.M.

460
General Discussion / Re: Do we need a "CueStaff" plugin?
If it's not the idea I just had, I'll let you know, and you can tell me which of the two ideas might work best.
I have attached my current (very incomplete) code and the sample file.
The idea is:
  • There are two NWC staffs and, additionally, the "mirror drawing" above the second staff
  • Staff 1 is the lower one you see - no problem here
  • Staff 2 contains the notes to be mirrored.
    -- In the print version, it gets staff color white (you have to set "Highlight 4" to white  - I never needed it), and it gets layered over Staff 1; only the user objects get color black (you have to set "Highlight 5" to black). One could also set some things that can be scaled and moved up manually (e.g. texts, probably many user objects) to black and not mirror them.
    -- While editing, it is not layered and gets some visible color.

The main "distributor" in the code is the "mirror" table; and right now I have only implemented calls for Chord and Note in there and a dummy (single line) for Bar.

The main work to be done is note and bar drawing - correct positioning (right now, not even the bars line up exactly, because I do not compute the center); for notes, all the articulation, then beams and tails, triplets and slurs; but also drawing the staff keys (where the placement depends on the current clef ... ... ... ) ... And I do have problems at line breaks - can be seen in the example. Interestingly, lyrics should work out of the box, because it can be offset far enough ...

An important problem with this approach would be that all the user plugins that cannot themselves scale and shift cannot be used; in these times of patching up NWC with more and more plugins, that will decrease the value of such an object more and more (cloudy thought: "Recursive execution" of user plugins is missing from NWC - i.e., if a user plugin stumbles over another one by way of :find, the first one whould have the ability to call its _draw - and _play??? - methods, but additionally do something to the output - x/y-scale and shift it for draw, modify the resulting queue objects for play ... now that would be some sort of meta-machinery ...)

Last, the plugin has a very weird problem: It does not work if I open the example too quickly - then, draw the notes are not drawn (but the cue staff lines are visible). I have no idea why this happens - is there a (very small?) time limit such that draw simply gets killed? But would that really happen with only the few items in the test file ... ...? If this cannot be solved, the whole idea is useless anyway ...

H.M.
461
General Discussion / Do we need a "CueStaff" plugin?
Some of us have wished that NWC would have an option to have (vertically) smaller staffs - I call them cue staffs, but they are used for multiple purposes (alternative notes for other instruments, or in different manuscripts; solo voices in piano scores; and some more).

I have played with the idea of writing a plugin that can, in some quite limited way, produce such staffs - see the (very incomplete) example in the attachment (produced by actual code - I can scale it, and the noteheads and accidentals already are plaed at about the right spots).

I would still heartily wish that NWC would have this as a built-in feature - but in the meantime (however long it will be), would such a plugin be useful? I ask because writing it would be lots of work - essentially, one has to mimic all the possible printing features of NWC - from chords and notes with their various durations (beamed and with tails) to accidentals, articulations, triplets, slurs, all the different bars, ... etc.

Would this be worthwhile??

H.M.
462
Object Plugins / Re: RepeatMark.test (0.4)
In a thread in a German forum, there was a longer discussion about these symbols (they are called "Faulenzer" in German, meaning about "lazy guys"). Even if you cannot read German, the photos from various newer and older music dictionaries are interesting ... (and no, I do not plan to support all these various symbols).

Also, Unicode contains these symbols at codepoints 1D10D...1D10F.

H.M.
463
General Discussion / Re: Learning to crescendo and decrescendo
My  midi files are not usually very good because I can’t seem to control the subtle nuances  ...
@SEBC : Out of interest - what is your "sound creation tool chain": Which "synthesizer" (soundfonts, virtual instruments, ...) do you use, and do you use any "container" (like a VSTi container, or Kontakt)? I'm interested because my long (or medium?) term goal is to create nuanced (MP3) results from NWC scores - that's why I developed the Envelope user objects, for example; and I hope that I can create some additional plugins for better sound rendering.

H.M.
466
Object Plugins / RepeatMark.test (0.5)
I have taken over Mike's code from that thread (RepeatMark.ms).

The main selection is the "Repeat Type", which can be
  • Single - for a one-bar "simile sign" (centered in the bar) and/or a counting label
  • Double - for a two-bar "simile sign" right over the bar line and/or also a counting label
  • Double with 2 - for a two-bar "simile sign" with a 2 above it (a counting label is possible, but confusing in this case)

The label can have one of two formats - either selected manually or automatically:
  • "Plain" shows the repetition label unadorned;
  • "Parentheses" shows it between (..);
  • "Default" is "Plain" for the two "Double" types and "Parentheses" for type "Single".

The label controls whether it and the sign are visible:
  • 0 - no label, sign is visible
  • > 0 - both label and sign are visible
  • < 0 - label shown (without the minus), but sign is invisible

Additionally, there are some more format options for the label.

For reference, those who have access to E.Gould's "Behind Bars" can look up the rules on pp. 233 and 578.

For convenience, there is a user tool with two "actions" Double and Single to quickly create repeat marks for multiple bars. The three following animated GIFs show three examples of working with the user tool; on the right side, you can see the keys I pressed (I do not use the mouse with NWC).


The GIFs might be a little confusing first, but if you watch them for a few rounds (they loop endlessly) and look at the pressed keys and maybe try them out in NWC, you'll find out how that works - and how quick it works.

There are three very useful initial label values for the user tool (which are all shown in the demos above):
  • 2 - this is useful when one wants customary marks that start with label 2; the selection is from the first repetition onwards.
  • -1 - this is useful when creating "B.B." style marks, i.e., where the initial segment gets label 1; the selection must include that initial segment.
  • 0 - if one does not want any labels (e.g. if the repeat count is only 2 or 3); the selection is from the first repetition onwards.
Other values might also be useful (see e.g. value -5 in one of the examples). There is no user-tool support for non-contiguous labels (e.g., only every second or fourth label); if you need that, just set the labels of some objects to zero afterwards.

Many thanks, of course, go to Mike for his previous version of this tool!; and to David for a long and ongoing list of comments - I believe that the current tool can do everything he wants, and rather quickly - but also everything to fulfil the "B.B." requirements.

H.M.
468
Object Plugins / Re: RepeatMark.ms (0.3)
A color-coded answer - I hope the items and responses are somewhat clear and legible ...
... and my answers (some explain how my current development code works, not the one attached above - I'll upload that version in the evening, i.e. about 5 hours from now ...).

  • ...The main necessary feature is that the number 1 must appear above the notes defining the repeated segment.
    Why?  The tool doesn't seem to increment the number in the repeat bars and I don't think I've ever seen the number 1 appearing above the repeated bar in professionally engraved charts..
    Same for me, but the "bible" B.B. says differently; of course, I want only the option to do it according to Elaine Gould.
  • Of course, one could create this label manually. However, to me this simply seems cumbersome - why not use the same object, but without a symbol? This seems quite logical to me.
    I'm not sure what you mean.
    If one wants that 1 above the first execution, one could put a standard text there (instead of the object providing that option); however, then centering would e.g. be not easy.
  • The same effect (label, but no symbol because notes are visible) is necessary after a line break, according to one example in B.B.
    Yet in "Repeated bars and line break" you put the number in the visible bar that begins the second system.
    The label is the number (this is the "definition" in Mikes code). So yes, I put the label above the visible bar, as I say. I do not understand your "Yet" ... maybe you thought "label" was something else (see your question somewhere down below).
  • First, I did not want to pop up two dialogs, therefore I put the flag that says whether the symbol should appear into the sign of the label; but maybe the alternative design, with a separate checkbox dialog with default "show symbol" does not need more key hits ... I have not counted them. 
    Agreed.  The fewer the clicks the better.  Getting to the label box in the dialogue window is a little awkward.
    As there is only one box, one ends up exactly there without any ado - that should be acceptable.
  • Second, for single staff printing, the user tool should add useful spacers.
    As it currently works, you need spacers before and after the symbol to make it sit inside the bar instead of over the next bar line.  You want the double bar repeat to sit on the bar line, so it's only the single repeat that needs to be tweaked.
    No, also with double bar repeats spacers are necessary. The spacers are not for sitting inside the bar in the "Single" type - this is nicely done by a computation in Mike's code. The spacers are only necessary for single staff prints, in order to avoid that the bars collapse to length zero.[/green]
  • How about changing the symbol from % to .....%..... (where ..... is a space set with the space bar), and using the Preserve Width setting?  The dialogue box could ask the user how many spaces to use..
    The "symbol" is drawn from separate lines, so it is not a text. The space rows, therefore would have to be two separate texts anyway - but then, spacers fulfill the same purpose and - I think - better, as series of spaces do not take part in the distance computations of NWC. Also, I think the space idea only works if one does not want the B.B. feature of having numbers over visible bars; but as I want to advertise NWC (at some point) as "doing all of B.B.", I would not like to do this.
  • Last, the tool should make all the notes and dynamics (and what else??) invisible when applied.
    In percussion parts, jazz bass and jazz solo charts, the single bar repeat is dictating the rhythm or the chords  but not necessarily dynamics, text, dynamic variations, or tempo variations.  For instance, I occasionally see hairpins in the last few bars of single bar repeats.  In such cases, the repeat sign is not "correctly" a repeat, since you want the player to do what the rest of the group is doing.  I think it would be enough to simply change the notes within each bar to invisible, rather than make everything else invisible too.
    The user tool will (should) do what's standard; afterwards, one can manually change any visibility of any item at will. Te standard, according to B.B., is "notes and rests; and dynamics" - that's why I chose them. From your comment, I think that this is exactly what should be done. Unfortunately, there will probably be problems with hairpins anyway, as they will vanish, when the notes become invisible. In such cases, layered staffs might be the only solution ... but this certainly will not be part of that "simple convenience tool".
  • RepeatMark.ms places brackets around the label:  (4), (6) etc.  That is preferable to the label currently generated by RepeatMark_ms.hmm.  Why?  I recently sight read a chart with many successive two-bar repeat signs, each of which had the required 2 over the symbol.  The chart also had small printed bar numbers above each bar line as well as labels showing the repeat iteration number.  Brackets around the label make it easier to differentiate from the other numbers.
    My modification has exactly the same behavior by default (single -> brackets, double -> no brackets) ... might be buggy right now; however, one can also choose the format explicitly, because neither B.B. nor the scores I have follow this convention.
  • Each repeat sign seems to need to be entered manually, with labels (if needed) set individually. The numbers in the label don't seem to increment automatically (maybe I missed it).  Automatic would be better, since suppressing the label with 0 or setting the label requires some awkward mouse movement in the popup window.
    When one selects more than one bar in the user tool, the bars get incremented numbers.
  • I wonder if the logic could work like the multibar rest sign?  Insert the tool in the bar after the one that is to be repeated, set the number of times it is to copy that bar, make the notes invisible and insert the sign, and give the user control over which repeat iterations get labelled.
    I thought about that also; right now, the "mark it and then run it" seems nicer - why should I count the bars? Your suggestion is, if I understand it correctly, also to copy the notes - but this is, from my experience, not the use case: You will have the copied notes already there (because you listened to them while arranging), and inserting repeat marks is just a final decision about appearance (which might be reversed for numerous reasons, e.g. that line or page breaks have to occur in the middle of the repeat sequence and the like).
  • Each simile bar may be labelled with a number if the user wishes, but it's more common to only see the label every 4 or 6 bars. Your tool allows the label to be suppressed, but the best way to invoke that is simply set it up in the first repeat bar and copy that entire bar as many times as desired, changing the ones you want to label.
    Except for that one example in B.B. with the tremolos, I have never seen non-contiguous labels, I must say. But still - setting the labels in between to zero (i.e., suppress the label) is easy - just select the whole range over all user tools and set the label
    to zero for all of them with a single operation.
  Overall, a very useful tool, please carry on developing. 
I'll try :)

Thank you for your extensive comments!!

H.M.



469
Object Plugins / Re: RepeatMark.ms (0.3)
... I would be happy to relegate the RepeatMark code over to you, where you can evolve it as needed, ...
Thanks,
Mike
Thanks back to you! - for the plugins + expertise I (& we) got from you - so yes, I'll take the code and try to build from there on. I'll open a new thread when I have the first result.

Re the name: I also thought to call it SimileMarks, but (a) B.B. does not call it that; it actually circumvents giving these symbols a name - I don't know why, but maybe: (b) "simile" is a too general name, because it is used for many other "repeated things" (like "continue with staccato" etc.). I stink I'll actually stick with your name - it's known, it's not wrong, also not w.r.t B.B. ...

H.M.
472
Object Plugins / Re: RepeatMark.ms (0.3)
Hi Mike -

I have a number for suggestions for this object. They all follow essentially from attempts to write the examples in "Behind Bars" with it. Instead of writing too much text here, I have implemented some modifications and, using them, written the B.B. examples - all of this is attached. The main necessary feature is that the number 1 must appear above the notes defining the repeated segment.
Of course, one could create this label manually. However, to me this simply seems cumbersome - why not use the same object, but without a symbol? This seems quite logical to me.
The same effect (label, but no symbol because notes are visible) is necessary after a line break, according to one example in B.B.

I also have a vision how to use this object, which has triggered my to write a sketch of a user tool - which has actually helped me to write the B.B. examples quite quickly (at least the type "single" ones). Three aspects have driven its design:
  • First, I did not want to pop up two dialogs, therefore I put the flag that says whether the symbol should appear into the sign of the label; but maybe the alternative design, with a separate checkbox dialog with default "show symbol" does not need more key hits ... I have not counted them.
  • Second, for single staff printing, the user tool should add useful spacers.
  • Last, the tool should make all the notes and dynamics (and what else??) invisible when applied.

What do you think about my usage ideas and my implementation sketch? (the Lua file has, for the moment, _ms.hmm as its "author", just to indicate that the code is not all your fault, but also not all my creation)

H.M.
473
Object Plugins / Re: XText.hmm (0.9)
Version 0.9 allows the specification of arbitrary Windows fonts in an segment. I think this should be very useful for the small arrows sometimes needed when voices are split or come together ("Behind Bars" shows an example on p.468; I see them often in John Rutter scores).

H.M.
474
Object Plugins / Re: Envelope.hmm (0.9) - supporting MIDI envelopes in NWC
0.9 is a pure maintenance release: I have understood how to remove quite a bit of duplicated Lua code; and I moved the "problems" section here so that it does not pollute the main posting.

H.M.

Current problems

(1) [see code/please help] copy-pasted code for some methods because they work on different objects. Repaired inside Envelope.hmm; but duplication over EnvelopeMaestro.hmm and Envelope.hmm cannot be avoided, it seems.

(2) [see code/I'll investigate - by reading & understanding this] :find('prior',...) does not search to start of score. - solved

(3) [see code/please help] Defaults for properties have to be repeated when accessing them via :objProp(). - solved thanks to Mike.

(4) [see code/please help] It's necessary to add "+ 0" to objProp results, even though they are escaped with an "or constant". - solved thanks to Mike.

(5) [see code/please help] I would like to set the color of all envelope objects for one controller to the corresponding maestro's object color - is this possible? - not possible, says Mike - I will have to write a (probably embedded) user tool for this.

(6) [see code/please comment] The supported values for controllers are 0...127. The same range is also used for the pitch bend "pseudo controller", even though there, MIDI nominally supports fine-grained values from 0 to 16383, with "no bend" being 8192. In the Envelope object, "no bend" is indicated by 64, which might be confusing for users. However, I wouldn't like to change the 0...127 standard only for the pitch bend pseudo controller. "as designed

(7) [see code/please comment] 128 is used to select the "pitch bend pseudo controller". Controllers are selected from a drop-down list so that the "pitch bend controller" can be easily found.

(8) [see code/please comment] It would be nice to present the controllers also by name (where a standard name exists). On the other hand, controllers for advanced virtual instruments are often in the "general purpose" or even "undefined" segments, so this is maybe not that helpful anyway (envelopes can get a "Show as" string for presentation). Done in 0.6

(9) [see code/please help, or comment] The sloped lines do not really end where one would expect it. For example, a slope of span 1 over a whole rest ends whortly after the rest symbol, not at the place where the rest "logically ends". Should I extend the slope to the start of the next object? Fixed (I think) in 0.5

(10) [see code/please help] Is it helpful if the maestro object is of type "StaffSig"? What for?

(11) [see code/please comment, or help?] Printing of envelopes does not work - they get cut at line breaks. However, one must say that envelopes are not there for printing, but only for playing - so this is a "luxury problem". On the other hand, NWC objects typically do print themselves gracefully ...

(12) [please comment, or help?] Start and reset: When one starts playing a score in the middle, previous changes are not applied to the output, and I do not see how this is possible as there is, in general, no object at the start point that could do this. Moreover, such a start will use the values from the previous play, which might be unhelpful - e.g., if the previous play ended with a zero volume. I would assume that MPCs also have this problem ... but I have not yet looked into this. This is not a problem: I have now added volumes to a complete choral score with more than 100 measures, and I could start at any place and always got useful volumes. I'm not sure why it works so well, but it does!

(13) [please comment] Should the font of the "Show as" text be selectable (this might be helpful if there is more than one envelope on a staff).Fonts are not selectable, but in 0.6 I added a scale if someone is in great need.

475
Object Plugins / Re: XText.hmm (0.8)
Version 0.8 allows the specification of arbitrary characters with decimal code (%...%) or hexadecimal code (%0x...%).

H.M.
476
Object Plugins / Re: Breve.hmm (0.5)
With your help, I have now finished the Breve object - therefore, it has now proceeded from status .test to .hmm. The changes in the 0.5 version are

  • the separation of the notehead from the drawing method;
  • for "double bar" noteheads, installed *Dings fonts and the standard NWC font are used (explicitly by the user and implicitly, based on availability); for "square" noteheads, installed *Dings fonts are used; "single bar" noteheads are always drawn as a semibreve head with two lines, as this symbol is not available in any font - as a consequence, there is now a huge if-then-else machinery for glyph selection;
  • a number of symbol positionings are now better than before;
  • correct support if another NWC note font is selected (an example with NWC2SwingDings notes shows this);
  • and there is an example file AllBreveHeads.nwctxt showing all possible heads (but not over all fonts);

Mike, you could - if you wanted - now tweak CueHeads a little to make it aware of this object ...

H.M.
477
Object Plugins / Re: Breve.test (0.4)
Thanks for the tight quality assurance loop ;)

  • Size problem should be fixed with 0.4.
  • Germanic and Euro fonts removed from examples, but ...
  • ... I left the dependency on Mensurstrich.hmm in the Play example - after all, the time of breves was also the time of no bars in music, i.e., where we now insert those small Mensurstriche.

All the x/y coordinates are still "arrived at by optical heuristics" - i.e., looking whether the heads end up about where I expect them. I am not sure whether there is some more analytic method ...

H.M.
479
General Discussion / Re: Objects online synch
I'm innocent, I'm innocent, I swear! (I am the only one who has fired out objects in the last weeks, as far as I can see ...)

But right now, all seems to work here - I could update (my own) four last changes ...

H.M.
480
Object Plugins / Re: Breve.test (0.1)
In my experience, while NWC does remove all space for a note on the current staff when you mark it as not visible. However, when there are multiple staves, it does seem to keep them lined up with the same note position on the other staves.
Mhm - I wrote a minimal user tool + example (see attachments) to check what happens - the result is quite chaotic even with two staffs, I think.
// Edit: ... but for whole notes only, the alignment should work - with the exception of a dotted whole note on another staff, I assume. However, I would also like my breves to be aligned usefully for a single staff ...

But back to the breves: I honestly tried using the letters in various fonts for the "square" notehead - but nwcdraw.text does not output characters with code > 127  >:( ... does anyone know why this might be the case? (the breve heads are at 177 in Lawrie's suites). I have uploaded a version 0.2 which would support these chars, but - well - it does not work :(

And I have another question: Can a plugin somehow detect whether a font is actually installed? .setFont does not return any "success" value, and even querying .getTypeFace() afterwards just returns the set typeface, even if it is 'asdfghj' or some other nonsense. This seems to be the way the Windows font system works ... but I would like to give the user some - any - feedback if the square breve head cannot be drawn (my ugly kicked-over I's, on the other hand, always work ... as long as a "Times New Roman" font is present ...).


Re the ready-made glyphs (whole notehead and 2 or 4 vertical bars): I do, right now, not bother that much with them - drawing the bars is really no problem; and I started the whole object actually only because of the square head (I only found out later about the other ones - we do not use them here). But of course, I might use them if my primary problems are solved ...

H.M.
481
Object Plugins / Re: Breve.test (0.1)
.. doing a short break, so I'm online :)

(a) CueHeads detecting Breve should be possible - I already thought of this, but the creators of both would have to disucuss this :)

(b) Implementing width and marking the chords as hidden: I actually started with this, but it did not work out at all (maybe I did not try all possibilities). The main problem is that hidden notes are not aligned by NWC with other notes, and therefore it is alsmost impossible to place the breves lined up with notes on other staffs; it gets worse with (*) accidentals, (*) the "increase spacing" option in the page setup, (*) lyrics (breves are mostly useful for vocal music) etc. That's why I ended up with the blank noteheads ...

(In the course of this and - upcoming - considerations about RepeatMarks, I would wish that (x) NWC had more than one - distinguishable - "quite" blank heads; and (y) a way to insert additional, note-aligned spacers when drawing (my idea would be that width(t) could return some more sophisticated result ... but that's long-term ...)

H.M.
482
Object Plugins / Re: Breve.test (0.1)
That's why I like this ".test" idea - try something out, get told that there are better ways - improve, rinse & repeat until it's finally something which might be usable :)

Thanks to both of you - we'll drive home now (5 hours drive) ... then I'll use this glyphs.

H.M.
483
Object Plugins / Breve.hmm (0.6)
Here is a user object that helps with breve notes (double length of whole notes). The plugin should suffice to write the final chords of hymnbook melodies and chants, and maybe some more uses - the examples have some of them. However, it has its limitations, especially if one wants to use ties (not typical with breves), dots (not at all typical with breves), or when playing them.
(The BrevePlayExample needs the Mensurstrich.hmm object - breves go with old music, so this makes sense, I think).

To create a breve, first create two whole notes (semibreves), then place this object to the left of the first semibreve, and finally change the noteheads of both semibreves to blank heads (by selecting both and then e.g. pressing Q B on the keyboard). In the editor, two small vertical lines indicate the position of the now indiscernable two notes - which are, however, technically not "hidden": The reason for this is that NWC will do layouting with the two semibreves, and the breve notehead can be placed accordingly.

The second semibreve can also be a whole rest, or actually any item. The second item is only used by NWC to reserve space for the complete breve. Using a hidden rest as the second item is useful if the breve is tied to another note - however, the ties are not really placed nicely.

The drawing of the noteheads is controlled by available fonts and user selected options: If fonts from Lawrie Pardy's *Dings suites are installed, one can use square and "double bar" noteheads from them. By default, the plugin looks for the fonts MusikDingsSerif and then MusikDingsSans; if neither is found,

  • the double bar notehead is taken from the standard NWC font;
  • the single bar notehead is drawn as a semibreve (whole) notehead with a line on each side;
  • the square notehead is created by two Times New Roman letters 'I' that are rotated by 90 degrees (which makes the notehead a little too short).

It is also possible to have chords of breves, and even chords with two durations do somehow work.

Last, there is also some support for playing. By default, the object is muted, but it can be unmuted. In that case, the two blank semibreves should be muted. Playing does not work with chords with two duration and restchords. Performance marks like staccato etc. are not considered when playing.

This user object does not (yet?) work nicely with the Cueheads.ms object, because that object also uses blank note heads.

H.M.
485
Object Plugins / Re: Beam.hmm (0.4)
Thanks (I had a wrong option in my string search ...) - I have now replaced the file with one that has all User Fonts set to Times New Roman.

H.M.
486
Object Plugins / Re: Beam.hmm (0.4)
I have now looked into the plugin and into the examples - none of them contains any string that contains the letters "German" anywhere. So how can it be David stumbles over that font??? :o - any help is appreciated!

H.M.
489
Object Plugins / Re: Beam.hmm (0.4)
1.  I don't have MusikChordSansGermanic and it isn't listed in the Fonts section of the Scriptorium.  Where can I download it? Does it need to be set up as Userfont1, or something else in Page Setup Fonts?
Dont set it up - I'll repair the examples so that they dont need it ... just my error. But this is no problem for your scores.

3.  Alert = "Detected 4 unknown user objects in Stemlets.nwctxt"
If you go to Tools-->Options-->Folders, what is the folder near "Object Plugins"? Is this exactly the folder where you installed (copied) the Beam.hmm.nwcuser.lua file to?
  • If not, then this is the problem: The file is not where NWC looks for user plugins. Place the file in that folder, and then hopefully all works fine.
  • If it is, please check whether you installed it under some non-admin rights, so that it is not visible under normal Windows user rights. I confess I dont fully understand Windows here, but I know form first-hand experience that such things happen - I then open a cmd shell as "Administrator" and do the copying of the file in it, and then all works ... maybe you could try that.

4.  See attached Stemlets.PHN (9.79 KB) 
Thanks - that's why I am quite sure that the plugin is "somewhere else" than NWC looks for plugins.

5.  I opened the nwctxt file in an already open NWC2 session.  NWC2 never generates error messages for me when I open the program.
Good to know! - if that had happened, there would be an error in some source code which NWC finds on startup.

I hope that helps ...

H.M.



491
Object Plugins / Re: Beam.hmm (0.4)
Hi -

I don't think it has to do with fonts. First, the .nwctxt files do contain the font names embedded, so one should see in the page setup whether there would be any unusual fonts.
But second and more important, I do not use fonts, but rather draw the beams with NWC's plugin machinery (in concrete, the nwcdraw module; the code for drawing a beam is copied verbatim from the nwcdraw documentation).

Just to make sure - I use NWC version 2.75a.2.

And I have attached an image on how "Stemlets.nwctxt" looks in my NWC ... what does yours look like?

//Edit:
Do you see any alerts - either
  • when opening NWC (which would indicate a problem with Beam.hmm's source code),
  • or when opening an example .nwctxt file (which would either indicate that Beam.hmm is not installed at the expected folder, or again an error in the source code which for some reason does not occur on my computer)?

H.M.
492
Object Plugins / Re: Beam.hmm (0.4)
I have now upgraded the Beam object from .test to .hmm. There are quite a few changes for this first "production ready" version:

  • Most important, the beam options for notes and rests under the beam have been changed from obscure symbols to (somewhat) understandable texts.
  • The selection of the number of beams for a beam group is now on the start note of the beam group , i.e. the note after the reduced number of beams (similar to NWC's "Beam group start" option) - this seems a little more intuitive than the previous attempt, where one specified the beam reduction on its left side.
  • The maximum span of a Beam object is now 16 notes and rests. If a longer beam group is needed, two or more overlapping beam objects can be defined (see extreme example in "ComplexGrouping.nwctxt").
  • A span of 1 is also supported; this can be used for single beamed notes (see last example in "FractionalBeams.nwctxt").
  • Stemlets for rests compute their length correctly.
  • There is a rudimentary option for stemlets on notes (see last example in "Stemlets.nwctxt").
  • Some more examples have been added.

As always, I'm happy about any comments!

H.M.
493
Object Plugins / Re: Beam.test (0.3)
0.3 has rounding at some crucial places, so that one can always (I hope) create horizontal beams; and, after the suggestion of Mike, the spinner now uses 0.5 increments. Also, I added another example file.

H.M.
494
Object Plugins / Re: Beam.test (0.91)
0.2 has an additional property to keep non-through-running beams together - the problem came up with an example on page 315 of B.B.
0.91 provides smaller beams for grace notes as well as CueHead notes.

Here are the six remaining example files:

  • "SpeedVariationBeams" shows a notation that would drive our church choir crazy. This notation requires that all notes are eighths, because otherwise each user object (there is one for each slanting beam) would draw a second, unwanted parallel bar; if one wanted to play this, the varying tempo would have to be created by a tempo track.
  • "Stemlets" shows a notation that connects rests to a beamed group. E.Gould writes: "This notation is helpful for passages of complex rhythms, especially where rests occupy the start or finish of a subdivision of a beat". One could also use it to mark special notes under a beam, as my last example shows.
  • "DoubleBeams" shows double beams on a single staff, which can e.g. help with quickly notating SATB scores on two staffs.
  • "Tuplets" shows how with tuplets, one can e.g. draw one single beam above somewhat lengthened sixteenth to create the impression of "short eighths".
  • "DoubleStemmedBeams" (since 0.7) shows overlapping beams, with additional non-beamed notes on double-stemmed chords.
  • "GraceBeams" (since 0.91) shows small to tiny beams with grace notes as well as CueHeads.

H.M.
495
Object Plugins / Beam.hmm (0.91)
NWC is missing cross-staff beams, unison beams, more complex grouping (where some group have one running beam, others two), overhanging fractional beams, beam groups for speed variation, stemlets, single notes with beams, and double beams (double stem chords with beams on both sides). I thought this could be remedied by creating a versatile Beam object, which is attached to this posting.
In addition, there are ten example files, which mainly use examples from "Behind Bars":

  • "UnisonBeams" has three unison beam examples;
  • "CrossStaffBeams" has a percussion example and two piano examples; the last - an excerpt from a piece by Webern - is, I would say, quite interesting ...
  • "OppositeStemDirectionBeams" has some examples with stems in opposite directions (but the previous file also has some ...);
  • "ComplexGrouping" has a single example with different numbers of connecting beams - NWC cannot do this, but I doubt that this is really an important feature;
  • "FractionalBeams" shows an interesting way to indicate complex rhythms, which I have yet to see outside B.B.; and has single notes with beams.

The remaining examples are attached to the next posting.

The maximum span for a Beam object is 16 notes and rests. If a longer beam group is needed, two or more overlapping beam objects can be defined (see example in "ComplexGrouping.nwctxt").

Breaking beams at a line break does not work - you have to provide a separate Beam object for each line.

(If you possess "Behind Bars", I am interested in whether you see problems with my example scores; and if you have suggestions for interesting examples I could or should add).

H.M.
496
Object Plugins / Re: XText.hmm (0.7)
Another update (I think it's the last one): I added explicit negative kerning, i.e., the possibility to move a piece of text to the left. A simple example is the composition of an "fp" dynamic signature from the existing f and p dynamics, which can be done with the StaffSymbols text segment %f%%---%%p%.

The attachments of the primary posting show some more example usages.

The addition of this feature required a complete rewrite of the internal logic, so I may have introduced new bugs - if you find any, let me know!

H.M.
497
Object Plugins / Re: XText.hmm (0.6)
Ha - you got me! ... yes, I considered it for a second, but I have not yet "interned" (in my mind) the Lua patterns (too much experience with the "big" regexps of C# etc.), so I am a little too cautious there. But right after uploading the script, I thought that the following much simpler code should work:
Code: [Select · Download]
  ['%%1/8%%']     = 'H',
  ['%%ppp%%']     = 'P',
...
    for k, v in pairs(replacements) do
      text = string.gsub(text, k, v)
    end
If you read this - do you have any complaints? - if not, I'll simply replace 0.6 (no functional change).

... I just did it :)

H.M.
498
Object Plugins / Re: XText.hmm (0.5)
As Lawrie points out, the dynamic signs are in the StaffSymbols font, so you could just find them there ...

... however, in version 0.6 I have added a number of abbreviations for quite a few characters from that font: Just select font StaffSymbols, and then use e.g. %ppp% or %f% or %cclef% or %#% etc. For all symbols, look into the help text. If you want some more symbols added, just tell me (including the abbreviation name you think is helpful).

XTextExamples.nwctxt (attached to the primary posting) contains some examples for this, e.g. the "sempre pp" xtext.


A technical remark and question: The code simply replaces the abbreviations with single letters, as defined in a table with entries like
Code: [Select · Download]
  ['%1/8%']     = 'H',
  ['%ppp%']     = 'P',
Thus, for %ppp%, the character P is substituted, which has hex code 0x50. However, when I look into the CharMap of the standard StaffSymbols font NWC2STDA, the ppp symbol has character code 0xf050. Yet, my code works ... but I am not really sure why; and whether there might be circumstances when it does not work. Could someone tell me what's going on here? - thanks!

H.M.
499
General Discussion / Re: My (new, and long) NWC wishlist
Thanks for comments - especially those regarding scanning and MusicXML: When I have time, I'll certainly try them out ... at least out of interest, but maybe then for actual use!

... for the rest of my and our items, I hope to get from NWC/Eric at least a little by the way of replies ...

H.M.
500
General Discussion / Re: Beyond Bars Lyric sizes
Are you talking about the size of lyrics (so it says in the subject) or about text sizes in general (as you mention "text instructions" in your question)?

First of all, find out what you want or like: Just take a number of printed scores (I'd say at least 20; and preferably recent ones; and of course professional ones), decide which you like for their readability, measure the sizes they use - and there you are.
Most publishers have at least the first pages of scores available on the internet - often with water marks or the like to prevent copying, but that's of no concern to you.
Measuring font sizes is tricky - a standard ruler with millimeter granularity is not fine enough. But I think it should be easy to enlarge a pdf or a scanned page e.g. exactly by a factor of 5 (500%) and then measure the sizes.

Here is what "Behind Bars" says for lyrics (p.438): Regarding fonts, it says
Quote
Place the text below the vocal line, in roman type. Italic may be used to differentiate sounds that are not part of the literary text, such as mm and ah ...
And regarding size, it says:
Quote
TEXT SIZE
The text must be at a comfortable size to read easily. Do not reduce its size to accommodate lengthy syllables for short note-values. A good proprotion for the height of a lower-case letter (such as 'm') is one stave-space.
That's all there is (or I found).

In practice, I found that people in our choir are happy when I increase the font size for lyrics by one point from NWC's default sizes. A recent score of mine has a "staff metrics" of 15.5pt and a lyrics font size of 9.5pt, and no-one complained. Typically, I now go for 10pt for the lyrics size and even 11pt for some pieces, with correspondingly larger staff metrics.

Hope that helps a little ...

H.M.