Microphone

Record the player's default Windows microphone as PCM WAVE data.

The ue.microphone namespace records voice input for persistent Lua sessions. Capture runs outside the Unreal game thread; completion callbacks return to the game thread, where it is safe to call reflected Blueprint functions.

Only one Lua microphone capture can be active in the game process at a time.

Typical flow

  1. Call microphone.start when push-to-talk begins.
  2. Call microphone.stop when push-to-talk ends.
  3. Upload result.wav with http.request using a multipart file part.
  4. Pass the transcription text to a Blueprint function or UI.

Functions

FunctionDescription
microphone.startStart recording from the default input device.
microphone.stopFinish recording and receive WAV bytes.
microphone.cancelStop and discard a capture.

Note: Windows microphone privacy settings still apply. If capture cannot open the device, the stop callback reports the device error.

On this page