Jump to content
View in the app

A better way to browse. Learn more.

Opusmodus

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Random movement between notes in time frame

Featured Replies

Hey everyone,

 

I want to create movement from f1 to c1 in a timeframe of 5 seconds. How can I generate random note values until 5 seconds are reached? Repetitions of notes should also be possible. Here's what I got so far:

 

(make-omn :length (rnd-sample 6 '(s -s e q)) :pitch (midi-to-pitch '(65 64 63 62 61 60)))

 

Thanks in advance,

Veit

 

 

 

 

;;; quick-function
(defun make-seq (&key (prob 0.5) (possible-pitches (make-scale 'c4 11))) ;; prob = length/rest-weight 
  (make-omn :pitch (rnd-sample 10 possible-pitches)
            :length (gen-length
                     (loop for i in (rnd-sum-to-size 20 10 '(1 2 3 4 5))
                           collect (if (probp prob)
                                       (* -1 i)
                                     i))
                     '1/16)
            :span :length))

;;; EVAL
(make-seq)

(make-seq :possible-pitches (midi-to-pitch (gen-integer 10 110))) ;; with rnd-pitches

of course... with 60bpm

Create an account or sign in to comment


Copyright © 2014-2026 Opusmodus™ Ltd. All rights reserved.
Product features, specifications, system requirements and availability are subject to change without notice.
Opusmodus, the Opusmodus logo, and other Opusmodus trademarks are either registered trademarks or trademarks of Opusmodus Ltd.
All other trademarks contained herein are the property of their respective owners.

Powered by Invision Community

Important Information

Terms of Use Privacy Policy

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.