Bug 307156 - Playback stuck for a few seconds at the end of video
Summary: Playback stuck for a few seconds at the end of video
Status: RESOLVED FIXED
Alias: None
Product: phonon-backend-gstreamer
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: 4.6-git
Platform: unspecified Linux
: NOR normal
Target Milestone: 4.7
Assignee: Harald Sitter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-21 13:14 UTC by Aurelien Gateau
Modified: 2013-01-08 13:48 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.6.3


Attachments
Test script to reproduce the bug (1.34 KB, application/octet-stream)
2012-09-21 13:14 UTC, Aurelien Gateau
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aurelien Gateau 2012-09-21 13:14:28 UTC
Created attachment 74079 [details]
Test script to reproduce the bug

When playing a video with phonon-gstreamer, the "finished()" signal is emitted 8 or 9 seconds after the end of the movie. This ruins the experience when using Gwenview to play slideshow in folders mixing photos and videos: at the end of the video the last frame stays there for a few seconds.

Attached test scripts shows the problem: start it with a video as argument and it will play it and show the time at which ticked() is emitted (and the tick value) as well as the time when finished() is emitted. With phonon-gstreamer, ticked() continues to be emitted for a few seconds at the end of the video. This does not happen with phonon-vlc.

On Gwenview side I could workaround this by checking if the tick value is the same for the last 3 or 4 calls, but that sounds ugly and may break.
Comment 1 Aurelien Gateau 2012-09-21 13:20:29 UTC
Forgot to add I reproduced this using master branches of  phonon (78e67a9dc5d3b847da192b7920b1cf21a09bf3fe) and phonon-gstreamer (4f65f6c1897f4855ed9c765e3cfffa38e25ad149)
Comment 2 Aurelien Gateau 2012-09-21 13:59:03 UTC
Git commit dd7f70ad936a7cb342cf52e9e100d485539b667e by Aurélien Gâteau.
Committed on 21/09/2012 at 15:56.
Pushed by gateau into branch 'workaround-phonon-gstreamer-finished-bug'.

Work around for phonon gstreamer bug

Current phonon gstreamer does not emit the finished() signal immediatly
after reaching the end of the video.

@Phonon people: do you think the workaround in this commit is
acceptable?

M  +13   -0    lib/documentview/videoviewadapter.cpp

http://commits.kde.org/gwenview/dd7f70ad936a7cb342cf52e9e100d485539b667e
Comment 3 Torrie Fischer 2012-09-21 20:09:58 UTC
I'm not able to reproduce the bug, are you sure you're using latest git? Sometimes even I get that messed up, as pgst from git might install to /usr/lib/ instead of /usr/lib64.
Comment 4 Torrie Fischer 2012-09-23 09:16:42 UTC
updating status
Comment 5 Aurelien Gateau 2012-10-18 20:37:41 UTC
Hi Trever, I checked it does happen with latest git. I sent you the url of a video to reproduce the problem via email. Did you try it?
Comment 6 Benni Hill 2013-01-05 22:41:06 UTC
Reopening since Aurélien supplied the info.
Comment 7 Aurelien Gateau 2013-01-08 13:48:07 UTC
This bug is fixed in phonon-gstreamer master and in the 4.6 branch. The fix should be in the 4.6.3 release.