Commit Graph

99 Commits

Author SHA1 Message Date
stefang d7c0bde0e1 move zeroing of alpha channel register out of YSCALEYUV2xxx macros,
patch by Cédric Schieli (cschieli at gmail youknowwhat)


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28687 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-21 10:54:29 +00:00
stefang 3d263a0ae5 splits various YSCALEYUV2xxx macros into YSCALEYUV2xxx_UV,
YSCALEYUV2xxx_YA and YSCALEYUV2xxx_COEFF,
patch by Cédric Schieli (cschieli at gmail youknowwhat)


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28686 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-21 10:52:59 +00:00
stefang 52e18fdc4f make MMX registers parametrized in the WRITEBGR32 macro,
patch by Cédric Schieli (cschieli at gmail youknowwhat)


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28685 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-21 10:49:52 +00:00
kostya 919b7aef26 Some AltiVec functions in SwScaler produce different output than their
counterparts in pure C, so don't invoke them in bitexact mode.



git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28555 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-14 16:37:39 +00:00
diego cecfbf85db HAVE_3DNOW --> HAVE_AMD3DNOW to sync with latest configure changes.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28358 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-01-25 19:58:33 +00:00
aurel be34ba7a39 Change semantic of CONFIG_*, HAVE_* and ARCH_*.
They are now always defined to either 0 or 1.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28311 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-01-14 00:13:56 +00:00
diego f76cb1f891 Put variable declaration inside an #ifdef to avoid an unused variable warning.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27945 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-17 10:33:59 +00:00
cehoyos d6ed4677ca Remove unused code that can't be compiled without svn archive.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27827 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-25 20:41:51 +00:00
diego e9b43bec09 cosmetics: typo fix
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27816 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-23 16:23:42 +00:00
flameeyes 3679961515 Convert asm keyword into __asm__.
Neither the asm() nor the __asm__() keyword is part of the C99
standard, but while GCC accepts the former in C89 syntax, it is not
accepted in C99 unless GNU extensions are turned on (with -fasm). The
latter form is accepted in any syntax as an extension (without
requiring further command-line options).

Sun Studio C99 compiler also does not accept asm() while accepting
__asm__(), albeit reporting warnings that it's not valid C99 syntax.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27778 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-16 13:34:30 +00:00
flameeyes 3ab65de119 Invert logic for the single-pass in swScale() functions.
Instead of having a firstTime variable defaulting to 1, have a
warnedAlready defaulting to 0. While this should make no difference in
code speed at runtime, it allows to aggregate the four bytes of that
variable with clip_table in .bss section, rather than issuing a .data
section just for that.

As it is, libswscale require no .data section but .data.rel.ro (that
can be mitigated by prelinking), so the change might actually save one
page of memory at runtime (per process).



git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27734 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-09 11:10:30 +00:00
vitor 74bb6be453 Do not set src[1] to the palette, it is now in the context
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27731 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-08 17:48:23 +00:00
cehoyos 99877b2fc6 Remove b5Dither, g5Dither and r5Dither from libswscale.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27718 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-04 18:50:39 +00:00
cehoyos 15d516ffdf Remove g6Dither from libswscale.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27715 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-10-04 16:40:35 +00:00
lu_zero cec6a449ef Uniform *ToY and *ToUV function signatures
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27636 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-18 00:26:37 +00:00
lu_zero 3a3d1283b6 Split mono2Y in monowhite and monoblack
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27635 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-18 00:24:32 +00:00
lu_zero b1f6b96548 Factorize unit32_t* casts for palette pointer
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27634 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-18 00:22:53 +00:00
ben 62146f22be Fix libswscale build after r27561 if --enable-runtime-cpudetection is used.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27602 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-13 16:13:04 +00:00
michael b726d73ed1 Fix indention.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27600 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-13 13:41:47 +00:00
michael 79c5484c9f Disable mmx routines that are not bitexact when the user wants
bitexact ones.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27597 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-13 03:12:15 +00:00
michael 6869e4a7a4 Make horizontal mmx scaling code match C code.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27596 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-13 02:18:12 +00:00
michael 68de5a33c9 Make the horizontal C scaler code clip only against INT16_MAX not 0,
this decreases the difference between C and MMX, its also faster.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27593 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-12 22:29:21 +00:00
michael df44f03e48 Fix another 1000l bug in the mono input code.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27590 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-12 18:05:57 +00:00
michael d28a3ad668 10000l PIX_FMT_MONOWHITE check was really a || 1.
Thats what happens when one does not do the full set of tests before each commit
and just quickly goes over the diff thinking, "hey it is a trivial change".


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27588 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-12 17:28:36 +00:00
michael 296ccc70ea Support mono as input format.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27587 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-12 16:46:38 +00:00
michael fc855e63d2 Add support for PIX_FMT_MONOWHITE as output format.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27586 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-12 16:01:17 +00:00
michael 6d7e720009 Fix typo that lead to averaging of the same pixel in rgb24ToUV_half().
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27582 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-11 14:47:18 +00:00
michael 6009a04a23 Implement full horizontal chroma for rgb/bgr24/32 output.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27580 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-11 14:39:12 +00:00
michael 9c49671d8b Factorize yuv2packedXinC().
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27578 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-11 02:36:51 +00:00
michael 53a3e8ee69 Make the 2point linear interpolation coefficients correct even for the
nearly never occurring 0.0, 1.0.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27574 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 22:41:55 +00:00
michael 60a3099c0d Fix overflow.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27573 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 20:47:16 +00:00
michael b42b0e0c92 Fix build failure due to %%eip on x86_64.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27569 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 17:50:49 +00:00
michael a92e68d5a8 Change RGB2YUV_SHIFT from 16 to 15 to make it able to work
with 16bit signed constants (like SIMD might use).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27568 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 16:39:56 +00:00
michael 9af0a56c05 Add bgr/rgb15/16/32->UV-half to the macro so there is less code duplication
at the source level.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27567 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 13:55:51 +00:00
michael bd999ce6c7 Factorize RGB/BGR15/16/32->UV by using the preprocessor.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27566 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 03:56:06 +00:00
michael d49d2d9a86 Factorize rgb/bgr15/16/32->Y by using the preprocessor.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27565 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 03:42:45 +00:00
michael 50e3ffeacb Make SWS_FULL_CHR_H_INP work.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27564 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-10 02:28:38 +00:00
michael 0c6d92bfda Rewrite bgr24->yuv mmx code, the new code is cleaner, more accurate,
and does not throw half the chroma away.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27561 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-09 23:30:06 +00:00
michael 877f8300fb More correct rounding for the rgb/bgr->yuv converters.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27557 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-09 16:55:58 +00:00
michael ca1afd1bb8 Prevent overflows during mpeg->jpeg yuv.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27552 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-09 03:35:07 +00:00
michael b128f3e558 Fix jpeg yuv.
Fixes issue504.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27547 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-08 12:36:38 +00:00
michael 7dd7068c7a Fix accurate rounding mode on x86_64.
Fixes issue222.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27545 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-07 21:06:21 +00:00
lu_zero 6078a4b0e6 Make ToY and ToUV family of function consistent part I
Convert width argument from int to long (note: srcW is still an int).


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27544 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-07 18:22:29 +00:00
michael a0d85f9301 Make 16bit grayscale output work.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27524 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-04 22:58:16 +00:00
michael 172a4bfaea Support PIX_FMT_RGB32_1 and PIX_FMT_BGR32_1.
Fixes issue248.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27522 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-04 21:59:15 +00:00
michael b8d98f8959 Fix rgb15/16 vs. bgr part2.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27517 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-09-04 18:24:25 +00:00
michael 17b0917069 Make C code in yuv2yuv1() do accurate rounding, this could be split
depending on SWS_ACCURATE as well if someone wants.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27323 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-07-18 00:09:09 +00:00
michael 3076d107cf indent
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27322 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-07-17 23:43:48 +00:00
michael 8db6dab345 Forgotten accurate rounding function YSCALEYUV2YV121_ACCURATE.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27321 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-07-17 23:42:06 +00:00
michael e96aa16d0c simplify yuv2yuv1()
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27320 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-07-17 23:35:36 +00:00