Unable to mux subtitle into a .mkv file

Victor vgdoqd at gmail.com
Wed Jul 25 11:07:23 UTC 2018


Hi,

The pipeline description is as follow:

```
gst-launch-1.0 -v \
videotestsrc num-buffers=300 \
! videoconvert \
! theoraenc \
! MUXER.video_%u \
filesrc location=src.srt \
! subparse \
! text/x-raw,format=utf8 \
! MUXER.subtitle_0 \
matroskamux name=MUXER \
! filesink location=dst.mkv
```

Whether or not a `capsfilter caps=text/x-raw,format=utf8` is between 
`subparse` and the muxer, it will fail.

Below is a simplistic `src.srt` that can be used to try the command:

```
1
00:00:01,000 --> 00:00:02,000
one

2
00:00:02,000 --> 00:00:03,000
two

3
00:00:03,000 --> 00:00:04,000
three

4
00:00:04,000 --> 00:00:05,000
four

5
00:00:05,000 --> 00:00:06,000
five

6
00:00:06,000 --> 00:00:07,000
six

7
00:00:07,000 --> 00:00:08,000
seven

8
00:00:08,000 --> 00:00:09,000
eight

9
00:00:09,000 --> 00:00:10,000
nine

10
00:00:10,000 --> 00:00:11,000
ten
```

According to `gst-inspect-1.0`, the source caps of subparse is 
`text/x-raw,format=pango-markup` or `text/x-raw,format=utf8`, but I 
don't know how to make it `text/x-raw,format=utf8`, since matroskamux 
does not accept `text/x-raw,format=pango-markup` among the two formats. 
I did successfully mux `subtitle/x-kate` subtitles by using matroskamux 
though, but that format is not supported by 2 of my favorite media 
player `mpv` and `vlc`. My system is Debian 9.5, and the GStreamer is 
version 1.14.2. Thanks.

Victor.


More information about the gstreamer-devel mailing list