feilong
V2EX  ›  Android

请问安卓手机连接带有麦克风的耳机后还能通过手机上的麦克风捕捉声音么?

  •  
  •   feilong · Jan 18, 2019 · 13776 views
    This topic created in 2847 days ago, the information mentioned may be changed or developed.
    3 replies  •  2019-02-17 00:42:16 +08:00
    python35
    python35
    Jan 18, 2019
    1
    如果是安卓开发者的话,有一个 AudioSource 参数可以调整,建议直接看安卓 api 文档
    wanwaneryide
    wanwaneryide
    Jan 19, 2019
    2
    有时间问,还是自己实测一下,才几分钟的事
    Kosmos
    Kosmos
    Feb 17, 2019
    3
    当然可以,插入耳机时系统默认会关闭手机自带的麦。
    这时想用系统的麦克风直接调 api 切换音源就行了:MediaRecorder.AudioSource.MIC
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   3227 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 10:37 · PVG 18:37 · LAX 02:37 · JFK 05:37
    ♥ Do have faith in what you're doing.