video - How to access compressed stream from webcam with ffmpeg -
I want to stream live webcam with ffmpeg. The output stream of raw and compressed data in my Logitech c920 webcam ffmpeg -f v4l2 -list_formats all -i / dev / video1
produces the following console output:
< code> [video4linux2, v4l2 @ 0x26709e0] Raw: yuyv422: YUV 4: 2: 2 (YUYV): 640x480 160x90 160x120 176x144 320x180 320x240 352x288 432x240 640x360 800x448 800x600 864x480 960x720 1024x576 1280x720 1600x896 1920x1080 2304x1296 2304x1536 [video4linux2, V4L2 @ 0x26709e0] Compressed : h264: 264: 640x480 160x90 160x120 176x144 320x180 320x240 352x288 432x240 640x360 800x448 800x600 864x480 960x720 1024x576 1280x720 1600x896 1920x1080 [video4linux2, V4L2 @ 0x26709e0] Compressed: mjpeg: MJPEG: 640x480 160x90 160x120 176x144 320x180 320x240 352x288 432x240 640x360 800x448 800x600 864x480 960x720 1024x576 1280x7 20 1600x896 1920x1080
I would like to image a compressed H264 image and send it to ffserver.
When I use this command ffmpeg -r 25 -f v4l2 -i / dev / video0 -C: VGD 264-B: V 2500k http: // localhost: 8090 / feed1 .ffm
program receives raw data and transcodes it with the h264 codec.
When I - C: v: libx264
to
-c: v copy
I get an error because ffmpeg tries to copy the raw camera image is.
How to specify the format for how I can use H.264 compressed image, there is a input_format
in FFMPEG
Input device. Try adding -input_format h264
as an input option in your order.
Comments
Post a Comment