lavfi/hue: reindent after previous commits

This commit is contained in:
Stefano Sabatini 2012-08-16 14:51:33 +02:00
parent 419e1b7463
commit 5b0151a474
1 changed files with 26 additions and 26 deletions

View File

@ -72,34 +72,34 @@ static av_cold int init(AVFilterContext *ctx, const char *args)
hue->class = &hue_class; hue->class = &hue_class;
av_opt_set_defaults(hue); av_opt_set_defaults(hue);
/* named options syntax */
if (args) { if (args) {
if (equal = strchr(args, '=')) { /* named options syntax */
if ((ret = av_set_options_string(hue, args, "=", ":")) < 0) if (equal = strchr(args, '=')) {
return ret; if ((ret = av_set_options_string(hue, args, "=", ":")) < 0)
if (hue->hue != -FLT_MAX && hue->hue_deg != -FLT_MAX) { return ret;
av_log(ctx, AV_LOG_ERROR, if (hue->hue != -FLT_MAX && hue->hue_deg != -FLT_MAX) {
"H and h options are incompatible and cannot be specified " av_log(ctx, AV_LOG_ERROR,
"at the same time\n"); "H and h options are incompatible and cannot be specified "
return AVERROR(EINVAL); "at the same time\n");
} return AVERROR(EINVAL);
/* compatibility syntax */ }
} else { /* compatibility h:s syntax */
n = sscanf(args, "%f%c%f%c", &hue->hue_deg, &c1, &hue->saturation, &c2); } else {
if (n != 1 && (n != 3 || c1 != ':')) { n = sscanf(args, "%f%c%f%c", &hue->hue_deg, &c1, &hue->saturation, &c2);
av_log(ctx, AV_LOG_ERROR, if (n != 1 && (n != 3 || c1 != ':')) {
"Invalid syntax for argument '%s': " av_log(ctx, AV_LOG_ERROR,
"must be in the form 'hue[:saturation]'\n", args); "Invalid syntax for argument '%s': "
return AVERROR(EINVAL); "must be in the form 'hue[:saturation]'\n", args);
} return AVERROR(EINVAL);
}
if (hue->saturation < -10 || hue->saturation > 10) { if (hue->saturation < -10 || hue->saturation > 10) {
av_log(ctx, AV_LOG_ERROR, av_log(ctx, AV_LOG_ERROR,
"Invalid value for saturation %0.1f: " "Invalid value for saturation %0.1f: "
"must be included between range -10 and +10\n", hue->saturation); "must be included between range -10 and +10\n", hue->saturation);
return AVERROR(EINVAL); return AVERROR(EINVAL);
} }
} }
} }
if (hue->saturation == -FLT_MAX) if (hue->saturation == -FLT_MAX)