Lines Matching refs:aps
792 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setDeviceConnectionState() local
796 if (aps == 0) return PERMISSION_DENIED; in setDeviceConnectionState()
804 return aps->setDeviceConnectionState(device, state, address, name, encodedFormat); in setDeviceConnectionState()
810 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getDeviceConnectionState() local
811 if (aps == 0) return AUDIO_POLICY_DEVICE_STATE_UNAVAILABLE; in getDeviceConnectionState()
813 return aps->getDeviceConnectionState(device, device_address); in getDeviceConnectionState()
821 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in handleDeviceConfigChange() local
825 if (aps == 0) return PERMISSION_DENIED; in handleDeviceConfigChange()
833 return aps->handleDeviceConfigChange(device, address, name, encodedFormat); in handleDeviceConfigChange()
839 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setPhoneState() local
840 if (aps == 0) return PERMISSION_DENIED; in setPhoneState()
842 return aps->setPhoneState(state); in setPhoneState()
847 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setForceUse() local
848 if (aps == 0) return PERMISSION_DENIED; in setForceUse()
849 return aps->setForceUse(usage, config); in setForceUse()
854 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getForceUse() local
855 if (aps == 0) return AUDIO_POLICY_FORCE_NONE; in getForceUse()
856 return aps->getForceUse(usage); in getForceUse()
862 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutput() local
863 if (aps == 0) return 0; in getOutput()
864 return aps->getOutput(stream); in getOutput()
879 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutputForAttr() local
880 if (aps == 0) return NO_INIT; in getOutputForAttr()
881 return aps->getOutputForAttr(attr, output, session, stream, pid, uid, in getOutputForAttr()
888 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in startOutput() local
889 if (aps == 0) return PERMISSION_DENIED; in startOutput()
890 return aps->startOutput(portId); in startOutput()
895 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in stopOutput() local
896 if (aps == 0) return PERMISSION_DENIED; in stopOutput()
897 return aps->stopOutput(portId); in stopOutput()
902 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseOutput() local
903 if (aps == 0) return; in releaseOutput()
904 aps->releaseOutput(portId); in releaseOutput()
919 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getInputForAttr() local
920 if (aps == 0) return NO_INIT; in getInputForAttr()
921 return aps->getInputForAttr( in getInputForAttr()
928 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in startInput() local
929 if (aps == 0) return PERMISSION_DENIED; in startInput()
930 return aps->startInput(portId); in startInput()
935 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in stopInput() local
936 if (aps == 0) return PERMISSION_DENIED; in stopInput()
937 return aps->stopInput(portId); in stopInput()
942 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseInput() local
943 if (aps == 0) return; in releaseInput()
944 aps->releaseInput(portId); in releaseInput()
951 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in initStreamVolume() local
952 if (aps == 0) return PERMISSION_DENIED; in initStreamVolume()
953 return aps->initStreamVolume(stream, indexMin, indexMax); in initStreamVolume()
960 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setStreamVolumeIndex() local
961 if (aps == 0) return PERMISSION_DENIED; in setStreamVolumeIndex()
962 return aps->setStreamVolumeIndex(stream, index, device); in setStreamVolumeIndex()
969 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getStreamVolumeIndex() local
970 if (aps == 0) return PERMISSION_DENIED; in getStreamVolumeIndex()
971 return aps->getStreamVolumeIndex(stream, index, device); in getStreamVolumeIndex()
978 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setVolumeIndexForAttributes() local
979 if (aps == 0) return PERMISSION_DENIED; in setVolumeIndexForAttributes()
980 return aps->setVolumeIndexForAttributes(attr, index, device); in setVolumeIndexForAttributes()
987 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getVolumeIndexForAttributes() local
988 if (aps == 0) return PERMISSION_DENIED; in getVolumeIndexForAttributes()
989 return aps->getVolumeIndexForAttributes(attr, index, device); in getVolumeIndexForAttributes()
994 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getMaxVolumeIndexForAttributes() local
995 if (aps == 0) return PERMISSION_DENIED; in getMaxVolumeIndexForAttributes()
996 return aps->getMaxVolumeIndexForAttributes(attr, index); in getMaxVolumeIndexForAttributes()
1001 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getMinVolumeIndexForAttributes() local
1002 if (aps == 0) return PERMISSION_DENIED; in getMinVolumeIndexForAttributes()
1003 return aps->getMinVolumeIndexForAttributes(attr, index); in getMinVolumeIndexForAttributes()
1008 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getStrategyForStream() local
1009 if (aps == 0) return PRODUCT_STRATEGY_NONE; in getStrategyForStream()
1010 return aps->getStrategyForStream(stream); in getStrategyForStream()
1015 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getDevicesForStream() local
1016 if (aps == 0) return AUDIO_DEVICE_NONE; in getDevicesForStream()
1017 return aps->getDevicesForStream(stream); in getDevicesForStream()
1022 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutputForEffect() local
1024 if (aps == 0) return AUDIO_IO_HANDLE_NONE; in getOutputForEffect()
1025 return aps->getOutputForEffect(desc); in getOutputForEffect()
1034 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in registerEffect() local
1035 if (aps == 0) return PERMISSION_DENIED; in registerEffect()
1036 return aps->registerEffect(desc, io, strategy, session, id); in registerEffect()
1041 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in unregisterEffect() local
1042 if (aps == 0) return PERMISSION_DENIED; in unregisterEffect()
1043 return aps->unregisterEffect(id); in unregisterEffect()
1048 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setEffectEnabled() local
1049 if (aps == 0) return PERMISSION_DENIED; in setEffectEnabled()
1050 return aps->setEffectEnabled(id, enabled); in setEffectEnabled()
1055 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in moveEffectsToIo() local
1056 if (aps == 0) return PERMISSION_DENIED; in moveEffectsToIo()
1057 return aps->moveEffectsToIo(ids, io); in moveEffectsToIo()
1062 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isStreamActive() local
1063 if (aps == 0) return PERMISSION_DENIED; in isStreamActive()
1065 *state = aps->isStreamActive(stream, inPastMs); in isStreamActive()
1072 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isStreamActiveRemotely() local
1073 if (aps == 0) return PERMISSION_DENIED; in isStreamActiveRemotely()
1075 *state = aps->isStreamActiveRemotely(stream, inPastMs); in isStreamActiveRemotely()
1081 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isSourceActive() local
1082 if (aps == 0) return PERMISSION_DENIED; in isSourceActive()
1084 *state = aps->isSourceActive(stream); in isSourceActive()
1127 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setAllowedCapturePolicy() local
1128 if (aps == nullptr) return PERMISSION_DENIED; in setAllowedCapturePolicy()
1129 return aps->setAllowedCapturePolicy(uid, flags); in setAllowedCapturePolicy()
1135 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isOffloadSupported() local
1136 if (aps == 0) return false; in isOffloadSupported()
1137 return aps->isOffloadSupported(info); in isOffloadSupported()
1146 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioPorts() local
1147 if (aps == 0) return PERMISSION_DENIED; in listAudioPorts()
1148 return aps->listAudioPorts(role, type, num_ports, ports, generation); in listAudioPorts()
1153 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getAudioPort() local
1154 if (aps == 0) return PERMISSION_DENIED; in getAudioPort()
1155 return aps->getAudioPort(port); in getAudioPort()
1161 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in createAudioPatch() local
1162 if (aps == 0) return PERMISSION_DENIED; in createAudioPatch()
1163 return aps->createAudioPatch(patch, handle); in createAudioPatch()
1168 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseAudioPatch() local
1169 if (aps == 0) return PERMISSION_DENIED; in releaseAudioPatch()
1170 return aps->releaseAudioPatch(handle); in releaseAudioPatch()
1177 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioPatches() local
1178 if (aps == 0) return PERMISSION_DENIED; in listAudioPatches()
1179 return aps->listAudioPatches(num_patches, patches, generation); in listAudioPatches()
1184 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setAudioPortConfig() local
1185 if (aps == 0) return PERMISSION_DENIED; in setAudioPortConfig()
1186 return aps->setAudioPortConfig(config); in setAudioPortConfig()
1191 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in addAudioPortCallback() local
1192 if (aps == 0) return PERMISSION_DENIED; in addAudioPortCallback()
1200 aps->setAudioPortCallbacksEnabled(true); in addAudioPortCallback()
1208 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in removeAudioPortCallback() local
1209 if (aps == 0) return PERMISSION_DENIED; in removeAudioPortCallback()
1217 aps->setAudioPortCallbacksEnabled(false); in removeAudioPortCallback()
1224 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in addAudioVolumeGroupCallback() local
1225 if (aps == 0) return PERMISSION_DENIED; in addAudioVolumeGroupCallback()
1233 aps->setAudioVolumeGroupCallbacksEnabled(true); in addAudioVolumeGroupCallback()
1240 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in removeAudioVolumeGroupCallback() local
1241 if (aps == 0) return PERMISSION_DENIED; in removeAudioVolumeGroupCallback()
1249 aps->setAudioVolumeGroupCallbacksEnabled(false); in removeAudioVolumeGroupCallback()
1298 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in acquireSoundTriggerSession() local
1299 if (aps == 0) return PERMISSION_DENIED; in acquireSoundTriggerSession()
1300 return aps->acquireSoundTriggerSession(session, ioHandle, device); in acquireSoundTriggerSession()
1305 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseSoundTriggerSession() local
1306 if (aps == 0) return PERMISSION_DENIED; in releaseSoundTriggerSession()
1307 return aps->releaseSoundTriggerSession(session); in releaseSoundTriggerSession()
1312 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getPhoneState() local
1313 if (aps == 0) return AUDIO_MODE_INVALID; in getPhoneState()
1314 return aps->getPhoneState(); in getPhoneState()
1319 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in registerPolicyMixes() local
1320 if (aps == 0) return PERMISSION_DENIED; in registerPolicyMixes()
1321 return aps->registerPolicyMixes(mixes, registration); in registerPolicyMixes()
1326 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setUidDeviceAffinities() local
1327 if (aps == 0) return PERMISSION_DENIED; in setUidDeviceAffinities()
1328 return aps->setUidDeviceAffinities(uid, devices); in setUidDeviceAffinities()
1332 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in removeUidDeviceAffinities() local
1333 if (aps == 0) return PERMISSION_DENIED; in removeUidDeviceAffinities()
1334 return aps->removeUidDeviceAffinities(uid); in removeUidDeviceAffinities()
1341 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in startAudioSource() local
1342 if (aps == 0) return PERMISSION_DENIED; in startAudioSource()
1343 return aps->startAudioSource(source, attributes, portId); in startAudioSource()
1348 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in stopAudioSource() local
1349 if (aps == 0) return PERMISSION_DENIED; in stopAudioSource()
1350 return aps->stopAudioSource(portId); in stopAudioSource()
1355 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setMasterMono() local
1356 if (aps == 0) return PERMISSION_DENIED; in setMasterMono()
1357 return aps->setMasterMono(mono); in setMasterMono()
1362 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getMasterMono() local
1363 if (aps == 0) return PERMISSION_DENIED; in getMasterMono()
1364 return aps->getMasterMono(mono); in getMasterMono()
1383 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getStreamVolumeDB() local
1384 if (aps == 0) return NAN; in getStreamVolumeDB()
1385 return aps->getStreamVolumeDB(stream, index, device); in getStreamVolumeDB()
1400 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getSurroundFormats() local
1401 if (aps == 0) return PERMISSION_DENIED; in getSurroundFormats()
1402 return aps->getSurroundFormats( in getSurroundFormats()
1408 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setSurroundFormatEnabled() local
1409 if (aps == 0) return PERMISSION_DENIED; in setSurroundFormatEnabled()
1410 return aps->setSurroundFormatEnabled(audioFormat, enabled); in setSurroundFormatEnabled()
1415 const sp <IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setAssistantUid() local
1416 if (aps == 0) return PERMISSION_DENIED; in setAssistantUid()
1418 return aps->setAssistantUid(uid); in setAssistantUid()
1423 const sp <IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setA11yServicesUids() local
1424 if (aps == 0) return PERMISSION_DENIED; in setA11yServicesUids()
1426 return aps->setA11yServicesUids(uids); in setA11yServicesUids()
1431 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isHapticPlaybackSupported() local
1432 if (aps == 0) return false; in isHapticPlaybackSupported()
1433 return aps->isHapticPlaybackSupported(); in isHapticPlaybackSupported()
1439 & aps = AudioSystem::get_audio_policy_service(); in getHwOffloadEncodingFormatsSupportedForA2DP() local
1440 if (aps == 0) return PERMISSION_DENIED; in getHwOffloadEncodingFormatsSupportedForA2DP()
1441 return aps->getHwOffloadEncodingFormatsSupportedForA2DP(formats); in getHwOffloadEncodingFormatsSupportedForA2DP()
1446 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioProductStrategies() local
1447 if (aps == 0) return PERMISSION_DENIED; in listAudioProductStrategies()
1448 return aps->listAudioProductStrategies(strategies); in listAudioProductStrategies()
1495 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getProductStrategyFromAudioAttributes() local
1496 if (aps == 0) return PERMISSION_DENIED; in getProductStrategyFromAudioAttributes()
1497 return aps->getProductStrategyFromAudioAttributes(aa,productStrategy); in getProductStrategyFromAudioAttributes()
1502 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioVolumeGroups() local
1503 if (aps == 0) return PERMISSION_DENIED; in listAudioVolumeGroups()
1504 return aps->listAudioVolumeGroups(groups); in listAudioVolumeGroups()
1510 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getVolumeGroupFromAudioAttributes() local
1511 if (aps == 0) return PERMISSION_DENIED; in getVolumeGroupFromAudioAttributes()
1512 return aps->getVolumeGroupFromAudioAttributes(aa, volumeGroup); in getVolumeGroupFromAudioAttributes()
1517 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setRttEnabled() local
1518 if (aps == 0) return PERMISSION_DENIED; in setRttEnabled()
1519 return aps->setRttEnabled(enabled); in setRttEnabled()