diff options
author | Steve Kondik <steve@cyngn.com> | 2016-04-23 00:50:06 -0700 |
---|---|---|
committer | Steve Kondik <shade@chemlab.org> | 2016-04-27 23:35:58 -0700 |
commit | 39312b1c0cc17db8c485a072c4e3b2c001c207d2 (patch) | |
tree | 284518e8dc43120974ba8c43d04a98b7052a4f6a /core | |
parent | 766d3bb5e46f262fdade4f1837e6bf421d4b0313 (diff) | |
download | frameworks_base-39312b1c0cc17db8c485a072c4e3b2c001c207d2.zip frameworks_base-39312b1c0cc17db8c485a072c4e3b2c001c207d2.tar.gz frameworks_base-39312b1c0cc17db8c485a072c4e3b2c001c207d2.tar.bz2 |
media: Remove effect session callbacks from the framework
* This API is moving to CMSDK.
Revert "media: Add flags, channelMask, and UID to audio session callbacks"
This reverts commit e0554d493e870ea5e323ed06f54becb93c19fa04.
Revert "audiosystem: Add API for listening to effect session events"
This reverts commit 9957394df71db6f01802091858216582c58eab67.
Change-Id: I5f18fdb3390db25285a5b819dfe2136ae111c0b3
Diffstat (limited to 'core')
-rw-r--r-- | core/jni/android_media_AudioSystem.cpp | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/core/jni/android_media_AudioSystem.cpp b/core/jni/android_media_AudioSystem.cpp index a282a44..91b3278 100644 --- a/core/jni/android_media_AudioSystem.cpp +++ b/core/jni/android_media_AudioSystem.cpp @@ -154,11 +154,6 @@ static struct { jmethodID postDynPolicyEventFromNative; } gDynPolicyEventHandlerMethods; -static struct { - jmethodID postEffectSessionEventFromNative; -} gEffectSessionEventHandlerMethods; - - static Mutex gLock; enum AudioError { @@ -391,25 +386,6 @@ android_media_AudioSystem_dyn_policy_callback(int event, String8 regId, int val) } -static void -android_media_AudioSystem_effect_session_callback(int event, audio_stream_type_t stream, - audio_unique_id_t sessionId, audio_output_flags_t flags, - audio_channel_mask_t channelMask, uid_t uid, bool added) -{ - JNIEnv *env = AndroidRuntime::getJNIEnv(); - if (env == NULL) { - return; - } - - jclass clazz = env->FindClass(kClassPathName); - - env->CallStaticVoidMethod(clazz, gEffectSessionEventHandlerMethods.postEffectSessionEventFromNative, - event, stream, sessionId, flags, channelMask, uid, added); - - env->DeleteLocalRef(clazz); - -} - static jint android_media_AudioSystem_setDeviceConnectionState(JNIEnv *env, jobject thiz, jint device, jint state, jstring device_address, jstring device_name) { @@ -1511,12 +1487,6 @@ android_media_AudioSystem_registerDynPolicyCallback(JNIEnv *env, jobject thiz) AudioSystem::setDynPolicyCallback(android_media_AudioSystem_dyn_policy_callback); } -static void -android_media_AudioSystem_registerEffectSessionCallback(JNIEnv *env, jobject thiz) -{ - AudioSystem::setEffectSessionCallback(android_media_AudioSystem_effect_session_callback); -} - static jint convertAudioMixToNative(JNIEnv *env, AudioMix *nAudioMix, @@ -1689,8 +1659,6 @@ static JNINativeMethod gMethods[] = { (void *)android_media_AudioSystem_registerPolicyMixes}, {"native_register_dynamic_policy_callback", "()V", (void *)android_media_AudioSystem_registerDynPolicyCallback}, - {"native_register_effect_session_callback", "()V", - (void *)android_media_AudioSystem_registerEffectSessionCallback}, {"systemReady", "()I", (void *)android_media_AudioSystem_systemReady}, }; @@ -1798,10 +1766,6 @@ int register_android_media_AudioSystem(JNIEnv *env) GetStaticMethodIDOrDie(env, env->FindClass(kClassPathName), "dynamicPolicyCallbackFromNative", "(ILjava/lang/String;I)V"); - gEffectSessionEventHandlerMethods.postEffectSessionEventFromNative = - GetStaticMethodIDOrDie(env, env->FindClass(kClassPathName), - "effectSessionCallbackFromNative", "(IIIIIIZ)V"); - jclass audioMixClass = FindClassOrDie(env, "android/media/audiopolicy/AudioMix"); gAudioMixClass = MakeGlobalRefOrDie(env, audioMixClass); gAudioMixFields.mRule = GetFieldIDOrDie(env, audioMixClass, "mRule", |