From 3dfaf571022f6328121392e581887be6aee16257 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Mon, 25 Aug 2014 07:41:58 -0700 Subject: [PATCH] obs-x264: Log settings after custom opts parsed The log of the settings didn't take in to account the potential of custom x264 options. This changes it to log the actual x264 settings after parsing. --- plugins/obs-x264/obs-x264.c | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/plugins/obs-x264/obs-x264.c b/plugins/obs-x264/obs-x264.c index 542ac1da9..ffc4b5b6c 100644 --- a/plugins/obs-x264/obs-x264.c +++ b/plugins/obs-x264/obs-x264.c @@ -307,20 +307,6 @@ static void update_params(struct obs_x264 *obsx264, obs_data_t settings, obsx264->params.p_log_private = obsx264; obsx264->params.i_log_level = X264_LOG_WARNING; - info("settings:\n" - "\tbitrate: %d\n" - "\tbuffer size: %d\n" - "\tfps_num: %d\n" - "\tfps_den: %d\n" - "\twidth: %d\n" - "\theight: %d\n" - "\tkeyint: %d\n" - "\tcbr: %s", - bitrate, buffer_size, voi->fps_num, voi->fps_den, - width, height, - obsx264->params.i_keyint_max, - cbr ? "on" : "off"); - /* use the new filler method for CBR to allow real-time adjusting of * the bitrate */ if (cbr) { @@ -346,6 +332,22 @@ static void update_params(struct obs_x264 *obsx264, obs_data_t settings, while (*params) set_param(obsx264, *(params++)); + + info("settings:\n" + "\tbitrate: %d\n" + "\tbuffer size: %d\n" + "\tfps_num: %d\n" + "\tfps_den: %d\n" + "\twidth: %d\n" + "\theight: %d\n" + "\tkeyint: %d\n" + "\tcbr: %s", + obsx264->params.rc.i_vbv_max_bitrate, + obsx264->params.rc.i_vbv_buffer_size, + voi->fps_num, voi->fps_den, + width, height, + obsx264->params.i_keyint_max, + cbr ? "on" : "off"); } static bool update_settings(struct obs_x264 *obsx264, obs_data_t settings)