OpenShot Audio Library | OpenShotAudio 0.4.0

Loading...
Searching...
No Matches
Public Member Functions | List of all members
juce::universal_midi_packets::BytestreamToUMPDispatcher Class Reference

`#include <juce_UMPDispatcher.h>`

## Public Member Functions
| BytestreamToUMPDispatcher (PacketProtocol pp, int storageSize)
void | reset ()
template<typename PacketCallbackFunction >
void | dispatch (const uint8_t *begin, const uint8_t *end, double timestamp, PacketCallbackFunction &&callback)

## Detailed Description

Parses a stream of bytes representing a sequence of bytestream-encoded MIDI 1.0 messages, converting the messages to UMP format and passing the packets to a user-provided callback as they become ready.

Definition at line 77 of file juce_UMPDispatcher.h.

## Constructor & Destructor Documentation

## ◆ BytestreamToUMPDispatcher()

juce::universal_midi_packets::BytestreamToUMPDispatcher::BytestreamToUMPDispatcher | ( | PacketProtocol | pp,
|  | int | storageSize )
| inline explicit

Initialises the dispatcher.

Channel messages will be converted to the requested protocol format `pp`. `storageSize` bytes will be allocated to store incomplete messages.

Definition at line 85 of file juce_UMPDispatcher.h.

## Member Function Documentation

## ◆ dispatch()

template<typename PacketCallbackFunction >

void juce::universal_midi_packets::BytestreamToUMPDispatcher::dispatch | ( | const uint8_t * | begin,
|  | const uint8_t * | end,
|  | double | timestamp,
|  | PacketCallbackFunction && | callback )
| inline

Calls `callback` with a View of each converted packet as it becomes ready.

Parameters

  begin | the first byte in a range of bytes representing bytestream-encoded MIDI messages.
  end | one-past the last byte in a range of bytes representing bytestream-encoded MIDI messages.
  timestamp | a timestamp to apply to the created packets.
  callback | a callback which will be passed a View pointing to each new packet as it becomes ready.

Definition at line 104 of file juce_UMPDispatcher.h.

## ◆ reset()

void juce::universal_midi_packets::BytestreamToUMPDispatcher::reset | ( |  | ) |
| inline

Definition at line 90 of file juce_UMPDispatcher.h.

The documentation for this class was generated from the following file:

- juce_UMPDispatcher.h