summaryrefslogtreecommitdiff
path: root/libavfilter/vf_scale.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2021-07-06 10:17:06 +0200
committerAnton Khirnov <anton@khirnov.net>2021-08-29 18:44:54 +0200
commitca32d0462cd9a2d161be036fc45dc429013d0840 (patch)
tree5dbc7c0163c375762f25d83eb1cbe93283c1d92e /libavfilter/vf_scale.c
parent03f3680080639b7569c41fdd43b16feaf40dc094 (diff)
lavfi/vf_scale: remove the nb_slices option
It was intended for debugging only and has been superseded by the standalone tool for testing sliced scaling.
Diffstat (limited to 'libavfilter/vf_scale.c')
-rw-r--r--libavfilter/vf_scale.c14
1 files changed, 0 insertions, 14 deletions
diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c
index 7ca833bbb1..909080b829 100644
--- a/libavfilter/vf_scale.c
+++ b/libavfilter/vf_scale.c
@@ -148,8 +148,6 @@ typedef struct ScaleContext {
int force_original_aspect_ratio;
int force_divisible_by;
- int nb_slices;
-
int eval_mode; ///< expression evaluation mode
} ScaleContext;
@@ -802,17 +800,6 @@ scale:
ret = scale_slice(scale, out, in, scale->isws[0], 0, (link->h+1)/2, 2, 0);
if (ret >= 0)
ret = scale_slice(scale, out, in, scale->isws[1], 0, link->h /2, 2, 1);
- } else if (scale->nb_slices) {
- int i, slice_h, slice_start, slice_end = 0;
- const int nb_slices = FFMIN(scale->nb_slices, link->h);
- for (i = 0; i < nb_slices; i++) {
- slice_start = slice_end;
- slice_end = (link->h * (i+1)) / nb_slices;
- slice_h = slice_end - slice_start;
- ret = scale_slice(scale, out, in, scale->sws, slice_start, slice_h, 1, 0);
- if (ret < 0)
- break;
- }
} else {
ret = scale_slice(scale, out, in, scale->sws, 0, link->h, 1, 0);
}
@@ -944,7 +931,6 @@ static const AVOption scale_options[] = {
{ "force_divisible_by", "enforce that the output resolution is divisible by a defined integer when force_original_aspect_ratio is used", OFFSET(force_divisible_by), AV_OPT_TYPE_INT, { .i64 = 1}, 1, 256, FLAGS },
{ "param0", "Scaler param 0", OFFSET(param[0]), AV_OPT_TYPE_DOUBLE, { .dbl = SWS_PARAM_DEFAULT }, INT_MIN, INT_MAX, FLAGS },
{ "param1", "Scaler param 1", OFFSET(param[1]), AV_OPT_TYPE_DOUBLE, { .dbl = SWS_PARAM_DEFAULT }, INT_MIN, INT_MAX, FLAGS },
- { "nb_slices", "set the number of slices (debug purpose only)", OFFSET(nb_slices), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, FLAGS },
{ "eval", "specify when to evaluate expressions", OFFSET(eval_mode), AV_OPT_TYPE_INT, {.i64 = EVAL_MODE_INIT}, 0, EVAL_MODE_NB-1, FLAGS, "eval" },
{ "init", "eval expressions once during initialization", 0, AV_OPT_TYPE_CONST, {.i64=EVAL_MODE_INIT}, .flags = FLAGS, .unit = "eval" },
{ "frame", "eval expressions during initialization and per-frame", 0, AV_OPT_TYPE_CONST, {.i64=EVAL_MODE_FRAME}, .flags = FLAGS, .unit = "eval" },