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

Commit fe62dcaf authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "EffectProxy return the active sub-effect descriptor" into main am:...

Merge "EffectProxy return the active sub-effect descriptor" into main am: 7abcc988 am: 965bdfbc am: 467e03b4

Original change: https://android-review.googlesource.com/c/platform/frameworks/av/+/2668035



Change-Id: I01bd9099d7ee8707afd305a25267db866986486c
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents e909229e 467e03b4
Loading
Loading
Loading
Loading
+8 −2
Original line number Original line Diff line number Diff line
@@ -134,8 +134,8 @@ ndk::ScopedAStatus EffectProxy::close() {
}
}


ndk::ScopedAStatus EffectProxy::getDescriptor(Descriptor* desc) {
ndk::ScopedAStatus EffectProxy::getDescriptor(Descriptor* desc) {
    desc->common = mDescriptorCommon;
    *desc = mSubEffects[mActiveSubIdx].descriptor;
    desc->capability = mSubEffects[mActiveSubIdx].descriptor.capability;
    desc->common.id.uuid = desc->common.id.proxy.value();
    return ndk::ScopedAStatus::ok();
    return ndk::ScopedAStatus::ok();
}
}


@@ -166,6 +166,12 @@ Descriptor::Common EffectProxy::buildDescriptorCommon(
            common.flags.hwAcceleratorMode = Flags::HardwareAccelerator::TUNNEL;
            common.flags.hwAcceleratorMode = Flags::HardwareAccelerator::TUNNEL;
        }
        }


        // initial flag values before we know which sub-effect to active (with setOffloadParam)
        // same as HIDL EffectProxy flags
        common.flags.type = Flags::Type::INSERT;
        common.flags.insert = Flags::Insert::LAST;
        common.flags.volume = Flags::Volume::NONE;

        // set indication if any sub-effect indication was set
        // set indication if any sub-effect indication was set
        common.flags.offloadIndication |= desc.common.flags.offloadIndication;
        common.flags.offloadIndication |= desc.common.flags.offloadIndication;
        common.flags.deviceIndication |= desc.common.flags.deviceIndication;
        common.flags.deviceIndication |= desc.common.flags.deviceIndication;