Documentation
¶
Overview ¶
Package glut provides a fluent Go API over the macOS GLUT framework.
Construction ¶
New… functions create objects; each With… method sets one property and returns its receiver, so configuration calls chain. A <Type>FromID constructor adopts an Objective-C object obtained elsewhere.
Lifecycle ¶
A wrapper releases its Objective-C object automatically once the garbage collector finds it unreachable. Call Release to relinquish the reference deterministically (for objects holding scarce resources); Release is idempotent, and afterwards the wrapper's methods are no-ops returning zero values.
Index ¶
- func AddMenuEntry(label string, value int)
- func AddSubMenu(label string, submenu int)
- func AttachMenu(button int)
- func BitmapCharacter(font unsafe.Pointer, character int)
- func BitmapLength(font unsafe.Pointer) (result int, str uint8)
- func BitmapWidth(font unsafe.Pointer, character int) int
- func ButtonBoxFunc(func_ unsafe.Pointer)
- func ChangeToMenuEntry(item int, label string, value int)
- func ChangeToSubMenu(item int, label string, submenu int)
- func CheckLoop()
- func CopyColormap(win int)
- func CreateMenu(arg unsafe.Pointer) int
- func CreateSubWindow(win int, x int, y int, width int, height int) int
- func CreateWindow(title string) int
- func DestroyMenu(menu int)
- func DestroyWindow(win int)
- func DetachMenu(button int)
- func DeviceGet(type_ uint32) int
- func DialsFunc(func_ unsafe.Pointer)
- func DisplayFunc(func_ unsafe.Pointer)
- func EnterGameMode() int
- func EntryFunc(func_ unsafe.Pointer)
- func EstablishOverlay()
- func ExtensionSupported(name string) int
- func ForceJoystickFunc()
- func FullScreen()
- func GameModeGet(mode uint32) int
- func GameModeString(str string)
- func Get(type_ uint32) int
- func GetColor(ndx int, component int) float32
- func GetMenu() int
- func GetModifiers() int
- func GetProcAddress(procName string) unsafe.Pointer
- func GetWindow() int
- func GlutBitmap8By13() uintptr
- func GlutBitmap9By15() uintptr
- func GlutBitmapHelvetica10() uintptr
- func GlutBitmapHelvetica12() uintptr
- func GlutBitmapHelvetica18() uintptr
- func GlutBitmapTimesRoman10() uintptr
- func GlutBitmapTimesRoman24() uintptr
- func GlutStrokeMonoRoman() uintptr
- func GlutStrokeRoman() uintptr
- func HideOverlay()
- func HideWindow()
- func IconifyWindow()
- func IdleFunc(func_ unsafe.Pointer)
- func IgnoreKeyRepeat(ignore int)
- func Init(argv string) (argcp int32)
- func InitDisplayMode(mode int)
- func InitDisplayString(str string)
- func InitWindowPosition(x int, y int)
- func InitWindowSize(width int, height int)
- func JoystickFunc(func_ unsafe.Pointer, pollInterval int)
- func KeyboardFunc(func_ unsafe.Pointer)
- func KeyboardUpFunc(func_ unsafe.Pointer)
- func LayerGet(type_ uint32) int
- func LeaveGameMode()
- func MainLoop()
- func MenuStateFunc(func_ unsafe.Pointer)
- func MenuStatusFunc(func_ unsafe.Pointer)
- func MotionFunc(func_ unsafe.Pointer)
- func MouseFunc(func_ unsafe.Pointer)
- func OverlayDisplayFunc(func_ unsafe.Pointer)
- func PassiveMotionFunc(func_ unsafe.Pointer)
- func PopWindow()
- func PositionWindow(x int, y int)
- func PostOverlayRedisplay()
- func PostRedisplay()
- func PostWindowOverlayRedisplay(win int)
- func PostWindowRedisplay(win int)
- func PushWindow()
- func RemoveMenuItem(item int)
- func RemoveOverlay()
- func ReportErrors()
- func ReshapeFunc(func_ unsafe.Pointer)
- func ReshapeWindow(width int, height int)
- func SetColor(arg int, red float32, green float32, blue float32)
- func SetCursor(cursor int)
- func SetIconTitle(title string)
- func SetKeyRepeat(repeatMode int)
- func SetMenu(menu int)
- func SetWindow(win int)
- func SetWindowTitle(title string)
- func SetupVideoResizing()
- func ShowOverlay()
- func ShowWindow()
- func SolidCone(base float64, height float64, slices int32, stacks int32)
- func SolidCube(size float64)
- func SolidDodecahedron()
- func SolidIcosahedron()
- func SolidOctahedron()
- func SolidSphere(radius float64, slices int32, stacks int32)
- func SolidTeapot(size float64)
- func SolidTetrahedron()
- func SolidTorus(innerRadius float64, outerRadius float64, sides int32, rings int32)
- func SpaceballButtonFunc(func_ unsafe.Pointer)
- func SpaceballMotionFunc(func_ unsafe.Pointer)
- func SpaceballRotateFunc(func_ unsafe.Pointer)
- func SpecialFunc(func_ unsafe.Pointer)
- func SpecialUpFunc(func_ unsafe.Pointer)
- func StopVideoResizing()
- func StrokeCharacter(font unsafe.Pointer, character int)
- func StrokeLength(font unsafe.Pointer) (result int, str uint8)
- func StrokeWidth(font unsafe.Pointer, character int) int
- func SurfaceTexture(target uint32, internalformat uint32, surfacewin int)
- func SwapBuffers()
- func TabletButtonFunc(func_ unsafe.Pointer)
- func TabletMotionFunc(func_ unsafe.Pointer)
- func TimerFunc(millis int, func_ unsafe.Pointer, value int)
- func UseLayer(layer uint32)
- func VideoPan(x int, y int, width int, height int)
- func VideoResize(x int, y int, width int, height int)
- func VideoResizeGet(param uint32) int
- func VisibilityFunc(func_ unsafe.Pointer)
- func WMCloseFunc(func_ unsafe.Pointer)
- func WarpPointer(x int, y int)
- func WindowStatusFunc(func_ unsafe.Pointer)
- func WireCone(base float64, height float64, slices int32, stacks int32)
- func WireCube(size float64)
- func WireDodecahedron()
- func WireIcosahedron()
- func WireOctahedron()
- func WireSphere(radius float64, slices int32, stacks int32)
- func WireTeapot(size float64)
- func WireTetrahedron()
- func WireTorus(innerRadius float64, outerRadius float64, sides int32, rings int32)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddMenuEntry ¶ added in v0.17.0
AddMenuEntry calls the GLUT framework function glutAddMenuEntry.
func AddSubMenu ¶ added in v0.17.0
AddSubMenu calls the GLUT framework function glutAddSubMenu.
func AttachMenu ¶ added in v0.17.0
func AttachMenu(button int)
AttachMenu calls the GLUT framework function glutAttachMenu.
func BitmapCharacter ¶ added in v0.17.0
BitmapCharacter calls the GLUT framework function glutBitmapCharacter.
func BitmapLength ¶ added in v0.17.0
BitmapLength calls the GLUT framework function glutBitmapLength.
func BitmapWidth ¶ added in v0.17.0
BitmapWidth calls the GLUT framework function glutBitmapWidth.
func ButtonBoxFunc ¶ added in v0.17.0
ButtonBoxFunc calls the GLUT framework function glutButtonBoxFunc.
func ChangeToMenuEntry ¶ added in v0.17.0
ChangeToMenuEntry calls the GLUT framework function glutChangeToMenuEntry.
func ChangeToSubMenu ¶ added in v0.17.0
ChangeToSubMenu calls the GLUT framework function glutChangeToSubMenu.
func CheckLoop ¶ added in v0.17.0
func CheckLoop()
CheckLoop calls the GLUT framework function glutCheckLoop.
func CopyColormap ¶ added in v0.17.0
func CopyColormap(win int)
CopyColormap calls the GLUT framework function glutCopyColormap.
func CreateMenu ¶ added in v0.17.0
CreateMenu calls the GLUT framework function glutCreateMenu.
func CreateSubWindow ¶ added in v0.17.0
CreateSubWindow calls the GLUT framework function glutCreateSubWindow.
func CreateWindow ¶ added in v0.17.0
CreateWindow calls the GLUT framework function glutCreateWindow.
func DestroyMenu ¶ added in v0.17.0
func DestroyMenu(menu int)
DestroyMenu calls the GLUT framework function glutDestroyMenu.
func DestroyWindow ¶ added in v0.17.0
func DestroyWindow(win int)
DestroyWindow calls the GLUT framework function glutDestroyWindow.
func DetachMenu ¶ added in v0.17.0
func DetachMenu(button int)
DetachMenu calls the GLUT framework function glutDetachMenu.
func DisplayFunc ¶ added in v0.17.0
DisplayFunc calls the GLUT framework function glutDisplayFunc.
func EnterGameMode ¶ added in v0.17.0
func EnterGameMode() int
EnterGameMode calls the GLUT framework function glutEnterGameMode.
func EstablishOverlay ¶ added in v0.17.0
func EstablishOverlay()
EstablishOverlay calls the GLUT framework function glutEstablishOverlay.
func ExtensionSupported ¶ added in v0.17.0
ExtensionSupported calls the GLUT framework function glutExtensionSupported.
func ForceJoystickFunc ¶ added in v0.17.0
func ForceJoystickFunc()
ForceJoystickFunc calls the GLUT framework function glutForceJoystickFunc.
func FullScreen ¶ added in v0.17.0
func FullScreen()
FullScreen calls the GLUT framework function glutFullScreen.
func GameModeGet ¶ added in v0.17.0
GameModeGet calls the GLUT framework function glutGameModeGet.
func GameModeString ¶ added in v0.17.0
func GameModeString(str string)
GameModeString calls the GLUT framework function glutGameModeString.
func GetMenu ¶ added in v0.17.0
func GetMenu() int
GetMenu calls the GLUT framework function glutGetMenu.
func GetModifiers ¶ added in v0.17.0
func GetModifiers() int
GetModifiers calls the GLUT framework function glutGetModifiers.
func GetProcAddress ¶ added in v0.17.0
GetProcAddress calls the GLUT framework function glutGetProcAddress.
func GetWindow ¶ added in v0.17.0
func GetWindow() int
GetWindow calls the GLUT framework function glutGetWindow.
func GlutBitmap8By13 ¶
func GlutBitmap8By13() uintptr
GlutBitmap8By13 returns the address of the symbol glutBitmap8By13.
func GlutBitmap9By15 ¶
func GlutBitmap9By15() uintptr
GlutBitmap9By15 returns the address of the symbol glutBitmap9By15.
func GlutBitmapHelvetica10 ¶
func GlutBitmapHelvetica10() uintptr
GlutBitmapHelvetica10 returns the address of the symbol glutBitmapHelvetica10.
func GlutBitmapHelvetica12 ¶
func GlutBitmapHelvetica12() uintptr
GlutBitmapHelvetica12 returns the address of the symbol glutBitmapHelvetica12.
func GlutBitmapHelvetica18 ¶
func GlutBitmapHelvetica18() uintptr
GlutBitmapHelvetica18 returns the address of the symbol glutBitmapHelvetica18.
func GlutBitmapTimesRoman10 ¶
func GlutBitmapTimesRoman10() uintptr
GlutBitmapTimesRoman10 returns the address of the symbol glutBitmapTimesRoman10.
func GlutBitmapTimesRoman24 ¶
func GlutBitmapTimesRoman24() uintptr
GlutBitmapTimesRoman24 returns the address of the symbol glutBitmapTimesRoman24.
func GlutStrokeMonoRoman ¶
func GlutStrokeMonoRoman() uintptr
GlutStrokeMonoRoman returns the address of the symbol glutStrokeMonoRoman.
func GlutStrokeRoman ¶
func GlutStrokeRoman() uintptr
GlutStrokeRoman returns the address of the symbol glutStrokeRoman.
func HideOverlay ¶ added in v0.17.0
func HideOverlay()
HideOverlay calls the GLUT framework function glutHideOverlay.
func HideWindow ¶ added in v0.17.0
func HideWindow()
HideWindow calls the GLUT framework function glutHideWindow.
func IconifyWindow ¶ added in v0.17.0
func IconifyWindow()
IconifyWindow calls the GLUT framework function glutIconifyWindow.
func IgnoreKeyRepeat ¶ added in v0.17.0
func IgnoreKeyRepeat(ignore int)
IgnoreKeyRepeat calls the GLUT framework function glutIgnoreKeyRepeat.
func InitDisplayMode ¶ added in v0.17.0
func InitDisplayMode(mode int)
InitDisplayMode calls the GLUT framework function glutInitDisplayMode.
func InitDisplayString ¶ added in v0.17.0
func InitDisplayString(str string)
InitDisplayString calls the GLUT framework function glutInitDisplayString.
func InitWindowPosition ¶ added in v0.17.0
InitWindowPosition calls the GLUT framework function glutInitWindowPosition.
func InitWindowSize ¶ added in v0.17.0
InitWindowSize calls the GLUT framework function glutInitWindowSize.
func JoystickFunc ¶ added in v0.17.0
JoystickFunc calls the GLUT framework function glutJoystickFunc.
func KeyboardFunc ¶ added in v0.17.0
KeyboardFunc calls the GLUT framework function glutKeyboardFunc.
func KeyboardUpFunc ¶ added in v0.17.0
KeyboardUpFunc calls the GLUT framework function glutKeyboardUpFunc.
func LeaveGameMode ¶ added in v0.17.0
func LeaveGameMode()
LeaveGameMode calls the GLUT framework function glutLeaveGameMode.
func MainLoop ¶ added in v0.17.0
func MainLoop()
MainLoop calls the GLUT framework function glutMainLoop.
func MenuStateFunc ¶ added in v0.17.0
MenuStateFunc calls the GLUT framework function glutMenuStateFunc.
func MenuStatusFunc ¶ added in v0.17.0
MenuStatusFunc calls the GLUT framework function glutMenuStatusFunc.
func MotionFunc ¶ added in v0.17.0
MotionFunc calls the GLUT framework function glutMotionFunc.
func OverlayDisplayFunc ¶ added in v0.17.0
OverlayDisplayFunc calls the GLUT framework function glutOverlayDisplayFunc.
func PassiveMotionFunc ¶ added in v0.17.0
PassiveMotionFunc calls the GLUT framework function glutPassiveMotionFunc.
func PopWindow ¶ added in v0.17.0
func PopWindow()
PopWindow calls the GLUT framework function glutPopWindow.
func PositionWindow ¶ added in v0.17.0
PositionWindow calls the GLUT framework function glutPositionWindow.
func PostOverlayRedisplay ¶ added in v0.17.0
func PostOverlayRedisplay()
PostOverlayRedisplay calls the GLUT framework function glutPostOverlayRedisplay.
func PostRedisplay ¶ added in v0.17.0
func PostRedisplay()
PostRedisplay calls the GLUT framework function glutPostRedisplay.
func PostWindowOverlayRedisplay ¶ added in v0.17.0
func PostWindowOverlayRedisplay(win int)
PostWindowOverlayRedisplay calls the GLUT framework function glutPostWindowOverlayRedisplay.
func PostWindowRedisplay ¶ added in v0.17.0
func PostWindowRedisplay(win int)
PostWindowRedisplay calls the GLUT framework function glutPostWindowRedisplay.
func PushWindow ¶ added in v0.17.0
func PushWindow()
PushWindow calls the GLUT framework function glutPushWindow.
func RemoveMenuItem ¶ added in v0.17.0
func RemoveMenuItem(item int)
RemoveMenuItem calls the GLUT framework function glutRemoveMenuItem.
func RemoveOverlay ¶ added in v0.17.0
func RemoveOverlay()
RemoveOverlay calls the GLUT framework function glutRemoveOverlay.
func ReportErrors ¶ added in v0.17.0
func ReportErrors()
ReportErrors calls the GLUT framework function glutReportErrors.
func ReshapeFunc ¶ added in v0.17.0
ReshapeFunc calls the GLUT framework function glutReshapeFunc.
func ReshapeWindow ¶ added in v0.17.0
ReshapeWindow calls the GLUT framework function glutReshapeWindow.
func SetCursor ¶ added in v0.17.0
func SetCursor(cursor int)
SetCursor calls the GLUT framework function glutSetCursor.
func SetIconTitle ¶ added in v0.17.0
func SetIconTitle(title string)
SetIconTitle calls the GLUT framework function glutSetIconTitle.
func SetKeyRepeat ¶ added in v0.17.0
func SetKeyRepeat(repeatMode int)
SetKeyRepeat calls the GLUT framework function glutSetKeyRepeat.
func SetMenu ¶ added in v0.17.0
func SetMenu(menu int)
SetMenu calls the GLUT framework function glutSetMenu.
func SetWindow ¶ added in v0.17.0
func SetWindow(win int)
SetWindow calls the GLUT framework function glutSetWindow.
func SetWindowTitle ¶ added in v0.17.0
func SetWindowTitle(title string)
SetWindowTitle calls the GLUT framework function glutSetWindowTitle.
func SetupVideoResizing ¶ added in v0.17.0
func SetupVideoResizing()
SetupVideoResizing calls the GLUT framework function glutSetupVideoResizing.
func ShowOverlay ¶ added in v0.17.0
func ShowOverlay()
ShowOverlay calls the GLUT framework function glutShowOverlay.
func ShowWindow ¶ added in v0.17.0
func ShowWindow()
ShowWindow calls the GLUT framework function glutShowWindow.
func SolidCube ¶ added in v0.17.0
func SolidCube(size float64)
SolidCube calls the GLUT framework function glutSolidCube.
func SolidDodecahedron ¶ added in v0.17.0
func SolidDodecahedron()
SolidDodecahedron calls the GLUT framework function glutSolidDodecahedron.
func SolidIcosahedron ¶ added in v0.17.0
func SolidIcosahedron()
SolidIcosahedron calls the GLUT framework function glutSolidIcosahedron.
func SolidOctahedron ¶ added in v0.17.0
func SolidOctahedron()
SolidOctahedron calls the GLUT framework function glutSolidOctahedron.
func SolidSphere ¶ added in v0.17.0
SolidSphere calls the GLUT framework function glutSolidSphere.
func SolidTeapot ¶ added in v0.17.0
func SolidTeapot(size float64)
SolidTeapot calls the GLUT framework function glutSolidTeapot.
func SolidTetrahedron ¶ added in v0.17.0
func SolidTetrahedron()
SolidTetrahedron calls the GLUT framework function glutSolidTetrahedron.
func SolidTorus ¶ added in v0.17.0
SolidTorus calls the GLUT framework function glutSolidTorus.
func SpaceballButtonFunc ¶ added in v0.17.0
SpaceballButtonFunc calls the GLUT framework function glutSpaceballButtonFunc.
func SpaceballMotionFunc ¶ added in v0.17.0
SpaceballMotionFunc calls the GLUT framework function glutSpaceballMotionFunc.
func SpaceballRotateFunc ¶ added in v0.17.0
SpaceballRotateFunc calls the GLUT framework function glutSpaceballRotateFunc.
func SpecialFunc ¶ added in v0.17.0
SpecialFunc calls the GLUT framework function glutSpecialFunc.
func SpecialUpFunc ¶ added in v0.17.0
SpecialUpFunc calls the GLUT framework function glutSpecialUpFunc.
func StopVideoResizing ¶ added in v0.17.0
func StopVideoResizing()
StopVideoResizing calls the GLUT framework function glutStopVideoResizing.
func StrokeCharacter ¶ added in v0.17.0
StrokeCharacter calls the GLUT framework function glutStrokeCharacter.
func StrokeLength ¶ added in v0.17.0
StrokeLength calls the GLUT framework function glutStrokeLength.
func StrokeWidth ¶ added in v0.17.0
StrokeWidth calls the GLUT framework function glutStrokeWidth.
func SurfaceTexture ¶ added in v0.17.0
SurfaceTexture calls the GLUT framework function glutSurfaceTexture.
func SwapBuffers ¶ added in v0.17.0
func SwapBuffers()
SwapBuffers calls the GLUT framework function glutSwapBuffers.
func TabletButtonFunc ¶ added in v0.17.0
TabletButtonFunc calls the GLUT framework function glutTabletButtonFunc.
func TabletMotionFunc ¶ added in v0.17.0
TabletMotionFunc calls the GLUT framework function glutTabletMotionFunc.
func UseLayer ¶ added in v0.17.0
func UseLayer(layer uint32)
UseLayer calls the GLUT framework function glutUseLayer.
func VideoResize ¶ added in v0.17.0
VideoResize calls the GLUT framework function glutVideoResize.
func VideoResizeGet ¶ added in v0.17.0
VideoResizeGet calls the GLUT framework function glutVideoResizeGet.
func VisibilityFunc ¶ added in v0.17.0
VisibilityFunc calls the GLUT framework function glutVisibilityFunc.
func WMCloseFunc ¶ added in v0.17.0
WMCloseFunc calls the GLUT framework function glutWMCloseFunc.
func WarpPointer ¶ added in v0.17.0
WarpPointer calls the GLUT framework function glutWarpPointer.
func WindowStatusFunc ¶ added in v0.17.0
WindowStatusFunc calls the GLUT framework function glutWindowStatusFunc.
func WireCube ¶ added in v0.17.0
func WireCube(size float64)
WireCube calls the GLUT framework function glutWireCube.
func WireDodecahedron ¶ added in v0.17.0
func WireDodecahedron()
WireDodecahedron calls the GLUT framework function glutWireDodecahedron.
func WireIcosahedron ¶ added in v0.17.0
func WireIcosahedron()
WireIcosahedron calls the GLUT framework function glutWireIcosahedron.
func WireOctahedron ¶ added in v0.17.0
func WireOctahedron()
WireOctahedron calls the GLUT framework function glutWireOctahedron.
func WireSphere ¶ added in v0.17.0
WireSphere calls the GLUT framework function glutWireSphere.
func WireTeapot ¶ added in v0.17.0
func WireTeapot(size float64)
WireTeapot calls the GLUT framework function glutWireTeapot.
func WireTetrahedron ¶ added in v0.17.0
func WireTetrahedron()
WireTetrahedron calls the GLUT framework function glutWireTetrahedron.
Types ¶
This section is empty.