[FFmpeg-devel] [PATCH] examples/muxing: drop duplicated code in add_video_stream()

Stefano Sabatini stefasab at gmail.com
Fri Aug 3 18:04:31 CEST 2012


---
 doc/examples/muxing.c |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/doc/examples/muxing.c b/doc/examples/muxing.c
index ca5e107..4e62b87 100644
--- a/doc/examples/muxing.c
+++ b/doc/examples/muxing.c
@@ -203,12 +203,6 @@ static AVStream *add_video_stream(AVFormatContext *oc, enum CodecID codec_id)
 
     c = st->codec;
 
-    /* find the video encoder */
-    codec = avcodec_find_encoder(codec_id);
-    if (!codec) {
-        fprintf(stderr, "codec not found\n");
-        exit(1);
-    }
     avcodec_get_context_defaults3(c, codec);
 
     c->codec_id = codec_id;
-- 
1.7.5.4



More information about the ffmpeg-devel mailing list