diff options
author | Miao Wang <miaowang@google.com> | 2017-02-24 05:47:35 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-02-24 05:47:35 +0000 |
commit | 76535e88885881d32016709dbae53e96df238291 (patch) | |
tree | 22584e27daf40e7efe62f4e62c2b6c6048b4ed76 /rs/jni/android_renderscript_RenderScript.cpp | |
parent | 3b7643ceed1ee80ad843678b7833393ab66c2f3a (diff) | |
parent | 9017b2563187cc41a005c82e59b378a6ded7f4f9 (diff) |
Merge "Update RenderScript JNI code for Treble"
am: 9017b25631
Change-Id: I0cc281a372ec83d3731a83b0af5cc3a02b259a67
Diffstat (limited to 'rs/jni/android_renderscript_RenderScript.cpp')
-rw-r--r-- | rs/jni/android_renderscript_RenderScript.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/rs/jni/android_renderscript_RenderScript.cpp b/rs/jni/android_renderscript_RenderScript.cpp index af370ff2f630..2300da32d355 100644 --- a/rs/jni/android_renderscript_RenderScript.cpp +++ b/rs/jni/android_renderscript_RenderScript.cpp @@ -35,8 +35,8 @@ #include "android_runtime/android_util_AssetManager.h" #include "android/graphics/GraphicsJNI.h" -#include <rs.h> #include <rsEnv.h> +#include <rsApiStubs.h> #include <gui/Surface.h> #include <gui/GLConsumer.h> #include <android_runtime/android_graphics_SurfaceTexture.h> @@ -1134,7 +1134,7 @@ nElementGetNativeData(JNIEnv *_env, jobject _this, jlong con, jlong id, jintArra // we will pack mType; mKind; mNormalized; mVectorSize; NumSubElements assert(dataSize == 5); - uintptr_t elementData[5]; + uint32_t elementData[5]; rsaElementGetNativeData((RsContext)con, (RsElement)id, elementData, dataSize); for(jint i = 0; i < dataSize; i ++) { @@ -1157,7 +1157,7 @@ nElementGetSubElements(JNIEnv *_env, jobject _this, jlong con, jlong id, uintptr_t *ids = (uintptr_t*)malloc(dataSize * sizeof(uintptr_t)); const char **names = (const char **)malloc(dataSize * sizeof(const char *)); - uint32_t *arraySizes = (uint32_t *)malloc(dataSize * sizeof(uint32_t)); + size_t *arraySizes = (size_t *)malloc(dataSize * sizeof(size_t)); rsaElementGetSubElements((RsContext)con, (RsElement)id, ids, names, arraySizes, (uint32_t)dataSize); |