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

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

Merge "audio_policy: Add support for HDMI passthrough to APM"

parents 7b9dd431 c3b1d327
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -120,6 +120,10 @@ ifeq ($(strip $(DOLBY_DAP)),true)
    endif
endif #DOLBY_END

ifeq ($(strip $(AUDIO_FEATURE_ENABLED_HDMI_PASSTHROUGH)),true)
    LOCAL_CFLAGS += -DHDMI_PASSTHROUGH_ENABLED
endif

LOCAL_MODULE:= libaudiopolicymanagerdefault

include $(BUILD_SHARED_LIBRARY)
+571 −10

File changed.

Preview size limit exceeded, changes collapsed.

+24 −0
Original line number Diff line number Diff line
@@ -821,6 +821,30 @@ protected:
        uint32_t        mTestLatencyMs;
#endif //AUDIO_POLICY_TEST

#ifdef HDMI_PASSTHROUGH_ENABLED
        void checkAndSuspendOutputs();
        void checkAndRestoreOutputs();
        audio_devices_t handleHDMIPassthrough(audio_devices_t device,
                         audio_io_handle_t output,
                         int stream = -1,
                         int strategy = -1);
        audio_io_handle_t getPassthroughOutput(
                                    audio_stream_type_t stream,
                                    uint32_t samplingRate,
                                    audio_format_t format,
                                    audio_channel_mask_t channelMask,
                                    audio_output_flags_t flags,
                                    const audio_offload_info_t *offloadInfo,
                                    audio_devices_t device);
        bool isEffectEnabled();
        void closeOffloadOutputs();
        void updateAndCloseOutputs();
        bool isHDMIPassthroughEnabled();
#endif
        uint32_t mPrimarySuspended;
        uint32_t mFastSuspended;
        uint32_t mMultiChannelSuspended;

        // returns true if given output is direct output
        bool isDirectOutput(audio_io_handle_t output);
        //parameter indicates of HDMI speakers disabled