Open tannker opened 6 months ago
If video is paused after load, the position should be the first video frame timestamp(there is a bug in current code and will be fixed soon). If not paused, the position varies. seek is the same.
Ok. Yes, what I have noticed is the position after initial load (sometimes 0, 20, 80 ms). I also noticed the same issue with seekTo to either to the start (Duration.zero - again 0, 20, 80 ms) or to the end (videoController.value.duration - position value differs slightly from the actual duration).
upgrade libmdk
pod cache clean mdk
pod deintegrate ios/Runner.xcodeproj
rm ios/Podfile.lock
rm -rf ios/Pods
Describe the bug After loading video, I call after few second delay videoController.positon.then((value){print(value)}. The result is inconsistent. Sometimes it returns 0, sometimes 20 or 80 milliseconds. The same issue occurs when calling position after videoController.seekTo. After seeking to the start (Duration.zero or Duration(milliseconds: 0) or to the end, the position value returned varies. The variation is in some milliseconds, but on most cases it is not equal to actual start or end. I made some debugging and it seems that this error is already present at video_player_mdk.dart function getPosition. This function I guess already gets input from libmdk.
Additionally, I updated mdk pod from 0.25.1 to the latest 0.27 one, but the behaviour remained the same. The test is made with latest version of fvp - 0.17.0. I am testing on MacOS Sonoma 14.4.1.
Expected behavior Position value is consistent across all calls.
Log