Interface IMicManager
麥克風管理介面,負責開啟與關閉本地麥克風。
public interface IMicManager
Methods
EndLocalMic()
Stops recording.
void EndLocalMic()
RequestPermission()
Request that the user grant access to a Microphone.
void RequestPermission()
StartLocalMic(bool, int, int, bool)
Start Recording with device.
AudioClip StartLocalMic(bool loop = true, int lengthSec = 10, int frequency = 44100, bool leapSync = false)
Parameters
loopboolIndicates whether the recording should continue recording if lengthSec is reached, and wrap around and record from the beginning of the AudioClip.
lengthSecintIs the length of the AudioClip produced by the recording.
frequencyintThe sample rate of the AudioClip produced by the recording.
leapSyncbool
Returns
- AudioClip
The function returns null if the recording fails to start.