Exemplo n.º 1
0
// AudioDeviceCount returns the number of devices for audio output. These devices
// are hardware oriented like analog or digital output of sound cards.
func (this *Instance) AudioDeviceCount(output string) (int, error) {
	if this.ptr == nil {
		return 0, syscall.EINVAL
	}

	c := C.CString(output)
	defer C.free(unsafe.Pointer(c))
	return int(C.libvlc_audio_output_device_count(this.ptr, c)), checkError()
}
Exemplo n.º 2
0
// AudioDeviceCount returns the number of devices for audio output. These devices
// are hardware oriented like analog or digital output of sound cards.
func (this *Player) AudioDeviceCount(output string) (int, error) {
	if this.ptr == nil {
		return 0, &VLCError{"Player is nil"}
	}

	c := C.CString(output)
	defer C.free(unsafe.Pointer(c))
	return int(C.libvlc_audio_output_device_count(this.ptr, c)), checkError()
}