从麦克风声音输入触发事件 [英] Trigger event on sound input from mic
问题描述
我试图做出一种尖利和响亮的声音在我的平板电脑话筒听到会发生反应的应用程序。
I'm trying to make an application that'll react when a sharp and loud sound will be heard in my tablets microphone.
我想知道如果有可能触发此类事件,并有可能设置一些门槛为输入的声音层次。
What I want to know is if it's possible to trigger such an event and is it possible to set some sort of threshold for the sound level of the input.
感谢
推荐答案
检查这些链接了
http://stackoverflow.com/a/6116694/530933
这导致本
<一个href=\"http://$c$c.google.com/p/android-labs/source/browse/trunk/NoiseAlert/src/com/google/android/noisealert/SoundMeter.java?r=2\" rel=\"nofollow\">http://$c$c.google.com/p/android-labs/source/browse/trunk/NoiseAlert/src/com/google/android/noisealert/SoundMeter.java?r=2
但它只是监听麦克风,然后触发您的事件时噪音水平够高的问题。
But its just a matter of listening on the microphone then triggering your event when sound levels are high enough
这篇关于从麦克风声音输入触发事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!