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

Commit 2e6eede4 authored by Lajos Molnar's avatar Lajos Molnar Committed by Android Git Automerger
Browse files

am fdb2112b: camera2: limit flexYUV array size in DngCreator

* commit 'fdb2112b':
  camera2: limit flexYUV array size in DngCreator
parents 8ad51b56 fdb2112b
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -530,9 +530,9 @@ public final class DngCreator implements AutoCloseable {
        int uPixStride = uPlane.getPixelStride();

        byte[] yuvPixel = { 0, 0, 0 };
        byte[] yFullRow = new byte[yPixStride * width];
        byte[] uFullRow = new byte[uPixStride * width / 2];
        byte[] vFullRow = new byte[vPixStride * width / 2];
        byte[] yFullRow = new byte[yPixStride * (width - 1) + 1];
        byte[] uFullRow = new byte[uPixStride * (width / 2 - 1) + 1];
        byte[] vFullRow = new byte[vPixStride * (width / 2 - 1) + 1];
        byte[] finalRow = new byte[BYTES_PER_RGB_PIX * width];
        for (int i = 0; i < height; i++) {
            int halfH = i / 2;