Questions tagged [v4l2]

v4l2 (video for Linux 2) is a video capture interface for a variety of video capture devices tested to be fully compatible with Linux. v4l2 is commonly used by programs and frameworks such as Ekiga, gstreamer, Mplayer, Skype, and VLC media player.

A good place to start understanding the V4L2 framework is the following series of articles on lwn.net.

Part 1: The Video4Linux2 API
Part 2: registration and open()
Part 3: Basic ioctl() handling
Part 4: Inputs and Outputs
Part 5a: Colors and formats
Part 5b: Format negotiation
Part 6a: Basic frame I/O
Part 6b: Streaming I/O
Part 7: Controls

444 questions
0
votes
0 answers

v4l2 -> QByteArray(?) -> QWebsocket -> internet -> {PC, Android, web}

as you can assume from the tile, I would like to broadcast a webcam stream to different clients. I know that there are many solutions (as motion), but I have already a working infrastructure based on a Qt server software and a websocket as…
0
votes
2 answers

Does v4l2 support multi-map?

I'm trying to share frames(images) that I receive from a USB camera(logitech c270) between two processes so that I can avoid a memcpy. I'm using memory mapping streaming I/O method described here and I can successfully get frames from the camera…
Fazil
  • 93
  • 1
  • 3
0
votes
1 answer

Capture 1920x1080 video with OpenCV over Raspberry PI

Hardware: 1. Raspberry Pi 2 2. Raspberry Pi Camera Software: 1. OpenCV 2.4.11 2. Programming with C++ I've the following trivial code that capture video from camera and displays it within window. The frame size is always 640 x 480, trying to…
teach me
  • 453
  • 5
  • 20
0
votes
3 answers

v4l2 build error on Debian 8

I am installing video 4 linux following these steps, http://www.linuxtv.org/wiki/index.php/How_to_Obtain,_Build_and_Install_V4L-DVB_Device_Drivers but when build, following error appears. Debian 8 virtual machine. ... CC [M] …
Jaume
  • 3,672
  • 19
  • 60
  • 119
0
votes
0 answers

av_read_frame reads frames from cache

I want to detect an object with my camera. For performance reason, i like to keep the connection to my camera alive and read new images on demand. The function to read images calls av_read_frame till the frame is complete and then does some…
mineichen
  • 470
  • 2
  • 11
0
votes
1 answer

Video 4 Linux 2 reading MMAP address

I'm trying to write out the memory that I get from a video 4 linux 2 example program. However, it's not working. I'm getting a segmentation fault when trying to access the pointer. I hope this isn't a stupid mistake because I've spent a couple of…
0
votes
6 answers

How to parallelize this for loop for rapidly converting YUV422 to RGB888?

I am using v4l2 api to grab images from a Microsoft Lifecam and then transferring these images over TCP to a remote computer. I am also encoding the video frames into a MPEG2VIDEO using ffmpeg API. These recorded videos play too fast which is…
vineet
  • 1
0
votes
2 answers

v4l2-ctl - Parameters list?

I got this script on the Internet and tried to find a comprehensive list of parameters on Google but no success: # Record a video v4l2-ctl --set-fmt-video=width=800,height=600,pixelformat=4 v4l2-ctl --stream-mmap=3 --stream-count=100…
user1688175
0
votes
0 answers

Play rtsp video on android issue

I have implemented a simple program to play RTSP video in android with below code: private String path2 = "rtsp://mylocalip:port/webcam"; Uri video = Uri.parse(path2); mVideoView.setVideoURI(video); …
0
votes
1 answer

V4L2 / Beaglebone Black / Radiumboard HD Camera / Controls

I am trying to take snapshots with a Beaglebone Black paired with a RadiumBoards HD Camera Cape. I've noticed that using the built-in application (like cheese) will auto-adjust exposure. However, if I write custom C/C++ code on top of the v4l2…
Nanoforge
  • 1
  • 1
0
votes
1 answer

Reading Microphone Data by Polling using ALSA [or V4L2]

I am trying to read data from multiple microphones in Linux (ubuntu 14.04). I have a specific constraint that the reading from microphones should be via polling(so no waiting until there is data, although the data comes in high frequency). I wanted…
Amir Zadeh
  • 3,481
  • 2
  • 26
  • 47
0
votes
1 answer

Display uyvy data in Qt

I have input source as DVD player with video format as UYVY.I want to develop a Qt application which takes UYVY data as input and displays the video frame.I used v4l2 Linux commands in Qt for capture and Qt widget to display video frames. I guess Qt…
DubSum2
  • 91
  • 1
  • 6
0
votes
1 answer

The call imshow() in OpenCV is not creating any output

I am trying to read data from an industrial camera using the V4l linux driver and C++. I would like to display the result using the OpenCV. I read the buffer, create an Mat object, which actually contains values in range 0...255. The problem seems…
karlitos
  • 1,604
  • 3
  • 27
  • 59
0
votes
1 answer

Changing camera exposure on frame by frame basis

Is it possible to change exposure of a webcam on a frame-to-frame basis, with proper synchronization. My operating system is Ubuntu 14.04. Webcam - Logitech HD Pro 920 I know for sure that it's not possible with OpenCV. And certainly it would also…
Vishal
  • 3,178
  • 2
  • 34
  • 47
0
votes
1 answer

Ubuntu Opencv Camera settings V4L2 error Exposure control not supported

I wrote a simple Opencv program in Ubuntu 12.04LTS that adjusts a webcam (Logitech C525) settings like brightness and exposure and such. It works fine in Windows 7, but in Linux it gives me this error $ ./adjust-camera init done opengl…
ChumbiChubaGo
  • 968
  • 2
  • 9
  • 15