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