diff options
author | Martin Storsjö <martin@martin.st> | 2011-11-30 23:11:50 +0200 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2011-12-01 23:19:25 +0200 |
commit | 04403ec2e405a3cfcfbdd45f1274be30c652e462 (patch) | |
tree | fe21c357be17e094ec500dc1daae7fb13bb95156 /libavformat/rtpenc.c | |
parent | fa6dce4c572fd52266201f1c9d83d26bc662bf56 (diff) | |
download | ffmpeg-04403ec2e405a3cfcfbdd45f1274be30c652e462.tar.gz |
rtpenc: Add support for G726 audio
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat/rtpenc.c')
-rw-r--r-- | libavformat/rtpenc.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libavformat/rtpenc.c b/libavformat/rtpenc.c index 7434837a02..1f036a6baf 100644 --- a/libavformat/rtpenc.c +++ b/libavformat/rtpenc.c @@ -72,6 +72,7 @@ static int is_supported(enum CodecID id) case CODEC_ID_THEORA: case CODEC_ID_VP8: case CODEC_ID_ADPCM_G722: + case CODEC_ID_ADPCM_G726: return 1; default: return 0; @@ -411,6 +412,10 @@ static int rtp_write_packet(AVFormatContext *s1, AVPacket *pkt) * clock. */ rtp_send_samples(s1, pkt->data, size, 8 * st->codec->channels); break; + case CODEC_ID_ADPCM_G726: + rtp_send_samples(s1, pkt->data, size, + st->codec->bits_per_coded_sample * st->codec->channels); + break; case CODEC_ID_MP2: case CODEC_ID_MP3: rtp_send_mpegaudio(s1, pkt->data, size); |