Feeds:
Posts
Comments

Posts Tagged ‘audio’

Introduction to the FLAC Format

The FLAC audio format is so awesome, I still can’t get my head around it! It is lossless, like WAV files, yet often less than half the size. For example, if you had an album at full-quality (320 kbps) in MP3 format (which is lossy, meaning some quality had to be sacrificed), it could well be around 140Mb. Raw, lossless audio in the form of .wav files would on the other hand take up around 1Gb, if not closer to 1.5Gb. The reason .flac files have become so popular is that while being lossless in quality like .wav files, that album would probably only take up about 450Mb – half the size or less, but the same lossless quality.

If you’re quite happy with MP3s and their much-smaller filesize, if you ever end up with an album in FLAC format, you can always convert the tracks down to MP3 with a program like Sound Converter. But what if you get the album as one, long, continuous .flac file? Well, as long as that file also came with a .cue file (which specifies the breaks between tracks), it’s really easy to split it via the command-line, as you’ll see.

How to Split a FLAC Album with CUE File

First off, you need to make sure you have the necessary packages installed, which you can do with the following command:

sudo apt-get install cuetools shntool flac

Once done, you can start splitting the album with a command like the following:

cuebreakpoints album.cue | shnsplit -o flac album.flac

… replacing the word “album” in each case with the correct name. If the 2 files have multiple words with spaces, you’ll have to enclose them in double-quotes, like in the following example:

cuebreakpoints “The Number Of The Beast.cue” | shnsplit -o flac “The Number Of The Beast.flac”

Once that’s done, all you’ll have to do is rename the tracks (unless it doesn’t worry you), and edit the tags (the info you see in your audio player) via Rhythmbox, or a dedicated tag editor.

☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻

Did this information make your day? Did it rescue you from hours of headache? Then please consider making a donation via PayPal, to buy me a donut, beer, or some fish’n’chips for my time and effort! Many thanks!

Buy Ubuntu Genius a Beer to say Thanks!

Advertisements

Read Full Post »

If you’ve upgraded your Ubuntu system to 13.10 and found that you no longer have any sound, you may have noticed in your sound preferences you now only have an audio device called “Dummy Output“. And you can’t change the device to your actual sound card, as it is no longer there (in KDE’s sound preferences, it will probably be listed as a device, yet will be greyed out, meaning you can’t select it). The problem isn’t your sound card, or needing new drivers for it, but a problem with ALSA – and hopefully will be easily fixed with the info in this article.

First, you need to check that your sound card is recognised by running this command in a terminal:

sudo aplay -l

It will then list the devices it finds (in the case of the following output, it finds the built-in audio [which is disabled in the BIOS] as well as the actual sound card I use):

**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: ALC883 Analog [ALC883 Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: Intel [HDA Intel], device 1: ALC883 Digital [ALC883 Digital]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: Audigy2 [SB Audigy 2 ZS [SB0360]], device 0: emu10k1 [ADC Capture/Standard PCM Playback]
card 1: Audigy2 [SB Audigy 2 ZS [SB0360]], device 2: emu10k1 efx [Multichannel Capture/PT Playback]
card 1: Audigy2 [SB Audigy 2 ZS [SB0360]], device 3: emu10k1 [Multichannel Playback]
card 1: Audigy2 [SB Audigy 2 ZS [SB0360]], device 4: p16v [p16v]

If you see something like that, then all should be well, but if you want to make sure, copy and paste this rather lengthy command into the terminal:

echo "Sound cards recognized by the system:"; lspci -nn | grep --color=none '\[04[80][13]\]'; echo "Sound cards recognized by ALSA:"; lspci -nn | grep '\[04[80][13]\]' | while read line; do lspci -nnk | grep -A 3 '\[04[80][13]\]' | grep -e 'Kernel modules: ..*' -e '\[04[80][13]\]' | grep --color=none -F "$line"; done; echo "Sound cards recognized by ALSA, and activated:"; lspci -nn | grep '\[04[80][13]\]' | while read line; do lspci -nnk | grep -A 3 '\[04[80][13]\]' | grep -e 'Kernel drivers in use: ..*' -e '\[04[80][13]\]' | grep --color=none -F "$line"; done

The output should be something like:

Sound cards recognized by the system:
00:1b.0 Audio device [0403]: Intel Corporation 82801I (ICH9 Family) HD Audio Controller [8086:293e] (rev 02)
05:01.0 Multimedia audio controller [0401]: Creative Labs SB Audigy [1102:0004] (rev 04)
Sound cards recognized by ALSA:
00:1b.0 Audio device [0403]: Intel Corporation 82801I (ICH9 Family) HD Audio Controller [8086:293e] (rev 02)
05:01.0 Multimedia audio controller [0401]: Creative Labs SB Audigy [1102:0004] (rev 04)
Sound cards recognized by ALSA, and activated:
00:1b.0 Audio device [0403]: Intel Corporation 82801I (ICH9 Family) HD Audio Controller [8086:293e] (rev 02)
05:01.0 Multimedia audio controller [0401]: Creative Labs SB Audigy [1102:0004] (rev 04)

Once again, everything seems fine, other than the fact you can’t enable your sound card as an audio device. Hopefully, the following command will rectify the situation:

sudo alsa force-reload

You will probably see no change until you reboot, so do so and when you login again, your sound should be back. If it isn’t, you may need to go back into the sound preferences and make the sound card the default audio device, after which all should be well.

☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻

If the problem still persists, you can try the following command which has worked for some (replace “yourusername” with your actual username):

sudo usermod -aG audio,video,pulse,pulse-access yourusername

☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻☻

Did this information make your day? Did it rescue you from hours of headache? Then please consider making a donation via PayPal, to buy me a donut, beer, or some fish’n’chips for my time and effort! Many thanks!

Buy Ubuntu Genius a Beer to say Thanks!

Read Full Post »