Corrupted output and other issues with certain audiobook (.m4b) files

Issue #540 new
Nolaine Crusher created an issue

I’ve noticed that when working with a source output by either Audiobook Builder or Audiobook Binder, Subler comes up with a number of issues.

As far as I can tell--and I have not tested it extensively yet--any time I open a file that was created or edited by Audiobook Binder to tweak the metadata/chapters/cover, when I do a “Save As” the output file will be corrupt and nothing will read it. If I do a “Save” the source file will be corrupted.

The file appeared to work properly before Subler touched it.

When dealing with files created by AudioBook builder, Subler is a LITTLE more stable. It only creates a corrupted output file some of the time, and I have not yet figured out what those specific situations are. HOWEVER…

When doing a “Save As” it will incorrectly flag the file as being over 4GB in size and needing the 64-bit chunk offset, even though it isn’t. This doesn’t appear to affect the quality of the output file, mostly it’s just a false warning I can ignore. But when doing a straight-up “Save” sometimes it will, again, corrupt the source file in the attempt to save.

Finally a feature request: please allow .cue and/or .xml files created by TwistedWave and/or other audio editors to mark chapters to be imported as a chapter source. Thank you.

Comments (11)

  1. Nolaine Crusher reporter

    Hi, I have uploaded the files here.

    https://drive.google.com/drive/folders/1_3su_i7nAFD6a5ufXjRUsFmI7qjVBOkJ?usp=sharing

    Of course, now Audiobook Binder is going to make a liar out of me, because this particular file doesn't appear to have any issues, but that hasn't been my experience in the past. I'm really not sure what's different this time.

    If I may make one other feature request while I have your attention... perhaps a means to join together .m4b files? Audiobook Builder doesn't have a way to turn off splitting long .m4b files so that they'll play on some older Apple devices, which means the file gets split whether you need it to or not.

    Thank you!

  2. Damiano Galassi repo owner

    The files from ABB are not valid mp4 files. They use a mov only atom (“wide”), and the size of the mdat atom is wrong.

    AUDIOBOOK BUILDER Honor Harrington #10.m4b seems ok, SOURCE Honor Harrington #10 - War of Honor.m4b too.

  3. Nolaine Crusher reporter

    I assume by ABB you mean Audiobook Binder instead of Audiobook Builder? I’ve had issue in the past with Audiobook Builder not recognizing files that have been output by Audiobook Binder, and the error message had them listed as having a .mov extension, which makes sense given what you’re saying. We’ll just chalk Audiobook Binder up as an unreliable tool, I guess.

    That only leaves the issue with Subler thinking that files that have been output by Audiobook Builder are >4GB when they’re not. If you do a save-as in Subler of a file that has been output by Audiobook Builder, it will say it couldn’t save (even though it still does) because the file was over 4GB and needs the 64-bit chunk offset box checked. Obviously the files aren’t larger than 4GB, but it still gives that message anyway. It does, however, still save the file and the file is usually usable.

  4. Damiano Galassi repo owner

    “Save as” right now works like this: it copies the file, and then modifies it. So it will fail in the same way as just saving a normal file. The error message is a generic one.

    One way to workaround the input file issue is to create a new empty document in Subler and import the file (the plus button in the toolbar).

  5. Nolaine Crusher reporter

    Hi there.

    I uploaded several options. TwistedWave offers exports of the chapter markers in a number of formats. I included the .cue, .csv, .xml, and 30fps example (they also offer that in a number of other framerates as well, but I didn't include them all.)

    I included a .cue exported from Fission as well, because it's slightly different, as Fission includes metadata for each chapter instead of just the whole file.

    For both of those, I used Dragons Fire, which I also included in case you need the audio source.

    I included a label track from Audacity as well, which is in yet a different format entirely. Since Audacity wouldn't read an .m4b, I used a different .mp3 file, and included that in the folder too.

    You can find them in the same directory as before, here: https://drive.google.com/drive/folders/1_3su_i7nAFD6a5ufXjRUsFmI7qjVBOkJ?usp=sharing

    I'm hesitant to make too many feature requests because I don't know how interested you are in making Subler a tool for audiobooks, which is primarily what I use it for. But if that is functionality you wish to include, I have other ideas as well. The hard part about working with audiobooks on Mac is that there are far fewer tools, and fewer still for audiobooks, and most of what we're doing is using tools meant for encoding or tagging music and/or video, and none of them are really entirely suited to the purpose. But then, even Itunes still tries to handle audiobooks like music instead of a different creature altogether, so things like support for library curation and series management are sort of cobbled together out of "what can I make playlists do for me today?" wishful thinking.

  6. Nolaine Crusher reporter

    Hi Damiano. If you have time, could I pick your brain about MacOS app development and XCode/Swift? I’ve been working really hard going through tutorials trying to learn the basics, but now that I’m sort of past the basics, I’m having trouble figuring out where to go next to acquire the knowledge I need to start a project I’d really like to start.

    If you want to email me, you can reach me on gmail, nolainecrusher, or let me know how to get in touch with you. Thank you.

  7. Damiano Galassi repo owner

    If you are a beginner learning UI frameworks like Appkit or similar will be a bigger task than learning the basics of Swift. Probably you should search for a good book on Cocoa with Swift.

  8. Nolaine Crusher reporter

    Actually my big stumbling block so far seems to be ffmpeg.

    My “phase one” project for my audiobook management system for MacOS is to build a tool that will let the user convert audiobook formats, rechapter, and tweak metadata, by calling on ffmpeg.

    I’ve got a working interface, with a browse button that lets the user choose a file to import, a browse button that lets the user select an output destination, text fields to display both of those paths, a popup menu that offers the user a few different common audiobook formats to convert to, and a “start conversion” button. All of which works.

    I’ve even successfully added ffmpeg to the resource bundle and implemented a process to launch it. But for some reason, ffmpeg isn’t liking the arguments I’m feeding into it and I cannot for the life of me troubleshoot why.

    What a stupid thing to get stuck on.

  9. Log in to comment