Beispiel #1
0
// AvailableToWrite returns the number of frames that
// can be written from the stream without waiting.
func (s *Stream) AvailableToWrite() (int, error) {
	n := C.Pa_GetStreamWriteAvailable(s.paStream)
	if n < 0 {
		return 0, newError(C.PaError(n))
	}
	return int(n), nil
}
Beispiel #2
0
// GetStreamWriteAvailable function as declared in portaudio/portaudio.h:1146
func GetStreamWriteAvailable(stream *Stream) int {
	cstream, _ := (unsafe.Pointer)(unsafe.Pointer(stream)), cgoAllocsUnknown
	__ret := C.Pa_GetStreamWriteAvailable(cstream)
	__v := (int)(__ret)
	return __v
}