Updated source codes for book Mastering OpenCV Android Application Programming and it's Chinese edition 《深入OpenCV Android应用开发》.

The book is written by Salil Kapur and Nisarg Thakkar, and translated into Chinese by John Hany. The english edition was first published by Packt Publishin in July, 2015, and the Chinese edition in June, 2016. Many pieces of codes in the book have been deprecated over the time. This repository aims to provide source codes for the latest developing and building tools (Android Studio, Android SDK, NDK and OpenCV) and to achieve the exact functionalities of original codes in the book.


All tests are passed on Windows 10 and Ubuntu 16.04.

For Chp3 and Chp6, configuring native build with CMake in Android Studio is required.

For Chp3, compiling OpenCV Android SDK with opencv_contrib modules on Ubuntu is required.

For Chp7, MNIST dataset is required. A pre-trained SVM classifier is available here. Please copy train-images.idx3-ubyte, train-labels.idx1-ubyte and SVM_MNIST.xml files to root directory of sd-card in your Android device. C++ codes for training and testing SVM and KNN on PC are provided here and here.


Related Posts


The MOAAP updated codes are released under the MIT license.

Copyrights of English edition of MOAAP book including the original source codes belong to Packt Publishing. Copyrights of the Chinese edition belong to Publishing House of Electronics Industry. As translator for the Chinese edition, under the contract with Publishin House of Electronics Industry, I do not own the copyrights of any material in the Chinese edition. I do believe, however, I'm entitled rights to release updated source codes (aka this repository) under an open-source license, since the source codes in this repository do not resemble the original ones in many aspects and I'm not profitting from this project in any form.