本文整理汇总了C++中MidiMessage::isQuarterFrame方法的典型用法代码示例。如果您正苦于以下问题:C++ MidiMessage::isQuarterFrame方法的具体用法?C++ MidiMessage::isQuarterFrame怎么用?C++ MidiMessage::isQuarterFrame使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MidiMessage
的用法示例。
在下文中一共展示了MidiMessage::isQuarterFrame方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: timerCallback
//.........这里部分代码省略.........
midiLine += ") = ";
midiLine += String (msg.getControllerValue());
}
else if (msg.isTimeSignatureMetaEvent ())
{
int newNumerator, newDenominator;
msg.getTimeSignatureInfo (newNumerator, newDenominator);
midiLine += "TIME SIGNATURE: ";
midiLine += String (newNumerator);
midiLine += " / ";
midiLine += String (newDenominator);
}
else if (msg.isTempoMetaEvent ())
{
midiLine += "TEMPO: ";
midiLine += String (msg.getTempoSecondsPerQuarterNote ());
//midiLine += " ";
//midiLine += String (msg.getTempoMetaEventTickLength (ticksPerQuarterNote));
}
else if (msg.isMidiMachineControlMessage())
{
midiLine += "MIDI CONTROL: ";
switch (msg.getMidiMachineControlCommand())
{
case MidiMessage::mmc_stop: midiLine += "stop"; break;
case MidiMessage::mmc_play: midiLine += "play"; break;
case MidiMessage::mmc_deferredplay: midiLine += "deferredplay"; break;
case MidiMessage::mmc_fastforward: midiLine += "fastforward"; break;
case MidiMessage::mmc_rewind: midiLine += "rewind"; break;
case MidiMessage::mmc_recordStart: midiLine += "recordStart"; break;
case MidiMessage::mmc_recordStop: midiLine += "recordStop"; break;
case MidiMessage::mmc_pause: midiLine += "pause"; break;
}
}
else if (msg.isMidiStart ())
{
midiLine += "MIDI START: ";
}
else if (msg.isMidiContinue ())
{
midiLine += "MIDI CONTINUE: ";
}
else if (msg.isMidiStop ())
{
midiLine += "MIDI STOP: ";
}
else if (msg.isSongPositionPointer ())
{
midiLine += "SONG POSITION: ";
midiLine += String (msg.getSongPositionPointerMidiBeat ());
}
else if (msg.isQuarterFrame ())
{
midiLine += "QUARTER FRAME: ";
midiLine += String (msg.getQuarterFrameSequenceNumber ());
midiLine += " ";
midiLine += String (msg.getQuarterFrameValue ());
}
else if (msg.isFullFrame ())
{
midiLine += "FULL FRAME: ";
msg.getFullFrameParameters (hours, minutes, seconds, frames, timeCode);
midiLine += String (hours);
midiLine += ":";
midiLine += String (minutes);
midiLine += ":";
midiLine += String (seconds);
midiLine += ":";
midiLine += String (frames);
midiLine += " timecode: ";
switch (timeCode) {
case MidiMessage::fps24: midiLine += "fps24"; break;
case MidiMessage::fps25: midiLine += "fps25"; break;
case MidiMessage::fps30drop: midiLine += "fps30drop"; break;
case MidiMessage::fps30: midiLine += "fps30"; break;
}
}
else if (msg.isMidiMachineControlGoto (hours, minutes, seconds, frames))
{
midiLine += "MIDI CONTROL GOTO: ";
midiLine += String (hours);
midiLine += ":";
midiLine += String (minutes);
midiLine += ":";
midiLine += String (seconds);
midiLine += ":";
midiLine += String (frames);
}
midiOutputEditor->insertTextAtCursor (midiLine + T("\n"));
}
}
}
示例2: getName
const String getName(const MidiMessage &m)
{
if (m.isActiveSense())
{
return (" [Active Sense]");
}
if (m.isAftertouch())
{
return (" [Aftertouch]");
}
if (m.isAllNotesOff())
{
return (" [All notes off]");
}
if (m.isAllSoundOff())
{
return (" [All sound off]");
}
if (m.isChannelPressure())
{
return (" [Channel pressure]");
}
if (m.isController())
{
return (" [Controller]");
}
if (m.isFullFrame())
{
return (" [Full frame]");
}
if (m.isMetaEvent())
{
return (" [Meta event]");
}
if (m.isMidiClock())
{
return (" [MIDI Clock]");
}
if (m.isMidiContinue())
{
return (" [MIDI Continue]");
}
if (m.isMidiStart())
{
return (" [MIDI Start]");
}
if (m.isMidiStop())
{
return (" [MIDI Stop]");
}
if (m.isNoteOff())
{
return (" [Note off]");
}
if (m.isNoteOn())
{
return (" [Note on]");
}
if (m.isPitchWheel())
{
return (" [Pitch wheel]");
}
if (m.isProgramChange())
{
return (" [Program change]");
}
if (m.isQuarterFrame())
{
return (" Quarter frame]");
}
if (m.isSysEx())
{
return (" [System exclusive]");
}
return (" [Yet unknown]");
}