[FFmpeg-devel] [PATCH] WIP: lavf/segment: provide a virtual AVIOContext representing all the segments

Michael Niedermayer michaelni at gmx.at
Mon Mar 30 15:01:35 CEST 2015


On Sun, Mar 29, 2015 at 10:07:21PM -0600, Rodger Combs wrote:
> This needs a fair bit of testing and review before merge.
> 
> Re: mini:
      ^^^^
If you wish to shorten my name please use mn, its fewer keys, so you
safe some time


> > if the header does get updated at the end this would mismatch if only a
> > subset of segments get concatenated
> 
> This is one reason why I have the `seekback` option disabled by default
> (the other being that it avoids potential interprocess races)

ok, i tested a bit and it seems:
./ffmpeg -i randomfile.mpg -f ssegment -t 4 -segment_time 1.5  -individual_header_trailer 0 file.%4d.ts
results in a missing file.0000.ts segments starting from 0001 instead

[...]


>      /* copy modified name in list entry */
>      size = strlen(av_basename(oc->filename)) + 1;
> +
>      if (seg->entry_prefix)
>          size += strlen(seg->entry_prefix);
>  
> @@ -226,19 +355,23 @@ static int segment_start(AVFormatContext *s, int write_header)
>      }
>  
>      seg->segment_idx++;
> -    if ((seg->segment_idx_wrap) && (seg->segment_idx%seg->segment_idx_wrap == 0))
> +    if ((seg->segment_idx_wrap) && (seg->segment_idx % seg->segment_idx_wrap == 0))

unrelated

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

Many things microsoft did are stupid, but not doing something just because
microsoft did it is even more stupid. If everything ms did were stupid they
would be bankrupt already.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150330/65c60806/attachment.asc>


More information about the ffmpeg-devel mailing list