harbour-fernschreiber
harbour-fernschreiber copied to clipboard
messageAnimation loop
Even though it'll not be perfect due to the qt limitations (manual loop handling; visible breaks before restarting), sub-one-second animations are barely visible without looping.
See https://github.com/Wunderfitz/harbour-fernschreiber/blob/fba20712b23cc288722196a71d68cc09d95512d3/qml/components/inlineQueryResults/InlineQueryResultAnimation.qml#L261 for example implementation.
Probably it is possible to stack two times the same Animation and start and stop them and hide and show alternating. Will be difficult from the timing-side, but could be possible.
There's bug in a Sailfish OS specific gstreamer plugin which causes video playback to stop a few hundred milliseconds too early, which is especially noticeable on short (e.g. 1 sec) videos/animations. Looping won't look perfect. I actually prototyped it at some point, didn't like the result and decided not to submit the patch.
This recent change in droidmedia should improve the simulation. But it's not part of any public release yet.
The droidmedia change mentioned above landed in SFOS 4.0, but "built-in" loops (MediaPlayer
) still have a considerable pauses (VideoOutput
gets transparent for a while) before restarting videos from the beginning.
A possible Workaround may be to just seek(0)
when onStopped
is emitted (since we just pause otherwise instead of stopping). I haven't tried that, yet.