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

Receiver decoder node. More...

#include <receiver_decoder.h>

Inheritance diagram for roc::node::ReceiverDecoder:
Collaboration diagram for roc::node::ReceiverDecoder:

Public Types

typedef void(* sess_metrics_func_t) (const pipeline::ReceiverSessionMetrics &sess_metrics, size_t sess_index, void *sess_arg)
 Callback for getting session metrics. More...
 

Public Member Functions

 ReceiverDecoder (Context &context, const pipeline::ReceiverConfig &pipeline_config)
 Initialize. More...
 
 ~ReceiverDecoder ()
 Deinitialize. More...
 
bool is_valid ()
 Check if successfully constructed. More...
 
bool activate (address::Interface iface, address::Protocol proto)
 Activate interface. More...
 
bool get_metrics (pipeline::ReceiverSlotMetrics &slot_metrics, sess_metrics_func_t sess_metrics_func, size_t *sess_metrics_size, void *sess_metrics_arg)
 Get metrics. More...
 
ROC_ATTR_NODISCARD status::StatusCode write (address::Interface iface, const packet::PacketPtr &packet)
 Write packet for decoding. More...
 
sndio::ISourcesource ()
 Source for reading decoded frames. More...
 
- Public Member Functions inherited from roc::node::Node
 Node (Context &context)
 Initialize. More...
 
virtual ~Node ()
 Deinitialize. More...
 
Contextcontext ()
 All nodes hold reference to context. More...
 

Detailed Description

Receiver decoder node.

Definition at line 29 of file receiver_decoder.h.

Member Typedef Documentation

◆ sess_metrics_func_t

typedef void(* roc::node::ReceiverDecoder::sess_metrics_func_t) (const pipeline::ReceiverSessionMetrics &sess_metrics, size_t sess_index, void *sess_arg)

Callback for getting session metrics.

Definition at line 44 of file receiver_decoder.h.

Constructor & Destructor Documentation

◆ ReceiverDecoder()

roc::node::ReceiverDecoder::ReceiverDecoder ( Context context,
const pipeline::ReceiverConfig pipeline_config 
)

Initialize.

◆ ~ReceiverDecoder()

roc::node::ReceiverDecoder::~ReceiverDecoder ( )

Deinitialize.

Member Function Documentation

◆ activate()

bool roc::node::ReceiverDecoder::activate ( address::Interface  iface,
address::Protocol  proto 
)

Activate interface.

◆ get_metrics()

bool roc::node::ReceiverDecoder::get_metrics ( pipeline::ReceiverSlotMetrics slot_metrics,
sess_metrics_func_t  sess_metrics_func,
size_t *  sess_metrics_size,
void *  sess_metrics_arg 
)

Get metrics.

Remarks
Metrics for slot are written into slot_metrics. Metrics for each session are passed to sess_metrics_func.

◆ is_valid()

bool roc::node::ReceiverDecoder::is_valid ( )

Check if successfully constructed.

◆ source()

sndio::ISource& roc::node::ReceiverDecoder::source ( )

Source for reading decoded frames.

◆ write()

ROC_ATTR_NODISCARD status::StatusCode roc::node::ReceiverDecoder::write ( address::Interface  iface,
const packet::PacketPtr packet 
)

Write packet for decoding.


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