aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2024-03-25 02:36:54 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2024-03-28 03:08:00 +0100
commit8013574e9b4a52c28f896655bae235244d139801 (patch)
tree264a5d056e040810effbd95ecaee3bcf9a1c1394
parent0b212f359571c7e967c292c399ebfad8d3c6c642 (diff)
downloadffmpeg-8013574e9b4a52c28f896655bae235244d139801.tar.gz
avcodec/mjpegenc: Inline chroma subsampling
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r--libavcodec/mjpegenc.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/libavcodec/mjpegenc.c b/libavcodec/mjpegenc.c
index 521c9e8aff..c8cb2207e3 100644
--- a/libavcodec/mjpegenc.c
+++ b/libavcodec/mjpegenc.c
@@ -32,8 +32,6 @@
#include "config_components.h"
-#include "libavutil/pixdesc.h"
-
#include "avcodec.h"
#include "codec_internal.h"
#include "jpegtables.h"
@@ -595,9 +593,7 @@ static int amv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
MpegEncContext *s = avctx->priv_data;
AVFrame *pic;
int i, ret;
- int chroma_h_shift, chroma_v_shift;
-
- av_pix_fmt_get_chroma_sub_sample(avctx->pix_fmt, &chroma_h_shift, &chroma_v_shift);
+ int chroma_v_shift = 1; /* AMV is 420-only */
if ((avctx->height & 15) && avctx->strict_std_compliance > FF_COMPLIANCE_UNOFFICIAL) {
av_log(avctx, AV_LOG_ERROR,