Commit Graph

294 Commits

Author SHA1 Message Date
Stefano Sabatini b87d4c2b9f vf_drawtext: do not set limitations on fontsize
It may be needed to use values greater than 72, and in general greater
than an arbitrary big value. Let the user choose what's too big for
her.
2011-09-23 01:35:38 +02:00
Clément Bœsch 46c9ddf83c lavfi: fix avfilter_get_audio_buffer() doxy to match reality. 2011-09-18 17:32:03 +02:00
Stefano Sabatini e72aa524d8 asrc_anullsrc: implement a request_frame callback for returning frames
This is mainly useful for filters (like the sox synth), which
overwrite the content of the passed data.
2011-09-18 12:38:33 +02:00
Stefano Sabatini 44ab77db9e asrc_anullsrc: extend syntax to make it accept a non positional list of arguments
The new syntax is more extensible and more user-friendly.

This breaks the previous syntax, should not be an issue as possibly
no-one is already using anullsrc.
2011-09-18 12:30:01 +02:00
Stefano Sabatini 37cc443c83 lavfi: add audio convert filter
Add aconvert filter to perform sample format, channel layout, and
packing format conversion.

The aconvert code depends on audio conversion code in libavcodec, so
this requires a dependency on libavcodec.

Based on previous work by S.N. Hemanth Meenakshisundaram and Mina Nagy
Zaki, performed for the GSoC 2010 and 2011.
2011-09-16 20:44:27 +02:00
Stefano Sabatini ea8de109af lavfi: add avfilter_all_channel_layouts public symbol
This list is mainly useful to be directly used as a parameter by the
audio sink buffer, when there is no need to force a specific channel
layout.

The list of formats is generated programmatically, and avoids channel
layouts not supported by libavfilter (with more than 8 channels).

We preferred to avoid compile-time generation in order to avoid some
unnecessary complexity (build hacks, generating code maintainance
etc.).

A more compact way to express this list through the use of macros
should be possible when libavfilter will support more than 8 channels,
as there will be no need to filter out channel layouts with more than
8 channels.

See thread:
Subject: [FFmpeg-devel] [PATCH] lavfi: add ff_all_channel_layouts internal symbol
Date: Sat, 20 Aug 2011 15:33:16 +0200
2011-09-16 00:46:41 +02:00
Stefano Sabatini 9899037dc6 lavfi: rename avfilter_all_* function names to avfilter_make_all_*
A function name should tell what the function does rather than what
the function returns. This also avoids possible conflicts
(e.g. between a function and a public list of all supported formats),
and clarifies the code.

Breaks audio API/ABI, add a backward compatibility layer for video
API/ABI.
2011-09-16 00:42:47 +02:00
Stefano Sabatini 9efae6a161 lavfi: bump minor and update APIchanges after recent updates
These changes were forgotten in commits:
  lavfi: simplify signature for avfilter_get_audio_buffer() and friends
  (commit 2c0317419b)
and
  lavfi: consistently use int for sample_rate in AVFilterLink and AVFilterBufferRefAudioProps
  (commit 4381bddc9f)
2011-09-12 22:08:53 +02:00
Stefano Sabatini 4381bddc9f lavfi: consistently use int for sample_rate in AVFilterLink and AVFilterBufferRefAudioProps
Also consistent with AVCodecContext.sample_rate. Simplify/avoid
pointless type checks and conversions.

Breaks audio API/ABI.
2011-09-12 18:51:46 +02:00
Stefano Sabatini 2c0317419b lavfi: simplify signature for avfilter_get_audio_buffer() and friends
The additional parameters were never used and are complicating the
function interface. Also, they were inconsistent with the way the
video API works.

So this assumes that a requested samples buffer will have *always* the
format specified in the requested link.

This breaks audio filtering API and ABI.
2011-09-12 18:51:18 +02:00
Stefano Sabatini 4f7dfe12ea lavfi: rename vsink_buffer.c to sink_buffer.c, and vsink_buffer.h to buffersink.h
This is done in order to clarify the non-video-specific nature of the
buffersink code, as the result of the video/audio API unification of
the previous commit, and for improving overall consistency.
2011-09-06 18:51:09 +02:00
Stefano Sabatini c4415f6ec9 lavfi: unify asink_buffer and vsink_buffer API
The new API is more generic (no distinction between audio/video for
pulling frames), and avoids code duplication.

A backward compatibility layer is kept for avoiding tools ABI breaks
(only for the video binary interface, audio interface was never used
in the tools).
2011-09-06 18:47:04 +02:00
Michael Niedermayer 3d8176d2f5 avfilter: Add avfilter_graph_que_command()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-08-29 20:16:10 +02:00
Michael Niedermayer 1e5014c7c7 avfilter: Add command passing support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-08-29 20:16:01 +02:00
Stefano Sabatini 24ddfb2bdb lavfi: add amovie source - audio movie source 2011-08-27 12:46:55 +02:00
Stefano Sabatini df4c7ae9db asink_abuffer: extend ABufferSinkContext to make it accept lists of formats in input
This is required for the pending lavfi indev extension, also
consistent with the video buffer sink.
2011-08-22 10:34:43 +02:00
Stefano Sabatini 34c997599e vsrc_testsrc: allow to set the sample aspect ratio
Add the sar option. Useful for debugging/testing purposes.
2011-08-21 15:27:09 +02:00
Mina Nagy Zaki 587c8ab912 lavfi: add asrc_abuffer - audio buffer source
Originally based on code by Stefano Sabatini and S. N. Hemanth.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-21 11:37:57 +02:00
Stefano Sabatini e30a0b1b3b lavfi: add ashowinfo filter
Useful for debugging.
2011-08-20 15:00:23 +02:00
Mina Nagy Zaki 3a9e227fb1 lavfi: add aresample filter
Based on a patch by Stefano.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-17 13:12:40 +02:00
Stefano Sabatini 6e89bdfecf lavfi: remove delogo mp wrapper
The delogo filter has been natively integrated into libavfilter,
simplify.
2011-08-14 12:26:44 +02:00
Stefano Sabatini 2701f6cc6a lavfi: port libmpcodecs delogo filter
The ported filter supports named option parsing and more YUV formats.
2011-08-14 12:17:10 +02:00
Mina Nagy Zaki 0a2295815d lavfi: add aformat filter
Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-14 10:31:23 +02:00
Stefano Sabatini 3560089e12 vsink_buffer: make the buffer cache all the incoming frames
Allow to cache more than one frame (e.g. for filters which return
more than one frame when avfilter_request_frame() is called on them),
and do not discard previously cached frames when a new one is added.
2011-08-14 02:04:19 +02:00
Stefano Sabatini e72657f83d lavfi: remove mp test wrapper
The source was natively integrated into libavfilter, with the name
mptestsrc.
2011-08-11 16:19:53 +02:00
Stefano Sabatini 1a5e63f924 lavfi: port mp test source 2011-08-11 16:19:48 +02:00
Stefano Sabatini 640a905ece lavfi: remove gradfun mp wrapper
The gradfun filter was already integrated natively in libavfilter.
Both filters issue the same output, and have a comparable performance.

See thread:
Subject: [FFmpeg-devel] [PATCH] lavfi: remove gradfun mp wrapper
Date: Fri,  5 Aug 2011 00:19:04 +0200
2011-08-07 17:43:02 +02:00
Mina Nagy Zaki a8dcf5eebb lavfi: add asink_abuffer - audio buffer sink
Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-06 13:17:49 +02:00
Mina Nagy Zaki 3e12b5893d lavfi: fix doxygen doc for config_props() callback
Update/extend documentation related to the link fields to set, and fix
a pads->filters braino.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-06 12:14:37 +02:00
Mina Nagy Zaki 5f68a91be2 lavfi: remove default config_props() callback and refactor avfilter_config_links()
Link properties have to be checked after config_props() is called to
make sure everything is sane, so the default config_props() for output
links was redundant.

Also remove channel_layout check as it is now negotiated.

Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-08-06 12:13:18 +02:00
Stefano Sabatini 4b7889453e lavfi: remove avfilter_default_config_input_link() declaration
The function is not implemented (and possibly useless).
2011-08-06 12:11:12 +02:00
Stefano Sabatini 45f9e053d8 vf_crop: add support for a, dar, sar, hsub, and vsub variables
Consistent with the pad and scale filters.
2011-07-30 18:30:07 +02:00
Stefano Sabatini 61d55fda2b lavfi: tweak display aspect ratio variables in pad and scale filters
Previously, "dar" and "a" were documented like "input display aspect
ratio", but their actual value was "in_w/in_h".

In order to avoid to break scripts which rely on the "a" variable, the
patch keeps the same semantics but fixes the corresponding docs, and
fixes the semantics of the recently added "dar" variable, which
now correctly expresses the input Display Aspect Ratio value as
"(inw_w/in_h)*sar".
2011-07-30 18:27:24 +02:00
Stefano Sabatini cc0dc50d02 vf_mp: remove blackframe filter wrapper
blackframe is integrated as a native filter.
2011-07-23 10:55:50 +02:00
Stefano Sabatini 8c2863b87f vf_mp: remove cropdetect wrapper
The cropdetect filter is natively integrated into libavfilter.
2011-07-21 13:04:48 +02:00
Stefano Sabatini c76974524a vf_blackframe: port missing features from libmpcodecs blackframe
Use and show picref->video->pict_type and key_frame information.
The pict_type and key_frame information was not available at the time
of the port.
2011-07-21 13:04:48 +02:00
Mina Nagy Zaki b57df29f95 lavfi: add audio channel packing negotiation fields
Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
2011-07-16 19:22:49 +02:00
Stefano Sabatini 9dbe8d9e22 lavfi: add rgbtestsrc source, ported from MPlayer libmpcodecs
The licence was changed from GPL to LGPL with explicit approval from
the original author.

See thread:
Subject: [FFmpeg-devel] [PATCH] lavfi: add rgbtestsrc source,
        ported from MPlayer libmpcodecs
Date: Mon, 11 Jul 2011 16:32:41 +0200
2011-07-15 01:44:56 +02:00
Stefano Sabatini 4bd28579e5 vf_mp: remove boxblur wrapper
It is natively included in libavfilter.
2011-07-15 01:06:00 +02:00
Stefano Sabatini 6b61920ab7 lavfi: port boxblur filter from libmpcodecs
With the following additions:
* support to gray format
* support to yuva420p format
* parametric luma/chroma/alpha radius
* consistency check on the radius values, avoid crashes with invalid values
2011-07-14 00:00:31 +02:00
Stefano Sabatini 2420763638 graphparser: simplify condition in avfilter_graph_parse()
Since avfilter_graph_parse() creates the "[in]" inout for the first
unlabelled input pad, it is expected that it will create an "[out]"
inout for last unlabelled output pad, even in the case where it cannot
find any open input pad with that name.

This change removes the check on the existence of an open input pad
named "out", so it simplifies the checked condition while implementing
a more intuitive behavior.
2011-07-10 18:00:50 +02:00
Nicolas George e6d88f63a8 libavfilter: add a default to silence a warning. 2011-07-05 08:27:42 +02:00
Stefano Sabatini 0bf02fb1ea vf_pad: add support for a "sar" variable
Also add a "dar" alias for "a", for avoiding confusion with sar/dar.
2011-07-04 11:20:00 +02:00
Stefano Sabatini 01151a26c0 vf_scale: add a "sar" variable
Also create a "dar" alias for the "a" variable, for avoiding possible
confusion between dar/sar.
2011-07-04 11:19:46 +02:00
Michael Niedermayer 976a8b2179 Merge remote-tracking branch 'qatar/master'
* qatar/master: (40 commits)
  H.264: template left MB handling
  H.264: faster fill_decode_caches
  H.264: faster write_back_*
  H.264: faster fill_filter_caches
  H.264: make filter_mb_fast support the case of unavailable top mb
  Do not include log.h in avutil.h
  Do not include pixfmt.h in avutil.h
  Do not include rational.h in avutil.h
  Do not include mathematics.h in avutil.h
  Do not include intfloat_readwrite.h in avutil.h
  Remove return statements following infinite loops without break
  RTSP: Doxygen comment cleanup
  doxygen: Escape '\' in Doxygen documentation.
  md5: cosmetics
  md5: use AV_WL32 to write result
  md5: add fate test
  md5: include correct headers
  md5: fix test program
  doxygen: Drop array size declarations from Doxygen parameter names.
  doxygen: Fix parameter names to match the function prototypes.
  ...

Conflicts:
	libavcodec/x86/dsputil_mmx.c
	libavformat/flvenc.c
	libavformat/oggenc.c
	libavformat/wtv.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-07-04 00:45:21 +02:00
Mans Rullgard abc78a5a7c Do not include log.h in avutil.h
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-07-03 21:42:07 +01:00
Mans Rullgard d49ea4afb4 Do not include pixfmt.h in avutil.h
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-07-03 21:42:07 +01:00
Mans Rullgard e91709ca17 Do not include rational.h in avutil.h
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-07-03 21:42:06 +01:00
Stefano Sabatini 7464a53aaa lavfi: make pix_fmt_is_in() in vf_lut.c an internal function
Also generalize it, making it accept ints rather than pixel formats.
Allow factorization.
2011-07-01 12:14:16 +02:00
Stefano Sabatini 2f222b9550 lavfi: add testsrc source 2011-06-26 19:49:24 +02:00