diff --git a/codec-cfg.c b/codec-cfg.c index b36ecfc50f..8315ef7cf2 100644 --- a/codec-cfg.c +++ b/codec-cfg.c @@ -155,6 +155,7 @@ static int add_to_format(char *s, char *alias,unsigned int *fourcc, unsigned int {"444P", IMGFMT_444P}, {"422P", IMGFMT_422P}, {"411P", IMGFMT_411P}, + {"440P", IMGFMT_440P}, {"Y800", IMGFMT_Y800}, {"Y8", IMGFMT_Y8}, diff --git a/fmt-conversion.c b/fmt-conversion.c index 06699c6ee5..14a1f2df6f 100644 --- a/fmt-conversion.c +++ b/fmt-conversion.c @@ -58,6 +58,7 @@ static const struct { {IMGFMT_411P, PIX_FMT_YUV411P}, {IMGFMT_422P, PIX_FMT_YUV422P}, {IMGFMT_444P, PIX_FMT_YUV444P}, + {IMGFMT_440P, PIX_FMT_YUV440P}, // YUVJ are YUV formats that use the full Y range and not just // 16 - 235 (see colorspaces.txt). @@ -65,6 +66,7 @@ static const struct { {IMGFMT_YV12, PIX_FMT_YUVJ420P}, {IMGFMT_422P, PIX_FMT_YUVJ422P}, {IMGFMT_444P, PIX_FMT_YUVJ444P}, + {IMGFMT_440P, PIX_FMT_YUVJ440P}, {IMGFMT_XVMC_MOCO_MPEG2, PIX_FMT_XVMC_MPEG2_MC}, {IMGFMT_XVMC_IDCT_MPEG2, PIX_FMT_XVMC_MPEG2_IDCT}, diff --git a/libmpcodecs/img_format.c b/libmpcodecs/img_format.c index d4f4d59f38..bfdcf91b64 100644 --- a/libmpcodecs/img_format.c +++ b/libmpcodecs/img_format.c @@ -108,6 +108,10 @@ int mp_get_chroma_shift(int format, int *x_shift, int *y_shift) xs = 2; ys = 0; break; + case IMGFMT_440P: + xs = 0; + ys = 1; + break; default: err = 1; break; diff --git a/libmpcodecs/img_format.h b/libmpcodecs/img_format.h index 56d96c481a..bcbdf0b56e 100644 --- a/libmpcodecs/img_format.h +++ b/libmpcodecs/img_format.h @@ -71,6 +71,7 @@ #define IMGFMT_444P 0x50343434 #define IMGFMT_422P 0x50323234 #define IMGFMT_411P 0x50313134 +#define IMGFMT_440P 0x50303434 #define IMGFMT_HM12 0x32314D48 /* Packed YUV Formats */ diff --git a/libmpcodecs/mp_image.h b/libmpcodecs/mp_image.h index cfc42f81e7..bd750de9ca 100644 --- a/libmpcodecs/mp_image.h +++ b/libmpcodecs/mp_image.h @@ -151,6 +151,7 @@ static inline void mp_image_setfmt(mp_image_t* mpi,unsigned int out_fmt){ case IMGFMT_444P: case IMGFMT_422P: case IMGFMT_411P: + case IMGFMT_440P: return; case IMGFMT_Y800: case IMGFMT_Y8: diff --git a/m_option.c b/m_option.c index db45e3c242..752a7f1330 100644 --- a/m_option.c +++ b/m_option.c @@ -1035,6 +1035,7 @@ static struct { {"444p", IMGFMT_444P}, {"422p", IMGFMT_422P}, {"411p", IMGFMT_411P}, + {"440p", IMGFMT_440P}, {"yuy2", IMGFMT_YUY2}, {"uyvy", IMGFMT_UYVY}, {"yvu9", IMGFMT_YVU9},