Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cumulative delays #72

Open
MichaelLiaoFeng opened this issue Jul 23, 2020 · 1 comment
Open

cumulative delays #72

MichaelLiaoFeng opened this issue Jul 23, 2020 · 1 comment

Comments

@MichaelLiaoFeng
Copy link

I have a problem with cumulative delays.

My software is developed based on electron, runs in the local area network, and plays the camera RTSP stream.

My computer configuration is as follows:

image

image

The parameters of low-latency playback in the document.

image

const mpvProperty = ['profile=low-latency', 'cache-pause=yes', 'framedrop=no', 'speed=1.01', 'opengl-glfinish=yes']

mpvProperty.forEach(prop => {
  this.playerInstance._sendProperty(...prop.split('='))
})

this.playerInstance.loadFile(this.streamUrl)

(The cache-pause is set to yes because it needs to be monitored and prompted to the user when buffering.)

After configuring the parameters, the delay is very low during the initial period of time, within 500 milliseconds, but after a period of time, the delay will accumulate up to ten seconds or even half a minute.

image

I guess it might be a caching problem, so I execute the drop-buffers command once every ten minutes. This has a certain effect but it is not ideal. Because the paused-for-cache event is often triggered after execution, and the delay after execution has not been reduced too much.

So I really don't understand which link caused the delay. The main video stream is 1920*1080. I can accept the reduction of video quality. How to configure the parameters?

Please help!

@lyg1949
Copy link

lyg1949 commented Aug 14, 2020

我觉得应该是mpv的问题,我也遇到了这个问题。
我用ffmpeg 将本地文件推送到rtsp服务,再用mpv拉流,延迟就很明显(与vlc相比,vlc就几乎没有延迟),不光这样,音视频同步还有问题。

应该是mpv对rtsp这种协议的支持不是很好造成的。

最好去mpv那里问更合适一些。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants