-
Notifications
You must be signed in to change notification settings - Fork 99
obs-v4l2sink Resolving all the issues to make it work #54
Comments
That's not really an issue but it's my pleasure to share all the stuff works for me to use the plugin. |
Just a small modification for
as mentioned in first "issue". Everything else works great. Thank you @huertacjavier |
Thank you @huertacjavier . I have followed (with some differences on how to build, but yours should work) steps, and got plugin loaded and it seems to work! PURE AWESOMSS!
If format to be chosen in obs/plugin, it is YUY2, not just YUY. Verified being able to see video in vlc and zoom. Jitsi didn't see the device, but may be restart of the browser would help (next to try) |
Ubuntu 18.04.4 LTS Yes to installing the Yes to everything about
I didn't want to argue with C++ include files, so I edited The I started Note: To start OBS itself I have to use this: |
Thanks for this @huertacjavier . Helped a lot. |
This saved my bacon. Why does the plugin get installed to a directory which OBS doesn't load plugins from? This seems like a real issue. |
I followed your directions. V4L2Slink does not appear in the utility menue. I am using obs 25.08 on Ubuntu 20.4. OBS cam shows as one of the video capture devices (OBS Cam (platform:v4l2loopback-000) |
Thanks to tell me. I fixed it |
Try this v4l2sink doesn't appear in OBS > tools |
Jesus Christ, thank you so much, I haven't been able to get this forever (to be fair, I upgraded my system yesterday, so the correct cstlib is there now, but I have been working on this all day and didn't get it yet). Your weird ffmpeg fix saved me quite a bit of time, thanks! |
@huertacjavier, thank you so much! You should win a Nobel prize for that dude! :D |
Hi! I'm new in using linux mint. I already followed the tutorial but when i type Tell CMake where to find the compiler by setting either the environment -- Configuring incomplete, errors occurred! what can i do? since i cannot proceed to the next command. |
Thanks for your post. Do you see a significant lag in the virtual camera output? I am having about a one second lag with the V4l2sink when I use it as camera input to zoom. If I disconnect zoom from the sink feed, guvcview won't show the stream (invalid pixel format and resolution errors). I have a GTX 1660 graphics card I expected to be doing the heavy lifting. |
if you're using a wireless connection then in general you get this delay.
Try using ADB connection via USB cable to get better results.
…On Sat, Oct 3, 2020 at 1:57 PM James Grenning ***@***.***> wrote:
Thanks for your post. Do you see a significant lag in the virtual camera
output?
I am having about a one second lag with the V4l2sink when I use it as
camera input to zoom. If I disconnect zoom from the sink feed, guvcview
won't show the stream (invalid pixel format and resolution errors).
I have a GTX 1660 graphics card I expected to be doing the heavy lifting.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#54 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABD6LZFVLN57TSYMDRNH2JDSI5JZLANCNFSM4OAHO24Q>
.
|
Everything is hard-wired. USB camera. Wired LAN. What is ADB? |
@jwgrenning, what camera are you using? ADB stands for "android debug bridge". If your camera OS is based on android (e.g. if you are using the camera on your cellphone) you need to switch debug mode on to allow the USB connection. |
I'm using obs-v4l2sink on Ubuntu with a Logitech c922. I thought ADB was an android thing. |
Doesn't work for me, any other options? |
hi @hamzahfadh i did follow this https://unix.stackexchange.com/questions/574961/why-is-there-no-cmake-cxx-compiler-could-be-found-and-how-to-solve and it is solved. im on Ubuntu 20.04.1 LTS 64-bit. Hope it works with you too |
Ubuntu 20.04.1 myname@Online:~/obs-v4l2sink/build$ make -j4 i dont know how to fix this since im new to ubuntu |
also v4l2sink not seen in tools |
Ubuntu 20.04.1 It used to work fine for a few months (actually since the beginning of the pandemic) with regular updates, but for a few days now (second wave of the pandemic... always harder ;-)) I can't select anymore the virtual cam device in Zoom (5.4.1) or in the Web browser (I have tried both Firefox and Chrome). However I can see and access the OBS output with my virtual webcam content in guvcview (when OBS is also running). I have no idea what causes this as I haven't changed anything related to the webcam recently. Maybe a kernel/OS update? It doesn't seem to be linked to OBS because I have tried two different versions, the latest 25.0.8 from the Ubuntu repositories and the one from the OBS project PPA 26.0.2. Both versions give the same result in guvcview. I have no issue with v4l2sink because it shows in the Tools menu of OBS and I use the YUY2 video format. I get no error when starting it. The device number is also correct (/dev/video2). My webcam is a Logitech StreamCam that provides /dev/video0 for its stream and /dev/video1 for its metadata. Please, if you can recommend something to check or try? Thank you. |
@jplandrain from time to time I have faced the same issue as well.
So I just added following alias in my .bashrc and run that alias obs_loopback='sudo modprobe v4l2loopback video_nr=10 card_label="OBS Video Source" exclusive_caps=1' |
@raulgool Thanks but that doesn't help (still I have tried your solution, just in case). Everything looks fine in my case related to v4l2loopback, v4l2sink and OBS, as I can see the output from OBS through my virtual webcam using guvcview connected to it. It's just that Zoom and the web browsers I use don't offer me anymore the possibility to select the virtual cam as webcam device. But guvcview still does... That really puzzles me. All was working fine for many months. |
I have found the answer. With the latest kernels on Ubuntu 20.04.1, it looks like the v4l2loopback-dkms package from the Ubuntu repositories is too old (v0.12.3) and not compatible anymore. I have solved the issue by taking it from the latest sources (v0.12.5 at this time):
And then reboot. Now it doesn't work anymore in guvcview, but it works in Zoom, Firefox and Chrome (BTW I use this test website that allows to select the camera when there are multiple cams, virtual or not, connected: https://www.webcamtests.com) |
Also to do the modprobe at startup, this is explained on the Github https://github.com/umlaeute/v4l2loopback:
|
hi @jplandrain
and this is inside my 5.9.0-1-amd64 folder:
any advice?? |
Yes. Did you compile by yourself or use |
Given the quoted message, I assume you have compiled v4l2loopback by yourself. In the folder that you have compiled it, can you do a I'm thinking maybe you forgot to run the simple If there is a file named Also, make sure to do a |
could be but not this time. I cp the .ko file to the /lib/modules/$(uname -r) - Thank you |
@ochen1 |
It looks like the issue I have mentioned with v4l2loopback-dkms is limited to Ubuntu 20.04 and it is going to be fixed soon. |
Hello, I did experience issues, even if I was on a 18.04 but finally solved them ; So I mention them here for the record :
which I "solved" by manually installing libobs0 : So I went along your procedure, compiling and installing obs-v4l2sink. And after that, I reinstalled obs-studio which ultimately removed libobs-dev and libsobs0 . I'm not very confident about the idea that a lib is installed, used to compile (and link) and ultimately removed. Actually v4l2sink.so seems to be still linked to libobs.so.0 ; but well, :
I'm now able to start the v4l2sink , using YUY2 , and I'm seeing it directly in vlc . I see it in the devices in M. Teams as well . So I think it is working perfectly. Thanks for your help. |
v4l2sink now installs the plugin into /usr/lib/x86_64-linux-gnu/obs-plugins , but it seems as if it also has to live within |
I can confirm that the version 26 wont work with the current version of virtual cam for linux. I cannot even make it work with the old one. |
This saved me, thank you very much! |
for me on kubuntu 20.04 with |
I had my virtual camera working just fine. Recently, I reinstall ubuntu 20.04, everything shows up in obs and there are no problem while installing the lib, but as soon as i click start "START",, obs crashes :( i encountered no errors, and even had this exact procedure working before |
You don't need this anymore. OBS provides native support as of v26... |
Someone should archive this repo. @CatxFish ? |
Hi I am looking at OBS 26.1.2 dfsg1-1+b1 (linux) |
i can confirm that it works - is there somewhere some documentation about the details? |
Windows has got that option, not linux |
this link actually solved the problem.
Thank you |
Everything ran smooth, but v4l2sink doesn't appear in OBS, under Tools, even after |
Which obs do you run?? |
Thank you for the answer. It's 26.1.1. I have "studio mode" under the start recording. Before, I used droidcam as a video source in Zoom, but it lagged and the video was not in sync with the audio. I thought if I could use OBS as a video source as well as an audio source (input) in Zoom, there would no longer be any problem, but I've not been successful so far. I've looked for easier options (such as delaying the audio input in zoom so that it would start at the same time as the lagging video) but I haven't found any tool to do so in Linux Mint. |
I installed successfully to make it work toghether OBS with Zoom. I share my experience in just one post because I had to research in several posts to make it.
OS Ubuntu 18.04
First of all I installed OBS from Ubuntu repositories. I didn't compile it or install in other way, just as usual in a terminal:
sudo apt-get install obs-studio
Second, download Zoom .deb package from Zoom website and install it
After that I installed v4l2loopback driver just in the same way as OBS:
sudo apt-get install v4l2loopback-dkms
No more than that. Not source code, not GitHub, just as simple as it sounds.
Just as a note of this installation, linux-headers of kernel must be installed before v4l2loopback. Debian and derivates most of the times install them by default. But if there isn't, easy way for me, is using synaptic or if you prefer use the terminal.
At the end of v4l2loopback installation just run this command:
sudo modprobe v4l2loopback video_nr=10 card_label="OBS Video Source" exclusive_caps=1
where nr=10 will be the number of the device, so you write any number you want, just don't forget it. So important at the end!
Next, I installed obs-v4l2sink and this is the interesting part of all the process.
You need to install previously to avoid errors or lack of dependecies:
git
sudo apt-get install git
cmake
sudo apt-get install cmake
Qt5
sudo apt-get install qtbase5-dev
libobs-dev
sudo apt-get install libobs-dev
This avoid the error LIBOBS not found at the time cmake is gathering all the dependecies.
ffmpeg
sudo apt-get install ffmpeg
Crazy but true, it doesn't matter if you have installed, you need to run this in the terminal. Sometimes, to me happened, cmake find the error ffmpeg not found. Running that command makes system recognize installed manually. Terminal displays ffmpeg is already installed in the newer version, or something like that, but this fix the error mentioned. Yeah! Really weird but it works.
Well, you're ready to continue, maybe there are other dependecies issues, but these are I needed to get solution.
For me worked to make a directory to compile all the source code in the same place
mkdir codev4l2sink or any name you wish
cd /home/username/codev4l2sink to enter and work in the directory, change user for the name of your own user
Clone the OBS source code
git clone --recursive https://github.com/obsproject/obs-studio.git
Clone the plugin v4l2sink source code
git clone https://github.com/CatxFish/obs-v4l2sink
Install obs-v4l2sink
cd /obs-v4l2sink _Other crazy thing: If you don't able to get in the directory, write it complete as /home/username/codev4l2sink/obs-v4l2sink _
mkdir build && cd build
cmake -DLIBOBS_INCLUDE_DIR="../../obs-studio/libobs" -DCMAKE_INSTALL_PREFIX=/usr ..
make -j4
sudo make install
If everything runs smoothly you'll be done.
Aftermath
v4l2sink doesn't appear in OBS > tools
Sad but true, all the work, maybe for nothing. Fix running this in a terminal:
sudo cp /usr/lib/obs-plugins/v4l2sink.so /usr/lib/x86_64-linux-gnu/obs-plugins/
Start OBS again, it will be there
v4l2sink format not supported
Yes, a final issue. Just to be sure that the device has the correct number, same you write at the beginning in the step after installing v4l2loopback and choose YUY2. And it will be fine.
Open Zoom, choose camera
In video choose the virtual camara. Now everything happens in OBS, happens in Zoom
I hope all this stuff will be useful as me
The text was updated successfully, but these errors were encountered: