* Pass along the SSA header in mkv files to the decoder.
authorDerk-Jan Hartman <hartman@videolan.org>
Sun, 22 Jan 2006 22:54:57 +0000 (22:54 +0000)
committerDerk-Jan Hartman <hartman@videolan.org>
Sun, 22 Jan 2006 22:54:57 +0000 (22:54 +0000)
modules/demux/mkv.cpp

index 6b7ec4f..177afb4 100644 (file)
@@ -2421,6 +2421,12 @@ bool matroska_segment_c::Select( mtime_t i_start_time )
         {
             tracks[i_track]->fmt.i_codec = VLC_FOURCC( 's', 's', 'a', ' ' );
             tracks[i_track]->fmt.subs.psz_encoding = strdup( "UTF-8" );
+            if( tracks[i_track]->i_extra_data ) 
+            {
+                tracks[i_track]->fmt.i_extra = tracks[i_track]->i_extra_data;
+                tracks[i_track]->fmt.p_extra = malloc( tracks[i_track]->i_extra_data );
+                memcpy( tracks[i_track]->fmt.p_extra, tracks[i_track]->p_extra_data, tracks[i_track]->i_extra_data );
+            }
         }
         else if( !strcmp( tracks[i_track]->psz_codec, "S_VOBSUB" ) )
         {