Vittorio Giovara
58400ac133
lavfi: name anonymous structs
11 years ago
Michael Niedermayer
0cc5011f9a
avfilter/vf_pad: fix req_end
Fixes out of array accesses
Fixes Ticket3190
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Anton Khirnov
cd43ca0443
lavfi: do not export the filters from shared objects
11 years ago
Michael Niedermayer
4bc7a2a64b
avfilter: remove duplicate includes
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Paul B Mahol
59d72f8b16
lavfi/pad,crop,scale: remove options description from filter description
Signed-off-by: Paul B Mahol <onemda@gmail.com>
11 years ago
Paul B Mahol
b211607b5c
avfilter: various cosmetics
Signed-off-by: Paul B Mahol <onemda@gmail.com>
11 years ago
Michael Niedermayer
e43a0a232d
avfilter: fix plane validity checks
Fixes out of array accesses
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Paul B Mahol
d2dd1e075c
lavfi/pad: use FFSIGN
Signed-off-by: Paul B Mahol <onemda@gmail.com>
12 years ago
Paul B Mahol
85e8a1169c
lavfi/pad: switch to AV_OPT_TYPE_COLOR
Signed-off-by: Paul B Mahol <onemda@gmail.com>
12 years ago
Anton Khirnov
3062ac4c47
vf_pad: use the name 's' for the pointer to the private context
This is shorter and consistent across filters.
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
40c885c589
vf_pad: switch to an AVOptions-based system.
12 years ago
Nicolas George
392ec7ec1c
lavfi/vf_pad: use standard options parsing.
12 years ago
Clément Bœsch
c10b57973d
lavfi/pad: fix horizontal/vertical shift confusion.
12 years ago
Xi Wang
5d639b2b4a
vf_pad: fix a & instead of && typo
Avoid buffer overflow in buffer_needs_copy()
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
12 years ago
Xi Wang
969e8d35b5
lavfi/pad: avoid buffer overflow in buffer_needs_copy()
Replace & with short-circuit &&.
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
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
Stefano Sabatini
1897109c00
lavfi/pad: add support to named options
12 years ago
Michael Niedermayer
6be0df5080
vf_pad: switch to filter_frame
Based on patch by Anton Khirnov
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
Anton Khirnov
ba04177eeb
vf_pad/scale: use double precision for aspect ratios.
Fixes Bug 203.
CC:libav-stable@libav.org
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
Anton Khirnov
8f3a3ce730
lavfi: check all ff_get_video_buffer() calls for errors.
13 years ago
Anton Khirnov
d4f89906e3
lavfi: add error handling to end_frame().
13 years ago
Anton Khirnov
e9b992d035
lavfi: add error handling to draw_slice().
13 years ago
Anton Khirnov
ebc8d97481
lavfi: add error handling to start_frame().
13 years ago
Ronald S. Bultje
3db407038e
lavfi: use const for AVFilterPad declarations in all filters.
12 years ago
Anton Khirnov
4c9080a7ef
lavfi: unref AVFilterLink.out_buf in ff_end_frame().
This reduces code duplication and prevents stale pointers from remaining
on the link.
13 years ago
Anton Khirnov
07bad27810
lavfi: unref AVFilterLink.cur_buf in ff_end_frame().
This reduces code duplication and prevents stale pointers from remaining
on the link.
13 years ago
Anton Khirnov
f493c644cd
vf_pad: don't give up its own reference to the output buffer.
13 years ago
Anton Khirnov
1a49a169eb
lavfi: make filters less verbose.
13 years ago
Anton Khirnov
a5e8c41c28
lavfi: remove 'opaque' parameter from AVFilter.init()
It is not used in any filters currently and is inherently evil. If
passing binary data to filters is required in the future, it should be
done with some AVOptions-based system.
13 years ago
Michael Niedermayer
46c50b1726
vf_pad: check that we have write permission before writing in the buffer.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Anton Khirnov
9d0bfc5052
lavfi: make AVFilterPad opaque after two major bumps.
It will allow adding new fields to it without ABI breaks.
13 years ago
Anton Khirnov
6d58358a3a
lavfi: make avfilter_get_video_buffer() private on next bump.
They are only useful inside filters and we don't allow user filters for
now.
13 years ago
Anton Khirnov
803391f719
lavfi: remove request/poll and drawing functions from public API on next bump
They are only useful inside filters and we don't allow user filters for
now.
13 years ago
Anton Khirnov
b74a1da49d
lavfi: make formats API private on next bump.
It is only useful inside filters and we don't allow user filters for
now.
13 years ago
Reimar Döffinger
24eac3cff5
Mark GRAY8 format as pseudo-paletted.
This fixes that the GIF encoder crashes with it because
it has no palette.
And the arguments for the pseudopalette apply to gray8 as
much as to RGB8 etc.
In addition the changes required in lavfi should be needed anyway
when adding support for RGB8 etc.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
13 years ago
Nicolas George
53b7a3fe08
vf_pad: port to new drawutils API.
13 years ago
Nicolas George
b50767c31d
vf_pad: keep a reference to the output buffer.
Once fixed, the end_frame function does exactly what
avfilter_default_end_frame does; therefore, end_frame
can be removed to let avfilter_default_end_frame work.
Fixes ticket #1038 .
13 years ago
Alex Converse
b0f29db5c2
Mark mutable static data const where appropriate.
13 years ago
Michael Niedermayer
b1b0fd2790
pad: fix format string length
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Reimar Döffinger
5af7daabc4
Mark AVFilterPad[] compound literals as const.
GCC 4.6.2 at least still seems to fail to put them in .rodata though,
see also http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37303
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
13 years ago
Reimar Döffinger
d78473334e
Add const to static arrays where it was forgotten.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
13 years ago
Michael Niedermayer
d7dcd96a23
vf_pad: Fix alignment of get_video_buffer()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Nicolas George
e2abe90ed7
vf_pad: remove mathematical constants now redundant.
Signed-off-by: Nicolas George <nicolas.george@normalesup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago