Example #1
0
func (id AudioDeviceID) PauseAudio(p bool) {
	var cp C.int
	if p {
		cp = 1
	}

	C.SDL_PauseAudioDevice(C.SDL_AudioDeviceID(id), cp)
}
Example #2
0
func (id AudioDeviceID) c() C.SDL_AudioDeviceID {
	return C.SDL_AudioDeviceID(id)
}
Example #3
0
func UnlockAudioDevice(dev AudioDeviceID) {
	C.SDL_UnlockAudioDevice(C.SDL_AudioDeviceID(int(dev)))
}
Example #4
0
func LockAudioDevice(dev AudioDeviceID) {
	C.SDL_LockAudioDevice(C.SDL_AudioDeviceID(int(dev)))
}
Example #5
0
func PauseAudioDevice(dev AudioDeviceID, pause_on bool) {
	C.SDL_PauseAudioDevice(C.SDL_AudioDeviceID(int(dev)), C.int(bool2int(pause_on)))
}
Example #6
0
func GetAudioDeviceStatus(dev AudioDeviceID) int {
	return int(C.SDL_GetAudioDeviceStatus(C.SDL_AudioDeviceID(int(dev))))
}
Example #7
0
func (dev AudioDeviceID) Close() {
	C.SDL_CloseAudioDevice(C.SDL_AudioDeviceID(dev))
}
Example #8
0
func (dev AudioDeviceID) Unlock() {
	C.SDL_UnlockAudioDevice(C.SDL_AudioDeviceID(dev))
}
Example #9
0
func (dev AudioDeviceID) Lock() {
	C.SDL_LockAudioDevice(C.SDL_AudioDeviceID(dev))
}
Example #10
0
func (id AudioDeviceID) GetStatus() AudioStatus {
	return AudioStatus(C.SDL_GetAudioDeviceStatus(C.SDL_AudioDeviceID(id)))
}