[FFmpeg-user] (no subject)

Karlitos Bemowo karolek150101 at gmail.com
Tue Dec 3 12:48:47 EET 2024


I’m trying to analyze the quality of a video stream over a local network
using FFmpeg. My goal is to capture the actual streamed video (with all
artifacts, stuttering, or buffering) as experienced in real-time, rather
than a reconstructed, smooth output. Currently, the recorded video is
perfectly smooth, but the live stream played using ffplay exhibits
noticeable stuttering. Additionally, while the duration of the recording
matches the original video, the live stream lasts longer, likely due to
buffering caused by network instability.

Here are the commands I’m using:
Sender: ffmpeg -re -i file.mp4 -c:v libx265 -preset veryfast -f mpegts
udp://192.168.1.26:1234
Receiver: ffmpeg -i udp://192.168.1.10:1234 -c copy received_fhd.mp4
-fflags nobuffer

The recorded file received_fhd.mp4 plays back perfectly, with no stuttering
or frame drops, even though the network stream has visible issues when
viewed in real-time with ffplay.The recorded file has the same duration as
the original video (fhd.mp4), while the real-time stream playback with
ffplay takes longer, suggesting delays caused by buffering or network
issues. Same issue with with other codes for example vp9.

GOAL: I want to capture the actual streamed video as experienced in
real-time, with all stuttering, buffering, and artifacts included. This
would allow me to analyze the network's impact on the video quality
effectively.

Questions:

   1. How can I modify my commands to record the video stream exactly as it
   is experienced in real-time, including any network-induced issues?
   2. Is there a way to configure FFmpeg to behave more like ffplay in
   terms of handling and recording the stream?

Any guidance or alternative approaches would be greatly appreciated. Thank
you!

Experimented with different codecs (e.g., H.265, VP9) and output formats.
Older codes has no delay in transmission so I didn't notice the issue at
frist.

Explored various ffmpeg options like -fflags nobuffer and -c copy (as
documentation says " For example, -codec copy or -codec: copy would copy
all the streams without reencoding."), but it still doesn’t replicate the
actual stream behavior.


More information about the ffmpeg-user mailing list