mirror of
https://github.com/vsariola/sointu.git
synced 2025-07-14 02:54:37 -04:00
style: add comments to the public methods and members in the root package.
This commit is contained in:
8
audio.go
8
audio.go
@ -1,10 +1,18 @@
|
||||
package sointu
|
||||
|
||||
// AudioSink represents something where we can send audio e.g. audio output.
|
||||
// WriteAudio should block if not ready to accept audio e.g. buffer full.
|
||||
type AudioSink interface {
|
||||
WriteAudio(buffer []float32) error
|
||||
Close() error
|
||||
}
|
||||
|
||||
// AudioContext represents the low-level audio drivers. There should be at most
|
||||
// one AudioContext at a time. The interface is implemented at least by
|
||||
// oto.OtoContext, but in future we could also mock it.
|
||||
//
|
||||
// AudioContext is used to create one or more AudioSinks with Output(); each can
|
||||
// be used to output separate sound & closed when done.
|
||||
type AudioContext interface {
|
||||
Output() AudioSink
|
||||
Close() error
|
||||
|
Reference in New Issue
Block a user