I've compiled codec2 for Android before, I've wrote Java class to wrap it up to be used in Java.
https://github.com/AhmedObaidi/codec2-android It is very simple to use it within the Java Android // con here work as pointer long con = Codec2.create(Codec2.CODEC2_MODE_1200); int bitsSize = Codec2.getBitsSize(con); int samples = Codec2.getSamplesPerFrame(con) * 2; char[] bits = new char[bitsSize]; Codec2.encode(con,buff, bits); Codec2.decode(con,buff, bits); Codec2.destroy(con); The buffer should be 16 bit PCM with 16000 sample per second. ________________________________ From: "Adcock, Jamison M." <[email protected]> To: "[email protected]" <[email protected]> Sent: Tuesday, August 19, 2014 7:39 AM Subject: [Freetel-codec2] Problems cross-compiling codec2 for Android Hi, I’m trying to cross compile codec2 for Android on an Ubuntu machine, and I’m having problems with cmake. I don’t know if something is screwy with my cmake setup (I grabbed the android-cmake collection of scripts) or if I’m missing something else (I’m using the NDK r9 with a standalone api18 toolchain created by the make-standalone-toolchain.sh script). However, when I run cmake, the output is: $ cmake-android .. -- codec2 version: 0.3 -- Build type is: Release -- Looking for include files HAVE_STDLIB_H -- Looking for include files HAVE_STDLIB_H - found -- Looking for include files HAVE_STRING_H -- Looking for include files HAVE_STRING_H - found -- Looking for floor -- Looking for floor - found -- Looking for ceil -- Looking for ceil - found -- Looking for pow -- Looking for pow - found -- Looking for sqrt -- Looking for sqrt - found -- Looking for sin -- Looking for sin - found -- Looking for cos -- Looking for cos - found -- Looking for atan2 -- Looking for atan2 - found -- Looking for log10 -- Looking for log10 - found -- Looking for round -- Looking for round - found -- Looking for getopt -- Looking for getopt - found -- IMPORT_EXECUTABLES:IMPORTFILE-NOTFOUND CMake Error at src/CMakeLists.txt:87 (INCLUDE): include could not find load file: IMPORTFILE-NOTFOUND -- Configuring incomplete, errors occurred! Apparently, IMPORT_EXECUTABLES gets the value “IMPORTFILE-NOTFOUND”, which causes things to blow up. Has anyone seen this before or know how I can fix it? I have also done cmake to build for Linux, and that appears to work correctly. many thanks, -Jamison Jamison M. Adcock Johns Hopkins University Applied Physics Laboratory 443-778-4676 [email protected] ------------------------------------------------------------------------------ _______________________________________________ Freetel-codec2 mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/freetel-codec2 ------------------------------------------------------------------------------ Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ _______________________________________________ Freetel-codec2 mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/freetel-codec2
