Question / Help No mjpeg as video format with logitech c930e

8tungdata

New Member
Hi,

I have a problem with my webcam logitech c930e. This should work with 1980x1280 30 fps without any lags. And you should choose mjpeg for the hardware recording.

I can choose this option as video format under Windows 10 but not under Linux Manjaro, fresh install with Kernel: 5.6.5-3-MANJARO.

In Linux there is only yuy2 or something else but no mjpeg. How can I fix this with linux?

Thanks in advance,
8tungdata
 

Tuna

Member
v4l2 source plugin only supports uncompressed video.

There is a gstreamer plugin that should be able to handle it. You need some experience or read something about gstreamer though.
 

8tungdata

New Member
Ok, I want to try it. Is there an installation howto of the gstreamer plugin with the other dependencies under linux? what different packages do I need?

Ist this the right pipe for me, if I only want to record my logitech webcam c930e with the mjpeg format hardencoded:

Code:
v4l2src device=/dev/video6 ! image/jpeg,framerate=60/1,width=1280,height=720 ! jpegdec ! video
 

Tuna

Member
You need to have the gstreamer libraries installed (most installs should have them as many multimedia apps use these - but it depends on your distribution/install).

The pipe may look something like:

Code:
v4l2src device=/dev/video6 ! image/jpeg,framerate=60/1,width=1280,height=720 ! decodebin ! video.

(unsure about the image/jpeg caps - but i assume they work for your case.. i hope)

From there you can try to experiment with hardware jpeg decoders too assuming your system has one (and if it is not auto-plugged automatically)
 

8tungdata

New Member
I found here in another thread the statement:

Try using one of the Pixelformats marked as "Emulated". Those should be native MJPEG in most cases with the v4l2 userspace library converting them to something obs can handle.

leonhard said:

Good call! That lowered the resource load greatly.

There seems to be a fork of OBS but the developper has changed his mind.

I've implemented MJPEG support for v4l2. Then I discovered that emulated modes do what I need. Few hours wasted.

Anyway, if your camera doesn't support emulated modes you can try it:

(https://github.com/ggodlewski/obs-studio

My camera works with the emulated modes. The cpu-load has 10-15 %. Seems to me that it is not necessary to fiddle around with the gstreamer-plugin?

The videoquality seems to be okay. But I know myself, I'm curios after some weeks I will test it.
 
Top