如何以编程方式将两个aac文件合并为一个?

时间:2022-05-07 12:19:09

I'm looking for a cat for aac music files (the stuff iTunes uses).

我正在为aac音乐文件寻找一只猫(iTunes使用的东西)。

Use Case: My father in law will not touch computers except for audiobooks he downloads to his iPod. I have taught him some iTunes (Windows) basics, but his library is a mess. It turns out, that iTunes is optimized for listening to podcasts and random songs from your library, not for audiobooks.

使用案例:除了他下载到iPod上的有声读物外,我的岳父不接触电脑。我教他一些iTunes(Windows)基础知识,但他的图书馆很乱。事实证明,iTunes已经过优化,可以收听您图书馆的播客和随机歌曲,而不是有声读物。

I would like to write a script (preferably python, but comfortable with other stuff too) to import his audiobook cds in a sane fashion, combining the tracks of each cd into a bookmarkable aac file (.m4b?) and then adding that to iTunes so it shows up in the audiobooks section.

我想写一个脚本(最好是python,但也很舒服其他的东西)以一种理智的方式导入他的有声读物CD,将每张CD的曲目组合成一个可收藏的aac文件(.m4b?),然后将其添加到iTunes所以它出现在有声读物部分。

I have figured out how to talk to iTunes (there is a COM interface in Windows, look for the iTunes SDK). Using that interface, I can use iTunes to rip the CD to aac format. It's the actual concatenation of the aac files I'm having trouble with. Can't find the right stuff on the net...

我已经想出如何与iTunes交谈(Windows中有一个COM界面,寻找iTunes SDK)。使用该界面,我可以使用iTunes将CD翻录为aac格式。这是我遇到问题的aac文件的实际连接。在网上找不到合适的东西......

4 个解决方案

#1


I created a freeware program called "Chapter and Verse" to concatenate m4a (AAC) files into a single m4b audiobook file with chapter marks and metadata.

我创建了一个名为“Chapter and Verse”的免费软件程序,将m4a(AAC)文件连接成一个带有章节标记和元数据的m4b有声读物文件。

If you have already ripped the CD's to AAC using itunes (which you say you have) then the rest is easy with my software. I wrote it for this exact reason and scenario. You can download it from www.lodensoftware.com

如果你已经使用itunes(你说你有)将CD翻录到AAC,那么使用我的软件很容易。我是出于这个确切的原因和场景而写的。您可以从www.lodensoftware.com下载

After trying to work with SlideShow Assembler, the QT SDK and a bunch of other command line tools, I ended up building my own application based on the publicly available MP4v2 library. The concatenating of files and adding of chapters is done using the MP4v2 library.

在尝试使用SlideShow Assembler,QT SDK和许多其他命令行工具之后,我最终基于公开的MP4v2库构建了自己的应用程序。使用MP4v2库完成文件的连接和章节的添加。

There are quite a few nuances in building an audiobook properly formatted for the iPod. The information is hard to find. Working with Apple documentation and open libraries has its own challenges as well.

构建适合iPod格式化的有声读物有很多细微差别。这些信息很难找到。使用Apple文档和开放库也有其自身的挑战。

Best of Luck.

最好的运气。

#2


Not programming related (well, kinda.)

不编程相关(好吧,有点。)

iTunes already has functionality to rip as a single track (e.g. an audiobook.) Check this out: http://www.ehow.com/how_2108906_merge-cd-single-track-itunes.html

iTunes已经具有作为单曲(例如有声读物)翻录的功能。请查看:http://www.ehow.com/how_2108906_merge-cd-single-track-itunes.html

That fixes your immediate problem, but I guess people can keep discussing how to do it programatically.

这解决了你当前的问题,但我想人们可以继续讨论如何以编程方式进行。

#3


The most powerful Python audio manipulation module out there seems to be Python Audio Tools. The download comes with CLI tools that would probably do everything you'd want to do, even ripping, so you can even get by with shell scripting the whole thing. The module itself is also pretty powerful and has a handy set of functions to manipulate audio files. If you want to stick with writing everything in python, you can possibly learn enough to do what you want to do after studying their CLI source code. Specifically they have a tool that just does audio file cat in any codec. (They do depend on FAAC/FAAD2 for AAC support, but that'd be true for every library you'll find)

最强大的Python音频处理模块似乎是Python Audio Tools。下载的CLI工具可能会完成你想要做的所有事情,甚至是翻录,所以你甚至可以通过shell脚本完成整个过程。该模块本身也非常强大,并具有一组便于操作音频文件的功能。如果你想坚持在python中编写所有东西,你可以学习足够的东西,在研究它们的CLI源代码后做你想做的事情。具体来说,他们有一个工具,可以在任何编解码器中执行音频文件cat。 (他们确实依赖于FAAC / FAAD2来获得AAC支持,但是对于您找到的每个图书馆都是如此)

#4


I haven't seen an aac codec library for python, but you could use wav files as an intermediary format.

我没有看到python的aac编解码器库,但你可以使用wav文件作为中间格式。

You can pull the tracks off the cd as wav files, and then use the wave module to concatenate them into one large file, which could then be converted by itunes to aac. This may increase your processing time considerably because of the size of the data, but it would be fairly easy, and you don't need any external libraries.

您可以将CD中的轨道作为wav文件拉出,然后使用wave模块将它们连接成一个大文件,然后可以通过itunes将其转换为aac。由于数据的大小,这可能会大大增加您的处理时间,但它相当容易,并且您不需要任何外部库。

#1


I created a freeware program called "Chapter and Verse" to concatenate m4a (AAC) files into a single m4b audiobook file with chapter marks and metadata.

我创建了一个名为“Chapter and Verse”的免费软件程序,将m4a(AAC)文件连接成一个带有章节标记和元数据的m4b有声读物文件。

If you have already ripped the CD's to AAC using itunes (which you say you have) then the rest is easy with my software. I wrote it for this exact reason and scenario. You can download it from www.lodensoftware.com

如果你已经使用itunes(你说你有)将CD翻录到AAC,那么使用我的软件很容易。我是出于这个确切的原因和场景而写的。您可以从www.lodensoftware.com下载

After trying to work with SlideShow Assembler, the QT SDK and a bunch of other command line tools, I ended up building my own application based on the publicly available MP4v2 library. The concatenating of files and adding of chapters is done using the MP4v2 library.

在尝试使用SlideShow Assembler,QT SDK和许多其他命令行工具之后,我最终基于公开的MP4v2库构建了自己的应用程序。使用MP4v2库完成文件的连接和章节的添加。

There are quite a few nuances in building an audiobook properly formatted for the iPod. The information is hard to find. Working with Apple documentation and open libraries has its own challenges as well.

构建适合iPod格式化的有声读物有很多细微差别。这些信息很难找到。使用Apple文档和开放库也有其自身的挑战。

Best of Luck.

最好的运气。

#2


Not programming related (well, kinda.)

不编程相关(好吧,有点。)

iTunes already has functionality to rip as a single track (e.g. an audiobook.) Check this out: http://www.ehow.com/how_2108906_merge-cd-single-track-itunes.html

iTunes已经具有作为单曲(例如有声读物)翻录的功能。请查看:http://www.ehow.com/how_2108906_merge-cd-single-track-itunes.html

That fixes your immediate problem, but I guess people can keep discussing how to do it programatically.

这解决了你当前的问题,但我想人们可以继续讨论如何以编程方式进行。

#3


The most powerful Python audio manipulation module out there seems to be Python Audio Tools. The download comes with CLI tools that would probably do everything you'd want to do, even ripping, so you can even get by with shell scripting the whole thing. The module itself is also pretty powerful and has a handy set of functions to manipulate audio files. If you want to stick with writing everything in python, you can possibly learn enough to do what you want to do after studying their CLI source code. Specifically they have a tool that just does audio file cat in any codec. (They do depend on FAAC/FAAD2 for AAC support, but that'd be true for every library you'll find)

最强大的Python音频处理模块似乎是Python Audio Tools。下载的CLI工具可能会完成你想要做的所有事情,甚至是翻录,所以你甚至可以通过shell脚本完成整个过程。该模块本身也非常强大,并具有一组便于操作音频文件的功能。如果你想坚持在python中编写所有东西,你可以学习足够的东西,在研究它们的CLI源代码后做你想做的事情。具体来说,他们有一个工具,可以在任何编解码器中执行音频文件cat。 (他们确实依赖于FAAC / FAAD2来获得AAC支持,但是对于您找到的每个图书馆都是如此)

#4


I haven't seen an aac codec library for python, but you could use wav files as an intermediary format.

我没有看到python的aac编解码器库,但你可以使用wav文件作为中间格式。

You can pull the tracks off the cd as wav files, and then use the wave module to concatenate them into one large file, which could then be converted by itunes to aac. This may increase your processing time considerably because of the size of the data, but it would be fairly easy, and you don't need any external libraries.

您可以将CD中的轨道作为wav文件拉出,然后使用wave模块将它们连接成一个大文件,然后可以通过itunes将其转换为aac。由于数据的大小,这可能会大大增加您的处理时间,但它相当容易,并且您不需要任何外部库。