1 %% Do not edit this file; it is auto-generated from LSR http://lsr.dsi.unimi.it
2 %% This file is in the public domain.
8 This Scheme-based snippet generates 24 random notes (or as many as
9 required), based on the current time (or any randomish number you might
10 wish to specify instead, so you can obtain the same random notes each
11 time): i.e., to get different random notes patterns, just change this
16 { #(let ((random-state (seed->random-state (current-time))))
18 (make-music 'SequentialMusic 'elements
20 (let ((idx (random 12 random-state)))
21 (make-music 'EventChord
22 'elements (list (make-music 'NoteEvent
23 'duration (ly:make-duration 2 0 1 1)
24 'pitch (ly:make-pitch (quotient idx 7)