RtmsSender class.
More...
#include <rtmsSender.hpp>
RtmsSender class.
This class is used to send RTMS samples including the IFW RTMS Extended Info. It is based on the llnetio library. It is expected that the Extended Info of the Leader packet contains the following information:
<ext info> ::= <timestamp (seconds since epoch)>
All fields shall have type int32_t.
◆ RtmsSender()
| ifw::rtmslib::RtmsSender::RtmsSender |
( |
const std::string & | src_ip, |
|
|
const std::string & | dest_ip, |
|
|
const int | dest_port, |
|
|
const int8_t | bytes_per_pixel, |
|
|
const size_t | raw_image_size, |
|
|
const SenderConfig & | sndr_cfg = SenderConfig() ) |
Simple RTMS Sender class.
- Parameters
-
| src_ip | Source IPv4 address to bind the UDP socket. |
| dest_ip | Destination IPv4 address (unicast or multicast) for outgoing packets. |
| dest_port | Destination UDP port for outgoing packets. |
| data_type | Type of pixels sent. |
| pixels_per_sample | Number of pixels per image. |
| sndr_cfg | Additional sender configuration. |
◆ ~RtmsSender()
| ifw::rtmslib::RtmsSender::~RtmsSender |
( |
| ) |
|
|
virtual |
◆ GetPixelsPerSample()
| int ifw::rtmslib::RtmsSender::GetPixelsPerSample |
( |
| ) |
const |
◆ SendSample()
| int ifw::rtmslib::RtmsSender::SendSample |
( |
const SampleExtInfo & | ext_info, |
|
|
const std::vector< uint8_t > & | sample_payload ) |
User provided method to send an image as an RTMS Sample.
- Parameters
-
| ext_info | Extended Header Info. |
| sample_payload | Image data to send. |
- Returns
- 0 in case of success. Non-zero if the sample was dropped (e.g. connection refused); internal sender state is reset so the next sample can proceed.
◆ m_sample_id
| uint32_t ifw::rtmslib::RtmsSender::m_sample_id |
The documentation for this class was generated from the following files: