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

Audio frame. More...

#include <frame.h>

Inheritance diagram for roc::audio::Frame:
Collaboration diagram for roc::audio::Frame:

Public Types

enum  { FlagBlank = (1 << 0), FlagIncomplete = (1 << 1), FlagDrops = (1 << 2) }
 Frame flags. More...

Public Member Functions

 Frame (sample_t *data, size_t size)
 Construct frame from samples. More...
void set_flags (unsigned flags)
 Set flags. More...
unsigned flags () const
 Get flags. More...
sample_tdata () const
 Get frame data. More...
size_t size () const
 Get frame data size. More...

Detailed Description

Audio frame.

Definition at line 22 of file frame.h.

Member Enumeration Documentation

anonymous enum

Frame flags.


Set if the frame is fully filled with zeros instead of data from packets.


Set if the frame is partially filled with zeros instead of data from packets.


Set if some late packets were dropped while the frame was being built.

Definition at line 30 of file frame.h.

Constructor & Destructor Documentation

roc::audio::Frame::Frame ( sample_t data,
size_t  size 

Construct frame from samples.

The pointer is saved in the frame, no copying is performed.

Member Function Documentation

sample_t* roc::audio::Frame::data ( ) const

Get frame data.

unsigned roc::audio::Frame::flags ( ) const

Get flags.

void roc::audio::Frame::set_flags ( unsigned  flags)

Set flags.

size_t roc::audio::Frame::size ( ) const

Get frame data size.

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