<div dir="ltr">I have more debug output.  Now I am trying to read AMR frames and encode them to AAC. AMR sample format after decoding frame is <span style="font-size:12.8000001907349px">AV_SAMPLE_FMT_FLT. Audio stream in video file has sample format set to </span><span style="font-size:12.8000001907349px">AV_SAMPLE_FMT_FLT as well. But these data is encoded as AAC. I see that AAC has </span><span style="font-size:12.8000001907349px">AV_SAMPLE_FMT_FLTP sample format. Do I have to resample AMR samples from </span><span style="font-size:12.8000001907349px">AV_SAMPLE_FMT_FLT to </span><span style="font-size:12.8000001907349px">AV_SAMPLE_FMT_FLTP before encoding to AAC?</span></div><div class="gmail_extra"><br><div class="gmail_quote">On 1 July 2015 at 10:40, adev dev <span dir="ltr"><<a href="mailto:androiddevmar11@gmail.com" target="_blank">androiddevmar11@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><span style="font-size:12.8000001907349px">I am compressing movies from bitmaps and audio files. With AAC files it is working correctly. But when I have AMR_WB files sound is corrupted. I can recognise correct words in video file but it is delayed and with very bad quality.</span><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">My AMR files are recorded with parameters:</span><div><div><span style="font-size:12.8000001907349px">- sampling rate: 16000,</span></div><div><span style="font-size:12.8000001907349px">- bitrate: 23000.</span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">I am setting this parameters in audio stream which is added to video. Sample format is set to </span>AV_SAMPLE_FMT_FLT. When using other formats app crashes with "Unsupported sample format". </div><div><br></div><div>What needs to be done to correctly add AMR stream to video file? Do I have to reencode it to AAC and add as AAC audio stream?? Thank you for all hints.</div></div></div></div>
</blockquote></div><br></div>