Beispiel #1
0
// GL_GetSwapInterval (https://wiki.libsdl.org/SDL_GL_GetSwapInterval)
func GL_GetSwapInterval() (int, error) {
	i := int(C.SDL_GL_GetSwapInterval())
	if i == -1 {
		return i, GetError()
	}
	return i, nil
}
Beispiel #2
0
func GL_GetSwapInterval() (bool, error) {
	interval := C.SDL_GL_GetSwapInterval()
	if interval < 0 {
		return false, getError()
	}

	return interval == 1, nil
}
Beispiel #3
0
func GL_GetSwapInterval() int {
	return (int)(C.SDL_GL_GetSwapInterval())
}