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

Commit 004e7cb0 authored by Roman Kiryanov's avatar Roman Kiryanov
Browse files

Add GraphicBufferMapper::importBufferNoValidate



this will allow camera HALs to avoid using
HandleImporter (which is yet another wrapper
around `Mapper`).

Bug: 251042358
Test: presubmit
Change-Id: I823f98a97f13910b422caafe0009aedf291c9452
Merged-In: I062ba3160fae972757669241fedcaf6ac3c6c12b
Signed-off-by: default avatarRoman Kiryanov <rkir@google.com>
parent d30f8081
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -109,6 +109,11 @@ status_t GraphicBufferMapper::importBuffer(buffer_handle_t rawHandle,
    return NO_ERROR;
}

status_t GraphicBufferMapper::importBufferNoValidate(const native_handle_t* rawHandle,
                                                     buffer_handle_t* outHandle) {
    return mMapper->importBuffer(rawHandle, outHandle);
}

void GraphicBufferMapper::getTransportSize(buffer_handle_t handle,
            uint32_t* outTransportNumFds, uint32_t* outTransportNumInts)
{
+2 −0
Original line number Diff line number Diff line
@@ -59,6 +59,8 @@ public:
            PixelFormat format, uint64_t usage, uint32_t stride,
            buffer_handle_t* outHandle);

    status_t importBufferNoValidate(const native_handle_t* rawHandle, buffer_handle_t* outHandle);

    status_t freeBuffer(buffer_handle_t handle);

    void getTransportSize(buffer_handle_t handle,