[FFmpeg-user] v4l2 overlay on mjpeg stream

Carl Eugen Hoyos ceffmpeg at gmail.com
Mon Jan 25 00:39:53 EET 2021

Am So., 24. Jan. 2021 um 23:34 Uhr schrieb Baltazár Radics
<baltazar.radics at gmail.com>:
> I'm trying to overlay a v4l2 input on the mjpeg stream of an android IP
> camera. The first few seconds are alright, but the overlay slowly lags
> behind more and more, and starts dropping frames.
> I also get the following warning:
> >
> > Thread message queue blocking; consider raising the
> > thread_queue_size option
> I have tried raising it but it doesn't seem to help.
> The command I'm using (the output is a v4l2loopback device):
> ffmpeg -i -i /dev/video3 -filter_complex
> '[0:v]scale=iw*4/3:-1,crop=1280:720[cam];[1:v]scale=4*iw:-1:flags=neighbor[calc];[cam][calc]overlay'
> -vcodec rawvideo -pix_fmt yuv420p -f v4l2 /dev/video2

Please test current FFmpeg git head and provide the command line you tested
together with the complete, uncut console output.

> Overlaying a v4l2 source on another v4l2 source works perfectly with the
> same filter.

Feel free to show this one as well.

Carl Eugen

More information about the ffmpeg-user mailing list