Support and General Use > Audio Playback, Database and Playlists

[solved] youtube aac and ffmpeg

<< < (2/4) > >>

Crispin:
I now tried the following formats/containers

*.m4a - ffmpeg name: ipod : Rockbox skips the file when opening
*.mp4 - ffmpeg name: mp4 : Rockbox skips the file when opening
*.rm   - ffmpeg name: rm : Rockbox hangs when trying to play the file

When I rename the Youtube video file to *.mp4 without (de)muxing or converting, Rockbox manages to play the first 15 seconds of the embedded audio stream and then hangs. ffmpeg identifies the container as 'mov,mp4,m4a,3gp,3g2,mj2' but is not able to write such a container.

What's next? Thank you very much!
Crispin

sirdan:
The only appropriate container for aac is mp4 with .mp4 extension. M4a is only for itunes crap.


Crispin.... i discussed your problem just few topics earlier.... You have to optimize mp4 file layout. Mainly put all metadata at the begining of the file.
You can use mp4creator with -optimize parameter. If you are on linux, you can compile it from source archive. Or maybe someone did it already.

Crispin:
Thank you very much, sirdan, that solved my problem.
Sorry for my ignorance earlier, but I could only see you were recommending me some proprietary software.
There is an ubuntu package in the official repos called mpeg4ip-server which contains mp4creator.

My command line for extracting the aac audio from a Youtube video and putting it in a container readable for Rockbox now looks like this:

--- Code: ---ffmpeg -i YoutubeVideo -vn -acodec copy AudioStream.aac && mp4creator AudioStream.aac -O OutputFile.mp4
--- End code ---

Thank you very much, all of you!
Crispin

Dr4pht:
I know this topic is almost 2 years old, but I found it by doing a search and want to add some information. For me, in case I'll forget it (again  ;)) and for others having the same problem like me.

It took me quite some time to figure out, why - following the steps above - Rockbox would play some mp4 files and others not. So here are two additional hints to avoid trouble with converted mp4 files.

1st: mp4creator has modified some of the options commands. So the line of code has to be modified like this:

--- Code: ---ffmpeg -i YoutubeVideo -vn -acodec copy AudioStream.aac && mp4creator AudioStream.aac -optimize OutputFile.mp4
--- End code ---

2nd: Most important after this step is to add some tag information like the song's name and artist, or else Rockbox refuses to play it. (At least on my Sansa Clip+). After adding those information I optimize the file with foobar2000.

With these two steps all converted mp4 files should be playable.

Current version of Rockbox has no problem in playing tagless mp4 files. Please read my additional post below.

saratoga:

--- Quote from: Dr4pht on March 20, 2011, 01:05:51 PM ---2nd: Most important after this step is to add some tag information like the song's name and artist, or else Rockbox refuses to play it. (At least on my Sansa Clip+). After adding those information I optimize the file with foobar2000.

With these two steps all converted mp4 files should be playable.

--- End quote ---

Hmm that shouldn't be needed.  Can you file a bug report with a link to one of these files that doesn't play?

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version