1 changed files with 33 additions and 0 deletions
@ -0,0 +1,33 @@ |
|||
#!/usr/bin/env python3 |
|||
|
|||
# Perkons Sequencer Model |
|||
# (Hypothetical) |
|||
|
|||
ppq_cc = 16 |
|||
cc_count = 8 |
|||
cc_bits = 7 |
|||
|
|||
ppq_note = 4 |
|||
note_trigger_bits = 1 |
|||
note_threepos_count = 3 |
|||
note_threepos_bits = 2 |
|||
note_accent_bits = 1 |
|||
note_ratchet_bits = 3 |
|||
note_odd_bits = 4 |
|||
note_prob_bits = 3 |
|||
|
|||
bars = 1 |
|||
channels = 4 |
|||
|
|||
|
|||
cc_bits_per_pulse = cc_count * cc_bits |
|||
note_bits_per_pulse = (note_threepos_count * note_threepos_bits) + (note_trigger_bits) + note_ratchet_bits + note_odd_bits + note_prob_bits |
|||
|
|||
cc_bytes_per_quarter = cc_bits_per_pulse / 8 * ppq_cc |
|||
note_bytes_per_quarter = note_bits_per_pulse / 8 * ppq_note |
|||
|
|||
bytes_per_quarter = cc_bytes_per_quarter + note_bytes_per_quarter |
|||
#bytes_per_quarter = 128 |
|||
|
|||
print('quarter size: {0} bits {1}bytes'.format(bytes_per_quarter * 8, bytes_per_quarter)) |
|||
print('sequence size: {0} kb'.format((bytes_per_quarter * 4 * bars * channels) / 1024)) |
Loading…
Reference in new issue