[JW Lua] Hairpins

Martin Marris mmarris at notecraft.com
Thu Dec 24 11:55:26 CET 2020


Hi Jan,

 

Good to hear from you. Long story, but it turned out that Perfect Layout, while no doubt excellent for most production projects, was not suited to this one. We need very tight control over a limited number of things, but I found Perfect Layout to be a bit too broad-brush for what we are trying to do on this rather odd project. We are not trying to produce a visually attractive or perfect score in Finale, but rather, we are doing “smart explosion” of conductor scores and then parsing the objects so that they will look good when imported somewhere else via XML. This often means making things look fairly crappy in Finale, to get the desired result at the other end. (Once the XML transfer process has been completed, the Finale files could just as well be thrown away.)

 

After three weeks of coding I now have two large JW Lua scripts that have automated the majority of tasks, cutting time spent by at least 75% on most files. This is a similar approach to what we’d been doing for the past couple of decades with very large Sibelius projects, but it is the first time I have done deep automation on the Finale side of things. In retrospect I wish we’d started earlier!

 

The main issue with super-automation of this kind is that you have to be able to justify the time spent on development. In this case it was three weeks of coding, but I think it is going to cut what might have been a six-month project down to six weeks. The trouble is that when you start coding a project, you are never quite sure how long it is going to take or even whether it will be possible to achieve your automation goals!

 

Thanks for the tip about controlling the endpoints in JW Lua, I will play around with it. We’ve already automated the placement of most common objects, hairpins are really the one remaining item that is wasting too much time in human editing.

 

Merry Christmas everyone, and fervent wishes for a better 2021!

 

Martin

 

From: JWLua <jwlua-bounces at jwmusic.nu> On Behalf Of Jan Angermüller
Sent: Thursday, December 24, 2020 10:38
To: The JW Lua script plug-in. <jwlua at jwmusic.nu>
Subject: Re: [JW Lua] Hairpins

 

Hi Martin,

as you own Perfect Layout, why don't you use it for hairpins?
The plug-in has this barline collision algorithm.
Hairpins can be controlled through JW Lua, except for hairpins that span more than two systems: then only the first and the last hairpin part can be adjusted.

 

>1. You will almost certainly need to call SetCustomShaped(true). (What has me confused is that in Finale each endpoint has its >own customized bit, so I am not sure how the PDK Framework is doing this without specifying the left or right endpoint.
SetCustomOffset uses the boolean value to determine the start/end segment.


void FCSmartShapeSegment::SetCustomOffset 

(

bool 

rightside

)

	



Best.
Jan

Am 24.12.2020 um 07:51 schrieb Martin Marris:

Thanks Robert. I am giving up on this one for the time being. We will use the JW Change plugin manually. It has a whole set of commands specifically for Hairpins. We have found that we can get more or less what we are looking for by setting all the horizontal positions to zero or something close to zero. This can be relative to the note entries, or relative to the measure borders. The very existence of all these options makes me think there must be some way to do the same in JW Lua although of course these may be calls that have not been implemented yet.

 

The JW Change plugin can cope with most of these issues, but cannot always fix sloppily attached hairpins, even though it has options that try to do this. That is one of the reasons I was hoping to achieve this programmatically in JW Lua (by using the “find nearest” stuff, which I am already using to fix the attachment of text dynamics). We are not looking for subtlety. All of the source material is at the elementary level and, for most instruments, hairpins should always start on a note entry and end at the rhythmic conclusion of another note entry (but without colliding with group barlines, so pulled back slightly at the right hand end at the end of a measure). In theory we should use a different algorithm for pianos and other instruments that cannot change dynamic through a sustained note, but I have more or less given up on that one and perhaps it is only engravers and other notation geeks who care.

 

Martin

 

From: JWLua  <mailto:jwlua-bounces at jwmusic.nu> <jwlua-bounces at jwmusic.nu> On Behalf Of Robert Patterson
Sent: Thursday, December 24, 2020 00:29
To: The JW Lua script plug-in.  <mailto:jwlua at jwmusic.nu> <jwlua at jwmusic.nu>
Subject: Re: [JW Lua] Hairpins

 

I've never used the PDK Framework support for Smart Shapes. It's complicated even with direct PDK access. That said:

 

1. You will almost certainly need to call SetCustomShaped(true). (What has me confused is that in Finale each endpoint has its own customized bit, so I am not sure how the PDK Framework is doing this without specifying the left or right endpoint.

 

2. It's possible you are correct that FCSmartShapeCtrlPointAdjust is not what you want. But if it isn't, then what you *do* want is not hooked up through the PDK Framework. So it's worth fiddling further, I'd say.

 

Good luck.

 

 

On Wed, Dec 23, 2020 at 6:14 PM Martin Marris <mmarris at notecraft.com <mailto:mmarris at notecraft.com> > wrote:

I’ve been trying to adjust the right end-point of hairpins. In the source Finale material I am working with, these routinely collide with or cross the group barlines in conductor scores, but I want them to stop a bit before the barline (this issue gets even more exaggerated if the file is brought into another environment via MusicXML). 

 

>From Google searches it seems like this is a known issue for Finale users, with all sorts of manual and semi-automated solutions. Indeed if I create a totally vanilla Finale document without using any special settings, that is exactly the behavior that I get when placing a slur. If you create a hairpin that spans a measure, it snaps to end exactly on the group barline.

 

There is a sample script on the JW Lua website that loads FCSmartshape objects, filters for hairpins, and changes the hairpin opening size by changing the FCSmartShapeCtrlPointAdjust setting for ControlPoint1OffsetY.

 

So far, so good. But when I try to change the “X” horizontal settings, nothing happens. I am beginning to think that these “control point adjust” settings have nothing to do with what I am trying to achieve, namely changing the X-offset (relative to the beat, or relative to the measure) of the SmartShape object.

 

Martin

 

_______________________________________________
JWLua mailing list
JWLua at jwmusic.nu <mailto:JWLua at jwmusic.nu> 
http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu





_______________________________________________
JWLua mailing list
JWLua at jwmusic.nu <mailto:JWLua at jwmusic.nu> 
http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu





-- 
Jan Angermüller
Dipl.-Ing.(FH) Dipl.-Jur. 
Orchideenstieg 13
22297 Hamburg
Tel. 040 - 28 94 84 82
Mobil 0173 - 99 33 904
www.elbsound.studio <http://www.elbsound.studio> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20201224/c9cad4a5/attachment.htm>


More information about the JWLua mailing list