After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 791408 - basic-tutorial-8/playback-tutorial-3: fix buffer duration calculations
basic-tutorial-8/playback-tutorial-3: fix buffer duration calculations
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: documentation
git master
Other All
: Normal minor
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-12-08 21:15 UTC by Aleksandr Slobodeniuk
Modified: 2017-12-09 12:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to fix it (1.11 KB, patch)
2017-12-08 21:15 UTC, Aleksandr Slobodeniuk
committed Details | Review

Description Aleksandr Slobodeniuk 2017-12-08 21:15:37 UTC
Created attachment 365275 [details] [review]
Patch to fix it

Just a little fix of example's code found by revision.
Buffer duration was counted from buffer's size in bytes, like it were number of samples.
It looks like patch doesn't affect on anything.
Comment 1 Sebastian Dröge (slomo) 2017-12-09 12:02:40 UTC
commit 30f8595780c0475d83b8950b3a4922e850aafbd0 (HEAD -> master)
Author: Sebastian Dröge <sebastian@centricular.com>
Date:   Sat Dec 9 14:01:51 2017 +0200

    playback-tutorial-3/basic-tutorial-8: Fix buffer duration calculations
    
    Same as last commit in various other places
    
    https://bugzilla.gnome.org/show_bug.cgi?id=791408

commit ea888a0e3baa106f926d0ded1fd5501a6aae6bd5
Author: Aleksandr Slobodeniuk <alenuke@yandex.ru>
Date:   Sat Dec 9 00:07:17 2017 +0300

    basic-tutorial-8: Fix buffer duration calculation
    
    Buffer duration was counted from buffer's size in bytes, like it were number of samples.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=791408
Comment 2 Sebastian Dröge (slomo) 2017-12-09 12:04:52 UTC
Thanks for the patch!

It has no effect (usually) because almost no element is using the duration of raw audio buffers, but instead works with the number of samples contained in them or even just the timestamps.