Line data Source code
1 : /*
2 : * SPDX-License-Identifier: GPL-3.0-only
3 : * MuseScore-Studio-CLA-applies
4 : *
5 : * MuseScore Studio
6 : * Music Composition & Notation
7 : *
8 : * Copyright (C) 2021 MuseScore Limited and others
9 : *
10 : * This program is free software: you can redistribute it and/or modify
11 : * it under the terms of the GNU General Public License version 3 as
12 : * published by the Free Software Foundation.
13 : *
14 : * This program is distributed in the hope that it will be useful,
15 : * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 : * GNU General Public License for more details.
18 : *
19 : * You should have received a copy of the GNU General Public License
20 : * along with this program. If not, see <https://www.gnu.org/licenses/>.
21 : */
22 :
23 : #include "windssetupdataresolver.h"
24 :
25 : using namespace mu::engraving;
26 : using namespace muse::mpe;
27 :
28 21 : PlaybackSetupData WindsSetupDataResolver::doResolve(const Instrument* instrument)
29 : {
30 : static const std::unordered_map<std::string, PlaybackSetupData> SETUP_DATA_MAP = {
31 : { "winds", { SoundId::WindsGroup, SoundCategory::Winds } },
32 : { "eb-piccolo", { SoundId::Piccolo, SoundCategory::Winds } },
33 : { "db-piccolo", { SoundId::Piccolo, SoundCategory::Winds } },
34 : { "piccolo", { SoundId::Piccolo, SoundCategory::Winds } },
35 : { "treble-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Treble } } },
36 : { "soprano-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
37 : { "alto-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Alto } } },
38 : { "bass-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Bass } } },
39 : { "contra-alto-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Contra_Alto } } },
40 : { "contrabass-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
41 : { "subcontra-alto-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Sub_Contra_Alto } } },
42 : { "double-contrabass-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Double_Contra_Bass } } },
43 : { "hyperbass-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Hyper_Bass } } },
44 : { "irish-flute", { SoundId::Flute, SoundCategory::Winds, { SoundSubCategory::Irish } } },
45 : { "flute", { SoundId::Flute, SoundCategory::Winds } },
46 : { "traverso", { SoundId::Traverso, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
47 : { "danso", { SoundId::Danso, SoundCategory::Winds } },
48 : { "daegeum", { SoundId::Daegeum, SoundCategory::Winds, { SoundSubCategory::Korean } } },
49 :
50 : { "a-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
51 : { "g-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
52 : { "f-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
53 : { "e-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
54 : { "d-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
55 : { "c-dizi", { SoundId::Dizi, SoundCategory::Winds, { SoundSubCategory::Chinese } } },
56 :
57 : { "shakuhachi", { SoundId::Shakuhachi, SoundCategory::Winds, { SoundSubCategory::Japanese } } },
58 : { "hichiriki", { SoundId::Hichiriki, SoundCategory::Winds, { SoundSubCategory::Japanese } } },
59 : { "fife", { SoundId::Fife, SoundCategory::Winds } },
60 :
61 : { "d-tin-whistle", { SoundId::Whistle, SoundCategory::Winds, { SoundSubCategory::Tin } } },
62 : { "c-tin-whistle", { SoundId::Whistle, SoundCategory::Winds, { SoundSubCategory::Tin } } },
63 : { "bflat-tin-whistle", { SoundId::Whistle, SoundCategory::Winds, { SoundSubCategory::Tin } } },
64 : { "slide-whistle", { SoundId::Whistle, SoundCategory::Winds, { SoundSubCategory::Slide } } },
65 :
66 : { "french-flageolet", { SoundId::Flageolet, SoundCategory::Winds } },
67 : { "english-flageolet", { SoundId::Flageolet, SoundCategory::Winds } },
68 : { "flageolet", { SoundId::Flageolet, SoundCategory::Winds } },
69 :
70 : { "garklein-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Garklein } } },
71 : { "sopranino-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
72 : { "soprano-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
73 : { "recorder", { SoundId::Recorder, SoundCategory::Winds } },
74 : { "alto-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Alto } } },
75 : { "bass-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Bass } } },
76 : { "tenor-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
77 : { "greatbass-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Great_Bass } } },
78 : { "contrabass-recorder", { SoundId::Recorder, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
79 :
80 : { "g-soprano-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
81 : { "f-soprano-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
82 : { "ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
83 : { "c-soprano-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
84 : { "bb-soprano-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Alto } } },
85 : { "g-alto-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Alto } } },
86 : { "f-alto-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Alto } } },
87 : { "c-alto-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Alto } } },
88 : { "bb-alto-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Alto } } },
89 : { "c-bass-ocarina", { SoundId::Ocarina, SoundCategory::Winds, { SoundSubCategory::Bass } } },
90 :
91 : { "gemshorn", { SoundId::Gemshorn, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
92 : { "soprano-gemshorn", { SoundId::Gemshorn, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
93 : { "alto-gemshorn", { SoundId::Gemshorn, SoundCategory::Winds, { SoundSubCategory::Alto } } },
94 : { "tenor-gemshorn", { SoundId::Gemshorn, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
95 : { "bass-gemshorn", { SoundId::Gemshorn, SoundCategory::Winds, { SoundSubCategory::Bass } } },
96 :
97 : { "theremin", { SoundId::Theremin, SoundCategory::Winds, { SoundSubCategory::Electric } } },
98 :
99 : { "pan-flute", { SoundId::PanFlute, SoundCategory::Winds } },
100 :
101 : { "quena", { SoundId::Quena, SoundCategory::Winds } },
102 : { "c-quena", { SoundId::Quena, SoundCategory::Winds } },
103 : { "g-quena", { SoundId::Quena, SoundCategory::Winds } },
104 : { "f-quena", { SoundId::Quena, SoundCategory::Winds } },
105 : { "d-quena", { SoundId::Quena, SoundCategory::Winds } },
106 :
107 : { "fs-castilian-dulzaina", { SoundId::Dulzaina, SoundCategory::Winds, { SoundSubCategory::Castilian } } },
108 :
109 : { "piccolo-heckelphone", { SoundId::Heckelphone, SoundCategory::Winds } },
110 : { "heckelphone", { SoundId::Heckelphone, SoundCategory::Winds } },
111 : { "piccolo-oboe", { SoundId::Oboe, SoundCategory::Winds } },
112 : { "baroque-oboe", { SoundId::Oboe, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
113 : { "oboe", { SoundId::Oboe, SoundCategory::Winds } },
114 : { "oboe-d'amore", { SoundId::Oboe, SoundCategory::Winds } },
115 : { "oboe-da-caccia", { SoundId::Oboe, SoundCategory::Winds } },
116 : { "english-horn", { SoundId::Oboe, SoundCategory::Winds, { SoundSubCategory::English } } },
117 : { "bass-oboe", { SoundId::Oboe, SoundCategory::Winds, { SoundSubCategory::Bass } } },
118 : { "lupophone", { SoundId::Lupophone, SoundCategory::Winds } },
119 :
120 : { "sopranino-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
121 : { "soprano-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
122 : { "alto-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Alto } } },
123 : { "tenor-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
124 : { "bass-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Bass } } },
125 : { "great-bass-shawm", { SoundId::Shawm, SoundCategory::Winds, { SoundSubCategory::Great_Bass } } },
126 :
127 : { "cromorne", { SoundId::Cromorne, SoundCategory::Winds, { SoundSubCategory::French,
128 : SoundSubCategory::Baroque,
129 : SoundSubCategory::Reed } } },
130 :
131 : { "crumhorn", { SoundId::Crumhorn, SoundCategory::Winds } },
132 : { "soprano-crumhorn", { SoundId::Crumhorn, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
133 : { "alto-crumhorn", { SoundId::Crumhorn, SoundCategory::Winds, { SoundSubCategory::Alto } } },
134 : { "tenor-crumhorn", { SoundId::Crumhorn, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
135 : { "bass-crumhorn", { SoundId::Crumhorn, SoundCategory::Winds, { SoundSubCategory::Bass } } },
136 : { "greatbass-crumhorn", { SoundId::Crumhorn, SoundCategory::Winds, { SoundSubCategory::Great_Bass } } },
137 :
138 : { "cornamuse", { SoundId::Cornamuse, SoundCategory::Winds } },
139 : { "soprano-cornamuse", { SoundId::Cornamuse, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
140 : { "alto-cornamuse", { SoundId::Cornamuse, SoundCategory::Winds, { SoundSubCategory::Alto } } },
141 : { "tenor-cornamuse", { SoundId::Cornamuse, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
142 : { "bass-cornamuse", { SoundId::Cornamuse, SoundCategory::Winds, { SoundSubCategory::Bass } } },
143 :
144 : { "soprano-kelhorn", { SoundId::Kelhorn, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
145 : { "alto-kelhorn", { SoundId::Kelhorn, SoundCategory::Winds, { SoundSubCategory::Alto } } },
146 : { "tenor-kelhorn", { SoundId::Kelhorn, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
147 : { "bass-kelhorn", { SoundId::Kelhorn, SoundCategory::Winds, { SoundSubCategory::Bass } } },
148 : { "greatbass-kelhorn", { SoundId::Kelhorn, SoundCategory::Winds, { SoundSubCategory::Great_Bass } } },
149 :
150 : { "sopranino-rauschpfeife", { SoundId::Rauschpfeife, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
151 : { "rauschpfeife", { SoundId::Rauschpfeife, SoundCategory::Winds } },
152 : { "soprano-rauschpfeife", { SoundId::Rauschpfeife, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
153 :
154 : { "f-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
155 : { "e-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
156 : { "d-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
157 : { "c-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
158 : { "b-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
159 : { "bb-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
160 : { "duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
161 : { "a-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
162 : { "g-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Armenian } } },
163 : { "a-bass-duduk", { SoundId::Duduk, SoundCategory::Winds, { SoundSubCategory::Bass,
164 : SoundSubCategory::Armenian } } },
165 :
166 : { "shenai", { SoundId::Shenai, SoundCategory::Winds, { SoundSubCategory::Indian } } },
167 :
168 : { "piccolo-clarinet", { SoundId::Clarinet, SoundCategory::Winds } },
169 : { "soprano-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
170 : { "eb-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Sopranino,
171 : SoundSubCategory::In_E_flat } } },
172 : { "d-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
173 : { "c-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
174 : { "bb-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano,
175 : SoundSubCategory::In_B_flat } } },
176 : { "clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano,
177 : SoundSubCategory::In_B_flat } } },
178 : { "a-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
179 : { "g-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
180 : { "basset-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
181 : { "basset-horn", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
182 : { "alto-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Alto } } },
183 : { "bass-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Bass,
184 : SoundSubCategory::In_B_flat } } },
185 : { "bb-bass-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Bass,
186 : SoundSubCategory::In_B_flat } } },
187 : { "bb-bass-clarinet-bass-clef", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Bass,
188 : SoundSubCategory::In_B_flat } } },
189 : { "a-bass-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
190 : { "a-bass-clarinet-bass-clef", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
191 : { "contra-alto-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Contra_Alto } } },
192 : { "contrabass-clarinet", { SoundId::Clarinet, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
193 :
194 : { "sopranino-chalumeau", { SoundId::Chalumeau, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
195 : { "soprano-chalumeau", { SoundId::Chalumeau, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
196 : { "alto-chalumeau", { SoundId::Chalumeau, SoundCategory::Winds, { SoundSubCategory::Alto } } },
197 : { "chalumeau", { SoundId::Chalumeau, SoundCategory::Winds } },
198 : { "tenor-chalumeau", { SoundId::Chalumeau, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
199 : { "bass-chalumeau", { SoundId::Chalumeau, SoundCategory::Winds, { SoundSubCategory::Bass } } },
200 :
201 : { "d-xaphoon", { SoundId::Xaphoon, SoundCategory::Winds } },
202 : { "xaphoon", { SoundId::Xaphoon, SoundCategory::Winds } },
203 : { "bb-xaphoon", { SoundId::Xaphoon, SoundCategory::Winds } },
204 : { "g-xaphoon", { SoundId::Xaphoon, SoundCategory::Winds } },
205 :
206 : { "tarogato", { SoundId::Tarogato, SoundCategory::Winds, { SoundSubCategory::Hungarian,
207 : SoundSubCategory::Romanian } } },
208 :
209 : { "octavin", { SoundId::Octavin, SoundCategory::Winds } },
210 :
211 : { "sopranissimo-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Sopranissimo } } },
212 : { "sopranino-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
213 : { "aulochrome", { SoundId::Saxophone, SoundCategory::Winds } },
214 : { "soprano-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
215 : { "mezzo-soprano-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Mezzo_Soprano } } },
216 : { "heckelphone-clarinet", { SoundId::HeckelphoneClarinet, SoundCategory::Winds } },
217 : { "alto-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Alto } } },
218 : { "melody-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Melody } } },
219 : { "saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
220 : { "tenor-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
221 : { "baritone-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Baritone } } },
222 : { "bass-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Bass } } },
223 : { "contrabass-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
224 : { "subcontrabass-saxophone", { SoundId::Saxophone, SoundCategory::Winds, { SoundSubCategory::Sub_Contra_Bass } } },
225 :
226 : { "bassoon", { SoundId::Bassoon, SoundCategory::Winds } },
227 : { "contrabassoon", { SoundId::Contrabassoon, SoundCategory::Winds } },
228 : { "reed-contrabass", { SoundId::Contrabassoon, SoundCategory::Winds, { SoundSubCategory::Reed } } },
229 : { "dulcian", { SoundId::Dulcian, SoundCategory::Winds } },
230 : { "rackett", { SoundId::Rackett, SoundCategory::Winds } },
231 :
232 : { "sopranino-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Sopranino } } },
233 : { "sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
234 : { "soprano-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
235 : { "alto-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Alto } } },
236 : { "tenor-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
237 : { "baritone-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Baritone } } },
238 : { "bass-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Bass } } },
239 : { "contrabass-sarrusophone", { SoundId::Sarrusophone, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
240 :
241 : { "bagpipe", { SoundId::Bagpipe, SoundCategory::Winds } },
242 : { "accordion", { SoundId::Accordion, SoundCategory::Winds } },
243 : { "bandoneon", { SoundId::Bandoneon, SoundCategory::Winds } },
244 : { "concertina", { SoundId::Concertina, SoundCategory::Winds } },
245 :
246 : { "harmonica", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
247 : { "harmonica-d10high-g", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
248 : { "harmonica-d10f", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
249 : { "harmonica-d10d", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
250 : { "harmonica-d10c", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
251 : { "harmonica-d10a", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
252 : { "harmonica-d10g", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
253 : { "harmonica-d10low-d", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Diatonic } } },
254 : { "harmonica-c12c", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Chromatic } } },
255 : { "harmonica-c12g", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Chromatic } } },
256 : { "harmonica-c12tenor-c", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Chromatic,
257 : SoundSubCategory::Tenor } } },
258 : { "harmonica-c14c", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Chromatic } } },
259 : { "harmonica-c16c", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Chromatic } } },
260 : { "harmonica-chordet", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Huang } } },
261 : { "bass-harmonica-hohner", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Bass,
262 : SoundSubCategory::Hohner } } },
263 : { "bass-harmonica-huang", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Bass,
264 : SoundSubCategory::Huang } } },
265 : { "bass-harmonica", { SoundId::Harmonica, SoundCategory::Winds, { SoundSubCategory::Bass } } },
266 :
267 : { "melodica", { SoundId::Melodica, SoundCategory::Winds } },
268 :
269 : { "sho", { SoundId::Sho, SoundCategory::Winds, { SoundSubCategory::Japanese } } },
270 : { "alto-sheng", { SoundId::Sheng, SoundCategory::Winds, { SoundSubCategory::Alto } } },
271 : { "tenor-sheng", { SoundId::Sheng, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
272 : { "bass-sheng", { SoundId::Sheng, SoundCategory::Winds, { SoundSubCategory::Bass } } },
273 : { "sheng", { SoundId::Sheng, SoundCategory::Winds } },
274 : { "soprano-sheng", { SoundId::Sheng, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
275 :
276 : { "brass", { SoundId::BrassGroup, SoundCategory::Winds } },
277 :
278 : { "c-horn-alto", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Alto,
279 : SoundSubCategory::In_C } } },
280 : { "bb-horn-alto", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Alto,
281 : SoundSubCategory::In_B_flat } } },
282 : { "a-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_A } } },
283 : { "ab-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_A_flat } } },
284 : { "g-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_G } } },
285 : { "e-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_E } } },
286 : { "eb-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_E_flat } } },
287 : { "d-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_D } } },
288 : { "horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::French,
289 : SoundSubCategory::In_F } } },
290 : { "c-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::In_C } } },
291 : { "c-horn-bass", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Bass,
292 : SoundSubCategory::In_C } } },
293 : { "bb-horn-basso", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Bass,
294 : SoundSubCategory::In_B_flat } } },
295 : { "vienna-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Vienna } } },
296 :
297 : { "bb-wagner-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Wagner } } },
298 : { "f-wagner-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Wagner } } },
299 : { "wagner-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Wagner } } },
300 :
301 : { "eb-cornet", { SoundId::Cornet, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
302 : { "c-cornet", { SoundId::Cornet, SoundCategory::Winds } },
303 : { "bb-cornet", { SoundId::Cornet, SoundCategory::Winds } },
304 : { "a-cornet", { SoundId::Cornet, SoundCategory::Winds } },
305 :
306 : { "saxhorn", { SoundId::Saxhorn, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
307 : { "f-alto-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Alto } } },
308 : { "eb-alto-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Alto } } },
309 : { "baritone-horn", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Baritone } } },
310 : { "baritone-horn-treble", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Baritone,
311 : SoundSubCategory::Treble } } },
312 : { "baritone-horn-central-europe-treble", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::CentralEuropean,
313 : SoundSubCategory::Baritone,
314 : SoundSubCategory::Treble } } },
315 : { "baritone-horn-central-europe", { SoundId::Horn, SoundCategory::Winds, { SoundSubCategory::Baritone,
316 : SoundSubCategory::CentralEuropean } } },
317 : { "posthorn", { SoundId::Posthorn, SoundCategory::Winds } },
318 :
319 : { "bb-piccolo-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Piccolo } } },
320 : { "piccolo-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Piccolo } } },
321 : { "a-piccolo-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Piccolo } } },
322 : { "f-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
323 : { "e-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
324 : { "eb-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
325 : { "d-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
326 : { "c-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
327 : { "trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
328 : { "bb-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
329 : { "a-trumpet", { SoundId::Trumpet, SoundCategory::Winds } },
330 : { "pocket-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Pocket } } },
331 : { "slide-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Slide } } },
332 : { "tenor-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
333 : { "eb-bass-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
334 : { "c-bass-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
335 : { "bass-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
336 : { "bb-bass-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Bass } } },
337 : { "f-baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
338 : { "eb-baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
339 : { "d-baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
340 : { "c-baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
341 : { "bb-baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
342 : { "baroque-trumpet", { SoundId::Trumpet, SoundCategory::Winds, { SoundSubCategory::Baroque } } },
343 :
344 : { "bugle", { SoundId::Bugle, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
345 : { "soprano-bugle", { SoundId::Bugle, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
346 : { "alto-bugle", { SoundId::Bugle, SoundCategory::Winds, { SoundSubCategory::Alto } } },
347 : { "mellophone", { SoundId::MellophoneBugle, SoundCategory::Winds } },
348 : { "baritone-bugle", { SoundId::Bugle, SoundCategory::Winds, { SoundSubCategory::Baritone } } },
349 : { "euphonium-bugle", { SoundId::EuphoniumBugle, SoundCategory::Winds } },
350 : { "mellophon-bugle", { SoundId::MellophoneBugle, SoundCategory::Winds } },
351 : { "contrabass-bugle", { SoundId::Bugle, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
352 :
353 : { "fiscorn", { SoundId::Fiscorn, SoundCategory::Winds, { SoundSubCategory::Bass } } },
354 : { "flugelhorn", { SoundId::Flugelhorn, SoundCategory::Winds } },
355 : { "kuhlohorn", { SoundId::Kuhlohorn, SoundCategory::Winds } },
356 :
357 : { "f-alto-ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Alto } } },
358 : { "eb-alto-ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Alto } } },
359 : { "ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Bass } } },
360 : { "c-bass-ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Bass } } },
361 : { "bb-bass-ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Bass } } },
362 : { "eb-contrabass-ophicleide", { SoundId::Ophicleide, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
363 :
364 : { "cornettino", { SoundId::Cornettino, SoundCategory::Winds } },
365 : { "cornett", { SoundId::Cornett, SoundCategory::Winds } },
366 : { "soprano-cornett", { SoundId::Cornett, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
367 : { "alto-cornett", { SoundId::Cornett, SoundCategory::Winds, { SoundSubCategory::Alto } } },
368 : { "tenor-cornett", { SoundId::Cornett, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
369 :
370 : { "serpent", { SoundId::Serpent, SoundCategory::Winds } },
371 :
372 : { "soprano-trombone", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Soprano } } },
373 : { "alto-trombone", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Alto } } },
374 : { "tenor-trombone", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
375 : { "trombone", { SoundId::Trombone, SoundCategory::Winds } },
376 : { "trombone-treble", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Treble } } },
377 : { "contrabass-trombone", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
378 : { "bass-trombone", { SoundId::Trombone, SoundCategory::Winds, { SoundSubCategory::Bass } } },
379 : { "cimbasso", { SoundId::Cimbasso, SoundCategory::Winds } },
380 :
381 : { "alto-sackbut", { SoundId::Sackbut, SoundCategory::Winds, { SoundSubCategory::Alto } } },
382 : { "tenor-sackbut", { SoundId::Sackbut, SoundCategory::Winds, { SoundSubCategory::Tenor } } },
383 : { "bass-sackbut", { SoundId::Sackbut, SoundCategory::Winds, { SoundSubCategory::Bass } } },
384 :
385 : { "euphonium", { SoundId::Euphonium, SoundCategory::Winds } },
386 : { "euphonium-treble", { SoundId::Euphonium, SoundCategory::Winds, { SoundSubCategory::Treble } } },
387 :
388 : { "tuba", { SoundId::Tuba, SoundCategory::Winds } },
389 : { "f-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Bass } } },
390 : { "eb-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Bass } } },
391 : { "bass-eb-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Bass } } },
392 : { "bass-f-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Bass } } },
393 : { "eb-tuba-treble", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Treble,
394 : SoundSubCategory::Bass } } },
395 : { "c-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
396 : { "bb-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Contra_Bass } } },
397 : { "bb-tuba-treble", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Treble } } },
398 : { "subcontrabass-tuba", { SoundId::Tuba, SoundCategory::Winds, { SoundSubCategory::Sub_Contra_Bass } } },
399 :
400 : { "bb-sousaphone", { SoundId::Sousaphone, SoundCategory::Winds } },
401 : { "bb-sousaphone-treble", { SoundId::Sousaphone, SoundCategory::Winds, { SoundSubCategory::Treble } } },
402 : { "sousaphone", { SoundId::Sousaphone, SoundCategory::Winds } },
403 : { "helicon", { SoundId::Helicon, SoundCategory::Winds } },
404 :
405 : { "conch", { SoundId::Conch, SoundCategory::Winds } },
406 : { "horagai", { SoundId::Horagai, SoundCategory::Winds, { SoundSubCategory::Japanese } } },
407 :
408 : { "alphorn", { SoundId::Alphorn, SoundCategory::Winds, { SoundSubCategory::Alpine } } },
409 : { "rag-dung", { SoundId::RagDung, SoundCategory::Winds, { SoundSubCategory::Tibetan } } },
410 : { "didgeridoo", { SoundId::Didgeridoo, SoundCategory::Winds, { SoundSubCategory::Australian } } },
411 : { "shofar", { SoundId::Shofar, SoundCategory::Winds } },
412 : { "vuvuzela", { SoundId::Vuvuzela, SoundCategory::Winds } },
413 : { "tuned-klaxon-horns", { SoundId::KlaxonHorns, SoundCategory::Winds } },
414 : { "kazoo", { SoundId::Kazoo, SoundCategory::Winds } },
415 646 : };
416 :
417 21 : auto search = SETUP_DATA_MAP.find(instrument->id().toStdString());
418 21 : if (search == SETUP_DATA_MAP.cend()) {
419 11 : static PlaybackSetupData empty;
420 11 : return empty;
421 : }
422 :
423 : static const std::unordered_set<SoundId> supportPrimaryAndSecondaryCategories {
424 : SoundId::Flute,
425 12 : };
426 :
427 10 : if (muse::contains(supportPrimaryAndSecondaryCategories, search->second.soundId())) {
428 3 : SoundSubCategory category = instrument->isPrimary() ? SoundSubCategory::Primary : SoundSubCategory::Secondary;
429 3 : PlaybackSetupData setupData = search->second;
430 3 : setupData.add(category);
431 3 : return setupData;
432 3 : }
433 :
434 7 : return search->second;
435 312 : }
|