mp3.asm source code for the mp3 decoding functions mp3play.asm source code for the windows command line tool mp3play.exe win32 executable with support for all commandline options mp3tiny.exe win32 executable cutdown kkcrunchy-compressed 9.5Kbyte version |
mp3play "file.mp3" output to speakers mp3play "file.mp3" /test measure timings without output mp3play "file.mp3" "file.wav" output to .wav file mp3play "file.bit" "file.pcm" verify output against lieff's .pcm files mp3play ... /fast about 10% faster (slightly less accurate) mp3play ... /mono about twice as fast (faster, and still good) mp3play ... /half half sample rate (faster, and still good) mp3play ... /quarter quarter sample rate (doesn't sound so good) mp3play ... /8bit for old hardware (good, but not much faster) mp3play ... >"file.txt" redirect screen output to file (as usually) |
mp3play "Pisse - Fliegerbombe.mp3" /test nocash mp3 decoder v1.1, 2024 martin korth, press ctrl+c to quit, BDS now file: Pisse - Fliegerbombe.mp3 file size: 2,584,576, id3 size: 110,453, tag size: 0 input: 44100 hz, 2 channels, 234 kbit/s output: 44100 hz, 2 channels, 16 bit audio duration 84,584 milliseconds, decoded in 930 milliseconds clock cycles per second: read header 8,137 read extra 5,399 read granule 31,900 append main 133,763 read scalefac 49,550 xlat scalefac 100,201 read huffman 1,927,429 ms stereo 175,986 i stereo 0 reorder 10,813 antialias 498,490 imdct 1,517,604 imdct36 1,370,519 imdct12 16,766 imdct0 72,374 synth/dct 7,119,406 synth.dct32 1,832,372 synth.output 5,051,125 total 11,645,068 |
version processor tester clks/s (ms) cpu load mp3play v0.0 Pentium III, 1GHz nocash 16,xxx,xxx (pre-release) 0.016 ;\ mp3play v1.0 Pentium III, 1GHz nocash 12,190,805 (1019ms) 0.012 ; mp3play v1.1 Pentium III, 1GHz nocash 11,644,126 (935ms) 0.012 ; mp3play v1.2 Pentium III, 1GHz nocash 11,477,895 (903ms) 0.011 ; mp3play v1.3 Pentium III, 1GHz nocash 11,468,126 (899ms) 0.011 ; mp3play v1.4 Pentium III, 1GHz nocash 11,458,863 (885ms) 0.011 ; mp3play v1.1 C2D E8600, 3.33GHz TmEE 7,988,837 (207ms) 0.002 ; perfect mp3play v1.1 i5-4300U, 2.5GHz, TmEE 6,476,551 (281ms) 0.002 ; quality mp3play v1.1 i7-6700K, 4GHz, Memblers 6,427,673 (219ms) 0.002 ; mp3play v1.1 i7-9750H, 2.6GHz, GValiente 4,223,386 (235ms) 0.002 ; mp3play v1.4 Cyrix 5x86, 120MHz Many Bothans ~57.7M (40,663ms) 0.481 ; mp3play v1.4 Cyrix 5x86, 50x2MHz Many Bothans ~54.3M (45,914ms) 0.542 ; mp3play v1.4 Cyrix 5x86, 33x3MHz Many Bothans ~57.9M (48,979ms) 0.579 ; mp3play v1.4 Cyrix 5x86, 80MHz Many Bothans ~56.7M (59,960ms) 0.708 ; mp3play v1.4 Cyrix 5x86, 66MHz Many Bothans ~56.5M (72,499ms) 0.857 ; mp3play v1.4 AMD Am5x86, 160MHz Many Bothans ~94.8M (50,126ms) 0.592 ; mp3play v1.4 AMD Am5x86, 150MHz Many Bothans ~90.2M (50,855ms) 0.601 ; mp3play v1.4 AMD Am5x86, 133MHz Many Bothans ~99.9M (63,540ms) 0.751 ; mp3play v1.4 AMD Am5x86, 120MHz Many Bothans ~93.0M (65,610ms) 0.775 ; mp3play v1.4 AMD Am5x86, 100MHz Many Bothans ~91.5M (77,355ms) 0.914 ;/ mp3play v1.4 AMD Am5x86, 75MHz Many Bothans ~91.0M (102,654ms) 1.213 ;\ mp3play v1.4 Intel 486DX2, 66MHz Many Bothans ~91.7M (117,499ms) 1.389 ; good mp3play v1.4 Intel 486DX2, 50MHz Many Bothans ~92.6M (156,670ms) 1.852 ;/ mp3play v1.4 Intel 486SX, 33MHz Many Bothans ~87.2M (223,563ms) 2.643 ;-low(?) mp3play v1.4 Intel 486SX, 25MHz Many Bothans ~87.6M (296,439ms) 3.504 ;-too slow mp3play 80486DX2-66MHz - ? (more tests welcome) mp3play 80486DX4-100MHz - ? (unknown) mp3play 80386 - ? (unknown) mp3play Pentium I - ? (unknown) |
switches 44100Hz/234kbit/84584ms 48000Hz/256kbit speed quality /test 11,449,871 (899ms) 12,413,478 1.000 perfect /test /fast 10,165,734 (794ms) 11,015,452 1.127 good /test /half 8,191,299 (674ms) 8,839,641 1.404 good /test /fast /half 7,528,040 (605ms) 8,139,875 1.525 good /test /fast /mono 5,246,163 (445ms) 5,679,721 2.185 good /test /fast /mono /half 3,930,032 (320ms) 4,249,539 2.921 good /test /fast /mono /quarter 3,386,091 (268ms) 3,659,921 3.392 low /test /fast /mono /quarter /8bit 3,353,499 (269ms) 3,633,287 3.416 low |
source file clks/s speed quality pisse_44khz_234kbit.mp3 /test 11,449,871 1.000 perfect pisse_44khz_112kbit.mp3 /test 10,651,344 1.075 good pisse_22khz_112kbit.mp3 /test 6,028,984 1.899 good pisse_44khz_112kbit.mp3 /test /fast /mono /half 3,440,489 3.328 good pisse_11khz_56kbit.mp3 /test 3,034,350 3.773 low pisse_22khz_112kbit.mp3 /test /fast /mono 2,761,704 4.146 good pisse_22khz_112kbit.mp3 /test /fast /mono /half 2,099,826 5.453 low pisse_11khz_56kbit.mp3 /test /fast /mono 1,384,470 8.270 low |
WAV 44,100Hz, stereo, 16bit 1,411,200 bit/s (1:1) FLAC 44,100Hz, stereo, 16bit ~705,600 bit/s (1:2) ADPCM 44,100Hz, stereo, 4bit 352,800 bit/s (1:4) ADPCM 44,100Hz, mono, 4bit 176,400 bit/s (1:8) ADPCM 22,050Hz, mono, 4bit 88,200 bit/s (1:16) MP3 variable rate, high quality ~240,000 bit/s (1:5.88) MP3 320kbit/s (highest) 320,000 bit/s (1:4.41) MP3 256kbit/s (common these days) 256,000 bit/s (1:5.51) MP3 192kbit/s (common earlier) 192,000 bit/s (1:7.53) MP3 128kbit/s (medium) 128,000 bit/s (1:11.02) MP3 32kbit/s (lowest for mpeg1) 32,000 bit/s (1:44.10) MP3 8kbit/s (lowest for mpeg2) 8,000 bit/s (1:176.40) OGG compresses better than mp3 AAC compresses yet better than mp3 |