vlc | branch: master | Andrey Utkin <[email protected]> | Sun Dec 8 04:25:29 2013 +0200| [124e58dde55f5222c6c05ebdc9eab6e4b2ecc79c] | committer: Jean-Baptiste Kempf
Enable OPUS RTP packetization Signed-off-by: Jean-Baptiste Kempf <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=124e58dde55f5222c6c05ebdc9eab6e4b2ecc79c --- modules/stream_out/rtpfmt.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/modules/stream_out/rtpfmt.c b/modules/stream_out/rtpfmt.c index aa4bcb1..94480a4 100644 --- a/modules/stream_out/rtpfmt.c +++ b/modules/stream_out/rtpfmt.c @@ -501,6 +501,21 @@ int rtp_get_fmt( vlc_object_t *obj, es_format_t *p_fmt, const char *mux, rtp_fmt->ptname = "GSM"; rtp_fmt->pf_packetize = rtp_packetize_split; break; + case VLC_CODEC_OPUS: + if (p_fmt->audio.i_channels > 2) + { + msg_Err( obj, "Multistream opus not supported in RTP" + " (having %d channels input)", + p_fmt->audio.i_channels ); + return VLC_EGENERIC; + } + rtp_fmt->ptname = "opus"; + rtp_fmt->pf_packetize = rtp_packetize_split; + rtp_fmt->clock_rate = 48000; + rtp_fmt->channels = 2; + if (p_fmt->audio.i_channels == 2) + rtp_fmt->fmtp = strdup( "sprop-stereo=1" ); + break; default: msg_Err( obj, "cannot add this stream (unsupported " _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
