AutoMovie API
    Preparing search index...

    Function createInstrument

    • A musical instrument: an upright piano, a steel-string guitar, a violin, a side drum or a bugle, with the keys, frets and strings a hand plays numbered as contacts.

      • An upright piano stands with its back at the origin's Z and its keyboard toward +Z, the bass at -X. key1 to key88 are its keys from the bottom A and each is a button pressed down by its dip. keybed is the keyboard's top. lid hinges the fallboard from upright at rest to flat over the keys. The right foot meets the damperPedal plate on the moving damperPedalHinge. A production seats a player on a createSeat bench.
      • A guitar and a violin lie on their backs with the neck toward +X, the body's neck end at the origin's X. string1 to string6 (four on a violin) run from the nut to the saddle or bridge, string1 the highest on the -Z edge; a guitar's fret1 to fret20 are the places a fingertip stops the strings behind each fret, each a bar across the fingerboard whose sites run across the strings; neck is the neck the fretting hand grips; a guitar's body is where the strumming hand meets the strings. A violin's chinrest is absent. The bow is a separate model from createViolinBow.
      • A side drum stands on its bottom head: head the batter head the sticks strike, sling the hook a sling or a carrier holds it by.
      • A bugle lies on its side, its bell toward +X: grip where a hand holds it, mouthpiece the socket the lips meet.

      Playing a note by finger, fret or key needs the finger campaign's laws (#3445, #3446); holding, carrying and the drummer's march do not.

      Parameters

      • params: createInstrument.IParams

        The kind and any dimension the author fixes.

      • Optionalseed: string | number

        The seed that draws every dimension left free inside its band; absent, each takes the middle of its band.

      Returns Archetype<createInstrument.Affordance, createInstrument.Dimension>

      The instrument.

      For a fixed dimension outside its band, or one only another kind has.