[MPlayer-users] mplayer rawvideo stream mixes two frames

Reimar Döffinger Reimar.Doeffinger at gmx.de
Mon Mar 21 23:16:01 CET 2016


On Mon, Mar 21, 2016 at 09:23:21PM +0000, Carlos Piñeiro wrote:
> 
> I am creating a rawvideo stream with known format:
> 
> 
> ffmpeg  -y -re -i udp://@127.0.0.1:1235 -fflags nobuffer -an -fpsprobesize 5 -f rawvideo -pixel_format yuv420p -video_size 320x240 udp://@127.0.0.1:2223
> 
> 
> And watching it with mplayer.
> 
> mplayer  -nofs -noquiet -identify -nomouseinput -vo gl -nosound -benchmark -demuxer +rawvideo -rawvideo w=320:h=240:format=i420:size=115200  udp://@127.0.0.1:2223
> 
> 
> 7/10 times works fine but some times the video starts incorrectly. As if it starts in the middle of the frame, so half of the frame belongs to one real frame, and the other half to other.
> 
> 
> Is there any way to prevent that from happening? I wanted to use raw video simply to reduce CPU time.

You REALLY can't use UDP with rawvideo (at least
without suitable container, and unfortunately
I can't suggest one that would really work even
though it is rather quite trivial to design one -
y4m would be it if it didn't require a stream header).
UDP is not a reliable transport and packets can get lost,
and with rawvideo there is no way to resync.


More information about the MPlayer-users mailing list