From b18bfd0352cc1723ad9194a2cd31e263124e62b5 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 10 Apr 2016 16:29:33 +0200 Subject: aspect: remove useless debug messages Never needed them. This makes the code slightly more readable. --- video/out/aspect.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/video/out/aspect.c b/video/out/aspect.c index f3ba21c02e..178fd28724 100644 --- a/video/out/aspect.c +++ b/video/out/aspect.c @@ -26,28 +26,20 @@ #include "vo.h" #include "sub/osd.h" -static void aspect_calc_panscan(struct mp_log *log, struct mp_vo_opts *opts, +static void aspect_calc_panscan(struct mp_vo_opts *opts, int w, int h, int d_w, int d_h, int window_w, int window_h, double monitor_par, int *out_w, int *out_h) { - mp_dbg(log, "aspect(0) fitin: %dx%d monitor_par: %.2f\n", - window_w, window_h, monitor_par); int fwidth = window_w; int fheight = (float)window_w / d_w * d_h / monitor_par; - mp_dbg(log, "aspect(1) wh: %dx%d (org: %dx%d)\n", - fwidth, fheight, d_w, d_h); if (fheight > window_h || fheight < h) { int tmpw = (float)window_h / d_h * d_w * monitor_par; if (tmpw <= window_w) { fheight = window_h; fwidth = tmpw; - } else if (fheight > window_h) { - mp_warn(log, "No suitable new aspect found!\n"); } } - mp_dbg(log, "aspect(2) wh: %dx%d (org: %dx%d)\n", - fwidth, fheight, d_w, d_h); int vo_panscan_area = window_h - fheight; double f_w = fwidth / (double)fheight; @@ -153,7 +145,7 @@ void mp_get_src_dst_rects(struct mp_log *log, struct mp_vo_opts *opts, }; if (opts->keepaspect) { int scaled_width, scaled_height; - aspect_calc_panscan(log, opts, src_w, src_h, src_dw, src_dh, + aspect_calc_panscan(opts, src_w, src_h, src_dw, src_dh, window_w, window_h, monitor_par, &scaled_width, &scaled_height); src_dst_split_scaling(src_w, window_w, scaled_width, opts->unscaled, -- cgit v1.2.3