after a couple of weeks I have been unable to get the android set of tools to a functioning level with c++ before and have been given the opportunity of using a project tango, and though that sounds awesome and wondrous and would open a world of opportunity for working with VR... I feel like I am stuck at step -4. My understanding is limited, so bear with me.
I stumbled upon the PCL built for running algorithms on point cloud data, it was open source and appeared like a wonderful solution, it is written in C++ and I have a mild understanding of both c++ and java.
I have tried using Eclipse and the NDK and actually managed to get a project 'deployed' to the tango, however upon attempting to edit any file in the project, java or c++, it breaks and will never deploy again.
Now I am trying to use Android Studio, and after following about 5 conflicting tutorials on 'how to get C++/ndk working in android studio' I have yet to get a working environment.
So here is my question, and we can start at step one, any help is appreciated. How does one get c++ and the PCL working on a google project tango, is there a better way for someone of my skill level? The end result is a mapped 3d space with the project tango, with exportable data sets of manageable size. I have seen it done in demos on youtube, but thus far, like i said, I am stuck on step -4.

- 69
- 6
-
I tried like mad with Android Studio, as I know Eclipse and do not relish it's company - I failed miserably and returned to Eclipse - for me, the unsurmountable problem was trying to get Gradle to bring in the Tango shared lib. – Mark Mullin Feb 06 '15 at 21:28
3 Answers
we are working on converting all project to android studio based, for now, here is the walk around to get you started:
Open Android Studio, import the project from the repo you just cloned.
Take the motion-tracking-jni-example as the example, copy tango-gl-render, tango-service-sdk, and third-party into the motion-tracking-jni-example/app/src.
Run ndk-build in the motion-tracking-jni-example/app/src/main folder.
ndk will generate the libs folder, rename it to jniLibs.
Go to Android Studio, in build.gradle(Module:app) file, add line 'sourceSets.main.jni.srcDirs = []' to the defaultConfig section.
Just click the run button in Android Studio.
What we did here is basically disabled the Android Stdio's JNI compile and manually built it using ndk.

- 1,816
- 1
- 11
- 15
-
Thanks for the help, I also found this blog very helpful. [link](http://www.shaneenishry.com/blog/2014/08/17/ndk-with-android-studio/) – Jason Ryan Feb 10 '15 at 18:38
Start with unity3d, its easy to get a working demo with a week with Unity3D. And support is very good, documentation is top notch.
Hope this will help.

- 273
- 2
- 12
Tango NDK Tutorial Will help but the basic layout is
- Setup a new project
- Create your Java activity
- Create a JNI file to bridge Java to the C++
- Create your C++ logic
- Setup your Makefiles and Gradle (probably the most annoying part)

- 1,688
- 1
- 19
- 31