Changes In Branch tld Excluding Merge-Ins
This is equivalent to a diff from 3d4ddcbab5 to aa88358397
2010-11-17
| ||
07:42 | csound score lines are no longer hardcoded, but are stored with each instrument check-in: b8d35587a4 user: spiffytech@gmail.com tags: master | |
07:34 | WIP on tld: 4b95fed Added support for rest notes Leaf check-in: ec61af8387 user: spiffytech@gmail.com tags: stash | |
07:34 | index on tld: 4b95fed Added support for rest notes check-in: ef35a8e9e0 user: spiffytech@gmail.com tags: stash | |
07:30 | Added support for rest notes Closed-Leaf check-in: aa88358397 user: spiffytech@gmail.com tags: tld | |
06:57 | Note duration is now counted as fraction of a whole note, as measured based on BPM check-in: 5a35ffdd27 user: spiffytech@gmail.com tags: tld | |
00:07 | Added support for top-down composition check-in: 7c7ce6adb8 user: spiffytech@gmail.com tags: tld | |
2010-11-16
| ||
19:15 | Added todo list Leaf check-in: 3d4ddcbab5 user: spiffytech@gmail.com tags: ply | |
18:37 | Now prints csound code, both notes and chords, replicating the functionality of the original Minimaly Functional Version check-in: 9bd31df856 user: spiffytech@gmail.com tags: ply | |
Modified cfg.py from [8e359b2146] to [08a2f25157].
1 2 3 4 5 6 7 8 9 10 11 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 | + + + + + - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - + - - + + - - + + + + - + + + - - + - - + - + - | #!/usr/bin/env python from __future__ import division import os import random import sys import time random.seed(time.time()) import parse def main(): key = "A" bps = 80/60 print bps tempo = 1/bps max_duration = 1 |
Modified parse.py from [503badc6f2] to [3a88b8ab43].
1 2 3 4 5 6 7 8 9 10 11 12 13 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | - + + + + + + + + | #!/usr/bin/env python from ply import lex, yacc class Note(): def __init__(self, value, duration=.25, octave=8): self.value = value self.duration = duration self.octave = octave self.accidental = None def __repr__(self): return "Note %s %s %s" % (self.value, self.duration, self.octave) class Chord(): |
︙ | |||
64 65 66 67 68 69 70 | 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | - + + - + + | # Parse (yacc) def p_pitch_list(p): '''score : score note |
︙ | |||
100 101 102 103 104 105 106 | 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | + + - + | p[0] = new_note def p_chord(p): '''chord : QUOTE pitch QUOTE | QUOTE pitch CHORD_TYPE QUOTE ''' pitch = p[2].value pitch = pitch.upper() |
︙ | |||
125 126 127 128 129 130 131 132 133 134 135 136 137 138 | 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 | + + + + + + + + | p[0] = p[1] def p_pitch(p): '''pitch : BASENOTE ''' p[0] = Note(p[1]) def p_rest(p): ''' rest : REST | REST NOTE_LENGTH ''' p[0] = Rest() if len(p) > 2: p[0].duration = p[2] def p_error(p): print "Syntax error at '%s' of element type %s" % (p.value, p.type) yacc.yacc() #print yacc.parse("GFG B'AB,, | g/2fg gab | GFG BAB | d2A AFD") return yacc.parse(score) |
Modified test.sco from [da39a3ee5e] to [dabc4744e4].