Home
last modified time | relevance | path

Searched refs:audioContext (Results 1 – 10 of 10) sorted by relevance

/packages/services/Car/service/src/com/android/car/audio/
DCarAudioContext.java218 @AudioContext int audioContext = CONTEXT_TO_USAGES.keyAt(i);
221 USAGE_TO_CONTEXT.put(usage, audioContext); in USAGE_TO_CONTEXT.put() argument
232 static void preconditionCheckAudioContext(@AudioContext int audioContext) { in preconditionCheckAudioContext() argument
233 Preconditions.checkArgument(Arrays.binarySearch(CONTEXTS, audioContext) >= 0, in preconditionCheckAudioContext()
234 "audioContext %d is invalid", audioContext); in preconditionCheckAudioContext() local
263 static boolean isCriticalAudioContext(@CarAudioContext.AudioContext int audioContext) { in isCriticalAudioContext() argument
264 return CarAudioContext.EMERGENCY == audioContext || CarAudioContext.SAFETY == audioContext; in isCriticalAudioContext()
268 static String toString(@AudioContext int audioContext) { in toString() argument
269 String name = CONTEXT_NAMES.get(audioContext); in toString()
273 return "Unsupported Context 0x" + Integer.toHexString(audioContext); in toString()
DCarAudioZonesHelper.java107 private static boolean isLegacyContext(@AudioContext int audioContext) { in isLegacyContext() argument
108 return Arrays.binarySearch(LEGACY_CONTEXTS, audioContext) >= 0; in isLegacyContext()
115 for (@AudioContext int audioContext : CarAudioContext.CONTEXTS) {
116 if (!isLegacyContext(audioContext)) {
117 NON_LEGACY_CONTEXTS.add(audioContext);
124 for (@AudioContext int audioContext : NON_LEGACY_CONTEXTS) { in setNonLegacyContexts()
125 groupBuilder.setDeviceInfoForContext(audioContext, info); in setNonLegacyContexts()
476 private void validateCarAudioContextSupport(@AudioContext int audioContext) { in validateCarAudioContextSupport() argument
477 if (isVersionOne() && NON_LEGACY_CONTEXTS.contains(audioContext)) { in validateCarAudioContextSupport()
481 CarAudioContext.toString(audioContext), SUPPORTED_VERSION_1)); in validateCarAudioContextSupport()
DFocusInteraction.java409 for (int audioContext = 0; audioContext < matrixToClone.length; audioContext++) { in cloneInteractionMatrix()
410 System.arraycopy(matrixToClone[audioContext], 0, in cloneInteractionMatrix()
411 interactionMatrixClone[audioContext], 0, matrixToClone.length); in cloneInteractionMatrix()
DCarAudioZone.java181 String getAddressForContext(int audioContext) { in getAddressForContext() argument
182 CarAudioContext.preconditionCheckAudioContext(audioContext); in getAddressForContext()
185 deviceAddress = volumeGroup.getAddressForContext(audioContext); in getAddressForContext()
193 + " for audio context " + audioContext); in getAddressForContext()
DCarVolumeGroup.java119 String getAddressForContext(int audioContext) { in getAddressForContext() argument
120 return mContextToAddress.get(audioContext); in getAddressForContext()
259 int audioContext = contextToAddress.keyAt(i); in containsCriticalAudioContext() local
260 if (CarAudioContext.isCriticalAudioContext(audioContext)) { in containsCriticalAudioContext()
DCarAudioFocus.java105 int audioContext = CarAudioContext.getContextForAttributes( in abandonNonCriticalFocusLocked() local
108 if (!isCriticalAudioContext(audioContext)) { in abandonNonCriticalFocusLocked()
171 int audioContext = CarAudioContext.getContextForAttributes(afi.getAttributes()); in evaluateFocusRequestLocked() local
172 if (!isCriticalAudioContext(audioContext)) { in evaluateFocusRequestLocked()
DCarAudioService.java893 @AudioContext int audioContext = CarAudioContext.getContextForUsage(usage); in getVolumeGroupIdForUsage() local
894 return getVolumeGroupIdForAudioContextLocked(zoneId, audioContext); in getVolumeGroupIdForUsage()
899 private int getVolumeGroupIdForAudioContextLocked(int zoneId, @AudioContext int audioContext) { in getVolumeGroupIdForAudioContextLocked() argument
904 if (audioContext == groupAudioContext) { in getVolumeGroupIdForAudioContextLocked()
/packages/services/Car/service/src/com/android/car/audio/hal/
DAudioControlWrapperV1.java137 public int getBusForContext(@CarAudioContext.AudioContext int audioContext) { in getBusForContext() argument
139 return mAudioControlV1.getBusForContext(audioContext); in getBusForContext()
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/audio/
DCarAudioContextTest.java100 for (@AudioContext int audioContext : CarAudioContext.CONTEXTS) { in getUsagesForContext_returnsUniqueValuesForAllContexts()
101 @AttributeUsage int[] usages = CarAudioContext.getUsagesForContext(audioContext); in getUsagesForContext_returnsUniqueValuesForAllContexts()
DFocusInteractionTest.java274 private FocusEntry newMockFocusEntryWithContext(@AudioContext int audioContext) { in newMockFocusEntryWithContext() argument
276 when(focusEntry.getAudioContext()).thenReturn(audioContext); in newMockFocusEntryWithContext()