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 765498 - qtdemux: Fix key_time in gst_qtdemux_adjust_seek()
qtdemux: Fix key_time in gst_qtdemux_adjust_seek()
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
git master
Other Linux
: Normal normal
: 1.10.3
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-04-24 12:48 UTC by Seungha Yang
Modified: 2017-01-09 13:52 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
qtdemux: Fix key_time in gst_qtdemux_adjust_seek() (1010 bytes, patch)
2016-04-24 12:49 UTC, Seungha Yang
committed Details | Review
Log with proposed patch (9.69 KB, text/x-log)
2016-04-24 12:50 UTC, Seungha Yang
  Details
Log without proposed patch (9.89 KB, text/x-log)
2016-04-24 12:50 UTC, Seungha Yang
  Details

Description Seungha Yang 2016-04-24 12:48:21 UTC
time in segment should be PTS based (not DTS).
Comment 1 Seungha Yang 2016-04-24 12:49:22 UTC
Created attachment 326632 [details] [review]
qtdemux: Fix key_time in gst_qtdemux_adjust_seek()
Comment 2 Seungha Yang 2016-04-24 12:50:12 UTC
Created attachment 326633 [details]
Log with proposed patch
Comment 3 Seungha Yang 2016-04-24 12:50:38 UTC
Created attachment 326634 [details]
Log without proposed patch
Comment 4 Seungha Yang 2016-04-24 13:00:32 UTC
- In case of KEY_UNIT seeking, qtdemux finds offset of keyframe.

qtdemux.c:1483:gst_qtdemux_perform_seek:<qtdemux0>^[[00m seeking to 0:04:48.360944166
.
.
qtdemux.c:1170:gst_qtdemux_find_keyframe:<qtdemux0>^[[00m searching for keyframe index before index 6913 gave 6816
qtdemux.c:1314:gst_qtdemux_adjust_seek:<qtdemux0>^[[00m keyframe at 6816 with time 0:04:44.284000000 at offset 112041550

- Then, qtdemux do similar thing when state_movie. But, due to incorrect segment value (results from gst_qtdemux_adjust_seek() function), going back further....

qtdemux.c:4519:gst_qtdemux_activate_segment:<qtdemux0:video_0>^[[00m moving data pointer to 0:04:44.284000000, index: 6814, pts 0:04:44.284000000
qtdemux.c:1170:gst_qtdemux_find_keyframe:<qtdemux0>^[[00m searching for keyframe index before index 6814 gave 6775
qtdemux.c:4572:gst_qtdemux_activate_segment:<qtdemux0:video_0>^[[00m moving backwards to keyframe at 6775 (pts 0:04:42.657000000 dts 0:04:42.574000000 )

- With this patch, the bug can be fixed
qtdemux.c:1483:gst_qtdemux_perform_seek:<qtdemux0>^[[00m seeking to 0:04:48.150215000
.
.
qtdemux.c:1170:gst_qtdemux_find_keyframe:<qtdemux0>^[[00m searching for keyframe index before index 6908 gave 6816
qtdemux.c:1314:gst_qtdemux_adjust_seek:<qtdemux0>^[[00m keyframe at 6816 with time 0:04:44.367000000 at offset 112041550
.
.
qtdemux.c:4519:gst_qtdemux_activate_segment:<qtdemux0:video_0>^[[00m moving data pointer to 0:04:44.367000000, index: 6816, pts 0:04:44.367000000
qtdemux.c:1170:gst_qtdemux_find_keyframe:<qtdemux0>^[[00m searching for keyframe index before index 6816 gave 6816
qtdemux.c:4572:gst_qtdemux_activate_segment:<qtdemux0:video_0>^[[00m moving backwards to keyframe at 6816 (pts 0:04:44.367000000 dts 0:04:44.284000000 )
Comment 5 Jan Schmidt 2017-01-03 04:13:54 UTC
Thanks! Pushed to master