Trying to create a new fake webcam device (/dev/video2) and play a video on it so I can use it as a virtual webcam.
Steps I took:
sudo apt-get install v4l2loopback-dkms
sudo modprobe v4l2loopback
sudo depmod -a
ffmpeg -i vid1.mp4 -vcodec rawvideo -pix_fmt yuv420p -threads 0 -f v4l2 /dev/video2
The error from the ffmpeg command:
ioctl(VIDIOC_G_FMT): Invalid argument
Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
Error initializing output stream 0:0
Conversion failed!
No idea what to do.