smourier / VCamNetSample

Windows 11 Virtual Camera sample .NET code.
MIT License
10 stars 2 forks source link

Access Denied starting ComObject #1

Closed CarteKiwi closed 4 months ago

CarteKiwi commented 4 months ago

Hello Simon,

Thanks for this great work ! Exactly what I was looking for right now :)

I was not able to use regsvr32 as you said: regsvr32 VCamNetSampleSource.dll (that was raising an error "DllRegisterServer not found")

Had to call it on the ComHost file: regsvr32 VCamNetSampleSource.comhost.dll

But, I now get an "access denied" when instantiating camera in Main.cs of client app. hr = _camera.Object.Start(null);

Any idea ? I'm on Windows 11

Thanks

smourier commented 4 months ago

Hi,

Aw... of course you need to register the comhost.dll (this was an incorrect copy paste from the native version https://github.com/smourier/VCamSample)

As for the access denied, it's probably the same issue as for the native version https://github.com/smourier/VCamSample/issues/1

Here is a summary:

=> So the solution is just to either copy the output directory once built (or downloaded) somewhere where everyone has access and register VCamNetSampleSource.comhost.dll from there, or copy/checkout the whole repo where everyone has access and build and register there.

CarteKiwi commented 4 months ago

Crystal clear :) It's working now. Thanks for your prompt reply !