/packages/services/Car/tests/carservice_test/src/com/android/car/audio/ |
D | CarAudioZonesValidatorTest.java | 113 CarVolumeGroup mockVolumeGroup = generateVolumeGroup(List.of("one", "two", "three")); in validate_addressesCanNotRepeatAcrossZones() 115 .withVolumeGroups(new CarVolumeGroup[]{mockVolumeGroup}) in validate_addressesCanNotRepeatAcrossZones() 120 CarVolumeGroup mockSecondaryVolumeGroup = generateVolumeGroup( in validate_addressesCanNotRepeatAcrossZones() 123 .withVolumeGroups(new CarVolumeGroup[]{mockSecondaryVolumeGroup}) in validate_addressesCanNotRepeatAcrossZones() 142 CarVolumeGroup mockVolumeGroup1 = generateVolumeGroup(List.of("one", "two", "three")); in validate_addressesCanNotRepeatAcrossConfigs() 143 CarVolumeGroup mockVolumeGroup2 = generateVolumeGroup(List.of("three", "four", "five")); in validate_addressesCanNotRepeatAcrossConfigs() 145 .withVolumeGroups(new CarVolumeGroup[]{mockVolumeGroup1, mockVolumeGroup2}) in validate_addressesCanNotRepeatAcrossConfigs() 169 CarVolumeGroup mockVolumeGroup1 = generateVolumeGroup(List.of("BT", "two", "three")); in validate_passesWithoutExceptionForRepeatAddressInDifferentConfigs() 170 CarVolumeGroup mockVolumeGroup2 = generateVolumeGroup(List.of("BT", "four", "five")); in validate_passesWithoutExceptionForRepeatAddressInDifferentConfigs() 172 .withVolumeGroups(new CarVolumeGroup[]{mockVolumeGroup1}) in validate_passesWithoutExceptionForRepeatAddressInDifferentConfigs() [all …]
|
D | CarAudioZonesHelperLegacyTest.java | 254 CarVolumeGroup[] volumeGroups = zones.get(0).getCurrentVolumeGroups(); in loadAudioZones_parsesAllVolumeGroups() 303 CarVolumeGroup[] volumeGroups = zones.get(0).getCurrentVolumeGroups(); in loadAudioZones_associatesLegacyContextsWithCorrectBuses() 304 CarVolumeGroup mediaVolumeGroup = volumeGroups[0]; in loadAudioZones_associatesLegacyContextsWithCorrectBuses() 309 CarVolumeGroup secondVolumeGroup = volumeGroups[1]; in loadAudioZones_associatesLegacyContextsWithCorrectBuses() 333 CarVolumeGroup[] volumeGroups = zones.get(0).getCurrentVolumeGroups(); in loadAudioZones_associatesNonLegacyContextsWithMediaBus() 334 CarVolumeGroup mediaVolumeGroup = volumeGroups[0]; in loadAudioZones_associatesNonLegacyContextsWithMediaBus()
|
D | CarAudioDynamicRoutingTest.java | 289 CarVolumeGroup mockMusicGroup = new VolumeGroupBuilder() in getTestCarAudioZones() 293 CarVolumeGroup mockNavGroupRoutingOnMusic = new VolumeGroupBuilder() in getTestCarAudioZones() 353 CarVolumeGroup build() { in build() 354 CarVolumeGroup carVolumeGroup = mock(CarVolumeGroup.class); in build()
|
D | CarAudioZonesHelperTest.java | 590 CarVolumeGroup primaryVolumeGroup = primaryZone.getCurrentVolumeGroups()[0]; in loadAudioZones_parsesAddresses() 595 CarVolumeGroup secondaryVolumeGroup = secondaryZone.getCurrentVolumeGroups()[0]; in loadAudioZones_parsesAddresses() 615 CarVolumeGroup volumeGroup = primaryZone.getCurrentVolumeGroups()[0]; in loadAudioZones_versionTwoParsesAddresses() 633 CarVolumeGroup volumeGroup = zones.get(0).getCurrentVolumeGroups()[0]; in loadAudioZones_parsesContexts() 638 CarVolumeGroup rseVolumeGroup = zones.get(2).getCurrentVolumeGroups()[0]; in loadAudioZones_parsesContexts() 683 CarVolumeGroup volumeGroup = zones.get(0).getCurrentVolumeGroups()[0]; in loadAudioZones_versionTwoParsesContexts() 688 CarVolumeGroup rseVolumeGroup = zones.get(2).getCurrentVolumeGroups()[0]; in loadAudioZones_versionTwoParsesContexts() 713 CarVolumeGroup volumeGroup = defaultZone.getCurrentVolumeGroups()[0]; in loadAudioZones_forVersionOne_bindsNonLegacyContextsToDefault() 1517 CarVolumeGroup mediaVolumeGroup = configBTMedia.getVolumeGroup("media"); in loadAudioZones_withPrimaryZoneAndDynamicAudioDevices() 1593 CarVolumeGroup[] volumeGroups = zoneConfig.getVolumeGroups(); in loadAudioZones_withMinMaxActivationVolumeAndNoActivationVolumeSupport() [all …]
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/audio/ |
D | CarVolumeGroupUnitTest.java | 157 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in getAddressForContext_withSupportedContext_returnsAddress() 166 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in getAddressForContext_withUnsupportedContext_returnsNull() 175 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenUnmuted_onActivation_returnsTrue() 183 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenUnmuted_onDeactivation_returnsFalse() 192 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenMuted_onDeactivation_returnsTrue() 201 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenMuted_onActivation_returnsFalse() 210 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenHalMuted_onActivation_returnsTrue() 226 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in setMuted_whenHalMuted_onDeactivation_returnsFalse() 242 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in isMuted_whenDefault_returnsFalse() 250 CarVolumeGroup carVolumeGroup = getCarVolumeGroupWithMusicBound(); in isMuted_afterMuting_returnsTrue() [all …]
|
D | CarAudioZoneConfigUnitTest.java | 109 private CarVolumeGroup mMockMusicGroup; 111 private CarVolumeGroup mMockInactiveMusicGroup; 113 private CarVolumeGroup mMockNavGroup; 115 private CarVolumeGroup mMockVoiceGroup; 276 CarVolumeGroup[] volumeGroups = zoneConfig.getVolumeGroups(); in getCarVolumeGroups() 336 CarVolumeGroup mockMusicGroup = new VolumeGroupBuilder() in validateCanUseDynamicMixRouting_addressSharedAmongGroups_forbidUseDynamicRouting() 339 CarVolumeGroup mockNavGroupRoutingOnMusic = new VolumeGroupBuilder() in validateCanUseDynamicMixRouting_addressSharedAmongGroups_forbidUseDynamicRouting() 354 CarVolumeGroup mockMusicGroup = new VolumeGroupBuilder() in validateCanUseDynamicMixRouting_whenUseCoreRouting_disablesDynamicRouting() 357 CarVolumeGroup mockNavGroupRoutingOnMusic = new VolumeGroupBuilder() in validateCanUseDynamicMixRouting_whenUseCoreRouting_disablesDynamicRouting() 376 CarVolumeGroup mockMusicGroup = new VolumeGroupBuilder() in validateZoneWhenUsageSharedAmongContext_forbidUseDynamicRouting() [all …]
|
D | CarVolumeGroupMutingTest.java | 86 private CarVolumeGroup mMusicCarVolumeGroup; 87 private CarVolumeGroup mNavigationCarVolumeGroup; 88 private CarVolumeGroup mVoiceCarVolumeGroup; 89 private CarVolumeGroup mSecondaryZoneVolumeGroup; 93 private CarVolumeGroup mTertiaryZoneVolumeGroup; 539 private CarAudioZone createAudioZone(CarVolumeGroup volumeGroup, String name, int zoneId) { in createAudioZone() 547 private CarVolumeGroup groupWithContextAndAddress(int context, String address) { in groupWithContextAndAddress() 557 private void setUpCarVolumeGroupIsMuted(CarVolumeGroup carVolumeGroup, boolean muted) { in setUpCarVolumeGroupIsMuted() 561 private void setUpCarVolumeGroupHasCriticalAudioContexts(CarVolumeGroup carVolumeGroup) { in setUpCarVolumeGroupHasCriticalAudioContexts()
|
D | CarVolumeGroupFactoryTest.java | 90 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in setDeviceInfoForContext_associatesDeviceAddresses() 101 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in setDeviceInfoForContext_associatesContexts() 252 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in factoryBuild_withNoStoredGain_usesDefaultGain() 264 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in factoryBuild_withTooLargeStoredGain_usesDefaultGain() 276 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in factoryBuild_withTooSmallStoredGain_usesDefaultGain() 288 CarVolumeGroup carVolumeGroup = mFactory.getCarVolumeGroup(/* useCoreAudioVolume= */ false); in factoryBuild_withValidStoredGain_usesStoredGain()
|
D | CarAudioPlaybackMonitorTest.java | 77 private CarVolumeGroup mMockPrimaryZoneMediaGroup; 79 private CarVolumeGroup mMockPrimaryZoneNavGroup; 81 private CarVolumeGroup mMockPrimaryZoneRingtoneGroup; 83 private CarVolumeGroup mMockSecondaryZoneMediaGroup; 85 private CarVolumeGroup mMockSecondaryZoneNavGroup;
|
D | VolumeGroupBuilder.java | 129 public CarVolumeGroup build() { in build() 130 CarVolumeGroup carVolumeGroup = mock(CarVolumeGroup.class); in build()
|
D | CarAudioZoneUnitTest.java | 115 private CarVolumeGroup mMockMusicGroup0; 117 private CarVolumeGroup mMockNavGroup0; 119 private CarVolumeGroup mMockVoiceGroup0; 121 private CarVolumeGroup mMockGroup1; 128 private List<CarVolumeGroup> mZoneConfig0VolumeGroups; 932 private List<CarVolumeGroup> mCarVolumeGroups = new ArrayList<>(); 950 TestCarAudioZoneConfigBuilder addVolumeGroup(CarVolumeGroup volumeGroup) { in addVolumeGroup() 968 .thenReturn(mCarVolumeGroups.toArray(new CarVolumeGroup[0])); in build() 1029 CarVolumeGroup group = mCarVolumeGroups.get(updatedGroupIds.valueAt(index)); in build()
|
/packages/services/Car/service/src/com/android/car/audio/ |
D | CarAudioZoneConfig.java | 69 private final List<CarVolumeGroup> mVolumeGroups; 83 List<CarVolumeGroup> volumeGroups, Map<String, Integer> deviceAddressToGroupId, in CarAudioZoneConfig() 129 CarVolumeGroup getVolumeGroup(String groupName) { in getVolumeGroup() 137 CarVolumeGroup getVolumeGroup(int groupId) { in getVolumeGroup() 149 CarVolumeGroup group = mVolumeGroups.get(index); in getAudioDevice() 162 CarVolumeGroup group = mVolumeGroups.get(index); in getAudioDeviceSupportingDynamicMix() 182 CarVolumeGroup[] getVolumeGroups() { in getVolumeGroups() 183 return mVolumeGroups.toArray(new CarVolumeGroup[0]); in getVolumeGroups() 199 CarVolumeGroup group = mVolumeGroups.get(index); in validateCanUseDynamicMixRouting() 268 CarVolumeGroup group = mVolumeGroups.get(index); in validateVolumeGroups() [all …]
|
D | CarAudioZone.java | 124 CarVolumeGroup getCurrentVolumeGroup(String groupName) { in getCurrentVolumeGroup() 128 CarVolumeGroup getCurrentVolumeGroup(int groupId) { in getCurrentVolumeGroup() 150 CarVolumeGroup[] getCurrentVolumeGroups() { in getCurrentVolumeGroups() 288 for (CarVolumeGroup volumeGroup : getCurrentVolumeGroups()) { in getAddressForContext() 302 for (CarVolumeGroup volumeGroup : getCurrentVolumeGroups()) { in getAudioDeviceForContext() 369 CarVolumeGroup getVolumeGroupForAudioAttributes(AudioAttributes audioAttributes) { in getVolumeGroupForAudioAttributes()
|
D | CarAudioZonesHelperLegacy.java | 160 List<CarVolumeGroup> volumeGroups = loadVolumeGroups(); in loadAudioZones() 177 private List<CarVolumeGroup> loadVolumeGroups() { in loadVolumeGroups() 178 List<CarVolumeGroup> carVolumeGroups = new ArrayList<>(); in loadVolumeGroups() 210 private CarVolumeGroup parseVolumeGroup(int id, AttributeSet attrs, in parseVolumeGroup()
|
D | CarVolumeGroupFactory.java | 64 CarVolumeGroup getCarVolumeGroup(boolean useCoreAudioVolume) { in getCarVolumeGroup() 67 CarVolumeGroup group; in getCarVolumeGroup()
|
D | CarAudioZonesValidator.java | 122 CarVolumeGroup[] groups = config.getVolumeGroups(); in validateEachAddressAppearsAtMostOnceInOneConfig() 123 for (CarVolumeGroup carVolumeGroup : groups) { in validateEachAddressAppearsAtMostOnceInOneConfig()
|
D | CarAudioDynamicRouting.java | 100 CarVolumeGroup[] volumeGroups = zoneConfig.getVolumeGroups(); in setupAudioDynamicRoutingForZoneConfig() 116 CarVolumeGroup group, CarAudioContext carAudioContext, in setupAudioDynamicRoutingForGroup()
|
D | CarVolumeGroupMuting.java | 204 CarVolumeGroup[] groups = audioZone.getCurrentVolumeGroups(); in generateMutingInfoFromZone() 207 CarVolumeGroup group = groups[groupIndex]; in generateMutingInfoFromZone()
|
D | CarAudioService.java | 960 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); in setGroupVolume() 990 CarVolumeGroup volumeGroup = mCarAudioZones.get(zoneId) in handleActivationVolumeWithActivationInfos() 1082 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); in getGroupMaxVolume() 1100 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); in getGroupMinVolume() 1119 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); in getGroupVolume() 1445 private CarVolumeGroup getCarVolumeGroupLocked(int zoneId, int groupId) { in getCarVolumeGroupLocked() 1451 private CarVolumeGroup getCarVolumeGroupLocked(int zoneId, String groupName) { in getCarVolumeGroupLocked() 2518 CarVolumeGroup[] groups = getCarAudioZoneLocked(zoneId).getCurrentVolumeGroups(); 2538 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); 2594 CarVolumeGroup group = getCarVolumeGroupLocked(zoneId, groupId); [all …]
|
D | CarAudioVolumeGroup.java | 38 final class CarAudioVolumeGroup extends CarVolumeGroup {
|
D | CarAudioPlaybackMonitor.java | 131 CarVolumeGroup volumeGroup = currentZoneConfig.getVolumeGroupForAudioAttributes( in getActivationInfo()
|
D | CoreAudioVolumeGroup.java | 50 final class CoreAudioVolumeGroup extends CarVolumeGroup {
|
D | CarVolumeGroup.java | 96 /* package */ abstract class CarVolumeGroup { class 174 protected CarVolumeGroup(CarAudioContext carAudioContext, CarAudioSettings settingsManager, in CarVolumeGroup() method in CarVolumeGroup
|