Help for Adding of a Custom Instrument Needed! :-)

Hello dear colleagues,
I’m trying to add a custom instrument to Dorico 4 Pro, but for now unsuccessfully…

I’m following the the how to provided by @FredGUnn:

I’m using the Visual Studio Code Editor in Administrator mode in order to edit the following files:
instruments.xml, instrumentnames_en.xml, instrumentFamiliesDefinitions.xml

Here is the entry I’m adding to
instruments.xml:

			<InstrumentEntityDefinition>
				<name>Qanun</name>
				<entityID>instrument.strings.qanun</entityID>
				<parentEntityID/>
				<inheritanceMask>0</inheritanceMask>
				<nameID>instrumentname.strings.qanun</nameID>
				<numStaves>2</numStaves>
				<musicXMLSoundID>pluck.zither</musicXMLSoundID>
				<numberingStyle>kDummy</numberingStyle>
				<showGuitarChords>false</showGuitarChords>
				<showChordSymbols>false</showChordSymbols>
				<staveDefinition>
					<numStaveLines>5</numStaveLines>
					<barlineSpan>2</barlineSpan>
					<useBrace>true</useBrace>
					<isVocalStave>false</isVocalStave>
					<defaultContextualStemDirectionIsUp>false</defaultContextualStemDirectionIsUp>
				</staveDefinition>
				<clefs>
					<clefIDsForEachStave array="true">
						<staveClefIDs>
							<idForTransposingLayouts>clef.treble</idForTransposingLayouts>
						</staveClefIDs>
						<staveClefIDs>
							<idForTransposingLayouts>clef.bass</idForTransposingLayouts>
						</staveClefIDs>
					</clefIDsForEachStave>
				</clefs>
				<pitchedInstrumentData>
					<standardRange>A2-E6</standardRange>
					<advancedRange>A2-E6</advancedRange>
					<concertOctaveTransposition>0</concertOctaveTransposition>
					<transposedChromaticTransposition>0</transposedChromaticTransposition>
					<transposedDiatonicTransposition>0</transposedDiatonicTransposition>
					<useKeySignatures>true</useKeySignatures>
					<showTransposition>kNever</showTransposition>
				</pitchedInstrumentData>
				<playingTechniques array="true">
					<playingTechnique>
						<techniqueID>pt.accent</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.crescendoDiminuendo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.diminuendo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.diminuendoCrescendo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.f</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.ff</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.fff</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.ffp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.fp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.laissezVibrer</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.marcato</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.mf</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.mp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.natural</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.pp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.ppp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.sf</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.sfp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.sfz</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.simile</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.staccatissimo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.staccato</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.tremolo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.crescendo</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.p</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.tenuto</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.arpeggioDown</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.arpeggioUp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.damp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.nail</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.pince</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.glissandoDown</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.glissandoUp</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.tremblement</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.trill</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.legato</techniqueID>
					</playingTechnique>
					<playingTechnique>
						<techniqueID>pt.nonLegato</techniqueID>
					</playingTechnique>
				</playingTechniques>
			</InstrumentEntityDefinition>

N.B: When <parentEntityID/>instrument.strings.zither</parentEntityID> is added Dorico shows the following Error Message at start-up:

<parentEntityID/> must be left unpopulated in order to start Dorico 4 Pro normally.

instrumentnames_en.xml:

<InstrumentNameEntityDefinition>
				<entityID>instrumentname.strings.qanun</entityID>
				<name>Qanun</name>
				<parentEntityID/>
				<inheritanceMask>0</inheritanceMask>
				<data>
					<uiName>Qanun</uiName>
					<singularFullName>Qanun</singularFullName>
					<singularShortName>Qan.</singularShortName>
					<pluralFullName>Qanuns</pluralFullName>
					<pluralShortName>Qan.</pluralShortName>
					<gender>kNeutral</gender>
					<language>kEnglish</language>
				</data>
			</InstrumentNameEntityDefinition>

instrumentFamiliesDefinitions.xml:

<InstrumentFamilyEntityDefinition>
				<entityID>instrument family.strings</entityID>
				<name>Strings</name>
				<order>10</order>
				<parentEntityID/>
				<inheritanceMask>0x0</inheritanceMask>
				<instrumentDefinitionIDs>instrument.strings.contrabass, instrument.strings.contrabass.alias.contrabass, instrument.strings.contrabass.d, instrument.strings.contrabass.d.alias.contrabass, instrument.strings.guitarrón, instrument.strings.hurdy-gurdy, instrument.strings.kora, instrument.strings.koto, instrument.strings.oud, instrument.strings.sarangi, instrument.strings.shamisen, instrument.strings.tanpura.female, instrument.strings.tanpura.female.alias.tambura-female, instrument.strings.tanpura.male, instrument.strings.tanpura.male.alias.tambura-male, instrument.strings.uprightbass, instrument.strings.uprightbass, instrument.strings.uprightbass.alias.string-bass, instrument.strings.uprightbass.alias.string-bass, instrument.strings.viol.bass, instrument.strings.viol.bass.alias.bass-viola-da-gamba, instrument.strings.viol.tenor, instrument.strings.viol.tenor.alias.tenor-viola-da-gamba, instrument.strings.viol.treble, instrument.strings.viol.treble.alias.treble-viola-da-gamba, instrument.strings.viola, instrument.strings.violin, instrument.strings.violin.alias.fiddle, instrument.strings.violoncello, instrument.strings.zither, instrument.strings.qanun</instrumentDefinitionIDs>
			</InstrumentFamilyEntityDefinition>

At the end when I’m able to start Dorico 4 Pro properly and trying to add the Qanun as Player
it gives blank instrument in the list:

Am I doing something wrong?!
Every help will be very welcomed!

Thank you very much for your time! :slight_smile:

Best wishes,
Thurisaz :slight_smile:

I’m not sure what you’re doing wrong but it worked for me.

Files below:
qanun.zip (103.9 KB)

EDIT: Just saw you wanted it to have 2 staves. I just copied the Zither setup so it only has 1 staff in the files. You can edit that of course.

I’ve no idea… But I wonder why you would want to to do this.

Is it not simpler just to appropriate another similar instrument, rename it and apply an appropriate endpoint to get your playback?

That said - I would have thought a qanun would be most similar to a zither/harp and not be part of the strings family.

Dorico has Zither in the Strings category by default. I just copied and pasted the Zither definition as a starting point and didn’t change that, but that’s pretty easy to move to another category if desired.

…and as you found, the zither is just a single stave…

I’m not questioning the methodology, rather just the need. For me it’s a why bother?

Hi @Janus and @FredGUnn
Thank you very much for the replies! :slight_smile:

@Janus,

Firstly I did this, but it led to a problem in my Playback Template because of duplicating instrument IDs/Names.
I need to create completely new instrument with unique instrument ID in order to solve this issue.

@FredGUnn,
The Qanun is part of the Zither family, but it’s a bit bigger and has larger range and more articulations than the zither. I found Single Staff and Grand Staff examples on internet for writing for Qanun. I find the Grand Staff approach more comfortable for writing and reading due to the range and way of playing.
Unfortunately I can’t make it appearing in the Dorico’s Instrument list.
I don’t know what I’m doing wrong?!

Best wishes,
Thurisaz :slight_smile:

There are also situations where Dorico doesn’t have a predefined instrument to even use to rename. I’ve needed to use a 1-line non-percussion staff and a 0-line staff before, and there aren’t any existing instruments with those configurations. It’s also a bit trickier with percussion if you are trying to create percussion maps that will work correctly. Dorico only has high and low congas IIRC, but VSL Synchron has 3, Tumba, Conga, and Quinto. (Up to 5 are pretty common too. LP sells 4 sizes in Giovanni’s line.)

I actually was commissioned to write a medley with 2 Qanuns in Spring 2021! It was a virtual commencement piece to feature all the graduating seniors from a music school since they couldn’t play together in person. Anyway, the arrangement opens with the 2 Qanun players. Here’s a link, hopefully it still works.

3 Likes

Can you be more explicit? For example, I have no problem creating multiple violins and routing them to different VSTs with different expression maps.

Fine. Those are deficiencies. But a Qanun can easily be mimicked.

Hey, @FredGUnn, bravo! :slight_smile:
Pretty nice piece involving two qanuns! :slight_smile:
I’m using the qanun as part of an ethnic ensemble + symphonic orchestra.
In order to combine Middle Eastern and Balkan music with Symphonic orchestra.

Best wishes,
Thurisaz :slight_smile:

1 Like

Hi @Janus,

I was using the Piano instrument and renamed it to Qanun in order to assign a Virtual Instrument to it.
The problem occurs when I created an Endpoint configurations for the VE Pro template, where the piano is always loaded.
The Endpoint Configuration detects the Qanun as Piano and redirects it to both Qanun and Piano VE Pro Server Templates and then I’m getting the grand piano triggered by the qanun expression maps.
I’m having a Rhodes Piano in the same score, which is part of the VE Pro Piano template, so the Playback Template loads the Endpoint configuration for the Pianos, too.

Best wishes,
Thurisaz :slight_smile:

So that’s a VEpro problem, rather than a Dorico problem?
I don’t use VEpro, but I’ve had no problem assigning the same Dorico instrument to different VSTs instruments.

Thanks!

If I’m reading him correctly, I would think that would be a Dorico Playback Template problem. It shouldn’t be hard to manually assign, but if he wants to set up a Playback Template that assigns everything automatically to the correct VEP instance, then each instrument will need its own definition.

(As I said I don’t use VEP) but I can manually assign fake Dorico Instruments (eg 2 violins, one renamed as electric violin) to two different VSTs, assign different expression maps and for all intents consider those instruments as unique and independent in the playback template.

Why should VEP behave any different?

Like any Playback Template, I think it would depend on the order assigned. If he simply renames so has multiple different instruments with the same “Piano” ID (can’t remember which type of ID the Playback Template references), then sure, you could create a template where the first “Piano” routes to the Qanun sound library and the second Piano routes to a Piano. If he ever has a single Piano and wants to apply a master PT, then of course it will route to the wrong sound.

This could be solved by routing it manually or having multiple Playback Templates, but if he wants a default template to just do everything correctly automatically, then he’ll need to create the instrument.

1 Like

@Janus ,
The routing inside Dorico is slightly different than when the instruments are hosted in VE Pro.
If you don’t have any previous experience with VE Pro, it won’t be an easy task to explain it.
When using VE Pro you should create a multiple Endpoint Configuration in order to use as less as possible Instrument Racks in Dorico.
When you are hosting your instruments inside Dorico, then you are having a dedicated rack for every instrument and and an Endpoint Configuration for every rack with as less as possible entries.

@FredGUnn already explained my case very well. :slight_smile:

I hope now it’s a bit clear for you! :slight_smile:

Best wishes,
Thurisaz

1 Like

As I said - I don’t use VE Pro. All I’d observe is that, if you didn’t use VE pro, there’d (apparently) be no need to create a custom instrument!

Janus,
I would like to take advantage of VE Pro, since it saves me a lot of time waiting the large libraries to load and reload. :slight_smile:

I don’t disagree. I’m just trying to separate issues so we don’t get confused. I’d hate for novices to think they had to mess with Dorico’s underlying xml files in order to create unusual instruments.

@Janus ,

Don’t worry… I’m far, far away from novice with Dorico and the other Steinberg products. I’m a Steiny user for around 14 years. I’m following the development of Dorico since it was publicly introduced and became an active user since version 3.
Including my previous IT experience… I perfectly know what and why I’m trying to achieve. :slight_smile:

The problem here is why Dorico doesn’t show me the newly created instrument, since I’m following the exact instructions of @FredGUnn?! Still gives me a Blank Instrument.
By the way the files provided by @FredGUnn don’t work for me, too…
No matter how I’m starting Dorico, As an Administrator, or not… Very interesting… The instruments created by him are Blank too…

Best wishes,
Thurisaz :slight_smile: