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

Commit 60a3c31e authored by Wonsik Kim's avatar Wonsik Kim Committed by Automerger Merge Worker
Browse files

Merge "CCodec: pass video scaling param to CCodecConfig" into main am: cbef7606

parents 6b68eb61 cbef7606
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -2633,6 +2633,15 @@ void CCodec::signalSetParameters(const sp<AMessage> &msg) {
    if (config->mInputSurface == nullptr
            && (property_get_bool("debug.stagefright.ccodec_delayed_params", false)
                    || comp->getName().find("c2.android.") == 0)) {
        std::vector<std::unique_ptr<C2Param>> localConfigUpdate;
        for (const std::unique_ptr<C2Param> &param : configUpdate) {
            if (param && param->coreIndex().coreIndex() == C2StreamSurfaceScalingInfo::CORE_INDEX) {
                localConfigUpdate.push_back(C2Param::Copy(*param));
            }
        }
        if (!localConfigUpdate.empty()) {
            (void)config->setParameters(comp, localConfigUpdate, C2_MAY_BLOCK);
        }
        mChannel->setParameters(configUpdate);
    } else {
        sp<AMessage> outputFormat = config->mOutputFormat;