[Bug 752847] New: matroska mux doesn't write user-supplied tags unless the 'streamable' property is set
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Fri Jul 24 16:40:11 PDT 2015
https://bugzilla.gnome.org/show_bug.cgi?id=752847
Bug ID: 752847
Summary: matroska mux doesn't write user-supplied tags unless
the 'streamable' property is set
Classification: Platform
Product: GStreamer
Version: unspecified
OS: Linux
Status: NEW
Severity: normal
Priority: Normal
Component: gst-plugins-good
Assignee: gstreamer-bugs at lists.freedesktop.org
Reporter: grd at loganmill.net
QA Contact: gstreamer-bugs at lists.freedesktop.org
GNOME version: ---
User-supplied tags are not written out unless 'streamable=true' is set. Easily
reproducible with gst-launch and mkvinfo.
We'll try to but the tag comment=hello into the x.mkv file:
$ gst-launch-1.0 videotestsrc ! taginject tags=comment=hello ! matroskamux !
filesink location=x.mkv
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:03.699848471
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
^C
$ mkvinfo x.mkv
+ EBML head
|+ Doc type: matroska
|+ Doc type version: 2
|+ Doc type read version: 2
+ Segment, size unknown
|+ Seek head (subentries will be skipped)
|+ Segment information
| + Segment UID: 0x12 0x21 0x11 0xd4 0x51 0x77 0xbe 0x8e 0xd1 0x31 0x26 0xa7
0x26 0x70 0x10 0x62
| + Timecode scale: 1000000
| + Duration: 0.000s (00:00:00.000)
| + Muxing application: GStreamer matroskamux version 1.5.2.1
| + Writing application: GStreamer Matroska muxer
| + Date: Fri Jul 24 23:05:15 2015 UTC
|+ Segment tracks
| + A track
| + Track number: 1 (track ID for mkvmerge & mkvextract: 0)
| + Track type: video
| + Track UID: 2201393592170869641
| + Default duration: 33.333ms (30.000 frames/fields per second for a video
track)
| + Name: Video
| + Video track
| + Pixel width: 320
| + Pixel height: 240
| + Colour space: length 4, data: 0x49 0x34 0x32 0x30
| + Codec ID: V_UNCOMPRESSED
|+ Cluster
...Note that the mkvinfo does not show the "comment" tag as being defined.
Rerun with the streamable property set:
$ gst-launch-1.0 videotestsrc ! taginject tags=comment=hello ! matroskamux
streamable=true ! filesink location=x.mkv
$ mkvinfo x.mkv
+ EBML head
|+ Doc type: matroska
|+ Doc type version: 2
|+ Doc type read version: 2
+ Segment, size unknown
|+ Tags
| + Tag
| + Targets
| + TrackUID: 127012133913909968
| + Simple
| + Name: COMMENTS
| + String: hello
|+ Segment information
| + Segment UID: 0x3d 0x73 0xba 0x2e 0x51 0x16 0xc9 0x66 0x5f 0x7b 0x83 0x4a
0xdb 0x82 0x8d 0xac
| + Timecode scale: 1000000
| + Muxing application: GStreamer matroskamux version 1.5.2.1
| + Writing application: GStreamer Matroska muxer
| + Date: Fri Jul 24 23:15:12 2015 UTC
|+ Segment tracks
| + A track
| + Track number: 1 (track ID for mkvmerge & mkvextract: 0)
| + Track type: video
| + Track UID: 127012133913909968
| + Default duration: 33.333ms (30.000 frames/fields per second for a video
track)
| + Name: Video
| + Video track
| + Pixel width: 320
| + Pixel height: 240
| + Colour space: length 4, data: 0x49 0x34 0x32 0x30
| + Codec ID: V_UNCOMPRESSED
|+ Cluster
...and the 'hello' comment is set.
It seems that streams_tags are written by the following call in matroska-mux.c,
which is only invoked when streamable is true:
if (mux->streamable) {
....
gst_matroska_mux_write_streams_tags (mux);
...
}
Disabling the mux->streamable conditional fixes the issue for me;
diff --git a/gst/matroska/matroska-mux.c b/gst/matroska/matroska-mux.c
index 9f79175..ff0971e 100644
--- a/gst/matroska/matroska-mux.c
+++ b/gst/matroska/matroska-mux.c
@@ -2729,7 +2729,8 @@ gst_matroska_mux_start (GstMatroskaMux * mux)
gst_ebml_write_master_finish (ebml, master);
}
- if (mux->streamable) {
+ // if (mux->streamable) {
+ if (1) { // Write tags regardless of value of mux->streamable
const GstTagList *tags;
gboolean has_main_tags;
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list