Loopback transport for testing.
More...
This is the loopback media transport, where packets sent to this transport will be sent back to the streams attached to this transport. Unlike the other PJMEDIA transports, the loop transport may be attached to multiple streams (in other words, application should specify the same loop transport instance when calling pjmedia_stream_create()). Any RTP or RTCP packets sent by one stream to this transport by default will be sent back to all streams that are attached to this transport, including to the stream that sends the packet. Application may individually select which stream to receive packets by calling pjmedia_transport_loop_disable_rx().
◆ pjmedia_loop_tp_setting_default()
Initialize loopback media transport setting with its default values.
- Parameters
-
opt | SRTP setting to be initialized. |
◆ pjmedia_transport_loop_create()
Create the loopback transport.
- Parameters
-
endpt | The media endpoint instance. |
p_tp | Pointer to receive the transport instance. |
- Returns
- PJ_SUCCESS on success.
◆ pjmedia_transport_loop_create2()
Create the loopback transport.
- Parameters
-
endpt | The media endpoint instance. |
opt | Optional settings. If NULL is given, default settings will be used. |
p_tp | Pointer to receive the transport instance. |
- Returns
- PJ_SUCCESS on success.
◆ pjmedia_transport_loop_disable_rx()
Set the configuration of whether a stream will become the receiver of incoming packets.
- Parameters
-
tp | The transport. |
user | The stream. |
disabled | PJ_TRUE to disable the receiving of packets, or PJ_FALSE to enable it. |