Selaa lähdekoodia

obs-ffmpeg: Show friendly error for NV_ENC_ERR_INVALID_VERSION

Richard Stanway 5 vuotta sitten
vanhempi
sitoutus
ea7bb7a7cd
1 muutettua tiedostoa jossa 5 lisäystä ja 0 poistoa
  1. 5 0
      plugins/obs-ffmpeg/jim-nvenc-helpers.c

+ 5 - 0
plugins/obs-ffmpeg/jim-nvenc-helpers.c

@@ -29,6 +29,11 @@ bool nv_failed(obs_encoder_t *encoder, NVENCSTATUS err, const char *func,
 			encoder, obs_module_text("NVENC.UnsupportedDevice"));
 		break;
 
+	case NV_ENC_ERR_INVALID_VERSION:
+		obs_encoder_set_last_error(
+			encoder, obs_module_text("NVENC.OutdatedDriver"));
+		break;
+
 	default:
 		dstr_printf(&error_message,
 			    "NVENC Error: %s: %s failed: %d (%s)", func, call,