Browse Source

obs-x264: Set CRF value conditionally

Matches value seen when encoding with FFmpeg.
jpark37 4 years ago
parent
commit
abf6a97ca9
1 changed files with 1 additions and 2 deletions
  1. 1 2
      plugins/obs-x264/obs-x264.c

+ 1 - 2
plugins/obs-x264/obs-x264.c

@@ -518,10 +518,9 @@ static void update_params(struct obs_x264 *obsx264, obs_data_t *settings,
 		}
 	} else {
 		obsx264->params.rc.i_rc_method = X264_RC_CRF;
+		obsx264->params.rc.f_rf_constant = (float)crf;
 	}
 
-	obsx264->params.rc.f_rf_constant = (float)crf;
-
 	if (info.format == VIDEO_FORMAT_NV12)
 		obsx264->params.i_csp = X264_CSP_NV12;
 	else if (info.format == VIDEO_FORMAT_I420)