Loading media/codec2/sfplugin/CCodec.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -1400,6 +1400,10 @@ void CCodec::configure(const sp<AMessage> &msg) { } } if (config->mTunneled) { config->mOutputFormat->setInt32("android._tunneled", 1); } ALOGD("setup formats input: %s", config->mInputFormat->debugString().c_str()); ALOGD("setup formats output: %s", Loading media/codec2/sfplugin/CCodecBufferChannel.cpp +20 −3 Original line number Diff line number Diff line Loading @@ -1358,6 +1358,12 @@ status_t CCodecBufferChannel::start( } } } int32_t tunneled = 0; if (!outputFormat->findInt32("android._tunneled", &tunneled)) { tunneled = 0; } mTunneled = (tunneled != 0); } // Set up pipeline control. This has to be done after mInputBuffers and Loading Loading @@ -1853,11 +1859,22 @@ bool CCodecBufferChannel::handleWork( } } bool drop = false; if (worklet->output.flags & C2FrameData::FLAG_DROP_FRAME) { ALOGV("[%s] onWorkDone: drop buffer but keep metadata", mName); drop = true; } if (notifyClient && !buffer && !flags) { if (mTunneled && drop && outputFormat) { ALOGV("[%s] onWorkDone: Keep tunneled, drop frame with format change (%lld)", mName, work->input.ordinal.frameIndex.peekull()); } else { ALOGV("[%s] onWorkDone: Not reporting output buffer (%lld)", mName, work->input.ordinal.frameIndex.peekull()); notifyClient = false; } } if (buffer) { for (const std::shared_ptr<const C2Info> &info : buffer->info()) { Loading media/codec2/sfplugin/CCodecBufferChannel.h +2 −0 Original line number Diff line number Diff line Loading @@ -323,6 +323,8 @@ private: return mCrypto != nullptr || mDescrambler != nullptr; } std::atomic_bool mSendEncryptedInfoBuffer; std::atomic_bool mTunneled; }; // Conversion of a c2_status_t value to a status_t value may depend on the Loading Loading
media/codec2/sfplugin/CCodec.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -1400,6 +1400,10 @@ void CCodec::configure(const sp<AMessage> &msg) { } } if (config->mTunneled) { config->mOutputFormat->setInt32("android._tunneled", 1); } ALOGD("setup formats input: %s", config->mInputFormat->debugString().c_str()); ALOGD("setup formats output: %s", Loading
media/codec2/sfplugin/CCodecBufferChannel.cpp +20 −3 Original line number Diff line number Diff line Loading @@ -1358,6 +1358,12 @@ status_t CCodecBufferChannel::start( } } } int32_t tunneled = 0; if (!outputFormat->findInt32("android._tunneled", &tunneled)) { tunneled = 0; } mTunneled = (tunneled != 0); } // Set up pipeline control. This has to be done after mInputBuffers and Loading Loading @@ -1853,11 +1859,22 @@ bool CCodecBufferChannel::handleWork( } } bool drop = false; if (worklet->output.flags & C2FrameData::FLAG_DROP_FRAME) { ALOGV("[%s] onWorkDone: drop buffer but keep metadata", mName); drop = true; } if (notifyClient && !buffer && !flags) { if (mTunneled && drop && outputFormat) { ALOGV("[%s] onWorkDone: Keep tunneled, drop frame with format change (%lld)", mName, work->input.ordinal.frameIndex.peekull()); } else { ALOGV("[%s] onWorkDone: Not reporting output buffer (%lld)", mName, work->input.ordinal.frameIndex.peekull()); notifyClient = false; } } if (buffer) { for (const std::shared_ptr<const C2Info> &info : buffer->info()) { Loading
media/codec2/sfplugin/CCodecBufferChannel.h +2 −0 Original line number Diff line number Diff line Loading @@ -323,6 +323,8 @@ private: return mCrypto != nullptr || mDescrambler != nullptr; } std::atomic_bool mSendEncryptedInfoBuffer; std::atomic_bool mTunneled; }; // Conversion of a c2_status_t value to a status_t value may depend on the Loading