[FFmpeg-devel] [PATCH v3 5/5] avformat/tee: Use BSF list API

Michael Niedermayer michael at niedermayer.cc
Sun Aug 21 15:57:02 EEST 2016


On Tue, Aug 09, 2016 at 02:00:24PM +0200, sebechlebskyjan at gmail.com wrote:
[...]
>  
> @@ -506,13 +481,32 @@ static int tee_write_packet(AVFormatContext *avf, AVPacket *pkt)

>          av_packet_rescale_ts(&pkt2, tb, tb2);

>          pkt2.stream_index = s2;
>  
> -        if ((ret = av_apply_bitstream_filters(avf2->streams[s2]->codec, &pkt2,
> -                                              tee->slaves[i].bsfs[s2])) < 0 ||
> -            (ret = av_interleaved_write_frame(avf2, &pkt2)) < 0) {
> +        ret = av_bsf_send_packet(tee->slaves[i].bsfs[s2], &pkt2);
> +        if (ret < 0) {
> +            av_log(avf, AV_LOG_ERROR, "Error while sending packet to bitstream filter: %s\n",
> +                   av_err2str(ret));
>              ret = tee_process_slave_failure(avf, i, ret);
>              if (!ret_all && ret < 0)
>                  ret_all = ret;
>          }
> +
> +        do {
> +            ret = av_bsf_receive_packet(tee->slaves[i].bsfs[s2], &pkt2);
> +            if (ret < 0)
> +                break;
> +

> +            av_packet_rescale_ts(&pkt2, tb, tb2);

are the timestamps rescaled twice ?
is that intended ?


[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The real ebay dictionary, page 1
"Used only once"    - "Some unspecified defect prevented a second use"
"In good condition" - "Can be repaird by experienced expert"
"As is" - "You wouldnt want it even if you were payed for it, if you knew ..."
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160821/d51cca99/attachment.sig>


More information about the ffmpeg-devel mailing list