Merge remote-tracking branch 'qatar/master'
authorMichael Niedermayer <michaelni@gmx.at>
Thu, 15 Nov 2012 10:31:13 +0000 (11:31 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 15 Nov 2012 10:31:13 +0000 (11:31 +0100)
* qatar/master:
  bgmc: Fix av_malloc checks in ff_bgmc_init()
  rtp: set the payload type as stream id

Conflicts:
libavformat/rtpenc_chain.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
12 files changed:
1  2 
libavformat/avformat.h
libavformat/internal.h
libavformat/movenc.c
libavformat/movenchint.c
libavformat/rtp.c
libavformat/rtp.h
libavformat/rtpenc.c
libavformat/rtpenc_chain.c
libavformat/rtpenc_chain.h
libavformat/rtsp.c
libavformat/sapenc.c
libavformat/sdp.c

Simple merge
Simple merge
@@@ -1801,10 -1576,10 +1804,10 @@@ static int mov_write_trak_tag(AVIOConte
      if (track->mode == MODE_PSP)
          mov_write_uuid_tag_psp(pb,track);  // PSP Movies require this uuid box
      if (track->tag == MKTAG('r','t','p',' '))
-         mov_write_udta_sdp(pb, track->rtp_ctx, track->track_id);
+         mov_write_udta_sdp(pb, track);
      if (track->enc->codec_type == AVMEDIA_TYPE_VIDEO && track->mode == MODE_MOV) {
          double sample_aspect_ratio = av_q2d(st->sample_aspect_ratio);
 -        if (0.0 != sample_aspect_ratio && 1.0 != sample_aspect_ratio)
 +        if (st->sample_aspect_ratio.num && 1.0 != sample_aspect_ratio)
              mov_write_tapt_tag(pb, track);
      };
      return update_size(pb, pos);
Simple merge
Simple merge
Simple merge
Simple merge
@@@ -57,8 -59,13 +59,16 @@@ int ff_rtp_chain_mux_open(AVFormatConte
      rtpctx->max_delay = s->max_delay;
      /* Copy other stream parameters. */
      rtpctx->streams[0]->sample_aspect_ratio = st->sample_aspect_ratio;
 +    rtpctx->flags |= s->flags & AVFMT_FLAG_MP4A_LATM;
 +
+     /* Get the payload type from the codec */
+     if (st->id < RTP_PT_PRIVATE)
+         rtpctx->streams[0]->id =
+             ff_rtp_get_payload_type(rtpctx, st->codec, idx);
+     else
+         rtpctx->streams[0]->id = st->id;
++
      if (av_opt_get(s, "rtpflags", AV_OPT_SEARCH_CHILDREN, &rtpflags) >= 0)
          av_dict_set(&opts, "rtpflags", rtpflags, AV_DICT_DONT_STRDUP_VAL);
  
Simple merge
@@@ -629,9 -628,10 +629,10 @@@ int ff_rtsp_open_transport_ctx(AVFormat
          s->ctx_flags |= AVFMTCTX_NOHEADER;
  
      if (s->oformat && CONFIG_RTSP_MUXER) {
 -        int ret = ff_rtp_chain_mux_open(&rtsp_st->transport_priv, s, st,
 +        int ret = ff_rtp_chain_mux_open((AVFormatContext **)&rtsp_st->transport_priv, s, st,
                                          rtsp_st->rtp_handle,
-                                         RTSP_TCP_MAX_PACKET_SIZE);
+                                         RTSP_TCP_MAX_PACKET_SIZE,
+                                         rtsp_st->stream_index);
          /* Ownership of rtp_handle is passed to the rtp mux context */
          rtsp_st->rtp_handle = NULL;
          if (ret < 0)
Simple merge
Simple merge