Vittorio Giovara
41ed7ab45f
cosmetics: Fix spelling mistakes
Signed-off-by: Diego Biurrun <diego@biurrun.de>
9 years ago
Derek Buitenhuis
21f9468402
avutil: Rename FF_CEIL_COMPAT to AV_CEIL_COMPAT
Libav, for some reason, merged this as a public API function. This will
aid in future merges.
A define is left for backwards compat, just in case some person
used it, since it is in a public header.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
9 years ago
Ganesh Ajjanagadde
8507b98c10
avfilter,swresample,swscale: use fabs, fabsf instead of FFABS
It is well known that fabs and fabsf are at least as fast and sometimes
faster than the FFABS macro, at least on the gcc+glibc combination.
For instance, see the reference:
http://patchwork.sourceware.org/patch/6735/ .
This was a patch to glibc in order to remove their usages of a macro.
The reason essentially boils down to fabs using the __builtin_fabs of
the compiler, while FFABS needs to infer to not use a branch and to
simply change the sign bit. Usually the inference works, but sometimes
it does not. This may be easily checked by looking at the asm.
This also has the added benefit of reducing macro usage, which has
problems with side-effects.
Note that avcodec is not handled here, as it is huge and
most things there are integer arithmetic anyway.
Tested with FATE.
Reviewed-by: Clément Bœsch <u@pkh.me>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
9 years ago
Vittorio Giovara
2268db2cd0
lavu: Drop the {minus,plus}1 suffix from AVComponentDescriptor fields
The new fields can be accessed directly and are more intelligible.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
9 years ago
Michael Niedermayer
4240e6a921
avfilter/vf_hqdn3d: Initialize the whole LUT
With bps > 8 more than 255..255 are used
The initialized table content is left unchanged,
But it could also be adjusted for the slight difference of
the maximum
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Clément Bœsch
fd682b1892
avfilter: handle error in query_formats() of a bunch of random video filters
10 years ago
Clément Bœsch
55feff57ce
avfilter/hqdn3d: an invalid bit depth means a bug, not invalid read data
This code looks clumsy, and an assert would probably be more welcome.
10 years ago
Vittorio Giovara
22b985d59c
hqdn3d: check memory allocations and propagate errors
10 years ago
Michael Niedermayer
14e2e40f3b
avfilter/vf_hqdn3: use av_malloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Luca Barbato
e995cf1bcc
avfilter: Add missing emms_c when needed
Arch specific calls should have an emms_c following to keep the cpu
state consistent.
Reported-By: wm4
CC: libav-stable@libav.org
11 years ago
Anton Khirnov
cd43ca0443
lavfi: do not export the filters from shared objects
11 years ago
Paul B Mahol
b211607b5c
avfilter: various cosmetics
Signed-off-by: Paul B Mahol <onemda@gmail.com>
11 years ago
Paul B Mahol
a8e00cf926
avfilter: remove redundant use of AV_NE() macro
Signed-off-by: Paul B Mahol <onemda@gmail.com>
11 years ago
Paul B Mahol
622c977437
lavfi/hqdn3d: make use of AVFILTER_DEFINE_CLASS
Signed-off-by: Paul B Mahol <onemda@gmail.com>
12 years ago
Anton Khirnov
3ba35a346c
vf_hqdn3d: make config_props work properly when called multiple times.
Do not leak all the temp buffers.
12 years ago
Anton Khirnov
56e4ce0d13
vf_hqdn3d: use the name 's' for the pointer to the private context
This is shorter and consistent across filters.
12 years ago
Clément Bœsch
0122300c86
lavfi/hqdn3d: restore timeline feature.
12 years ago
Clément Bœsch
0652111833
lavfi/hqdn3d: use macros instead of hardcoded indexes.
12 years ago
Clément Bœsch
50e66726a2
lavfi: use ceil right shift for chroma width/height.
This should fix several issues with odd dimensions inputs.
lut, vflip, pad and crop video filters also need to be checked for such
issues. It's possible sws is also affected.
12 years ago
Diego Biurrun
093804a93c
avfilter: Add av_cold attributes to init/uninit functions
12 years ago
Clément Bœsch
039c2b7828
lavfi/hqdn3d: remove timeline flag.
The filter stores some temporal data, which needs to be done with the
passthrough callback system when timeline is enabled. Until then,
timeline support is disabled.
12 years ago
Clément Bœsch
fdd93eabfb
lavfi: add timeline support.
Flag added in a few simple filters. A bunch of other filters can likely
use the feature as well.
12 years ago
Michael Niedermayer
3dedcef8b8
avfilter: add missing AV_OPT_FLAG_FILTERING_PARAM
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
d69a4177b9
lavfi: remove now unused args parameter from AVFilter.init
Conflicts:
libavfilter/avfilter.c
libavfilter/vf_drawtext.c
libavfilter/vf_lut.c
libavfilter/vf_select.c
libavfilter/vf_setpts.c
libavfilter/vsrc_color.c
libavfilter/vsrc_movie.c
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
c43a7ecad9
lavfi: remove now unused args parameter from AVFilter.init
12 years ago
Anton Khirnov
8c747d46f7
vf_hqdn3d: switch to an AVOptions-based system.
12 years ago
Loren Merritt
5b3c1aecb2
hqdn3d: Fix out of array read in LOWPASS
CC:libav-stable@libav.org
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Anton Khirnov
d0a863ac89
vf_hqdn3d: fix uninitialized variable use
CC:libav-stable@libav.org
12 years ago
Anton Khirnov
7e350379f8
lavfi: switch to AVFrame.
Deprecate AVFilterBuffer/AVFilterBufferRef and everything related to it
and use AVFrame instead.
12 years ago
Diego Biurrun
76d90125cd
vf_hqdn3d: x86: Add proper arch optimization initialization
12 years ago
Diego Biurrun
bcb8d9eb8f
Drop unnecessary 'l' length modifier when printfing double values.
%f denotes a double argument and 'l' does nothing in this case
according to the C spec.
12 years ago
Clément Bœsch
b5eb630e21
lavfi: remove some video w/h settings after avfilter_copy_buffer_ref_props.
video->[wh] will be set with the same values as the input after
avfilter_copy_buffer_ref_props. These filters don't change the size of
the input so there is no need for this code.
12 years ago
Clément Bœsch
9e1914dfba
lavfi/hqdn3d: avoid use of uninitialized variable.
12 years ago
Michael Niedermayer
ed547e2ce5
vf_hqdn3d: fix permissions
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
1b43fc127c
vf_hqdn3d: switch to filter_frame
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
565e4993c6
lavfi: merge start_frame/draw_slice/end_frame
Any alleged performance benefits gained from the split are purely
mythological and do not justify added code complexity.
12 years ago
Anton Khirnov
59ee9f78b0
lavfi: do not use av_pix_fmt_descriptors directly.
12 years ago
Mans Rullgard
568c70e79e
lavfi: convert input/ouput list compound literals to named objects
A number of compilers, for example those from TI and IBM, choke on
these initialisers. The current style is also quite ugly.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Anton Khirnov
716d413c13
Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat
12 years ago
Loren Merritt
1b1b902e2c
hqdn3d: Fix out of array read in LOWPASS
Fixes ticket1752
Commit message by commiter
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
4f92d31aa4
vf_hqdn3d: remove duplicate inline
This should fix compilation with gcc 3
Found-by: ubitux
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Martin Storsjö
b441a4517b
vf_hqdn3d: Remove a duplicate inline declaration
Compilation seems to fail on GCC 3.4 due to this duplicate
declaration.
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Martin Storsjö
2bd67175c7
vf_hqdn3d: Don't declare the loop variable within the for loop
This C99 feature is generally not used in the libav codebase,
since it breaks building with some fringe compilers (GCC 2.95,
MSVC).
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Michael Niedermayer
851bac4b06
vf_hqdn3d: avoid declaring variable in for()
This should fix compilation with gcc 2.95 and possibly others
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Loren Merritt
7a1944b907
vf_hqdn3d: x86 asm
13% faster on penryn, 16% on sandybridge, 15% on bulldozer
Not simd; a compiler should have generated this, but gcc didn't.
12 years ago
Loren Merritt
566858a770
vf_hqdn3d: support 16bit colordepth
12 years ago
Martin Storsjö
1d9c2dc89a
Don't include common.h from avutil.h
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Loren Merritt
1ad715dbf3
vf_hqdn3d: support 9 and 10bit colordepth
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
12 years ago
Loren Merritt
0f583e6cc5
vf_hqdn3d: reduce intermediate precision
11% faster on penryn, 7% on sandybridge, 5% on bulldozer
Negligible change to output.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
12 years ago
Loren Merritt
85e228c71d
vf_hqdn3d: simplify and optimize
14% faster on penryn, 2% on sandybridge, 9% on bulldozer
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
12 years ago