diff options
author | Vitaly Novichkov <Wohlstand@users.noreply.github.com> | 2018-07-02 04:12:41 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-02 04:12:41 +0300 |
commit | 167231c0cf19a7cffd30210817b571a0d0b55013 (patch) | |
tree | afeea26af7965ef479f02cf78db33028a2746e6b /src/adlmidi_midiplay.cpp | |
parent | 306d925a17d13b1327b66658bee85784764dca48 (diff) | |
parent | b2a05a8912ff6b38c160494b64e999be55e10983 (diff) | |
download | libADLMIDI-167231c0cf19a7cffd30210817b571a0d0b55013.tar.gz libADLMIDI-167231c0cf19a7cffd30210817b571a0d0b55013.tar.bz2 libADLMIDI-167231c0cf19a7cffd30210817b571a0d0b55013.zip |
Merge pull request #124 from jpcima/describe-channels
color attribute for channel descriptor
Diffstat (limited to 'src/adlmidi_midiplay.cpp')
-rw-r--r-- | src/adlmidi_midiplay.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/adlmidi_midiplay.cpp b/src/adlmidi_midiplay.cpp index 5161b50..e01a1b8 100644 --- a/src/adlmidi_midiplay.cpp +++ b/src/adlmidi_midiplay.cpp @@ -1761,7 +1761,11 @@ void MIDIplay::describeChannels(char *str, char *attr, size_t size) } } - attr[index] = '\0'; // TODO + uint8_t attribute = 0; + if (loc) // 4-bit color index of MIDI channel + attribute |= (uint8_t)(loc->loc.MidCh & 0xF); + + attr[index] = (char)attribute; } str[index] = 0; |