Delete unused downloads page asset.
[chromium-blink-merge.git] / media / midi / midi_message_util.h
blob6533ab3f1a1d007d5e7329becdf78168026ada63
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef MEDIA_MIDI_MIDI_MESSAGE_UTIL_H_
6 #define MEDIA_MIDI_MIDI_MESSAGE_UTIL_H_
8 #include <deque>
9 #include <vector>
11 #include "base/basictypes.h"
12 #include "media/midi/midi_export.h"
14 namespace media {
15 namespace midi {
17 // Returns the length of a MIDI message in bytes. Never returns 4 or greater.
18 // Returns 0 if |status_byte| is:
19 // - not a valid status byte, namely data byte.
20 // - the MIDI System Exclusive message.
21 // - the End of System Exclusive message.
22 MIDI_EXPORT size_t GetMidiMessageLength(uint8 status_byte);
24 const uint8 kSysExByte = 0xf0;
25 const uint8 kEndOfSysExByte = 0xf7;
27 const uint8 kSysMessageBitMask = 0xf0;
28 const uint8 kSysMessageBitPattern = 0xf0;
29 const uint8 kSysRTMessageBitMask = 0xf8;
30 const uint8 kSysRTMessageBitPattern = 0xf8;
32 } // namespace midi
33 } // namespace media
35 #endif // MEDIA_MIDI_MIDI_MESSAGE_UTIL_H_