Конвертируем музыкальные файлы m4a в mp3 в Ubuntu 10.10

Posted by

Сейчас я покажу, как сконвертировать файлы с расширением в для устройств не поддерживающих воспроизведение файлов в формате m4a:

 

Исходные файлы:

keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 — Seemann$ file *
01. Seeman.m4a:                                  ISO Media, MPEG v4 system, iTunes AAC-LC
02. Der Meister.m4a:                             ISO Media, MPEG v4 system, iTunes AAC-LC
03. Rammstein In The House (Timewriter Rmx).m4a: ISO Media, MPEG v4 system, iTunes AAC-LC

Для начала потребуется установить следующие пакеты:
keiz@ekz:~$ aptitude search libmp3lame
p   libmp3lame-dev- An MP3 encoding library (development)
i A libmp3lame0   — An MP3 encoding library

keiz@ekz:~$ aptitude search
i   ffmpeg — multimedia player, server and encoder

keiz@ekz:~$ ffmpeg -V
FFmpeg version 0.6-4:0.6-2ubuntu6.3

Конвертируем в mp3

keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 — Seemann$ ffmpeg -v 5 -y -i 01.\ Seeman.m4a -acodec libmp3lame -ac 2 -ab 320k Seeman.mp3
FFmpeg version 0.6-4:0.6-2ubuntu6.3, Copyright (c) 2000-2010 the FFmpeg developers
built on Dec 21 2011 18:28:03 with gcc 4.4.5
configuration: —extra-version=4:0.6-2ubuntu6.3 —prefix=/usr —enable-avfilter —enable-avfilter-lavf —enable-vdpau —enable-bzlib —enable-libgsm —enable-libschroedinger —enable-libspeex —enable-libtheora —enable-libvorbis —enable-vaapi —enable-pthreads —enable-zlib —enable-libvpx —disable-stripping —enable-runtime-cpudetect —enable-gpl —enable-postproc —enable-x11grab —enable-libdc1394 —enable-shared —disable-static
WARNING: library configuration mismatch
libavutil   configuration: —extra-version=4:0.6-2ubuntu3.3 —prefix=/usr —enable-avfilter —enable-avfilter-lavf —enable-vdpau —enable-bzlib —enable-libdirac —enable-libgsm —enable-libopenjpeg —enable-libschroedinger —enable-libspeex —enable-libtheora —enable-libvorbis —enable-vaapi —enable-pthreads —enable-zlib —enable-libvpx —disable-stripping —enable-runtime-cpudetect —enable-libmp3lame —enable-gpl —enable-postproc —enable-x11grab —enable-libfaad —enable-libxvid —enable-libx264 —enable-librtmp —enable-libdc1394 —enable-shared —disable-static
libavcodec  configuration: —extra-version=4:0.6-2ubuntu3.3 —prefix=/usr —enable-avfilter —enable-avfilter-lavf —enable-vdpau —enable-bzlib —enable-libdirac —enable-libgsm —enable-libopenjpeg —enable-libschroedinger —enable-libspeex —enable-libtheora —enable-libvorbis —enable-vaapi —enable-pthreads —enable-zlib —enable-libvpx —disable-stripping —enable-runtime-cpudetect —enable-libmp3lame —enable-gpl —enable-postproc —enable-x11grab —enable-libfaad —enable-libxvid —enable-libx264 —enable-librtmp —enable-libdc1394 —enable-shared —disable-static
libavutil     50.15. 1 / 50.15. 1
libavcodec    52.72. 2 / 52.72. 2
libavformat   52.64. 2 / 52.64. 2
libavdevice   52. 2. 0 / 52. 2. 0
libavfilter    1.19. 0 /  1.19. 0
libswscale     0.11. 0 /  0.11. 0
libpostproc   51. 2. 0 / 51. 2. 0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from ’01. Seeman.m4a’:
Metadata:
major_brand     : M4A
minor_version   : 0
compatible_brands: M4A mp42isom
album           : Seeman (Single)
artist          : Rammstein
title           : Seeman
track           : 1
date            : 1996
Duration: 00:04:50.16, start: 0.000000, bitrate: 961 kb/s
Stream #0.0(eng): Audio: alac, 44100 Hz, 2 channels, s16, 948 kb/s
Output #0, mp3, to ‘Seeman.mp3’:
Metadata:
TSSE            : Lavf52.64.2
Stream #0.0(eng): Audio: libmp3lame, 44100 Hz, 2 channels, s16, 320 kb/s
Stream mapping:
Stream #0.0 -> #0.0
Press [q] to stop encoding
size=   11336kB time=290.19 bitrate= 320.0kbits/s
video:0kB audio:11336kB global headers:0kB muxing overhead 0.000284%

Смотрим, что получилось:
keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 — Seemann$ file Seeman.mp3
Seeman.mp3: Audio file with ID3 version 2.4.0, contains: MPEG ADTS, layer III, v1, 320 kbps, 44.1 kHz, JntStereo
Результат достигнут. На этом все удачи.

keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 — Seemann$ file *

01. Seeman.m4a: ISO Media, MPEG v4 system, iTunes AAC-LC

02. Der Meister.m4a: ISO Media, MPEG v4 system, iTunes AAC-LC

03. Rammstein In The House (Timewriter Rmx).m4a: ISO Media, MPEG v4 system, iTunes AAC-LC

keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 — Seemann$

Для начала потребуется установить следующие пакеты:

keiz@ekz:~$ aptitude search libmp3lame

p libmp3lame-dev- An MP3 encoding library (development)

i A libmp3lame0 — An MP3 encoding library

keiz@ekz:~$ aptitude search ffmpeg

i ffmpeg — multimedia player, server and encoder

keiz@ekz:~$ ffmpeg -V

FFmpeg version 0.6-4:0.6-2ubuntu6.3

Конвертируем в mp3

keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 - Seemann$ ffmpeg -v 5 -y -i 01.\ Seeman.m4a -acodec libmp3lame -ac 2 -ab 320k Seeman.mp3
FFmpeg version 0.6-4:0.6-2ubuntu6.3, Copyright (c) 2000-2010 the FFmpeg developers
 built on Dec 21 2011 18:28:03 with gcc 4.4.5
 configuration: --extra-version=4:0.6-2ubuntu6.3 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-x11grab --enable-libdc1394 --enable-shared --disable-static
 WARNING: library configuration mismatch
 libavutil configuration: --extra-version=4:0.6-2ubuntu3.3 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libdirac --enable-libgsm --enable-libopenjpeg --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-libmp3lame --enable-gpl --enable-postproc --enable-x11grab --enable-libfaad --enable-libxvid --enable-libx264 --enable-librtmp --enable-libdc1394 --enable-shared --disable-static
 libavcodec configuration: --extra-version=4:0.6-2ubuntu3.3 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libdirac --enable-libgsm --enable-libopenjpeg --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-vaapi --enable-pthreads --enable-zlib --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-libmp3lame --enable-gpl --enable-postproc --enable-x11grab --enable-libfaad --enable-libxvid --enable-libx264 --enable-librtmp --enable-libdc1394 --enable-shared --disable-static
 libavutil 50.15. 1 / 50.15. 1
 libavcodec 52.72. 2 / 52.72. 2
 libavformat 52.64. 2 / 52.64. 2
 libavdevice 52. 2. 0 / 52. 2. 0
 libavfilter 1.19. 0 / 1.19. 0
 libswscale 0.11. 0 / 0.11. 0
 libpostproc 51. 2. 0 / 51. 2. 0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '01. Seeman.m4a':
 Metadata:
 major_brand : M4A 
 minor_version : 0
 compatible_brands: M4A mp42isom
 album : Seeman (Single)
 artist : Rammstein
 title : Seeman
 track : 1
 date : 1996
 Duration: 00:04:50.16, start: 0.000000, bitrate: 961 kb/s
 Stream #0.0(eng): Audio: alac, 44100 Hz, 2 channels, s16, 948 kb/s
Output #0, mp3, to 'Seeman.mp3':
 Metadata:
 TSSE : Lavf52.64.2
 Stream #0.0(eng): Audio: libmp3lame, 44100 Hz, 2 channels, s16, 320 kb/s
Stream mapping:
 Stream #0.0 -> #0.0
Press [q] to stop encoding
size= 11336kB time=290.19 bitrate= 320.0kbits/s 
video:0kB audio:11336kB global headers:0kB muxing overhead 0.000284%
keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 - Seemann$ 

Смотрим, что получилось:
keiz@ekz:~/Музыка/music_v3/Rammstein ALAC/Singles/1996 - Seemann$ file Seeman.mp3 
Seeman.mp3: Audio file with ID3 version 2.4.0, contains: MPEG ADTS, layer III, v1, 320 kbps, 44.1 kHz, JntStereo
Результат достигнут. На этом все удачи.

Leave a Reply

Ваш e-mail не будет опубликован. Обязательные поля помечены *

8 − семь =