Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

obs-studio-node compatibility help #9

Open
jgarcie opened this issue May 19, 2021 · 0 comments
Open

obs-studio-node compatibility help #9

jgarcie opened this issue May 19, 2021 · 0 comments

Comments

@jgarcie
Copy link

jgarcie commented May 19, 2021

I am trying to use this plugin with obs-studio-node and I am having a compatibility issue. Obs-studio-node essentially wraps libobs so it is compatible with NodeJS and Electron. I was hoping you could point me in the right direction to solving it because I am not very experienced with OBS development.

I had to rebuild obs-virual-cam-filter to change the output type on this line in the code

context->virtualCam = obs_output_create("virtualcam_output", "virtualcam_output_filter", NULL, NULL);

to

context->virtualCam = obs_output_create("virtual_output", "virtualcam_output_filter", NULL, NULL);

This changes the output type from "virtualcam_output" to "virtual_output" to work with obs-studio-node. Then I put the dll in the /obs-studio-node/obs-plugins/64bit/ folder. The module loads without any errors in the logs!

Then I add the plugin to a source with the following (Javascript):

...
[CODE HERE CREATES THE SOURCE obsCameraInput WHICH WORKS CORRECTLY]
...

const vcFilter = osn.FilterFactory.create('virtual_cam_filter', 'virtcam');
obsCameraInput.addFilter(vcFilter);

This gives the following output in the logs

[000:00:00:03.809.769.000][Debug] output 'virtualcam_output_filter' (virtual_output) created
[000:00:00:03.809.794.400][Debug] private source 'virtcam' (virtual_cam_filter) created
[000:00:00:03.810.217.400][Debug] - filter 'virtcam' (virtual_cam_filter) added to source 'camera-video'
[000:00:00:03:810.842.400][Debug] starting virtual-output on VirtualCam'1'

Then it crashes with no more output.

Any ideas on what to try next?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant