diff options
author | Janne Grunau <janne-ffmpeg@jannau.net> | 2009-07-26 23:08:04 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2009-07-26 23:08:04 +0000 |
commit | 6dc13ccbcc12d72b3746664edf44fcccf5d277fb (patch) | |
tree | f14fee307d7f73deeb1bca0f9f51bcf736048584 /libavcodec | |
parent | 7e4ceabe7ceccb5d9d8a85dedfd7a9cdfc426ae8 (diff) | |
download | ffmpeg-6dc13ccbcc12d72b3746664edf44fcccf5d277fb.tar.gz |
Set subtitle type in DVD and XSUB subtitle decoders.
Patch by Janne Grunau <ja?ne-f?mpeg jannau net>.
Originally committed as revision 19512 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/dvdsubdec.c | 1 | ||||
-rw-r--r-- | libavcodec/xsubdec.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/dvdsubdec.c b/libavcodec/dvdsubdec.c index 8abf700688..6c0756b6a4 100644 --- a/libavcodec/dvdsubdec.c +++ b/libavcodec/dvdsubdec.c @@ -353,6 +353,7 @@ static int decode_dvd_subtitles(AVSubtitle *sub_header, sub_header->rects[0]->y = y1; sub_header->rects[0]->w = w; sub_header->rects[0]->h = h; + sub_header->rects[0]->type = SUBTITLE_BITMAP; sub_header->rects[0]->pict.linesize[0] = w; } } diff --git a/libavcodec/xsubdec.c b/libavcodec/xsubdec.c index ccb9bf92e5..4754987f54 100644 --- a/libavcodec/xsubdec.c +++ b/libavcodec/xsubdec.c @@ -91,6 +91,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, av_freep(&sub->rects[0]->pict.data[0]); sub->rects[0]->x = x; sub->rects[0]->y = y; sub->rects[0]->w = w; sub->rects[0]->h = h; + sub->rects[0]->type = SUBTITLE_BITMAP; sub->rects[0]->pict.linesize[0] = w; sub->rects[0]->pict.data[0] = av_malloc(w * h); sub->rects[0]->nb_colors = 4; |