diff options
author | Xiaofei Wan <xiaofei.wan@intel.com> | 2014-03-31 14:26:20 +0800 |
---|---|---|
committer | Xiaofei Wan <xiaofei.wan@intel.com> | 2014-03-31 14:40:08 +0800 |
commit | 21e0af987d7baccd5417a2f744d2dd706d85604e (patch) | |
tree | e3365704f32b67c61f8aaa710b0ff34a4f864c82 /rs/java | |
parent | 1e4cad8198056a5e27a7aeb104ceb8ada331eafe (diff) | |
download | frameworks_base-21e0af987d7baccd5417a2f744d2dd706d85604e.zip frameworks_base-21e0af987d7baccd5417a2f744d2dd706d85604e.tar.gz frameworks_base-21e0af987d7baccd5417a2f744d2dd706d85604e.tar.bz2 |
Fix RenderScriptGL setSurfaceTexture problem
rsnContextSetSurfaceTexture() has no implementation in rs-jni, use nContextSetSurface() in setSurfaceTexture().
Change-Id: I066432575c9e74f21ea3a3776628b572b6e31377
Signed-off-by: Xiaofei Wan <xiaofei.wan@intel.com>
Diffstat (limited to 'rs/java')
-rw-r--r-- | rs/java/android/renderscript/RenderScriptGL.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/rs/java/android/renderscript/RenderScriptGL.java b/rs/java/android/renderscript/RenderScriptGL.java index c9cbe3e..d6841c8 100644 --- a/rs/java/android/renderscript/RenderScriptGL.java +++ b/rs/java/android/renderscript/RenderScriptGL.java @@ -232,9 +232,13 @@ public class RenderScriptGL extends RenderScript { validate(); //android.util.Log.v("rs", "set surface " + sur + " w=" + w + ", h=" + h); + Surface s = null; + if (sur != null) { + s = new Surface(sur); + } mWidth = w; mHeight = h; - nContextSetSurfaceTexture(w, h, sur); + nContextSetSurface(w, h, s); } /** |