summaryrefslogtreecommitdiff
path: root/src/rexmpp.c
diff options
context:
space:
mode:
authordefanor <defanor@uberspace.net>2023-09-21 19:45:44 +0300
committerdefanor <defanor@uberspace.net>2023-09-21 19:45:44 +0300
commit4ea2ee3870d95b6d95c8e9c7c08277bc9d34d5e0 (patch)
tree70c0c2d4b2965a2d12edbad5ae6b391066692d76 /src/rexmpp.c
parent27999bd847c95bc85b3e860684fed794867677b4 (diff)
Handle audio I/O, codecs, and RTP for Jingle calls
Diffstat (limited to 'src/rexmpp.c')
-rw-r--r--src/rexmpp.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/rexmpp.c b/src/rexmpp.c
index beb2762..8674b7d 100644
--- a/src/rexmpp.c
+++ b/src/rexmpp.c
@@ -561,27 +561,19 @@ rexmpp_err_t rexmpp_init (rexmpp_t *s,
s->last_network_activity.tv_nsec = 0;
s->disco_info = NULL;
- /* The default description. Since the players and streamers are
- external for now, this may be adjusted by an application or a
- user. */
s->jingle_rtp_description =
rexmpp_xml_new_elem("description", "urn:xmpp:jingle:apps:rtp:1");
rexmpp_xml_add_attr(s->jingle_rtp_description, "media", "audio");
rexmpp_xml_t *pl_type;
+#ifdef HAVE_OPUS
pl_type = rexmpp_xml_new_elem("payload-type", "urn:xmpp:jingle:apps:rtp:1");
rexmpp_xml_add_attr(pl_type, "id", "97");
rexmpp_xml_add_attr(pl_type, "name", "opus");
rexmpp_xml_add_attr(pl_type, "clockrate", "48000");
rexmpp_xml_add_attr(pl_type, "channels", "2");
rexmpp_xml_add_child(s->jingle_rtp_description, pl_type);
-
- pl_type = rexmpp_xml_new_elem("payload-type", "urn:xmpp:jingle:apps:rtp:1");
- rexmpp_xml_add_attr(pl_type, "id", "96");
- rexmpp_xml_add_attr(pl_type, "name", "speex");
- rexmpp_xml_add_attr(pl_type, "clockrate", "32000");
- rexmpp_xml_add_attr(pl_type, "channels", "1");
- rexmpp_xml_add_child(s->jingle_rtp_description, pl_type);
+#endif
pl_type = rexmpp_xml_new_elem("payload-type", "urn:xmpp:jingle:apps:rtp:1");
rexmpp_xml_add_attr(pl_type, "id", "0");