[FFmpeg-user] ffserver mjpg rtp stream pixel format problems

Julian julian at arandomworld.co.uk
Sun Nov 8 21:42:19 CET 2015


Hi,

I'm trying to stream a webcam from windows to ffserver on linux and then 
play the RTP stream on linux. I'm having problems with pixel format I 
think, my camera seems to only support yuyv422 and so its sending this 
to ffserver but I don't think RTP can support the format since ffserver 
keeps saying "Only 1x1 chroma blocks are supported. Aborted" whenever I 
run ffplay for the stream.

I've tried adding -pix_fmt yuv420p to ffmpeg but it doesn't change 
anything, is there anything obvious I'm missing?

As an experiment I tried running ffmpeg -f lavfi -i 
testsrc=size=640x480:rate=25 http://192.168.0.18:8090/feed1.ffm which 
then uses yuvj444p and ffserver says "Unsupported pixel format" but I 
can't seem to get the format to change.

Thanks!

FFserver.conf:

HTTPPort 8090
HTTPBindAddress 0.0.0.0
RTSPPort 8091
RTSPBindAddress 0.0.0.0
MaxHTTPConnections 2000
MaxClients 1000
MaxBandwidth 1000

<Feed feed1.ffm>
     File /tmp/feed1.ffm
     FileMaxSize 1M
</Feed>

<Stream cam.mjpg>
     Feed feed1.ffm
     Format rtp
     VideoFrameRate 25
     VideoSize 640x480
     VideoCodec mjpeg
     NoAudio
</Stream>

<Stream stat.html>
     Format status
     ACL allow localhost
     ACL allow 192.168.0.0 192.168.255.255
</Stream>

ffmpeg command:
ffmpeg -f dshow -i video="USB2.0 Camera" http://192.168.0.18:8090/feed1.ffm
ffmpeg version N-76479-gc878082 Copyright (c) 2000-2015 the FFmpeg 
developers
   built with gcc 5.2.0 (GCC)
   ...
Input #0, dshow, from 'video=USB2.0 Camera':
   Duration: N/A, start: 17930.120000, bitrate: N/A
     Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640x480, 
30 tbr, 10000k tbn, 30 tbc
[swscaler @ 00000008c0a5afe0] deprecated pixel format used, make sure 
you did set range correctly
Output #0, ffm, to 'http://192.168.0.18:8090/feed1.ffm':
   Metadata:
     creation_time   : 2015-11-08 20:32:06
     encoder         : Lavf57.14.100
     Stream #0:0: Video: mjpeg, yuvj422p(pc), 640x480, q=2-31, 64 kb/s, 
30 fps, 1000k tbn, 25 tbc
     Metadata:
       encoder         : Lavc57.14.100 mjpeg
Stream mapping:
   Stream #0:0 -> #0:0 (rawvideo (native) -> mjpeg (native))
Press [q] to stop, [?] for help
[mjpeg @ 00000008c0a57660] rc buffer underflow
     Last message repeated 16 times
[mjpeg @ 00000008c0a57660] rc buffer underflowe=00:00:00.68 
bitrate=2939.5kbits/s dup=11 drop=0

list-options:
ffmpeg -list_options true -f dshow -i video="USB2.0 Camera"
ffmpeg version N-76479-gc878082 Copyright (c) 2000-2015 the FFmpeg 
developers
   built with gcc 5.2.0 (GCC)
   ...
[dshow @ 00000049c119ac40] DirectShow video device options (from video 
devices)
[dshow @ 00000049c119ac40]  Pin "Capture" (alternative pin name "0")
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=640x480 fps=30 
max s=640x480 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=640x480 fps=30 
max s=640x480 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=160x120 fps=30 
max s=160x120 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=160x120 fps=30 
max s=160x120 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=320x240 fps=30 
max s=320x240 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=320x240 fps=30 
max s=320x240 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=176x144 fps=30 
max s=176x144 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=176x144 fps=30 
max s=176x144 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=352x288 fps=30 
max s=352x288 fps=30
[dshow @ 00000049c119ac40]   pixel_format=yuyv422  min s=352x288 fps=30 
max s=352x288 fps=30
video=USB2.0 Camera: Immediate exit requested


More information about the ffmpeg-user mailing list