[FFmpeg-devel] [PATCH] lavformat: Fixed processing teletext descriptor and packets in mpegts
Michael Niedermayer
michaelni at gmx.at
Wed May 29 23:28:09 CEST 2013
On Tue, May 21, 2013 at 05:17:54PM +0400, Dzmitry Kamiahin wrote:
> Hi!
>
> I attached patch which fixed muxing dvb_teletext problem for mpegts
>
> Thanks.
> ---
> libavformat/mpegts.c | 7 +++++++
> libavformat/mpegtsenc.c | 33 ++++++++++++++++++++++++++++++---
> 2 files changed, 37 insertions(+), 3 deletions(-)
>
> diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c
> index 85b5146..da8bba8 100644
> --- a/libavformat/mpegts.c
> +++ b/libavformat/mpegts.c
> @@ -1365,6 +1365,13 @@ int ff_parse_mpeg2_descriptor(AVFormatContext *fc,
> AVStream *st, int stream_type
> }
> break;
> case 0x56: /* DVB teletext descriptor */
> + /* copy all descriptor's data (ETSI EN 300 468 - 6.2.43) */
> + if (!st->codec->extradata) {
> + st->codec->extradata = av_malloc(desc_len +
> FF_INPUT_BUFFER_PADDING_SIZE);
> + st->codec->extradata_size = desc_len;
> + memcpy(st->codec->extradata, *pp, desc_len);
> + }
> + /* parse language in first descriptor */
extradata is only for "constant" non changing information.
the data doesnt sound constant from reading the spec but rather
changing to indicate the transmitted data if i dont misunderstand it
Changing information should be exported through AVPackets
either .data or side data
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130529/6fcc3435/attachment.asc>
More information about the ffmpeg-devel
mailing list