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

Commit 0029faf8 authored by Andreas Huber's avatar Andreas Huber
Browse files

Don't believe the PV decoder's lies...

Change-Id: I97391235255afb8a4890a4ff52d4e8e9ca954f27
parent 936a981b
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -421,8 +421,13 @@ void SoftMPEG4::onQueueFilled(OMX_U32 portIndex) {

        int32_t bufferSize = inHeader->nFilledLen;

        // The PV decoder is lying to us, sometimes it'll claim to only have
        // consumed a subset of the buffer when it clearly consumed all of it.
        // ignore whatever it says...
        int32_t tmp = bufferSize;

        if (PVDecodeVideoFrame(
                    mHandle, &bitstream, &timestamp, &bufferSize,
                    mHandle, &bitstream, &timestamp, &tmp,
                    &useExtTimestamp,
                    outHeader->pBuffer) != PV_TRUE) {
            LOGE("failed to decode video frame.");