Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
roc::audio::Depacketizer Class Reference

Depacketizer. More...

#include <depacketizer.h>

Inheritance diagram for roc::audio::Depacketizer:
Collaboration diagram for roc::audio::Depacketizer:

Public Member Functions

 Depacketizer (packet::IReader &reader, IFrameDecoder &payload_decoder, packet::channel_mask_t channels, bool beep)
 Initialization. More...
virtual void read (Frame &frame)
 Read audio frame. More...
bool started () const
 Did depacketizer catch first packet? More...
packet::timestamp_t timestamp () const
 Get next timestamp to be rendered. More...
- Public Member Functions inherited from roc::core::ListNode
ListNodeDatalist_node_data () const
 Get list node data. More...

Detailed Description


Reads packets from a packet reader, decodes samples from packets using a decoder, and produces an audio stream.

Definition at line 29 of file depacketizer.h.

Constructor & Destructor Documentation

roc::audio::Depacketizer::Depacketizer ( packet::IReader reader,
IFrameDecoder payload_decoder,
packet::channel_mask_t  channels,
bool  beep 



  • reader is used to read packets
  • payload_decoder is used to extract samples from packets
  • channels defines a set of channels in the output frames
  • beep enables weird beeps instead of silence on packet loss

Member Function Documentation

virtual void roc::audio::Depacketizer::read ( Frame frame)

Read audio frame.

Implements roc::audio::IReader.

bool roc::audio::Depacketizer::started ( ) const

Did depacketizer catch first packet?

packet::timestamp_t roc::audio::Depacketizer::timestamp ( ) const

Get next timestamp to be rendered.

started() should return true

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