Ask Your Question

How to use Aruco in Android?

asked 2018-04-10 02:56:35 -0500

Sellmair gravatar image

Hi, I was not able to find the Aruco package documented here (v.3.4.1)

in the SDK provided here

Is there a way to use the Auroc package for Android?

Thanks in advance :)

edit retag flag offensive close merge delete

3 answers

Sort by ยป oldest newest most voted

answered 2018-12-08 11:53:49 -0500

Sellmair gravatar image

We published packaged .aar builds for opencv android to jcenter. Feel free to use our packages:

dependencies {

  // opencv 3.4.1
  implementation 'com.quickbirdstudios:opencv:3.4.1'

  // opencv 3.4.4 with contribution packages
  implementation 'com.quickbirdstudios:opencv:3.4.4-contrib'
edit flag offensive delete link more


that's a nice attempt, but are you going to maintain that in the future ?

berak gravatar imageberak ( 2018-12-08 20:45:05 -0500 )edit

answered 2018-05-08 05:11:26 -0500

mshabunin gravatar image

Please check build logs from our CI builder: For example: It had built OpenCV Android SDK with contrib successfully.

edit flag offensive delete link more


This post helps. I spent days trying to build opencv contrib for android with no success.

syaifulnizamyahya gravatar imagesyaifulnizamyahya ( 2018-11-11 22:06:00 -0500 )edit

answered 2018-04-10 03:01:56 -0500

berak gravatar image

updated 2018-04-10 03:04:43 -0500

the aruco module is from opencv_contrib , and it's not included in the prebuilt android sdk from SF.

you'll have to download the contrib repo, and rebuild the sdk from src

edit flag offensive delete link more


Hey, thanks for your quick answer! I tried to build from source and tried many things, but it always fails with the output below. Tried build tools version 24.4.1, 25, 27 Tried ndk version 10, 15, 16

[1025/1193] Linking CXX executable bin/hello-android
ninja: build stopped: subcommand failed.
Traceback (most recent call last):
  File "../", line 363, in <module>
Sellmair gravatar imageSellmair ( 2018-04-10 08:32:28 -0500 )edit

I am sorry for opening a duplicate, but could you please give me more information? I used ninja version 1.8.2 if this was your hint?

Sellmair gravatar imageSellmair ( 2018-04-10 08:51:41 -0500 )edit

it did not find it (i dont think the version is a problem)

if youcan just type "ninja" on you cmdline, and it runs, it's all fine, else you have to put it on the PATH or such

berak gravatar imageberak ( 2018-04-10 09:10:37 -0500 )edit

Then ninja looks fine! I would only need to build the jniLib .so files to make it work, as the java code is already generated. Maybe I can find a workaround? I successfully built OpenCV with the contrib module. It only fails for the android_sdk =(

Sellmair gravatar imageSellmair ( 2018-04-10 09:19:02 -0500 )edit

This is my build command:

python ../ --extra_modules_path=/Users/sellmair/0source/opencv/opencv_contrib/modules --ndk_path=/Users/sellmair/Desktop/android-ndk-r15c --sdk_path=/Users/sellmair/Desktop/tools --no_ccache . /Users/sellmair/0source/opencv/opencv/
Sellmair gravatar imageSellmair ( 2018-04-10 09:27:50 -0500 )edit

wait, can you try with an older ndk, like 10 or 12 ? (15 might be too advanced)

berak gravatar imageberak ( 2018-04-10 09:36:31 -0500 )edit

I also tried 10e. I am really frustrated =(

Sellmair gravatar imageSellmair ( 2018-04-10 09:43:29 -0500 )edit

I am trying version 9 now! Hopefully this helps!

Sellmair gravatar imageSellmair ( 2018-04-10 10:10:55 -0500 )edit

Did not work =/

Sellmair gravatar imageSellmair ( 2018-04-10 10:44:47 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2018-04-10 02:56:35 -0500

Seen: 567 times

Last updated: Dec 08 '18