Statistics
| Branch: | Revision:

ffmpeg / libswscale / swscale.c @ 9c5a9e6b

History | View | Annotate | Download (126 KB)

# Date Author Comment
bd381fd3 11/18/2009 05:16 PM Diego Biurrun

Add functions to return library license and library configuration.

Originally committed as revision 29932 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

8cbcb1c7 11/10/2009 07:11 PM NVIDIA Corporation

Support VDPAU hardware accelerated decoding of MPEG-4 ASP on capable
hardware.

Original patch by NVIDIA corporation.

Originally committed as revision 29885 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

749fac31 09/13/2009 01:49 AM Ramiro Polla

Reset slice direction at end of each frame.

Originally committed as revision 29675 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

9cf484d0 09/06/2009 12:07 AM Ramiro Polla

Rename CHECKED_ALLOC(Z) to FF_ALLOC(Z)_OR_GOTO and add context and label
parameters.

Originally committed as revision 29652 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

c2613a31 09/05/2009 11:35 PM Ramiro Polla

Indent.

Originally committed as revision 29651 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

991e579c 09/05/2009 11:33 PM Lars Täuber

Make 16bit YUV formats compatible with NE avcodec_get_pix_fmt().
Patch by Lars Täuber <lars <dot> taeuber <at> gmx <dot> net>.

Originally committed as revision 29650 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

67c2c5bb 08/29/2009 11:08 PM Ramiro Polla

Curly brackets cosmetics for previous commit.

Originally committed as revision 29587 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

1ddb5747 08/29/2009 11:06 PM Ramiro Polla

Check for return value of initFilter().

Originally committed as revision 29586 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

7248797c 08/29/2009 11:02 PM Ramiro Polla

swscale: Check for return values of malloc.

Originally committed as revision 29584 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0607b090 08/29/2009 02:44 AM Ramiro Polla

Restore comment that was partially removed.

Originally committed as revision 29582 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

1b03a9d6 08/20/2009 01:55 AM Ramiro Polla

Check return values of sws_allocVec() and sws_getConstVec().

Originally committed as revision 29543 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

1aff375d 08/19/2009 01:33 AM Ramiro Polla

Introduce and use sws_allocVec().

Originally committed as revision 29536 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

20484b90 08/19/2009 01:32 AM Ramiro Polla

Reuse sws_getConstVec() where possible.

Originally committed as revision 29535 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

dd68318c 08/16/2009 09:11 PM Ramiro Polla

Cosmetics:
- Place curly brackets in the same line as while/for/if/switch/else/do;
- Place curly brackets at column 0 in the next line starting a function.

Originally committed as revision 29523 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

9b734d44 08/16/2009 12:32 AM Ramiro Polla

Indent libswscale:
- Use 4 spaces throughout for indentation;
- Fix inconsistent indentation;
- Indent function calls and declarations aligning arguments on multiple lines
to the column after the opening parentheses;
- Align asm code to the column 4 spaces after the call to asm();...

52154148 08/14/2009 03:52 PM Ramiro Polla

Vertical yuv -> yuv16 scaler.

Originally committed as revision 29517 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

737cbcde 08/13/2009 07:03 PM Ramiro Polla

Indent.

Originally committed as revision 29512 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

48f4c612 08/13/2009 06:31 PM Ramiro Polla

MMX2 horizontal scaler: Determine code size at runtime.

Originally committed as revision 29510 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

07287788 08/13/2009 06:29 PM Ramiro Polla

Protect mmx2 filter code buffers so they are not executable and writeable at
the same time (only mmap for now).

Originally committed as revision 29509 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

bcdedf67 08/13/2009 06:28 PM Ramiro Polla

Rename "funny" code to "mmx2 filter" code.

Originally committed as revision 29507 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

184410e6 08/09/2009 03:34 PM Ramiro Polla

Put some altivec code under COMPILE_ALTIVEC, and not HAVE_ALTIVEC.

Originally committed as revision 29484 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0bf18ed3 08/08/2009 03:18 PM Diego Biurrun

Remove disabled crufty code.

Originally committed as revision 29482 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

062394e0 08/01/2009 09:30 PM Guennadi Liakhovetski

Fix regression when converting to nv12/nv21.

Patch by Guennadi Liakhovetski, g D liakhovetski A gmx D de

Originally committed as revision 29464 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

469fd9b0 07/28/2009 05:45 AM Ramiro Polla

MMX2 scaler: Remove {} block leftover from factorization in initMMX2Scaler().
Merge variable declarations to previous {} block and indent.

Originally committed as revision 29454 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

f1c6dfa3 07/28/2009 05:42 AM Ramiro Polla

MMX2 scaler: factorize initMMX2Scaler().

Originally committed as revision 29453 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

901775c7 07/28/2009 05:41 AM Ramiro Polla

MMX2 scaler: add variable to ease factorization of initMMX2Scaler().

Originally committed as revision 29452 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

571d9587 07/28/2009 04:46 AM Ramiro Polla

Remove useless code.
flags can never be any other kind of scaling algorithm inside this if().

Originally committed as revision 29449 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

94daf2e9 07/27/2009 06:47 AM Ramiro Polla

Do not misuse HAVE_ defines. Introduce COMPILE_TEMPLATE_ defines and use them
instead.

Originally committed as revision 29446 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

a898cdc9 07/26/2009 12:26 PM Måns Rullgård

Replace WORDS_BIGENDIAN with HAVE_BIGENDIAN

Originally committed as revision 29439 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

78d01ada 07/23/2009 03:23 PM Måns Rullgård

Remove unnecessary #include <unistd.h>

Originally committed as revision 29437 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

804db446 07/21/2009 08:17 PM Ramiro Polla

Remove unused variables.

Originally committed as revision 29435 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

8b1a6441 06/25/2009 08:06 PM Diego Biurrun

AltiVec code and runtime cpudetect do not require CONFIG_GPL.
Make sure the latter is only checked for x86 optimizations, which are GPL.

Originally committed as revision 29390 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

57f6d52a 06/25/2009 11:27 AM Diego Biurrun

The AltiVec optimizations of libswscale are no longer under GPL.

Originally committed as revision 29389 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

e912c13a 06/25/2009 10:14 AM Diego Biurrun

PPC: Make sure that COMPILE_C is not deactivated if RUNTIME_CPUDETECT is set.

Originally committed as revision 29388 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

fa8c408b 06/17/2009 06:40 PM Vitor Sessak

Do not call rgb2rgbWrapper() for rgb48*, there is no special converter
yet for those formats

Originally committed as revision 29371 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

92db6235 06/04/2009 09:55 PM Pavel Pavlov

Use DECLARE_ALIGNED macro instead of gcc attribute.
Patch by Pavel Pavlov <pavel at summit-tech dot ca>

Originally committed as revision 29348 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

68e7f482 06/02/2009 12:30 PM Kostya Shishkov

YUV into RGB48 BE/LE conversion support

Originally committed as revision 29342 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

e8417235 06/02/2009 12:28 PM Kostya Shishkov

Partial (low bits ignored, no direct transcoding into other RGB formats) support
for inputting RGB48BE/LE.

Originally committed as revision 29341 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

80704c47 05/25/2009 04:42 PM Kostya Shishkov

Move colorspace conversion functions implemented in pure C from template
into swscale.c

Originally committed as revision 29320 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

075ec82c 05/19/2009 05:26 PM Kostya Shishkov

Make SwScaler recognize RGB48 BE/LE colourspaces (not support though).

Originally committed as revision 29316 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0020c54c 05/10/2009 02:00 PM Diego Biurrun

Add const qualifier to param argument of sws_getContext() and
sws_getCachedContext(). Fixes the warning:
swscale.c:3408: warning: assignment discards qualifiers from pointer target type

Originally committed as revision 29288 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

465477e1 05/10/2009 11:37 AM Diego Biurrun

Move preprocessor condition before variable declaration, fixes the warning:
libswscale/swscale.c:1795: warning: unused variable 'flags'

Originally committed as revision 29287 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

5f9ae198 05/07/2009 08:41 PM Vitor Sessak

Fix sliced yuv410 -> yuv420 conversion

Originally committed as revision 29272 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

8e86dd12 04/23/2009 10:19 PM Carl Eugen Hoyos

Make reset_ptr() void.

Originally committed as revision 29229 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

de1275d5 04/21/2009 01:08 AM Michael Niedermayer

Planar 16bit 420 422 444 YUV support (output is only supported in some
unscaled convertions).
This, like gray16 converts down to 8bit, which is a big FIXME & patch welcome,
we should preserve more bits.

Originally committed as revision 29217 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

61a3f379 04/21/2009 12:08 AM Michael Niedermayer

Merge gray->gray converters into planarCopy(), this should also make planarCopy()
useable for other 16bit formats once we support them.

Originally committed as revision 29216 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

b87fae9f 04/21/2009 12:01 AM Michael Niedermayer

Make sure src/dst are NULL when they arent used, some code uses this to
simpify checks.

Originally committed as revision 29214 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

081aa41d 04/20/2009 09:05 PM Michael Niedermayer

Use generic BE check instead of checking for gray16LE.

Originally committed as revision 29213 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0c067dc3 04/18/2009 11:53 AM Stefano Sabatini

Make sws_setColorspaceDetails() return -1 if the destination format is
not supported.

Originally committed as revision 29187 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

2d26fa28 04/18/2009 11:45 AM Stefano Sabatini

Move sws_[gs]etColorspaceDetails() documentation from swscale.c to
swscale.h.

Originally committed as revision 29186 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

10a7d216 04/08/2009 08:21 PM Ramiro Polla

Rename RUNTIME_CPUDETECT to CONFIG_RUNTIME_CPUDETECT and always define it.

Originally committed as revision 29154 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

dd409025 04/05/2009 07:17 PM Ramiro Polla

swscale: Remove X86 commented out code.

Originally committed as revision 29149 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

40fa5140 04/04/2009 10:45 PM Ramiro Polla

swscale: Use function pointers for swScale functions.

Originally committed as revision 29145 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

14d5c18c 04/04/2009 10:43 PM Ramiro Polla

swscale: {}-related cosmetics.

Originally committed as revision 29144 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

7ac40327 04/04/2009 10:41 PM Ramiro Polla

swscale: Add const to some swScale functions' parameters.

Originally committed as revision 29143 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

4626ee1a 03/24/2009 07:11 AM Cédric Schieli

Adds "YUYV422 to YUVA420P" and "UYVY422 to YUVA420P" unscaled convertion

Originally committed as revision 29048 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

08218e6d 03/24/2009 07:10 AM Cédric Schieli

Fix some places where "non-alpha to YUVA420P" do not fill the alpha plane

Originally committed as revision 29047 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

ff8084cf 03/21/2009 11:59 PM Michael Niedermayer

Enable unscaled packed422 -> planar 420 converters by default as the
imgconvert inherited quality issues should be fixed.

Originally committed as revision 29031 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

6f348086 03/21/2009 10:20 AM Reimar Döffinger

Fix planarCopy to ignore the GRAY8 "pseudo"-palette, fixes libavtest regression test.

Originally committed as revision 29021 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

20ddf5a8 03/20/2009 05:22 PM Reimar Döffinger

Avoid crash on planarCopy to a destination without alpha.
Makes regression tests run again, though the results are still wrong.

Originally committed as revision 29018 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

6268f55b 03/20/2009 02:16 PM Cédric Schieli

YUVA420P is now supported as output format

Originally committed as revision 29012 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

6858492e 03/20/2009 02:15 PM Cédric Schieli

Add alpha channel scaling

Originally committed as revision 29011 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

f6cf4ed0 03/20/2009 02:01 PM Cédric Schieli

Use a simpler and more general check for the gray case in the planarCopy function

Originally committed as revision 29009 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

dd35beb2 03/19/2009 09:52 PM Ramiro Polla

Allocate executable memory with VirtualAlloc() in Windows.

Originally committed as revision 29006 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

16a3717f 03/19/2009 09:50 PM Ramiro Polla

Drop unnecessary cast and cosmetically align.

Originally committed as revision 29005 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

72ef3dd7 03/19/2009 02:04 PM Michael Niedermayer

Fix 10l typo.

Originally committed as revision 29002 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0411072e 03/19/2009 03:45 AM Michael Niedermayer

Unscaled converters for
YUYV->YUV420P
YUYV->YUV422P
UYVY->YUV420P
UYVY->YUV422P

Originally committed as revision 28997 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

d0ce212a 03/18/2009 05:07 PM Ramiro Polla

Do not assume long is same width as x86 register.

Originally committed as revision 28992 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

780daf2b 03/18/2009 08:06 AM Diego Biurrun

Consistently use ff_ prefixes for internal symbols.

Originally committed as revision 28988 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

d4da3e47 03/17/2009 07:53 PM Cédric Schieli

Add a fillPlane function to fill a plane with one constant value

Originally committed as revision 28986 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

4c01b868 03/17/2009 07:51 PM Cédric Schieli

Don't write outside of the picture buffer in planarCopy in the gray case

Originally committed as revision 28985 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

c662e788 03/11/2009 02:22 PM Cédric Schieli

In initMMX2HScaler, when chrDstW is not divisible by 4, the last filterPos element is initialized on the wrong index (not evenly aligned). This fixes it

Originally committed as revision 28933 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

6208d676 03/07/2009 09:39 AM Cédric Schieli

Let the 4th plane reach the swScale function

Originally committed as revision 28868 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

a3398feb 03/05/2009 09:02 PM Cédric Schieli

Fix bug introduced by me in r28756

Originally committed as revision 28825 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

f8a138be 02/28/2009 08:01 AM Cédric Schieli

When converting from a non alpha format to an alpha format, defaults

Originally committed as revision 28756 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

2c897342 02/27/2009 10:13 PM Cédric Schieli

Use YUV420P code path for YUVA420P where appropriate

Originally committed as revision 28746 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

e76709d8 02/22/2009 09:22 AM Kostya Shishkov

New LGPLed YUV2RGB table generator for SwScaler

Originally committed as revision 28700 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

e14ff1e6 02/14/2009 08:18 PM Stefano Sabatini

Use sws_printVec2() instead of the deprecated sws_printVec().

Originally committed as revision 28567 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

26b40a65 02/14/2009 08:14 PM Stefano Sabatini

Implement sws_printVec2() and deprecate sws_printVec().

Originally committed as revision 28566 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

12794f73 02/14/2009 04:37 PM Kostya Shishkov

Some AltiVec functions in SwScaler produce different output than their
counterparts in pure C, so don't invoke them in bitexact mode.

Originally committed as revision 28555 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

6d3cf67c 02/10/2009 11:45 PM Stefano Sabatini

Move sws_getGaussianVec() documentation from swscale.c to swscale.h.

Originally committed as revision 28528 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

b954b34a 02/10/2009 11:26 PM Stefano Sabatini

Move documentation of sws_getCachedContext() from swscale.c to
swscale.h.

Originally committed as revision 28523 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

9ea5e6f6 02/10/2009 11:25 PM Stefano Sabatini

Remove pointless comment regarding sws_scale_ordered().

Originally committed as revision 28522 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

e2a004ad 02/09/2009 02:31 PM Kostya Shishkov

Prefix visible YUV2RGB functions with sws_

Originally committed as revision 28496 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

fa58ba15 02/09/2009 02:17 PM Kostya Shishkov

Give better name to Inverse_Table_6_9

Originally committed as revision 28495 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

c099766f 02/08/2009 11:06 PM Stefano Sabatini

Drop the deprecated sws_scale_ordered() at the next major version
bump.

Originally committed as revision 28492 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

f4406ec1 01/25/2009 07:58 PM Diego Biurrun

HAVE_3DNOW --> HAVE_AMD3DNOW to sync with latest configure changes.

Originally committed as revision 28358 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

dfe44a85 01/25/2009 11:59 AM Diego Biurrun

Disable C code when compiling AltiVec code, fixes the warning:
swscale_template.c:2623: warning: `swScale_C' defined but not used

Originally committed as revision 28352 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

f40c7dbb 01/25/2009 11:57 AM Diego Biurrun

spelling/grammar cosmetics

Originally committed as revision 28351 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

7a24ec50 01/25/2009 11:33 AM Diego Biurrun

Fix #endif comments.

Originally committed as revision 28350 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

0ab80395 01/20/2009 09:31 AM Carl Eugen Hoyos

Add PIX_FMT_VDPAU_WMV3 and PIX_FMT_VDPAU_VC1.

Originally committed as revision 28344 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

4e2b4876 01/16/2009 02:14 AM NVIDIA Corporation

Add VDPAU hardware accelerated decoding for MPEG1 and MPEG2 which will
be used by MPlayer.

Original patch by NVIDIA corporation.

Originally committed as revision 28322 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

b63f641e 01/14/2009 12:13 AM Aurelien Jacobs

Change semantic of CONFIG_*, HAVE_* and ARCH_*.
They are now always defined to either 0 or 1.

Originally committed as revision 28311 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

420169e5 01/08/2009 07:54 PM Carl Eugen Hoyos

Add PIX_FMT_VDPAU_H264.

Originally committed as revision 28281 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

cb82a073 12/27/2008 11:33 AM Diego Biurrun

consistency cosmetics: Rename POWERPC identifiers to PPC.

Originally committed as revision 28194 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

75add6fb 10/27/2008 07:59 PM Vitor Sessak

Silence GCC warnings:

ibswscale/swscale.c: In function ‘sws_scale’:
libswscale/swscale.c:2678: warning: ‘b’ may be used uninitialized in
this function
libswscale/swscale.c:2678: warning: ‘g’ may be used uninitialized in
this function
libswscale/swscale.c:2678: warning: ‘r’ may be used uninitialized in...

65f65c30 10/26/2008 03:41 PM Vitor Sessak

Silence GCC warning

Originally committed as revision 27834 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

9b0d44ef 10/25/2008 03:00 PM Michael Niedermayer

Do not attempt to use the unscaled yuv2rgb converter when height is odd because
it will overflow the buffer by 1 line. This might have been exploitable.

Originally committed as revision 27826 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

76e9fd01 10/23/2008 07:20 PM Vitor Sessak

Cosmetics: alignment

Originally committed as revision 27818 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

522ce957 10/23/2008 07:13 PM Vitor Sessak

Fix broken palette8to*.

Originally committed as revision 27817 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale