[Ffmpeg-devel] [PATCH] asf.[ch] patch to handle mms streaming....

Michael Niedermayer michaelni
Tue Nov 28 11:56:58 CET 2006


Hi

On Mon, Nov 27, 2006 at 05:28:00PM -0600, Ryan Martell wrote:
> A couple of minor modifications to handle mms streaming.
> 
> mms streaming patch will be forthcoming (if anyone is interested?)

yes mms support is welcome ...


[...]

> Index: asf.c
> ===================================================================
> --- asf.c	(revision 7177)
> +++ asf.c	(working copy)
> @@ -205,6 +205,11 @@
>              st->start_time = asf->hdr.preroll;
>              st->duration = asf->hdr.send_time /
>                  (10000000 / 1000) - st->start_time;
> +            if(asf->hdr.flags & 0x01) { // streaming; override these values
> +                st->duration= AV_NOPTS_VALUE;

somehow i think this should rather be:
if(!(asf->hdr.flags & 1))
    st->duration = asf->hdr.send_time / (10000000 / 1000) - st->start_time;
instead of setting it wrongly and then correcting it ...


> +                asf->nb_packets = asf->hdr.packets_count; // MAX_VALUE

is this not already set to that?


> +                asf->packet_timestamp_start = -1; // force the renumbering of packets (there could be overflow issues here)
> +            }
>              get_guid(pb, &g);
>  
>              test_for_ext_stream_audio = 0;
> @@ -333,6 +338,9 @@
>              } else {
>                  asf->data_object_size = (uint64_t)-1;
>              }
> +            if(asf->hdr.flags & 0x01) { // streaming (replace)
> +                asf->data_object_size = (uint64_t)-1;
> +            }

why not merge this with the else above?


[...]
-- 
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