From b92a28ffdf6513647d1a51293cebc93d62052a15 Mon Sep 17 00:00:00 2001 From: Joel Bethke Date: Tue, 13 Oct 2026 13:54:52 -0700 Subject: [PATCH] win-dshow: Update virtualcam installer scripts Remove the registry key check for the virtual camera module installer. The regsvr32 will perform this check itself, so we don't need to if the registration is already present. However, if we want to update the path, simply checking that the key exists will prevent us from being able to update the path in the future, and as necessary for OBS v33+. This also corrects the incorrect file paths to the modules in the new core plugin structure. --- .../virtualcam-install.bat.in | 32 +++---------------- .../virtualcam-uninstall.bat.in | 8 ++--- 2 files changed, 8 insertions(+), 32 deletions(-) diff --git a/plugins/win-dshow/virtualcam-module/virtualcam-install.bat.in b/plugins/win-dshow/virtualcam-module/virtualcam-install.bat.in index 51166e8b3..229e64caa 100644 --- a/plugins/win-dshow/virtualcam-module/virtualcam-install.bat.in +++ b/plugins/win-dshow/virtualcam-module/virtualcam-install.bat.in @@ -11,33 +11,10 @@ goto checkAdmin goto end ) -:checkDLL - echo Checking for 32-bit Virtual Cam registration... - reg query "HKLM\SOFTWARE\Classes\WOW6432Node\CLSID\{@VIRTUALCAM_GUID@}" >nul 2>&1 - if %errorLevel% == 0 ( - echo 32-bit Virtual Cam found, skipping install... - echo. - ) else ( - echo 32-bit Virtual Cam not found, installing... - goto install32DLL - ) - -:CheckDLLContinue - echo Checking for 64-bit Virtual Cam registration... - reg query "HKLM\SOFTWARE\Classes\CLSID\{@VIRTUALCAM_GUID@}" >nul 2>&1 - if %errorLevel% == 0 ( - echo 64-bit Virtual Cam found, skipping install... - echo. - ) else ( - echo 64-bit Virtual Cam not found, installing... - goto install64DLL - ) - goto endSuccess - :install32DLL echo Installing 32-bit Virtual Cam... - if exist "%~dp0\data\core\win-dshow\obs-virtualcam-module32.dll" ( - regsvr32.exe /i /s "%~dp0\data\core\win-dshow\obs-virtualcam-module32.dll" + if exist "%~dp0\core\win-dshow\data\obs-virtualcam-module32.dll" ( + regsvr32.exe /i /s "%~dp0\core\win-dshow\data\obs-virtualcam-module32.dll" ) else ( regsvr32.exe /i /s obs-virtualcam-module32.dll ) @@ -50,12 +27,11 @@ goto checkAdmin echo. goto end ) - goto checkDLLContinue :install64DLL echo Installing 64-bit Virtual Cam... - if exist "%~dp0\data\core\win-dshow\obs-virtualcam-module64.dll" ( - regsvr32.exe /i /s "%~dp0\data\core\win-dshow\obs-virtualcam-module64.dll" + if exist "%~dp0\core\win-dshow\data\obs-virtualcam-module64.dll" ( + regsvr32.exe /i /s "%~dp0\core\win-dshow\data\obs-virtualcam-module64.dll" ) else ( regsvr32.exe /i /s obs-virtualcam-module64.dll ) diff --git a/plugins/win-dshow/virtualcam-module/virtualcam-uninstall.bat.in b/plugins/win-dshow/virtualcam-module/virtualcam-uninstall.bat.in index fb9e417d0..9daebcc8c 100644 --- a/plugins/win-dshow/virtualcam-module/virtualcam-uninstall.bat.in +++ b/plugins/win-dshow/virtualcam-module/virtualcam-uninstall.bat.in @@ -12,13 +12,13 @@ goto checkAdmin ) :uninstallDLLs - if exist "%~dp0\data\core\win-dshow\obs-virtualcam-module32.dll" ( - regsvr32.exe /u /s "%~dp0\data\core\win-dshow\obs-virtualcam-module32.dll" + if exist "%~dp0\core\win-dshow\data\obs-virtualcam-module32.dll" ( + regsvr32.exe /u /s "%~dp0\core\win-dshow\data\obs-virtualcam-module32.dll" ) else ( regsvr32.exe /u /s obs-virtualcam-module32.dll ) - if exist "%~dp0\data\core\win-dshow\obs-virtualcam-module64.dll" ( - regsvr32.exe /u /s "%~dp0\data\core\win-dshow\obs-virtualcam-module64.dll" + if exist "%~dp0\core\win-dshow\data\obs-virtualcam-module64.dll" ( + regsvr32.exe /u /s "%~dp0\core\win-dshow\data\obs-virtualcam-module64.dll" ) else ( regsvr32.exe /u /s obs-virtualcam-module64.dll )