[FFmpeg-cvslog] avcodec/mjpegenc: disable unused code with AMV

Davinder Singh git at videolan.org
Fri Aug 11 05:30:06 EEST 2017


ffmpeg | branch: master | Davinder Singh <ds.mudhar at gmail.com> | Thu Aug 10 07:26:34 2017 +0530| [1939b9030642106a5f75d7d2cfd1ec5208bea0ab] | committer: Michael Niedermayer

avcodec/mjpegenc: disable unused code with AMV

disable unused amv_encode_picture() when AMV encoder is not configured.

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1939b9030642106a5f75d7d2cfd1ec5208bea0ab
---

 libavcodec/mjpegenc.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/mjpegenc.c b/libavcodec/mjpegenc.c
index ee77cde8cb..9c3f863f6c 100644
--- a/libavcodec/mjpegenc.c
+++ b/libavcodec/mjpegenc.c
@@ -346,6 +346,7 @@ void ff_mjpeg_encode_mb(MpegEncContext *s, int16_t block[12][64])
     }
 }
 
+#if CONFIG_AMV_ENCODER
 // maximum over s->mjpeg_vsample[i]
 #define V_MAX 2
 static int amv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
@@ -387,6 +388,7 @@ static int amv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
     av_frame_free(&pic);
     return ret;
 }
+#endif
 
 #define OFFSET(x) offsetof(MpegEncContext, x)
 #define VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM



More information about the ffmpeg-cvslog mailing list