mirror of https://github.com/mpv-player/mpv
vf_scale: remove rounding of sizes to 2 with 4:2:0
libswscale doesn't seem to require this (anymore?), and libavfiltert's vf_scale doesn't do it either. Moreover, this wasn't done for most other subsampled formats, not even very old ones. So just remove it. (It'd be quite easy to align on chroma boundaries with all pixel formats, though.)
This commit is contained in:
parent
a012e484dc
commit
48789b3546
|
@ -297,17 +297,6 @@ static int reconfig(struct vf_instance *vf, struct mp_image_params *p, int flags
|
|||
}
|
||||
}
|
||||
|
||||
// calculate the missing parameters:
|
||||
switch (best) {
|
||||
case IMGFMT_420P: /* YV12 needs w & h rounded to 2 */
|
||||
case IMGFMT_NV12:
|
||||
case IMGFMT_NV21:
|
||||
vf->priv->h = (vf->priv->h + 1) & ~1;
|
||||
case IMGFMT_YUYV: /* YUY2 needs w rounded to 2 */
|
||||
case IMGFMT_UYVY:
|
||||
vf->priv->w = (vf->priv->w + 1) & ~1;
|
||||
}
|
||||
|
||||
mp_msg(MSGT_VFILTER, MSGL_DBG2, "SwScale: scaling %dx%d %s to %dx%d %s \n",
|
||||
width, height, vo_format_name(outfmt), vf->priv->w, vf->priv->h,
|
||||
vo_format_name(best));
|
||||
|
|
Loading…
Reference in New Issue