[FFmpeg-cvslog] r9591 - in trunk: libavcodec/avcodec.h libavformat/matroska.c libavformat/matroskadec.c
aurel
subversion
Wed Jul 11 15:13:20 CEST 2007
Author: aurel
Date: Wed Jul 11 15:13:20 2007
New Revision: 9591
Log:
add support for Matroska subtitle tracks
Modified:
trunk/libavcodec/avcodec.h
trunk/libavformat/matroska.c
trunk/libavformat/matroskadec.c
Modified: trunk/libavcodec/avcodec.h
==============================================================================
--- trunk/libavcodec/avcodec.h (original)
+++ trunk/libavcodec/avcodec.h Wed Jul 11 15:13:20 2007
@@ -262,6 +262,7 @@ enum CodecID {
/* subtitle codecs */
CODEC_ID_DVD_SUBTITLE= 0x17000,
CODEC_ID_DVB_SUBTITLE,
+ CODEC_ID_TEXT,
CODEC_ID_MPEG2TS= 0x20000, /* _FAKE_ codec to indicate a raw MPEG-2 TS
* stream (only used by libavformat) */
Modified: trunk/libavformat/matroska.c
==============================================================================
--- trunk/libavformat/matroska.c (original)
+++ trunk/libavformat/matroska.c Wed Jul 11 15:13:20 2007
@@ -58,6 +58,11 @@ CodecTags ff_mkv_codec_tags[]={
{"A_REAL/ATRC" , CODEC_ID_ATRAC3},
{"A_REAL/COOK" , CODEC_ID_COOK},
// {"A_REAL/SIPR" , CODEC_ID_SIPRO},
+
+ {"S_TEXT/ASCII" , CODEC_ID_TEXT},
+ {"S_TEXT/UTF8" , CODEC_ID_TEXT},
+ {"S_VOBSUB" , CODEC_ID_DVD_SUBTITLE},
+
{NULL , CODEC_ID_NONE}
/* TODO: AC3-9/10 (?), Real, Musepack, Quicktime */
};
Modified: trunk/libavformat/matroskadec.c
==============================================================================
--- trunk/libavformat/matroskadec.c (original)
+++ trunk/libavformat/matroskadec.c Wed Jul 11 15:13:20 2007
@@ -2028,10 +2028,8 @@ matroska_read_header (AVFormatContext
track = matroska->tracks[i];
track->stream_index = -1;
- /* libavformat does not really support subtitles.
- * Also apply some sanity checks. */
- if ((track->type == MATROSKA_TRACK_TYPE_SUBTITLE) ||
- (track->codec_id == NULL))
+ /* Apply some sanity checks. */
+ if (track->codec_id == NULL)
continue;
for(j=0; ff_mkv_codec_tags[j].str; j++){
More information about the ffmpeg-cvslog
mailing list