Special Notations ================= *Example script* (scamp): `examples/Tutorial/23_special_notations.py `__ *Download:* :download:`23_special_notations.py ` Ornaments, tremolo and other single-note notations. These notational details are passed to the fourth, optional "properties" argument of play_note. *Topics:* :doc:`Notation & engraving › Special notations `, :doc:`Playback › Playback adjustments ` .. raw:: html
score
.. raw:: html
.. code-block:: python from scamp import * # these lines set an playback adjustment to occur on notes with the "turn" notation, bending the pitch up and down # a similar approach could be taken with other notations. turn_pitch_envelope = Envelope([0, 0, 1, 1, 0, 0, -1, -1, 0, 0], [0.07, 0, 0.07, 0, 0.07, 0, 0.07, 0, 0.07]) playback_settings.set_playback_adjustment("turn", NotePlaybackAdjustment.add_to_params(pitch=turn_pitch_envelope)) s = Session() violin = s.new_part("Violin") s.start_transcribing() for pitch in [60, 64, 67, 72]: violin.play_note(pitch, 1, 0.5) violin.play_note(74, 1, 1, "tremolo") violin.play_note(75, 1, 0.5, "tremolo1") violin.play_note(76, 1, 0.25, "tremolo2") violin.play_note(78, 1, 0.25, "tremolo3") violin.play_note(77, 1, 1.75, "turn, tremolo, fermata") violin.play_note(84, 1, 0.25, "mordent") violin.play_note(83, 1, 1, "inverted mordent") violin.play_note(82, 1, 1, "trill mark") violin.play_note(81, 1, 1, "open-string") violin.play_note(80, 1, 1, "up-bow") violin.play_note(79, 1, 1, "down-bow") violin.play_note(78, 1, 1, "stopped") violin.play_note(77, 1, 1, "snap-pizzicato") violin.play_chord([60, 64, 67, 72], 1, 1, "arpeggiate") violin.play_chord([60, 64, 67, 72], 1, 1, "arpeggiate down") violin.play_chord([60, 64, 67, 72], 1, 1, "fermata, arpeggiate up") performance = s.stop_transcribing() performance.to_score().show()