[MPlayer-dev-eng] Re: [PATCH] Saturation & PSWAPD bugfix in mp3lib/dct64_3dnow.c & mp3lib/dct64_k7.c

Zuxy Meng zuxy.meng at gmail.com
Wed Jun 21 15:22:24 CEST 2006


2006/6/21, Zuxy Meng <zuxy.meng at gmail.com>:
> Hello,
>
> 3DNow! version of DCT64 in mp3lib use PF2ID to convert float to int,
> then MOVW to convert int to short, which produces bad result when
> overflow occurs. If you listen carefully you'll notice the difference
> in the played sound.
>
> This patch replace all PF2ID with PF2IW.
>
> Original behavior under 3DNow! (erroneous):
> 1. Floating point DCT
> 2. Saturate to 32-bit int (PF2ID)
> 3. Truncate to 16-bit short (MOVW)
>
> Now (same results with dct64_MMX):
> 1. Floating point DCT
> 2. Saturate to 16-bit short (PF2IW)
>
> In addition, a false dependency of MMX2 in dct64_k7.c is also fixed
> (replace pshufw $78 with pswapd) so it can be used on a K6-2/3+.
>

3DNow! dosen't have PF2IW, so we have to use PF2ID/PACKSSDW instead,
hence the new patch. Sorry for the trouble.

-- 
Zuxy
Beauty is truth,
While truth is beauty.
PGP KeyID: E8555ED6
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dct64_3dnow.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20060621/1d3772fb/attachment.asc>


More information about the MPlayer-dev-eng mailing list