Skip to main content

Topic: pcutmp3 tool (Read 239384 times) previous topic - next topic

0 Members and 1 Guest are viewing this topic.
  • markanini
  • [*][*][*][*][*]
pcutmp3 tool
Reply #200
I've created a new version of PCutMp3 with a GUI for creating, opening, etc. cuesheets.
It also fixes a bug concerning 48000Hz mp3 files.

See https://github.com/hoesterholt/pcutmp3-gui for the source.
And https://github.com/hoesterholt/pcutmp3-gui/...aster/README.md for a small readme and a download link for an installer.

Thanks, it's nice to have an all-in-one installer.
Unfortunately I have a bug report: Invoking the file menu does nothing. Strangely it worked fine the other day. There have been no changes in my sytem that would account for the change in behaviour.

  • n0v!ze
  • [*]
pcutmp3 tool
Reply #201
I've got a couple of questions regarding ID3v2 support in pcutmp3:

- By default, does pcutmp3 write ID3v2.3 or ID3v2.4 tags?
- If the latter, is there a command line switch to force ID3v2.3?
- In case of ID3v2.3, what padding size is used? (analog to LAME's --pad-id3v2-size option)
- Is there a way to specify the padding size?

Regards

  • n0v!ze
  • [*]
pcutmp3 tool
Reply #202
Since I got no answer from the author, I decided to fork the project on my Bitbucket account.
It is here : https://bitbucket.org/gbouthenot/pcutmp3/
I do not claim being the original author. I would remove it if the authors ask me to. It's New BSD Licence, so it should be legal, though.

The webpage provides a download link for the compiled jar (Megar Build 3), So I will remove Build 2 from here.

Megar Build 3 seems to have a bug in the options parser:



When I remove --artist and --album from the command line, it works:



Both options --artist and --album are explicitely allowed:


  • n0v!ze
  • [*]
pcutmp3 tool
Reply #203
I've got a couple of questions regarding ID3v2 support in pcutmp3:

- By default, does pcutmp3 write ID3v2.3 or ID3v2.4 tags?
- If the latter, is there a command line switch to force ID3v2.3?
- In case of ID3v2.3, what padding size is used? (analog to LAME's --pad-id3v2-size option)
- Is there a way to specify the padding size?

Regards

I ran a quick test with an input file which only has ID3v2.3 tags and found that the split files do have ID3v2.3 tags only, too:



Unfortunately, metamp3 doesn't tell me anything about the padding size. Anybody?

  • bilbo
  • [*][*][*]
pcutmp3 tool
Reply #204
I've got a couple of questions regarding ID3v2 support in pcutmp3:

Unfortunately, metamp3 doesn't tell me anything about the padding size. Anybody?
You might want to try mp3packer. It will let you do many operations to the file, all lossless. Here is an example of extracting information. is this padding information the information that you are looking for?

Code: [Select]
Info

By specifying the -i option, the program will print data about the input file then exit. No files will be written and the output (if given) will be ignored. Example printout:

*** "test/APS.mp3"
INFO:
 MPEG1 layer 3
 21687 frames
 44100 Hz
 38.281250 frames per second
 566.517551 seconds
 12514543 bytes in file (176.722405 kbps)
 12514126 bytes in MP3 frames (176.716516 kbps) = current bitrate
 93784923 bits of payload data (165.546368 kbps)
 11732617 bytes of payload data (165.680544 kbps)
 76013 bits wasted from partially-full bytes (0.134176 kbps)
 12513349 bytes of MP3 data (176.705544 kbps) = minimum bitrate possible
 777 bytes of padding (0.010972 kbps)
 417 bytes outside MP3 frames (0.005889 kbps)
 1 sync error
 Bitrate distribution:
   32: 9,0
  128: 3641,0
  160: 7691,0
  192: 6700,0
  224: 2736,0
  256: 785,0
  320: 125,0
 Largest frame uses 8478 bits = 1060 bytes = 324.548437 kbps
 Smallest bitrate for CBR is 256

It will let you remove all padding.
Glass half full!

  • n0v!ze
  • [*]
pcutmp3 tool
Reply #205
Actually, I want quite the opposite: I'd like to make sure that there's enough room for tagging without extending the file. If I knew this is 4096 bytes, everything would be fine.

  • mjb2006
  • [*][*][*][*][*]
pcutmp3 tool
Reply #206
I haven't seen any tag-reading tools that go beyond just telling you what type of tags are in the file, and what the name-value pairs are. Tag type, order, size, and how the space is utilized in each tag are things I only ever learn by looking at the file with a hex editor.

  • n0v!ze
  • [*]
pcutmp3 tool
Reply #207
I haven't seen any tag-reading tools that go beyond just telling you what type of tags are in the file, and what the name-value pairs are. Tag type, order, size, and how the space is utilized in each tag are things I only ever learn by looking at the file with a hex editor.

OK, did this. Actually the Xing header starts at offset 1078h (4217) and there are only ASCII nulls up to offset 1045h (4180). So I guess the padding size is 4096 bytes. Looks like pcutmp3 is the right tool for the job. :-)

  • yoasif
  • [*]
pcutmp3 tool
Reply #208
I'm running into the same issues with the MEGAR BUILD 3 of pcutmp3 that others have found.

I'm cutting a 48000Hz VBR file and even after using vbrfix, mp3brfix and foobar2000's "Fix VBR MP3 Header" on the file, I run into a "is NOT a multiple of 640" error.

The error is:

Code: [Select]
PCutMP3 -- Properly Cut MP3 -- MEGAR BUILD 3
see http://www.hydrogenaudio.org/forums/index.php?showtopic=35654

scanning "/home/asif/bin/01-tiesto_-_essential_mix-sat-02-01-2014-talion.mp3" ...
first frame header = MPEG1 Layer3 128kbps 48000Hz J-Stereo
Xing/Info and LAME tag present
bitrate = 220.0 kbps (VBR)
accurate length = yes
344573952 samples (is NOT a multiple of 640)
writing "/home/asif/bin/temp/01. Essential Mix - Intro.mp3" ...
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: -10
    at de.zebee.mpa.util.ScannedMP3.getInt16(ScannedMP3.java:91)
    at de.zebee.mpa.util.ScannedMP3.getInt32(ScannedMP3.java:95)
    at de.zebee.mpa.util.ScannedMP3.getFrameFileOfs(ScannedMP3.java:109)
    at de.zebee.mpa.util.ScannedMP3.crop(ScannedMP3.java:367)
    at de.zebee.mpa.MainCLI.main(MainCLI.java:368)


which has been reported previously.

Is this a hard and fast limitation of pcutmp3? Other users seem to have resolved this issue in various ways, but running the VBR fix tools don't seem like it will help this situation. Is there any way to pad the original mp3 with a few samples of silence at the end to ensure that the sample count is divisible by 640? Or is there some other way to resolve this?

  • mjb2006
  • [*][*][*][*][*]
pcutmp3 tool
Reply #209
Are you sure this exception is related to the warning about the sample count not being a multiple of 640? Looks like the warning is just informational, letting you know that the last track will end slightly early; i.e. it doesn't look like it came from a CD.

The exception happens later, I think, when it's trying to look at the bit reservoir, which involves looking at previous frames. https://code.google.com/p/pcutmp3/source/br...ScannedMP3.java

I don't fully grok what's going on, but my guess is that the first frame(s) of the input MP3 say their data starts in the bit reservoir (i.e., back a frame or two), and pcutmp3 wasn't expecting that, since it wouldn't be the case in a normal MP3, but would happen in a stream that was already crudely split, like your captured radio show probably is.

You might try pre-processing the mp3 with mp3packer -b 320 -r (makes all frames 320 kbps and minimizes bit reservoir usage). Then if the pcutmp3 split works, run the result through mp3packer -s -t -z (squeezes it back down to VBR, as tightly as possible) (might not actually be necessary; pcutmp3 might do well enough).

(I fully admit I may have no idea what I'm talking about)
  • Last Edit: 05 February, 2014, 07:34:03 PM by mjb2006

  • yoasif
  • [*]
pcutmp3 tool
Reply #210
So this is what I did, based on your recommendation:

Code: [Select]
wine mp3packer.exe -b 320 -r /home/asif/Downloads/01-tiesto_-_essential_mix-sat-02-01-2014-talion.mp3 /home/asif/Downloads/01-tiesto_-_essential_mix-sat-02-01-2014-talion-new.mp3
fixme:msvcrt:MSVCRT__wsopen_s : pmode 0x01b6 ignored

*** '/home/asif/Downloads/01-tiesto_-_essential_mix-sat-02-01-2014-talion.mp3' -> '/home/asif/Downloads/01-tiesto_-_essential_mix-sat-02-01-2014-talion-new.mp3'
WARNING: Buffer over/underflow on frame 0 at 0:00.00
100% done with 299112 frames (664.94x)

  WARNING: an error was encountered
    1 buffer error


I was then able to successfully cut the mp3 using pcutmp3. 

pcutmp3 didn't really cut the filesize down, and foobar2000 shows that the files it generated are 320kbps. After running mp3packer -s -t -z as you suggested, the files do become vbr, and LAME tags are preserved.

Thank you so much for your suggestion, mjb2006 - I have been having this problem for months with various other files, and I spent a decent amount of time searching for assistance. You have made my day!

  • Molusc
  • [*]
pcutmp3 tool
Reply #211
I've created a new version of PCutMp3 with a GUI for creating, opening, etc. cuesheets.
It also fixes a bug concerning 48000Hz mp3 files.

See https://github.com/hoesterholt/pcutmp3-gui for the source.
And https://github.com/hoesterholt/pcutmp3-gui/...aster/README.md for a small readme and a download link for an installer.

Thanks, it's nice to have an all-in-one installer.
Unfortunately I have a bug report: Invoking the file menu does nothing. Strangely it worked fine the other day. There have been no changes in my sytem that would account for the change in behaviour.


Did you ever find a fix for this?  I'm seeing a similar issue - the File --> Open menu command doesn't do anything.  Other menu commands like Save and Quit do work.

It was working fine yesterday and nothing has changed on my computer.
  • Last Edit: 08 February, 2014, 08:59:59 AM by Molusc

  • boardlord
  • [*]
Re: pcutmp3 tool
Reply #212
I've created a new version of PCutMp3 with a GUI for creating, opening, etc. cuesheets.
It also fixes a bug concerning 48000Hz mp3 files.

See https://github.com/hoesterholt/pcutmp3-gui for the source.
And https://github.com/hoesterholt/pcutmp3-gui/...aster/README.md for a small readme and a download link for an installer.
Thanks, it's nice to have an all-in-one installer.
Unfortunately I have a bug report: Invoking the file menu does nothing. Strangely it worked fine the other day. There have been no changes in my sytem that would account for the change in behaviour.

Did you ever find a fix for this?  I'm seeing a similar issue - the File --> Open menu command doesn't do anything.  Other menu commands like Save and Quit do work.

It was working fine yesterday and nothing has changed on my computer.

@hoesterholt

Any chance of a recompile? I saw that you fixed this bug on Git :) Thanks!

Edit: I downloaded Eclipse, and did a re-export, it was fairly easy :) I don't want to share this, since I am not sure of licenses and such...
  • Last Edit: 25 February, 2017, 04:35:44 AM by boardlord