[FFmpeg-cvslog] scale: fix computation for the "hsub" and "vsub" constants
Stefano Sabatini
git at videolan.org
Sun Apr 17 17:40:46 CEST 2011
ffmpeg | branch: master | Stefano Sabatini <stefano.sabatini-lala at poste.it> | Sun Apr 17 16:26:53 2011 +0200| [e93d3334a94ed6d23380bd421c9bfe8984785c07] | committer: Stefano Sabatini
scale: fix computation for the "hsub" and "vsub" constants
Signed-off-by: Stefano Sabatini <stefano.sabatini-lala at poste.it>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e93d3334a94ed6d23380bd421c9bfe8984785c07
---
libavfilter/vf_scale.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c
index adebdee..1e8a194 100644
--- a/libavfilter/vf_scale.c
+++ b/libavfilter/vf_scale.c
@@ -158,8 +158,8 @@ static int config_props(AVFilterLink *outlink)
var_values[VAR_OUT_W] = var_values[VAR_OW] = NAN;
var_values[VAR_OUT_H] = var_values[VAR_OH] = NAN;
var_values[VAR_A] = (float) inlink->w / inlink->h;
- var_values[VAR_HSUB] = 2<<av_pix_fmt_descriptors[inlink->format].log2_chroma_w;
- var_values[VAR_VSUB] = 2<<av_pix_fmt_descriptors[inlink->format].log2_chroma_h;
+ var_values[VAR_HSUB] = 1<<av_pix_fmt_descriptors[inlink->format].log2_chroma_w;
+ var_values[VAR_VSUB] = 1<<av_pix_fmt_descriptors[inlink->format].log2_chroma_h;
/* evaluate width and height */
av_expr_parse_and_eval(&res, (expr = scale->w_expr),
More information about the ffmpeg-cvslog
mailing list