Commit 557a13d1fb for aom
commit 557a13d1fb8dff5759baaebb6a525e1761b29bef
Author: Wan-Teh Chang <wtc@google.com>
Date: Thu Apr 9 17:40:59 2026 -0700
Handle vmaf_model_path in set_config_arg_ctrls()
Since AV1E_SET_VMAF_MODEL_PATH is in the av1_arg_ctrl_map array, it
should be handled in set_config_arg_ctrls() rather than in
parse_stream_params().
Change-Id: I42bdd6d15102c00ca3065535f164c8636fb25e85
diff --git a/apps/aomenc.c b/apps/aomenc.c
index c2b7d95f40..d79e974f98 100644
--- a/apps/aomenc.c
+++ b/apps/aomenc.c
@@ -873,6 +873,13 @@ static void set_config_arg_ctrls(struct stream_config *config, int key,
return;
}
+#if CONFIG_TUNE_VMAF
+ if (key == AV1E_SET_VMAF_MODEL_PATH) {
+ config->vmaf_model_path = arg->val;
+ return;
+ }
+#endif
+
// For target level, the settings should accumulate rather than overwrite,
// so we simply append it.
if (key == AV1E_SET_TARGET_SEQ_LEVEL_IDX) {
@@ -1139,10 +1146,6 @@ static int parse_stream_params(struct AvxEncoderConfig *global,
} else if (arg_match(&arg, &g_av1_codec_arg_defs.tile_height, argi)) {
config->cfg.tile_height_count =
arg_parse_list(&arg, config->cfg.tile_heights, MAX_TILE_HEIGHTS);
-#if CONFIG_TUNE_VMAF
- } else if (arg_match(&arg, &g_av1_codec_arg_defs.vmaf_model_path, argi)) {
- config->vmaf_model_path = arg.val;
-#endif
} else if (arg_match(&arg, &g_av1_codec_arg_defs.partition_info_path,
argi)) {
config->partition_info_path = arg.val;