]> git.sesse.net Git - ffmpeg/commitdiff
Merge commit '28816050e47b6dba430a52e429d21a864cffda8e'
authorMichael Niedermayer <michaelni@gmx.at>
Tue, 7 Oct 2014 00:51:08 +0000 (02:51 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Tue, 7 Oct 2014 00:51:08 +0000 (02:51 +0200)
* commit '28816050e47b6dba430a52e429d21a864cffda8e':
  lavf: Set the stream time base hint properly for chained muxers

Conflicts:
libavformat/segment.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavformat/hdsenc.c
libavformat/hlsenc.c
libavformat/mpegtsenc.c
libavformat/segment.c
libavformat/smoothstreamingenc.c

Simple merge
index b5535727bce95b966ead9abaea66a90dd342f696,ad53df5734e42b9d72b51a5fe9360fa605b1c0c4..8b180dce5ac5ce7ff9a8d504a31b3f117f427aee
@@@ -101,8 -80,8 +101,9 @@@ static int hls_mux_init(AVFormatContex
              return AVERROR(ENOMEM);
          avcodec_copy_context(st->codec, s->streams[i]->codec);
          st->sample_aspect_ratio = s->streams[i]->sample_aspect_ratio;
+         st->time_base = s->streams[i]->time_base;
      }
 +    hls->start_pos = 0;
  
      return 0;
  }
Simple merge
index f35bbef8dcbdb04800924c2c58167f0e7ae656d6,52da6b9ce3451d6e6a6ba63d19f6d5568ad4887e..6183208fa28ac6b607048de6e44407ebc32058f2
@@@ -147,22 -70,11 +147,23 @@@ static int segment_mux_init(AVFormatCon
  
      for (i = 0; i < s->nb_streams; i++) {
          AVStream *st;
 +        AVCodecContext *icodec, *ocodec;
 +
          if (!(st = avformat_new_stream(oc, NULL)))
              return AVERROR(ENOMEM);
 -        avcodec_copy_context(st->codec, s->streams[i]->codec);
 +        icodec = s->streams[i]->codec;
 +        ocodec = st->codec;
 +        avcodec_copy_context(ocodec, icodec);
 +        if (!oc->oformat->codec_tag ||
 +            av_codec_get_id (oc->oformat->codec_tag, icodec->codec_tag) == ocodec->codec_id ||
 +            av_codec_get_tag(oc->oformat->codec_tag, icodec->codec_id) <= 0) {
 +            ocodec->codec_tag = icodec->codec_tag;
 +        } else {
 +            ocodec->codec_tag = 0;
 +        }
          st->sample_aspect_ratio = s->streams[i]->sample_aspect_ratio;
+         st->time_base = s->streams[i]->time_base;
 +        av_dict_copy(&st->metadata, s->streams[i]->metadata, 0);
      }
  
      return 0;
Simple merge