Page 1 of 1

Inconsistent audio and video duration causes seek to freeze

Posted: 28 Oct 2024 07:28
by miao
The duration of the video and audio is inconsistent, with the audio being shorter. When the audio finishes playing, if you perform a seek fast-forward operation, the video will freeze and keep spinning. I now want the video to still be able to seek normally. Where is the code that handles this logic, and how should I modify it?

Re: Inconsistent audio and video duration causes seek to freeze

Posted: 28 Oct 2024 08:22
by Aza
Do you have a sample to share? If you want to take a look at it yourself, you should start here: https://code.videolan.org/videolan/vlc

Re: Inconsistent audio and video duration causes seek to freeze

Posted: 28 Oct 2024 13:38
by miao
Do you have a sample to share? If you want to take a look at it yourself, you should start here: https://code.videolan.org/videolan/vlc
Thank you for your response.
What do you specifically mean by "sample"? I am playing a file where the video duration is longer than the audio duration. After the audio ends, if I perform a seek, the video freezes. I think this might be due to a problem with audio-video synchronization. When using the standard version of VLC, playback works fine, and I can still seek after the audio ends. Since I am customizing VLC-Android, I would like to know exactly which code files or a few files handle this logic, or if you can tell me the general approach to solving this issue, that would be great (I also considered the case where the video duration is less than the audio duration). Thank you very much.

Re: Inconsistent audio and video duration causes seek to freeze

Posted: 29 Oct 2024 07:25
by Aza
What do you specifically mean by "sample"?
A file that can reproduce this issue.
I would like to know exactly which code files or a few files handle this logic
This is handled by the core and not vlc-android.