summaryrefslogtreecommitdiffstats
path: root/core/jni/android/graphics/Camera.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/jni/android/graphics/Camera.cpp')
-rw-r--r--core/jni/android/graphics/Camera.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/core/jni/android/graphics/Camera.cpp b/core/jni/android/graphics/Camera.cpp
index 9f832b0..d17f46c 100644
--- a/core/jni/android/graphics/Camera.cpp
+++ b/core/jni/android/graphics/Camera.cpp
@@ -3,7 +3,6 @@
#include "SkCamera.h"
-#include "Canvas.h"
#include "GraphicsJNI.h"
static jfieldID gNativeInstanceFieldID;
@@ -96,10 +95,10 @@ static void Camera_getMatrix(JNIEnv* env, jobject obj, jlong matrixHandle) {
}
static void Camera_applyToCanvas(JNIEnv* env, jobject obj, jlong canvasHandle) {
- SkCanvas* canvas = reinterpret_cast<android::Canvas*>(canvasHandle)->getSkCanvas();
+ SkCanvas* native_canvas = GraphicsJNI::getNativeCanvas(canvasHandle);
jlong viewHandle = env->GetLongField(obj, gNativeInstanceFieldID);
Sk3DView* v = reinterpret_cast<Sk3DView*>(viewHandle);
- v->applyToCanvas(canvas);
+ v->applyToCanvas((SkCanvas*)native_canvas);
}
static jfloat Camera_dotWithNormal(JNIEnv* env, jobject obj,