]> git.sesse.net Git - vlc/commitdiff
Flush all subtitles when recycling a vout.
authorLaurent Aimar <fenrir@videolan.org>
Fri, 13 Feb 2009 22:53:31 +0000 (23:53 +0100)
committerLaurent Aimar <fenrir@videolan.org>
Fri, 13 Feb 2009 22:53:31 +0000 (23:53 +0100)
src/input/decoder [deleted file]
src/input/ressource.c
src/video_output/vout_subpictures.c

diff --git a/src/input/decoder b/src/input/decoder
deleted file mode 100644 (file)
index e69de29..0000000
index 11003d9a61aff409484d2e602091e723fc8f281b..a1698bdca378a1acdd0711e364e32c83bf90da67 100644 (file)
@@ -30,6 +30,7 @@
 
 #include <vlc_common.h>
 #include <vlc_vout.h>
+#include <vlc_osd.h>
 #include <vlc_aout.h>
 #include <vlc_sout.h>
 #include "../libvlc.h"
@@ -243,6 +244,8 @@ static vout_thread_t *RequestVout( input_ressource_t *p_ressource,
         {
             msg_Dbg( p_ressource->p_input, "saving a free vout" );
             vout_Flush( p_vout, 1 );
+            spu_Control( p_vout->p_spu, SPU_CHANNEL_CLEAR, -1 );
+
             p_ressource->p_vout_free = p_vout;
         }
         return NULL;
index eca71ab723530e84ad55e0a8e3c827d96909e040..1dc316ff4acad44e91874373a14d2dc3d887a161 100644 (file)
@@ -1675,7 +1675,9 @@ static void SpuClearChannel( spu_t *p_spu, int i_channel )
         spu_heap_entry_t *p_entry = &p_sys->heap.p_entry[i_subpic];
         subpicture_t *p_subpic = p_entry->p_subpicture;
 
-        if( !p_subpic || p_subpic->i_channel != i_channel )
+        if( !p_subpic )
+            continue;
+        if( p_subpic->i_channel != i_channel && ( i_channel != -1 || p_subpic->i_channel == DEFAULT_CHAN ) )
             continue;
 
         /* You cannot delete subpicture outside of spu_SortSubpictures */