문제

I am using libav along with libfaac to encode audio into aac. following is the logic:

frames[n]
i = 0 ;
while (there are frames)
{ 
  cur_frame =  frames[i];
  av_encode_audio(frame, ...., &frame_finished);
  if( frame_finished )
  {
     i++;
  }
}

but I am getting this annoying warning for few frames "queue input is backward in time !"

도움이 되었습니까?

해결책

The answer is very simple, you are not supposed to pass the same frame again to the libfaac, so even if the frame_finished is not 1 you should still go to the next frame.

it should be as follows:

frames[n]
i = 0 ;
while (there are frames)
{ 
  cur_frame =  frames[i];
  av_encode_audio(frame, ...., &frame_finished);
  i++;
}
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top