Re: [patch v2] external MPEG audio decoding using libmpg123
Thomas Orgis <[email protected]> Sun, 23 Sep 2018 10:28:33 +0200
| Newsgroups | gmane.comp.audio.mp3.lame |
|---|---|
| Message-ID | <20180923102833.52bc00bd@klammerschelle> |
Am Sun, 23 Sep 2018 00:28:33 +0200 schrieb Elio Blanca via Lame-dev <[email protected]>: > topolinik@cindy:/tmp/lametest.HDq5P/lame/frontend$ ./lame --verbose > --decode compl.mp3 test.wav > Error opening MPEG input file compl.mp3. > Can't init infile 'compl.mp3' This most weird. For some reason your build differs in that little property of not being totally broken. > My PC is an Intel Core i5 6200 with the latest Linux Mint Debian > Edition 3 x86-64, aka Cindy. Hm, works fine for me on Ubuntu 18.04 and $CUSTOM_SYSTEM with gcc 7.2. Next step without thinking much is to compare libmpg123's debugging output. If you add --enable-debug to the mpg123 and lame builds … #!/bin/sh set -e workdir=$(mktemp -d -t lametest.XXXXX) echo "working directory: $workdir" cd $workdir # creates mpg123-$TIMESTAMP.tar.bz2 # Alternatively, fetch svn://scm.orgis.org/mpg123/trunk and # run `autoreconf -iv` there. wget --content-disposition https://mpg123.org/snapshot tar -xf mpg123-*.tar.bz2 cd mpg123-*/ ./configure --enable-debug --prefix=$workdir/mpg123 make -j3 make install cd $workdir wget https://mpg123.org/test/lame-svn-r6432-libmpg123.patch svn co https://svn.code.sf.net/p/lame/svn/trunk/lame lame cd lame patch -Np0 < ../lame-svn-r6432-libmpg123.patch autoreconf # gnu89 needed for mp3x, with gtk1 # If you do not care, remove --enable-mp3x. #CFLAGS="-std=gnu89 $CFLAGS" \ PKG_CONFIG_PATH=$workdir/mpg123/lib/pkgconfig:$PKG_CONFIG_PATH \ ./configure --enable-libmpg123 --enable-debug=alot make -j3 pwd # Now test things in frontend/ … you should observe different output than this: shell$ svn export svn://scm.orgis.org/mpg123/test/compliance/layer3/compl.bit compl.mp3 shell$ ./lame --decode compl.mp3 test.wav 2>&1 | head -n 30 [src/libmpg123/readers.c:1106] debug: open_bad [src/libmpg123/frame.c:837] debug: frame_gapless_init: given -1 frames, skip 0 and 0 [src/libmpg123/frame.c:849] debug: frame_gapless_init: from 0 to 0 samples [src/libmpg123/frame.c:244] debug: resizing index to 1000 [src/libmpg123/index.c:75] debug: new index of size 1000 at 0x14edd50 [src/libmpg123/frame.c:246] debug: index resized... 1000 at 0x14edd50 [src/libmpg123/frame.c:256] debug: set up frame index of size 1000 (ret=0) [src/libmpg123/libmpg123.c:73] debug: cpu opt setting [src/libmpg123/libmpg123.c:180] debug: set flags to 0x8000 [src/libmpg123/readers.c:1106] debug: open_bad [src/libmpg123/frame.c:837] debug: frame_gapless_init: given -1 frames, skip 0 and 0 [src/libmpg123/frame.c:849] debug: frame_gapless_init: from 0 to 0 samples [src/libmpg123/index.c:132] debug: reset with size 1000 [src/libmpg123/readers.c:1120] debug: feed reader [src/libmpg123/readers.c:1139] debug: feed reader init successful [src/libmpg123/libmpg123.c:176] debug: set flags to 0x88000 [src/libmpg123/libmpg123.c:176] debug: set flags to 0x88020 [src/libmpg123/readers.c:1106] debug: open_bad [src/libmpg123/frame.c:837] debug: frame_gapless_init: given -1 frames, skip 0 and 0 [src/libmpg123/frame.c:849] debug: frame_gapless_init: from 0 to 0 samples [src/libmpg123/index.c:132] debug: reset with size 1000 [src/libmpg123/readers.c:1159] debug: stream reader [src/libmpg123/libmpg123.c:642] debug: read frame [src/libmpg123/parse.c:519] debug: trying to get frame 0 at 0 [src/libmpg123/parse.c:1048] debug: doing ahead check with BPF 192 at 4 [src/libmpg123/parse.c:1067] debug: After fetching next header, at 4 [src/libmpg123/parse.c:1074] debug: does next header 0xfffb54c4 match first 0xfffb54c4? [src/libmpg123/parse.c:562] debug: read frame body of 188 at 4 [src/libmpg123/parse.c:149] debug: do we have lame tag? [src/libmpg123/frame.c:1027] debug: changing scale value from 1.000000 to 1.000000 (peak estimated to -1.000000) I presume your build does not get as far as read_frame. At least your output should be smaller so that you can spare the `head -n 30`. If that does not show anything, we need to add some more lines of debugging output to lame, before libmpg123 comes into play. Alrighty then, Thomas -- Thomas Orgis - Source Mage GNU/Linux Developer (http://www.sourcemage.org) OrgisNetzOrganisation ---)=- http://orgis.org GPG public key 60D5CAFE: http://thomas.orgis.org/public_key Fingerprint: D021 FF8E CF4B E097 19D6 1A27 231C 4CBC 60D5 CAFE _______________________________________________ Lame-dev mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/lame-dev