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

Commit 2b095d9c authored by Harish Mahendrakar's avatar Harish Mahendrakar
Browse files

codec2: Queue ROI info buffer for surface mode

When running in surface mode, RoI info buffer is sent in a work
item with no input buffers to the encoder.

Bug: 325549730
Bug: 299191092
Test: Build

Change-Id: I915cf9bd4669c9f7d1c818b3fe35b66110862b42
parent 91e28a3e
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
@@ -2784,7 +2784,16 @@ void CCodecBufferChannel::resetBuffersPixelFormat(bool isEncoder) {
}

void CCodecBufferChannel::setInfoBuffer(const std::shared_ptr<C2InfoBuffer> &buffer) {
    if (mInputSurface == nullptr) {
        mInfoBuffers.push_back(buffer);
    } else {
        std::list<std::unique_ptr<C2Work>> items;
        std::unique_ptr<C2Work> work(new C2Work);
        work->input.infoBuffers.emplace_back(*buffer);
        work->worklets.emplace_back(new C2Worklet);
        items.push_back(std::move(work));
        c2_status_t err = mComponent->queue(&items);
    }
}

status_t toStatusT(c2_status_t c2s, c2_operation_t c2op) {