| Branch: | Revision:

ffmpeg / libavfilter / avfilter.c @ master

History | View | Annotate | Download (22.3 KB)

# Date Author Comment
c34cb130 05/06/2011 11:02 PM Michael Niedermayer

avfilter: dont use AVFilterLink as priv for pictures as its freed too early.
Signed-off-by: Michael Niedermayer <>

39f66edb 05/06/2011 09:53 PM Michael Niedermayer

AVFilter: use picture pool to avoid malloc().
Signed-off-by: Michael Niedermayer <>

fa3eddc0 05/06/2011 09:37 PM Michael Niedermayer

avfilter_unref_buffer: favor av_freep()
Signed-off-by: Michael Niedermayer <>

b000b86e 05/05/2011 01:30 AM Michael Niedermayer

Merge remote branch 'qatar/master'

  • qatar/master: (23 commits)
    doc: Check standalone compilation before submitting new components.
    Fix standalone compilation of pipe protocol.
    Fix standalone compilation of ac3_fixed encoder.
    Fix standalone compilation of binkaudio_dct / binkaudio_rdft decoders....
0699dbb8 05/04/2011 02:35 AM Ronald S. Bultje

avfilter: check malloc return values.

f8af93ab 05/04/2011 02:29 AM Ronald S. Bultje

avfilter: don't av_malloc(0).

35fe66ab 05/01/2011 11:10 AM Stefano Sabatini

lavfi: rename AVFilterBufferRefVideoProps.pixel_aspect to sample_aspect_ratio

Improve consistency with libavcodec.

This breaks libavfilter API/ABI.

The non-sequential 2.1.0 -> 2.4.0 bump is due to the mess previously
done with the lavfi minor number.

f7bdffb0 04/27/2011 09:03 AM Stefano Sabatini

lavfi: print key-frame and picture type information in ff_dlog_ref()

Signed-off-by: Stefano Sabatini <>

2912e87a 03/19/2011 01:33 PM Mans Rullgard

Replace FFmpeg with Libav in licence headers

Signed-off-by: Mans Rullgard <>

e528cdac 03/17/2011 04:26 PM Michael Niedermayer


This reverts commit 29ba091136a5e04574f7bfc1b17536c923958f6f.

0cb88628 03/17/2011 04:26 PM Michael Niedermayer

Revert "use LIBAV_LICENSE and LIBAV_VERSION instead of FFMPEG_*"

This reverts commit a03be6e1ba4cbf9984b0bbdb674704bbb2da6713.

a03be6e1 03/16/2011 08:54 PM Janne Grunau


29ba0911 03/16/2011 08:54 PM Janne Grunau


also update the multiple inclusion guards in config.h|mak

737eb597 02/15/2011 03:18 PM Reinhard Tartler

Merge libavcore into libavutil

It is pretty hopeless that other considerable projects will adopt
libavutil alone in other projects. Projects that need small footprint
are better off with more specialized libraries such as gnulib or rather
just copy the necessary parts that they need. With this in mind, nobody...

70c275f8 02/14/2011 08:00 PM Stefano Sabatini

Make avfilter_config_links() propagate audio information of the source link if it is not explicitely set by the filter.

910b5b82 02/14/2011 01:07 PM Michael Niedermayer

Add sample_aspect_ratio to AVFilterLink

Signed-off-by: Mans Rullgard <>

5fce60c3 02/02/2011 12:12 PM Stefano Sabatini

Log debug information in filter_samples().

Signed-off-by: Mans Rullgard <>

dfd2a005 01/29/2011 10:55 PM Luca Barbato

Replace dprintf with av_dlog

dprintf clashes with POSIX.1-2008

eb7ccf8f 01/26/2011 03:33 PM Diego Elio Pettenò

Make the avfilter debug functions and macros static to avfilter.c

This removes ff_get_ref_perms_string, ff_dprintf_ref and ff_dprintf_link
fro the interface of libavfilter.

Signed-off-by: Mans Rullgard <>

b1779800 01/15/2011 08:43 PM Stefano Sabatini

Include libavcore/audioconvert.h, required for
av_get_channel_layout_string() in ff_dprintf_link.

Fix compilation.

Originally committed as revision 26380 to svn://

1d5b1885 01/15/2011 08:02 PM Stefano Sabatini


Originally committed as revision 26379 to svn://

7986e34d 01/15/2011 07:58 PM Stefano Sabatini

Make ff_dprintf_link() print meaningful information for audio links.

Originally committed as revision 26378 to svn://

a242ac36 01/15/2011 05:31 PM Stefano Sabatini

Rename AVFilterBufferRefAudioProps.samples_nb to nb_samples.

More consistent with the rest of FFmpeg and sounds more natural to
English speaking people.

Originally committed as revision 26374 to svn://

6baf4afa 01/15/2011 05:21 PM Stefano Sabatini

Make avfilter_unref_buffer() accept a NULL parameter.

Originally committed as revision 26373 to svn://

891aeeee 01/13/2011 01:00 AM Stefano Sabatini

Check linked pads media type mismatch in avfilter_link().

Originally committed as revision 26325 to svn://

36dc00de 01/11/2011 11:53 PM Michael Niedermayer

Add w,h,format back into AVFilterBuffer, these are required for direct rendering.
These fields are needed to be able to know which area of memory is allocated and
which is off limits.
This reverts 24291 and parts of r24424.

Originally committed as revision 26314 to svn://

0ccabeea 12/27/2010 03:10 PM Michael Niedermayer

Support filters and decoders that dont support negative linesizes.
This patch is based on work by stefano.

Originally committed as revision 26108 to svn://

fee0deb6 12/19/2010 07:08 PM Stefano Sabatini

Fix avfilter_draw_slice() copy code with alpha planes.

Originally committed as revision 26060 to svn://

3fa77bde 11/28/2010 10:22 AM Stefano Sabatini

In libavfilter, use consistently "Copyright (c)" in the license

Originally committed as revision 25838 to svn://

d38c340f 11/25/2010 08:50 PM Stefano Sabatini

Implement avfilter_get_video_buffer_ref_from_arrays().

Originally committed as revision 25827 to svn://

906eaab4 11/13/2010 09:20 AM Stefano Sabatini

In ff_get_ref_perms_string() use 'u' and 'U' for representing
AV_PERM_REUSE and AV_PERM_REUSE2 flags, avoid conflict with the char
'r' used for AV_PERM_READ.

Originally committed as revision 25739 to svn://

5d6e4c16 11/12/2010 11:04 AM Stefano Sabatini

Replace deprecated symbols SAMPLE_FMT_* with AV_SAMPLE_FMT_*, and enum
SampleFormat with AVSampleFormat.

Originally committed as revision 25730 to svn://

24de0edb 11/08/2010 12:32 PM Stefano Sabatini

Rename avfilter_destroy() as avfilter_free().

The new name is shorter and more consistent with the FFmpeg API, and
sounds less evil.

Originally committed as revision 25707 to svn://

d545aea8 10/25/2010 04:28 AM Stefano Sabatini

100l: remove bogus inclusion of libavcodec/audioconvert.c in

Originally committed as revision 25565 to svn://

cf5fe8ec 10/12/2010 10:32 PM Stefano Sabatini

Make avfilter_config_links() use the timebase of the first input link
of a filter for setting the output timebase, if there is such a link,
rather than always use AV_TIME_BASE_Q.

This fixes configuration for all the filters which do not use the
default config_props for the output link, and do not set explicitely...

867ae7aa 10/10/2010 10:26 PM Stefano Sabatini

Add a time_base field to AVFilterLink.

This is required for allowing a filter to use a time base different
from AV_TIME_BASE_Q, as it was previously assumed.

Originally committed as revision 25441 to svn://

69f73a89 10/10/2010 06:54 PM Stefano Sabatini

Make avfilter_config_links() propagate the error code coming from the
callee functions.

Originally committed as revision 25433 to svn://

486adc55 09/27/2010 09:57 PM Stefano Sabatini

Use more expressive names for the avfilter_insert_filter() in and out

Originally committed as revision 25235 to svn://

db9dfa3c 09/27/2010 05:28 PM Stefano Sabatini

Make avfilter_insert_filter() propagate an error code in case the
called avfilter_link() fails.

Originally committed as revision 25229 to svn://

acc0490f 09/27/2010 04:58 PM Stefano Sabatini

Make AVFilterLink store the pointers to the source and destination
pads, rather than their index.

Originally committed as revision 25227 to svn://

b1a05b82 09/27/2010 01:17 AM Stefano Sabatini

Make avfilter_destroy() code less convoluted, introducing a temporary
variable link.

Originally committed as revision 25217 to svn://

e16f217c 09/07/2010 07:15 PM Stefano Sabatini

Use new imgutils.h API names, fix deprecation warnings.

Originally committed as revision 25058 to svn://

eedca998 08/24/2010 03:12 PM Stefano Sabatini

Implement ff_get_ref_perms_string() and use it for tracing.

Originally committed as revision 24900 to svn://

5a9dd3de 08/24/2010 08:37 AM Stefano Sabatini

Make avfilter_start_frame() invoke avfilter_get_video_buffer() on the
link rather than avfilter_default_get_video_buffer().

This is required as the buffer requested may be greater than the
buffer allocated locally by avfilter_default_get_video_buffer(), for...

014df3a2 08/20/2010 03:16 PM Stefano Sabatini

Make ff_dprintf_ref() print audio related information if available.

Originally committed as revision 24849 to svn://

e29b451a 08/20/2010 03:16 PM Stefano Sabatini

Cosmetics: merge two lines in ff_dprintf_ref().

Originally committed as revision 24848 to svn://

0055b2d1 08/20/2010 03:16 PM Stefano Sabatini

Make ff_dprintf_ref() print the information related to the referenced

Originally committed as revision 24847 to svn://

b5fbb31e 08/20/2010 03:15 PM Stefano Sabatini

Rename ff_dprintf_picref() to ff_dprintf_ref().

The function is going to be used to represent also audio data.

Originally committed as revision 24846 to svn://

801ab980 08/20/2010 02:41 PM Stefano Sabatini

Extend ff_dprintf_picref() to make it print video interlaced and
top_field_first information.

Originally committed as revision 24845 to svn://

382ecd35 08/20/2010 02:41 PM Stefano Sabatini

Make ff_dprintf_picref() print video properties only if available.

Originally committed as revision 24844 to svn://

28c52b1e 08/20/2010 02:41 PM Stefano Sabatini

Only print the pointer to the first plane in ff_dprintf_picref().

To display the other planes is usually not useful and add noise to the

Originally committed as revision 24843 to svn://

dc46661a 08/19/2010 02:32 PM Stefano Sabatini

Enable and change the log level to DEBUG for the message printed in
case of picref copy.

Originally committed as revision 24831 to svn://

ca857431 08/19/2010 02:32 PM Stefano Sabatini

Cosmetics: apply misc spacing style fixes.

Originally committed as revision 24830 to svn://

ad2c9501 08/17/2010 06:08 PM S.N. Hemanth Meenakshisunda...

Implement libavfilter audio framework.

Patch by S.N. Hemanth Meenakshisundaram * smeenaks * ucsd * edu *.

Originally committed as revision 24811 to svn://

4f9ce3c4 08/17/2010 03:12 PM Stefano Sabatini

Add missing NULL checks in avfilter_ref_buffer().

Originally committed as revision 24808 to svn://

81c1ecab 08/12/2010 03:06 PM Stefano Sabatini

Deprecate ff_get_plane_bytewidth() in favor of

Originally committed as revision 24787 to svn://

382ac60e 08/11/2010 03:38 PM S.N. Hemanth Meenakshisunda...

Set type on buffer in get_video_buffer().

Patch by S.N. Hemanth Meenakshisundaram reverse("skaneems") + "".

Originally committed as revision 24775 to svn://

84c03869 08/11/2010 11:44 AM Stefano Sabatini

Change avfilter_open() signature, from:
AVFilterContext *avfilter_open(AVFilter *filter, const char *inst_name);
int avfilter_open(AVFilterContext **filter_ctx, AVFilter *filter, const char *inst_name);

This way it is possible to propagate an error code telling the reason...

cc80caff 08/11/2010 11:06 AM S.N. Hemanth Meenakshisunda...

Separate video specific BufferRef properties into VideoProps.

Define a new struct AVFilterBufferRefVideoProps and add a type field
to AVFilterBufferRef.

Video specific properties in AVFilterBufferRefVideoProps are now
referred to by *video pointer in AVFilterBufferRef....

5d4890d7 08/07/2010 01:15 AM S.N. Hemanth Meenakshisunda...

Rename fields:

AVFilterLink.srcpic -> AVFilterLink.src_buf
AVFilterLink.cur_pic -> AVFilterLink.cur_buf
AVFilterLink.outpic -> AVFilterLink.out_buf

The new names are more generic and more consistent, since the struct
they contain, which was named AVFilterPicRef, has been renamed to...

7fce481a 08/07/2010 01:15 AM S.N. Hemanth Meenakshisunda...

Rename functions and fields:

avfilter_(un)ref_pic -> avfilter_(un)ref_buffer
avfilter_copy_picref_props -> avfilter_copy_buffer_ref_props
AVFilterBufferRef.pic -> AVFilterBufferRef.buffer

They have been renamed to allow sharing with audio.

Patch by S.N. Hemanth Meenakshisundaram $smeenaks$ucsd$edu$....

ecc8dada 08/07/2010 01:15 AM S.N. Hemanth Meenakshisunda...

Rename AVFilterPicRef to AVFilterBufferRef.

The struct is going to be used for storing audio buffer references as
well, and the new name is more generic.

Patch by S.N. Hemanth Meenakshisundaram smeenaks@ucsd@edu.

Originally committed as revision 24730 to svn://

5a6fbf4c 08/06/2010 10:25 PM Måns Rullgård

avfilter: indent

Originally committed as revision 24720 to svn://

0bb7408e 08/06/2010 10:25 PM Måns Rullgård

avfilter: do not crash on null link src/dst in avfilter_destroy()

Originally committed as revision 24719 to svn://

f3b90d25 08/06/2010 10:25 PM Måns Rullgård

avfilter: free link in/out_formats in avfilter_destroy()

Originally committed as revision 24718 to svn://

bdab614b 07/22/2010 11:12 AM S.N. Hemanth Meenakshisunda...

Generalize pixel format enum fields to int formats.

This is needed to make the libavfilter framework work with audio

In particular add a type field to AVFilterLink, change the field types:
enum PixelFormat format -> int format in AVFilterBuffer...

9f0e31d2 07/18/2010 10:37 PM Stefano Sabatini

Make avfilter.c dprintf* functions internal and declare them in an
internal.h header, so they can be easily used from other files.

Originally committed as revision 24319 to svn://

922189fe 07/11/2010 02:44 PM Víctor Paesa

Use avfilter_copy_picref_props() along lavfi.

Originally committed as revision 24196 to svn://

efdc74ef 05/07/2010 10:02 AM Michael Niedermayer

Try to keep track of interlaced and top field first.

Originally committed as revision 23044 to svn://

2308b6c1 04/28/2010 08:00 PM Michael Niedermayer

Add version to AVClass so we can add to and use fields of AVClass without ABI issues.

Originally committed as revision 22987 to svn://

2bb96256 04/03/2010 03:29 PM Bobby Bingham

Remove variable whose value was never read. Found by clang.

Originally committed as revision 22794 to svn://

5bb5c1dc 03/13/2010 11:27 AM Stefano Sabatini

Add AVFilterPicRef.pos field and make libavfilter propagate stream
byte position information, as stored in the pkt.pos, through the

Note that the pos field is added non at the end of the
AVFilterPicRef struct, thus breaking ABI compatibility, which is...

63833766 03/06/2010 09:28 PM Stefano Sabatini

Show aspect ratio information in dprintf_picref() traces.

Originally committed as revision 22255 to svn://

b4b66456 01/31/2010 04:33 PM Stefano Sabatini

Avoid usage of avcodec_get_pix_fmt_name() and
avcodec_get_chroma_sub_sample(), directly access
av_pix_fmt_descriptors instead.

Remove some of the dependancies of lavfi on lavc.

Originally committed as revision 21575 to svn://

08f8b51f 01/13/2010 12:16 AM Stefano Sabatini

Make avfilter_insert_filter() log the names of the filters between
which it inserts the new filter.

Originally committed as revision 21177 to svn://

999c23a1 01/10/2010 01:45 PM Stefano Sabatini

Make avfilter_insert_filter() print the instance name of the
auto-inserted scale filter, rather than the filter name, as this
provides more information.

Originally committed as revision 21123 to svn://

41600690 01/03/2010 02:31 PM Stefano Sabatini

Prefer "*FUNC_NAME(" over "* FUNC_NAME(" for XXX_configuration() and
XXX_license() functions, consistent with the rest of FFmpeg.

Originally committed as revision 21005 to svn://

a13a5437 12/04/2009 11:26 PM Stefano Sabatini

Add a slice_dir parameter to avfilter_draw_slice().

Avoid the need to implement slice direction detection code, thus
reducing code duplication.

See the thread:
"[FFmpeg-devel] [PATCH] Add a slice_dir parameter to avfilter_start_frame()".

Originally committed as revision 20734 to svn://

1433c4ab 11/24/2009 11:58 PM Stefano Sabatini

Implement avfilter_next().

Originally committed as revision 20607 to svn://

86a60fa1 11/24/2009 11:47 PM Stefano Sabatini

Implement a new registration system for filters.

Create a new static array containing pointers to the AVFilter
definitions, so that the non-constant next filter in the AVFilter
struct is not anymore required and the AVFilter definitions may be
stored in shareable memory....

c1736936 11/18/2009 05:15 PM Diego Biurrun

Add functions to return library license and library configuration.

Originally committed as revision 20547 to svn://

da23d424 11/03/2009 10:15 PM Stefano Sabatini

Make avfilter_get_video_buffer() use
avfilter_default_get_video_buffer() if the get_video_buffer() callback
is not defined in a filter.

Libavfilter filters author have to explicitely define the
get_video_buffer() callback if they want the buffer to be requested to...

3555d2e8 10/27/2009 07:52 PM Stefano Sabatini

Introduce first_avfilter and use that, together with,
for registering and finding filters, rather than use the struct
AVFilterList, which is removed.

Simplify the filter registration management code.

Originally committed as revision 20387 to svn://

8fdb01c1 10/25/2009 09:06 PM Stefano Sabatini

Make dprintf_link() show the name of the link pixel format.

Originally committed as revision 20372 to svn://

9dd08b4e 10/18/2009 10:33 PM Vitor Sessak

Fix recursive avfilter_poll_frame(). It was doing
min = FFMIN)
which, since FFMIN is a macro, was calling itself
twice for every input, causing an exponential cost in time.

Originally committed as revision 20295 to svn://

0eb4ff9e 10/18/2009 08:16 AM Stefano Sabatini

Make avfilter_get_video_buffer() recursive.

When called on a link with a filter whose destination pad has not a
get_video_buffer callback defined, it will call
avfilter_get_video_buffer() on the first output link of the
destination filer, rather than use avfilter_default_get_buffer(), so...

96da1c51 10/06/2009 10:07 PM Stefano Sabatini

Implement trace messages logging in the filterchain processing.

It is only enabled when the DEBUG symbol is defined.

Originally committed as revision 20187 to svn://

fe479c9d 04/14/2009 08:48 AM Cédric Schieli

Also copy pixel_aspect when copying the picref in avfilter_start_frame.
This avoids a division by zero in '[in]fifo,scale[out]'

Originally committed as revision 18507 to svn://

b6fec3eb 03/26/2009 09:46 PM Víctor Paesa

Make static the list of registered filters.

Originally committed as revision 18198 to svn://

90993b38 01/12/2009 08:34 PM Stefano Sabatini

Reindent after the last commit, while at it also add some spaces for
improving readability.

Originally committed as revision 16566 to svn://

689a5f49 01/12/2009 08:30 PM Stefano Sabatini

Make avfilter_open() set to NULL the pads and the filters when the
corresponding count is zero, rather than allocate a 16 bytes sized
block for them. Improve safety.

Originally committed as revision 16565 to svn://

b9609848 01/11/2009 10:05 PM Stefano Sabatini

Implement the avfilter_default_draw_slice() handler and use it in
avfilter_draw_slice() when the draw_slice callback is not defined in
the input pad.

Originally committed as revision 16554 to svn://

5bc8ebd3 11/26/2008 06:59 PM Carl Eugen Hoyos

Use PIX_FMT_NONE to silence icc warning #188:
enumerated type mixed with another type

Originally committed as revision 15942 to svn://

540f1c7b 08/08/2008 06:43 PM Stefano Sabatini

Implement avfilter_version().

Originally committed as revision 14669 to svn://

245976da 05/09/2008 11:56 AM Diego Biurrun

Use full path for #includes from another directory.

Originally committed as revision 13098 to svn://

b049ad50 03/07/2008 09:08 AM Måns Rullgård

fix AVClass for avfilter

Originally committed as revision 12357 to svn://

805d0232 02/15/2008 09:42 PM Vitor Sessak

Do not copy more data than needed
Commited in SoC by Vitor Sessak on 2008-02-15 21:11:35

Originally committed as revision 12061 to svn://

e9f54274 02/15/2008 09:41 PM Vitor Sessak

Remove header now made useless
Commited in SoC by Vitor Sessak on 2008-02-12 20:59:51

Originally committed as revision 12060 to svn://

3bc2a526 02/15/2008 09:41 PM Vitor Sessak

Remove unneeded function.

Commited in SoC by Vitor Sessak on 2008-02-12 20:54:11

Originally committed as revision 12059 to svn://

b57fc327 02/15/2008 09:41 PM Vitor Sessak

Missed this file in my conditional compilation patch
Commited in SoC by Vitor Sessak on 2008-02-12 20:40:32

Originally committed as revision 12058 to svn://