summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramFragmentFixedFunction.java
diff options
context:
space:
mode:
authorLeon Scroggins III <scroggo@google.com>2019-03-26 16:28:41 -0400
committerLeon Scroggins III <scroggo@google.com>2019-03-27 13:39:23 -0400
commit71fae62f5fe03e9f8453ac3880587567ffcf9be6 (patch)
tree2d6c009c2e34eaebd050506048406dd1876a9f02 /rs/java/android/renderscript/ProgramFragmentFixedFunction.java
parentca8aef63766b3193464b8f9b4cde45324a83789a (diff)
Pass Bitmap's native instance to JNI where feasible
Test: CtsGraphicsTestCases, CtsUiRenderingTestCases, CtsRenderscriptTestCases This is significantly faster than passing the Java object down and then calling a JNI method to retrieve the pointer. See https://buganizer.corp.google.com/issues/16656908#comment19 In some cases this changes what used to be native crashes (due to android::BitmapWrapper:assertValid's LOG_ALWAYS_FATAL_IF) into NullPointerExceptions (if a caller used a null Bitmap). In addition: - Remove unnecessary JNIEnv param from toBitmap(jlong) - Change instances of toBitmap(JNIEnv*, jobject) to the above - Replace calls to GraphicsJNI::getSkBitmap() to inline calls to toBitmap/getSkBitmap - make Canvas#nInitRaster @FastNative (FIXME: Could these be @CriticalNative?) Change-Id: I6194097be1b6e6952eba70e1e7052a5a250eed93
Diffstat (limited to 'rs/java/android/renderscript/ProgramFragmentFixedFunction.java')
0 files changed, 0 insertions, 0 deletions