printf("Audio decoding\n");
- /* set end of buffer to 0 (this ensures that no overreading happens for damaged mpeg streams) */
- memset(inbuf + INBUF_SIZE, 0, FF_INPUT_BUFFER_PADDING_SIZE);
-
/* find the mpeg audio decoder */
codec = avcodec_find_decoder(CODEC_ID_MP2);
if (!codec) {
exit(1);
}
- /* the codec gives us the frame size, in samples */
-
f = fopen(filename, "wb");
if (!f) {
fprintf(stderr, "could not open %s\n", filename);