summaryrefslogtreecommitdiffstats
path: root/core/jni
diff options
context:
space:
mode:
authorMathias Agopian <mathias@google.com>2011-11-10 14:34:26 -0800
committerMathias Agopian <mathias@google.com>2011-11-11 18:44:35 -0800
commitb89d88f531ee39927f8f554baaae5ecc9101ba9d (patch)
treec00601c0b328a2670e449a3afb296bd7ea30eadd /core/jni
parentc51bb4d394dd47e48abc8a6d9cbc740f821546ff (diff)
downloadframeworks_base-b89d88f531ee39927f8f554baaae5ecc9101ba9d.zip
frameworks_base-b89d88f531ee39927f8f554baaae5ecc9101ba9d.tar.gz
frameworks_base-b89d88f531ee39927f8f554baaae5ecc9101ba9d.tar.bz2
Define, document, and test the behavior of very large SurfaceTextures
updateTexImage() now throws a runtime exception when its native counterpart fails Bug: 5506633 Change-Id: I151a6f685d465966e7df4df624412ab2da62e95f
Diffstat (limited to 'core/jni')
-rw-r--r--core/jni/android/graphics/SurfaceTexture.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/jni/android/graphics/SurfaceTexture.cpp b/core/jni/android/graphics/SurfaceTexture.cpp
index ffcd1a0..de2d8c4 100644
--- a/core/jni/android/graphics/SurfaceTexture.cpp
+++ b/core/jni/android/graphics/SurfaceTexture.cpp
@@ -212,10 +212,10 @@ static void SurfaceTexture_setDefaultBufferSize(
surfaceTexture->setDefaultBufferSize(width, height);
}
-static void SurfaceTexture_updateTexImage(JNIEnv* env, jobject thiz)
+static jint SurfaceTexture_updateTexImage(JNIEnv* env, jobject thiz)
{
sp<SurfaceTexture> surfaceTexture(SurfaceTexture_getSurfaceTexture(env, thiz));
- surfaceTexture->updateTexImage();
+ return surfaceTexture->updateTexImage();
}
static void SurfaceTexture_getTransformMatrix(JNIEnv* env, jobject thiz,
@@ -246,7 +246,7 @@ static JNINativeMethod gSurfaceTextureMethods[] = {
{"nativeInit", "(ILjava/lang/Object;Z)V", (void*)SurfaceTexture_init },
{"nativeFinalize", "()V", (void*)SurfaceTexture_finalize },
{"nativeSetDefaultBufferSize", "(II)V", (void*)SurfaceTexture_setDefaultBufferSize },
- {"nativeUpdateTexImage", "()V", (void*)SurfaceTexture_updateTexImage },
+ {"nativeUpdateTexImage", "()I", (void*)SurfaceTexture_updateTexImage },
{"nativeGetTransformMatrix", "([F)V", (void*)SurfaceTexture_getTransformMatrix },
{"nativeGetTimestamp", "()J", (void*)SurfaceTexture_getTimestamp },
{"nativeRelease", "()V", (void*)SurfaceTexture_release },