2012/2/24 Pavel Sokolov <[email protected]>:
> Hi All!
>
> I need to get LPCM data from ac3, to add it later to MPEG2 PES packet.
> I'm using "avcodec_decode_audio4" to decode ac3 packet.
> In which format the resulting AVFrame structure stores data?

The decoded audio data format can be checked in AVFrame.format, and
also AVCodecContext.sample_fmt. For audio, check it with enum
AVSampleFormat. Sample rate is in AVCodecContext.sample_rate.

> Is it in LPCM
> format or something else format?

The most widely used is AV_SAMPLE_FMT_S16, which stands for signed
16bit samples. So the answer is practically yes.

-- 
Andrey Utkin
_______________________________________________
Libav-user mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/libav-user

Reply via email to