tags:

views:

39

answers:

2

I want to make an app that downloads a specific MP3 file, allow the user to crop/trim it and re-upload it back to our server. How can I trim MP3 files inside my app ? Do I need to achieve this in C and then port it/use NDK ? If MP3 is tough, I can switch over to other easy formats too.

Will be great if anyone can show me the right path.

A: 

I think of all the alternatives, using something like LAME and compiling for the NDK is your best option. Be warned that there are patent restrictions on the MP3 format (most of which I don't understand), and you may run into problems if you distribute your app. YMMV

Quartz
Thanks. Any other music format that you can think of which doesn't get me into any sort of licensing issues ?
vikikivi
Ogg Vorbis or WAV should be fine. There are probably a few more, but those are the most common.
Quartz
A: 

I didn't test it on Android yet, but there is a pure Java MP3 decoder / player I wrote a while ago. Maybe you can use parts of it. The code is based on JLayer from JavaZoom (also LGPL).

Thomas Mueller