[FFmpeg-devel] [PATCH] Add PJS subtitles demuxer and decoder.

Alexander Strasser eclipse7 at gmx.net
Sun Dec 30 17:29:57 CET 2012


Nicolas George wrote:
> L'octidi 8 nivôse, an CCXXI, Clement Boesch a écrit :
> > +++ b/libavformat/pjsdec.c
[...]
> > +
> > +        pts_start = read_ts(&p, &duration);
> > +        if (pts_start != AV_NOPTS_VALUE) {
> > +            AVPacket *sub;
> > +
> > +            p[strcspn(p, "\"")] = 0;
> > +            sub = ff_subtitles_queue_insert(&pjs->q, p, strlen(p), 0);
> > +            if (!sub)
> > +                return AVERROR(ENOMEM);
> > +            sub->pos = pos;
> > +            sub->pts = pts_start;
> > +            sub->duration = duration;
> > +        }
> 
> I believe this part is missing error report when garbage is found.

  Not sure if it applies here too. But Clement mentioned in another
review that he likes to silently ignore garbage lines because they
may be just unsupported features. In that case it may be a good
idea to log that the line was ignored but at a verbose level higher
than the default one.

[...]

  Alexander


More information about the ffmpeg-devel mailing list