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 732294 - mxfdemux: Use IndexTableSegments
mxfdemux: Use IndexTableSegments
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal enhancement
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks: 759118
Reported: 2014-06-26 20:16 UTC by Mathieu Duponchelle
Modified: 2015-12-07 12:37 UTC
See Also:
GNOME target: ---
GNOME version: ---

Proposed patch to fix the issue (9.59 KB, patch)
2014-06-26 20:19 UTC, Mathieu Duponchelle
committed Details | Review
Scenario to validate the patch (135 bytes, text/scenario)
2014-06-26 20:20 UTC, Mathieu Duponchelle

Description Mathieu Duponchelle 2014-06-26 20:16:59 UTC
This patch integrates with the existing code in the following way:

For now, when a seek was requested in a position that hadn't been played back or seeked to previously, the whole file was parsed up from the current position to the requested position, and an index was filled.

A lot of MXF files contain IndexTableSegments, located at the beginning of each partition.

The position of each partition is provided by the random index pack, we now use this information when a seek is requested to directly skip to the relevant partition, the index is then filled and used as it was done previously.

One can test the patch with the scenario that I will attach and a (long enough to see the difference) MXF file containing Index Table Segments.

The time to make the initial seek is now considerably reduced, from 2 seconds to seek to the end of a 3-minute long MXF file to 0.04 seconds.

validating the patch can be done with :

gst-validate-1.0 playbin uri=file:///path/to/mxf --set-scenario /path/to/scenario

Additionally, standard validate tests were run with the files available , and no regressions were spotted.

Patch and scenario follow.
Comment 1 Mathieu Duponchelle 2014-06-26 20:19:04 UTC
Created attachment 279337 [details] [review]
Proposed patch to fix the issue
Comment 2 Mathieu Duponchelle 2014-06-26 20:20:00 UTC
Created attachment 279338 [details]
Scenario to validate the patch
Comment 3 Sebastian Dröge (slomo) 2015-10-23 19:14:30 UTC
This doesn't properly implement the algorithm from S377-1-2009c chapter 11, it's not that simple.