Win a copy of Android Programming: The Big Nerd Ranch Guide this week in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

executing ffmpeg from android application  RSS feed

 
Jim Harrison
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I have the ffmpeg built on Ubuntu for the ARM architecture. When I do the unix file command I get the following output:

ffmpeg: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), stripped

Via cygwin, I've chmod 777 the ffmpeg

I've copied it into my eclipse (running on Win7 Pro) project under the assets folder and verify that it is in the apk (via jar -tvf command)

2284760 Tue Jul 23 16:34:18 EDT 2013 assets/ffmpeg

I'm using


When I run it on my non-rooted Nexus 10 I get the following output:



A couple of concerns:

1. I'm not sure if everything for the executable is there: the "file" commands states it uses shared libraries (which I'm assuming it comes from the build I did).
2. Is it correct to put the executable in the assets? In other words if I created a standalone executable for the ARM architecture to print "Hello World", is that the correct place?
3. Is the binary permission set for execute?

Any help/direction would be appreciated.

Thanks,
Jim


 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not certain one way or the other, but I very much doubt that you can execute native apps that are part of APKs. A better approach would be to use the NDK to build an app that calls those methods of ffmpeg that you need via JNI.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!