Documentation
¶
Overview ¶
Package audiorecorder records from the microphone to an AAC file, for a voice memo, say. Pause and Resume work, and the file comes back as bytes from Stop. For one spoken turn that ends by itself, see the audio plugin.
nimbus native plugin add audio-recorder
if ok, _ := audiorecorder.Request(ctx); ok {
audiorecorder.Start(ctx)
}
r, err := audiorecorder.Stop(ctx)
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Recording ¶
type Recording struct {
Data []byte `json:"data"` // the file
Type string `json:"type"` // its MIME type, "audio/mp4"
Seconds float64 `json:"seconds"` // how long it runs
}
Recording is a finished recording.
Click to show internal directories.
Click to hide internal directories.