[MPlayer-dev-eng] [PATCH] Dithered audio out for Ogg & mp3lib_pentium_mode

ACS adrian.bacon at xs4all.nl
Tue May 17 07:28:08 CEST 2005


Hi,

This patch adds dithered outputs for both ogg and mp3lib (pentium mode) 
plugins.

The patch works for me, but a lot of work can be done:
-better declaration of dithertable
-add code for other codecs/CPU/modes. (even for replaygain on lossless 
files)
-make dither optional using configure or commandline
-.....

For more background, details, (audible!) test results... see:
http://213.84.144.87/dither123


The patch is split into 3 parts:
1) libvorbis patch.
2) mp3lib patch (pentium assembler routines changed + ugly hack to force 
pentium mode for x86 CPUs)
Note: The web page mentioned shows the mmx-routine is broken as sound 
quality is concerned!
3) a large table.(for space saving reasons this patch isn't attached but it 
can be DLed from the site mentioned.) It looks like this:

diff -Naur ./MPlayer-20050516/dither.h ./MPlayer-20050516dither/dither.h
--- ./MPlayer-20050516/dither.h 1970-01-01 01:00:00.000000000 +0100
+++ ./MPlayer-20050516dither/dither.h 2005-04-21 04:21:13.000000000 +0200
@@ -0,0 +1,65541 @@
+/* table holding dither values. noise shaping used */
+
+
+
+float dithertable[65536]={
+-0.126371,
+0.497872,
+-0.779434,
+0.843073,
+-0.646505,



Regards from
Adrian Bacon 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mp3libdither.diff
Type: application/octet-stream
Size: 7428 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20050517/d9e46ad3/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: oggdither.diff
Type: application/octet-stream
Size: 1117 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20050517/d9e46ad3/attachment-0001.obj>


More information about the MPlayer-dev-eng mailing list