[vlc-commits] demux: mp4: fix ttml / handlers regression

Francois Cartegnie git at videolan.org
Sat Mar 17 20:02:29 CET 2018


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Sat Mar 17 19:02:49 2018 +0100| [9e71a998d1ac4e83ba160c372457c775ed6af0ff] | committer: Francois Cartegnie

demux: mp4: fix ttml / handlers regression

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=9e71a998d1ac4e83ba160c372457c775ed6af0ff
---

 modules/demux/mp4/libmp4.c | 1 +
 modules/demux/mp4/mp4.c    | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/modules/demux/mp4/libmp4.c b/modules/demux/mp4/libmp4.c
index 11b0d79f09..d9b84cae8c 100644
--- a/modules/demux/mp4/libmp4.c
+++ b/modules/demux/mp4/libmp4.c
@@ -4705,6 +4705,7 @@ static int MP4_ReadBox_default( stream_t *p_stream, MP4_Box_t *p_box )
             case ATOM_hint:
                 return MP4_ReadBox_sample_hint8( p_stream, p_box );
             case ATOM_text:
+            case ATOM_subt:
             case ATOM_tx3g:
             case ATOM_sbtl:
                 return MP4_ReadBox_sample_text( p_stream, p_box );
diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index 8a16e41c3c..f1adc2de30 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -2965,7 +2965,9 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
         break;
 
     case SPU_ES:
-        if ( p_sample->i_handler != ATOM_text ||
+        if ( ( p_sample->i_handler != ATOM_text &&
+               p_sample->i_handler != ATOM_subt &&
+               p_sample->i_handler != ATOM_sbtl ) ||
              !SetupSpuES( p_demux, p_track, p_sample ) )
            return VLC_EGENERIC;
         break;



More information about the vlc-commits mailing list