Loading audio/core/all-versions/vts/functional/6.0/AudioPrimaryHidlHalTest.cpp +12 −6 Original line number Diff line number Diff line Loading @@ -73,8 +73,11 @@ const std::vector<DeviceConfigParameter>& getOutputDeviceConfigParameters() { getCachedPolicyConfig().getModuleFromName(std::get<PARAM_DEVICE_NAME>(device)); for (const auto& ioProfile : module->getOutputProfiles()) { for (const auto& profile : ioProfile->getAudioProfiles()) { auto configs = ConfigHelper::combineAudioConfig(profile->getChannels(), profile->getSampleRates(), const auto& channels = profile->getChannels(); const auto& sampleRates = profile->getSampleRates(); auto configs = ConfigHelper::combineAudioConfig( vector<audio_channel_mask_t>(channels.begin(), channels.end()), vector<uint32_t>(sampleRates.begin(), sampleRates.end()), profile->getFormat()); auto flags = ioProfile->getFlags(); for (auto& config : configs) { Loading Loading @@ -125,8 +128,11 @@ const std::vector<DeviceConfigParameter>& getInputDeviceConfigParameters() { getCachedPolicyConfig().getModuleFromName(std::get<PARAM_DEVICE_NAME>(device)); for (const auto& ioProfile : module->getInputProfiles()) { for (const auto& profile : ioProfile->getAudioProfiles()) { auto configs = ConfigHelper::combineAudioConfig(profile->getChannels(), profile->getSampleRates(), const auto& channels = profile->getChannels(); const auto& sampleRates = profile->getSampleRates(); auto configs = ConfigHelper::combineAudioConfig( vector<audio_channel_mask_t>(channels.begin(), channels.end()), vector<uint32_t>(sampleRates.begin(), sampleRates.end()), profile->getFormat()); for (const auto& config : configs) { result.emplace_back(device, config, AudioInputFlag(ioProfile->getFlags())); Loading audio/core/all-versions/vts/functional/ConfigHelper.h +2 −2 Original line number Diff line number Diff line Loading @@ -79,8 +79,8 @@ struct ConfigHelper { return {}; } static vector<AudioConfig> combineAudioConfig(android::ChannelMaskSet channelMasks, android::SampleRateSet sampleRates, static vector<AudioConfig> combineAudioConfig(vector<audio_channel_mask_t> channelMasks, vector<uint32_t> sampleRates, audio_format_t format) { vector<AudioConfig> configs; configs.reserve(channelMasks.size() * sampleRates.size()); Loading Loading
audio/core/all-versions/vts/functional/6.0/AudioPrimaryHidlHalTest.cpp +12 −6 Original line number Diff line number Diff line Loading @@ -73,8 +73,11 @@ const std::vector<DeviceConfigParameter>& getOutputDeviceConfigParameters() { getCachedPolicyConfig().getModuleFromName(std::get<PARAM_DEVICE_NAME>(device)); for (const auto& ioProfile : module->getOutputProfiles()) { for (const auto& profile : ioProfile->getAudioProfiles()) { auto configs = ConfigHelper::combineAudioConfig(profile->getChannels(), profile->getSampleRates(), const auto& channels = profile->getChannels(); const auto& sampleRates = profile->getSampleRates(); auto configs = ConfigHelper::combineAudioConfig( vector<audio_channel_mask_t>(channels.begin(), channels.end()), vector<uint32_t>(sampleRates.begin(), sampleRates.end()), profile->getFormat()); auto flags = ioProfile->getFlags(); for (auto& config : configs) { Loading Loading @@ -125,8 +128,11 @@ const std::vector<DeviceConfigParameter>& getInputDeviceConfigParameters() { getCachedPolicyConfig().getModuleFromName(std::get<PARAM_DEVICE_NAME>(device)); for (const auto& ioProfile : module->getInputProfiles()) { for (const auto& profile : ioProfile->getAudioProfiles()) { auto configs = ConfigHelper::combineAudioConfig(profile->getChannels(), profile->getSampleRates(), const auto& channels = profile->getChannels(); const auto& sampleRates = profile->getSampleRates(); auto configs = ConfigHelper::combineAudioConfig( vector<audio_channel_mask_t>(channels.begin(), channels.end()), vector<uint32_t>(sampleRates.begin(), sampleRates.end()), profile->getFormat()); for (const auto& config : configs) { result.emplace_back(device, config, AudioInputFlag(ioProfile->getFlags())); Loading
audio/core/all-versions/vts/functional/ConfigHelper.h +2 −2 Original line number Diff line number Diff line Loading @@ -79,8 +79,8 @@ struct ConfigHelper { return {}; } static vector<AudioConfig> combineAudioConfig(android::ChannelMaskSet channelMasks, android::SampleRateSet sampleRates, static vector<AudioConfig> combineAudioConfig(vector<audio_channel_mask_t> channelMasks, vector<uint32_t> sampleRates, audio_format_t format) { vector<AudioConfig> configs; configs.reserve(channelMasks.size() * sampleRates.size()); Loading