Exemple #1
0
import inspect
import typing

import abjad
import baca
from abjadext import rmakers

instruments = dict([
    ("BassClarinet", abjad.BassClarinet()),
    ("Bassoon", abjad.Bassoon()),
    ("Cello", abjad.Cello()),
    ("Clarinet", abjad.ClarinetInBFlat()),
    ("Contrabass", abjad.Contrabass(pitch_range="[E1, D6]")),
    ("EnglishHorn", abjad.EnglishHorn()),
    ("Flute", abjad.Flute()),
    ("Harp", abjad.Harp()),
    ("Horn", abjad.FrenchHorn()),
    ("Oboe", abjad.Oboe()),
    ("Percussion", abjad.Percussion()),
    ("Piano", abjad.Piano()),
    ("Trombone", abjad.TenorTrombone()),
    ("Trumpet", abjad.Trumpet()),
    ("Tuba", abjad.Tuba()),
    ("Vibraphone", abjad.Vibraphone()),
    ("Viola", abjad.Viola()),
    ("Violin", abjad.Violin()),
])


def instrument(key):
    return baca.instrument(instruments[key])
Exemple #2
0
import abjad
import mccartney

instruments = abjad.OrderedDict([
    (
        "Violin",
        abjad.Violin(
            markup=mccartney.markups.instrument("Violin"),
            short_markup=mccartney.markups.short_instrument("vln"),
        ),
    ),
    (
        "MonoSynth",
        abjad.ClarinetInBFlat(
            markup=mccartney.markups.instrument("MonoSynth"),
            short_markup=mccartney.markups.short_instrument("msy"),
        ),
    ),
    (
        "PolySynth",
        abjad.Piano(
            markup=mccartney.markups.instrument("PolySynth"),
            short_markup=mccartney.markups.short_instrument("psy"),
        ),
    ),
])

if __name__ == '__main__':
    for key, item in instruments.items():
        print(key, item)
Exemple #3
0
 class CcoClarinet2(calliope.Staff):
     instrument=abjad.ClarinetInBFlat(
         name="Clarinet in B♭ 2", short_name="cl.2")
     midi_instrument = "clarinet"
Exemple #4
0
 class OoaClarinet(calliope.Staff):
     instrument=abjad.ClarinetInBFlat(
         name="Clarinet in B♭", short_name="cl.")
     midi_instrument = "clarinet"
Exemple #5
0
 class CcoClarinets(calliope.Staff):
     instrument = abjad.ClarinetInBFlat(name="Clarinet in B♭ 1,2",
                                        short_name="cl.1,2")