@@ -4283,7 +4283,7 @@ Multi-channel input files are not affected by this option.
Options are true or false. Default is false.
@item print_format
-Set print format for stats. Options are summary, json, or none.
+Set print format for stats. Options are summary, json, compact or none.
Default value is none.
@item file, f
@@ -48,6 +48,7 @@ enum PrintFormat {
NONE,
JSON,
SUMMARY,
+ COMPACT,
PF_NB
};
@@ -124,6 +125,7 @@ static const AVOption loudnorm_options[] = {
{ "none", 0, 0, AV_OPT_TYPE_CONST, {.i64 = NONE}, 0, 0, FLAGS, "print_format" },
{ "json", 0, 0, AV_OPT_TYPE_CONST, {.i64 = JSON}, 0, 0, FLAGS, "print_format" },
{ "summary", 0, 0, AV_OPT_TYPE_CONST, {.i64 = SUMMARY}, 0, 0, FLAGS, "print_format" },
+ { "compact", 0, 0, AV_OPT_TYPE_CONST, {.i64 = COMPACT}, 0, 0, FLAGS, "print_format" },
{ "file", "set file path for the measured stats", OFFSET(filename), AV_OPT_TYPE_STRING, {.str=NULL}, FLAGS },
{ "f", "set file path for the measured stats", OFFSET(filename), AV_OPT_TYPE_STRING, {.str=NULL}, FLAGS },
{ NULL }
@@ -909,6 +911,16 @@ static av_cold void uninit(AVFilterContext *ctx)
);
break;
+ case COMPACT:
+ s->print(ctx, "input_i: %.2f, input_tp: %.2f, input_lra: %.2f, input_thresh: %.2f, "
+ "output_i: %.2f, output_tp: %.2f, output_lra: %.2f, output_thresh: %.2f, "
+ "normalization_type: %s, target_offset: %.2f\n",
+ i_in, 20. * log10(tp_in), lra_in, thresh_in,
+ i_out, 20. * log10(tp_out), lra_out, thresh_out,
+ s->frame_type == LINEAR_MODE ? "linear" : "dynamic",
+ s->target_i - i_out);
+ break;
+
case SUMMARY:
s->print(ctx,
"\n"