Jump to content
  • Sign in to follow this  

    Lesson 9. The Bass Part



    Two new functions enable the left-hand bass part to play sustained pitches for the length of each bar. This is a very common requirement in a multi-part texture where metres may be constantly changing.


    The first new function is GET-SPAN. This adds up each list of lengths.

    (setf rhythm (span line-rnd '(e)))
    => ((1/8 1/8 1/8 1/8) (1/8 1/8 1/8 1/8)
        (1/8 1/8 1/8 1/8 1/8) (1/8 1/8 1/8 1/8) (1/8 1/8 1/8))
    (setf bass-rhythm (get-span rhythm))
    => (1/2 1/2 5/8 1/2 3/8)


    The second function is FILTER-FIRST. This function selects the first pitch of each list in bass-line and groups them together as a separate list bass-select.

    (setf bass-line (span line-rnd bass))
    => ((c2 cs2 fs2 g2) (c3 c2 cs2 fs2)
        (g2 c3 c2 cs2 fs2) (g2 c3 c2 cs2) (fs2 g2 c3))
    (setf bass-select (filter-first 1 bass-line))
    => ((c2) (c3) (g2) (g2) (fs2))


    (setf line '(c4 cs4 fs4 g4 c5))
    (setf bass (pitch-transpose -24 line))
    (setf chords '(c4cs4fs4 g4c5))
    (setf line-rnd (gen-eval 5 '(rnd-sample (rnd-range 3 5) line) :seed 41))
    (setf rhythm (span line-rnd '(e)))
    (setf bass-line (span line-rnd bass))
    (setf dynamics (mclist '(f p f p ff)))
    (setf dyn-spanned (span line-rnd dynamics))
    (setf bass-rhythm (get-span rhythm))
    (setf bass-select (filter-first 1 bass-line))
    (setf line-1 (make-omn 
                  :length rhythm
                  :pitch line-rnd
                  :velocity dyn-spanned))
    (setf bass-1 (make-omn 
                  :length bass-rhythm
                  :pitch bass-select
                  :velocity dyn-spanned))
    (setf ts-list (get-time-signature line-1))
    (def-score lesson-9
               (:key-signature 'chromatic
                :time-signature ts-list
                :tempo 100
                :layout (piano-layout 'piano-rh 'piano-lh))
       :omn line-1
       :channel 1
       :sound 'gm
       :program 'acoustic-grand-piano)  
       :omn bass-1)


    Screen Shot 2017-12-05 at 11.26.43.png


    Next page Lesson 10. Gesture

    Go back to Reference page.

    Edited by opmo

    Sign in to follow this  

  • Introduction to OMN the language

    OMN is designed as a scripting language for musical events. It’s not about sounds themselves, it is about their control and organisation in a musical composition. As a linear script rather than a graphic stave, musical events can be transformed, extended, reorganised by powerful computer algorithms. Some sequencers and score writers provide basic algorithms, but they do not represent the way composers now think about the process of music composition. Composing has become such a multi-faceted pro

    OMN The Language 0
  • Introduction to Opusmodus

    Contents A Contemporary Language for Making Music The Parametric World of Music The Parametric Instrument Learning Opusmodus : A Strategy Important Questions: Necessary Answers

    Tutorial Guide 0
  • CLM Installation

    Contents CLM Installation Command Line Tools Load and Compile Instruments CLM Installation Common Lisp Music, by William Schottstaedt is a powerful sound synthesis language implemented in Lisp and C. CLM is essentiall

    CLM Examples 0
  • Create New...