[FFmpeg-devel] [PATCH/RFC] Fix dvbsub framing inconsistencies/add dvbsub bsf
Reimar Döffinger
Reimar.Doeffinger
Wed Sep 29 19:34:23 CEST 2010
On Tue, Sep 28, 2010 at 01:50:40PM +0200, Tomas H?rdin wrote:
> diff --git a/libavcodec/dvbsub.c b/libavcodec/dvbsub.c
> index ea55cae..08e05d4 100644
> --- a/libavcodec/dvbsub.c
> +++ b/libavcodec/dvbsub.c
> @@ -208,6 +208,7 @@ static int encode_dvb_subtitles(DVBSubtitleContext *s,
> if (h->num_rects == 0 || h->rects == NULL)
> return -1;
>
> + *q++ = 0x20; /* data_identifier */
> *q++ = 0x00; /* subtitle_stream_id */
> @@ -1429,7 +1429,8 @@ static int dvbsub_decode(AVCodecContext *avctx,
> if (buf_size <= 2)
> return -1;
>
> - p = buf;
> + //skip data_identifier and subtitle_stream_id
> + p = buf + 2;
I guess it might be useful to set/query the subtitle_stream_id, though
I admit that's a separate issue.
But please add a space between // and the text.
Otherwise I think it's ok, however I suspect this change might cause
issue with applications that use their own demuxer with the dvb subtitle
decoder, no idea if that is likely to be a real issue and whether
we should try to do something about it...
More information about the ffmpeg-devel
mailing list