AndreOktave Posted November 20 Share Posted November 20 Hello, I am trying to assign articulations (attributes) to certain note lengths my attempt: (setf omn '((q e3 p -q s a4) (s f3 mp -s) (e g3 mf))) (setf rh (omn :length omn)) ;=> ((1/4 -1/4 1/16) (1/16 -1/16) (1/8)) ;; how is it possible to convert the ratios to omn-notation?: (setf rhomn '((q -q s) (s -s) (e))) (setf aq '(ord) as '(stacc) ae '(spicc) a-q '(-) a-s '(-)) (setf art (assemble-section 'a (flatten rhomn))) ;;I don't understand how to handle the rests (setf pch (omn :pitch omn)) (setf vel (omn :velocity omn)) (make-omn :length rh :pitch pch :velocity vel :articulation art) ; => ((q e3 p ord - s a4 ord) (s f3 mp -) (e g3 mf stacc)) Which method can I use to achieve the correct assignment of the attributes to the specific note lengths, in order to obtain this result? ((q e3 p ord -q s a4 stacc ) (s f3 mp stacc -s) (e g3 mf spicc)) Thank you very much for any help or advice you can give me, best wishes AO Quote Link to comment Share on other sites More sharing options...
opmo Posted November 20 Share Posted November 20 One solution would be: (setf omn '((q e3 p -q s a4) (s f3 mp -s) (e g3 mf))) (setf dictum '((:any q :apply ord) (:any e :apply spicc) (:any s :apply stacc))) (dictum dictum omn) => ((q e3 p ord - s a4 stacc) (s f3 mp stacc -) (e g3 mf spicc)) Quote Link to comment Share on other sites More sharing options...
Stephane Boussuge Posted November 20 Share Posted November 20 Another solution is also possible with the function length-map: (setf omn '((q e3 p -q s a4) (s f3 mp -s) (e g3 mf))) (setf out (length-map '((q ord)(s stacc)(e spicc)) omn)) => ((q e3 p ord - s a4 stacc) (s f3 mp stacc -) (e g3 mf spicc)) opmo 1 Quote Link to comment Share on other sites More sharing options...
AndreOktave Posted November 20 Author Share Posted November 20 Thank you very much for your fast and helpful answers! best wishes Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.