Accessing virtual device using FFMPEG inside Docker Windows Container gives an error named "Unable to BindToObject"

Hi everyone,
Let me share the state of our current work in windows OS (not containerized).

1. CURRENT STATE IN WINDOWS COMPUTER

We are able to use FFMPEG to capture a virtual device and stream from a Windows Computer. The virtual device is named screen-capture-recorder.

We registered the virtual device with regsvr32 (regsvr32 <path to screen-capture-recorder.dll>).

The registry in OS and device list in FFMPEG are below:
1.1. Registry values:

HKEY_CLASSES_ROOT\CLSID{860BB310-5D01-11d0-BD3B-00A0C911CE86}\Instance{4EA69364-2C8A-4AE6-A561-56E4B5044439}
FriendlyName REG_SZ screen-capture-recorder
CLSID REG_SZ {4EA69364-2C8A-4AE6-A561-56E4B5044439}
FilterData REG_BINARY >02000000000020000100000000000000307069330800000000000000010000000000000000000000307479330000000038000000480000007669647300001000800000AA00389B7100000000000000000000000000000000

HKEY_CLASSES_ROOT\CLSID{4EA69364-2C8A-4AE6-A561-56E4B5044439}\InprocServer32
(Default) REG_SZ C:\screen-capture-recorder.dll
ThreadingModel REG_SZ Both

1.2. FFMPEG dshow device list:

[dshow @ 0000025848bce480] “screen-capture-recorder” (video)
[dshow @ 0000025848bce480] Alternative name “@device_sw_{860BB310-5D01-11D0-BD3B-00A0C911CE86}{4EA69364-2C8A-4AE6-A561-56E4B5044439}”

You can see that, there is a text “(video)” on the right side of the “screen-capture-recorder” virtual device.

2. WHAT WE DID IN DOCKER WINDOWS CONTAINER TO ACHIEVE THE ABOVE AND THE ISSUE
We registered the virtual device from the exported registry keys in the docker container (We observed, this way of registration do not have impact on the device capturing, as after importing the exported registry keys from another windows computer, the streaming is working in a windows computer). Thus, we assume that there is no issue with virtual device registration. Also, the screen-capture-recorder.dll had no other code in their “DllRegisterServer” function other than registering filters.

The registry values are like the ones as the host machine. The screen-capture-recorder.dll is kept in the path of the container (C:\screen-capture-recorder.dll) where the registry value is shown.

Although they look good so far, the FFMPEG shows dshow devicelist as below:

[dshow @ 00000269d07fe9c0] “screen-capture-recorder” (none)
[dshow @ 00000269d07fe9c0] Alternative name “@device_sw_{860BB310-5D01-11D0-BD3B-00A0C911CE86}{4EA69364-2C8A-4AE6-A561-56E4B5044439}”

The screen-capture-recorder is not shown as video device, rather shown as none.

And while trying to stream from container, the below error is shown:

After all the details, the questions to ask, Does windows container not support virtual dshow video devices? Can there be any issue with accessing the dll for container environment? How can we make the virtual device work with FFMPEG?

[Please note, since we cannot capture screen inside container, we modified the code to read images from a folder. The issue above occurs for both the modified and the unmodified screen-capture-recorder.dll.]