[][src]Enum nom_midi::MetaEvent

pub enum MetaEvent<'src> {
    SequenceNumber(u16),
    Text(&'src [u8]),
    Copyright(&'src [u8]),
    SequenceOrTrackName(&'src [u8]),
    InstrumentName(&'src [u8]),
    Lyric(&'src [u8]),
    Marker(&'src [u8]),
    CuePoint(&'src [u8]),
    ProgramName(&'src [u8]),
    DeviceName(&'src [u8]),
    MidiChannelPrefix(u8),
    MidiPort(u8),
    EndOfTrack,
    Tempo(u32),
    SMPTEOffset(SMPTEOffset),
    TimeSignature(TimeSignature),
    KeySignature(KeySignature),
    SequencerSpecificEvent(&'src [u8]),
    Unknown(u8&'src [u8]),
}

A special non-MIDI event

Variants

SequenceNumber(u16)

The sequence number (as would be used in a MIDI Cue message)

Text(&'src [u8])

Free text, can include comments and other useful information, if that information doesn't naturally fit in another text-based field

Copyright(&'src [u8])

A copyright notice

SequenceOrTrackName(&'src [u8])

The name of the current sequence or track (depending on context)

InstrumentName(&'src [u8])

The name of the current track The name of the instrument for this track (e.g. "Flute", "Piano", "Tenor", etc.)

Lyric(&'src [u8])

A syllable or set of syllables to be sung as part of a vocal track.

Marker(&'src [u8])

A useful position-dependent note in the music (e.g. rehersal mark "A", loop point, section name)

CuePoint(&'src [u8])

A marker to indicate this event should be synchronized with some non-midi event, e.g. "car crash on screen", "actors leave stage", etc.

ProgramName(&'src [u8])

Indicates what patch or program name should be used by the immediately subsequent Bank Select and Program Change messages.

DeviceName(&'src [u8])

The name of the hardware device used to produce sounds for this track. Might be inserted for example if using a branded synth or keyboard to generate midi events.

MidiChannelPrefix(u8)

Indicate which channel subsequent SysEx and Meta events apply to. Lasts until the next event of this type, or a normal MIDI event

MidiPort(u8)

Specify which port future MIDI event apply to. This exists to increase the 4-bit channel limit, and so it's functionality overlaps with channels

EndOfTrack

This event must be at the end of each track, and must not be anywhere else

Tempo(u32)

Specifies the number of microseconds per quarter note for future MIDI events.

SMPTEOffset(SMPTEOffset)

This is complicated and I don't understand it.

TimeSignature(TimeSignature)

Set the time signature. If no time signature event occurs before a MIDI event the default is (4, 4)

KeySignature(KeySignature)

Set the key signature. The default is C major.

SequencerSpecificEvent(&'src [u8])

Vendor specific events. I don't try to parse them - just return the data

Unknown(u8&'src [u8])

An unrecognised event. To be future-compatible, just ignore these

Trait Implementations

impl<'src> PartialEq<MetaEvent<'src>> for MetaEvent<'src>[src]

impl<'src> Clone for MetaEvent<'src>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<'src> Debug for MetaEvent<'src>[src]

Auto Trait Implementations

impl<'src> Unpin for MetaEvent<'src>

impl<'src> Sync for MetaEvent<'src>

impl<'src> Send for MetaEvent<'src>

impl<'src> RefUnwindSafe for MetaEvent<'src>

impl<'src> UnwindSafe for MetaEvent<'src>

Blanket Implementations

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]