[FFmpeg-user] MPD generated by ldash
jtheta
jtheta at protonmail.com
Sun Apr 26 06:39:54 EEST 2020
Hello,
I am working on a live stream pipeline from IP Cameras to web clients using DASH.
I run on demand FFmpeg to convert the RTSP stream from IP cameras, generate dash chunks and upload to my media server through HTTP and then serve the feed to my web clients.
Everything works well but unfortunately the first MPD file is generated after 4-5 seconds slowing down the entire video pipeline (I see the video after about 7-8s from when I request it)
Here is the command:
ffmpeg \
-rtsp_transport tcp -i rtsp://172.25.99.200/axis-media/media.amp \
-an -c:v libx264 -pix_fmt yuv420p -b:v 2048k -bufsize 4096k -tune zerolatency -preset ultrafast \
-fflags +genpts -f dash -format_options movflags=+empty_moov+default_base_moof+frag_keyframe \
-tune zerolatency -seg_duration 1 -frag_duration 0.2 -use_timeline 1 -use_template 1 -streaming 1 \
http://localhost:8000/live/mystream/start.mpd
So here the question, is there a way to get the manifest earlier? Basically what I observe is that FFmpeg generates the init file, then the first chunk and when the chunk is done, it will generated the MPD.
Unfortunately this will take at least 4s regardless the seg_duration.
I am asking since I don't understand if this lag is needed or just the way the code is implemented.
Thanks!
Sent with [ProtonMail](https://protonmail.com) Secure Email.
More information about the ffmpeg-user
mailing list