Browse Source

lavfi/scale: allocate interlaced scalers only if needed.

Fix "Value 0.000000 for parameter 'srch' out of range"
error message when source or destination height is 1.

Note: since the av_opt_set_int() calls are not checked for
failure and the interlaced scalers are not actually used,
this error has no consequence apart from a frightening message
in the log.
tags/n2.1
Nicolas George 12 years ago
parent
commit
ebaf20e94b
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      libavfilter/vf_scale.c

+ 2
- 0
libavfilter/vf_scale.c View File

@@ -287,6 +287,8 @@ static int config_props(AVFilterLink *outlink)


if ((ret = sws_init_context(*s, NULL, NULL)) < 0) if ((ret = sws_init_context(*s, NULL, NULL)) < 0)
return ret; return ret;
if (!scale->interlaced)
break;
} }
} }




Loading…
Cancel
Save