[Ffmpeg-devel] [PATCH] reduce MAX_SCAN_PACKETS in mpegts.c

Michael Niedermayer michaelni
Sun Aug 27 09:32:56 CEST 2006


Hi

On Sun, Aug 27, 2006 at 12:49:57AM +0200, Nico Sabbi wrote:
[...]
> >would help?
> >alternatively you could pass the threshold over AVFormatParameters, but
> >somehow i never liked AVFormatParameters, as you tend to end up copying
> >and dupliating variables, it also doesnt fit into the AVOption stuff at
> >all ...
> >
> >
> >[...]
> > 
> >
> 
> I agree. Updated patch attached.
> Thanks for your help

> Index: libavformat/avformat.h
> ===================================================================
> --- libavformat/avformat.h	(revisione 6099)
> +++ libavformat/avformat.h	(copia locale)
> @@ -106,6 +106,7 @@
>      int channel; /* used to select dv channel */
>      const char *device; /* video, audio or DV device */
>      const char *standard; /* tv standard, NTSC, PAL, SECAM */
> +    int prealloced_context:1;
>      int mpeg2ts_raw:1;  /* force raw MPEG2 transport stream output, if possible */

i think that will break compatibility, putting the new field at the end of
the bitfields seems safer

[...]
> +    for(i=0; i<opt_name_count; i++){
> +             AVOption *opt;
> +             double d= av_get_double(avformat_opts, opt_names[i], &opt);
> +    
> +             if(d==d && (opt->flags&AV_OPT_FLAG_DECODING_PARAM))
> +                 av_set_double(ic, opt_names[i], d);
> +    }

indention looks wrong


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

In the past you could go to a library and read, borrow or copy any book
Today you'd get arrested for mere telling someone where the library is




More information about the ffmpeg-devel mailing list