diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-10-14 11:33:25 +0200 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-10-21 12:02:29 +0200 |
commit | a17a7661906ba295d67afd80ac0770422e1b02b3 (patch) | |
tree | 37dd2b426804d375f7b79f79c1fca43eb2baac8f /libavcodec/dvbsub.c | |
parent | f890677d05bc4e8b494a73373ab4cc19791bf884 (diff) | |
download | ffmpeg-a17a7661906ba295d67afd80ac0770422e1b02b3.tar.gz |
lavc: Add data and linesize to AVSubtitleRect
Use the new fields directly instead of the ones from AVPicture.
This removes a layer of indirection which serves no pratical purpose
whatsoever, and will help in removing AVPicture structure completely
later.
Every subtitle encoder/decoder seamlessly points to the new arrays,
so it is possible to deprecate AVSubtitleRect.pict.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavcodec/dvbsub.c')
-rw-r--r-- | libavcodec/dvbsub.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/dvbsub.c b/libavcodec/dvbsub.c index 720e78669a..548bae1ca0 100644 --- a/libavcodec/dvbsub.c +++ b/libavcodec/dvbsub.c @@ -262,7 +262,7 @@ static int encode_dvb_subtitles(DVBSubtitleContext *s, *q++ = (1 << (7 - bpp_index)) | (0xf << 1) | 1; /* 2 bits/pixel full range */ { int a, r, g, b; - uint32_t x= ((uint32_t*)h->rects[clut_id]->pict.data[1])[i]; + uint32_t x= ((uint32_t*)h->rects[clut_id]->data[1])[i]; a = (x >> 24) & 0xff; r = (x >> 16) & 0xff; g = (x >> 8) & 0xff; @@ -359,10 +359,10 @@ static int encode_dvb_subtitles(DVBSubtitleContext *s, dvb_encode_rle = dvb_encode_rle4; top_ptr = q; - dvb_encode_rle(&q, h->rects[object_id]->pict.data[0], h->rects[object_id]->w * 2, + dvb_encode_rle(&q, h->rects[object_id]->data[0], h->rects[object_id]->w * 2, h->rects[object_id]->w, h->rects[object_id]->h >> 1); bottom_ptr = q; - dvb_encode_rle(&q, h->rects[object_id]->pict.data[0] + h->rects[object_id]->w, + dvb_encode_rle(&q, h->rects[object_id]->data[0] + h->rects[object_id]->w, h->rects[object_id]->w * 2, h->rects[object_id]->w, h->rects[object_id]->h >> 1); |