April 2015
Beginner to intermediate
494 pages
10h 26m
English
Let's create the native module that will generate our new effect.
jni/ RenderScript.cpp. We will need the following:android/bitmap.h header to manipulate bitmaps.jni.h for JNI strings.RenderScript.h, which is the main RenderScript header file. This is the only one you should need. RenderScript is written in C++ and is defined in the android::RSC namespace.#include <android/bitmap.h> #include <jni.h> #include <RenderScript.h> using namespace android::RSC; ...
... void lockBitmap(JNIEnv* pEnv, jobject pImage, AndroidBitmapInfo* pInfo, uint32_t** pContent) { if ...