Matthieu Bouron
b3ea901945
swscale/arm/yuv2rgb: factorize lsl in load_args_yuv422p
2016-04-01 17:23:45 +02:00
Matthieu Bouron
466e209e6e
swscale/arm/yuv2rgb: fix comments in load_args_yuv422p
2016-04-01 17:23:45 +02:00
Matthieu Bouron
11b4acab8b
swscale/arm/yuv2rgb: remove 32bit code path
2016-04-01 17:23:45 +02:00
Pedro Arthur
6de58b4903
swscale: cleanup unused code
...
Removed previous swscale code under '#ifndef NEW_FILTER'
and removed unused fields of SwsContext
2016-03-31 16:36:16 -03:00
Michael Niedermayer
3b905b9fe6
swscale: Deprecate vector functions which are unused outside swscale
...
There are no known users of these functions within debian
It should be thus possible to remove these functions without recommandition of a
replacement
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-03-31 20:21:14 +02:00
Clément Bœsch
263eb76bdf
sws/aarch64: add ff_hscale_8_to_15_neon
...
./ffmpeg -nostats -f lavfi -i testsrc2=4k:d=2 -vf bench=start,scale=1024x1024,bench=stop -f null -
before: t:0.489726 avg:0.489883 max:0.491852 min:0.489482
after: t:0.256515 avg:0.256458 max:0.256999 min:0.253755
2016-03-31 10:12:55 +02:00
Lou Logan
06eef96b69
fix some a/an typos
...
Signed-off-by: Lou Logan <lou@lrcd.com>
2016-03-28 14:13:17 -08:00
Clément Bœsch
277408b7f1
sws/aarch64/yuv2rgb: save a few mul and add
...
27ms to 26ms with UHD 2160 input.
2016-03-25 16:14:13 +01:00
Clément Bœsch
f1148390d7
sws/aarch64: add {nv12,nv21,yuv420p,yuv422p}_to_{argb,rgba,abgr,rgba}_neon
2016-03-01 17:53:33 +01:00
Clément Bœsch
1e7a37f0a0
sws/yuv2rgb: clarify precision of coeff and offset for mmx code
...
It makes easier looking at the difference with the generic code just
below.
2016-02-27 11:13:26 +01:00
Clément Bœsch
f9987464cf
sws/yuv2rgb: avoid a few ub on signed left shifts
2016-02-27 11:13:26 +01:00
Derek Buitenhuis
1a12eb4a73
Merge commit '29c2d06d67724e994980045afa055c6c34611b30'
...
* commit '29c2d06d67724e994980045afa055c6c34611b30':
cosmetics: Drop empty comment lines
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-02-24 17:31:44 +00:00
Kieran Kunhya
4170a44bbc
Add GBRAP12 pixel format
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-24 03:22:31 +01:00
Michael Niedermayer
67e5bd0c50
swscale/utils: Fix chrSrcHSubSample for GBRAP16
...
Fixes part of Ticket5264
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-24 00:02:44 +01:00
Michael Niedermayer
df36257a53
swscale/input: Fix GBRAP16 input
...
Fixes part of Ticket5264
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-24 00:02:44 +01:00
Xiaolei Yu
5a91589476
swscale/arm: re-enable neon rgbx to nv12 routines
...
Commit '842b8f4ba2e79b9c004a67f6fdb3d5c5d05805d3' fixed clang/iphone
build but failed on some versions of cygwin. It has now been verified
to work on both platforms.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-22 17:29:58 +01:00
Diego Biurrun
29c2d06d67
cosmetics: Drop empty comment lines
2016-02-18 15:35:30 +01:00
Michael Niedermayer
f6492a2ea8
swscale/x86/output: Fix yuv2planeX_16* with unaligned destination
...
Reviewed-by: BBB
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-17 04:47:51 +01:00
Michael Niedermayer
d07f6e5f1c
swscale/x86/output: Move code into yuv2planeX_mainloop
...
Reviewed-by: BBB
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-17 04:47:34 +01:00
Derek Buitenhuis
15d9645fb4
swscale/slice: Actually use the buffers' strides
...
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-02-16 14:25:25 +00:00
Michael Niedermayer
23261e6001
sws/output: fix ordered dither threshold for mono output
...
This makes sure that white stays white and black black
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-10 17:22:26 +01:00
Michael Niedermayer
61ea7f1509
swscale/swscale-test: Check av_image_fill_linesizes() for failure
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-04 01:49:38 +01:00
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>
2016-01-27 16:36:46 +00:00
Hendrik Leppkes
2e31434d84
swscale: add P010 input support
2016-01-26 12:10:45 +01:00
Vittorio Giovara
e9175634ec
yuv2rgb: Document the color space coefficients
...
Based on the original documentation found in mpeg2dec (1995).
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-01-20 11:18:31 -05:00
Vittorio Giovara
ff8c2c4103
yuv2rgb: Document the color space coefficients
...
Based on the original documentation found in mpeg2dec (1995).
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-01-19 23:30:36 +01:00
Michael Niedermayer
321e85e176
swscale/swscale: Add some sanity checks for srcSlice* parameters
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-17 20:35:36 +01:00
Michael Niedermayer
c8a9aaab26
swscale/x86/rgb2rgb_template: Fix planar2x() for short width
...
Fixes: 451b3e0cf956c0bd2f27ed753ac24050/asan_heap-oob_2873c01_3231_7ed10a9464d15f0d57277f5917c566a8.AVI
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-17 12:34:34 +01:00
Michael Niedermayer
757248ea3c
swscale/swscale_unscaled: Fix odd height inputs for bayer_to_yv12_wrapper()
...
Fixes: 372d2df1f04b49e25f109f07f90b1505/asan_heap-oob_2835d2e_8501_99e0114d7ba3a6db885d0b4684d200c1.cine
Fixes out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-17 01:19:43 +01:00
Michael Niedermayer
ad3b6fa7d8
swscale/swscale_unscaled: Fix odd height inputs for bayer_to_rgb24_wrapper()
...
Fixes: 372d2df1f04b49e25f109f07f90b1505/asan_heap-oob_2835d2e_8501_99e0114d7ba3a6db885d0b4684d200c1.cine
Fixes out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-17 01:19:43 +01:00
Michael Niedermayer
fc2588a1d6
swscale/vscale: Use matching sliceY/chrSliceY for luma/chroma
...
No case known where that makes a difference
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 23:49:52 +01:00
Michael Niedermayer
eb7802afef
swscale/vscale: Check that 2 tap filters are bilinear before using bilinear code
...
Fixes: out of array reads
Fixes: 07e8b9c5d348ccdf7add0f37de20cf6c/asan_heap-oob_27e8df7_6849_e56653f768070ec8cb52f587048444c2.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:59:12 +01:00
Michael Niedermayer
b99f498716
swscale/output: Assert that yalpha and uvalpha are within their expected range
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
fe6372bb61
swscale/vscale: Add fixme comment to "ugly" code
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
705a2f70ee
swscale/slice: Fix indention
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
8feeffc1d7
swscale/slice: Fix doc typo
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
e06403331c
swscale: Move Contexts used only in hscale.c into it
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
7b6e6895f2
swscale: Move VScalerContext into vscale.c
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 21:58:02 +01:00
Michael Niedermayer
cc538e9dbd
swscale/utils: Detect and skip unneeded sws_setColorspaceDetails() calls
...
This avoids running various table inits unnecessarily
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 15:46:55 +01:00
Michael Niedermayer
8f3a9a8c27
swscale/yuv2rgb: Increase YUV2RGB table headroom
...
This makes SWS more robust
Fixes: 07650a772d98aa63b0fed6370dc89037/asan_heap-oob_27ddeaf_2657_2c81ff264dee5d9712cb3251fb9c3bbb.264
Fixes: out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 15:46:55 +01:00
Michael Niedermayer
5e5f82a287
swscale/yuv2rgb: Factor YUVRGB_TABLE_LUMA_HEADROOM out
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-14 15:46:55 +01:00
Clément Bœsch
e8bc642202
lavu: add AV_CEIL_RSHIFT and use it in various places
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-01-11 15:32:56 -05:00
Michael Niedermayer
1edf129cbc
swscale/utils: Use normal bilinear scaler if fast cannot be used due to tiny dimensions
...
Fixes Ticket4960
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-04 23:54:11 +01:00
Matthieu Bouron
e4e9b9454e
swscale/arm/yuv2rgb: add ff_yuv422p_to_{argb,rgba,abgr,bgra}_neon_{16,32}
2016-01-04 18:56:52 +01:00
Matthieu Bouron
44913d1945
swscale/arm/yuv2rgb: fix typo
2016-01-04 18:56:52 +01:00
Michael Niedermayer
b83d8be6bf
swscale/utils: Fix intermediate format for cascaded alpha downscaling
...
Fixes Ticket4926
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-12-24 21:46:15 +01:00
Matthieu Bouron
b32a42295a
swscale/arm/yuv2rgb: add ff_yuv420p_to_{argb,rgba,abgr,bgra}_neon_{16,32}
2015-12-19 22:09:28 +01:00
Matthieu Bouron
e0dc22b99e
swscale/arm/yuv2rgb: disable neon if accurate_rnd is enabled
...
This disables the 32bit precision neon code path in favor of the
default C one and avoids breaking fate.
2015-12-19 22:09:28 +01:00
Matthieu Bouron
c2ad248321
swscale/arm/yuv2rgb: simplify process_16px_* macro call
2015-12-19 10:42:33 +01:00
Clément Bœsch
91b4afd58d
swscale/arm/yuv2rgb: fix slicing
2015-12-18 16:21:49 +01:00
Michael Niedermayer
a066ff89bc
swscale/x86/rgb2rgb_template: Fallback to mmx in interleaveBytes() if the alignment is insufficient for SSE*
...
This also as a sideeffect fixes the non aligned case
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-12-15 03:06:33 +01:00
Michael Niedermayer
80bfce35cc
swscale/x86/rgb2rgb_template: Do not crash on misaligend stride
...
Fixes Ticket5013
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-12-15 02:32:23 +01:00
Ganesh Ajjanagadde
c8905e0d67
swscale/utils: replace pow by exp2
...
exp2 is a faster function.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-12-08 22:00:05 -05:00
Matthieu Bouron
5aca33c2cf
swscale/arm: add ff_nv{12,21}_to_{argb,rgba,abgr,bgra}_neon_16
2015-12-08 08:12:42 +01:00
Michael Niedermayer
325b59368d
swscale/utils: Fix for runtime error: left shift of negative value -1
...
Fixes: c106b36fa36db8ff8f3ed0c82be7bea2/asan_heap-oob_32699f0_6321_467b9a1d7e03d7cfd310b7e65dc53bcc.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-12-04 21:44:53 +01:00
Clément Bœsch
010caed261
swscale: use AV_OPT_TYPE_BOOL for {src,dst}_range options
2015-12-04 15:43:34 +01:00
Matthieu Bouron
46feb66972
swscale/arm: add ff_nv{12,21}_to_{argb,rgba,abgr,bgra}_neon
...
Signed-off-by: Matthieu Bouron <matthieu.bouron@stupeflix.com>
Signed-off-by: Clément Bœsch <clement@stupeflix.com>
2015-11-23 14:47:12 +01:00
Andreas Cadhalpun
e8c3716064
swscale: rename sws_rgb2rgb_init to ff_sws_rgb2rgb_init
...
It is an internal swscale function and thus should not be exported.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-10-29 23:49:46 +01:00
Andreas Cadhalpun
8bfbc8c5e5
swscale: rename sws_context_class to ff_sws_context_class
...
It is an internal swscale symbol and thus should not be exported.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-10-29 23:49:10 +01:00
Ganesh Ajjanagadde
cd8a0a9a9a
swscale/swscale: add av_warn_unused_result to sws_init_context
...
This should not trigger any warnings; but adds robustness.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-10-16 17:18:21 -04:00
Pedro Arthur
5bd62a1b3c
swscale: fix ticket #4881
...
When scaling only a slice of a frame the output was written always
in the first lines leaving the rest of the frame black.
2015-10-13 13:43:39 -03:00
Ganesh Ajjanagadde
3b2000c2bf
doc/scaler, swscale/options: use proper capitalization
...
Proper names should be capitalized in all user facing API as far as
possible. The option names themselves have not been changed since:
1. We consistently keep option names in lower case.
2. Changing them would break existing scripts.
The converse is also true: improper names should not be capitalized
generally.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-10 19:32:56 +02:00
Ganesh Ajjanagadde
26e8895b73
all: add _DEFAULT_SOURCE locally wherever needed
...
Glibc 2.20 onwards generates a deprecation warning for usage of _BSD_SOURCE and _SVID_SOURCE.
The solution from man feature_test_macros is to define both _DEFAULT_SOURCE and the old macros.
This solution is on the lines of the one in commit af1818276e
.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2015-10-04 12:15:16 -04:00
Pedro Arthur
a8602dde5e
swscale: fix ticket #4877
2015-09-25 12:18:58 -03:00
Pedro Arthur
77367f61b3
swscale: fix ticket 4850
2015-09-20 18:08:14 -03:00
Ganesh Ajjanagadde
7cf22c7970
swscale/output: fix undefined left shifts of negative numbers
...
This fixes -Wshift-negative-value reported with clang 3.7+, e.g
http://fate.ffmpeg.org/log.cgi?time=20150918181527&log=compile&slot=x86_64-darwin-clang-polly-vectorize-stripmine-3.7 .
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-20 01:14:36 +02:00
Ganesh Ajjanagadde
b4cb597900
libswscale/swscale: fix -Wunused-function
...
hyscale, hcscale are only used in old filter code, hence place
header guard to silence -Wunused-function.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-18 23:19:42 +02:00
Ganesh Ajjanagadde
80d23d9d32
swscale/swscale: silence unused function warning
...
gamma_convert is only used with the old code. Thus, it is
placed under a header guard. This patch silences a -Wunused-function
observed on GCC 5.2.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-09-16 16:31:29 -07:00
Michael Niedermayer
0ae40c5a70
swscale/swscale: Fix "unused variable" warning
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-11 20:59:32 +02:00
Michael Niedermayer
d730dd8c53
swscale: Forward colorspace updates to the 2nd cascaded context in case of alphablend
...
The first just does the blending and wouldnt do anything with the colorspace values
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-10 17:05:20 +02:00
Michael Niedermayer
21c7272859
swscale/utils: Forward luma range to the cascaded context for alphablending
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-10 17:05:20 +02:00
Michael Niedermayer
319898bba2
swscale/utils: handle gray+alpha formats like gray for luma ranges
...
Its illogic to handle gray differently depending on the existence of an alpha channel
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-10 15:00:19 +02:00
Michael Niedermayer
816cf5181e
swscale/utils: If the source has no alpha then disable alpha blendaway
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-10 15:00:19 +02:00
Clément Bœsch
c97cd1169c
swscale: use AV_OPT_TYPE_BOOL
2015-09-08 22:39:24 +02:00
Hendrik Leppkes
5d8e836d0e
Replace all remaining occurances of step/depth_minus1 and offset_plus1
2015-09-08 17:10:48 +02:00
Hendrik Leppkes
151aa2ebff
Merge commit '2268db2cd052674fde55c7d48b7a5098ce89b4ba'
...
* commit '2268db2cd052674fde55c7d48b7a5098ce89b4ba':
lavu: Drop the {minus,plus}1 suffix from AVComponentDescriptor fields
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-08 16:35:28 +02:00
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>
2015-09-07 12:37:47 +02:00
Hendrik Leppkes
160e92c8bf
Merge commit 'e88103a7f92cf27a2868b50acc8a9912f6088249'
...
* commit 'e88103a7f92cf27a2868b50acc8a9912f6088249':
Bump major versions of all libraries
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-05 21:35:46 +02:00
Hendrik Leppkes
cebe51a625
Merge commit '9d58639e270f7612874681e0ca30fa461e2667b7'
...
* commit '9d58639e270f7612874681e0ca30fa461e2667b7':
sws: Drop deprecated SWS_CPU_CAPS defines
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-05 15:58:52 +02:00
Pedro Arthur
3059562aa1
swscale: re-enable gamma
...
+added gamma conversion to refactored code
2015-09-04 19:00:20 -03:00
Pedro Arthur
f67aff3ad7
swscale: added proper error check for ff_init_filters
2015-09-04 19:00:20 -03:00
Michael Niedermayer
1acd6311a1
swscale/utils: If cascaded contexts are used forward sws_setColorspaceDetails() to the first context
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-31 02:00:55 +02:00
Michael Niedermayer
8e05f9217a
swscale/utils: Split scaling if possible and yuv->yuv with different matrixes is requested
...
This uses a RGB intermediate, a more optimal solution would be to perform the rematrixing
directly in subsampled YUV, this is quite a bit more complicated though
Fixes Ticket4805
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-31 02:00:19 +02:00
Vittorio Giovara
e88103a7f9
Bump major versions of all libraries
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-08-28 16:04:28 +02:00
Vittorio Giovara
9d58639e27
sws: Drop deprecated SWS_CPU_CAPS defines
...
Deprecated in 07/2012.
2015-08-28 10:55:26 +02:00
Timothy Gu
68a9c8ac77
swscale: Silence an unused variable warning
...
Also remove a pair of extraneous ifdeffery.
2015-08-25 17:40:06 -07:00
Ganesh Ajjanagadde
eb3cfa7dd3
swscale/alphablend: fix pointer cast
...
Commit 7c72a4bbd3
was slightly wrong
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-08-22 20:11:48 +00:00
Michael Niedermayer
7c72a4bbd3
swscale/alphablend: Fix pointer type warnings
...
Found-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-21 12:14:08 +02:00
Pedro Arthur
62d176de12
swscale: refactor vertical scaler
2015-08-19 10:43:52 -03:00
Pedro Arthur
4545906f60
swscale: Fixed typos
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-18 22:56:50 +02:00
Pedro Arthur
ed80dec621
swscale: fixed compiler warnings
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-18 22:56:50 +02:00
Pedro Arthur
0f3687d6fb
swscale: add license headers and copyrights
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-18 22:56:50 +02:00
Pedro Arthur
737aa902f0
swscale: process horizontal lines in batches
...
Process more lines in a single pass to improve performance
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-18 01:33:32 +02:00
Pedro Arthur
e0a3173a94
swscale: refactor horizontal scaling
...
+ split color conversion from scaling
- disabled gamma correction, until it's refactored too
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-18 01:33:32 +02:00
Michael Niedermayer
3afca32561
swscale/swscale-test: Fix slice height in random reference data creation.
...
Found-by: Pedro Arthur <bygrandao@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-17 03:08:10 +02:00
Michael Niedermayer
0f9d46b70d
swscale/alphablend: Support chroma subsampling
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 18:04:46 +02:00
Michael Niedermayer
c5ebeaa308
swscale/alphablend: Support SWS_ALPHA_BLEND_CHECKERBOARD
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 17:11:53 +02:00
Michael Niedermayer
87100e828a
swscale/alphablend: Factor target computation out of the loops
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 16:09:30 +02:00
Michael Niedermayer
f28ba31b1b
swscale/alphablend: Fix big endian formats on LE
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 15:59:12 +02:00
Michael Niedermayer
b7faa9d314
swscale/alphablend: support packed pixel formats
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 15:58:43 +02:00
Michael Niedermayer
c64f01227f
swscale/swscale: Document param[0..1]
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-09 14:33:19 +02:00
Michael Niedermayer
d0e0757e9a
swscale: Implement alphablendaway for planar 4:4:4 formats
...
Fixes Ticket4746
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-08 13:24:52 +02:00
Michael Niedermayer
c382d9e8cb
swscale: Add sws_alloc_set_opts()
...
This simplifies allocating and initializing swscale contexts with custom options.
The function is internal currently but could be moved into the public header
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-08 13:08:16 +02:00
Michael Niedermayer
1909a9151c
swscale/output: Fix "warning: assignment from incompatible pointer type"
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-25 03:15:56 +02:00
Paul B Mahol
3cb8eee6f7
swscale: ayuv64le output support
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-07-24 03:45:48 +00:00
Paul B Mahol
052f64ecb2
swscale: ayuv64le input support
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-07-24 03:44:58 +00:00
Rong Yan
2af180bf1b
swscale/ppc/yuv2rgb_altivec: POWER LE support in the macros vec_unh() and vec_unl()
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-16 14:27:58 +02:00
Michael Niedermayer
a5d44d5c22
swscale/utils: Clear pix buffers
...
Fixes use of uninitialized memory
Fixes: a96874b9466b6edc660a519c7ad47977_signal_sigsegv_7ffff713351a_744_nc_sample.avi with memlimit 2147483648
Found-by: Samuel Groß, Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-15 20:06:34 +02:00
Kevin Coyle
1262711388
YUV->BGR32 MMX support
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-04 00:03:45 +02:00
Michael Niedermayer
8255b14c68
swscale/output: fix input indexing in yuv2ya8_2_c()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-04 00:03:45 +02:00
Michael Niedermayer
ab80d3fb3a
swscale/output: fix null pointer dereference in yuv2ya8_2_c()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-03 23:03:25 +02:00
Paul B Mahol
2778fdbe54
swscale: implement YA8 output
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-07-02 17:36:05 +00:00
Michael Niedermayer
f6ab967eae
swscale/swscale_unscaled: Fix rounding difference with RGBA output between little and big endian
...
Fixes fate/dds-rgb16 on big endian
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 13:54:35 +02:00
James Almer
e22edbfd41
swscale/x86/rgb2rgb_template: fix signedness of v in shuffle_bytes_2103_{mmx,mmxext}
...
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: James Almer <jamrial@gmail.com>
2015-06-23 13:28:09 -03:00
James Almer
0c15f2f158
swscale/x86/rgb2rgb_template: don't call emms on sse2/avx functions
...
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: James Almer <jamrial@gmail.com>
2015-06-23 13:28:03 -03:00
James Almer
910eeab480
swscale/x86/rgb2rgb_template: add missing xmm clobbers
...
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: James Almer <jamrial@gmail.com>
2015-06-23 13:27:56 -03:00
Michael Niedermayer
7604358018
swscale/rgb2rgb_template: Fix signedness of v in shuffle_bytes_2103_c()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-23 05:09:11 +02:00
Michael Niedermayer
abb833c568
swscale/rgb2rgb_template: Implement shuffle_bytes_0321_c and fix shuffle_bytes_2103_c on BE
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-23 05:09:06 +02:00
Michael Niedermayer
4df3cf90bf
swscale/rgb2rgb_template: Disable shuffle_bytes_2103_c on big endian
...
The function is specific to little endian
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-22 22:23:22 +02:00
Michael Niedermayer
e29d996149
swscale/output: Add rgba64/rgb48/bgra64/bgr48 output functions with full chroma interpolation
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-17 00:45:46 +02:00
Michael Niedermayer
f140a99f8b
swscale/output: Factorize rgb48 and 64bit code
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-17 00:45:46 +02:00
Michael Niedermayer
80b5a1e2ee
Mark vectors as NAN instead of dereferencing NULL pointers on malloc failure
...
Found-by: Daemon404
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-12 15:06:32 +02:00
Michael Niedermayer
ae0148ff60
swscale: Assert that pixel format descriptor is not NULL
...
This may help static analyzers, the pixel format is checked
during initialization
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-12 14:47:37 +02:00
Luca Barbato
da60b99a88
ppc: Restrict some Altivec implementations to Big Endian
...
In Little Endian the vec_ld/vec_st operations work as
expected only for byte-vectors.
2015-05-31 12:07:11 +02:00
Nick Lewycky
891df2a1ae
libswscale/x86/hscale_fast_bilinear_simd.c: There's no need to save BX if it's in the clobber list.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-13 11:59:30 +02:00
Nick Lewycky
48e9f68384
libswscale/x86/hscale_fast_bilinear_simd.c: Include BX in the clobber list on x86_64, because it isn't implicitly included when PIC is on.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-13 11:59:12 +02:00
Michael Niedermayer
54e64eaf68
swscale/x86/swscale: Fix warning about loosing significant bits in cast
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-10 15:09:04 +02:00
Michael Niedermayer
3b12335395
swscale/x86/hscale_fast_bilinear_simd: Remove ancient out-commented debug code
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-07 23:58:08 +02:00
Michael Niedermayer
b28d5c49f7
Merge remote-tracking branch 'rbultje/vp9-profile23-wip'
...
* rbultje/vp9-profile23-wip:
libvpxdec: add 440 pixfmts.
vp9: add profile 2/3 fate tests.
vp9: add inter-frame profile 2/3 suport.
vp9: add keyframe profile 2/3 support.
vp9: parse profile 2/3 bitdepth in frame header.
vp9: add profile 2/3 to exported profiles.
fate: add/update reference files for 440 addition.
swscale: add yuv440p10/12 pixfmts.
lavc: add yuv440p10/12 formats to aligned pixfmt list.
lavu: add yuv440p10/12 pixfmts.
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-07 13:22:04 +02:00
Michael Niedermayer
21b30947f2
swscale/x86/hscale_fast_bilinear_simd: Fix variable names in comments
...
Found-by: Nick Lewycky <nlewycky@google.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-07 03:57:21 +02:00
Ronald S. Bultje
711d8812ad
swscale: add yuv440p10/12 pixfmts.
2015-05-06 12:04:31 -04:00
Rong Yan
603c839398
swscale/ppc/swscale_altivec.c: POWER LE support in yuv2planeX_8() delete macro GET_VF() it was wrong
...
GCC tool had a bug of PPC intrinsic interpret, which has been fixed in GCC 4.9.1. This bug lead to
errors in two of our previous patches. We found this when we update our GCC tools to 4.9.1 and by
reading the related info on GCC website. We fix our previous error in two separate commits
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-27 12:59:05 +02:00
Michael Niedermayer
b57f9f5724
swscale/swscale: Get rid of the SWS_GAMMA_CORRECT flag
...
This avoids using up a bit of the public flags
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-23 20:34:51 +02:00
Pedro Arthur
2a7128f4ed
Add gamma encodign/decoding before/after scaling in libswscale
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-23 20:34:51 +02:00
Michael Niedermayer
bdcd36a4c8
swscale/output: Fix undefined shifts
...
Fixes: da14e86d8462be6493eab16bc2d40f88/asan_heap-oob_204cfd2_528_cov_340150052_COMPRESS.BMP
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-25 18:31:25 +01:00
Michael Niedermayer
324067d18b
Merge commit '7ebb3022297aa00afda6800105684b8303f2608e'
...
* commit '7ebb3022297aa00afda6800105684b8303f2608e':
swscale: Check memory allocation
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-22 03:40:37 +01:00
Federico Tomassetti
7ebb302229
swscale: Check memory allocation
...
Bug-Id: CID 1267890
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-03-21 23:18:11 +01:00
Michael Niedermayer
3e48616226
Merge commit '9a60b1fad02cb783b895b2145c3dafc01f7b337c'
...
* commit '9a60b1fad02cb783b895b2145c3dafc01f7b337c':
libswscale: fix compiler warnings enumerated type mixed with another type
Conflicts:
libswscale/swscale_unscaled.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 00:15:16 +01:00
Himangi Saraogi
9a60b1fad0
libswscale: fix compiler warnings enumerated type mixed with another type
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-03-15 18:29:22 +01:00
Christophe Gisquet
5d38c628b0
ppc: libswscale: use LOCAL_ALIGNED instead of DECLARE_ALIGNED
...
The later may yield incorrect code for on-stack variables.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-14 18:39:28 +01:00
Michael Niedermayer
fa74058dd3
swscale/utils: Fix undefined shift in initFilter()
...
Found-by: Clang -fsanitize=shift
Reported-by: Thierry Foucu <tfoucu@google.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-11 15:40:28 +01:00
Michael Niedermayer
ae20682f6b
swscale: Add prefix to updateMMXDitherTables()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-27 19:23:46 +01:00
Michael Niedermayer
007498fc1a
swscale/utils: clear formatConvBuffer on allocation
...
Fixes use of uninitialized memory
Fixes: asan_heap-oob_35ca682_1474_cov_3230122439_aletrek_tga_16bit.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-27 03:13:14 +01:00
Michael Niedermayer
fb8e5044b4
swscale/utils: add asserts to check filterpos
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-24 01:00:24 +01:00
Michael Niedermayer
1895d414aa
swscale/utils: More carefully merge and clear coefficients outside the input
...
Fixes out of array read
Fixes: asan_heap-oob_35ca682_1474_cov_3230122439_aletrek_tga_16bit.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-24 01:00:24 +01:00
Michael Niedermayer
03bffb68f6
swscale: Use av_clip_uintp2()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-21 14:49:17 +01:00
Michael Niedermayer
b20426398c
swscale/yuv2rgb: Use av_clip_uint8()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-21 14:44:47 +01:00
Michael Niedermayer
d501b986a9
swscale/bayer_template: Add () to protect the argument of BAYER_READ()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-18 01:55:15 +01:00
Michael Niedermayer
2a1b79d7e6
Merge commit 'e51f22122d23589e93ac4f0b3e570bb925755915'
...
* commit 'e51f22122d23589e93ac4f0b3e570bb925755915':
swscale: Check memory allocations
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-17 22:22:17 +01:00
Federico Tomassetti
e51f22122d
swscale: Check memory allocations
...
CC: libav-stable@libav.org
Bug-Id: CID 1267888 / CID 1267890
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-02-17 12:16:43 -05:00
Michael Niedermayer
692b22626e
swscale/utils: Limit filter shifting so as not to read from prior the array
...
Fixes out of array read
Fixes: asan_heap-oob_1fb2f9b_3780_cov_3984375136_usf.mkv
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-02-05 00:33:50 +01:00
Michael Niedermayer
f30798584f
swscale/input: fix rgba64 alpha non native
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-21 21:21:00 +01:00
Michael Niedermayer
95d04690aa
swscale/input: Fix alpha of YA16 input
...
Fixes Ticket4278
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-21 21:21:00 +01:00
Vittorio Giovara
2df7277711
swscale: fix gbrap to gbrap alpha scaling
2015-01-16 02:47:15 +01:00
Vittorio Giovara
89df3fd49e
swscale: fix warning about incompatible function pointer type
2015-01-16 02:47:10 +01:00
Michael Niedermayer
27513846f6
Merge commit '928061670e873e816daa14827853b7e11221ff5f'
...
* commit '928061670e873e816daa14827853b7e11221ff5f':
libswscale: GBRAP input & output and GBRAP16 input support
Conflicts:
libswscale/input.c
libswscale/swscale_internal.h
libswscale/swscale_unscaled.c
libswscale/utils.c
tests/ref/fate/filter-pixdesc-gbrap
tests/ref/fate/filter-pixfmts-copy
tests/ref/fate/filter-pixfmts-null
tests/ref/fate/filter-pixfmts-scale
tests/ref/fate/filter-pixfmts-vflip
See: 5c057433cc
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-15 05:47:25 +01:00
Paul B Mahol
928061670e
libswscale: GBRAP input & output and GBRAP16 input support
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-01-14 17:17:24 +01:00
Michael Niedermayer
90de28befd
Merge commit '1dd797e3c9f179f957316a0becbec048b42df8aa'
...
* commit '1dd797e3c9f179f957316a0becbec048b42df8aa':
swscale: check memory allocations
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-06 21:44:50 +01:00
Vittorio Giovara
1dd797e3c9
swscale: check memory allocations
...
CC: libav-stable@libav.org
Bug-Id: CID 1257779
2015-01-05 15:35:39 +01:00
Kieran Kunhya
18982f084c
swscale: Pass through chroma positions in sws_getCachedContext
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 17:55:12 +01:00
Michael Niedermayer
3a2bed1f9e
swscale/yuv2rgb: Fix width % 4 != 0 with bgr4_byte/rgb4_byte
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 00:33:21 +01:00
Michael Niedermayer
3848512d48
swscale/yuv2rgb: Fix width % 4 != 0 with bgr4/rgb4
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 00:32:53 +01:00
Michael Niedermayer
3d00ba2688
swscale/yuv2rgb: fix width % 8 != 0 and rgb/bgr8 output
...
Fixes Ticket2570
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 00:23:49 +01:00
Michael Niedermayer
2a983ff7fe
swscale: increase yuv2rgb table headroom
...
Fixes out of array access
Fixes: case2_bad_read_yuv2rgbx32.mp4
Found-by: Michal Zalewski <lcamtuf@coredump.cx>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-16 23:37:26 +01:00
Michael Niedermayer
e827f65618
Merge commit '33c827f632f95ffe3399b695a5a0d47b366b6e20'
...
* commit '33c827f632f95ffe3399b695a5a0d47b366b6e20':
swscale: Properly scale YUV
Conflicts:
libswscale/swscale_unscaled.c
tests/ref/fate/filter-pixdesc-yuv420p10be
tests/ref/fate/filter-pixdesc-yuv420p10le
tests/ref/fate/filter-pixdesc-yuv420p9be
tests/ref/fate/filter-pixdesc-yuv420p9le
tests/ref/fate/filter-pixdesc-yuva420p10be
tests/ref/fate/filter-pixdesc-yuva420p10le
tests/ref/fate/filter-pixdesc-yuva420p9be
tests/ref/fate/filter-pixdesc-yuva420p9le
tests/ref/fate/filter-pixfmts-copy
tests/ref/fate/filter-pixfmts-null
tests/ref/fate/filter-pixfmts-scale
tests/ref/fate/filter-pixfmts-vflip
See: abe0b8e9f3
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-06 01:30:08 +01:00
Derek Buitenhuis
33c827f632
swscale: Properly scale YUV
...
Only shift limited range luma, and always only shift chroma
for upconversion.
Based off a patch by Michael Niedermayer.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-12-05 13:03:49 +00:00
Michael Niedermayer
8524558858
swscale/x86/rgb2rgb_template: fix crash with tiny size and nv12 output
...
Fixes Ticket4151
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-03 20:21:56 +01:00
Michael Niedermayer
4388e78a0f
swscale/x86/rgb2rgb_template: handle the first 2 lines with C in rgb24toyv12_*()
...
This avoids out of array accesses
Should fix Ticket3451
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-20 01:20:31 +01:00
Michael Niedermayer
2f6bb86f85
swscale/utils: support bayer input + scaling, and bayer input + any supported output
...
Fixes Ticket4053
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-12 23:59:37 +01:00
Rong Yan
e74e14608f
libswscale/ppc/swscale_altivec.c : fix hScale_altivec_real() yuv2planeX_16_altivec() yuv2planeX_8() for little endian
...
add marcos GET_LS() GET_VF() LOAD_FILTER() LOAD_L1() GET_VF4() FIRST_LOAD() UPDATE_PTR() LOAD_SRCV() LOAD_SRCV8() GET_VFD() for POWER LE
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-12 15:15:03 +01:00
Kieran Kunhya
b546023b93
swscale: fix yuv2yuvX_8 assembly on x86
...
use_mmx_vfilter check/fix by commiter
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-11-09 23:52:17 +01:00
Michael Niedermayer
fa040c2247
Merge commit 'fc1eda543c6ef043300612db90da5cfd972af650'
...
* commit 'fc1eda543c6ef043300612db90da5cfd972af650':
swscale: fix sign extensions in yuv planar conversion
Conflicts:
libswscale/rgb2rgb_template.c
See: a07e9d72a1
See: a30972609c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-10-18 23:40:50 +02:00
Vittorio Giovara
fc1eda543c
swscale: fix sign extensions in yuv planar conversion
...
Casting the left-most byte to unsigned avoids an undefined
result of the shift by 24 if bit 7 is set.
yuvPlanartouyvy_c and yuvPlanartoyuy2_c are affected.
CC: libav-stable@libav.org
Bug-Id: CID 732281 / CID 732282
2014-10-18 16:15:10 +01:00
Michael Niedermayer
fba894615d
swscale: support internal scaler cascades
...
Fixes Ticket3170
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-10-11 05:05:17 +02:00
James Almer
fb7d8d50bc
swscale: remove obsolete FF_API_SWS_FORMAT_NAME cruft
...
Signed-off-by: James Almer <jamrial@gmail.com>
2014-10-05 17:10:29 -03:00
Michael Niedermayer
61af6bebb4
swscale: Allow chroma samples to be above and to the left of luma samples
...
Found-by: Kierank
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-09-21 12:23:24 +02:00
Vitor Sessak
55d11d277b
swscale/x86: do not expect registers to be preserved across inline ASM blocks
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-09-18 00:03:29 +02:00
Clément Bœsch
d469aa8cfa
sws: use av_clip() instead of av_clip_c()
2014-09-16 16:57:20 +02:00
James Almer
9ffac3d00d
lsws: duplicate ff_log2_tab
...
libswscale uses the table but wasn't duplicating it like the rest of the libs.
This should fix compilation failures on msvc/icl after lavu stopped exporting
internal functions and tables.
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-12 20:52:21 +02:00
Michael Niedermayer
a57ece0cb4
Merge commit '1985c2e75c607ac51bfd8dc87d2957a5edf2b6f8'
...
* commit '1985c2e75c607ac51bfd8dc87d2957a5edf2b6f8':
Bump major versions of all libraries.
Conflicts:
doc/APIchanges
libavcodec/version.h
libavdevice/version.h
libavfilter/version.h
libavformat/version.h
libavutil/version.h
libswscale/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-10 00:26:45 +02:00
Michael Niedermayer
3e41d2e612
Merge commit 'f4c444e17d137c786f0ed2da0e5943df505d5f9e'
...
* commit 'f4c444e17d137c786f0ed2da0e5943df505d5f9e':
Postpone API-incompatible changes until the next bump.
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-09 22:19:45 +02:00
Anton Khirnov
1985c2e75c
Bump major versions of all libraries.
2014-08-09 16:58:33 +00:00
Anton Khirnov
f4c444e17d
Postpone API-incompatible changes until the next bump.
2014-08-09 16:57:10 +00:00
Michael Niedermayer
4917fecf4a
Merge commit 'bb789016d423d2cfacd2904ac66257bdf7f0964e'
...
* commit 'bb789016d423d2cfacd2904ac66257bdf7f0964e':
swscale: Undeprecate sws_getContext()
Conflicts:
libswscale/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-07 20:52:40 +02:00
Diego Biurrun
bb789016d4
swscale: Undeprecate sws_getContext()
...
sws_getCachedContext is not a full replacement for the function.
2014-08-07 04:03:00 -07:00
Michael Niedermayer
aee99a5d44
swscale/swscale_internal: fix ya16 -> rgba
...
Fixes Ticket644
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-05 01:51:11 +02:00
Michael Niedermayer
700bf1fa4e
swscale/swscale_unscaled: fix ya16 input
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-05 00:33:27 +02:00
Michael Niedermayer
2f5bf2f7f2
Merge commit 'f84a1b597c29dc035b8d5529ef88c2d7ff057820'
...
* commit 'f84a1b597c29dc035b8d5529ef88c2d7ff057820':
swscale: support AV_PIX_FMT_YA16 as input
Conflicts:
libswscale/swscale_unscaled.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-04 22:32:13 +02:00
Michael Niedermayer
4c8bc6fdee
Merge commit 'e96c3b81cadd0ba84d43b1f3a54980df3785d9a5'
...
* commit 'e96c3b81cadd0ba84d43b1f3a54980df3785d9a5':
avutil: rename AV_PIX_FMT_Y400A to AV_PIX_FMT_YA8
Conflicts:
libavcodec/libopenjpegdec.c
libavcodec/libopenjpegenc.c
libavcodec/raw.c
libavutil/pixdesc.c
libavutil/pixfmt.h
libavutil/version.h
libswscale/swscale_internal.h
libswscale/swscale_unscaled.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-04 21:48:00 +02:00
Michael Niedermayer
8862c49661
Merge commit '5420099cab1e915b191cceccec4364f54cec6e52'
...
* commit '5420099cab1e915b191cceccec4364f54cec6e52':
swscale: correctly pad destination buffer in rgb conversion
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-08-04 21:18:17 +02:00
Vittorio Giovara
f84a1b597c
swscale: support AV_PIX_FMT_YA16 as input
...
Based on a long debug session with Kostya.
2014-08-04 12:56:05 +01:00
Vittorio Giovara
e96c3b81ca
avutil: rename AV_PIX_FMT_Y400A to AV_PIX_FMT_YA8
...
The rationale is that you have a packed format in form
<greyscale sample> <alpha sample> <greyscale sample> <alpha sample>
and shortening greyscale to 'G' might make one thing about Greenscale instead.
An alias pixel format and color space name are provided for compatibility.
2014-08-04 12:55:08 +01:00
Kostya Shishkov
5420099cab
swscale: correctly pad destination buffer in rgb conversion
...
Bug-Id: 772
CC: libav-stable@libav.org
Found-By: Justin Ruggles <justin.ruggles@gmail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-08-04 12:55:07 +01:00
Michael Niedermayer
b53bdae11f
swscale/utils: fix rgb -> fullrange yuv
...
Fixes part of Ticket3785
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 23:24:26 +02:00
Michael Niedermayer
d84abf35c0
swscale/utils: remove unused define
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 22:45:43 +02:00
Michael Niedermayer
54cba3f53e
swscale/x86/hscale_fast_bilinear_simd: add inline asm guards
...
Should fix MSVC build
Found-by: jamrial
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 13:26:36 +02:00
Michael Niedermayer
d5ee3580d8
sws: move inline asm hscale to MMX_OBJS
...
Found-by: jamrial
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 05:53:42 +02:00
Michael Niedermayer
6532a1a828
sws/x86: split mmxext fast bilinear scaler out
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 05:36:27 +02:00
Michael Niedermayer
e9f7c7aef9
sws: Move fast bilinear C code into seperate file
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 05:36:26 +02:00
Michael Niedermayer
76899be113
swscale/swscale_internal: add needed version.h
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-19 05:36:26 +02:00
Michael Niedermayer
1e3f77b53a
swscale/x86/rgb2rgb_template: fix 1 byte overread in yuyvtoyuv420 and uyvytoyuv420
...
might fix ticket 3410
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-13 05:48:09 +02:00
Andreas Cadhalpun
39a6e02fd4
fix spelling errors
...
Reviewed-by: Timothy Gu <timothygu99@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-12 22:33:27 +02:00
Michael Niedermayer
4abffbbc54
swscale/x86/input: prevent RGB32_TO_Y_FN from reading into the padding
...
This avoids reading uninitialized bytes and confusing valgrind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-22 03:09:28 +02:00
Michael Niedermayer
a1a76b209b
swscale/x86/input: prevent RGB32_TO_UV_FN from reading into the padding
...
This avoids reading uninitialized bytes and confusing valgrind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-22 02:32:30 +02:00
Carl Eugen Hoyos
891307b4d1
s86/scale: Do not return the result of a (void) function from a void function.
...
Fixes compilation with Sun C 5.12.
Reported by Bradley Mitchell in ticket #3649 .
2014-06-19 18:45:13 +02:00
Michael Niedermayer
7f5296005c
swscale/swscale: replace potentially slow % by &
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-18 04:24:31 +02:00
Michael Niedermayer
293d5d7a8e
swscale/input: fix harmless integer overflow
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-16 23:28:32 +02:00
Derek Buitenhuis
a4bd4733c0
swscale: Allow the max filter size to be set at compile time
...
This can help "extreme" resizes, e.g with some 4k stuff.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2014-06-13 14:49:59 +01:00
James Almer
345f2234d1
x86/scale: fix xmm register count for hscale*_sse2
...
xmm6 was being clobbered in ff_hscale8to{15,19}_8_sse2 on Win64
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-09 04:13:23 +02:00
Michael Niedermayer
b55d3bbeed
Merge commit '880e2aa23645ed9871c66ee1cbd00f93c72d2d73'
...
* commit '880e2aa23645ed9871c66ee1cbd00f93c72d2d73':
Remove all Blackfin architecture optimizations
Conflicts:
libavcodec/bfin/dsputil.S
libavcodec/bfin/dsputil_init.c
libavcodec/bfin/fdct_bfin.S
libavcodec/bfin/hpel_pixels_no_rnd.S
libavcodec/bfin/hpeldsp_init.c
libavcodec/bfin/idct_bfin.S
libavcodec/bfin/mathops.h
libavcodec/bfin/pixels.S
libavcodec/bfin/pixels.h
libavcodec/bfin/vp3dsp.S
libavcodec/bfin/vp3dsp_init.c
libavutil/bfin/asm.h
libavutil/bfin/attributes.h
libswscale/bfin/internal_bfin.S
libswscale/bfin/swscale_bfin.c
libswscale/bfin/yuv2rgb_bfin.c
libswscale/swscale_internal.h
libswscale/version.h
If someone wants to maintain blackfin support in FFmpeg, please contact
ffmpeg-devel@ffmpeg.org
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-06-02 19:38:01 +02:00
Diego Biurrun
880e2aa236
Remove all Blackfin architecture optimizations
...
Blackfin is a painful platform to work with, no test machines are available
and the range of multimedia applications is dubious. Thus it only represents
a maintenance burden.
2014-06-02 08:41:47 -07:00
Michael Niedermayer
ce4d91ba2a
sws: document color range >8bit oddity
2014-05-21 21:29:33 +02:00
Michael Niedermayer
c3417ed7fd
swscale/utils: Add check that ensures that the hardcoded struct offsets are valid
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-14 01:32:11 +02:00
Michael Niedermayer
3d7218d932
Merge commit '449511740f06a4675b0066730fa45cdb764ffafc'
...
* commit '449511740f06a4675b0066730fa45cdb764ffafc':
build: handle library dependencies in configure
Conflicts:
common.mak
configure
libavdevice/Makefile
libavfilter/Makefile
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-13 22:40:32 +02:00
Janne Grunau
449511740f
build: handle library dependencies in configure
...
Instead of setting FFLIBS in each library Makefile configure
exports FFLIBS-$library in config.mak.
2014-05-13 20:02:01 +02:00
Matt Oliver
1898c2f49d
inline asm: fix arrays as named constraints.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-07 15:02:45 +02:00
Michael Niedermayer
656fe7ecce
swscale/utils: use FF_ALLOC(Z)_ARRAY_OR_GOTO() and av_malloc(z)_array()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-04 19:49:06 +02:00
Michael Niedermayer
1c4110be90
Merge commit '3a177a9cca924e097265b32f9282814f6b653e08'
...
* commit '3a177a9cca924e097265b32f9282814f6b653e08':
swscale: Fix an undefined behaviour
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-03 23:36:54 +02:00
Luca Barbato
3a177a9cca
swscale: Fix an undefined behaviour
...
Prevent a division by zero down the codepath.
Sample-Id: 00001721-google
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
2014-05-03 18:25:17 +02:00
Michael Niedermayer
421b21ca8a
sws: dont use the optimized 410->420 unscaled conversion when height%4
...
Fixes Ticket3594
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-30 06:23:39 +02:00
Michael Niedermayer
a5e20d9f4d
Fix teh typos
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 15:16:13 +02:00
Carl Eugen Hoyos
b38910c979
Fix compilation with !HAVE_6REGS.
...
Can be tested with:
$ ./configure --cc='cc -m32' --disable-optimizations --enable-pic
2014-04-19 09:56:01 +02:00
Michael Niedermayer
14fa7fc6a8
swscale/swscale: fix srcStride/srcSlice typo
...
Fixes part of Ticket3466
Found by: Andrey_Karpov / PVS-Studio
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-16 02:09:39 +02:00
Michael Niedermayer
4959a4fcf7
swscale/utils: fix changing src/dst range after initializing the context
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-15 00:40:39 +02:00
Michael Niedermayer
fa98885be4
swscale/utils: move handling of unscaled case to the end of init function
...
This way all context fields get initialized and can be used without needing to reinit the context
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-14 23:32:41 +02:00
Michael Niedermayer
a2f088c0f9
swscale: factor ff_sws_init_range_convert() out
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-14 23:25:28 +02:00
Michael Niedermayer
3751e5a821
swscale/swscale: clear to/from convert pointers when they used.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-14 23:15:31 +02:00
Michael Niedermayer
28875c4188
Merge commit '60c4660ba035bbfbcc84ac34129ce40e037c70ad'
...
* commit '60c4660ba035bbfbcc84ac34129ce40e037c70ad':
swscale: fix an implementation-defined unsigned-to-signed conversion
Conflicts:
libswscale/swscale_unscaled.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-13 01:26:49 +02:00
Justin Ruggles
d9a542ace1
swscale: Set alpha to opaque for internal palettes.
...
Fixes conversion of pal8 to rgb formats with alpha.
Updated references for 2 FATE tests which previously encoded fully
transparent images.
Based on a patch by Baptiste Coudurier <baptiste.coudurier@gmail.com>
2014-04-12 14:07:19 -04:00
Justin Ruggles
60c4660ba0
swscale: fix an implementation-defined unsigned-to-signed conversion
2014-04-12 13:24:47 -04:00
Justin Ruggles
20c38c9c18
swscale: fix some undefined signed left shifts
...
Based on a patch by Michael Niedermayer <michaelni@gmx.at>
2014-04-12 13:24:47 -04:00
Lukasz Marek
fbf05759e3
sws: fix warning about RGB_PACK24_B_OPERANDS redefinition
...
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-10 02:07:07 +02:00
Michael Niedermayer
d98688efb1
swscale/input: replace assert() by av_assert1()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-09 05:14:34 +02:00
Michael Niedermayer
ed962414bd
Merge commit '92b099daf4b8ef93513e38b43899cb8458a2fde3'
...
* commit '92b099daf4b8ef93513e38b43899cb8458a2fde3':
swscale: support converting YVYU422 pixel format
Conflicts:
libswscale/input.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-09 03:36:38 +02:00
Michael Niedermayer
1752b1459d
swscale/utils: scale filter_size in warning so that it can be used as max for the compile time define
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-09 00:57:12 +02:00
Michael Niedermayer
7b2b06eb43
swscale/utils: dont print message about filter size when the cause is a malloc failure
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-09 00:57:12 +02:00
Michael Niedermayer
2fcef4a044
swscale/swscale_internal: remove obsolete warning
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-08 19:09:05 +02:00
Michael Niedermayer
955d7e26b6
swscale/swscale_internal: make the offset strings update themselfs when the MAX_FILTER_SIZE is changed
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-08 18:51:34 +02:00
Michael Niedermayer
f6759d9ad4
swscale/x86/swscale_template: loose hardcoded dstw_offset
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-08 18:39:39 +02:00
Vittorio Giovara
92b099daf4
swscale: support converting YVYU422 pixel format
2014-04-07 23:50:34 +02:00
Michael Niedermayer
37f69cd93e
swscale: add full bgra64 support
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-02 19:44:08 +02:00
Michael Niedermayer
3428a9b8d5
Merge commit '0ca0924c10d9617a5793964bf79655424ef32b68'
...
* commit '0ca0924c10d9617a5793964bf79655424ef32b68':
swscale: add endianness conversion for AV_PIX_FMT_BGRA64|RGBA64
Conflicts:
libswscale/swscale_unscaled.c
libswscale/utils.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-02 17:46:19 +02:00
Janne Grunau
0ca0924c10
swscale: add endianness conversion for AV_PIX_FMT_BGRA64|RGBA64
2014-04-02 11:39:26 +02:00
Michael Niedermayer
0371eaebcd
Merge commit 'aba70bb5387f12dfa5e6cd8cb861c9c7e668151f'
...
* commit 'aba70bb5387f12dfa5e6cd8cb861c9c7e668151f':
Add missing headers to make template files compile (more) standalone
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-26 14:50:55 +01:00
Diego Biurrun
aba70bb538
Add missing headers to make template files compile (more) standalone
2014-03-26 04:31:27 -07:00
Carl Eugen Hoyos
e6fe804bdd
Do not set swscale sizeFactor to -1.
...
Fixes ticket #3495 .
2014-03-25 15:46:35 +01:00
Øyvind Kolås
3e6016622e
swscale: add two spatially stable dithering methods
...
Both of these dithering methods are from http://pippin.gimp.org/a_dither/ for
GIF they can be considered better than bayer (provides more gray-levels), and
spatial stability - often more than twice as good compression and less visual
flicker than error diffusion methods (the methods also avoids error-shadow
artifacts of diffusion dithers).
These methods are similar to blue/green noise type dither masks; but are
simple enough to generate their mask on the fly. They are still research work
in progress; though more expensive to generate masks (which can be used in a
LUT) like 'void and cluster' and similar methods will yield superior results
2014-03-25 13:48:06 +01:00
Michael Niedermayer
c9c0451224
swscale/swscale: fix integer overflow
...
Should fix fate failure with clang ftrapv
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-24 05:01:32 +01:00
Carl Eugen Hoyos
074db4b764
Add APIchanges entry and bump libswscale micro version for making gray16 full-scale.
2014-03-19 09:11:22 +01:00
Matt Oliver
8236747511
Automatically change MANGLE() into named inline asm operands when direct symbol reference in inline asm are not supported.
...
This is part of the patch-set for intel C inline asm on windows support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-18 23:39:30 +01:00