]> git.sesse.net Git - vlc/commitdiff
Setting b_subtitle on subpictures during transcode, and applying correct timing.
authorBlake Livingston <blake.a.livingston@gmail.com>
Wed, 21 Jul 2010 05:42:32 +0000 (22:42 -0700)
committerLaurent Aimar <fenrir@videolan.org>
Wed, 21 Jul 2010 19:01:05 +0000 (21:01 +0200)
Signed-off-by: Laurent Aimar <fenrir@videolan.org>
modules/stream_out/transcode/spu.c
modules/stream_out/transcode/video.c

index d031d9a388eaf101f4554012d636660e7dcb8595..31211d9ce6a8c9c5799b67ae37a204f0305e2d98 100644 (file)
@@ -38,7 +38,9 @@ static subpicture_t *spu_new_buffer( decoder_t *p_dec,
                                      const subpicture_updater_t *p_upd )
 {
     VLC_UNUSED( p_dec );
-    return subpicture_New( p_upd );
+    subpicture_t *p_subpicture = subpicture_New( p_upd );
+    p_subpicture->b_subtitle = true;
+    return p_subpicture;
 }
 
 static void spu_del_buffer( decoder_t *p_dec, subpicture_t *p_subpic )
index 8afe2c2c6237e4ab6e903aa2820c7ecda2bf2739..6d4f855f61e96c2f526f767bba5bff82ff8b2ac0 100644 (file)
@@ -716,9 +716,8 @@ int transcode_video_process( sout_stream_t *p_stream, sout_stream_id_t *id,
             else
                 fmt = id->p_decoder->fmt_out.video;
 
-            /* FIXME the mdate() seems highly suspicious */
             spu_RenderSubpictures( p_sys->p_spu, p_pic, &fmt,
-                                   p_subpic, &id->p_decoder->fmt_out.video, mdate() );
+                                   p_subpic, &id->p_decoder->fmt_out.video, p_pic->date );
         }
 
         /* Run user specified filter chain */