[vlc-commits] commit: Add support for DivX XSUB subtitle streams. (Jai Menon )
git at videolan.org
git at videolan.org
Wed May 26 15:17:24 CEST 2010
vlc | branch: master | Jai Menon <jmenon86 at gmail.com> | Wed May 26 17:20:20 2010 +0530| [f5b8f4a13fe40151abd54a009049e5d9a6e6780c] | committer: Jean-Baptiste Kempf
Add support for DivX XSUB subtitle streams.
This close #2383
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=f5b8f4a13fe40151abd54a009049e5d9a6e6780c
---
modules/codec/avcodec/subtitle.c | 1 +
modules/demux/avi/avi.c | 2 ++
modules/demux/avi/libavi.h | 2 ++
3 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/modules/codec/avcodec/subtitle.c b/modules/codec/avcodec/subtitle.c
index 20284b2..205e02b 100644
--- a/modules/codec/avcodec/subtitle.c
+++ b/modules/codec/avcodec/subtitle.c
@@ -66,6 +66,7 @@ int InitSubtitleDec(decoder_t *dec, AVCodecContext *context,
/* */
switch (codec_id) {
case CODEC_ID_HDMV_PGS_SUBTITLE:
+ case CODEC_ID_XSUB:
break;
default:
msg_Warn(dec, "refusing to decode non validated subtitle codec");
diff --git a/modules/demux/avi/avi.c b/modules/demux/avi/avi.c
index 55d794a..b522217 100644
--- a/modules/demux/avi/avi.c
+++ b/modules/demux/avi/avi.c
@@ -450,6 +450,7 @@ static int Open( vlc_object_t * p_this )
{
msg_Dbg( p_demux, "stream[%d] subtitles", i );
es_format_Init( &fmt, SPU_ES, p_vids->p_bih->biCompression );
+ tk->i_cat = SPU_ES;
break;
}
else if( p_vids->p_bih->biCompression == 0x00 )
@@ -1921,6 +1922,7 @@ static void AVI_ParseStreamHeader( vlc_fourcc_t i_id,
SET_PTR( pi_type, VIDEO_ES );
break;
case AVITWOCC_tx:
+ case AVITWOCC_sb:
SET_PTR( pi_type, SPU_ES );
break;
default:
diff --git a/modules/demux/avi/libavi.h b/modules/demux/avi/libavi.h
index a9510c4..3862cf9 100644
--- a/modules/demux/avi/libavi.h
+++ b/modules/demux/avi/libavi.h
@@ -300,6 +300,8 @@ void AVI_ChunkFreeRoot( stream_t *, avi_chunk_t *p_chk );
#define AVITWOCC_pc VLC_TWOCC('p','c')
#define AVITWOCC_AC VLC_TWOCC('A','C')
#define AVITWOCC_tx VLC_TWOCC('t','x')
+#define AVITWOCC_sb VLC_TWOCC('s','b')
+
/* *** codex stuff *** */
/* DV */
More information about the vlc-commits
mailing list