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

Commit 908070d0 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "audio_policyhal: SSR support for compress offload"

parents 5231a25c be4392d1
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -2605,6 +2605,17 @@ bool AudioPolicyManager::isOffloadSupported(const audio_offload_info_t& offloadI
        return false;
    }

    // Check for soundcard status
    String8 valueStr = mpClientInterface->getParameters((audio_io_handle_t)0,
                                String8("SND_CARD_STATUS"));
    AudioParameter result = AudioParameter(valueStr);
    int isonline = 0;
    if ((result.getInt(String8("SND_CARD_STATUS"), isonline) == NO_ERROR)
           && !isonline) {
        ALOGD("copl: soundcard is offline rejecting offload request");
        return false;
    }

    // See if there is a profile to support this.
    // AUDIO_DEVICE_NONE
    sp<IOProfile> profile = getProfileForDirectOutput(AUDIO_DEVICE_NONE /*ignore device */,