mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-22 02:40:26 +00:00
Reenable loopback connections for VRG
This commit is contained in:
@@ -1154,11 +1154,6 @@ int main(int argc, char *argv[])
|
||||
video_rxtx_mode |= MODE_SENDER;
|
||||
}
|
||||
|
||||
if (video_rxtx_mode & MODE_RECEIVER && video_rxtx_mode & MODE_SENDER) {
|
||||
LOG(LOG_LEVEL_ERROR) << "Combined sender and receiver not supported in VRG mode!\n";
|
||||
EXIT(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
if (video_rx_port == -1) {
|
||||
if ((video_rxtx_mode & MODE_RECEIVER) == 0) {
|
||||
// do not occupy recv port if we are not receiving (note that this disables communication with
|
||||
|
||||
@@ -1111,10 +1111,13 @@ struct rtp *rtp_init_if(const char *addr, const char *iface,
|
||||
session->send_rtcp_to_origin = false; // VRG
|
||||
|
||||
// VRG specific changes
|
||||
assert((rx_port == 0 || tx_port == 0));
|
||||
session->rtp_socket = udp_init_if(addr, iface, rx_port, tx_port, ttl, force_ip_version, multithreaded);
|
||||
uint16_t rtcp_rx_port = rx_port != 0 ? 0 : tx_port != 0 ? tx_port + 1 : 0;
|
||||
uint16_t rtcp_tx_port = (rx_port == 0 ? tx_port : rx_port) + 1;
|
||||
if (rx_port != 0 && tx_port != 0) {
|
||||
assert (rx_port == tx_port);
|
||||
rtcp_rx_port = rtcp_tx_port = rx_port + 1;
|
||||
}
|
||||
|
||||
session->rtcp_socket =
|
||||
udp_init_if(addr, iface, rtcp_rx_port, rtcp_tx_port, ttl, force_ip_version, false);
|
||||
|
||||
Reference in New Issue
Block a user