GNOME Bugzilla – Bug 692397
New plugin for MPEG TS time shifting
Last modified: 2018-11-03 13:14:09 UTC
Created attachment 234220 [details] [review] Proposed implementation tstimeshift: New plugin for MPEG TS time shifting This is an initial proposal. I'd like to ask for any help, views, suggestions and directions. The plugin is base on Fluendo timeshift element [1] although quite substantially changed. The proposed code is maintained on GitHub [2]. The gsttstimeshift comprises several elements that can be used for MPEG TS time shifting: tsshifter : Time Shift for MPEG TS streams tsshifterbin : Time Shift + TS parser for MPEG TS streams tsseeker : Time Shift seeker tsindexer : Indexer for MPEG-TS streams A typical pipeline that makes use of them would look like: <some MPEG TS src> ! tsshifterbin ! <some MPEG TS sink> The tsshifterbin element will instantiate elements as follows: tsparse ! tsindexer ! tsshifter ! tsseeker and prepare tsindexer ("tune" it to look for the right PID containing PCRs). Potentially tsshifter can be replaced with queue2 (see the problems below) and this is actually one of the goals. Problems still to be considered/solved/improved: --------------------------------------- - naming Both tsindexer and tsseeker are supposed to be MPEG TS agnostic but ATM they are TS specific, hence their names. Also the tsshifter is actually a ring buffer. - tsindexer * uses overengineered for this use case and abandoned GstIndex API (local copy) * can't remove index entries * can't write the index to the disk * duplicates parsing TS packets logic from tsparse tsparse would have to be improved to send some additional timestamp information (e. g. as tags or as buffer timestamps) so that the indexer could pick them up. The indexer itself could be a generic component (no knowledge about TS packets), hard to come up with the right format though. - tsindexer and tsseeker share an index object while it should be shared through some index database - tsshifter * it's actually a ring buffer, not a shifter (see naming notes above) * ideally it should be replaced with queue2 * as a first attempt, replacement could be optional (both tsshifter and queue2 co-exist) There are still some issues when using queue2 instead of tsshifter that have to be solved. * as a goal tsshifter could be completely replaced with queue2 which might require some changes/improvements of the latter: * custom allocator can be used (see FileMemAllocator: https://bugzilla.gnome.org/show_bug.cgi?id=691299) - tests still to be written - documentation [1] https://github.com/kkonopko/gst-fluendo-timeshift [2] https://github.com/kkonopko/gst-plugins-bad/tree/ts-timeshifter-element
See also: prior discussion[1][2] on the gstreamer-devel: [1]: http://gstreamer-devel.966125.n4.nabble.com/implementing-timeshifter-is-GstIndex-going-to-be-ever-public-again-tt4656714.html [2]: http://gstreamer-devel.966125.n4.nabble.com/implementing-timeshifter-is-GstIndex-going-to-be-ever-public-again-tt4656716.html
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/85.