Lines Matching refs:AudioSystem

34 Mutex AudioSystem::gLock;
35 Mutex AudioSystem::gLockCache;
36 Mutex AudioSystem::gLockAPS;
37 Mutex AudioSystem::gLockAPC;
38 sp<IAudioFlinger> AudioSystem::gAudioFlinger;
39 sp<AudioSystem::AudioFlingerClient> AudioSystem::gAudioFlingerClient;
40 audio_error_callback AudioSystem::gAudioErrorCallback = NULL;
43 DefaultKeyedVector<audio_io_handle_t, AudioSystem::OutputDescriptor *> AudioSystem::gOutputs(NULL);
46 uint32_t AudioSystem::gPrevInSamplingRate;
47 audio_format_t AudioSystem::gPrevInFormat;
48 audio_channel_mask_t AudioSystem::gPrevInChannelMask;
49 size_t AudioSystem::gInBuffSize = 0; // zero indicates cache is invalid
51 sp<AudioSystem::AudioPortCallback> AudioSystem::gAudioPortCallback;
54 const sp<IAudioFlinger> AudioSystem::get_audio_flinger() in get_audio_flinger()
90 /* static */ status_t AudioSystem::checkAudioFlinger() in checkAudioFlinger()
98 status_t AudioSystem::muteMicrophone(bool state) in muteMicrophone()
100 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in muteMicrophone()
105 status_t AudioSystem::isMicrophoneMuted(bool* state) in isMicrophoneMuted()
107 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in isMicrophoneMuted()
113 status_t AudioSystem::setMasterVolume(float value) in setMasterVolume()
115 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setMasterVolume()
121 status_t AudioSystem::setMasterMute(bool mute) in setMasterMute()
123 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setMasterMute()
129 status_t AudioSystem::getMasterVolume(float* volume) in getMasterVolume()
131 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getMasterVolume()
137 status_t AudioSystem::getMasterMute(bool* mute) in getMasterMute()
139 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getMasterMute()
145 status_t AudioSystem::setStreamVolume(audio_stream_type_t stream, float value, in setStreamVolume()
149 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setStreamVolume()
155 status_t AudioSystem::setStreamMute(audio_stream_type_t stream, bool mute) in setStreamMute()
158 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setStreamMute()
164 status_t AudioSystem::getStreamVolume(audio_stream_type_t stream, float* volume, in getStreamVolume()
168 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getStreamVolume()
174 status_t AudioSystem::getStreamMute(audio_stream_type_t stream, bool* mute) in getStreamMute()
177 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getStreamMute()
183 status_t AudioSystem::setMode(audio_mode_t mode) in setMode()
186 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setMode()
191 status_t AudioSystem::setParameters(audio_io_handle_t ioHandle, const String8& keyValuePairs) in setParameters()
193 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setParameters()
198 String8 AudioSystem::getParameters(audio_io_handle_t ioHandle, const String8& keys) in getParameters()
200 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getParameters()
208 status_t AudioSystem::setParameters(const String8& keyValuePairs) in setParameters()
213 String8 AudioSystem::getParameters(const String8& keys) in getParameters()
226 float AudioSystem::linearToLog(int volume) in linearToLog()
234 int AudioSystem::logToLinear(float volume) in logToLinear()
242 status_t AudioSystem::getOutputSamplingRate(uint32_t* samplingRate, audio_stream_type_t streamType) in getOutputSamplingRate()
258 status_t AudioSystem::getSamplingRate(audio_io_handle_t output, in getSamplingRate()
261 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getSamplingRate()
266 OutputDescriptor *outputDesc = AudioSystem::gOutputs.valueFor(output); in getSamplingRate()
286 status_t AudioSystem::getOutputFrameCount(size_t* frameCount, audio_stream_type_t streamType) in getOutputFrameCount()
302 status_t AudioSystem::getFrameCount(audio_io_handle_t output, in getFrameCount()
305 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getFrameCount()
310 OutputDescriptor *outputDesc = AudioSystem::gOutputs.valueFor(output); in getFrameCount()
328 status_t AudioSystem::getOutputLatency(uint32_t* latency, audio_stream_type_t streamType) in getOutputLatency()
344 status_t AudioSystem::getLatency(audio_io_handle_t output, in getLatency()
347 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getLatency()
352 OutputDescriptor *outputDesc = AudioSystem::gOutputs.valueFor(output); in getLatency()
366 status_t AudioSystem::getInputBufferSize(uint32_t sampleRate, audio_format_t format, in getInputBufferSize()
369 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getInputBufferSize()
399 status_t AudioSystem::setVoiceVolume(float value) in setVoiceVolume()
401 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setVoiceVolume()
406 status_t AudioSystem::getRenderPosition(audio_io_handle_t output, uint32_t *halFrames, in getRenderPosition()
409 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getRenderPosition()
415 uint32_t AudioSystem::getInputFramesLost(audio_io_handle_t ioHandle) in getInputFramesLost()
417 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getInputFramesLost()
426 audio_unique_id_t AudioSystem::newAudioUniqueId() in newAudioUniqueId()
428 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in newAudioUniqueId()
433 void AudioSystem::acquireAudioSessionId(int audioSession, pid_t pid) in acquireAudioSessionId()
435 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in acquireAudioSessionId()
441 void AudioSystem::releaseAudioSessionId(int audioSession, pid_t pid) in releaseAudioSessionId()
443 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in releaseAudioSessionId()
449 audio_hw_sync_t AudioSystem::getAudioHwSyncForSession(audio_session_t sessionId) in getAudioHwSyncForSession()
451 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getAudioHwSyncForSession()
458 void AudioSystem::AudioFlingerClient::binderDied(const wp<IBinder>& who __unused) in binderDied()
462 Mutex::Autolock _l(AudioSystem::gLock); in binderDied()
463 AudioSystem::gAudioFlinger.clear(); in binderDied()
470 AudioSystem::gOutputs.clear(); in binderDied()
479 void AudioSystem::AudioFlingerClient::ioConfigChanged(int event, audio_io_handle_t ioHandle, in ioConfigChanged()
487 Mutex::Autolock _l(AudioSystem::gLockCache); in ioConfigChanged()
543 void AudioSystem::setErrorCallback(audio_error_callback cb) in setErrorCallback()
551 sp<IAudioPolicyService> AudioSystem::gAudioPolicyService;
552 sp<AudioSystem::AudioPolicyServiceClient> AudioSystem::gAudioPolicyServiceClient;
556 const sp<IAudioPolicyService> AudioSystem::get_audio_policy_service() in get_audio_policy_service()
591 status_t AudioSystem::setDeviceConnectionState(audio_devices_t device, in setDeviceConnectionState()
595 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setDeviceConnectionState()
607 audio_policy_dev_state_t AudioSystem::getDeviceConnectionState(audio_devices_t device, in getDeviceConnectionState()
610 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getDeviceConnectionState()
616 status_t AudioSystem::setPhoneState(audio_mode_t state) in setPhoneState()
619 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setPhoneState()
625 status_t AudioSystem::setForceUse(audio_policy_force_use_t usage, audio_policy_forced_cfg_t config) in setForceUse()
627 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setForceUse()
632 audio_policy_forced_cfg_t AudioSystem::getForceUse(audio_policy_force_use_t usage) in getForceUse()
634 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getForceUse()
640 audio_io_handle_t AudioSystem::getOutput(audio_stream_type_t stream, in getOutput()
647 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutput()
652 status_t AudioSystem::getOutputForAttr(const audio_attributes_t *attr, in getOutputForAttr()
662 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutputForAttr()
669 status_t AudioSystem::startOutput(audio_io_handle_t output, in startOutput()
673 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in startOutput()
678 status_t AudioSystem::stopOutput(audio_io_handle_t output, in stopOutput()
682 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in stopOutput()
687 void AudioSystem::releaseOutput(audio_io_handle_t output, in releaseOutput()
691 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseOutput()
696 status_t AudioSystem::getInputForAttr(const audio_attributes_t *attr, in getInputForAttr()
704 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getInputForAttr()
709 status_t AudioSystem::startInput(audio_io_handle_t input, in startInput()
712 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in startInput()
717 status_t AudioSystem::stopInput(audio_io_handle_t input, in stopInput()
720 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in stopInput()
725 void AudioSystem::releaseInput(audio_io_handle_t input, in releaseInput()
728 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseInput()
733 status_t AudioSystem::initStreamVolume(audio_stream_type_t stream, in initStreamVolume()
737 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in initStreamVolume()
742 status_t AudioSystem::setStreamVolumeIndex(audio_stream_type_t stream, in setStreamVolumeIndex()
746 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setStreamVolumeIndex()
751 status_t AudioSystem::getStreamVolumeIndex(audio_stream_type_t stream, in getStreamVolumeIndex()
755 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getStreamVolumeIndex()
760 uint32_t AudioSystem::getStrategyForStream(audio_stream_type_t stream) in getStrategyForStream()
762 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getStrategyForStream()
767 audio_devices_t AudioSystem::getDevicesForStream(audio_stream_type_t stream) in getDevicesForStream()
769 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getDevicesForStream()
774 audio_io_handle_t AudioSystem::getOutputForEffect(const effect_descriptor_t *desc) in getOutputForEffect()
776 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getOutputForEffect()
782 status_t AudioSystem::registerEffect(const effect_descriptor_t *desc, in registerEffect()
788 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in registerEffect()
793 status_t AudioSystem::unregisterEffect(int id) in unregisterEffect()
795 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in unregisterEffect()
800 status_t AudioSystem::setEffectEnabled(int id, bool enabled) in setEffectEnabled()
802 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setEffectEnabled()
807 status_t AudioSystem::isStreamActive(audio_stream_type_t stream, bool* state, uint32_t inPastMs) in isStreamActive()
809 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isStreamActive()
816 status_t AudioSystem::isStreamActiveRemotely(audio_stream_type_t stream, bool* state, in isStreamActiveRemotely()
819 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isStreamActiveRemotely()
826 status_t AudioSystem::isSourceActive(audio_source_t stream, bool* state) in isSourceActive()
828 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isSourceActive()
835 uint32_t AudioSystem::getPrimaryOutputSamplingRate() in getPrimaryOutputSamplingRate()
837 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getPrimaryOutputSamplingRate()
842 size_t AudioSystem::getPrimaryOutputFrameCount() in getPrimaryOutputFrameCount()
844 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in getPrimaryOutputFrameCount()
849 status_t AudioSystem::setLowRamDevice(bool isLowRamDevice) in setLowRamDevice()
851 const sp<IAudioFlinger>& af = AudioSystem::get_audio_flinger(); in setLowRamDevice()
856 void AudioSystem::clearAudioConfigCache() in clearAudioConfigCache()
875 bool AudioSystem::isOffloadSupported(const audio_offload_info_t& info) in isOffloadSupported()
878 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in isOffloadSupported()
883 status_t AudioSystem::listAudioPorts(audio_port_role_t role, in listAudioPorts()
889 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioPorts()
894 status_t AudioSystem::getAudioPort(struct audio_port *port) in getAudioPort()
896 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getAudioPort()
901 status_t AudioSystem::createAudioPatch(const struct audio_patch *patch, in createAudioPatch()
904 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in createAudioPatch()
909 status_t AudioSystem::releaseAudioPatch(audio_patch_handle_t handle) in releaseAudioPatch()
911 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseAudioPatch()
916 status_t AudioSystem::listAudioPatches(unsigned int *num_patches, in listAudioPatches()
920 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in listAudioPatches()
925 status_t AudioSystem::setAudioPortConfig(const struct audio_port_config *config) in setAudioPortConfig()
927 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in setAudioPortConfig()
932 void AudioSystem::setAudioPortCallback(sp<AudioPortCallback> callBack) in setAudioPortCallback()
938 status_t AudioSystem::acquireSoundTriggerSession(audio_session_t *session, in acquireSoundTriggerSession()
942 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in acquireSoundTriggerSession()
947 status_t AudioSystem::releaseSoundTriggerSession(audio_session_t session) in releaseSoundTriggerSession()
949 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in releaseSoundTriggerSession()
954 audio_mode_t AudioSystem::getPhoneState() in getPhoneState()
956 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in getPhoneState()
961 status_t AudioSystem::registerPolicyMixes(Vector<AudioMix> mixes, bool registration) in registerPolicyMixes()
963 const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service(); in registerPolicyMixes()
970 void AudioSystem::AudioPolicyServiceClient::binderDied(const wp<IBinder>& who __unused) in binderDied()
980 AudioSystem::gAudioPolicyService.clear(); in binderDied()
986 void AudioSystem::AudioPolicyServiceClient::onAudioPortListUpdate() in onAudioPortListUpdate()
994 void AudioSystem::AudioPolicyServiceClient::onAudioPatchListUpdate() in onAudioPatchListUpdate()