Loading services/audiopolicy/common/managerdefinitions/include/AudioIODescriptorInterface.h +3 −1 Original line number Diff line number Diff line Loading @@ -34,6 +34,8 @@ public: virtual audio_patch_handle_t getPatchHandle() const = 0; virtual void setPatchHandle(audio_patch_handle_t handle) = 0; virtual bool isMmap() = 0; }; template <class IoDescriptor, class Filter> Loading @@ -48,7 +50,7 @@ sp<DeviceDescriptor> findPreferredDevice( // created when the mmap stream is opened). This client is never active. // On non MMAP IOs, the preferred device is honored only if all active clients have // a preferred device in which case the first client drives the selection. if (desc->getPolicyAudioPort()->isMmap()) { if (desc->isMmap()) { // The client list is never empty on a MMAP IO return devices.getDeviceFromId( desc->clientsList(false /*activeOnly*/)[0]->preferredDeviceId()); Loading services/audiopolicy/common/managerdefinitions/include/AudioInputDescriptor.h +6 −0 Original line number Diff line number Diff line Loading @@ -92,6 +92,12 @@ public: audio_config_base_t getConfig() const override; audio_patch_handle_t getPatchHandle() const override; void setPatchHandle(audio_patch_handle_t handle) override; bool isMmap() override { if (getPolicyAudioPort() != nullptr) { return getPolicyAudioPort()->isMmap(); } return false; } status_t open(const audio_config_t *config, const sp<DeviceDescriptor> &device, Loading services/audiopolicy/common/managerdefinitions/include/AudioOutputDescriptor.h +6 −0 Original line number Diff line number Diff line Loading @@ -268,6 +268,12 @@ public: audio_config_base_t getConfig() const override; audio_patch_handle_t getPatchHandle() const override; void setPatchHandle(audio_patch_handle_t handle) override; bool isMmap() override { if (getPolicyAudioPort() != nullptr) { return getPolicyAudioPort()->isMmap(); } return false; } TrackClientVector clientsList(bool activeOnly = false, product_strategy_t strategy = PRODUCT_STRATEGY_NONE, Loading Loading
services/audiopolicy/common/managerdefinitions/include/AudioIODescriptorInterface.h +3 −1 Original line number Diff line number Diff line Loading @@ -34,6 +34,8 @@ public: virtual audio_patch_handle_t getPatchHandle() const = 0; virtual void setPatchHandle(audio_patch_handle_t handle) = 0; virtual bool isMmap() = 0; }; template <class IoDescriptor, class Filter> Loading @@ -48,7 +50,7 @@ sp<DeviceDescriptor> findPreferredDevice( // created when the mmap stream is opened). This client is never active. // On non MMAP IOs, the preferred device is honored only if all active clients have // a preferred device in which case the first client drives the selection. if (desc->getPolicyAudioPort()->isMmap()) { if (desc->isMmap()) { // The client list is never empty on a MMAP IO return devices.getDeviceFromId( desc->clientsList(false /*activeOnly*/)[0]->preferredDeviceId()); Loading
services/audiopolicy/common/managerdefinitions/include/AudioInputDescriptor.h +6 −0 Original line number Diff line number Diff line Loading @@ -92,6 +92,12 @@ public: audio_config_base_t getConfig() const override; audio_patch_handle_t getPatchHandle() const override; void setPatchHandle(audio_patch_handle_t handle) override; bool isMmap() override { if (getPolicyAudioPort() != nullptr) { return getPolicyAudioPort()->isMmap(); } return false; } status_t open(const audio_config_t *config, const sp<DeviceDescriptor> &device, Loading
services/audiopolicy/common/managerdefinitions/include/AudioOutputDescriptor.h +6 −0 Original line number Diff line number Diff line Loading @@ -268,6 +268,12 @@ public: audio_config_base_t getConfig() const override; audio_patch_handle_t getPatchHandle() const override; void setPatchHandle(audio_patch_handle_t handle) override; bool isMmap() override { if (getPolicyAudioPort() != nullptr) { return getPolicyAudioPort()->isMmap(); } return false; } TrackClientVector clientsList(bool activeOnly = false, product_strategy_t strategy = PRODUCT_STRATEGY_NONE, Loading