summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-07-18 13:16:59 +0200
committerwm4 <wm4@nowhere>2013-07-18 13:16:59 +0200
commit48789b354648b9892ec63dc91b91f7a3d5b588e4 (patch)
tree84853ab5b0d19f184222b4e750e5e083ae9ab8b4
parenta012e484dcc7ffc3f2b668774bbaee1d6e0586ad (diff)
downloadmpv-48789b354648b9892ec63dc91b91f7a3d5b588e4.tar.bz2
mpv-48789b354648b9892ec63dc91b91f7a3d5b588e4.tar.xz
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.)
-rw-r--r--video/filter/vf_scale.c11
1 files changed, 0 insertions, 11 deletions
diff --git a/video/filter/vf_scale.c b/video/filter/vf_scale.c
index 223c619fef..be2c336545 100644
--- a/video/filter/vf_scale.c
+++ b/video/filter/vf_scale.c
@@ -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));