Exemple #1
0
func GetDisplayMode(i int, m int) (*DisplayMode, error) {
	var dm DisplayMode
	if C.SDL_GetDisplayMode(C.int(i), C.int(m), dm.c()) != 0 {
		return nil, getError()
	}

	return &dm, nil
}
Exemple #2
0
func GetDisplayMode(displayIndex int, modeIndex int, mode *DisplayMode) int {
	_displayIndex := (C.int)(displayIndex)
	_modeIndex := (C.int)(modeIndex)
	_mode := (*C.SDL_DisplayMode)(unsafe.Pointer(mode))
	return (int)(C.SDL_GetDisplayMode(_displayIndex, _modeIndex, _mode))
}
Exemple #3
0
// GetDisplayMode (https://wiki.libsdl.org/SDL_GetDisplayMode)
func GetDisplayMode(displayIndex int, modeIndex int, mode *DisplayMode) error {
	if C.SDL_GetDisplayMode(C.int(displayIndex), C.int(modeIndex), mode.cptr()) != 0 {
		return GetError()
	}
	return nil
}
Exemple #4
0
func GetDisplayMode(displayIndex int, modeIndex int, mode *DisplayMode) int {
	return int(C.SDL_GetDisplayMode(C.int(displayIndex), C.int(modeIndex), mode.cptr()))
}