Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fcfb518b authored by Tingting Yang's avatar Tingting Yang Committed by Uday Kumar Sundar
Browse files

Fix for skia issue with buffer passed in S32_D565_Blend_Dither_neon.

S32_D565_Blend_Dither_neon works in
chunks and overruns the buffer boundary. Allocating additional 8
bytes to buffer that is passed to the method overcomes this issue.
The buffer allocation is done at the creation of AndroidPixelRef.

CRs-fixed: 568801

Change-Id: I47a643fad9f5a8d1b8a2f3eba9f7f3a99c1ea2a7
parent 25496c2e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -541,7 +541,7 @@ jbyteArray GraphicsJNI::allocateJavaPixelRef(JNIEnv* env, SkBitmap* bitmap,
    }

    size_t size = size64.get32();
    jbyteArray arrayObj = env->NewByteArray(size);
    jbyteArray arrayObj = env->NewByteArray(size + 8);
    if (arrayObj) {
        // TODO: make this work without jniGetNonMovableArrayElements
        jbyte* addr = jniGetNonMovableArrayElements(&env->functions, arrayObj);