Jump to content

Recommended Posts

In the video "Opusmodus Parametric Composition" by Jorvd, from 2019-12, at 11:10, he demonstrates using harmonic-path to combine a melody and chords. I entered this code to match the video, and it didn't work for me. Here's what he showed:

(setf chords '(c3g3c4ds4 gs2f3c4d4 c3g3c4ds4 gs2f3c4d4
               c3g3c4ds4 d3g3b3f4 c3g3c4g4 d3f3c4gs4
               ds3g3c4g4 cs3g3as3f4 ds3a3c4fs4 fs3a3c4ds4
               c3g3c4ds4 g2g3b3d4 gs2f3c4d4 b2d3f4
               c3g3c4ds4 f3gs3c4d4 g2g3b3d4 c3ds3g3ds4
               as2e3g3g4 f2f3c4gs4 g2g3b3d4 cs3g3as3f4
               b2g3d4g4 c3g3c4ds4 f3gs3c4f4 g2g3b3d4
               gs2ds3c4gs4 gs2ds3c4gs4 as2as3d4f4 ds3as3ds4g4
               d3f3b3f4 c3g3c4e4 f3gs3c4f4 g2g3c4ds4
               g2g3b3d4 c3ds3g3c4 c3ds3g3c4))

(setf instrument1 (gen-repeat (length chords) '(s g4c4 c4 g4e4 g4 d4 c4 g4f4 g4)))

(setf instrument1.map1 (harmonic-path chords instrument1 :type '> :octave 'path))

It seems that instrument1 needs to have the melody nested one level in order to make the result work, like this:

(setf instrument1 (gen-repeat (length chords) '((s g4c4 c4 g4e4 g4 d4 c4 g4f4 g4))))

It looks like something changes in gen-repeat, or possibly harmonic-path since December, or am I missing something? Thanks for any insights!

Link to post
Share on other sites
(setf instrument1 (gen-repeat (length chords) '((s g4c4 c4 g4e4 g4 d4 c4 g4f4 g4))))

Nothing change, it needs to be a list with sublists.

 

(gen-repeat 3 '((c4 g4) (c4 a4)))
=> ((c4 g4) (c4 a4) (c4 g4) (c4 a4) (c4 g4) (c4 a4))

If number is a list then each list is repeat individually.

(gen-repeat '(3) '((c4 g4) (c4 a4)))
=> ((c4 g4 c4 g4 c4 g4) (c4 a4 c4 a4 c4 a4))

 

Link to post
Share on other sites

Hi Stoney,

It took some time to look into the issue this morning, but I can't find a clear answer for you as well.

It might be the result from an earlier evaluation although I really doubt that since the video was recorded in one take, either way, sublists are the way to go!
 

- Jor

Link to post
Share on other sites

Thanks for the response. I have been tripped up by nesting several times, so I'm paying closer attention to it now. I will leave this as a mystery!

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Similar Topics

    • By Jorvd
      Hi Everyone,

      I'm looking for a method/function which changes the velocity only for notes that are repeating.
      In other words, if I have a sequence like this:
      '(c4 eb4 g4 ab4 ab4 ab4 d4 eb4) I would like to be able to create a crescendo/decrescendo or set a custom velocity for just the Ab notes.
      In the past I've customised a Pattern Matching function from Stephane to change the velocity for specific note lengths:
      (defun velocity-map-omn (map omn &key (otherwise '-)) (do-verbose ("velocity-map-omn") (let ((plist (disassemble-omn omn))) (setf (getf plist :velocity) (pattern-map map (getf plist :length) :otherwise otherwise :swallow t)) (apply 'make-omn plist)))) And I think this should be very close to what I want, however, I have no idea how to tell OM to process repeating notes only.
      Is there anyone who already has a function like this or can steer me in the right direction? Hope this makes sense, any help is very welcome!
       
      - Jor
    • By AM
      is there an RESPELL-function which would change sharps into flats and flats into sharps for single pitch-values? enharmonic changes....
       
      like: 
       
      (enharmonic 'cs4) => db4 (enharmonic 'db4) => cs4  
      but there is an other solution for an EQUALP* whicht is "independent" from pitch-name (enharmonic)... but a function like ENHARMONIC or EQUALP* could be useful (for pattern-match etc)...
       
      (defun equalp* (a b) (equal (pitch-to-midi a) (pitch-to-midi b))) (equalp* 'cs4 'db4) => t  
      there is an EQUALP in the system (but not documented), and works like that
      (equalp 'cs4 'db4) => nil (equalp 'cs4 'cs4) => t :
       
       
    • By AM
      ;;; CHANGE-TIME-STRUCTURES ;;; works okay, but not exactly precise because of rhy-to-integer, which is not very easy in some cases ;;; this function changes basic-rhy-structures (if it's all the time perhaps in x/32) ;;; to other/changing sections. the lengths/rests will be rounded like in LENGTH-RATIONAL-QUANTIZE ;;; rhy+span => '((32 2) (44 7)) => means in 32 three values, in 44 seven values (defun change-time-structure (omnseq rhy+span &key (basic-rhy 32) (round 1/4)) (let* ((intseq (loop for i in (omn :length (flatten omnseq)) collect (* i basic-rhy))) (rhyseq (mapcar #'car rhy+span)) (spanseq (mapcar #'cadr rhy+span)) (divided-intseq (gen-divide spanseq intseq))) (length-rational-quantize (flatten (gen-length divided-intseq rhyseq)) :round round))) (change-time-structure '(2/44 -2/44 3/44 5/44 6/44) '((32 2) (20 2) (28 3)) :basic-rhy 44) => (1/16 -1/16 -1/8 3/20 1/4 -1/10 3/14 -1/28) (change-time-structure '(2/32 -2/32 3/32 5/32 6/32) '((20 2) (44 2) (28 3)) :basic-rhy 32) => (1/10 -1/10 -1/20 3/44 5/44 -3/44 3/14 -1/28)  
      could be done better -> go for it 🙂
      greetings
      andré
×
×
  • Create New...