NiCMidi 1.1.0
A MIDI library derived from J.D.Koftinoff jdksmidi
|
Contains the MIDI values enumerations (to have readable values instead of hexadecimal values) and some utility function. More...
Go to the source code of this file.
Typedefs | |
typedef unsigned long | MIDIClockTime |
The type of a variable which can hold a time in MIDI ticks. More... | |
Enumerations | |
Channel status bytes | |
enum | : unsigned char { NOTE_OFF =0x80 , NOTE_ON =0x90 , POLY_PRESSURE =0xa0 , CONTROL_CHANGE =0xb0 , PROGRAM_CHANGE =0xc0 , CHANNEL_PRESSURE =0xd0 , PITCH_BEND =0xe0 , SYSEX_START =0xf0 , MTC =0xf1 , SONG_POSITION =0xf2 , SONG_SELECT =0xf3 , TUNE_REQUEST =0xf6 , SYSEX_END =0xf7 , RESET =0xff , META_EVENT =0xff } |
These are the type values for a MIDI channel message. More... | |
MIDI Real Time Messages | |
enum | : unsigned char { RT_TIMING_CLOCK =0xf8 , RT_MEASURE_END =0xf9 , RT_START =0xfa , RT_CONTINUE =0xfb , RT_STOP =0xfc , RT_ACTIVE_SENSE =0xfe } |
These bytes are used for quick one-byte messages intended to be sent during playback. More... | |
GM Controller Numbers | |
enum | : unsigned char { C_LSB =0x20 , C_GM_BANK =0x00 , C_MODULATION =0x01 , C_BREATH =0x02 , C_FOOT =0x04 , C_PORTA_TIME =0x05 , C_DATA_ENTRY =0x06 , C_MAIN_VOLUME =0x07 , C_BALANCE =0x08 , C_PAN =0x0a , C_EXPRESSION =0x0b , C_GENERAL_1 =0x10 , C_GENERAL_2 =0x11 , C_GENERAL_3 =0x12 , C_GENERAL_4 =0x13 , C_DAMPER =0x40 , C_PORTA =0x41 , C_SOSTENUTO =0x42 , C_SOFT_PEDAL =0x43 , C_HOLD_2 =0x45 , C_GENERAL_5 =0x50 , C_GENERAL_6 =0x51 , C_GENERAL_7 =0x52 , C_GENERAL_8 =0x53 , C_EFFECT_DEPTH =0x5b , C_TREMELO_DEPTH =0x5c , C_CHORUS_DEPTH =0x5d , C_CELESTE_DEPTH =0x5e , C_PHASER_DEPTH =0x5f , C_DATA_INC =0x60 , C_DATA_DEC =0x61 , C_NRPN_LSB =0x62 , C_NRPN_MSB =0x63 , C_RPN_LSB =0x64 , C_RPN_MSB =0x65 , C_ALL_SOUND_OFF =0x78 , C_RESET =0x79 , C_LOCAL =0x7a , C_ALL_NOTES_OFF =0x7b , C_OMNI_OFF =0x7c , C_OMNI_ON =0x7d , C_MONO =0x7e , C_POLY =0x7f } |
General MIDI standardized controller numbers. More... | |
Registered Parameter Numbers | |
enum | : unsigned char { RPN_BEND_WIDTH =0x00 , RPN_FINE_TUNE =0x01 , RPN_COARSE_TUNE =0x02 } |
These bytes are used by the GS standard in a RPN Control Change message. More... | |
META Event types | |
enum | : unsigned char { META_SEQUENCE_NUMBER = 0x00 , META_GENERIC_TEXT = 0x01 , META_COPYRIGHT = 0x02 , META_TRACK_NAME = 0x03 , META_INSTRUMENT_NAME = 0x04 , META_LYRIC_TEXT = 0x05 , META_MARKER_TEXT = 0x06 , META_CUE_TEXT = 0x07 , META_PROGRAM_NAME = 0x08 , META_DEVICE_NAME = 0x09 , META_GENERIC_TEXT_A = 0x0A , META_GENERIC_TEXT_B = 0x0B , META_GENERIC_TEXT_C = 0x0C , META_GENERIC_TEXT_D = 0x0D , META_GENERIC_TEXT_E = 0x0E , META_GENERIC_TEXT_F = 0x0F , META_CHANNEL_PREFIX = 0x20 , META_OUTPUT_CABLE = 0x21 , META_END_OF_TRACK = 0x2F , META_TEMPO = 0x51 , META_SMPTE = 0x54 , META_TIMESIG = 0x58 , META_KEYSIG = 0x59 , META_SEQUENCER_SPECIFIC = 0x7F } |
This is the byte 1 (after the status) of a message with status 0xff (MIDI meta event). More... | |
Functions | |
Helper functions for MIDI and music | |
const char * | GetChanMsgName (unsigned char status) |
Returns a readable name for the given channel message status. More... | |
const char * | GetChanModeMsgName (unsigned char number) |
Returns a readable name for the given channel mode (Control change with controller number between 0x78 ... 0x7f). More... | |
const char * | GetSysMsgName (unsigned char status) |
Returns a readable name for the given sys message status. More... | |
const char * | GetMetaMsgName (unsigned char type) |
Returns a readable name for the given meta message status. More... | |
const char * | GetGMProgramName (unsigned char number, int format=0) |
Returns a readable name for a GM program number. More... | |
const char * | GetGMDrumkitName (unsigned char number, int format=0) |
Returns a readable name for a GM program number on channel 10 (drumkit). More... | |
bool | IsNoteWhite (unsigned char note) |
Returns true if the MIDI number of the note denotes a white key. More... | |
bool | IsNoteBlack (unsigned char note) |
Returns true if the MIDI number of the note denotes a black key. More... | |
int | GetNoteOctave (unsigned char note) |
MIDI note number to standard octave conversion. More... | |
const char * | KeyName (signed char sharp_flats, unsigned char major_minor, bool uppercase=true, bool space=false, bool use_Mm=true) |
Converts a MIDI key signature into a readable form. More... | |
Variables | |
MIDI Clock related constants | |
const MIDIClockTime | TIME_INFINITE = 0xffffffff |
A constant which represents an infinite time. More... | |
const unsigned int | DEFAULT_CLKS_PER_BEAT = 120 |
The default clocks per beat parameter when initializing a MIDIMultiTrack. More... | |
Default constants when initializing messages and classes | |
const int | MIDI_DEFAULT_TIMESIG_NUMERATOR = 4 |
Timesig numerator. More... | |
const int | MIDI_DEFAULT_TIMESIG_DENOMINATOR = 4 |
Timesig denominator. More... | |
const double | MIDI_DEFAULT_TEMPO = 120.0 |
Musical tempo. More... | |
const int | MIDI_DEFAULT_KEYSIG_KEY = 0 |
Keysig key (C) More... | |
const int | MIDI_DEFAULT_KEYSIG_MODE = 0 |
Keysig mode (major) More... | |
Contains the MIDI values enumerations (to have readable values instead of hexadecimal values) and some utility function.