mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-21 06:40:15 +00:00
Server mode: support audio
This commit is contained in:
@@ -84,6 +84,7 @@
|
||||
#include "tv.h"
|
||||
#include "transmit.h"
|
||||
#include "pdb.h"
|
||||
#include "utils/net.h"
|
||||
#include "utils/thread.h"
|
||||
#include "utils/worker.h"
|
||||
|
||||
@@ -519,6 +520,9 @@ static struct rtp *initialize_audio_network(struct audio_network_parameters *par
|
||||
rtp_set_option(r, RTP_OPT_RECORD_SOURCE, TRUE);
|
||||
rtp_set_sdes(r, rtp_my_ssrc(r), RTCP_SDES_TOOL,
|
||||
PACKAGE_STRING, strlen(PACKAGE_VERSION));
|
||||
if (strcmp(params->addr, IN6_BLACKHOLE_STR) == 0) {
|
||||
rtp_set_option(r, RTP_OPT_SEND_BACK, TRUE);
|
||||
}
|
||||
rtp_set_recv_buf(r, DEFAULT_AUDIO_RECV_BUF_SIZE);
|
||||
}
|
||||
|
||||
|
||||
@@ -1121,6 +1121,9 @@ int main(int argc, char *argv[])
|
||||
if (strcmp(requested_display, "none") == 0) {
|
||||
requested_display = "dummy";
|
||||
}
|
||||
if (strcmp(audio_recv, "none") == 0) {
|
||||
audio_recv = "dummy";
|
||||
}
|
||||
}
|
||||
if (is_client) {
|
||||
commandline_params["udp-disable-multi-socket"] = string();
|
||||
@@ -1131,6 +1134,10 @@ int main(int argc, char *argv[])
|
||||
if (strcmp("none", vidcap_params_get_driver(vidcap_params_head)) == 0) {
|
||||
vidcap_params_set_device(vidcap_params_tail, "testcard:2:1:5:UYVY");
|
||||
}
|
||||
if (strcmp("none", audio_send) == 0) {
|
||||
parse_audio_capture_format("sample_rate=5");
|
||||
audio_send = "testcard:frames=1";
|
||||
}
|
||||
}
|
||||
|
||||
if (!audio_host) {
|
||||
|
||||
Reference in New Issue
Block a user