Ronald S. Bultje
1d8c4af396
swscale: take first/lastline over/underflows into account for MMX.
...
Fixes crashes for extremely large resizes (several 100-fold).
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
13 years ago
Ronald S. Bultje
b18f8cbf3d
Revert two swscale commits.
...
Revert "swscale: update context offsets after removal of AlpMmxFilter."
(commit a95e3fa90b
)
and
Revert "swscale: Remove some write-only variables related to alpha handling."
(commit 9d03cb9fc5
).
They broke alpha handling - it's the evil inline asm that still uses that
variable, so it's not truely write-only.
13 years ago
Ronald S. Bultje
1bab6f852c
swscale: make access to filter data conditional on filter type.
...
Prevents crashes on 1-tap filter (unscaled). Also rename "bguf" argument
to "vbuf", seems that was a typo.
13 years ago
Ronald S. Bultje
a95e3fa90b
swscale: update context offsets after removal of AlpMmxFilter.
13 years ago
Michael Niedermayer
e7dbfa59f2
swscale: enable some more SIMD functions.
...
They no longer just segfault.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Carl Eugen Hoyos
186923758d
Fix compilation with old yasm that does not support AVX.
13 years ago
Diego Biurrun
9d03cb9fc5
swscale: Remove some write-only variables related to alpha handling.
13 years ago
Ronald S. Bultje
771bab7f57
swscale: fix crashes in yuv2yuvX on x86-32.
...
They were introduced in an earlier commit that introduced use of named
arguments. One cause was a typo, a second cause appears to be a bug in
x264asm that I work around by not using named arguments.
13 years ago
Ronald S. Bultje
3e23badd83
swscale: convert yuv2yuvX() to using named arguments.
13 years ago
Ronald S. Bultje
8c433d8a03
swscale: rename "dstw" to "w" to prevent name collisions.
...
"dstw" can collide with the word-version of the "dst" argument, causing
all kind of weird stuff down the pipe.
13 years ago
Ronald S. Bultje
ef66a0ed2e
swscale: use named registers in yuv2yuv1_plane() place.
...
Most of the function had been converted before, but I forgot this
particular location.
13 years ago
Ronald S. Bultje
783487ae44
swscale: sign-extend integer function argument to qword on x86-64.
13 years ago
Ronald S. Bultje
ef1c785f11
swscale: make yuv2yuv1 use named registers.
13 years ago
Ronald S. Bultje
b7542dd3d7
swscale: fix V plane memory location in bilinear/unscaled RGB/YUYV case.
...
Fixes bug 221.
CC: libav-stable@libav.org
13 years ago
Ronald S. Bultje
7e4d9d5d45
win64: add a XMM clobber test configure option.
...
This will be useful to test more aggressively for failures to mark XMM
registers as clobbered in Win64 builds, and prevent regressions thereof.
Based on a patch by Ramiro Polla <ramiro.polla@gmail.com>
13 years ago
Ronald S. Bultje
de53b9068a
swscale: implement MMX, SSE2 and AVX functions for RGB32 input.
13 years ago
Ronald S. Bultje
378c5ef9ae
swscale: enable dithering in MMX functions.
...
This was accidently disabled.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
13 years ago
Ronald S. Bultje
212f161caa
swscale: make rgb24 function macros slightly smaller.
13 years ago
Ronald S. Bultje
b5d08c27c3
swscale: convert rgb/bgr24ToY/UV_mmx functions from inline asm to yasm.
...
Also implement sse2/ssse3/avx versions.
13 years ago
Ronald S. Bultje
3b15a6d742
config.asm: change %ifdef directives to %if directives.
...
This allows combining multiple conditionals in a single statement.
13 years ago
Michael Niedermayer
5a840f6364
x86/yuv2rgb_mmx: Remove yuv420 check.
...
This check is not correct, the code supports more yuv variants.
Fixes Ticket904
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
3c172a4106
swscale: change yuv2yuvX code to use cpuflag().
13 years ago
Carl Eugen Hoyos
ef3a19d595
Fix compilation with yasm-0.6.2
13 years ago
Michael Niedermayer
05577aafaa
sws: yuv2rgb asm, add memory clobber.
...
This fixes dithering for rgb555le, it appears gcc had moved the
setup of the variables after the asm or something like that.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
b14fa5572c
swscale: fix crash in fast_bilinear code when compiled with -mred-zone.
...
Additional comments from Måns Rullgard have been integrated
by Reinhard Tartler.
Signed-off-by: Reinhard Tartler <siretart@tauware.de>
13 years ago
Oka Motofumi
cd44521625
swscale: specify register type.
...
Fixes a compilation failure on win64.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
13 years ago
Ronald S. Bultje
2170a0e6ad
swscale: convert yuy2/uyvy/nv12/nv21ToY/UV from inline asm to yasm.
...
Also implement SSE2/AVX variants.
13 years ago
Ronald S. Bultje
6ea64339c5
swscale: split scale.asm.
...
scale.asm keeps horizontal scaling functions, whereas output.asm gets
the vertical scaling/output functions.
13 years ago
Diego Biurrun
3c62a71486
swscale_mmx: drop no longer required parameters from VSCALEX macros
13 years ago
Diego Biurrun
52de07e1f1
swscale: Mark yuv2planeX_8_mmx as MMX2; it contains MMX2 instructions.
13 years ago
Mans Rullgard
373211d828
Remove extraneous semicolons
...
These semicolons cause invalid empty top-level declarations.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Michael Niedermayer
3fd4fe0e03
swscale_mmx: Fix cast qualifier warnings:
...
libswscale/x86/swscale_mmx.c:131:36: warning: to be safe all intermediate pointers in cast from ‘int16_t **’ to ‘const int16_t **’ must be ‘const’ qualified [-Wcast-qual]
libswscale/x86/swscale_mmx.c:132:37: warning: to be safe all intermediate pointers in cast from ‘int16_t **’ to ‘const int16_t **’ must be ‘const’ qualified [-Wcast-qual]
libswscale/x86/swscale_mmx.c:133:74: warning: to be safe all intermediate pointers in cast from ‘int16_t **’ to ‘const int16_t **’ must be ‘const’ qualified [-Wcast-qual]
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
a24c4758d5
sws: remove unused variable
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
0a3a125fd9
sws: update copyright dates
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
8283f90a52
swscale: handle unaligned buffers in yuv2plane1
...
The issue had been introduced in
c435653627
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
13 years ago
Michael Niedermayer
7437db84a9
sws: Fix compilation with disabled MMX2
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Themaister
0827222b9c
Use more accurate conversion for rgb15/16 to rgb24/32 (C/MMX).
...
Fate update by michael.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
c435653627
swscale: write yuv2plane1 MMX/SSE2/SSE4/AVX functions.
13 years ago
Michael Niedermayer
e484b64ce3
sws: fallback to mmx2 when yuv2yuvX_sse3() cannot be used.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
b616600516
sws: replace long by x86_reg in x86 asm
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
9eb867e117
sws: add yuv2yuvX_sse3()
...
Code is about 2x as fast as previous
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
8b4b2ddf8d
sws: x86_32 fix
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
76a3490672
sws: add yuv2yuvX() back and updated to the just 1 plane API
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
4d31f42020
sws: port to thw new 1 plane API and add back yuv2yuv1_ar().
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
f15359727d
sws: better MOVNTQ macro
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
9e66b892e8
swscale: add missing colons to x86 assembly yuv2planeX.
...
This fixes assembling using "nasm".
13 years ago
Michael Niedermayer
1ac5b51203
swscale: disable functions that do not yet work
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
6cacecdca3
swscale: make yuv2yuvX_10_sse2/avx 8/9/16-bits aware.
...
Also implement MMX/MMX2 versions and SSE4 versions.
13 years ago
Kieran Kunhya
7fbbf95293
yuv2planeX10 SIMD
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
13 years ago
Kieran Kunhya
34e8d147b3
Split out yuv2yuv1 luma and chroma in order to make them generic DSP functions
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
13 years ago