-
Notifications
You must be signed in to change notification settings - Fork 47
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
Delayed optimization #21
Comments
Hi, Could you please try commenting this line: FFmpegPlayer/video/videoparserunnable.cpp Line 157 in aee8686
|
I 've already tried. comment the line. There's no delay. Using OBS to push the camera will be a little bit video and audio are out of sync. Can you shorten the display time? |
Just to be sure. You mentioned another code line. Have you tried this one? |
I am sorry, it looked like you were talking about the line with boost::this_thread::sleep_for() previously |
The problem is not very large, playing video stream, think RTSP playing video delay should be only about 200 MS |
This seems to be tricky area: |
Hi, when I used the ffmpet push camera and then played RTSP video with player, I found that the delay was about 1 second, mainly caused by the displayRunnable() thread, and if deleted
for (;;)
{
const double delay = m_videoStartClock + current_frame.m_pts - GetHiResTime();
if (delay < 0.005)
break;
if (delay > 0.1)
{
boost::this_thread::sleep_for(
boost::chrono::milliseconds(100 * speedDenominator / speedNumerator));
continue;
}
There will be no delay, but it will cause the audio and video to be out of sync.
How can we optimize it?
The text was updated successfully, but these errors were encountered: