summaryrefslogtreecommitdiffstats
path: root/video/img_format.c
diff options
context:
space:
mode:
Diffstat (limited to 'video/img_format.c')
-rw-r--r--video/img_format.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/video/img_format.c b/video/img_format.c
index f717ff9c1e..5451dd9ad1 100644
--- a/video/img_format.c
+++ b/video/img_format.c
@@ -249,6 +249,9 @@ struct mp_imgfmt_desc mp_imgfmt_get_desc(int mpfmt)
desc.plane_bits = 8; // usually restricted to 8 bit; may change
}
+ if (desc.chroma_xs || desc.chroma_ys)
+ desc.flags |= MP_IMGFLAG_SUBSAMPLED;
+
return desc;
}