Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
|
RTCP session. Processes incoming RTCP packets and generates outgoing RTCP packets. More...
#include <session.h>
Public Member Functions | |
Session (IReceiverHooks *recv_hooks, ISenderHooks *send_hooks, packet::IWriter *packet_writer, packet::IComposer &packet_composer, packet::PacketFactory &packet_factory, core::BufferFactory< uint8_t > &buffer_factory) | |
Initialize. More... | |
bool | is_valid () const |
Check if initialization succeeded. More... | |
ROC_ATTR_NODISCARD status::StatusCode | process_packet (const packet::PacketPtr &packet) |
Parse and process incoming packet. Invokes session hooks methods during processing. More... | |
core::nanoseconds_t | generation_deadline (core::nanoseconds_t current_time) |
When we should generate packets next time. Returns absolute time. current_time is current time in nanoseconds since Unix epoch. More... | |
status::StatusCode ROC_ATTR_NODISCARD | generate_packets (core::nanoseconds_t current_time) |
Generate and send packet(s). Should be called accroding to generation_deadline(). current_time is current time in nanoseconds since Unix epoch. More... | |
RTCP session. Processes incoming RTCP packets and generates outgoing RTCP packets.
roc::rtcp::Session::Session | ( | IReceiverHooks * | recv_hooks, |
ISenderHooks * | send_hooks, | ||
packet::IWriter * | packet_writer, | ||
packet::IComposer & | packet_composer, | ||
packet::PacketFactory & | packet_factory, | ||
core::BufferFactory< uint8_t > & | buffer_factory | ||
) |
Initialize.
status::StatusCode ROC_ATTR_NODISCARD roc::rtcp::Session::generate_packets | ( | core::nanoseconds_t | current_time | ) |
Generate and send packet(s). Should be called accroding to generation_deadline(). current_time
is current time in nanoseconds since Unix epoch.
core::nanoseconds_t roc::rtcp::Session::generation_deadline | ( | core::nanoseconds_t | current_time | ) |
When we should generate packets next time. Returns absolute time. current_time
is current time in nanoseconds since Unix epoch.
bool roc::rtcp::Session::is_valid | ( | ) | const |
Check if initialization succeeded.
ROC_ATTR_NODISCARD status::StatusCode roc::rtcp::Session::process_packet | ( | const packet::PacketPtr & | packet | ) |
Parse and process incoming packet. Invokes session hooks methods during processing.