]> git.sesse.net Git - ffmpeg/blobdiff - doc/examples/filtering_audio.c
avformat/avformat, utils: Make av_find_best_stream const-correct
[ffmpeg] / doc / examples / filtering_audio.c
index b109dbcb96d70e747a80a40de9334309852924e8..508c19c60bfce641c9aeefc4fc625a6bf2432408 100644 (file)
@@ -48,8 +48,8 @@ static int audio_stream_index = -1;
 
 static int open_input_file(const char *filename)
 {
+    const AVCodec *dec;
     int ret;
-    AVCodec *dec;
 
     if ((ret = avformat_open_input(&fmt_ctx, filename, NULL, NULL)) < 0) {
         av_log(NULL, AV_LOG_ERROR, "Cannot open input file\n");
@@ -74,7 +74,6 @@ static int open_input_file(const char *filename)
     if (!dec_ctx)
         return AVERROR(ENOMEM);
     avcodec_parameters_to_context(dec_ctx, fmt_ctx->streams[audio_stream_index]->codecpar);
-    av_opt_set_int(dec_ctx, "refcounted_frames", 1, 0);
 
     /* init the audio decoder */
     if ((ret = avcodec_open2(dec_ctx, dec, NULL)) < 0) {