NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: web-camera



On Tue, 15 Jun 2021, Todd Gruhn wrote:

I got pkgsrc-wip installed. Ideas here?


Assuming we're still discussing your webcam woes:

I tried out 2 USB webcams (the built-in one and a very old Logitech
that I had lying around) and both worked fine on 9.99.82:

$ dmesg | tail
[    20.157756] cpu 0: ucode 0x15->0x21
[    20.157756] cpu 1: ucode 0x15->0x21
[ 10304.957668] uvideo0 at uhub1 port 1 configuration 1 interface 0: Logitech (0x046d) product 0819 (0x0819), rev 2.00/0.10, addr 2 [ 10305.047668] video0 at uvideo0: Logitech (0x046d) product 0819 (0x0819), rev 2.00/0.10, addr 2
[ 10305.047668] uaudio0 at uhub1 port 1 configuration 1 interface 2
[ 10305.047668] uaudio0: Logitech (0x046d) product 0819 (0x0819), rev 2.00/0.10, addr 2
[ 10305.057668] uaudio0: audio rev 1.00
[ 10305.057668] audio1 at uaudio0: capture
[ 10305.057668] audio1: slinear_le:16 1ch 48000Hz, blk 11760 bytes (122.5ms) for recording



Using mpv (with the params. taken straight from the man-page):

$ mpv --profile=low-latency --untimed av://v4l2:/dev/video0
[ffmpeg/demuxer] video4linux2,v4l2: Time per frame unknown
 (+) Video --vid=1 (rawvideo 640x480)
[autoconvert] Converting yuyv422 -> yuv422p
VO: [gpu] 640x480 yuv422p
V: 451054:43:16 / 451054:43:16 (100%)
[ffmpeg/demuxer] video4linux2,v4l2: Some buffers are still owned by the caller on close.
[ffmpeg] ioctl(VIDIOC_QBUF): Bad file descriptor

Exiting... (Quit)



And, ffplay4, which was laggier than mpv:

$ ffplay4 /dev/video0
...
[video4linux2,v4l2 @ 0x7586ec46a000] Time per frame unknown f=0/0
Input #0, video4linux2,v4l2, from '/dev/video0':B sq=    0B f=0/0
  Duration: N/A, start: 1623797018.093746, bitrate: N/A
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640x480, 30 tbr, 1000k tbn, 1000k tbc
1623797022.84 M-V:  0.020 fd=   0 aq=    0KB vq=    0KB sq=    0B f=0/0

Try passing an explicit pixel format (yuyv422: very common) to ffplay:

$ ffplay4 -f v4l2 -pixel_format yuyv422 /dev/video0


-RVP


Home | Main Index | Thread Index | Old Index