IPB

Welcome Guest ( Log In | Register )

2 Pages V   1 2 >  
Reply to this topicStart new topic
Cue sheets, They are quite annoying
dignick
post Jun 15 2005, 12:01
Post #1





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



I have been reading these, and many other forums, about splitting mp3 files using cue sheets. I must have tried pretty much every solution, and I'm getting tired of them now.
Whenever I try to split an mp3 from a cue file using any software, there are always mistakes and noises at the start of every track. I am using besplit mainly now with the cue-splitter gui, and it works reasonably well apart from this problem. The only way I have found to split the mp3 without getting the sounds at the start is either to burn the mp3 to a CD using cdrwin, and then rip back to the PC, or to convert the whole thing to wav, split it, and convert back. I don't get the sounds then.

So, my question is, is it possible to split an mp3 without these noises at the start of each track? Is there a cue splitter application that will split the files properly?

Thanks
Go to the top of the page
+Quote Post
SebastianG
post Jun 15 2005, 13:04
Post #2





Group: Developer
Posts: 1317
Joined: 20-March 04
From: Göttingen (DE)
Member No.: 12875



QUOTE (dignick @ Jun 15 2005, 12:01 PM)
So, my question is, is it possible to split an mp3 without these noises at the start of each track?  Is there a cue splitter application that will split the files properly?
*


What decoder do you use for playback ?
Sounds like it chokes on incomplete bit reservoir buffers.

You see... MP3 frames are usually not independantly decodable due to the bit reservoir. So, if you split an MP3 file at a frame boundary the first frame of the 2nd file will most likely be indecodable. Most decoders just silence those first frames if they can not be decoded properly. Yours seem to try decoding frames with incomplete data as well and that's causing the noise.

There are several options. If the decoder is a software decoder just swap to a better one. In case you can't change that (ie hardware mp3 player) you should split the MP3 file properly (properly = accounting for the bitreservoir). Unfortunately I'm not aware of any mp3 splitter which produces all-decodable frames in case of bitreservoir usage. (This would require reformatting the stream. In possibly rare cases one has to insert one or more silence frames at the beginning which carry the necessary informations in the bitreservoir to overcome the frame size limitation. But in those cases you have to use a special mp3-merger, too (which removes those inserted frames) to get a big MP3 again which decodes to the same PCM file as the original one).


Sebi

This post has been edited by SebastianG: Jun 15 2005, 13:08
Go to the top of the page
+Quote Post
Jebus
post Jun 15 2005, 16:59
Post #3





Group: Developer
Posts: 1293
Joined: 17-March 03
From: Calgary, AB
Member No.: 5541



Decode to wav, then split. Shouldn't happen. MP3 frames share data with the preceeding and following frame, so clean splits are tricky without decoding first.
Go to the top of the page
+Quote Post
snookerdoodle
post Jun 15 2005, 17:09
Post #4





Group: Members
Posts: 120
Joined: 13-May 05
From: Albuquerque
Member No.: 22035



Stupid questions: what's a cue sheet and do I want one and why? I googled, but this doesn't seem to be the same thing you guys are talking about.

I just plays my dumb flac files through my squeezebox, but wouldn't wanna "miss out" on some new experience. smile.gif

Mark
Go to the top of the page
+Quote Post
dignick
post Jun 15 2005, 17:12
Post #5





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



I am using mpg123 in winamp, but the default winamp decoder is the same, and its the same in windows media player. It doesn't do this at the start of every track, or it's not noticable anyway.
Strangely, I cannot hear the noises when played in foobar2000, and that uses mpg123 doesn't it?
I do play music on my iPod, on which I can hear the sounds, so I need these files to be splitted properly. Does anyone know of a splitter that produces all-decodable frames? Or will I have to keep splitting them as wav?
Go to the top of the page
+Quote Post
dignick
post Jun 15 2005, 17:29
Post #6





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



QUOTE (Jebus @ Jun 15 2005, 04:59 PM)
Decode to wav, then split. Shouldn't happen. MP3 frames share data with the preceeding and following frame, so clean splits are tricky without decoding first.
*


Great, looks like lots more hard drive/CDRW usage for me laugh.gif
Go to the top of the page
+Quote Post
SebastianG
post Jun 15 2005, 17:36
Post #7





Group: Developer
Posts: 1317
Joined: 20-March 04
From: Göttingen (DE)
Member No.: 12875



QUOTE (dignick @ Jun 15 2005, 05:12 PM)
I am using mpg123 in winamp, but the default winamp decoder is the same, and its the same in windows media player.  It doesn't do this at the start of every track, or it's not noticable anyway.
Strangely, I cannot hear the noises when played in foobar2000, and that uses mpg123 doesn't it?
*

I guess some players don't make use of the mpg123 library correctly. (really just a guess)

QUOTE (dignick @ Jun 15 2005, 05:12 PM)
I do play music on my iPod, on which I can hear the sounds, so I need these files to be splitted properly.  Does anyone know of a splitter that produces all-decodable frames?  Or will I have to keep splitting them as wav?
*


There's a quick-and-dirty hack you can do if you're a programmer: Just make a copy of the last frame of the previous mp3-track and store it as first frame of the new mp3-track while zeroing the side-info block. This makes a silence frame containing the necessary bitreservoir informations for the next frame. You might want to mark this inserted silenceframe in order to be able to remove it automatically if you want to join the seperated tracks again. (Marking could be done via one of the 3 (stereo) or 5 (mono) private bits AFTER the mp3 header -- I guess the private bit in the header isn't really a safe place to put this information)

It's a quick hack 'cause you don't need any mp3 stream reformatting
It's a dirty hack 'cause it might only work in 99,9% of all cases.

Any volunteers ?
I'd do it myself but i'm rather busy right now


Sebi

edit: added remark about the 3/5 private bits after the header / fixed typos

edit2: since zeroing the side info block also requires recalcualtion of the CRC (if used) one could just set the protection bit in the header to 1 (1 = no CRC16 checksum). That'll simplify things.

This post has been edited by SebastianG: Jun 15 2005, 18:00
Go to the top of the page
+Quote Post
dignick
post Jun 15 2005, 19:36
Post #8





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



It would be great if someone could make a splitter that produces all-decodable frames, as I know from experiance that none of the current splitters do it properly. I would be happy to use the extra (I'm guessing) time and cpu power to reformat the streams like you said, as anything is better than what I am currently doing. Or even a tool that converts to wave, splits, and converts back on the fly would be a better, faster, and easier option.

I'd pay for it if someone did it anyway.
Go to the top of the page
+Quote Post
SebastianG
post Jun 15 2005, 22:23
Post #9





Group: Developer
Posts: 1317
Joined: 20-March 04
From: Göttingen (DE)
Member No.: 12875



You know what ?
Two years ago I already created a little app that may help you.

It's a tool that silences undecodable frames at the beginning of mp3 files. Since this is a destructive approach you won't be able to get the original mp3 back if you concatenate the tracks. But hey... at least you won't hear any noises. This is all I can offer for now.

grab it here

Sebi

This post has been edited by SebastianG: Jun 15 2005, 23:31
Go to the top of the page
+Quote Post
ponchorage
post Jun 15 2005, 23:40
Post #10





Group: Members
Posts: 509
Joined: 26-February 04
From: S.F., Utah
Member No.: 12282



Have you tried using Foobar? Does it produce this problem as well?
Go to the top of the page
+Quote Post
dignick
post Jun 16 2005, 18:03
Post #11





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



QUOTE (ponchorage)
Have you tried using Foobar? Does it produce this problem as well?

QUOTE (dignick @ Jun 15 2005, 05:12 PM)
Strangely, I cannot hear the noises when played in foobar2000, and that uses mpg123 doesn't it?
*


I tried that app, but it had no effect on the noise at the start of the file, which seems strange as shouldn't that tool fix it for good? It appears that the tool does not detect any bit-reservoir errors - from the results when running the tool:

MP3brfix (bit-reservoir-fix) v0.94(beta) © 2003/02-03 by ZeBee

first frame:
MPEG1 Layer3 128kbps 44100Hz J-Stereo
Xing-Tag present
flags: [fc] [bc] [toc] [vs]
LAME-Tag present ( LAME 3.96r )
mp3 frames: 15199, VBR (183.7 kbps)
Bit-Res errors: 0
no CRC protected frames found.
ready.


Also, would you be able to add batch support to that tool to fix a folder of mp3's?

I'm not bothered if the original gapless stream is unrecoverable, as long as it plays gapless on my PC, because I don't burn anything to CD any more.

Thanks for your help btw.

This post has been edited by dignick: Jun 16 2005, 18:04
Go to the top of the page
+Quote Post
ponchorage
post Jun 16 2005, 18:09
Post #12





Group: Members
Posts: 509
Joined: 26-February 04
From: S.F., Utah
Member No.: 12282



I meant, have you tried track splitting using Foobar (not playing) and does it produce these problems as well?
Go to the top of the page
+Quote Post
dignick
post Jun 16 2005, 18:35
Post #13





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



oh, sorry.

Forgive me biggrin.gif but i am new to foobar. How would I do this? I've had a look around but can't find how to do it.

Listening to the track more closely in foobar and comparing it to the original track playing directly from the cue file, I can hear the difference. So the splitters are actually making mistakes when splitting the files and creating these sounds, it's just foobar did a good job of hiding it. It's way more obvious in winamp.

As I say, I have tried many cue splitting programs, and all I have tried have this problem. So maybe foobar will be better to split it, when I find out how...
Go to the top of the page
+Quote Post
tycho
post Jun 16 2005, 19:01
Post #14





Group: Members
Posts: 345
Joined: 5-August 03
Member No.: 8183



Have you also tried http://mp3splt.sourceforge.net ?
I think its the most flexible splitter available, and I've never had the problem you describe.
Go to the top of the page
+Quote Post
ponchorage
post Jun 16 2005, 20:31
Post #15





Group: Members
Posts: 509
Joined: 26-February 04
From: S.F., Utah
Member No.: 12282



Just open up Foobar and load the cuesheet. Then go to the Foobar2000 menu--> Preferences. Next, look for "Diskwriter" and select it. You might not see this option if you didn't install the "Special" version of Foobar (which includes the diskwriter). Under Output Filename Formatting, I have:

CODE
%artist% - %album%\$num(%tracknumber%,2) - %artist% - %title%


but you can choose anything you like. Also, click on "Create subdirectories". Click on output presets and choose command line encoder: lame (the preset you want).
Then, click the edit button. This will open another window. In the "Encoder" textbox, browse to the location of lame.exe on your machine then click OK. Click Save All on the main preferences window and then close.

Then, select all tracks and right-click and choose "Convert-->Run Conversion". Choose the option you just edited (command line encoder: lame ...).

I think that's it!
Go to the top of the page
+Quote Post
dignick
post Jun 16 2005, 21:21
Post #16





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



Now, that works very nicely, but I guessed it would when i started looking at it as it re-encodes it. I will probably use this in future unless I can get mp3split that tycho mentioned working, as it would be better than re-encoding it, and faster. Thanks though Ponchorage, I had heard about foobar being able to split Cues but never found how to do it or anywhere that told me!

cheers

This post has been edited by dignick: Jun 16 2005, 21:38
Go to the top of the page
+Quote Post
ponchorage
post Jun 16 2005, 22:02
Post #17





Group: Members
Posts: 509
Joined: 26-February 04
From: S.F., Utah
Member No.: 12282



QUOTE (dignick @ Jun 16 2005, 12:21 PM)
Now, that works very nicely, but I guessed it would when i started looking at it as it re-encodes it.  I will probably use this in future unless I can get mp3split that tycho mentioned working, as it would be better than re-encoding it, and faster.  Thanks though Ponchorage, I had heard about foobar being able to split Cues but never found how to do it or anywhere that told me!

cheers
*


Yeah, you're right, it reencodes. I hadn't thought of that. crying.gif
Go to the top of the page
+Quote Post
dignick
post Jun 16 2005, 23:28
Post #18





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



QUOTE (ponchorage @ Jun 16 2005, 10:02 PM)
QUOTE (dignick @ Jun 16 2005, 12:21 PM)
Now, that works very nicely, but I guessed it would when i started looking at it as it re-encodes it.  I will probably use this in future unless I can get mp3split that tycho mentioned working, as it would be better than re-encoding it, and faster.  Thanks though Ponchorage, I had heard about foobar being able to split Cues but never found how to do it or anywhere that told me!

cheers
*


Yeah, you're right, it reencodes. I hadn't thought of that. crying.gif
*



Hey, it's a lot better than encoding to wav, splitting, then back to mp3 again. If i can't get mp3split working or it still makes the noises, I will definately be using foobar.

Just one more thing - do I need to add the --nogap switch to the LAME commandline? That switch isn't even in the documentation for lame - why?

Thanks

EDIT: I noticed that using the --nogap switch makes the first track of the conversion appear as 35 minutes long when it's only about 5. Strange.

This post has been edited by dignick: Jun 17 2005, 09:39
Go to the top of the page
+Quote Post
dignick
post Jun 17 2005, 10:06
Post #19





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



MP3splt also makes the noises. It couldn't be something specific to my computer could it? I think I will try splitting on a different computer and see if it makes any difference.

Results: Exactly the same. Is there a codec that could be doing this? I have the same codecs on both computers.

Edit: Tried on a different PC that has the default windows codecs - same.

So, until someone makes an app that can split mp3's without these noises (and please tell me if you do), I'll use foobar.

Thanks

This post has been edited by dignick: Jun 17 2005, 12:36
Go to the top of the page
+Quote Post
Jud
post Jun 19 2005, 00:33
Post #20





Group: Members (Donating)
Posts: 58
Joined: 12-March 04
From: Houston, TX
Member No.: 12673



hey dignick,

I saw this post and couldnt resist trying to do it. let me know if it works. I tried it on about 4 or 5 different cue/mp3 albums and didn't hear any problems, although I may have just gotten lucky smile.gif It rewrites the LAME header so foobar reports the correct track lenghts.

Anyway you can grab it here: http://cdtag.com/splitcue.zip

Go to the tag tab on the upper right, select your CUE and hit File, Split CUE Sheet

Let me know if there's a problem I'll try to fix it.
Go to the top of the page
+Quote Post
dignick
post Jun 20 2005, 11:11
Post #21





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



I tried it.
At first, I thought it had worked, but when i got to track 11, the noises came clear again. I really don't know why these noises are present, but they are.

Any thoughts? Because I really would like to reslove this problem, otherwise it will keep bugging me biggrin.gif

Thanks

This post has been edited by dignick: Jun 20 2005, 11:15
Go to the top of the page
+Quote Post
SebastianG
post Jun 20 2005, 17:42
Post #22





Group: Developer
Posts: 1317
Joined: 20-March 04
From: Göttingen (DE)
Member No.: 12875



sorry, for the absence (vacation to Scotland).

@Jud: Did you account for the bitreservoir ?

@dignick: Could you describe how you've done the splitting/fixing exactly ? I'm specifically interested in the used splitter. BTW: You can try to run LAME as a decoder with "--decode". It'll give you the "can't step back xxx bits" error message if the bitreservoir is incomplete. If it does it can be fixed with the mp3brfix app.

edit: you didn't take the first track, did you ? Because the first track will most likely NOT contain bit res errors.

QUOTE (dignick @ Jun 16 2005, 06:03 PM)
MP3brfix (bit-reservoir-fix) v0.94(beta) © 2003/02-03 by ZeBee

first frame:
  MPEG1 Layer3 128kbps 44100Hz J-Stereo
  Xing-Tag present
  flags: [fc] [bc] [toc] [vs]
  LAME-Tag present  ( LAME 3.96r )
mp3 frames: 15199, VBR (183.7 kbps)
Bit-Res errors: 0
no CRC protected frames found.
ready.
*


That's odd. The app used to work actually. Either the splitter accounts for the bitreservoir (somehow badly perhaps -- which would explain the clicks) or you just ran mp3brfix on the first track.


Sebi

This post has been edited by SebastianG: Jun 20 2005, 17:54
Go to the top of the page
+Quote Post
dignick
post Jun 20 2005, 18:47
Post #23





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



Using LAME to decode:

QUOTE
skipping initial 1105 samples (encoder+decoder delay)
Can't step back 78!
Frame# 17680/17681  256 kbps  MS


So yes, the bit reservoir is incomplete, but on the same track with mp3brfix:

QUOTE
MP3brfix (bit-reservoir-fix) v0.94(beta) © 2003/02-03 by ZeBee

first frame:
  MPEG1 Layer3 64kbps 44100Hz J-Stereo
  Xing-Tag present
  flags: [fc] [bc] [toc]
mp3 frames: 17682, VBR (213.6 kbps)
Bit-Res errors: 0
no CRC protected frames found.
ready.


The track doesn't change if I try to remove the bitreservoir errors, and decode with lame still gives the error. And it's track 11 that I am doing this on.

Any cue splitter that I have used does this, for example besplit, or the tool that Jud suggested. Using splitcue that jud suggested or besplit both give 0 bit-res errors in mp3brfix but I still get 'can't step back' errors when using lame. I noticed that the 'Can't step back' values change for the different splitting tools.

If I use foobar to split/re-encode, there are no 'Can't step back xxx!' errors on the same track.
Looks like you hit on the reason for the noises sebastian, right from the start!

This post has been edited by dignick: Jun 20 2005, 21:01
Go to the top of the page
+Quote Post
Jud
post Jun 21 2005, 05:32
Post #24





Group: Members (Donating)
Posts: 58
Joined: 12-March 04
From: Houston, TX
Member No.: 12673



QUOTE (SebastianG @ Jun 20 2005, 08:42 AM)
@Jud: Did you account for the bitreservoir ?
*

Sebi,

I tried your method with using the last frame from the previous track and zero'ing the side information (32 bytes after the 4 byte header, assumg M1L3). This produced a small but noticeable gap between tracks, and since I can't hear the difference when it just does a clean frame break I went with that method.

If you have any other suggestions I'd be willing to try them out if you're too busy.
Go to the top of the page
+Quote Post
dignick
post Jun 21 2005, 07:53
Post #25





Group: Members
Posts: 34
Joined: 15-June 05
Member No.: 22752



QUOTE (Jud @ Jun 21 2005, 05:32 AM)
QUOTE (SebastianG @ Jun 20 2005, 08:42 AM)
@Jud: Did you account for the bitreservoir ?
*

Sebi,

I tried your method with using the last frame from the previous track and zero'ing the side information (32 bytes after the 4 byte header, assumg M1L3). This produced a small but noticeable gap between tracks, and since I can't hear the difference when it just does a clean frame break I went with that method.

If you have any other suggestions I'd be willing to try them out if you're too busy.
*



Is that not the gap that normally occurs between tracks, that can be removed with a mpg123 decoder?

Also, what player/decoder are you using to play the files Jud?

Could you not make
QUOTE
I tried your method with using the last frame from the previous track and zero'ing the side information (32 bytes after the 4 byte header, assumg M1L3)

an option?
Go to the top of the page
+Quote Post

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 26th July 2014 - 08:47