扮演的是在通话过程中存储在手机内存音频剪辑 [英] play an audio clip that is stored in Phone Memory during the phone call

查看:693
本文介绍了扮演的是在通话过程中存储在手机内存音频剪辑的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何发挥是在通话过程中存储在手机内存音频剪辑,和相同的音频片段应该听到呼叫接收器...

How to play an Audio clip that is stored in Phone Memory during the Phone call, and the same Audio clip should hear to Call receiver...

我是用简单的code:

I am using simple code:

   public void onCallStateChanged(int state, String incomingNumber) {
    String stateString = "N/A";
    switch (state) {
    case TelephonyManager.CALL_STATE_IDLE:
      stateString = "Idle";
      break;
    case TelephonyManager.CALL_STATE_OFFHOOK:
      stateString = "Off Hook";
      break;
    case TelephonyManager.CALL_STATE_RINGING:
      stateString = "Ringing";
      break;

  } 

我真的不知道该怎么写code为播放音频文件自动接收器时会挑我的电话只针对一个特定的数字......

Really I don't know how to write code to play audio file automatically while receiver will pick my call only for a particular number.....

推荐答案

有在地方播放音乐超过语音呼叫的上行没有API中的Andr​​oid。有可能是手机在那里支持它(我没有测试过的每一个Android手机),但在总体上是行不通的。结果
你可以在最好的路由音乐扬声器,设置媒体音量到最大,并希望它得到由麦克风拾取。这听起来可怕了,所以它不是我推荐的。

There's no API in place in Android for playing audio over the voice call uplink. There may be phones out there that support it (I have not tested every single Android phone) but in general it's not going to work.
The best you could to is route the music to the loudspeaker, set the media volume to max and hope that it gets picked up by the microphone. That would sound awful though, so it's not something I'd recommend.

这篇关于扮演的是在通话过程中存储在手机内存音频剪辑的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆