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

Commit 430fffce authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Use layered version of graphic buffer allocation calls."

parents 3628f79c 4b2f8180
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -423,9 +423,11 @@ status_t MediaSender::packetizeAccessUnit(
            CHECK_GE(accessUnit->size(), rangeLength);

            sp<GraphicBuffer> grbuf(new GraphicBuffer(
                    rangeOffset + rangeLength, 1, HAL_PIXEL_FORMAT_Y8,
                    GRALLOC_USAGE_HW_VIDEO_ENCODER, rangeOffset + rangeLength,
                    handle, false));
                    rangeOffset + rangeLength /* width */, 1 /* height */,
                    HAL_PIXEL_FORMAT_Y8, 1 /* layerCount */,
                    GRALLOC_USAGE_HW_VIDEO_ENCODER,
                    rangeOffset + rangeLength /* stride */, handle,
                    false /* keepOwnership */));

            err = mHDCP->encryptNative(
                    grbuf, rangeOffset, rangeLength,
+2 −1
Original line number Diff line number Diff line
@@ -221,7 +221,8 @@ status_t Camera3BufferManager::getBufferForStream(int streamId, int streamSetId,
            status_t res = OK;
            buffer.fenceFd = -1;
            buffer.graphicBuffer = mAllocator->createGraphicBuffer(
                    info.width, info.height, info.format, info.combinedUsage, &res);
                    info.width, info.height, info.format, 1 /* layerCount */,
                    info.combinedUsage, &res);
            ALOGV("%s: allocating a new graphic buffer (%dx%d, format 0x%x) %p with handle %p",
                    __FUNCTION__, info.width, info.height, info.format,
                    buffer.graphicBuffer.get(), buffer.graphicBuffer->handle);