Tiny Core Extensions > TCE 1.x

ffmpeg

<< < (2/2)

mcewanw:
I'm trying to convert some mp4 videos to mp3 (to extract the sound)

I have ffmpeg and lame (tcz) extensions.

Tried, the following:

ffmpeg -i myfile.mp4 -vn -acodec libmp3lame -ab 128000 output.mp3
[apparently that is how someone does it on Puppy Linux; I've still to try on that, but want to use TC!]

and received the following error message:


--- Code: ---FFmpeg version SVN-r18347, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration:  --prefix=/usr/local
  libavutil     50. 3. 0 / 50. 3. 0
  libavcodec    52.25. 0 / 52.25. 0
  libavformat   52.32. 0 / 52.32. 0
  libavdevice   52. 2. 0 / 52. 2. 0
  libswscale     0. 7. 1 /  0. 7. 1
  built on Apr  7 2009 13:48:16, gcc: 4.2.2

Seems stream 1 codec frame rate differs from container frame rate: 60.00 (60/1) -> 30.00 (30/1)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'myfile.mp4':
  Duration: 00:03:05.15, start: 0.000000, bitrate: 440 kb/s
    Stream #0.0(und): Audio: aac, 44100 Hz, stereo, s16
    Stream #0.1(und): Video: h264, yuv420p, 480x360 [PAR 1:1 DAR 4:3], 30 tbr, 30 tbn, 60 tbc
Unknown encoder 'libmp3lame'

--- End code ---

I do have libmp3lame.so in /usr/local/lib

Any ideas why it won't work? Is ffmpeg not compiled to support libmp3lame [I know nothing about ffmpeg compilation]?

alu:
maybe:

ffmpeg -i yourvideofile.mp4 -ab 128k yoursoundfile.mp3 (note: 128k is the bit rate, feel free to change it)

alternatively (with mplayer nogui):

mplayer -vo null -dumpaudio -dumpfile /youraudio.mp3 /yourvideo.mp4

curaga:
The line you tried with ffmpeg would have re-encoded the sound, losing quality. Mplayer used as above only separates the existing stream.

mwhit95:
I have been using ffmpeg too and ran into the same problem with mp3.  Most of the time I am able to use the -acodec copy converting the flv files.   What you might use is the map option to take the audio to a wav file and then convert it with lame.  This is a good webpage that shows ways to do it:

ffmpeg how tohttp://howto-pages.org/ffmpeg/

soundcheck:
Is anybody working on the .devs? (For TC2.2) ;)

Navigation

[0] Message Index

[*] Previous page

Go to full version