]> git.sesse.net Git - ffmpeg/commitdiff
lavf/movenc: Write G.726 bitrate to make the files decodable.
authorCarl Eugen Hoyos <cehoyos@ag.or.at>
Sun, 2 Nov 2014 23:38:13 +0000 (00:38 +0100)
committerCarl Eugen Hoyos <cehoyos@ag.or.at>
Sun, 2 Nov 2014 23:38:13 +0000 (00:38 +0100)
Fixes ticket #4069.

libavformat/movenc.c

index 974edea46245bd073cf4402f1742e8caa0407510..b9576dc1f8e1c552e2a827b9d138fd65dce0c881 100644 (file)
@@ -938,6 +938,8 @@ static int mov_write_audio_tag(AVIOContext *pb, MOVTrack *track)
             if (track->enc->codec_id == AV_CODEC_ID_PCM_U8 ||
                 track->enc->codec_id == AV_CODEC_ID_PCM_S8)
                 avio_wb16(pb, 8); /* bits per sample */
+            else if (track->enc->codec_id == AV_CODEC_ID_ADPCM_G726)
+                avio_wb16(pb, track->enc->bits_per_coded_sample);
             else
                 avio_wb16(pb, 16);
             avio_wb16(pb, track->audio_vbr ? -2 : 0); /* compression ID */