bluecherrydvr / solo6x10

Bluecherry solo6x10 repo
23 stars 10 forks source link

Make it possible to specify MJPEG quality through Video4Linux2 controls #11

Open curtishall opened 13 years ago

curtishall commented 13 years ago

Imported from Redmine:

http://improve.bluecherrydvr.com/issues/930

Would it be possible to allow modification of MJPEG quality through the "v4l2-ctl --set-jpeg-comp" command? In our company we would require to switch this value on the fly so we can take high-quality screenshots while keeping the MJPEG video streaming easy on the bandwidth.

Updated by Robert Zalewski

ioctl requests which correspond to the get/set commands are described here: http://v4l2spec.bytesex.org/spec/r11285.htm Also "v4l2-ctl --help" command prints out this text under "Uncommon options"

--get-jpeg-comp query the JPEG compression [VIDIOC_G_JPEGCOMP] --set-jpeg-comp=quality=,markers=,comment=,app= set the JPEG compression [VIDIOC_S_JPEGCOMP]

is the app segment: 0-9 or a-f, is the actual string. is a colon separated list of: dht: Define Huffman Tables dqt: Define Quantization Tables dri: Define Restart Interval
JackSimth commented 10 years ago

This is noted from 2 years ago... Has this happened? I would like to have the same feature available for the BC-H16480A-REV2 16-port 150 fps h.264 card I have for testing.

curtishall commented 10 years ago

Not yet. It's eventually planned and might be looked at again in the next month or two.

Optionally we accept pull requests, if you wanted to implement this yourself. I can provide you the technical datasheets on the chips.

ghost commented 10 years ago

@JackSimth now we have the quality setting for H264 encoder: https://github.com/bluecherrydvr/solo6x10/commit/b6a9568366ee68954de18c42296a613e118a417e If you use exactly MJPEG encoder, please indicate in this topic, we can add that control similarly.