Versions in this module Expand all Collapse all v2 v2.0.7 Mar 14, 2021 Changes in this version + const GamepadButtonNum + var GraphicsNotReady = errors.New("graphics not ready") + var RegularTermination = errors.New("regular termination") + type Address int + const AddressClampToZero + const AddressRepeat + const AddressUnsafe + type CompositeMode int + const CompositeModeClear + const CompositeModeCopy + const CompositeModeDestination + const CompositeModeDestinationAtop + const CompositeModeDestinationIn + const CompositeModeDestinationOut + const CompositeModeDestinationOver + const CompositeModeLighter + const CompositeModeMax + const CompositeModeMultiply + const CompositeModeSourceAtop + const CompositeModeSourceIn + const CompositeModeSourceOut + const CompositeModeSourceOver + const CompositeModeUnknown + const CompositeModeXor + func (c CompositeMode) Operations() (src Operation, dst Operation) + type CursorMode int + const CursorModeCaptured + const CursorModeHidden + const CursorModeVisible + type Event interface + type Filter int + const FilterLinear + const FilterNearest + const FilterScreen + type GamepadAttach struct + Axes int + Buttons int + ID int + type GamepadAxis struct + Axis int + ID int + Position float32 + type GamepadButton int + const GamepadButton0 + const GamepadButton1 + const GamepadButton10 + const GamepadButton11 + const GamepadButton12 + const GamepadButton13 + const GamepadButton14 + const GamepadButton15 + const GamepadButton16 + const GamepadButton17 + const GamepadButton18 + const GamepadButton19 + const GamepadButton2 + const GamepadButton20 + const GamepadButton21 + const GamepadButton22 + const GamepadButton23 + const GamepadButton24 + const GamepadButton25 + const GamepadButton26 + const GamepadButton27 + const GamepadButton28 + const GamepadButton29 + const GamepadButton3 + const GamepadButton30 + const GamepadButton31 + const GamepadButton4 + const GamepadButton5 + const GamepadButton6 + const GamepadButton7 + const GamepadButton8 + const GamepadButton9 + type GamepadButtonDown struct + Button int + ID int + Pressure float32 + type GamepadButtonUp struct + Button int + ID int + Pressure float32 + type GamepadDetach struct + ID int + type GamepadID int + type Graphics interface + Begin func() + Draw func(dst, src ImageID, indexLen int, indexOffset int, mode CompositeMode, ...) error + DrawShader func(dst ImageID, srcs [graphics.ShaderImageNum]ImageID, ...) error + End func() + FramebufferYDirection func() YDirection + HasHighPrecisionFloat func() bool + InvalidImageID func() ImageID + IsGL func() bool + MaxImageSize func() int + NeedsRestoring func() bool + NewImage func(width, height int) (Image, error) + NewScreenFramebufferImage func(width, height int) (Image, error) + NewShader func(program *shaderir.Program) (Shader, error) + Reset func() error + SetTransparent func(transparent bool) + SetVertices func(vertices []float32, indices []uint16) + SetVsyncEnabled func(enabled bool) + type Image interface + Dispose func() + ID func() ImageID + IsInvalidated func() bool + Pixels func() ([]byte, error) + ReplacePixels func(args []*ReplacePixelsArgs) + type ImageID int + type Input interface + CursorPosition func() (x, y int) + GamepadAxis func(id GamepadID, axis int) float64 + GamepadAxisNum func(id GamepadID) int + GamepadButtonNum func(id GamepadID) int + GamepadIDs func() []GamepadID + GamepadName func(id GamepadID) string + GamepadSDLID func(id GamepadID) string + IsGamepadButtonPressed func(id GamepadID, button GamepadButton) bool + IsKeyPressed func(key Key) bool + IsMouseButtonPressed func(button MouseButton) bool + RuneBuffer func() []rune + TouchIDs func() []TouchID + TouchPosition func(id TouchID) (x, y int) + Wheel func() (xoff, yoff float64) + type Key int + const Key0 + const Key1 + const Key2 + const Key3 + const Key4 + const Key5 + const Key6 + const Key7 + const Key8 + const Key9 + const KeyA + const KeyApostrophe + const KeyB + const KeyBackslash + const KeyBackspace + const KeyC + const KeyCapsLock + const KeyComma + const KeyD + const KeyDelete + const KeyDown + const KeyE + const KeyEnd + const KeyEnter + const KeyEqual + const KeyEscape + const KeyF + const KeyF1 + const KeyF10 + const KeyF11 + const KeyF12 + const KeyF2 + const KeyF3 + const KeyF4 + const KeyF5 + const KeyF6 + const KeyF7 + const KeyF8 + const KeyF9 + const KeyG + const KeyGraveAccent + const KeyH + const KeyHome + const KeyI + const KeyInsert + const KeyJ + const KeyK + const KeyKP0 + const KeyKP1 + const KeyKP2 + const KeyKP3 + const KeyKP4 + const KeyKP5 + const KeyKP6 + const KeyKP7 + const KeyKP8 + const KeyKP9 + const KeyKPAdd + const KeyKPDecimal + const KeyKPDivide + const KeyKPEnter + const KeyKPEqual + const KeyKPMultiply + const KeyKPSubtract + const KeyL + const KeyLeft + const KeyLeftAlt + const KeyLeftBracket + const KeyLeftControl + const KeyLeftShift + const KeyLeftSuper + const KeyM + const KeyMenu + const KeyMinus + const KeyN + const KeyNumLock + const KeyO + const KeyP + const KeyPageDown + const KeyPageUp + const KeyPause + const KeyPeriod + const KeyPrintScreen + const KeyQ + const KeyR + const KeyReserved0 + const KeyReserved1 + const KeyReserved2 + const KeyReserved3 + const KeyRight + const KeyRightAlt + const KeyRightBracket + const KeyRightControl + const KeyRightShift + const KeyRightSuper + const KeyS + const KeyScrollLock + const KeySemicolon + const KeySlash + const KeySpace + const KeyT + const KeyTab + const KeyU + const KeyUp + const KeyV + const KeyW + const KeyX + const KeyY + const KeyZ + func (k Key) String() string + type KeyboardKeyCharacter struct + Character rune + Key Key + Modifier Modifier + type KeyboardKeyDown struct + Key Key + Modifier Modifier + type KeyboardKeyUp struct + Key Key + Modifier Modifier + type Modifier int + const ModifierAlt + const ModifierCapsLock + const ModifierControl + const ModifierNumLock + const ModifierShift + type MouseButton int + const MouseButtonLeft + const MouseButtonMiddle + const MouseButtonRight + type MouseButtonDown struct + Button int + Pressure float32 + X float32 + Y float32 + type MouseButtonUp struct + Button int + Pressure float32 + X float32 + Y float32 + type MouseEnter struct + X float32 + Y float32 + type MouseLeave struct + X float32 + Y float32 + type MouseMove struct + DeltaX float32 + DeltaY float32 + X float32 + Y float32 + type MouseWheel struct + DeltaX float32 + DeltaY float32 + X float32 + Y float32 + type Operation int + const DstAlpha + const DstColor + const One + const OneMinusDstAlpha + const OneMinusSrcAlpha + const SrcAlpha + const Zero + type Region struct + Height float32 + Width float32 + X float32 + Y float32 + type ReplacePixelsArgs struct + Height int + Pixels []byte + Width int + X int + Y int + type Shader interface + Dispose func() + ID func() ShaderID + type ShaderID int + type TouchBegin struct + DeltaX float32 + Deltay float32 + ID int + Pressure float32 + Primary bool + X float32 + Y float32 + type TouchCancel struct + ID int + type TouchEnd struct + DeltaX float32 + Deltay float32 + ID int + Pressure float32 + Primary bool + X float32 + Y float32 + type TouchID int + type TouchMove struct + DeltaX float32 + Deltay float32 + ID int + Pressure float32 + Primary bool + X float32 + Y float32 + type UI interface + CursorMode func() CursorMode + DeviceScaleFactor func() float64 + Graphics func() Graphics + Input func() Input + IsFocused func() bool + IsFullscreen func() bool + IsMousePassThru func() bool + IsRunnableOnUnfocused func() bool + IsScreenTransparent func() bool + IsVsyncEnabled func() bool + ResetForFrame func() + Run func(context UIContext) error + RunWithoutMainLoop func(context UIContext) + ScreenSizeInFullscreen func() (int, int) + SetCursorMode func(mode CursorMode) + SetFullscreen func(fullscreen bool) + SetInitFocused func(focused bool) + SetMousePassThru func(passThru bool) + SetRunnableOnUnfocused func(runnableOnUnfocused bool) + SetScreenTransparent func(transparent bool) + SetVsyncEnabled func(enabled bool) + Window func() Window + type UIContext interface + AdjustPosition func(x, y float64, deviceScaleFactor float64) (float64, float64) + ForceUpdate func() error + Layout func(outsideWidth, outsideHeight float64) + Update func() error + type ViewSize struct + Height int + Width int + type ViewUpdate struct + type Window interface + IsDecorated func() bool + IsFloating func() bool + IsMaximized func() bool + IsMinimized func() bool + IsResizable func() bool + Maximize func() + Minimize func() + Position func() (int, int) + Restore func() + SetDecorated func(decorated bool) + SetFloating func(floating bool) + SetIcon func(iconImages []image.Image) + SetPosition func(x, y int) + SetResizable func(resizable bool) + SetSize func(width, height int) + SetTitle func(title string) + Size func() (int, int) + type YDirection int + const Downward + const Upward