[FFmpeg-user] Audio transcoding with metadata and album cover image
Lukas Österreicher
lukas.oesterreicher at inode.at
Thu Apr 11 10:45:26 CEST 2013
> Hi Lukas!
> Lukas Österreicher <lukas.oesterreicher <at> inode.at> writes:
>> $ ffmpeg -i 150.mp3 -i 150.jpg -c:a libaacplus -b:a 48k
>> -map 0 -map 1 -metadata:s:v title="track title"
>> -metadata:s:v author="artist name" 150_encoded.m4a
>> Stream mapping:
>> Stream #0:0 -> #0:0 (mp3 -> libaacplus)
>> Stream #1:0 -> #0:1 (mjpeg -> ?)
> FFmpeg does not know what to do with your jpeg,
> specify either "-vcodec copy" (if jpeg is ok),
> or "-vcodec png" (if you prefer a png for some
> reason).
> Please do not top-post on this mailing list.
> Carl Eugen
Sorry, was just so used to put the most recent on top in other emails.
Thanx for the help, however -vcodec does not help. I tried both
with copy and with png, but it does not work:
morkeleb at morkeleb-VirtualBox:~/Music$ ffmpeg -i 150.mp3 -i 150.jpg -c:a libaacplus -b:a 48k -map 0 -map 1 -vcodec png -metadata:s:v title="track title" -metadata:s:v author="artist name" 150_encoded.m4a
ffmpeg version N-51694-g4e0130f Copyright (c) 2000-2013 the FFmpeg developers
built on Apr 10 2013 16:12:06 with gcc 4.7 (Ubuntu/Linaro 4.7.2-2ubuntu1)
configuration: --enable-gpl --enable-libaacplus --enable-libmp3lame --enable-version3 --enable-nonfree --enable-static
libavutil 52. 25.100 / 52. 25.100
libavcodec 55. 2.100 / 55. 2.100
libavformat 55. 1.100 / 55. 1.100
libavdevice 55. 0.100 / 55. 0.100
libavfilter 3. 49.101 / 3. 49.101
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
[mp3 @ 0xa03d280] max_analyze_duration 5000000 reached at 5015510 microseconds
Input #0, mp3, from '150.mp3':
Metadata:
title : Jesus Gave Me Water
artist : Sam Cooke & The Soul Stirrers
album : Portrait Of A Legend
Duration: 00:02:29.66, start: 0.000000, bitrate: 135 kb/s
Stream #0:0: Audio: mp3, 44100 Hz, stereo, s16p, 135 kb/s
Input #1, image2, from '150.jpg':
Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
Stream #1:0: Video: mjpeg, yuvj420p, 200x200 [SAR 1:1 DAR 1:1], 25 tbr, 25 tbn, 25 tbc
[ipod @ 0xa058b60] track 1: could not find tag, codec not currently supported in container
Output #0, ipod, to '150_encoded.m4a':
Metadata:
title : Jesus Gave Me Water
artist : Sam Cooke & The Soul Stirrers
album : Portrait Of A Legend
encoder : Lavf55.1.100
Stream #0:0: Audio: aac (mp4a / 0x6134706D), 44100 Hz, stereo, s16, 48 kb/s
Stream #0:1: Video: png, rgb24, 200x200 [SAR 1:1 DAR 1:1], q=2-31, 200 kb/s, 90k tbn, 25 tbc
Metadata:
title : track title
author : artist name
Stream mapping:
Stream #0:0 -> #0:0 (mp3 -> libaacplus)
Stream #1:0 -> #0:1 (mjpeg -> png)
Could not write header for output file #0 (incorrect codec parameters ?): Operation not permitted
I know cover images are generally supported in .mp4/mp4/3gp files -
but does ffmpeg support them too?
Or am I still doing something wrong?
More information about the ffmpeg-user
mailing list