Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FloatBufferTo16BitLE ¶
func FloatBufferTo16BitLE(from sointu.AudioBuffer, to []byte) []byte
FloatBufferTo16BitLE is a naive helper method to convert []float32 buffers to 16-bit little-endian, but encoded in byte buffer
Appends the encoded bytes into "to" slice, allowing you to preallocate the capacity or just use nil
Types ¶
type OtoContext ¶
func NewContext ¶
func NewContext() (*OtoContext, error)
NewPlayer creates and initializes a new OtoPlayer
func (*OtoContext) Close ¶
func (c *OtoContext) Close() error
func (*OtoContext) Output ¶
func (c *OtoContext) Output() sointu.AudioOutput
type OtoOutput ¶
type OtoOutput struct {
// contains filtered or unexported fields
}
func (*OtoOutput) WriteAudio ¶
func (o *OtoOutput) WriteAudio(floatBuffer sointu.AudioBuffer) (err error)
Play implements the audio.Player interface for OtoPlayer
Click to show internal directories.
Click to hide internal directories.