comparison classes.lisp @ 22:99ccd775245a

Moved midi out of main files darcs-hash:20061214125711-f76cc-c9e7f9af1054c67473ff6d8a8e3b84e45fe43f35.gz
author David Lewis <d.lewis@gold.ac.uk>
date Thu, 14 Dec 2006 12:57:11 +0000
parents 2f331bbdfab8
children
comparison
equal deleted inserted replaced
21:c389ba869ef9 22:99ccd775245a
38 (octave :accessor %diatonic-pitch-octave :initarg :octave))) 38 (octave :accessor %diatonic-pitch-octave :initarg :octave)))
39 39
40 (defclass pitch-interval (pitch-interval-designator) 40 (defclass pitch-interval (pitch-interval-designator)
41 ((span :accessor %pitch-interval-span :initarg :span))) 41 ((span :accessor %pitch-interval-span :initarg :span)))
42 42
43 (defclass midi-message () ;?
44 ((channel :accessor %midi-message-channel :initarg :channel)
45 (track :accessor %midi-message-track :initarg :track)))
46
47 ;; events 43 ;; events
48 44
49 (defclass event (anchored-period) ()) 45 (defclass event (anchored-period) ())
50 (defclass pitched-event (event pitch-designator) ()) 46 (defclass pitched-event (event pitch-designator) ())
51 (defclass chromatic-pitched-event (pitched-event chromatic-pitch) ()) 47 (defclass chromatic-pitched-event (pitched-event chromatic-pitch) ())
52 (defclass midi-pitched-event (chromatic-pitched-event midi-message)
53 ((velocity :initarg :velocity)
54 (patch :initarg :patch)))
55 (defclass percussive-event (event) ()) 48 (defclass percussive-event (event) ())
56 (defclass midi-percussive-event (percussive-event midi-message)
57 ((velocity :initarg :velocity)
58 (patch :initarg :patch)
59 (sound :initarg :sound)))
60 49
61 ;;; Range-based `constituents' 50 ;;; Range-based `constituents'
62 ;; Whilst these are all constituents in the CHARM sense, their 51 ;; Whilst these are all constituents in the CHARM sense, their
63 ;; properties apply to a timed range rather than to a set of 52 ;; properties apply to a timed range rather than to a set of
64 ;; events. As such, they can be regarded as anchored-periods with 53 ;; events. As such, they can be regarded as anchored-periods with
79 ;; Only has line-of-fifths distance from c, so custom signatures 68 ;; Only has line-of-fifths distance from c, so custom signatures
80 ;; won't work 69 ;; won't work
81 ((sharp-count :accessor %basic-key-signature-sharp-count 70 ((sharp-count :accessor %basic-key-signature-sharp-count
82 :initarg sharp-count))) 71 :initarg sharp-count)))
83 72
84 (defclass midi-key-signature (basic-key-signature)
85 ;; Is mode ever used in real life? Is it ever accurately used in
86 ;; real life?
87 ((mode :accessor %midi-key-signature-mode
88 :initarg mode)))
89
90 (defclass tempo (anchored-period) 73 (defclass tempo (anchored-period)
91 ;; accel and rit in symbolic encoding will need other structures, as 74 ;; accel and rit in symbolic encoding will need other structures, as
92 ;; will textual tempo markings. 75 ;; will textual tempo markings.
93 ((bpm :accessor %tempo-bpm 76 ((bpm :accessor %tempo-bpm
94 :initarg :bpm))) 77 :initarg :bpm)))