GithubHelp home page GithubHelp logo

Comments (15)

audiamus avatar audiamus commented on July 16, 2024 1

From your description I would guess that there is an issue with the embedded meta data information in this particular aax file. You can easily test this yourself and run ffmpeg from a console window:
ffmpeg.exe -i myaudiobook.aax
It will list all the chapters in text format, with start and end times in seconds for each of them. AAX Audio Converter simply parses this output. I would expect that the missing chapter will either not not appear in that list or will show up in a slightly modified format so that the parser cannot recognize it.

Now, when you run the audiobook from the App, things will be different. With the app, the meta data is not taken from the aax file itself but from a separate meta data file that will be downloaded by the app together with the aax file.

I have started working on this separate meta data file and hope to get it running for the next version of the program. Main reason for looking into this new file is the list of proper chapter names therein and some users have asked for these. But incorporating this new data will take a bit of time.

As you appear to be affected by the current 24h limit for a book, I suggest two workarounds:

  1. Download the book in parts. Keep the "single file" option. but convert all parts in one invocation.
  2. Or you try the "multiple files, ignoring chapters" option, with an average track length set to the max which is 30 min. Tracks will be split based on silence, so no loss of audio quality during track transition. (But try this second option this with caution. To obtain good precision for silence periods, the program still uses the chapter times to extract temoprary shorter files and then works on those, due a shortcoming of ffmpeg for silence detection. And with a missing chapter, this might go wrong. )

In both cases a playlist will be generated for seamless listening.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

Now, when you run the audiobook from the App, things will be different. With the app, the meta data is not taken from the aax file itself but from a separate meta data file that will be downloaded by the app together with the aax file.

I have started working on this separate meta data file and hope to get it running for the next version of the program. Main reason for looking into this new file is the list of proper chapter names therein and some users have asked for these. But incorporating this new data will take a bit of time.

This explains a lot. I thought it was too much of a coincidence for two random people to have the exact same issue. And a meta data file makes a lot of sense. It also explains why the chapters have name in the official players but not in AAC and OA.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

Download the book in parts. Keep the "single file" option. but convert all parts in one invocation.

If this suggestion was for the missing chapter, I confirm that this doesn't work.

Additionally, there's a small issue. The book in 4 parts gets extracted correctly, and 4 M4A files are created, as well as 4 subfolders ("Part 1" to "Part 4"), each with an empty M3U file. I'm guessing the idea was for a single M3U file linking to the parts in a single subfolder?

Edit: to clarify, I understood your instructions to mean "download the audiobook in parts, and choose the single file per AAX file option".

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

The way it is supposed to be done is to load all parts into AAX Audio Converter (the Open File dialog supports multiple select, or simply drag them onto its main window), then select them all in the list view (or Ctrl+A) and click "Convert". The program will detect the multi-part book, enter internal multi-part processing and assumes all parts are present. For the "Single file per aax file" mode, five files should be created for your four part book. Four audio files, mp3 or m4a, and one playlist file m3u. And the playlist should have four tracks.

No "part" sub-folders should be created, if invoked like this. If you convert file-by-file, though, you may encounter a bug as I just noticed, obviously a combination that I did not test. When converting a multi-part book for an individual part, a sub-folder "Part #" will be created and the output should go in there. However, this does not make much sense for the singe file per aax option. So, two policies are conflicting here and the result is not as expected. Has to be investigated.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

I just tried it with two different books.

Following your instructions, I still get the 4 "Part #" folders with the empty M3U files.

To be clear: I load all 4 files into the program, select them all, and convert using "single file per aax file" in one go.

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

I tested a few more option combinations but I cannot produce the result you describe. The closest I get is:

  • Load a 4 part book, all parts.
  • Select part 1, 2 and 4 in the list view but not part 3. This will put the program into the internal "some parts" mode.
  • Click Convert. Subfolders Part 1, Part 2 and Part 4 are created, each with an empty m3u playlist. Apparently a bug but not essential. Because the three converted audio files end up in the main folder. Not good and not intended, but there they are, at least for my tests.

Could it be that for your example the part numbers are not in consecutive order? The program enters "all parts" if part numbers start with 1 and the number of parts equals the highest part number (consecutive order). If conversion is processed for "all parts", no "Part" subfolders will be created.

A suggested bypass, if everything else fails: Convert the book part by part, individual invocations. After each part copy the created audio file somewhere else. When all audio files have been created and saved, use an external tool like Mp3Tag to create the playlist.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

Sorry for the delay. I thought it would be better if I uploaded screenshots of the process. Maybe I misunderstood your instructions, or I am unable to relay the results correctly. Here is what happens:

step1
step2
step2b
step3
step4
step5
step6
step7
step8

Additionally, I ran the test with "A Clash of Kings", the second book in the series, which doesn't seem to contain any missing chapters. I get the same:
step6b

Following your suggested bypass makes no difference. I deleted all files created from the steps 1 through 8 demonstration, and tried converting one AAX file at a time. This is what I get:
bypass_step1
bypass_step2

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

Many thanks for the additional input. That should provide enough clues. Apparently, the program enters the internal "some parts" mode and not, as it should, "all parts". I have to find out why. (Independent of the mess with creating "Part" sub-folders and then not using them.)

However, all the four audio files appear to have been created for both books, albeit without a proper playlist. Or are the m4a files empty, too?

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

I think I have now been able to kind of reproduce your result. As I said before, AAX Audio converter is entering its internal "some parts" processing mode here. This is the only mode that can create "Part" sub-folders. When the program detects "Part" (or any custom equivalent) in the book title it extracts the part number. For a multiple select conversion it tries to find out whether all parts are present. For this it needs the highest part number and then checks whether part numbers start with 1 and are consecutive. The current implementation src/AaxAudioConverterLib/Book.cs, CheckParts (), line 73 onward, has two flaws here. It sorts the parts by file path but should do it by file title. Then it assumes that the last part has the highest part number. This only works if the file path names reflect the part number order. In almost every case they do. But presumably in your example they don't.

What you can try is to rename your aax files

A_Game_of_Thrones_Part_1.aax
A_Game_of_Thrones_Part_2.aax
A_Game_of_Thrones_Part_3.aax
A_Game_of_Thrones_Part_4.aax

(all in the same folder, of course) and then try again. This will either prove me right or wrong. 😎

I will make two changes: sort by book title (from the embedded tags) and also explicitly search for the highest part number in all parts. Any of the two modifications should solve it.

I will also adjust the "Part" sub-folder creation policy. For "Single file" mode they will only be created if the "extra meta files" option is set, and then the single audio files also go into the "Part" sub-folder. An (empty) playlist will no longer be created.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

I can confirm, renaming the AAX files as you suggested gives the expected results: 4 M4A files and 1 M3U file all in the same level. The M3U contains the proper list of M4A files.

It sorts the parts by file path but should do it by file title. Then it assumes that the last part has the highest part number. This only works if the file path names reflect the part number order. In almost every case they do. But presumably in your example they don't.

Exactly. In most of these ASOIAF books, the filename cuts off the word "Part". "A Game of Thrones" has "Pa", and "A Clash of Kings" at "Par", to give a couple of examples.

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

Excellent, thanks a lot.

The aax file naming scheme is different for downloading via the Audible Download Helper or the Audible App. With the Download Helper, they are never cut short, apparently. Anyway, for the next version of this program, which is supposed to support named chapters, the Audible App file names must stay untouched. Because the cryptic part in it - presumably a hash across user and book id - is the key to the separate meta file which has the chapter names.

from aaxaudioconverter.

audiamus avatar audiamus commented on July 16, 2024

Fixed in version 1.7.

from aaxaudioconverter.

Squaredude avatar Squaredude commented on July 16, 2024

I'm sorry for taking so long, but I only just now got to try out the newer versions. I can confirm, the program is now extracting all chapters correctly, and also using the chapter titles. Thanks a lot for your hard work!

from aaxaudioconverter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.