mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-01-13 22:30:37 +08:00
translated
This commit is contained in:
parent
15dcfa0ed0
commit
433775e1cc
@ -1,90 +0,0 @@
|
||||
[#]: subject: "Convert audio in batches on Linux with SoundConverter"
|
||||
[#]: via: "https://opensource.com/article/21/12/soundconverter-linux"
|
||||
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
|
||||
[#]: collector: "lujun9972"
|
||||
[#]: translator: "geekpi"
|
||||
[#]: reviewer: " "
|
||||
[#]: publisher: " "
|
||||
[#]: url: " "
|
||||
|
||||
Convert audio in batches on Linux with SoundConverter
|
||||
======
|
||||
SoundConverter is a useful application not just because it does exactly
|
||||
what its name says it does, but because it does it in batches and in
|
||||
parallel.
|
||||
![radio communication signals][1]
|
||||
|
||||
There are many file formats used to store digital audio, and they're good for different purposes. Digital audio is, of course, only a representation of sound, a rendering of soundwaves that get translated into sound by a decoder and a set of speakers. Some audio formats, generically called _lossless_ formats, aim to encode audio close to its original analog form. Still, there's a lot of data in the real world, and as yet, digital can only approximate it in very large files. Other audio formats, called _lossy_ formats, balance file size with a reasonable representation of sound.
|
||||
|
||||
There are plenty of great terminal commands for audio conversion. There's `sox` and `ffmpeg` and a handful of format-specific encoders, like `opusenc`, `flac`, `oggenc`, `fdkaac`, `wavpack`, and countless others.
|
||||
|
||||
### Install SoundConverter on Linux
|
||||
|
||||
SoundConverter is available on most Linux distributions from your package manager. On Fedora, Mageia, and similar distributions:
|
||||
|
||||
|
||||
```
|
||||
`$ sudo dnf install kdenlive`
|
||||
```
|
||||
|
||||
On Elementary, Mint, and other Debian-based distributions:
|
||||
|
||||
|
||||
```
|
||||
`$ sudo apt install kdenlive`
|
||||
```
|
||||
|
||||
However, I use SoundConverter as a [Flatpak][2].
|
||||
|
||||
### Converting audio
|
||||
|
||||
Once you encode audio into a lossy format, you've lost data. Whether that data matters or not depends on the ears of its audience. Some people can't hear the difference between a low-bitrate MP3 and a full quality FLAC file, and even those who can often don't notice the difference between a 320kbps Ogg Vorbis podcast and a 128 kbps Ogg Vorbis podcast. Converting audio from a compressed format to an uncompressed format doesn't recover lost data, but it's not uncommon to need to convert audio from one format to another. You might want to upload a file to a website that accepts only a specific format, or your mobile device might only play a specific format, or to email a file that's too large for your host, or you might just want to save space on your drive.
|
||||
|
||||
SoundConverter lets you convert audio in batches with ease. To convert audio with SoundConverter:
|
||||
|
||||
1. Launch SoundConverter from your Applications or Activities menu.
|
||||
2. Click the **Add Files** button in the top left corner of the SoundConverter window, and select the files you want to convert.
|
||||
3. Once you've added files, click the **Preferences** button (the gear icon) in the top right corner of the window, and select the format you want to convert to. You can also set the file naming convention, the destination folder, and other options.
|
||||
4. When you're ready, click the **Convert** button in the top left corner.
|
||||
|
||||
|
||||
|
||||
![SoundConverter window][3]
|
||||
|
||||
(Seth Kenlon, [CC BY-SA 4.0][4])
|
||||
|
||||
### Parallel processing
|
||||
|
||||
SoundConverter is a useful application not just because it does exactly what its name says it does, but because it does it in batches and in parallel. Because modern computers have more than just CPU core, it's a waste of power and time to place each file in a queue to encode them one by one. SoundConverter can take several files at once and encode them simultaneously, meaning that converting 12 files can take the same time it would normally take to convert two—one after the other. You can do the same thing with a good terminal command, but only if you understand how to [launch parallel processes][5].
|
||||
|
||||
![SoundConverter preferences][6]
|
||||
|
||||
(Seth Kenlon, [CC BY-SA 4.0][4])
|
||||
|
||||
You can also convert stereo audio into mono files. This can be especially useful for podcasts and audiobooks. These usually consist of a person speaking from a singular location (the microphone) and don't require a sense of spatial location. In fact, reducing stereo files to mono makes the audio easier to hear should you have just one earbud and cuts the file size in half.
|
||||
|
||||
### The SoundConverter advantage
|
||||
|
||||
It's a great feature to have different file formats for audio, and yet it seems that whenever I've saved audio in one format, I inevitably need it in another format. There are several great Linux commands to [convert audio files][7], but sometimes you might want an application you can leave open on your desktop and drag and drop files to, and so there's [SoundConverter][8]. A simple, single-purpose application, SoundConverter does exactly, and only, what its name says: It converts sound from one format to another.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/21/12/soundconverter-linux
|
||||
|
||||
作者:[Seth Kenlon][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/seth
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/sound-radio-noise-communication.png?itok=KMNn9QrZ (radio communication signals)
|
||||
[2]: https://opensource.com/article/21/11/install-flatpak-linux
|
||||
[3]: https://opensource.com/sites/default/files/uploads/soundconverter_0.jpg (SoundConverter window)
|
||||
[4]: https://creativecommons.org/licenses/by-sa/4.0/
|
||||
[5]: https://opensource.com/article/18/5/gnu-parallel
|
||||
[6]: https://opensource.com/sites/default/files/uploads/soundconvert-preferences.jpg (SoundConverter preferences)
|
||||
[7]: https://opensource.com/article/17/6/ffmpeg-convert-media-file-formats
|
||||
[8]: https://soundconverter.org/
|
@ -0,0 +1,88 @@
|
||||
[#]: subject: "Convert audio in batches on Linux with SoundConverter"
|
||||
[#]: via: "https://opensource.com/article/21/12/soundconverter-linux"
|
||||
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
|
||||
[#]: collector: "lujun9972"
|
||||
[#]: translator: "geekpi"
|
||||
[#]: reviewer: " "
|
||||
[#]: publisher: " "
|
||||
[#]: url: " "
|
||||
|
||||
在 Linux 上用 SoundConverter 分批转换音频
|
||||
======
|
||||
SoundConverter 是一个有用的应用,不仅因为它能做到它的名字所说的那样,而且因为它是分批和并行地做的。
|
||||
![radio communication signals][1]
|
||||
|
||||
有许多文件格式用于存储数字音频,它们适用于不同的目的。当然,数字音频只是声音的一种表现形式,是由解码器和一组扬声器将声波转化为声音的一种渲染。一些音频格式,一般被称为无损格式,旨在将音频编码接近其原始模拟形式。然而,在现实世界中有大量的数据,到目前为止,数字只能在非常大的文件中接近它。其他的音频格式,被称_有损_格式,在文件大小与声音的合理表现之间取得平衡。
|
||||
|
||||
有很多很好的终端命令用于音频转换。有 `sox` 和 `ffmpeg` 以及一些特定格式的编码器,如 `opusenc`、`flac`、`oggenc`、`fdkaac`、`wavpack` 和无数的其他编码器。
|
||||
|
||||
### 在 Linux 上安装 SoundConverter
|
||||
|
||||
SoundConverter 在大多数 Linux 发行版上都可以通过你的包管理器获得。在 Fedora、Mageia 和类似的发行版上:
|
||||
|
||||
|
||||
```
|
||||
`$ sudo dnf install kdenlive`
|
||||
```
|
||||
|
||||
在 Elementary、Mint 和其他基于 Debian 的发行版上:
|
||||
|
||||
|
||||
```
|
||||
`$ sudo apt install kdenlive`
|
||||
```
|
||||
|
||||
然而,我使用使用 [Flatpak][2] 安装 SoundConverter。
|
||||
|
||||
### 转换音频
|
||||
|
||||
一旦你把音频编码成有损格式,你就丢失了数据。这些数据是否重要取决于其听众的耳朵。有些人听不出低比特率的 MP3 和全质量的 FLAC 文件之间的区别,即使那些能听出来的人,也常常注意不到 320kbps 的 Ogg Vorbis 播客和 128kbps 的 Ogg Vorbis 播客之间的区别。将音频从压缩格式转换为非压缩格式并不能恢复丢失的数据,但需要将音频从一种格式转换为另一种格式的情况并不少见。你可能想把文件上传到只接受特定格式的网站,或者你的移动设备可能只播放特定的格式,或者用电子邮件发送一个对你的主机来说太大的文件,或者你可能只是想节省硬盘上的空间。
|
||||
|
||||
SoundConverter 可以让你轻松地分批转换音频。要用 SoundConverter 转换音频:
|
||||
|
||||
1. 从你的应用或活动菜单中启动 SoundConverter。
|
||||
2. 点击 SoundConverter 窗口左上角的**添加文件**按钮,并选择你要转换的文件。
|
||||
3. 添加了文件后,点击窗口右上角的**偏好**按钮(齿轮图标),并选择你想转换的格式。你还可以设置文件命名规则、目标文件夹和其他选项。
|
||||
4. 当你准备好了,点击左上角的**转换**按钮。
|
||||
|
||||
|
||||
|
||||
![SoundConverter window][3]
|
||||
|
||||
(Seth Kenlon, [CC BY-SA 4.0][4])
|
||||
|
||||
### 并行处理
|
||||
|
||||
SoundConverter 是一个有用的应用,不仅因为它完全做了它的名字所说的事情,而且因为它是分批和并行地做的。因为现代计算机不仅仅有一个 CPU 核心,把每个文件放在一个队列中逐一编码,是对能量和时间的浪费。SoundConverter 可以同时处理几个文件,并对它们进行编码,这意味着转换 12 个文件所需的时间和通常转换两个文件所需的时间是一样的,一个接一个。你可以用一个好的终端命令做同样的事情,但前提是你要了解如何[启动并行进程][5]。
|
||||
|
||||
![SoundConverter preferences][6]
|
||||
|
||||
(Seth Kenlon, [CC BY-SA 4.0][4])
|
||||
|
||||
你也可以将立体声音频转换为单声道文件。这对播客和有声读物特别有用。这些通常由一个人从一个单一的位置(麦克风)说话组成,不需要空间位置感。事实上,将立体声文件减少到单声道,如果你只有一个耳塞,就能更容易听到音频,并将文件大小减半。
|
||||
|
||||
### SoundConverter 的优势
|
||||
|
||||
为音频提供不同的文件格式是一个很好的功能,但似乎每当我以一种格式保存音频时,我都不可避免地需要另一种格式。有几个很棒的 Linux 命令可以[转换音频文件][7],但有时你可能想要一个可以在桌面上打开并拖放文件的应用,于是有了 [SoundConverter][8]。SoundConverter 是一个简单的、用途单一的应用程序,它的作用和它的名字一样:把声音从一种格式转换为另一种格式。
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/21/12/soundconverter-linux
|
||||
|
||||
作者:[Seth Kenlon][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[geekpi](https://github.com/geekpi)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/seth
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/sound-radio-noise-communication.png?itok=KMNn9QrZ (radio communication signals)
|
||||
[2]: https://opensource.com/article/21/11/install-flatpak-linux
|
||||
[3]: https://opensource.com/sites/default/files/uploads/soundconverter_0.jpg (SoundConverter window)
|
||||
[4]: https://creativecommons.org/licenses/by-sa/4.0/
|
||||
[5]: https://opensource.com/article/18/5/gnu-parallel
|
||||
[6]: https://opensource.com/sites/default/files/uploads/soundconvert-preferences.jpg (SoundConverter preferences)
|
||||
[7]: https://opensource.com/article/17/6/ffmpeg-convert-media-file-formats
|
||||
[8]: https://soundconverter.org/
|
Loading…
Reference in New Issue
Block a user