Commit 27fe8930 authored by Steven Liu's avatar Steven Liu

avfilter: add comments for duplicate line

comment about the looks like a duplicate line.
but that is used to reason x is expressed from y

Suggested-by: Paul B Mahol
Suggested-by: Michael Niedermayer
Signed-off-by: 's avatarSteven Liu <lq@chinaffmpeg.org>
parent 61a4ee8a
......@@ -262,6 +262,7 @@ static int filter_frame(AVFilterLink *link, AVFrame *frame)
NAN : frame->pkt_pos;
s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, NULL);
s->var_values[VAR_Y] = av_expr_eval(s->y_pexpr, s->var_values, NULL);
/* It is necessary if x is expressed from y */
s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, NULL);
normalize_double(&s->x, s->var_values[VAR_X]);
......
......@@ -1390,6 +1390,7 @@ static int draw_text(AVFilterContext *ctx, AVFrame *frame,
s->x = s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, &s->prng);
s->y = s->var_values[VAR_Y] = av_expr_eval(s->y_pexpr, s->var_values, &s->prng);
/* It is necessary if x is expressed from y */
s->x = s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, &s->prng);
update_alpha(s);
......
......@@ -149,6 +149,7 @@ static void eval_expr(AVFilterContext *ctx)
s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, NULL);
s->var_values[VAR_Y] = av_expr_eval(s->y_pexpr, s->var_values, NULL);
/* It is necessary if x is expressed from y */
s->var_values[VAR_X] = av_expr_eval(s->x_pexpr, s->var_values, NULL);
s->x = normalize_xy(s->var_values[VAR_X], s->hsub);
s->y = normalize_xy(s->var_values[VAR_Y], s->vsub);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment