[vlc-commits] Fixed "spu-elapsed" value set by the core.

Laurent Aimar git at videolan.org
Tue Jun 14 20:08:32 CEST 2011


vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Mon Jun 13 20:52:28 2011 +0200| [a296434cdb98acde13d815964d87339da71a16af] | committer: Laurent Aimar

Fixed "spu-elapsed" value set by the core.

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

 src/video_output/vout_subpictures.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/video_output/vout_subpictures.c b/src/video_output/vout_subpictures.c
index e920965..ea6929c 100644
--- a/src/video_output/vout_subpictures.c
+++ b/src/video_output/vout_subpictures.c
@@ -257,7 +257,7 @@ static filter_t *SpuRenderCreateAndLoadScale(vlc_object_t *object,
 
 static void SpuRenderText(spu_t *spu, bool *rerender_text,
                           subpicture_region_t *region,
-                          mtime_t render_date)
+                          mtime_t elapsed_time)
 {
     filter_t *text = spu->p->text;
 
@@ -285,7 +285,7 @@ static void SpuRenderText(spu_t *spu, bool *rerender_text,
      * least show up on screen, but the effect won't change
      * the text over time.
      */
-    var_SetTime(text, "spu-elapsed", render_date);
+    var_SetTime(text, "spu-elapsed", elapsed_time);
     var_SetBool(text, "text-rerender", false);
 
     if (text->pf_render_html && region->psz_html)
@@ -691,7 +691,7 @@ static void SpuRenderRegion(spu_t *spu,
     /* Render text region */
     if (region->fmt.i_chroma == VLC_CODEC_TEXT) {
         SpuRenderText(spu, &restore_text, region,
-                      render_date);
+                      render_date - subpic->i_start);
 
         /* Check if the rendering has failed ... */
         if (region->fmt.i_chroma == VLC_CODEC_TEXT)



More information about the vlc-commits mailing list