[1.8.3.89], unable to load camera because of DLL path

When I click the green play button, I get
image

When I click Yes I get
image

It seems like there’s no encapsulation of the full path as there’s a space in my name, so instead of

regsvr32 “C:\Users\Ben PRFM\AppData\Roaming\BambuStudio\plugins\Whatever.dll”

it’s just doing

regsvr32 C:\Users\Ben PRFM\AppData\Roaming\BambuStudio\plugins\Whatever.dll

which results in everything after the space being treated as a second parameter which is being ignored because regsvr32 only takes 1 parameter, which is a full path to the DLL.

So we end up with 2 parameters

C:\Users\Ben

and

PRFM\AppData\Roaming\BambuStudio\plugins\Whatever.dll

regsvr32 will just see the first param that it needs and go “lol what’s this?” throw an error because it’s not a file, and return that result back to BambuStudio for the screenshot.

I would also say this is not unique to this version, it also happened several versions ago, I fixed it manually by registering the DLLs myself manually (I shouldn’t have to, it should just work) but since this upgrade, I thought I would report it since it clearly wasn’t spotted or fixed, or if it was reported, or it was ignored, or the developers didn’t understand the issue, but either way…

You might try the current release, v01.08.03.89

Usernames with spaces cause problems that are not unique to Studio.

Under Windows, while not strictly prohibited, spaces in user names are generally considered a bad idea. Usually a space will be omitted, or replaced with an underscore. In some circumstances, enclosing the full username in double quotes is recommended.

I’ve just tried v01.08.03.89 and unfortunately it’s exactly the same. Since there’s a github I didn’t know existed, I might make the fix and put in a pull request.

It’s a workplace domain; unfortunately I have zero control over my username within this environment as it’s fairly common practice for a users account to be “Forename Surname” by default. Even putting that aside, the moment you set up a Windows 11 PC and Microsoft forces you to log in to your Microsoft account, it creates a username with your forename and surname of your Microsoft account. To bypass it requires you to “know” which the average person simply won’t. At least on older versions Windows you had the luxury of choice but this seems to be the direction that Microsoft are choosing to go unfortunately, so this is only going to become a larger issue going forward as more people get brand new Windows 11 PCs vs in-place upgrade.

Since encapsulating paths can fix the issue going forward without relying on an ideology that Microsoft themselves won’t follow or enforce, it should be encapsulated.

in BambuStudio/src/slic3r/GUI/wxMediaCtrl2.cpp at v01.08.03.89 · bambulab/BambuStudio · GitHub

Lines 94 and 115, replace:

SHELLEXECUTEINFO info{sizeof(info), 0, NULL, L"open", L"regsvr32", dll_path.wstring().c_str(), SW_HIDE };

with

std::wstring quoted_path = L"\"" + dll_path + L"\""; SHELLEXECUTEINFO info{sizeof(info), 0, NULL, L"open", L"regsvr32", quoted_path.c_str(), SW_HIDE};