There is no real support for C code within Android at this time. If you have a very complicated algorithm I would suggest one of two things.
1: Since Android is supposed to be the new generation of internet connected phones you could do the C work on a server. This has advantages and disadvantages. One of the advantages is you can do whatever work you want in whatever language you want and just return it. A disadvantage is you're reliant on the network access. In a biometric application this could be a dealbreaker, but you'll have to evaluate that on your own. 2: Even complicated algorithms can be easily "translated" to another programming language. You can move each line one at a time. Since C and Java are similar in a lot of ways, you shouldn't need much infrastructure change to do this. You can also translate the whole thing into pseudo code. This, for me, is a good way as once I have the pseudo code I can write a duplicate of the program in any language with minimal effort. Now, obviously, neither of these are ideal, but unfortunately C code is not supported and hopefully never will be. Remember the original palm devices? They were stuck with an inferior processor for a long time, as others went to ARM and other chips they were stuck on the slower chip family they started with. This was because of the software that existed out there. Even once they moved on to newer chips they had to emulate the old chip. This is impossible with Android because OHA/Google can't control what devices will ship with Android and therefor can't possibly predict what chips will need emulation. Instead they've chosen an interpreted language that it's the OEM's responsibility to get working on their hardware. Once they've done that, it will run ALL Android software without any more mangling. A distinct advantage, and one that means eventually Android will have to win, as no other competitor can really match that feature. (True WinMo can run Java, but not easily and not well. Besides, we all know how WinMo has done in this whole phone race thing.) On Oct 2, 3:49 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Hello buddies!! > I'm involved in a biometric project. I need to write an app for > Android that must use an algorithm writen in C language. This C code > is very complex and for this reason translating this code into java is > not an option. The idea is to develop the main application in java > code and this would "call" to the algorithm somehow, so the algorithm > could return a value for the main app. I know there are some libs > writen in C/C++ and I'm wondering if I could do so for my project, > write my own lib and call it from the main app. But I don't know if it > is possible, how to do it, how to compile my C code for Android and so > on. > To help the algorithm is writen in C and is compiled for Linux. > Could anyone lead me through the darkness? > Thanks mates. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---