Trying to write a camera app where I can have a custom filter applied at runtime, currently sdk offer stuff such as greyscale, sephia etc and it's as simple as setting a parameter.
However I need to apply our own custom filter (where I would edit some pixels value)to both still images and videos, it shouldnt matter as the concept is the same. I managed to do this in iOS using opengles
, I was hoping if the same could be done on android.
The approach we tried so far is using sdk and applying a simple grey scale filter in a frame by frame basis, however the camera preview was much much slower (much lower fps) as probably it should be done at a lower level ndk or opengles.
OpenCV for Android is what you are looking for :)
http://opencv.org/platforms/android.html
If you want to further improve the performance, you can use NDK to compile your C/C++ code to make it run on the Android device. There are many samples of how to use openCv camera or Android native camera to do image/video manipulation.
OpenGL is fully functional and fast on Android. You can probably reuse much of your iOS code.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.