diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2011-05-19 01:17:16 +0200 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2011-05-19 23:15:34 +0200 |
commit | c000a9f78390b71812c7ee5187bbccc3c2d79b1e (patch) | |
tree | 101bafe8874835096c6dd536ec38a968a9174013 /ffmpeg.c | |
parent | d3fddb8454cab525cbcb6cc9c3d0ca29b6c78cdd (diff) | |
download | ffmpeg-c000a9f78390b71812c7ee5187bbccc3c2d79b1e.tar.gz |
vsrc_buffer: add av_vsrc_buffer_add_frame()
The new function is a wrapper around
av_vsrc_buffer_add_video_buffer_ref(), and allows to simplify the act
of pushing AVFrame data to the source buffer.
Diffstat (limited to 'ffmpeg.c')
-rw-r--r-- | ffmpeg.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -1643,18 +1643,13 @@ static int output_packet(AVInputStream *ist, int ist_index, #if CONFIG_AVFILTER if(ist->st->codec->codec_type == AVMEDIA_TYPE_VIDEO) { for(i=0;i<nb_ostreams;i++) { - AVFilterBufferRef *picref; ost = ost_table[i]; if (ost->input_video_filter && ost->source_index == ist_index) { if (!picture.sample_aspect_ratio.num) picture.sample_aspect_ratio = ist->st->sample_aspect_ratio; picture.pts = ist->pts; - picref = - avfilter_get_video_buffer_ref_from_frame(&picture, AV_PERM_WRITE); - av_vsrc_buffer_add_video_buffer_ref(ost->input_video_filter, picref); - picref->buf->data[0] = NULL; - avfilter_unref_buffer(picref); + av_vsrc_buffer_add_frame(ost->input_video_filter, &picture); } } } |