Documentation
¶
Index ¶
- Constants
- func AttachAudioMixedProcessor(processor AudioCallback)
- func BeginBlendMode(mode c.Int)
- func BeginDrawing()
- func BeginScissorMode(x c.Int, y c.Int, width c.Int, height c.Int)
- func ChangeDirectory(dirPath *c.Char) bool
- func CheckCollisionBoxes(box1 BoundingBox, box2 BoundingBox) bool
- func CheckCollisionRecs(rec1 Rectangle, rec2 Rectangle) bool
- func ClearWindowState(flags c.Uint)
- func CloseAudioDevice()
- func CloseWindow()
- func CodepointToUTF8(codepoint c.Int, utf8Size *c.Int) *c.Char
- func ColorIsEqual(col1 Color, col2 Color) bool
- func CompressData(data *uint8, dataSize c.Int, compDataSize *c.Int) *uint8
- func ComputeCRC32(data *uint8, dataSize c.Int) c.Uint
- func ComputeMD5(data *uint8, dataSize c.Int) *c.Uint
- func ComputeSHA1(data *uint8, dataSize c.Int) *c.Uint
- func ComputeSHA256(data *uint8, dataSize c.Int) *c.Uint
- func DecodeDataBase64(text *c.Char, outputSize *c.Int) *uint8
- func DecompressData(compData *uint8, compDataSize c.Int, dataSize *c.Int) *uint8
- func DetachAudioMixedProcessor(processor AudioCallback)
- func DirectoryExists(dirPath *c.Char) bool
- func DisableCursor()
- func DisableEventWaiting()
- func DrawCircle(centerX c.Int, centerY c.Int, radius c.Float, color Color)
- func DrawCircleLines(centerX c.Int, centerY c.Int, radius c.Float, color Color)
- func DrawEllipse(centerX c.Int, centerY c.Int, radiusH c.Float, radiusV c.Float, color Color)
- func DrawEllipseLines(centerX c.Int, centerY c.Int, radiusH c.Float, radiusV c.Float, color Color)
- func DrawFPS(posX c.Int, posY c.Int)
- func DrawGrid(slices c.Int, spacing c.Float)
- func DrawLine(startPosX c.Int, startPosY c.Int, endPosX c.Int, endPosY c.Int, color Color)
- func DrawPixel(posX c.Int, posY c.Int, color Color)
- func DrawRectangle(posX c.Int, posY c.Int, width c.Int, height c.Int, color Color)
- func DrawRectangleGradientH(posX c.Int, posY c.Int, width c.Int, height c.Int, left Color, right Color)
- func DrawRectangleGradientV(posX c.Int, posY c.Int, width c.Int, height c.Int, top Color, bottom Color)
- func DrawRectangleLines(posX c.Int, posY c.Int, width c.Int, height c.Int, color Color)
- func DrawText(text *c.Char, posX c.Int, posY c.Int, fontSize c.Int, color Color)
- func EnableCursor()
- func EnableEventWaiting()
- func EncodeDataBase64(data *uint8, dataSize c.Int, outputSize *c.Int) *c.Char
- func EndBlendMode()
- func EndDrawing()
- func EndMode2D()
- func EndMode3D()
- func EndScissorMode()
- func EndShaderMode()
- func EndTextureMode()
- func EndVrStereoMode()
- func ExportDataAsCode(data *uint8, dataSize c.Int, fileName *c.Char) bool
- func FileCopy(srcPath *c.Char, dstPath *c.Char) c.Int
- func FileExists(fileName *c.Char) bool
- func FileMove(srcPath *c.Char, dstPath *c.Char) c.Int
- func FileRemove(fileName *c.Char) c.Int
- func FileRename(fileName *c.Char, fileRename *c.Char) c.Int
- func FileTextFindIndex(fileName *c.Char, search *c.Char) c.Int
- func FileTextReplace(fileName *c.Char, search *c.Char, replacement *c.Char) c.Int
- func GetApplicationDirectory() *c.Char
- func GetCharPressed() c.Int
- func GetClipboardText() *c.Char
- func GetCodepoint(text *c.Char, codepointSize *c.Int) c.Int
- func GetCodepointCount(text *c.Char) c.Int
- func GetCodepointNext(text *c.Char, codepointSize *c.Int) c.Int
- func GetCodepointPrevious(text *c.Char, codepointSize *c.Int) c.Int
- func GetCurrentMonitor() c.Int
- func GetDirectoryFileCount(dirPath *c.Char) c.Uint
- func GetDirectoryFileCountEx(basePath *c.Char, filter *c.Char, scanSubdirs bool) c.Uint
- func GetDirectoryPath(filePath *c.Char) *c.Char
- func GetFPS() c.Int
- func GetFileExtension(fileName *c.Char) *c.Char
- func GetFileLength(fileName *c.Char) c.Int
- func GetFileModTime(fileName *c.Char) c.Long
- func GetFileName(filePath *c.Char) *c.Char
- func GetFileNameWithoutExt(filePath *c.Char) *c.Char
- func GetFrameTime() c.Float
- func GetGamepadAxisCount(gamepad c.Int) c.Int
- func GetGamepadAxisMovement(gamepad c.Int, axis c.Int) c.Float
- func GetGamepadButtonPressed() c.Int
- func GetGamepadName(gamepad c.Int) *c.Char
- func GetGestureDetected() c.Int
- func GetGestureDragAngle() c.Float
- func GetGestureHoldDuration() c.Float
- func GetGesturePinchAngle() c.Float
- func GetKeyName(key c.Int) *c.Char
- func GetKeyPressed() c.Int
- func GetMasterVolume() c.Float
- func GetMonitorCount() c.Int
- func GetMonitorHeight(monitor c.Int) c.Int
- func GetMonitorName(monitor c.Int) *c.Char
- func GetMonitorPhysicalHeight(monitor c.Int) c.Int
- func GetMonitorPhysicalWidth(monitor c.Int) c.Int
- func GetMonitorRefreshRate(monitor c.Int) c.Int
- func GetMonitorWidth(monitor c.Int) c.Int
- func GetMouseWheelMove() c.Float
- func GetMouseX() c.Int
- func GetMouseY() c.Int
- func GetPixelDataSize(width c.Int, height c.Int, format c.Int) c.Int
- func GetPrevDirectoryPath(dirPath *c.Char) *c.Char
- func GetRandomValue(min c.Int, max c.Int) c.Int
- func GetRenderHeight() c.Int
- func GetRenderWidth() c.Int
- func GetScreenHeight() c.Int
- func GetScreenWidth() c.Int
- func GetTextBetween(text *c.Char, begin *c.Char, end *c.Char) *c.Char
- func GetTime() c.Double
- func GetTouchPointCount() c.Int
- func GetTouchPointId(index c.Int) c.Int
- func GetTouchX() c.Int
- func GetTouchY() c.Int
- func GetWindowHandle() unsafe.Pointer
- func GetWorkingDirectory() *c.Char
- func HideCursor()
- func InitAudioDevice()
- func InitWindow(width c.Int, height c.Int, title *c.Char)
- func IsAudioDeviceReady() bool
- func IsCursorHidden() bool
- func IsCursorOnScreen() bool
- func IsFileDropped() bool
- func IsFileExtension(fileName *c.Char, ext *c.Char) bool
- func IsFileNameValid(fileName *c.Char) bool
- func IsGamepadAvailable(gamepad c.Int) bool
- func IsGamepadButtonDown(gamepad c.Int, button c.Int) bool
- func IsGamepadButtonPressed(gamepad c.Int, button c.Int) bool
- func IsGamepadButtonReleased(gamepad c.Int, button c.Int) bool
- func IsGamepadButtonUp(gamepad c.Int, button c.Int) bool
- func IsGestureDetected(gesture c.Uint) bool
- func IsKeyDown(key c.Int) bool
- func IsKeyPressed(key c.Int) bool
- func IsKeyPressedRepeat(key c.Int) bool
- func IsKeyReleased(key c.Int) bool
- func IsKeyUp(key c.Int) bool
- func IsMouseButtonDown(button c.Int) bool
- func IsMouseButtonPressed(button c.Int) bool
- func IsMouseButtonReleased(button c.Int) bool
- func IsMouseButtonUp(button c.Int) bool
- func IsPathFile(path *c.Char) bool
- func IsWindowFocused() bool
- func IsWindowFullscreen() bool
- func IsWindowHidden() bool
- func IsWindowMaximized() bool
- func IsWindowMinimized() bool
- func IsWindowReady() bool
- func IsWindowResized() bool
- func IsWindowState(flag c.Uint) bool
- func LoadCodepoints(text *c.Char, count *c.Int) *c.Int
- func LoadFileData(fileName *c.Char, dataSize *c.Int) *uint8
- func LoadFileText(fileName *c.Char) *c.Char
- func LoadRandomSequence(count c.Uint, min c.Int, max c.Int) *c.Int
- func LoadTextLines(text *c.Char, count *c.Int) **c.Char
- func LoadUTF8(codepoints *c.Int, length c.Int) *c.Char
- func MakeDirectory(dirPath *c.Char) c.Int
- func MaximizeWindow()
- func MeasureText(text *c.Char, fontSize c.Int) c.Int
- func MemAlloc(size c.Uint) unsafe.Pointer
- func MemFree(ptr unsafe.Pointer)
- func MemRealloc(ptr unsafe.Pointer, size c.Uint) unsafe.Pointer
- func MinimizeWindow()
- func OpenURL(url *c.Char)
- func PollInputEvents()
- func RestoreWindow()
- func SaveFileData(fileName *c.Char, data unsafe.Pointer, dataSize c.Int) bool
- func SaveFileText(fileName *c.Char, text *c.Char) bool
- func SetAudioStreamBufferSizeDefault(size c.Int)
- func SetAutomationEventBaseFrame(frame c.Int)
- func SetClipboardText(text *c.Char)
- func SetConfigFlags(flags c.Uint)
- func SetExitKey(key c.Int)
- func SetGamepadMappings(mappings *c.Char) c.Int
- func SetGamepadVibration(gamepad c.Int, leftMotor c.Float, rightMotor c.Float, duration c.Float)
- func SetGesturesEnabled(flags c.Uint)
- func SetLoadFileDataCallback(callback LoadFileDataCallback)
- func SetLoadFileTextCallback(callback LoadFileTextCallback)
- func SetMasterVolume(volume c.Float)
- func SetMouseCursor(cursor c.Int)
- func SetMouseOffset(offsetX c.Int, offsetY c.Int)
- func SetMousePosition(x c.Int, y c.Int)
- func SetMouseScale(scaleX c.Float, scaleY c.Float)
- func SetPixelColor(dstPtr unsafe.Pointer, color Color, format c.Int)
- func SetRandomSeed(seed c.Uint)
- func SetSaveFileDataCallback(callback SaveFileDataCallback)
- func SetSaveFileTextCallback(callback SaveFileTextCallback)
- func SetTargetFPS(fps c.Int)
- func SetTextLineSpacing(spacing c.Int)
- func SetTraceLogCallback(callback TraceLogCallback)
- func SetTraceLogLevel(logLevel c.Int)
- func SetWindowFocused()
- func SetWindowMaxSize(width c.Int, height c.Int)
- func SetWindowMinSize(width c.Int, height c.Int)
- func SetWindowMonitor(monitor c.Int)
- func SetWindowOpacity(opacity c.Float)
- func SetWindowPosition(x c.Int, y c.Int)
- func SetWindowSize(width c.Int, height c.Int)
- func SetWindowState(flags c.Uint)
- func SetWindowTitle(title *c.Char)
- func ShowCursor()
- func StartAutomationEventRecording()
- func StopAutomationEventRecording()
- func SwapScreenBuffer()
- func TakeScreenshot(fileName *c.Char)
- func TextAppend(text *c.Char, append *c.Char, position *c.Int)
- func TextCopy(dst *c.Char, src *c.Char) c.Int
- func TextFindIndex(text *c.Char, search *c.Char) c.Int
- func TextFormat(text *c.Char, __llgo_va_list ...any) *c.Char
- func TextInsert(text *c.Char, insert *c.Char, position c.Int) *c.Char
- func TextInsertAlloc(text *c.Char, insert *c.Char, position c.Int) *c.Char
- func TextIsEqual(text1 *c.Char, text2 *c.Char) bool
- func TextJoin(textList **c.Char, count c.Int, delimiter *c.Char) *c.Char
- func TextLength(text *c.Char) c.Uint
- func TextRemoveSpaces(text *c.Char) *c.Char
- func TextReplace(text *c.Char, search *c.Char, replacement *c.Char) *c.Char
- func TextReplaceAlloc(text *c.Char, search *c.Char, replacement *c.Char) *c.Char
- func TextReplaceBetween(text *c.Char, begin *c.Char, end *c.Char, replacement *c.Char) *c.Char
- func TextReplaceBetweenAlloc(text *c.Char, begin *c.Char, end *c.Char, replacement *c.Char) *c.Char
- func TextSplit(text *c.Char, delimiter c.Char, count *c.Int) **c.Char
- func TextSubtext(text *c.Char, position c.Int, length c.Int) *c.Char
- func TextToCamel(text *c.Char) *c.Char
- func TextToFloat(text *c.Char) c.Float
- func TextToInteger(text *c.Char) c.Int
- func TextToLower(text *c.Char) *c.Char
- func TextToPascal(text *c.Char) *c.Char
- func TextToSnake(text *c.Char) *c.Char
- func TextToUpper(text *c.Char) *c.Char
- func ToggleBorderlessWindowed()
- func ToggleFullscreen()
- func TraceLog(logLevel c.Int, text *c.Char, __llgo_va_list ...any)
- func UnloadCodepoints(codepoints *c.Int)
- func UnloadFileData(data *uint8)
- func UnloadFileText(text *c.Char)
- func UnloadRandomSequence(sequence *c.Int)
- func UnloadTextLines(text **c.Char, lineCount c.Int)
- func UnloadUTF8(text *c.Char)
- func UnloadWaveSamples(samples *c.Float)
- func WaitTime(seconds c.Double)
- func WindowShouldClose() bool
- type AudioCallback
- type AudioStream
- func (self AudioStream) AttachAudioStreamProcessor(processor AudioCallback)
- func (self AudioStream) DetachAudioStreamProcessor(processor AudioCallback)
- func (self AudioStream) IsAudioStreamPlaying() bool
- func (self AudioStream) IsAudioStreamProcessed() bool
- func (self AudioStream) IsAudioStreamValid() bool
- func (self AudioStream) Pause()
- func (self AudioStream) Play()
- func (self AudioStream) Resume()
- func (self AudioStream) SetAudioStreamCallback(callback AudioCallback)
- func (self AudioStream) SetAudioStreamPan(pan c.Float)
- func (self AudioStream) SetAudioStreamPitch(pitch c.Float)
- func (self AudioStream) SetAudioStreamVolume(volume c.Float)
- func (self AudioStream) Stop()
- func (self AudioStream) Unload()
- func (self AudioStream) Update(data unsafe.Pointer, frameCount c.Int)
- type AutomationEvent
- type AutomationEventList
- type BlendMode
- type BoneInfo
- type BoundingBox
- type Camera
- func (self Camera) DrawBillboard(texture Texture2D, position Vector3, scale c.Float, tint Color)
- func (self Camera) DrawBillboardPro(texture Texture2D, source Rectangle, position Vector3, up Vector3, ...)
- func (self Camera) DrawBillboardRec(texture Texture2D, source Rectangle, position Vector3, size Vector2, ...)
- func (self *Camera) Forward() Vector3
- func (self *Camera) GetCameraUp() Vector3
- func (self Camera) Matrix() Matrix
- func (self *Camera) MoveForward(distance c.Float, moveInWorldPlane bool)
- func (self *Camera) MoveRight(distance c.Float, moveInWorldPlane bool)
- func (self *Camera) MoveToTarget(delta c.Float)
- func (self *Camera) MoveUp(distance c.Float)
- func (self *Camera) Pitch(angle c.Float, lockView bool, rotateAroundTarget bool, rotateUp bool)
- func (self *Camera) ProjectionMatrix(aspect c.Float) Matrix
- func (self *Camera) Right() Vector3
- func (self *Camera) Roll(angle c.Float)
- func (self *Camera) Update(mode c.Int)
- func (self *Camera) UpdateCameraPro(movement Vector3, rotation Vector3, zoom c.Float)
- func (self *Camera) ViewMatrix() Matrix
- func (self *Camera) Yaw(angle c.Float, rotateAroundTarget bool)
- type Camera2D
- type Camera3D
- type CameraMode
- type CameraProjection
- type Color
- func (self Color) Alpha(alpha c.Float) Color
- func (self Color) AlphaBlend(src Color, tint Color) Color
- func (self Color) Brightness(factor c.Float) Color
- func (self Color) ClearBackground()
- func (self Color) Contrast(contrast c.Float) Color
- func (self Color) Fade(alpha c.Float) Color
- func (self Color) Lerp(color2 Color, factor c.Float) Color
- func (self Color) Normalize() Vector4
- func (self Color) ToHSV() Vector3
- func (self Color) ToInt() c.Int
- func (self *Color) UnloadImageColors()
- func (self *Color) UnloadImagePalette()
- type ConfigFlags
- type CubemapLayout
- type FilePathList
- type Float3
- type Float16
- type Font
- func (self Font) DrawTextCodepoint(codepoint c.Int, position Vector2, fontSize c.Float, tint Color)
- func (self Font) DrawTextCodepoints(codepoints *c.Int, codepointCount c.Int, position Vector2, fontSize c.Float, ...)
- func (self Font) DrawTextEx(text *c.Char, position Vector2, fontSize c.Float, spacing c.Float, tint Color)
- func (self Font) DrawTextPro(text *c.Char, position Vector2, origin Vector2, rotation c.Float, ...)
- func (self Font) ExportFontAsCode(fileName *c.Char) bool
- func (self Font) GlyphAtlasRec(codepoint c.Int) Rectangle
- func (self Font) GlyphIndex(codepoint c.Int) c.Int
- func (self Font) GlyphInfo(codepoint c.Int) GlyphInfo
- func (self Font) ImageTextEx(text *c.Char, fontSize c.Float, spacing c.Float, tint Color) Image
- func (self Font) IsFontValid() bool
- func (self Font) MeasureTextCodepoints(codepoints *c.Int, length c.Int, fontSize c.Float, spacing c.Float) Vector2
- func (self Font) MeasureTextEx(text *c.Char, fontSize c.Float, spacing c.Float) Vector2
- func (self Font) Unload()
- type FontType
- type GamepadAxis
- type GamepadButton
- type Gesture
- type GlyphInfo
- type Image
- func GenImageCellular(width c.Int, height c.Int, tileSize c.Int) Image
- func GenImageChecked(width c.Int, height c.Int, checksX c.Int, checksY c.Int, col1 Color, ...) Image
- func GenImageColor(width c.Int, height c.Int, color Color) Image
- func GenImageGradientLinear(width c.Int, height c.Int, direction c.Int, start Color, end Color) Image
- func GenImageGradientRadial(width c.Int, height c.Int, density c.Float, inner Color, outer Color) Image
- func GenImageGradientSquare(width c.Int, height c.Int, density c.Float, inner Color, outer Color) Image
- func GenImagePerlinNoise(width c.Int, height c.Int, offsetX c.Int, offsetY c.Int, scale c.Float) Image
- func GenImageText(width c.Int, height c.Int, text *c.Char) Image
- func GenImageWhiteNoise(width c.Int, height c.Int, factor c.Float) Image
- func GetClipboardImage() Image
- func ImageText(text *c.Char, fontSize c.Int, color Color) Image
- func LoadImage(fileName *c.Char) Image
- func LoadImageAnim(fileName *c.Char, frames *c.Int) Image
- func LoadImageAnimFromMemory(fileType *c.Char, fileData *uint8, dataSize c.Int, frames *c.Int) Image
- func LoadImageFromMemory(fileType *c.Char, fileData *uint8, dataSize c.Int) Image
- func LoadImageFromScreen() Image
- func LoadImageRaw(fileName *c.Char, width c.Int, height c.Int, format c.Int, headerSize c.Int) Image
- func (self Image) AlphaBorder(threshold c.Float) Rectangle
- func (self *Image) AlphaClear(color Color, threshold c.Float)
- func (self *Image) AlphaCrop(threshold c.Float)
- func (self *Image) AlphaMask(alphaMask Image)
- func (self *Image) AlphaPremultiply()
- func (self *Image) BlurGaussian(blurSize c.Int)
- func (self *Image) ClearBackground(color Color)
- func (self Image) Color(x c.Int, y c.Int) Color
- func (self *Image) ColorBrightness(brightness c.Int)
- func (self *Image) ColorContrast(contrast c.Float)
- func (self *Image) ColorGrayscale()
- func (self *Image) ColorInvert()
- func (self *Image) ColorReplace(color Color, replace Color)
- func (self *Image) ColorTint(color Color)
- func (self Image) Copy() Image
- func (self *Image) Crop(crop Rectangle)
- func (self *Image) Dither(rBpp c.Int, gBpp c.Int, bBpp c.Int, aBpp c.Int)
- func (self *Image) Draw(src Image, srcRec Rectangle, dstRec Rectangle, tint Color)
- func (self *Image) DrawCircle(centerX c.Int, centerY c.Int, radius c.Int, color Color)
- func (self *Image) DrawCircleLines(centerX c.Int, centerY c.Int, radius c.Int, color Color)
- func (self *Image) DrawCircleLinesV(center Vector2, radius c.Int, color Color)
- func (self *Image) DrawCircleV(center Vector2, radius c.Int, color Color)
- func (self *Image) DrawLine(startPosX c.Int, startPosY c.Int, endPosX c.Int, endPosY c.Int, color Color)
- func (self *Image) DrawLineEx(start Vector2, end Vector2, thick c.Int, color Color)
- func (self *Image) DrawLineV(start Vector2, end Vector2, color Color)
- func (self *Image) DrawPixel(posX c.Int, posY c.Int, color Color)
- func (self *Image) DrawPixelV(position Vector2, color Color)
- func (self *Image) DrawRectangle(posX c.Int, posY c.Int, width c.Int, height c.Int, color Color)
- func (self *Image) DrawRectangleLines(rec Rectangle, thick c.Int, color Color)
- func (self *Image) DrawRectangleRec(rec Rectangle, color Color)
- func (self *Image) DrawRectangleV(position Vector2, size Vector2, color Color)
- func (self *Image) DrawText(text *c.Char, posX c.Int, posY c.Int, fontSize c.Int, color Color)
- func (self *Image) DrawTextEx(font Font, text *c.Char, position Vector2, fontSize c.Float, spacing c.Float, ...)
- func (self *Image) DrawTriangle(v1 Vector2, v2 Vector2, v3 Vector2, color Color)
- func (self *Image) DrawTriangleEx(v1 Vector2, v2 Vector2, v3 Vector2, c1 Color, c2 Color, c3 Color)
- func (self *Image) DrawTriangleFan(points *Vector2, pointCount c.Int, color Color)
- func (self *Image) DrawTriangleLines(v1 Vector2, v2 Vector2, v3 Vector2, color Color)
- func (self *Image) DrawTriangleStrip(points *Vector2, pointCount c.Int, color Color)
- func (self Image) Export(fileName *c.Char) bool
- func (self Image) ExportImageAsCode(fileName *c.Char) bool
- func (self Image) ExportImageToMemory(fileType *c.Char, fileSize *c.Int) *uint8
- func (self *Image) FlipHorizontal()
- func (self *Image) FlipVertical()
- func (self Image) From(rec Rectangle) Image
- func (self Image) FromChannel(selectedChannel c.Int) Image
- func (self Image) GenMeshCubicmap(cubeSize Vector3) Mesh
- func (self Image) GenMeshHeightmap(size Vector3) Mesh
- func (self *Image) ImageFormat(newFormat c.Int)
- func (self *Image) ImageMipmaps()
- func (self Image) IsImageValid() bool
- func (self *Image) KernelConvolution(kernel *c.Float, kernelSize c.Int)
- func (self Image) LoadFontFrom(key Color, firstChar c.Int) Font
- func (self Image) LoadImageColors() *Color
- func (self Image) LoadImagePalette(maxPaletteSize c.Int, colorCount *c.Int) *Color
- func (self Image) LoadTextureCubemap(layout c.Int) TextureCubemap
- func (self Image) LoadTextureFrom() Texture2D
- func (self *Image) Resize(newWidth c.Int, newHeight c.Int)
- func (self *Image) ResizeCanvas(newWidth c.Int, newHeight c.Int, offsetX c.Int, offsetY c.Int, fill Color)
- func (self *Image) ResizeNN(newWidth c.Int, newHeight c.Int)
- func (self *Image) Rotate(degrees c.Int)
- func (self *Image) RotateCCW()
- func (self *Image) RotateCW()
- func (self Image) SetWindowIcon()
- func (self *Image) SetWindowIcons(count c.Int)
- func (self *Image) ToPOT(fill Color)
- func (self Image) Unload()
- type KeyboardKey
- type LoadFileDataCallback
- type LoadFileTextCallback
- type Material
- type MaterialMap
- type MaterialMapIndex
- type Matrix
- type Mesh
- func GenMeshCone(radius c.Float, height c.Float, slices c.Int) Mesh
- func GenMeshCube(width c.Float, height c.Float, length c.Float) Mesh
- func GenMeshCylinder(radius c.Float, height c.Float, slices c.Int) Mesh
- func GenMeshHemiSphere(radius c.Float, rings c.Int, slices c.Int) Mesh
- func GenMeshKnot(radius c.Float, size c.Float, radSeg c.Int, sides c.Int) Mesh
- func GenMeshPlane(width c.Float, length c.Float, resX c.Int, resZ c.Int) Mesh
- func GenMeshPoly(sides c.Int, radius c.Float) Mesh
- func GenMeshSphere(radius c.Float, rings c.Int, slices c.Int) Mesh
- func GenMeshTorus(radius c.Float, size c.Float, radSeg c.Int, sides c.Int) Mesh
- func (self Mesh) BoundingBox() BoundingBox
- func (self Mesh) Draw(material Material, transform Matrix)
- func (self Mesh) DrawMeshInstanced(material Material, transforms *Matrix, instances c.Int)
- func (self Mesh) Export(fileName *c.Char) bool
- func (self Mesh) ExportMeshAsCode(fileName *c.Char) bool
- func (self *Mesh) GenMeshTangents()
- func (self Mesh) LoadModelFrom() Model
- func (self Mesh) Unload()
- func (self Mesh) UpdateMeshBuffer(index c.Int, data unsafe.Pointer, dataSize c.Int, offset c.Int)
- func (self *Mesh) Upload(dynamic bool)
- type Model
- func (self Model) BoundingBox() BoundingBox
- func (self Model) Draw(position Vector3, scale c.Float, tint Color)
- func (self Model) DrawModelEx(position Vector3, rotationAxis Vector3, rotationAngle c.Float, scale Vector3, ...)
- func (self Model) DrawModelWires(position Vector3, scale c.Float, tint Color)
- func (self Model) DrawModelWiresEx(position Vector3, rotationAxis Vector3, rotationAngle c.Float, scale Vector3, ...)
- func (self Model) IsModelAnimationValid(anim ModelAnimation) bool
- func (self Model) IsModelValid() bool
- func (self *Model) SetModelMeshMaterial(meshId c.Int, materialId c.Int)
- func (self Model) Unload()
- func (self Model) UpdateModelAnimation(anim ModelAnimation, frame c.Float)
- func (self Model) UpdateModelAnimationEx(animA ModelAnimation, frameA c.Float, animB ModelAnimation, frameB c.Float, ...)
- type ModelAnimPose
- type ModelAnimation
- type ModelSkeleton
- type MouseButton
- type MouseCursor
- type Music
- func (self Music) IsMusicStreamPlaying() bool
- func (self Music) IsMusicValid() bool
- func (self Music) PauseMusicStream()
- func (self Music) PlayMusicStream()
- func (self Music) ResumeMusicStream()
- func (self Music) SeekMusicStream(position c.Float)
- func (self Music) SetMusicPan(pan c.Float)
- func (self Music) SetMusicPitch(pitch c.Float)
- func (self Music) SetMusicVolume(volume c.Float)
- func (self Music) StopMusicStream()
- func (self Music) TimeLength() c.Float
- func (self Music) TimePlayed() c.Float
- func (self Music) UnloadMusicStream()
- func (self Music) UpdateMusicStream()
- type NPatchInfo
- type NPatchLayout
- type PixelFormat
- type Quaternion
- type RAudioBuffer
- type RAudioProcessor
- type Ray
- func (self Ray) CollisionBox(box BoundingBox) RayCollision
- func (self Ray) CollisionMesh(mesh Mesh, transform Matrix) RayCollision
- func (self Ray) CollisionQuad(p1 Vector3, p2 Vector3, p3 Vector3, p4 Vector3) RayCollision
- func (self Ray) CollisionSphere(center Vector3, radius c.Float) RayCollision
- func (self Ray) CollisionTriangle(p1 Vector3, p2 Vector3, p3 Vector3) RayCollision
- func (self Ray) Draw(color Color)
- type RayCollision
- type Rectangle
- func (self Rectangle) DrawRectangleGradientEx(topLeft Color, bottomLeft Color, bottomRight Color, topRight Color)
- func (self Rectangle) DrawRectangleLinesEx(lineThick c.Float, color Color)
- func (self Rectangle) DrawRectanglePro(origin Vector2, rotation c.Float, color Color)
- func (self Rectangle) DrawRectangleRec(color Color)
- func (self Rectangle) DrawRectangleRounded(roundness c.Float, segments c.Int, color Color)
- func (self Rectangle) DrawRectangleRoundedLines(roundness c.Float, segments c.Int, color Color)
- func (self Rectangle) DrawRectangleRoundedLinesEx(roundness c.Float, segments c.Int, lineThick c.Float, color Color)
- type RenderTexture
- type RenderTexture2D
- type SaveFileDataCallback
- type SaveFileTextCallback
- type Shader
- func (self Shader) BeginShaderMode()
- func (self Shader) IsShaderValid() bool
- func (self Shader) Location(uniformName *c.Char) c.Int
- func (self Shader) LocationAttrib(attribName *c.Char) c.Int
- func (self Shader) SetShaderValue(locIndex c.Int, value unsafe.Pointer, uniformType c.Int)
- func (self Shader) SetShaderValueMatrix(locIndex c.Int, mat Matrix)
- func (self Shader) SetShaderValueTexture(locIndex c.Int, texture Texture2D)
- func (self Shader) SetShaderValueV(locIndex c.Int, value unsafe.Pointer, uniformType c.Int, count c.Int)
- func (self Shader) Unload()
- type ShaderAttributeDataType
- type ShaderLocationIndex
- type ShaderUniformDataType
- type Sound
- func (self Sound) IsSoundPlaying() bool
- func (self Sound) IsSoundValid() bool
- func (self Sound) LoadSoundAlias() Sound
- func (self Sound) Pause()
- func (self Sound) Play()
- func (self Sound) Resume()
- func (self Sound) SetSoundPan(pan c.Float)
- func (self Sound) SetSoundPitch(pitch c.Float)
- func (self Sound) SetSoundVolume(volume c.Float)
- func (self Sound) Stop()
- func (self Sound) Unload()
- func (self Sound) UnloadSoundAlias()
- func (self Sound) Update(data unsafe.Pointer, sampleCount c.Int)
- type Texture
- type Texture2D
- func (self Texture2D) DrawTexture(posX c.Int, posY c.Int, tint Color)
- func (self Texture2D) DrawTextureEx(position Vector2, rotation c.Float, scale c.Float, tint Color)
- func (self Texture2D) DrawTextureNPatch(nPatchInfo NPatchInfo, dest Rectangle, origin Vector2, rotation c.Float, ...)
- func (self Texture2D) DrawTexturePro(source Rectangle, dest Rectangle, origin Vector2, rotation c.Float, tint Color)
- func (self Texture2D) DrawTextureRec(source Rectangle, position Vector2, tint Color)
- func (self Texture2D) DrawTextureV(position Vector2, tint Color)
- func (self *Texture2D) GenTextureMipmaps()
- func (self Texture2D) IsTextureValid() bool
- func (self Texture2D) LoadImageFromTexture() Image
- func (self Texture2D) SetShapesTexture(source Rectangle)
- func (self Texture2D) SetTextureFilter(filter c.Int)
- func (self Texture2D) SetTextureWrap(wrap c.Int)
- func (self Texture2D) UnloadTexture()
- func (self Texture2D) UpdateTexture(pixels unsafe.Pointer)
- func (self Texture2D) UpdateTextureRec(rec Rectangle, pixels unsafe.Pointer)
- type TextureCubemap
- type TextureFilter
- type TextureWrap
- type TraceLogCallback
- type TraceLogLevel
- type Transform
- type Vector2
- func GetGestureDragVector() Vector2
- func GetGesturePinchVector() Vector2
- func GetMonitorPosition(monitor c.Int) Vector2
- func GetMouseDelta() Vector2
- func GetMousePosition() Vector2
- func GetMouseWheelMoveV() Vector2
- func GetTouchPosition(index c.Int) Vector2
- func GetWindowPosition() Vector2
- func GetWindowScaleDPI() Vector2
- func (self Vector2) CheckCollisionCircleLine(radius c.Float, p1 Vector2, p2 Vector2) bool
- func (self Vector2) CheckCollisionCircleRec(radius c.Float, rec Rectangle) bool
- func (self Vector2) CheckCollisionCircles(radius1 c.Float, center2 Vector2, radius2 c.Float) bool
- func (self Vector2) CheckCollisionLines(endPos1 Vector2, startPos2 Vector2, endPos2 Vector2, collisionPoint *Vector2) bool
- func (self Vector2) CheckCollisionPointCircle(center Vector2, radius c.Float) bool
- func (self Vector2) CheckCollisionPointLine(p1 Vector2, p2 Vector2, threshold c.Int) bool
- func (self Vector2) CheckCollisionPointPoly(points *Vector2, pointCount c.Int) bool
- func (self Vector2) CheckCollisionPointRec(rec Rectangle) bool
- func (self Vector2) CheckCollisionPointTriangle(p1 Vector2, p2 Vector2, p3 Vector2) bool
- func (self Vector2) DrawCircleGradient(radius c.Float, inner Color, outer Color)
- func (self Vector2) DrawCircleLinesV(radius c.Float, color Color)
- func (self Vector2) DrawCircleSector(radius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, ...)
- func (self Vector2) DrawCircleSectorLines(radius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, ...)
- func (self Vector2) DrawCircleV(radius c.Float, color Color)
- func (self Vector2) DrawEllipseLinesV(radiusH c.Float, radiusV c.Float, color Color)
- func (self Vector2) DrawEllipseV(radiusH c.Float, radiusV c.Float, color Color)
- func (self Vector2) DrawLineBezier(endPos Vector2, thick c.Float, color Color)
- func (self Vector2) DrawLineDashed(endPos Vector2, dashSize c.Int, spaceSize c.Int, color Color)
- func (self Vector2) DrawLineEx(endPos Vector2, thick c.Float, color Color)
- func (self *Vector2) DrawLineStrip(pointCount c.Int, color Color)
- func (self Vector2) DrawLineV(endPos Vector2, color Color)
- func (self Vector2) DrawPixelV(color Color)
- func (self Vector2) DrawPoly(sides c.Int, radius c.Float, rotation c.Float, color Color)
- func (self Vector2) DrawPolyLines(sides c.Int, radius c.Float, rotation c.Float, color Color)
- func (self Vector2) DrawPolyLinesEx(sides c.Int, radius c.Float, rotation c.Float, lineThick c.Float, color Color)
- func (self Vector2) DrawRectangleV(size Vector2, color Color)
- func (self Vector2) DrawRing(innerRadius c.Float, outerRadius c.Float, startAngle c.Float, endAngle c.Float, ...)
- func (self Vector2) DrawRingLines(innerRadius c.Float, outerRadius c.Float, startAngle c.Float, endAngle c.Float, ...)
- func (self *Vector2) DrawSplineBasis(pointCount c.Int, thick c.Float, color Color)
- func (self *Vector2) DrawSplineBezierCubic(pointCount c.Int, thick c.Float, color Color)
- func (self *Vector2) DrawSplineBezierQuadratic(pointCount c.Int, thick c.Float, color Color)
- func (self *Vector2) DrawSplineCatmullRom(pointCount c.Int, thick c.Float, color Color)
- func (self *Vector2) DrawSplineLinear(pointCount c.Int, thick c.Float, color Color)
- func (self Vector2) DrawSplineSegmentBasis(p2 Vector2, p3 Vector2, p4 Vector2, thick c.Float, color Color)
- func (self Vector2) DrawSplineSegmentBezierCubic(c2 Vector2, c3 Vector2, p4 Vector2, thick c.Float, color Color)
- func (self Vector2) DrawSplineSegmentBezierQuadratic(c2 Vector2, p3 Vector2, thick c.Float, color Color)
- func (self Vector2) DrawSplineSegmentCatmullRom(p2 Vector2, p3 Vector2, p4 Vector2, thick c.Float, color Color)
- func (self Vector2) DrawSplineSegmentLinear(p2 Vector2, thick c.Float, color Color)
- func (self Vector2) DrawTriangle(v2 Vector2, v3 Vector2, color Color)
- func (self *Vector2) DrawTriangleFan(pointCount c.Int, color Color)
- func (self Vector2) DrawTriangleLines(v2 Vector2, v3 Vector2, color Color)
- func (self *Vector2) DrawTriangleStrip(pointCount c.Int, color Color)
- func (self Vector2) ScreenToWorld2D(camera Camera2D) Vector2
- func (self Vector2) ScreenToWorldRay(camera Camera) Ray
- func (self Vector2) ScreenToWorldRayEx(camera Camera, width c.Int, height c.Int) Ray
- func (self Vector2) SplinePointBasis(p2 Vector2, p3 Vector2, p4 Vector2, t c.Float) Vector2
- func (self Vector2) SplinePointBezierCubic(c2 Vector2, c3 Vector2, p4 Vector2, t c.Float) Vector2
- func (self Vector2) SplinePointBezierQuad(c2 Vector2, p3 Vector2, t c.Float) Vector2
- func (self Vector2) SplinePointCatmullRom(p2 Vector2, p3 Vector2, p4 Vector2, t c.Float) Vector2
- func (self Vector2) SplinePointLinear(endPos Vector2, t c.Float) Vector2
- func (self Vector2) WorldToScreen2D(camera Camera2D) Vector2
- type Vector3
- func (self Vector3) CheckCollisionSpheres(radius1 c.Float, center2 Vector3, radius2 c.Float) bool
- func (self Vector3) DrawCapsule(endPos Vector3, radius c.Float, slices c.Int, rings c.Int, color Color)
- func (self Vector3) DrawCapsuleWires(endPos Vector3, radius c.Float, slices c.Int, rings c.Int, color Color)
- func (self Vector3) DrawCircle3D(radius c.Float, rotationAxis Vector3, rotationAngle c.Float, color Color)
- func (self Vector3) DrawCube(width c.Float, height c.Float, length c.Float, color Color)
- func (self Vector3) DrawCubeV(size Vector3, color Color)
- func (self Vector3) DrawCubeWires(width c.Float, height c.Float, length c.Float, color Color)
- func (self Vector3) DrawCubeWiresV(size Vector3, color Color)
- func (self Vector3) DrawCylinder(radiusTop c.Float, radiusBottom c.Float, height c.Float, slices c.Int, ...)
- func (self Vector3) DrawCylinderEx(endPos Vector3, startRadius c.Float, endRadius c.Float, sides c.Int, ...)
- func (self Vector3) DrawCylinderWires(radiusTop c.Float, radiusBottom c.Float, height c.Float, slices c.Int, ...)
- func (self Vector3) DrawCylinderWiresEx(endPos Vector3, startRadius c.Float, endRadius c.Float, sides c.Int, ...)
- func (self Vector3) DrawLine3D(endPos Vector3, color Color)
- func (self Vector3) DrawPlane(size Vector2, color Color)
- func (self Vector3) DrawPoint3D(color Color)
- func (self Vector3) DrawSphere(radius c.Float, color Color)
- func (self Vector3) DrawSphereEx(radius c.Float, rings c.Int, slices c.Int, color Color)
- func (self Vector3) DrawSphereWires(radius c.Float, rings c.Int, slices c.Int, color Color)
- func (self Vector3) DrawTriangle3D(v2 Vector3, v3 Vector3, color Color)
- func (self *Vector3) DrawTriangleStrip3D(pointCount c.Int, color Color)
- func (self Vector3) WorldToScreen(camera Camera) Vector2
- func (self Vector3) WorldToScreenEx(camera Camera, width c.Int, height c.Int) Vector2
- type Vector4
- type VrDeviceInfo
- type VrStereoConfig
- type Wave
- func (self Wave) Copy() Wave
- func (self *Wave) Crop(initFrame c.Int, finalFrame c.Int)
- func (self Wave) Export(fileName *c.Char) bool
- func (self Wave) ExportWaveAsCode(fileName *c.Char) bool
- func (self *Wave) Format(sampleRate c.Int, sampleSize c.Int, channels c.Int)
- func (self Wave) IsWaveValid() bool
- func (self Wave) LoadSoundFrom() Sound
- func (self Wave) LoadWaveSamples() *c.Float
- func (self Wave) Unload()
Constants ¶
const ( VERSION_MAJOR = 6 VERSION_MINOR = 0 VERSION_PATCH = 0 VERSION = "6.0" )
const LLGoPackage = "link: $(pkg-config --libs raylib); -lraylib"
Variables ¶
This section is empty.
Functions ¶
func AttachAudioMixedProcessor ¶
func AttachAudioMixedProcessor(processor AudioCallback)
Attach audio stream processor to the entire audio pipeline, receives frames x 2 samples as 'float' (stereo)
func BeginBlendMode ¶
Begin blending mode (alpha, additive, multiplied, subtract, custom)
func BeginScissorMode ¶
Begin scissor mode (define screen area for following drawing)
func ChangeDirectory ¶
Change working directory, return true on success
func CheckCollisionBoxes ¶
func CheckCollisionBoxes(box1 BoundingBox, box2 BoundingBox) bool
Check collision between two bounding boxes
func CheckCollisionRecs ¶
Basic shapes collision detection functions
func CodepointToUTF8 ¶
Encode one codepoint into UTF-8 byte array (array length returned as parameter)
func CompressData ¶
Compression/Encoding functionality
func ComputeMD5 ¶
Compute MD5 hash code, returns static int[4] (16 bytes)
func ComputeSHA1 ¶
Compute SHA1 hash code, returns static int[5] (20 bytes)
func ComputeSHA256 ¶
Compute SHA256 hash code, returns static int[8] (32 bytes)
func DecodeDataBase64 ¶
Decode Base64 string (expected NULL terminated), memory must be MemFree()
func DecompressData ¶
Decompress data (DEFLATE algorithm), memory must be MemFree()
func DetachAudioMixedProcessor ¶
func DetachAudioMixedProcessor(processor AudioCallback)
Detach audio stream processor from the entire audio pipeline
func DisableEventWaiting ¶
func DisableEventWaiting()
Disable waiting for events on EndDrawing(), automatic events polling
func DrawCircle ¶
Draw a color-filled circle
func DrawCircleLines ¶
Draw circle outline
func DrawEllipse ¶
Draw ellipse
func DrawEllipseLines ¶
Draw ellipse outline
func DrawRectangle ¶
Draw a color-filled rectangle
func DrawRectangleGradientH ¶
func DrawRectangleGradientH(posX c.Int, posY c.Int, width c.Int, height c.Int, left Color, right Color)
Draw a horizontal-gradient-filled rectangle
func DrawRectangleGradientV ¶
func DrawRectangleGradientV(posX c.Int, posY c.Int, width c.Int, height c.Int, top Color, bottom Color)
Draw a vertical-gradient-filled rectangle
func DrawRectangleLines ¶
Draw rectangle outline
func EnableEventWaiting ¶
func EnableEventWaiting()
Enable waiting for events on EndDrawing(), no automatic event polling
func EncodeDataBase64 ¶
Encode data to Base64 string (includes NULL terminator), memory must be MemFree()
func ExportDataAsCode ¶
Export data to code (.h), returns true on success
func FileRename ¶
Rename file (if exists)
func FileTextFindIndex ¶
Find text in existing file
func FileTextReplace ¶
Replace text in an existing file
func GetApplicationDirectory ¶
Get the directory of the running application (uses static string)
func GetCharPressed ¶
Get char pressed (unicode), call it multiple times for chars queued, returns 0 when the queue is empty
func GetCodepoint ¶
Get next codepoint in a UTF-8 encoded string, 0x3f('?') is returned on failure
func GetCodepointCount ¶
Get total number of codepoints in a UTF-8 encoded string
func GetCodepointNext ¶
Get next codepoint in a UTF-8 encoded string, 0x3f('?') is returned on failure
func GetCodepointPrevious ¶
Get previous codepoint in a UTF-8 encoded string, 0x3f('?') is returned on failure
func GetDirectoryFileCount ¶
Get the file count in a directory
func GetDirectoryFileCountEx ¶
Get the file count in a directory with extension filtering and recursive directory scan. Use 'DIR' in the filter string to include directories in the result
func GetDirectoryPath ¶
Get full path for a given fileName with path (uses static string)
func GetFileExtension ¶
Get pointer to extension for a filename string (includes dot: '.png')
func GetFileLength ¶
Get file length in bytes (NOTE: GetFileSize() conflicts with windows.h)
func GetFileModTime ¶
Get file modification time (last write time)
func GetFileName ¶
Get pointer to filename for a path string
func GetFileNameWithoutExt ¶
Get filename string without extension (uses static string)
func GetFrameTime ¶
Get time in seconds for last frame drawn (delta time)
func GetGamepadAxisCount ¶
Get axis count for a gamepad
func GetGamepadAxisMovement ¶
Get movement value for a gamepad axis
func GetGamepadButtonPressed ¶
Get the last gamepad button pressed
func GetGestureHoldDuration ¶
Get gesture hold time in seconds
func GetKeyName ¶
Get name of a QWERTY key on the current keyboard layout (eg returns string 'q' for KEY_A on an AZERTY keyboard)
func GetKeyPressed ¶
Get key pressed (keycode), call it multiple times for keys queued, returns 0 when the queue is empty
func GetMonitorHeight ¶
Get specified monitor height (current video mode used by monitor)
func GetMonitorName ¶
Get the human-readable, UTF-8 encoded name of the specified monitor
func GetMonitorPhysicalHeight ¶
Get specified monitor physical height in millimetres
func GetMonitorPhysicalWidth ¶
Get specified monitor physical width in millimetres
func GetMonitorRefreshRate ¶
Get specified monitor refresh rate
func GetMonitorWidth ¶
Get specified monitor width (current video mode used by monitor)
func GetMouseWheelMove ¶
Get mouse wheel movement for X or Y, whichever is larger
func GetPixelDataSize ¶
Get pixel data size in bytes for certain format
func GetPrevDirectoryPath ¶
Get previous directory path for a given path (uses static string)
func GetRandomValue ¶
Get a random value between min and max (both included)
func GetTextBetween ¶
Get text between two strings
func GetTouchPointId ¶
Get touch point identifier for given index
func GetWorkingDirectory ¶
Get current working directory (uses static string)
func InitWindow ¶
Window-related functions
func IsAudioDeviceReady ¶
func IsAudioDeviceReady() bool
Check if audio device has been initialized successfully
func IsFileExtension ¶
Check file extension (recommended include point: .png, .wav)
func IsFileNameValid ¶
Check if fileName is valid for the platform/OS
func IsGamepadAvailable ¶
Input-related functions: gamepads
func IsGamepadButtonDown ¶
Check if a gamepad button is being pressed
func IsGamepadButtonPressed ¶
Check if a gamepad button has been pressed once
func IsGamepadButtonReleased ¶
Check if a gamepad button has been released once
func IsGamepadButtonUp ¶
Check if a gamepad button is NOT being pressed
func IsGestureDetected ¶
Check if a gesture have been detected
func IsKeyPressedRepeat ¶
Check if a key has been pressed again
func IsMouseButtonDown ¶
Check if a mouse button is being pressed
func IsMouseButtonPressed ¶
Input-related functions: mouse
func IsMouseButtonReleased ¶
Check if a mouse button has been released once
func IsMouseButtonUp ¶
Check if a mouse button is NOT being pressed
func IsWindowState ¶
Check if one specific window flag is enabled
func LoadCodepoints ¶
Load all codepoints from a UTF-8 text string, codepoints count returned by parameter
func LoadFileData ¶
File system management functions
func LoadFileText ¶
Load text data from file (read), returns a '\0' terminated string
func LoadRandomSequence ¶
Load random values sequence, no values repeated
func LoadTextLines ¶
Text strings management functions (no UTF-8 strings, only byte chars) WARNING 1: Most of these functions use internal static buffers[], it's recommended to store returned data on user-side for re-use WARNING 2: Some functions allocate memory internally for the returned strings, those strings must be freed by user using MemFree()
func MakeDirectory ¶
Create directories (including full path requested), returns 0 on success
func MeasureText ¶
Measure string width for default font
func MemRealloc ¶
Internal memory reallocator
func SaveFileData ¶
Save data to file from byte array (write), returns true on success
func SaveFileText ¶
Save text data to file (write), string must be '\0' terminated, returns true on success
func SetAudioStreamBufferSizeDefault ¶
Default size for new audio streams
func SetAutomationEventBaseFrame ¶
Set automation event internal base frame to start recording
func SetGamepadMappings ¶
Set internal gamepad mappings (SDL_GameControllerDB)
func SetGamepadVibration ¶
Set gamepad vibration for both motors (duration in seconds)
func SetGesturesEnabled ¶
------------------------------------------------------------------------------------ Gestures and Touch Handling Functions (Module: rgestures) ------------------------------------------------------------------------------------
func SetLoadFileDataCallback ¶
func SetLoadFileDataCallback(callback LoadFileDataCallback)
File access custom callbacks WARNING: Callbacks setup is intended for advanced users
func SetLoadFileTextCallback ¶
func SetLoadFileTextCallback(callback LoadFileTextCallback)
Set custom file text data loader
func SetPixelColor ¶
Set color formatted into destination pixel pointer
func SetSaveFileDataCallback ¶
func SetSaveFileDataCallback(callback SaveFileDataCallback)
Set custom file binary data saver
func SetSaveFileTextCallback ¶
func SetSaveFileTextCallback(callback SaveFileTextCallback)
Set custom file text data saver
func SetWindowMaxSize ¶
Set window maximum dimensions (for FLAG_WINDOW_RESIZABLE)
func SetWindowMinSize ¶
Set window minimum dimensions (for FLAG_WINDOW_RESIZABLE)
func StartAutomationEventRecording ¶
func StartAutomationEventRecording()
Start recording automation events (AutomationEventList must be set)
func StopAutomationEventRecording ¶
func StopAutomationEventRecording()
Stop recording automation events
func SwapScreenBuffer ¶
func SwapScreenBuffer()
Custom frame control functions NOTE: Those functions are intended for advanced users that want full control over the frame processing By default EndDrawing() does this job: draws everything + SwapScreenBuffer() + manage frame timing + PollInputEvents() To avoid that behaviour and control frame processes manually, enable in config.h: SUPPORT_CUSTOM_FRAME_CONTROL
func TextAppend ¶
Append text at specific position and move cursor
func TextFindIndex ¶
Find first text occurrence within a string, -1 if not found
func TextFormat ¶
Text formatting with variables (sprintf() style)
func TextInsert ¶
Insert text in a defined byte position
func TextInsertAlloc ¶
Insert text in a defined byte position, memory must be MemFree()
func TextIsEqual ¶
Check if two text string are equal
func TextRemoveSpaces ¶
Remove text spaces, concat words
func TextReplace ¶
Replace text string with new string
func TextReplaceAlloc ¶
Replace text string with new string, memory must be MemFree()
func TextReplaceBetween ¶
Replace text between two specific strings
func TextReplaceBetweenAlloc ¶
Replace text between two specific strings, memory must be MemFree()
func TextSubtext ¶
Get a piece of a text string
func TextToCamel ¶
Get Camel case notation version of provided string
func TextToPascal ¶
Get Pascal case notation version of provided string
func TextToSnake ¶
Get Snake case notation version of provided string
func ToggleBorderlessWindowed ¶
func ToggleBorderlessWindowed()
Toggle window state: borderless windowed, resizes window to match monitor resolution
func ToggleFullscreen ¶
func ToggleFullscreen()
Toggle window state: fullscreen/windowed, resizes monitor to match window resolution
func UnloadFileText ¶
Unload file text data allocated by LoadFileText()
func UnloadRandomSequence ¶
Unload random values sequence
func UnloadWaveSamples ¶
Unload samples data loaded with LoadWaveSamples()
func WindowShouldClose ¶
func WindowShouldClose() bool
Check if application should close (KEY_ESCAPE pressed or windows close icon clicked)
Types ¶
type AudioCallback ¶
------------------------------------------------------------------------------------ Audio Loading and Playing Functions (Module: audio) ------------------------------------------------------------------------------------
llgo:type C
type AudioStream ¶
type AudioStream struct {
Buffer *RAudioBuffer
Processor *RAudioProcessor
SampleRate c.Uint
SampleSize c.Uint
Channels c.Uint
}
AudioStream, custom audio stream
func LoadAudioStream ¶
AudioStream management functions
func (AudioStream) AttachAudioStreamProcessor ¶
func (self AudioStream) AttachAudioStreamProcessor(processor AudioCallback)
Attach audio stream processor to stream, receives frames x 2 samples as 'float' (stereo)
llgo:link AudioStream.AttachAudioStreamProcessor C.AttachAudioStreamProcessor
func (AudioStream) DetachAudioStreamProcessor ¶
func (self AudioStream) DetachAudioStreamProcessor(processor AudioCallback)
Detach audio stream processor from stream
llgo:link AudioStream.DetachAudioStreamProcessor C.DetachAudioStreamProcessor
func (AudioStream) IsAudioStreamPlaying ¶
func (self AudioStream) IsAudioStreamPlaying() bool
Check if audio stream is playing
llgo:link AudioStream.IsAudioStreamPlaying C.IsAudioStreamPlaying
func (AudioStream) IsAudioStreamProcessed ¶
func (self AudioStream) IsAudioStreamProcessed() bool
Check if any audio stream buffers requires refill
llgo:link AudioStream.IsAudioStreamProcessed C.IsAudioStreamProcessed
func (AudioStream) IsAudioStreamValid ¶
func (self AudioStream) IsAudioStreamValid() bool
Checks if an audio stream is valid (buffers initialized)
llgo:link AudioStream.IsAudioStreamValid C.IsAudioStreamValid
func (AudioStream) Pause ¶
func (self AudioStream) Pause()
Pause audio stream
llgo:link AudioStream.Pause C.PauseAudioStream
func (AudioStream) Play ¶
func (self AudioStream) Play()
Play audio stream
llgo:link AudioStream.Play C.PlayAudioStream
func (AudioStream) Resume ¶
func (self AudioStream) Resume()
Resume audio stream
llgo:link AudioStream.Resume C.ResumeAudioStream
func (AudioStream) SetAudioStreamCallback ¶
func (self AudioStream) SetAudioStreamCallback(callback AudioCallback)
Audio thread callback to request new data
llgo:link AudioStream.SetAudioStreamCallback C.SetAudioStreamCallback
func (AudioStream) SetAudioStreamPan ¶
func (self AudioStream) SetAudioStreamPan(pan c.Float)
Set pan for audio stream (-1.0 to 1.0 range, 0.0 is centered)
llgo:link AudioStream.SetAudioStreamPan C.SetAudioStreamPan
func (AudioStream) SetAudioStreamPitch ¶
func (self AudioStream) SetAudioStreamPitch(pitch c.Float)
Set pitch for audio stream (1.0 is base level)
llgo:link AudioStream.SetAudioStreamPitch C.SetAudioStreamPitch
func (AudioStream) SetAudioStreamVolume ¶
func (self AudioStream) SetAudioStreamVolume(volume c.Float)
Set volume for audio stream (1.0 is max level)
llgo:link AudioStream.SetAudioStreamVolume C.SetAudioStreamVolume
func (AudioStream) Stop ¶
func (self AudioStream) Stop()
Stop audio stream
llgo:link AudioStream.Stop C.StopAudioStream
func (AudioStream) Unload ¶
func (self AudioStream) Unload()
Unload audio stream and free memory
llgo:link AudioStream.Unload C.UnloadAudioStream
type AutomationEvent ¶
Automation event
func (AutomationEvent) Play ¶
func (self AutomationEvent) Play()
Play a recorded automation event
llgo:link AutomationEvent.Play C.PlayAutomationEvent
type AutomationEventList ¶
type AutomationEventList struct {
Capacity c.Uint
Count c.Uint
Events *AutomationEvent
}
Automation event list
func LoadAutomationEventList ¶
func LoadAutomationEventList(fileName *c.Char) AutomationEventList
Automation events functionality
func (AutomationEventList) Export ¶
func (self AutomationEventList) Export(fileName *c.Char) bool
Export automation events list as text file
llgo:link AutomationEventList.Export C.ExportAutomationEventList
func (*AutomationEventList) Set ¶
func (self *AutomationEventList) Set()
Set automation event list to record to
llgo:link (*AutomationEventList).Set C.SetAutomationEventList
func (AutomationEventList) Unload ¶
func (self AutomationEventList) Unload()
Unload automation events list from file
llgo:link AutomationEventList.Unload C.UnloadAutomationEventList
type BlendMode ¶
Color blending modes (pre-defined)
const ( BLEND_ALPHA BlendMode = 0 BLEND_ADDITIVE BlendMode = 1 BLEND_MULTIPLIED BlendMode = 2 BLEND_ADD_COLORS BlendMode = 3 BLEND_SUBTRACT_COLORS BlendMode = 4 BLEND_ALPHA_PREMULTIPLY BlendMode = 5 BLEND_CUSTOM BlendMode = 6 // Blend textures using custom rgb/alpha separate src/dst factors (use rlSetBlendFactorsSeparate()) BLEND_CUSTOM_SEPARATE BlendMode = 7 )
type BoundingBox ¶
BoundingBox
func (BoundingBox) CheckCollisionBoxSphere ¶
func (self BoundingBox) CheckCollisionBoxSphere(center Vector3, radius c.Float) bool
Check collision between box and sphere
llgo:link BoundingBox.CheckCollisionBoxSphere C.CheckCollisionBoxSphere
func (BoundingBox) Draw ¶
func (self BoundingBox) Draw(color Color)
Draw bounding box (wires)
llgo:link BoundingBox.Draw C.DrawBoundingBox
type Camera ¶
type Camera = Camera3D
Camera type fallback, defaults to Camera3D
func (Camera) DrawBillboard ¶
Draw a billboard texture
llgo:link Camera.DrawBillboard C.DrawBillboard
func (Camera) DrawBillboardPro ¶
func (self Camera) DrawBillboardPro(texture Texture2D, source Rectangle, position Vector3, up Vector3, size Vector2, origin Vector2, rotation c.Float, tint Color)
Draw a billboard texture defined by source and rotation
llgo:link Camera.DrawBillboardPro C.DrawBillboardPro
func (Camera) DrawBillboardRec ¶
func (self Camera) DrawBillboardRec(texture Texture2D, source Rectangle, position Vector3, size Vector2, tint Color)
Draw a billboard texture defined by source
llgo:link Camera.DrawBillboardRec C.DrawBillboardRec
func (*Camera) GetCameraUp ¶
llgo:link (*Camera).GetCameraUp C.GetCameraUp
func (Camera) Matrix ¶
Get camera transform matrix (view matrix)
llgo:link Camera.Matrix C.GetCameraMatrix
func (*Camera) MoveToTarget ¶
llgo:link (*Camera).MoveToTarget C.CameraMoveToTarget
func (*Camera) ProjectionMatrix ¶
llgo:link (*Camera).ProjectionMatrix C.GetCameraProjectionMatrix
func (*Camera) Update ¶
------------------------------------------------------------------------------------ Camera System Functions (Module: rcamera) ------------------------------------------------------------------------------------
llgo:link (*Camera).Update C.UpdateCamera
func (*Camera) UpdateCameraPro ¶
Update camera movement/rotation
llgo:link (*Camera).UpdateCameraPro C.UpdateCameraPro
func (*Camera) ViewMatrix ¶
llgo:link (*Camera).ViewMatrix C.GetCameraViewMatrix
type Camera2D ¶
Camera2D, defines position/orientation in 2d space
func (Camera2D) BeginMode2D ¶
func (self Camera2D) BeginMode2D()
Begin 2D mode with custom camera (2D)
llgo:link Camera2D.BeginMode2D C.BeginMode2D
func (Camera2D) CameraMatrix2D ¶
Get camera 2d transform matrix
llgo:link Camera2D.CameraMatrix2D C.GetCameraMatrix2D
type Camera3D ¶
Camera, defines position/orientation in 3d space
func (Camera3D) BeginMode3D ¶
func (self Camera3D) BeginMode3D()
Begin 3D mode with custom camera (3D)
llgo:link Camera3D.BeginMode3D C.BeginMode3D
type CameraMode ¶
Camera system modes
const ( CAMERA_CUSTOM CameraMode = 0 CAMERA_FREE CameraMode = 1 CAMERA_ORBITAL CameraMode = 2 CAMERA_FIRST_PERSON CameraMode = 3 // Camera third person CAMERA_THIRD_PERSON CameraMode = 4 )
type CameraProjection ¶
Camera projection
const ( CAMERA_PERSPECTIVE CameraProjection = 0 // Orthographic projection CAMERA_ORTHOGRAPHIC CameraProjection = 1 )
type Color ¶
Color, 4 components, R8G8B8A8 (32bit)
func ColorFromHSV ¶
Get a Color from HSV values, hue [0..360], saturation/value [0..1]
func GetPixelColor ¶
Get Color from a source pixel pointer of certain format
func (Color) Alpha ¶
Get color with alpha applied, alpha goes from 0.0f to 1.0f
llgo:link Color.Alpha C.ColorAlpha
func (Color) AlphaBlend ¶
Get src alpha-blended into dst color with tint
llgo:link Color.AlphaBlend C.ColorAlphaBlend
func (Color) Brightness ¶
Get color with brightness correction, brightness factor goes from -1.0f to 1.0f
llgo:link Color.Brightness C.ColorBrightness
func (Color) ClearBackground ¶
func (self Color) ClearBackground()
Drawing-related functions
llgo:link Color.ClearBackground C.ClearBackground
func (Color) Contrast ¶
Get color with contrast correction, contrast values between -1.0f and 1.0f
llgo:link Color.Contrast C.ColorContrast
func (Color) Fade ¶
Get color with alpha applied, alpha goes from 0.0f to 1.0f
llgo:link Color.Fade C.Fade
func (Color) Lerp ¶
Get color lerp interpolation between two colors, factor [0.0f..1.0f]
llgo:link Color.Lerp C.ColorLerp
func (Color) Normalize ¶
Get Color normalized as float [0..1]
llgo:link Color.Normalize C.ColorNormalize
func (Color) ToHSV ¶
Get HSV values for a Color, hue [0..360], saturation/value [0..1]
llgo:link Color.ToHSV C.ColorToHSV
func (Color) ToInt ¶
Get hexadecimal value for a Color (0xRRGGBBAA)
llgo:link Color.ToInt C.ColorToInt
func (*Color) UnloadImageColors ¶
func (self *Color) UnloadImageColors()
Unload color data loaded with LoadImageColors()
llgo:link (*Color).UnloadImageColors C.UnloadImageColors
func (*Color) UnloadImagePalette ¶
func (self *Color) UnloadImagePalette()
Unload colors palette loaded with LoadImagePalette()
llgo:link (*Color).UnloadImagePalette C.UnloadImagePalette
type ConfigFlags ¶
---------------------------------------------------------------------------------- Enumerators Definition ---------------------------------------------------------------------------------- System/Window config flags NOTE: Every bit registers one state (use it with bit masks) By default all flags are set to 0
const ( FLAG_VSYNC_HINT ConfigFlags = 64 FLAG_FULLSCREEN_MODE ConfigFlags = 2 FLAG_WINDOW_RESIZABLE ConfigFlags = 4 FLAG_WINDOW_UNDECORATED ConfigFlags = 8 FLAG_WINDOW_HIDDEN ConfigFlags = 128 FLAG_WINDOW_MINIMIZED ConfigFlags = 512 FLAG_WINDOW_MAXIMIZED ConfigFlags = 1024 FLAG_WINDOW_UNFOCUSED ConfigFlags = 2048 FLAG_WINDOW_TOPMOST ConfigFlags = 4096 FLAG_WINDOW_ALWAYS_RUN ConfigFlags = 256 FLAG_WINDOW_TRANSPARENT ConfigFlags = 16 FLAG_WINDOW_HIGHDPI ConfigFlags = 8192 FLAG_WINDOW_MOUSE_PASSTHROUGH ConfigFlags = 16384 FLAG_BORDERLESS_WINDOWED_MODE ConfigFlags = 32768 FLAG_MSAA_4X_HINT ConfigFlags = 32 // Set to try enabling interlaced video format (for V3D) FLAG_INTERLACED_HINT ConfigFlags = 65536 )
type CubemapLayout ¶
Cubemap layouts
const ( CUBEMAP_LAYOUT_AUTO_DETECT CubemapLayout = 0 CUBEMAP_LAYOUT_LINE_VERTICAL CubemapLayout = 1 CUBEMAP_LAYOUT_LINE_HORIZONTAL CubemapLayout = 2 CUBEMAP_LAYOUT_CROSS_THREE_BY_FOUR CubemapLayout = 3 // Layout is defined by a 4x3 cross with cubemap faces CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE CubemapLayout = 4 )
type FilePathList ¶
File path list
func LoadDirectoryFiles ¶
func LoadDirectoryFiles(dirPath *c.Char) FilePathList
Load directory filepaths, files and directories, no subdirs scan
func LoadDirectoryFilesEx ¶
Load directory filepaths with extension filtering and subdir scan; some filters available: "*.*", "FILES*", "DIRS*"
func (FilePathList) UnloadDirectoryFiles ¶
func (self FilePathList) UnloadDirectoryFiles()
Unload filepaths
llgo:link FilePathList.UnloadDirectoryFiles C.UnloadDirectoryFiles
func (FilePathList) UnloadDroppedFiles ¶
func (self FilePathList) UnloadDroppedFiles()
Unload dropped filepaths
llgo:link FilePathList.UnloadDroppedFiles C.UnloadDroppedFiles
type Font ¶
type Font struct {
BaseSize c.Int
GlyphCount c.Int
GlyphPadding c.Int
Texture Texture2D
Recs *Rectangle
Glyphs *GlyphInfo
}
Font, font texture and GlyphInfo array data
func LoadFontEx ¶
Load font from file with extended parameters, use NULL for codepoints and 0 for codepointCount to load the default character set, font size is provided in pixels height
func LoadFontFromMemory ¶
func LoadFontFromMemory(fileType *c.Char, fileData *uint8, dataSize c.Int, fontSize c.Int, codepoints *c.Int, codepointCount c.Int) Font
Load font from memory buffer, fileType refers to extension: i.e. '.ttf'
func (Font) DrawTextCodepoint ¶
Draw one character (codepoint)
llgo:link Font.DrawTextCodepoint C.DrawTextCodepoint
func (Font) DrawTextCodepoints ¶
func (self Font) DrawTextCodepoints(codepoints *c.Int, codepointCount c.Int, position Vector2, fontSize c.Float, spacing c.Float, tint Color)
Draw multiple character (codepoint)
llgo:link Font.DrawTextCodepoints C.DrawTextCodepoints
func (Font) DrawTextEx ¶
func (self Font) DrawTextEx(text *c.Char, position Vector2, fontSize c.Float, spacing c.Float, tint Color)
Draw text using font and additional parameters
llgo:link Font.DrawTextEx C.DrawTextEx
func (Font) DrawTextPro ¶
func (self Font) DrawTextPro(text *c.Char, position Vector2, origin Vector2, rotation c.Float, fontSize c.Float, spacing c.Float, tint Color)
Draw text using Font and pro parameters (rotation)
llgo:link Font.DrawTextPro C.DrawTextPro
func (Font) ExportFontAsCode ¶
Export font as code file, returns true on success
llgo:link Font.ExportFontAsCode C.ExportFontAsCode
func (Font) GlyphAtlasRec ¶
Get glyph rectangle in font atlas for a codepoint (unicode character), fallback to '?' if not found
llgo:link Font.GlyphAtlasRec C.GetGlyphAtlasRec
func (Font) GlyphIndex ¶
Get glyph index position in font for a codepoint (unicode character), fallback to '?' if not found
llgo:link Font.GlyphIndex C.GetGlyphIndex
func (Font) GlyphInfo ¶
Get glyph font info data for a codepoint (unicode character), fallback to '?' if not found
llgo:link Font.GlyphInfo C.GetGlyphInfo
func (Font) ImageTextEx ¶
Create an image from text (custom sprite font)
llgo:link Font.ImageTextEx C.ImageTextEx
func (Font) IsFontValid ¶
Check if a font is valid (font data loaded, WARNING: GPU texture not checked)
llgo:link Font.IsFontValid C.IsFontValid
func (Font) MeasureTextCodepoints ¶
func (self Font) MeasureTextCodepoints(codepoints *c.Int, length c.Int, fontSize c.Float, spacing c.Float) Vector2
Measure string size for an existing array of codepoints for Font
llgo:link Font.MeasureTextCodepoints C.MeasureTextCodepoints
func (Font) MeasureTextEx ¶
Measure string size for Font
llgo:link Font.MeasureTextEx C.MeasureTextEx
type GamepadAxis ¶
Gamepad axes
const ( GAMEPAD_AXIS_LEFT_X GamepadAxis = 0 GAMEPAD_AXIS_LEFT_Y GamepadAxis = 1 GAMEPAD_AXIS_RIGHT_X GamepadAxis = 2 GAMEPAD_AXIS_RIGHT_Y GamepadAxis = 3 GAMEPAD_AXIS_LEFT_TRIGGER GamepadAxis = 4 // Gamepad back trigger right, pressure level: [1..-1] GAMEPAD_AXIS_RIGHT_TRIGGER GamepadAxis = 5 )
type GamepadButton ¶
Gamepad buttons
const ( GAMEPAD_BUTTON_UNKNOWN GamepadButton = 0 GAMEPAD_BUTTON_LEFT_FACE_UP GamepadButton = 1 GAMEPAD_BUTTON_LEFT_FACE_RIGHT GamepadButton = 2 GAMEPAD_BUTTON_LEFT_FACE_DOWN GamepadButton = 3 GAMEPAD_BUTTON_LEFT_FACE_LEFT GamepadButton = 4 GAMEPAD_BUTTON_RIGHT_FACE_UP GamepadButton = 5 GAMEPAD_BUTTON_RIGHT_FACE_RIGHT GamepadButton = 6 GAMEPAD_BUTTON_RIGHT_FACE_DOWN GamepadButton = 7 GAMEPAD_BUTTON_RIGHT_FACE_LEFT GamepadButton = 8 GAMEPAD_BUTTON_LEFT_TRIGGER_1 GamepadButton = 9 GAMEPAD_BUTTON_LEFT_TRIGGER_2 GamepadButton = 10 GAMEPAD_BUTTON_RIGHT_TRIGGER_1 GamepadButton = 11 GAMEPAD_BUTTON_RIGHT_TRIGGER_2 GamepadButton = 12 GAMEPAD_BUTTON_MIDDLE_LEFT GamepadButton = 13 GAMEPAD_BUTTON_MIDDLE GamepadButton = 14 GAMEPAD_BUTTON_MIDDLE_RIGHT GamepadButton = 15 GAMEPAD_BUTTON_LEFT_THUMB GamepadButton = 16 // Gamepad joystick pressed button right GAMEPAD_BUTTON_RIGHT_THUMB GamepadButton = 17 )
type Gesture ¶
Gesture NOTE: Provided as bit-wise flags to enable only desired gestures
const ( GESTURE_NONE Gesture = 0 GESTURE_TAP Gesture = 1 GESTURE_DOUBLETAP Gesture = 2 GESTURE_HOLD Gesture = 4 GESTURE_DRAG Gesture = 8 GESTURE_SWIPE_RIGHT Gesture = 16 GESTURE_SWIPE_LEFT Gesture = 32 GESTURE_SWIPE_UP Gesture = 64 GESTURE_SWIPE_DOWN Gesture = 128 GESTURE_PINCH_IN Gesture = 256 // Pinch out gesture GESTURE_PINCH_OUT Gesture = 512 )
type GlyphInfo ¶
GlyphInfo, font characters glyphs info
func LoadFontData ¶
func LoadFontData(fileData *uint8, dataSize c.Int, fontSize c.Int, codepoints *c.Int, codepointCount c.Int, type_ c.Int, glyphCount *c.Int) *GlyphInfo
Load font data for further use
func (*GlyphInfo) GenImageFontAtlas ¶
func (self *GlyphInfo) GenImageFontAtlas(glyphRecs **Rectangle, glyphCount c.Int, fontSize c.Int, padding c.Int, packMethod c.Int) Image
Generate image font atlas using chars info
llgo:link (*GlyphInfo).GenImageFontAtlas C.GenImageFontAtlas
func (*GlyphInfo) UnloadFontData ¶
Unload font chars info data (RAM)
llgo:link (*GlyphInfo).UnloadFontData C.UnloadFontData
type Image ¶
Image, pixel data stored in CPU memory (RAM)
func GenImageCellular ¶
Generate image: cellular algorithm, bigger tileSize means bigger cells
func GenImageChecked ¶
func GenImageChecked(width c.Int, height c.Int, checksX c.Int, checksY c.Int, col1 Color, col2 Color) Image
Generate image: checked
func GenImageColor ¶
Image generation functions
func GenImageGradientLinear ¶
func GenImageGradientLinear(width c.Int, height c.Int, direction c.Int, start Color, end Color) Image
Generate image: linear gradient, direction in degrees [0..360], 0=Vertical gradient
func GenImageGradientRadial ¶
func GenImageGradientRadial(width c.Int, height c.Int, density c.Float, inner Color, outer Color) Image
Generate image: radial gradient
func GenImageGradientSquare ¶
func GenImageGradientSquare(width c.Int, height c.Int, density c.Float, inner Color, outer Color) Image
Generate image: square gradient
func GenImagePerlinNoise ¶
func GenImagePerlinNoise(width c.Int, height c.Int, offsetX c.Int, offsetY c.Int, scale c.Float) Image
Generate image: perlin noise
func GenImageText ¶
Generate image: grayscale image from text data
func GenImageWhiteNoise ¶
Generate image: white noise
func LoadImageAnim ¶
Load image sequence from file (frames appended to image.data)
func LoadImageAnimFromMemory ¶
func LoadImageAnimFromMemory(fileType *c.Char, fileData *uint8, dataSize c.Int, frames *c.Int) Image
Load image sequence from memory buffer
func LoadImageFromMemory ¶
Load image from memory buffer, fileType refers to extension: i.e. '.png'
func LoadImageFromScreen ¶
func LoadImageFromScreen() Image
Load image from screen buffer and (screenshot)
func LoadImageRaw ¶
func LoadImageRaw(fileName *c.Char, width c.Int, height c.Int, format c.Int, headerSize c.Int) Image
Load image from RAW file data
func (Image) AlphaBorder ¶
Get image alpha border rectangle
llgo:link Image.AlphaBorder C.GetImageAlphaBorder
func (*Image) AlphaClear ¶
Clear alpha channel to desired color
llgo:link (*Image).AlphaClear C.ImageAlphaClear
func (*Image) AlphaCrop ¶
Crop image depending on alpha value
llgo:link (*Image).AlphaCrop C.ImageAlphaCrop
func (*Image) AlphaPremultiply ¶
func (self *Image) AlphaPremultiply()
Premultiply alpha channel
llgo:link (*Image).AlphaPremultiply C.ImageAlphaPremultiply
func (*Image) BlurGaussian ¶
Apply Gaussian blur using a box blur approximation
llgo:link (*Image).BlurGaussian C.ImageBlurGaussian
func (*Image) ClearBackground ¶
Image drawing functions NOTE: Image software-rendering functions (CPU)
llgo:link (*Image).ClearBackground C.ImageClearBackground
func (*Image) ColorBrightness ¶
Modify image color: brightness (-255 to 255)
llgo:link (*Image).ColorBrightness C.ImageColorBrightness
func (*Image) ColorContrast ¶
Modify image color: contrast (-100 to 100)
llgo:link (*Image).ColorContrast C.ImageColorContrast
func (*Image) ColorGrayscale ¶
func (self *Image) ColorGrayscale()
Modify image color: grayscale
llgo:link (*Image).ColorGrayscale C.ImageColorGrayscale
func (*Image) ColorInvert ¶
func (self *Image) ColorInvert()
Modify image color: invert
llgo:link (*Image).ColorInvert C.ImageColorInvert
func (*Image) ColorReplace ¶
Modify image color: replace color
llgo:link (*Image).ColorReplace C.ImageColorReplace
func (*Image) Dither ¶
Dither image data to 16bpp or lower (Floyd-Steinberg dithering)
llgo:link (*Image).Dither C.ImageDither
func (*Image) Draw ¶
Draw a source image within a destination image (tint applied to source)
llgo:link (*Image).Draw C.ImageDraw
func (*Image) DrawCircle ¶
Draw a filled circle within an image
llgo:link (*Image).DrawCircle C.ImageDrawCircle
func (*Image) DrawCircleLines ¶
Draw circle outline within an image
llgo:link (*Image).DrawCircleLines C.ImageDrawCircleLines
func (*Image) DrawCircleLinesV ¶
Draw circle outline within an image (Vector version)
llgo:link (*Image).DrawCircleLinesV C.ImageDrawCircleLinesV
func (*Image) DrawCircleV ¶
Draw a filled circle within an image (Vector version)
llgo:link (*Image).DrawCircleV C.ImageDrawCircleV
func (*Image) DrawLine ¶
func (self *Image) DrawLine(startPosX c.Int, startPosY c.Int, endPosX c.Int, endPosY c.Int, color Color)
Draw line within an image
llgo:link (*Image).DrawLine C.ImageDrawLine
func (*Image) DrawLineEx ¶
Draw a line defining thickness within an image
llgo:link (*Image).DrawLineEx C.ImageDrawLineEx
func (*Image) DrawLineV ¶
Draw line within an image (Vector version)
llgo:link (*Image).DrawLineV C.ImageDrawLineV
func (*Image) DrawPixelV ¶
Draw pixel within an image (Vector version)
llgo:link (*Image).DrawPixelV C.ImageDrawPixelV
func (*Image) DrawRectangle ¶
Draw rectangle within an image
llgo:link (*Image).DrawRectangle C.ImageDrawRectangle
func (*Image) DrawRectangleLines ¶
Draw rectangle lines within an image
llgo:link (*Image).DrawRectangleLines C.ImageDrawRectangleLines
func (*Image) DrawRectangleRec ¶
Draw rectangle within an image
llgo:link (*Image).DrawRectangleRec C.ImageDrawRectangleRec
func (*Image) DrawRectangleV ¶
Draw rectangle within an image (Vector version)
llgo:link (*Image).DrawRectangleV C.ImageDrawRectangleV
func (*Image) DrawText ¶
Draw text (using default font) within an image (destination)
llgo:link (*Image).DrawText C.ImageDrawText
func (*Image) DrawTextEx ¶
func (self *Image) DrawTextEx(font Font, text *c.Char, position Vector2, fontSize c.Float, spacing c.Float, tint Color)
Draw text (custom sprite font) within an image (destination)
llgo:link (*Image).DrawTextEx C.ImageDrawTextEx
func (*Image) DrawTriangle ¶
Draw triangle within an image
llgo:link (*Image).DrawTriangle C.ImageDrawTriangle
func (*Image) DrawTriangleEx ¶
Draw triangle with interpolated colors within an image
llgo:link (*Image).DrawTriangleEx C.ImageDrawTriangleEx
func (*Image) DrawTriangleFan ¶
Draw a triangle fan defined by points within an image (first vertex is the center)
llgo:link (*Image).DrawTriangleFan C.ImageDrawTriangleFan
func (*Image) DrawTriangleLines ¶
Draw triangle outline within an image
llgo:link (*Image).DrawTriangleLines C.ImageDrawTriangleLines
func (*Image) DrawTriangleStrip ¶
Draw a triangle strip defined by points within an image
llgo:link (*Image).DrawTriangleStrip C.ImageDrawTriangleStrip
func (Image) Export ¶
Export image data to file, returns true on success
llgo:link Image.Export C.ExportImage
func (Image) ExportImageAsCode ¶
Export image as code file defining an array of bytes, returns true on success
llgo:link Image.ExportImageAsCode C.ExportImageAsCode
func (Image) ExportImageToMemory ¶
Export image to memory buffer, memory must be MemFree()
llgo:link Image.ExportImageToMemory C.ExportImageToMemory
func (*Image) FlipHorizontal ¶
func (self *Image) FlipHorizontal()
Flip image horizontally
llgo:link (*Image).FlipHorizontal C.ImageFlipHorizontal
func (*Image) FlipVertical ¶
func (self *Image) FlipVertical()
Flip image vertically
llgo:link (*Image).FlipVertical C.ImageFlipVertical
func (Image) FromChannel ¶
Create an image from a selected channel of another image (GRAYSCALE)
llgo:link Image.FromChannel C.ImageFromChannel
func (Image) GenMeshCubicmap ¶
Generate cubes-based map mesh from image data
llgo:link Image.GenMeshCubicmap C.GenMeshCubicmap
func (Image) GenMeshHeightmap ¶
Generate heightmap mesh from image data
llgo:link Image.GenMeshHeightmap C.GenMeshHeightmap
func (*Image) ImageFormat ¶
Convert image data to desired format
llgo:link (*Image).ImageFormat C.ImageFormat
func (*Image) ImageMipmaps ¶
func (self *Image) ImageMipmaps()
Compute all mipmap levels for a provided image
llgo:link (*Image).ImageMipmaps C.ImageMipmaps
func (Image) IsImageValid ¶
Check if an image is valid (data and parameters)
llgo:link Image.IsImageValid C.IsImageValid
func (*Image) KernelConvolution ¶
Apply custom square convolution kernel to image
llgo:link (*Image).KernelConvolution C.ImageKernelConvolution
func (Image) LoadFontFrom ¶
Load font from Image (XNA style)
llgo:link Image.LoadFontFrom C.LoadFontFromImage
func (Image) LoadImageColors ¶
Load color data from image as a Color array (RGBA - 32bit)
llgo:link Image.LoadImageColors C.LoadImageColors
func (Image) LoadImagePalette ¶
Load colors palette from image as a Color array (RGBA - 32bit)
llgo:link Image.LoadImagePalette C.LoadImagePalette
func (Image) LoadTextureCubemap ¶
func (self Image) LoadTextureCubemap(layout c.Int) TextureCubemap
Load cubemap from image, multiple image cubemap layouts supported
llgo:link Image.LoadTextureCubemap C.LoadTextureCubemap
func (Image) LoadTextureFrom ¶
Load texture from image data
llgo:link Image.LoadTextureFrom C.LoadTextureFromImage
func (*Image) Resize ¶
Resize image (Bicubic scaling algorithm)
llgo:link (*Image).Resize C.ImageResize
func (*Image) ResizeCanvas ¶
func (self *Image) ResizeCanvas(newWidth c.Int, newHeight c.Int, offsetX c.Int, offsetY c.Int, fill Color)
Resize canvas and fill with color
llgo:link (*Image).ResizeCanvas C.ImageResizeCanvas
func (*Image) ResizeNN ¶
Resize image (Nearest-Neighbor scaling algorithm)
llgo:link (*Image).ResizeNN C.ImageResizeNN
func (*Image) Rotate ¶
Rotate image by input angle in degrees (-359 to 359)
llgo:link (*Image).Rotate C.ImageRotate
func (*Image) RotateCCW ¶
func (self *Image) RotateCCW()
Rotate image counter-clockwise 90deg
llgo:link (*Image).RotateCCW C.ImageRotateCCW
func (*Image) RotateCW ¶
func (self *Image) RotateCW()
Rotate image clockwise 90deg
llgo:link (*Image).RotateCW C.ImageRotateCW
func (Image) SetWindowIcon ¶
func (self Image) SetWindowIcon()
Set icon for window (single image, RGBA 32bit)
llgo:link Image.SetWindowIcon C.SetWindowIcon
func (*Image) SetWindowIcons ¶
Set icon for window (multiple images, RGBA 32bit)
llgo:link (*Image).SetWindowIcons C.SetWindowIcons
type KeyboardKey ¶
Keyboard keys (US keyboard layout) NOTE: Use GetKeyPressed() to allow redefining required keys for alternative layouts
const ( KEY_NULL KeyboardKey = 0 // Alphanumeric keys KEY_APOSTROPHE KeyboardKey = 39 KEY_COMMA KeyboardKey = 44 KEY_MINUS KeyboardKey = 45 KEY_PERIOD KeyboardKey = 46 KEY_SLASH KeyboardKey = 47 KEY_ZERO KeyboardKey = 48 KEY_ONE KeyboardKey = 49 KEY_TWO KeyboardKey = 50 KEY_THREE KeyboardKey = 51 KEY_FOUR KeyboardKey = 52 KEY_FIVE KeyboardKey = 53 KEY_SIX KeyboardKey = 54 KEY_SEVEN KeyboardKey = 55 KEY_EIGHT KeyboardKey = 56 KEY_NINE KeyboardKey = 57 KEY_SEMICOLON KeyboardKey = 59 KEY_EQUAL KeyboardKey = 61 KEY_A KeyboardKey = 65 KEY_B KeyboardKey = 66 KEY_C KeyboardKey = 67 KEY_D KeyboardKey = 68 KEY_E KeyboardKey = 69 KEY_F KeyboardKey = 70 KEY_G KeyboardKey = 71 KEY_H KeyboardKey = 72 KEY_I KeyboardKey = 73 KEY_J KeyboardKey = 74 KEY_K KeyboardKey = 75 KEY_L KeyboardKey = 76 KEY_M KeyboardKey = 77 KEY_N KeyboardKey = 78 KEY_O KeyboardKey = 79 KEY_P KeyboardKey = 80 KEY_Q KeyboardKey = 81 KEY_R KeyboardKey = 82 KEY_S KeyboardKey = 83 KEY_T KeyboardKey = 84 KEY_U KeyboardKey = 85 KEY_V KeyboardKey = 86 KEY_W KeyboardKey = 87 KEY_X KeyboardKey = 88 KEY_Y KeyboardKey = 89 KEY_Z KeyboardKey = 90 KEY_LEFT_BRACKET KeyboardKey = 91 KEY_BACKSLASH KeyboardKey = 92 KEY_RIGHT_BRACKET KeyboardKey = 93 KEY_GRAVE KeyboardKey = 96 // Function keys KEY_SPACE KeyboardKey = 32 KEY_ESCAPE KeyboardKey = 256 KEY_ENTER KeyboardKey = 257 KEY_TAB KeyboardKey = 258 KEY_BACKSPACE KeyboardKey = 259 KEY_INSERT KeyboardKey = 260 KEY_DELETE KeyboardKey = 261 KEY_RIGHT KeyboardKey = 262 KEY_LEFT KeyboardKey = 263 KEY_DOWN KeyboardKey = 264 KEY_UP KeyboardKey = 265 KEY_PAGE_UP KeyboardKey = 266 KEY_PAGE_DOWN KeyboardKey = 267 KEY_HOME KeyboardKey = 268 KEY_END KeyboardKey = 269 KEY_CAPS_LOCK KeyboardKey = 280 KEY_SCROLL_LOCK KeyboardKey = 281 KEY_NUM_LOCK KeyboardKey = 282 KEY_PRINT_SCREEN KeyboardKey = 283 KEY_PAUSE KeyboardKey = 284 KEY_F1 KeyboardKey = 290 KEY_F2 KeyboardKey = 291 KEY_F3 KeyboardKey = 292 KEY_F4 KeyboardKey = 293 KEY_F5 KeyboardKey = 294 KEY_F6 KeyboardKey = 295 KEY_F7 KeyboardKey = 296 KEY_F8 KeyboardKey = 297 KEY_F9 KeyboardKey = 298 KEY_F10 KeyboardKey = 299 KEY_F11 KeyboardKey = 300 KEY_F12 KeyboardKey = 301 KEY_LEFT_SHIFT KeyboardKey = 340 KEY_LEFT_CONTROL KeyboardKey = 341 KEY_LEFT_ALT KeyboardKey = 342 KEY_LEFT_SUPER KeyboardKey = 343 KEY_RIGHT_SHIFT KeyboardKey = 344 KEY_RIGHT_CONTROL KeyboardKey = 345 KEY_RIGHT_ALT KeyboardKey = 346 KEY_RIGHT_SUPER KeyboardKey = 347 KEY_KB_MENU KeyboardKey = 348 // Keypad keys KEY_KP_0 KeyboardKey = 320 KEY_KP_1 KeyboardKey = 321 KEY_KP_2 KeyboardKey = 322 KEY_KP_3 KeyboardKey = 323 KEY_KP_4 KeyboardKey = 324 KEY_KP_5 KeyboardKey = 325 KEY_KP_6 KeyboardKey = 326 KEY_KP_7 KeyboardKey = 327 KEY_KP_8 KeyboardKey = 328 KEY_KP_9 KeyboardKey = 329 KEY_KP_DECIMAL KeyboardKey = 330 KEY_KP_DIVIDE KeyboardKey = 331 KEY_KP_MULTIPLY KeyboardKey = 332 KEY_KP_SUBTRACT KeyboardKey = 333 KEY_KP_ADD KeyboardKey = 334 KEY_KP_ENTER KeyboardKey = 335 KEY_KP_EQUAL KeyboardKey = 336 // Android key buttons KEY_BACK KeyboardKey = 4 KEY_MENU KeyboardKey = 5 KEY_VOLUME_UP KeyboardKey = 24 // Key: Android volume down button KEY_VOLUME_DOWN KeyboardKey = 25 )
type Material ¶
type Material struct {
Shader Shader
Maps *MaterialMap
Params [4]c.Float
}
Material, includes shader and maps
func LoadMaterialDefault ¶
func LoadMaterialDefault() Material
Load default material (Supports: DIFFUSE, SPECULAR, NORMAL maps)
func LoadMaterials ¶
Material loading/unloading functions
func (Material) IsMaterialValid ¶
Check if a material is valid (shader assigned, map textures loaded in GPU)
llgo:link Material.IsMaterialValid C.IsMaterialValid
func (*Material) SetMaterialTexture ¶
Set texture for a material map type (MATERIAL_MAP_DIFFUSE, MATERIAL_MAP_SPECULAR...)
llgo:link (*Material).SetMaterialTexture C.SetMaterialTexture
type MaterialMap ¶
MaterialMap
type MaterialMapIndex ¶
Material map index
const ( MATERIAL_MAP_ALBEDO MaterialMapIndex = 0 MATERIAL_MAP_METALNESS MaterialMapIndex = 1 MATERIAL_MAP_NORMAL MaterialMapIndex = 2 MATERIAL_MAP_ROUGHNESS MaterialMapIndex = 3 MATERIAL_MAP_OCCLUSION MaterialMapIndex = 4 MATERIAL_MAP_EMISSION MaterialMapIndex = 5 MATERIAL_MAP_HEIGHT MaterialMapIndex = 6 MATERIAL_MAP_CUBEMAP MaterialMapIndex = 7 MATERIAL_MAP_IRRADIANCE MaterialMapIndex = 8 MATERIAL_MAP_PREFILTER MaterialMapIndex = 9 // Brdf material MATERIAL_MAP_BRDF MaterialMapIndex = 10 )
type Matrix ¶
type Matrix struct {
M0 c.Float
M4 c.Float
M8 c.Float
M12 c.Float
M1 c.Float
M5 c.Float
M9 c.Float
M13 c.Float
M2 c.Float
M6 c.Float
M10 c.Float
M14 c.Float
M3 c.Float
M7 c.Float
M11 c.Float
M15 c.Float
}
Matrix, 4x4 components, column major, OpenGL style, right-handed
type Mesh ¶
type Mesh struct {
VertexCount c.Int
TriangleCount c.Int
Vertices *c.Float
Texcoords *c.Float
Texcoords2 *c.Float
Normals *c.Float
Tangents *c.Float
Colors *uint8
Indices *uint16
BoneCount c.Int
BoneIndices *uint8
BoneWeights *c.Float
AnimVertices *c.Float
AnimNormals *c.Float
VaoId c.Uint
VboId *c.Uint
}
Mesh, vertex data and vao/vbo
func GenMeshCone ¶
Generate cone/pyramid mesh
func GenMeshCube ¶
Generate cuboid mesh
func GenMeshCylinder ¶
Generate cylinder mesh
func GenMeshHemiSphere ¶
Generate half-sphere mesh (no bottom cap)
func GenMeshKnot ¶
Generate trefoil knot mesh
func GenMeshPlane ¶
Generate plane mesh (with subdivisions)
func GenMeshSphere ¶
Generate sphere mesh (standard sphere)
func GenMeshTorus ¶
Generate torus mesh
func (Mesh) BoundingBox ¶
func (self Mesh) BoundingBox() BoundingBox
Compute mesh bounding box limits
llgo:link Mesh.BoundingBox C.GetMeshBoundingBox
func (Mesh) DrawMeshInstanced ¶
Draw multiple mesh instances with material and different transforms
llgo:link Mesh.DrawMeshInstanced C.DrawMeshInstanced
func (Mesh) Export ¶
Export mesh data to file, returns true on success
llgo:link Mesh.Export C.ExportMesh
func (Mesh) ExportMeshAsCode ¶
Export mesh as code file (.h) defining multiple arrays of vertex attributes
llgo:link Mesh.ExportMeshAsCode C.ExportMeshAsCode
func (*Mesh) GenMeshTangents ¶
func (self *Mesh) GenMeshTangents()
Compute mesh tangents
llgo:link (*Mesh).GenMeshTangents C.GenMeshTangents
func (Mesh) LoadModelFrom ¶
Load model from generated mesh (default material)
llgo:link Mesh.LoadModelFrom C.LoadModelFromMesh
func (Mesh) Unload ¶
func (self Mesh) Unload()
Unload mesh data from CPU and GPU
llgo:link Mesh.Unload C.UnloadMesh
func (Mesh) UpdateMeshBuffer ¶
Update mesh vertex data in GPU for a specific buffer index
llgo:link Mesh.UpdateMeshBuffer C.UpdateMeshBuffer
type Model ¶
type Model struct {
Transform Matrix
MeshCount c.Int
MaterialCount c.Int
Meshes *Mesh
Materials *Material
MeshMaterial *c.Int
Skeleton ModelSkeleton
CurrentPose ModelAnimPose
BoneMatrices *Matrix
}
Model, meshes, materials and animation data
func (Model) BoundingBox ¶
func (self Model) BoundingBox() BoundingBox
Compute model bounding box limits (considers all meshes)
llgo:link Model.BoundingBox C.GetModelBoundingBox
func (Model) DrawModelEx ¶
func (self Model) DrawModelEx(position Vector3, rotationAxis Vector3, rotationAngle c.Float, scale Vector3, tint Color)
Draw a model with extended parameters
llgo:link Model.DrawModelEx C.DrawModelEx
func (Model) DrawModelWires ¶
Draw a model wires (with texture if set)
llgo:link Model.DrawModelWires C.DrawModelWires
func (Model) DrawModelWiresEx ¶
func (self Model) DrawModelWiresEx(position Vector3, rotationAxis Vector3, rotationAngle c.Float, scale Vector3, tint Color)
Draw a model wires (with texture if set) with extended parameters
llgo:link Model.DrawModelWiresEx C.DrawModelWiresEx
func (Model) IsModelAnimationValid ¶
func (self Model) IsModelAnimationValid(anim ModelAnimation) bool
Check model animation skeleton match
llgo:link Model.IsModelAnimationValid C.IsModelAnimationValid
func (Model) IsModelValid ¶
Check if a model is valid (loaded in GPU, VAO/VBOs)
llgo:link Model.IsModelValid C.IsModelValid
func (*Model) SetModelMeshMaterial ¶
Set material for a mesh
llgo:link (*Model).SetModelMeshMaterial C.SetModelMeshMaterial
func (Model) Unload ¶
func (self Model) Unload()
Unload model (including meshes) from memory (RAM and/or VRAM)
llgo:link Model.Unload C.UnloadModel
func (Model) UpdateModelAnimation ¶
func (self Model) UpdateModelAnimation(anim ModelAnimation, frame c.Float)
Update model animation pose (vertex buffers and bone matrices)
llgo:link Model.UpdateModelAnimation C.UpdateModelAnimation
func (Model) UpdateModelAnimationEx ¶
func (self Model) UpdateModelAnimationEx(animA ModelAnimation, frameA c.Float, animB ModelAnimation, frameB c.Float, blend c.Float)
Update model animation pose, blending two animations
llgo:link Model.UpdateModelAnimationEx C.UpdateModelAnimationEx
type ModelAnimation ¶
type ModelAnimation struct {
Name [32]c.Char
BoneCount c.Int
KeyframeCount c.Int
KeyframePoses *ModelAnimPose
}
ModelAnimation, contains a full animation sequence
func LoadModelAnimations ¶
func LoadModelAnimations(fileName *c.Char, animCount *c.Int) *ModelAnimation
Model animations loading/unloading functions
func (*ModelAnimation) UnloadModelAnimations ¶
func (self *ModelAnimation) UnloadModelAnimations(animCount c.Int)
Unload animation array data
llgo:link (*ModelAnimation).UnloadModelAnimations C.UnloadModelAnimations
type ModelSkeleton ¶
type ModelSkeleton struct {
BoneCount c.Int
Bones *BoneInfo
BindPose ModelAnimPose
}
Skeleton, animation bones hierarchy
type MouseButton ¶
Mouse buttons
const ( MOUSE_BUTTON_LEFT MouseButton = 0 MOUSE_BUTTON_RIGHT MouseButton = 1 MOUSE_BUTTON_MIDDLE MouseButton = 2 MOUSE_BUTTON_SIDE MouseButton = 3 MOUSE_BUTTON_EXTRA MouseButton = 4 MOUSE_BUTTON_FORWARD MouseButton = 5 MOUSE_BUTTON_BACK MouseButton = 6 )
type MouseCursor ¶
Mouse cursor
const ( MOUSE_CURSOR_DEFAULT MouseCursor = 0 MOUSE_CURSOR_ARROW MouseCursor = 1 MOUSE_CURSOR_IBEAM MouseCursor = 2 MOUSE_CURSOR_CROSSHAIR MouseCursor = 3 MOUSE_CURSOR_POINTING_HAND MouseCursor = 4 MOUSE_CURSOR_RESIZE_EW MouseCursor = 5 MOUSE_CURSOR_RESIZE_NS MouseCursor = 6 MOUSE_CURSOR_RESIZE_NWSE MouseCursor = 7 MOUSE_CURSOR_RESIZE_NESW MouseCursor = 8 MOUSE_CURSOR_RESIZE_ALL MouseCursor = 9 // The operation-not-allowed shape MOUSE_CURSOR_NOT_ALLOWED MouseCursor = 10 )
type Music ¶
type Music struct {
Stream AudioStream
FrameCount c.Uint
Looping bool
CtxType c.Int
CtxData unsafe.Pointer
}
Music, audio stream, anything longer than ~10 seconds should be streamed
func LoadMusicStreamFromMemory ¶
Load music stream from data
func (Music) IsMusicStreamPlaying ¶
Check if music is playing
llgo:link Music.IsMusicStreamPlaying C.IsMusicStreamPlaying
func (Music) IsMusicValid ¶
Checks if a music stream is valid (context and buffers initialized)
llgo:link Music.IsMusicValid C.IsMusicValid
func (Music) PauseMusicStream ¶
func (self Music) PauseMusicStream()
Pause music playing
llgo:link Music.PauseMusicStream C.PauseMusicStream
func (Music) PlayMusicStream ¶
func (self Music) PlayMusicStream()
Start music playing
llgo:link Music.PlayMusicStream C.PlayMusicStream
func (Music) ResumeMusicStream ¶
func (self Music) ResumeMusicStream()
Resume playing paused music
llgo:link Music.ResumeMusicStream C.ResumeMusicStream
func (Music) SeekMusicStream ¶
Seek music to a position (in seconds)
llgo:link Music.SeekMusicStream C.SeekMusicStream
func (Music) SetMusicPan ¶
Set pan for a music (-1.0 left, 0.0 center, 1.0 right)
llgo:link Music.SetMusicPan C.SetMusicPan
func (Music) SetMusicPitch ¶
Set pitch for a music (1.0 is base level)
llgo:link Music.SetMusicPitch C.SetMusicPitch
func (Music) SetMusicVolume ¶
Set volume for music (1.0 is max level)
llgo:link Music.SetMusicVolume C.SetMusicVolume
func (Music) StopMusicStream ¶
func (self Music) StopMusicStream()
Stop music playing
llgo:link Music.StopMusicStream C.StopMusicStream
func (Music) TimeLength ¶
Get music time length (in seconds)
llgo:link Music.TimeLength C.GetMusicTimeLength
func (Music) TimePlayed ¶
Get current music time played (in seconds)
llgo:link Music.TimePlayed C.GetMusicTimePlayed
func (Music) UnloadMusicStream ¶
func (self Music) UnloadMusicStream()
Unload music stream
llgo:link Music.UnloadMusicStream C.UnloadMusicStream
func (Music) UpdateMusicStream ¶
func (self Music) UpdateMusicStream()
Updates buffers for music streaming
llgo:link Music.UpdateMusicStream C.UpdateMusicStream
type NPatchInfo ¶
type NPatchInfo struct {
Source Rectangle
Left c.Int
Top c.Int
Right c.Int
Bottom c.Int
Layout c.Int
}
NPatchInfo, n-patch layout info
type NPatchLayout ¶
N-patch layout
const ( NPATCH_NINE_PATCH NPatchLayout = 0 NPATCH_THREE_PATCH_VERTICAL NPatchLayout = 1 // Npatch layout: 3x1 tiles NPATCH_THREE_PATCH_HORIZONTAL NPatchLayout = 2 )
type PixelFormat ¶
Pixel formats NOTE: Support depends on OpenGL version and platform
const ( PIXELFORMAT_UNCOMPRESSED_GRAYSCALE PixelFormat = 1 PIXELFORMAT_UNCOMPRESSED_GRAY_ALPHA PixelFormat = 2 PIXELFORMAT_UNCOMPRESSED_R5G6B5 PixelFormat = 3 PIXELFORMAT_UNCOMPRESSED_R8G8B8 PixelFormat = 4 PIXELFORMAT_UNCOMPRESSED_R5G5B5A1 PixelFormat = 5 PIXELFORMAT_UNCOMPRESSED_R4G4B4A4 PixelFormat = 6 PIXELFORMAT_UNCOMPRESSED_R8G8B8A8 PixelFormat = 7 PIXELFORMAT_UNCOMPRESSED_R32 PixelFormat = 8 PIXELFORMAT_UNCOMPRESSED_R32G32B32 PixelFormat = 9 PIXELFORMAT_UNCOMPRESSED_R32G32B32A32 PixelFormat = 10 PIXELFORMAT_UNCOMPRESSED_R16 PixelFormat = 11 PIXELFORMAT_UNCOMPRESSED_R16G16B16 PixelFormat = 12 PIXELFORMAT_UNCOMPRESSED_R16G16B16A16 PixelFormat = 13 PIXELFORMAT_COMPRESSED_DXT1_RGB PixelFormat = 14 PIXELFORMAT_COMPRESSED_DXT1_RGBA PixelFormat = 15 PIXELFORMAT_COMPRESSED_DXT3_RGBA PixelFormat = 16 PIXELFORMAT_COMPRESSED_DXT5_RGBA PixelFormat = 17 PIXELFORMAT_COMPRESSED_ETC1_RGB PixelFormat = 18 PIXELFORMAT_COMPRESSED_ETC2_RGB PixelFormat = 19 PIXELFORMAT_COMPRESSED_ETC2_EAC_RGBA PixelFormat = 20 PIXELFORMAT_COMPRESSED_PVRT_RGB PixelFormat = 21 PIXELFORMAT_COMPRESSED_PVRT_RGBA PixelFormat = 22 PIXELFORMAT_COMPRESSED_ASTC_4x4_RGBA PixelFormat = 23 // 2 bpp PIXELFORMAT_COMPRESSED_ASTC_8x8_RGBA PixelFormat = 24 )
type RAudioBuffer ¶
type RAudioBuffer struct {
}
type RAudioProcessor ¶
type RAudioProcessor struct {
}
type Ray ¶
Ray, ray for raycasting
func (Ray) CollisionBox ¶
func (self Ray) CollisionBox(box BoundingBox) RayCollision
Get collision info between ray and box
llgo:link Ray.CollisionBox C.GetRayCollisionBox
func (Ray) CollisionMesh ¶
func (self Ray) CollisionMesh(mesh Mesh, transform Matrix) RayCollision
Get collision info between ray and mesh
llgo:link Ray.CollisionMesh C.GetRayCollisionMesh
func (Ray) CollisionQuad ¶
Get collision info between ray and quad
llgo:link Ray.CollisionQuad C.GetRayCollisionQuad
func (Ray) CollisionSphere ¶
func (self Ray) CollisionSphere(center Vector3, radius c.Float) RayCollision
Get collision info between ray and sphere
llgo:link Ray.CollisionSphere C.GetRayCollisionSphere
func (Ray) CollisionTriangle ¶
func (self Ray) CollisionTriangle(p1 Vector3, p2 Vector3, p3 Vector3) RayCollision
Get collision info between ray and triangle
llgo:link Ray.CollisionTriangle C.GetRayCollisionTriangle
type RayCollision ¶
RayCollision, ray hit information
type Rectangle ¶
Rectangle, 4 components
func GetCollisionRec ¶
Get collision rectangle for two rectangles collision
func GetShapesTextureRectangle ¶
func GetShapesTextureRectangle() Rectangle
Get texture source rectangle that is used for shapes drawing
func (Rectangle) DrawRectangleGradientEx ¶
func (self Rectangle) DrawRectangleGradientEx(topLeft Color, bottomLeft Color, bottomRight Color, topRight Color)
Draw a gradient-filled rectangle with custom vertex colors
llgo:link Rectangle.DrawRectangleGradientEx C.DrawRectangleGradientEx
func (Rectangle) DrawRectangleLinesEx ¶
Draw rectangle outline with extended parameters
llgo:link Rectangle.DrawRectangleLinesEx C.DrawRectangleLinesEx
func (Rectangle) DrawRectanglePro ¶
Draw a color-filled rectangle with pro parameters
llgo:link Rectangle.DrawRectanglePro C.DrawRectanglePro
func (Rectangle) DrawRectangleRec ¶
Draw a color-filled rectangle
llgo:link Rectangle.DrawRectangleRec C.DrawRectangleRec
func (Rectangle) DrawRectangleRounded ¶
Draw rectangle with rounded edges
llgo:link Rectangle.DrawRectangleRounded C.DrawRectangleRounded
func (Rectangle) DrawRectangleRoundedLines ¶
Draw rectangle lines with rounded edges
llgo:link Rectangle.DrawRectangleRoundedLines C.DrawRectangleRoundedLines
type RenderTexture ¶
RenderTexture, fbo for texture rendering
type RenderTexture2D ¶
type RenderTexture2D = RenderTexture
RenderTexture2D, same as RenderTexture
func LoadRenderTexture ¶
func LoadRenderTexture(width c.Int, height c.Int) RenderTexture2D
Load texture for rendering (framebuffer)
func (RenderTexture2D) BeginTextureMode ¶
func (self RenderTexture2D) BeginTextureMode()
Begin drawing to render texture
llgo:link RenderTexture2D.BeginTextureMode C.BeginTextureMode
func (RenderTexture2D) IsRenderTextureValid ¶
func (self RenderTexture2D) IsRenderTextureValid() bool
Check if a render texture is valid (loaded in GPU)
llgo:link RenderTexture2D.IsRenderTextureValid C.IsRenderTextureValid
func (RenderTexture2D) UnloadRenderTexture ¶
func (self RenderTexture2D) UnloadRenderTexture()
Unload render texture from GPU memory (VRAM)
llgo:link RenderTexture2D.UnloadRenderTexture C.UnloadRenderTexture
type SaveFileDataCallback ¶
type SaveFileDataCallback = func(_llcppg_param1 *c.Char, _llcppg_param2 unsafe.Pointer, _llcppg_param3 c.Int) bool
FileIO: Save binary data
llgo:type C
type Shader ¶
Shader
func LoadShader ¶
Shader management functions NOTE: Shader functionality is not available on OpenGL 1.1
func LoadShaderFromMemory ¶
Load shader from code strings and bind default locations
func (Shader) BeginShaderMode ¶
func (self Shader) BeginShaderMode()
Begin custom shader drawing
llgo:link Shader.BeginShaderMode C.BeginShaderMode
func (Shader) IsShaderValid ¶
Check if a shader is valid (loaded on GPU)
llgo:link Shader.IsShaderValid C.IsShaderValid
func (Shader) LocationAttrib ¶
Get shader attribute location
llgo:link Shader.LocationAttrib C.GetShaderLocationAttrib
func (Shader) SetShaderValue ¶
Set shader uniform value
llgo:link Shader.SetShaderValue C.SetShaderValue
func (Shader) SetShaderValueMatrix ¶
Set shader uniform value (matrix 4x4)
llgo:link Shader.SetShaderValueMatrix C.SetShaderValueMatrix
func (Shader) SetShaderValueTexture ¶
Set shader uniform value and bind the texture (sampler2d)
llgo:link Shader.SetShaderValueTexture C.SetShaderValueTexture
type ShaderAttributeDataType ¶
Shader attribute data types
const ( SHADER_ATTRIB_FLOAT ShaderAttributeDataType = 0 SHADER_ATTRIB_VEC2 ShaderAttributeDataType = 1 SHADER_ATTRIB_VEC3 ShaderAttributeDataType = 2 // Shader attribute type: vec4 (4 float) SHADER_ATTRIB_VEC4 ShaderAttributeDataType = 3 )
type ShaderLocationIndex ¶
Shader location index NOTE: Some locations are tried to be set automatically on shader loading, but only if default attributes/uniforms names are found, check config.h for names
const ( SHADER_LOC_VERTEX_POSITION ShaderLocationIndex = 0 SHADER_LOC_VERTEX_TEXCOORD01 ShaderLocationIndex = 1 SHADER_LOC_VERTEX_TEXCOORD02 ShaderLocationIndex = 2 SHADER_LOC_VERTEX_NORMAL ShaderLocationIndex = 3 SHADER_LOC_VERTEX_TANGENT ShaderLocationIndex = 4 SHADER_LOC_VERTEX_COLOR ShaderLocationIndex = 5 SHADER_LOC_MATRIX_MVP ShaderLocationIndex = 6 SHADER_LOC_MATRIX_VIEW ShaderLocationIndex = 7 SHADER_LOC_MATRIX_PROJECTION ShaderLocationIndex = 8 SHADER_LOC_MATRIX_MODEL ShaderLocationIndex = 9 SHADER_LOC_MATRIX_NORMAL ShaderLocationIndex = 10 SHADER_LOC_VECTOR_VIEW ShaderLocationIndex = 11 SHADER_LOC_COLOR_DIFFUSE ShaderLocationIndex = 12 SHADER_LOC_COLOR_SPECULAR ShaderLocationIndex = 13 SHADER_LOC_COLOR_AMBIENT ShaderLocationIndex = 14 SHADER_LOC_MAP_ALBEDO ShaderLocationIndex = 15 SHADER_LOC_MAP_METALNESS ShaderLocationIndex = 16 SHADER_LOC_MAP_NORMAL ShaderLocationIndex = 17 SHADER_LOC_MAP_ROUGHNESS ShaderLocationIndex = 18 SHADER_LOC_MAP_OCCLUSION ShaderLocationIndex = 19 SHADER_LOC_MAP_EMISSION ShaderLocationIndex = 20 SHADER_LOC_MAP_HEIGHT ShaderLocationIndex = 21 SHADER_LOC_MAP_CUBEMAP ShaderLocationIndex = 22 SHADER_LOC_MAP_IRRADIANCE ShaderLocationIndex = 23 SHADER_LOC_MAP_PREFILTER ShaderLocationIndex = 24 SHADER_LOC_MAP_BRDF ShaderLocationIndex = 25 SHADER_LOC_VERTEX_BONEIDS ShaderLocationIndex = 26 SHADER_LOC_VERTEX_BONEWEIGHTS ShaderLocationIndex = 27 SHADER_LOC_MATRIX_BONETRANSFORMS ShaderLocationIndex = 28 // Shader location: vertex attribute: instance transforms SHADER_LOC_VERTEX_INSTANCETRANSFORM ShaderLocationIndex = 29 )
type ShaderUniformDataType ¶
Shader uniform data type
const ( SHADER_UNIFORM_FLOAT ShaderUniformDataType = 0 SHADER_UNIFORM_VEC2 ShaderUniformDataType = 1 SHADER_UNIFORM_VEC3 ShaderUniformDataType = 2 SHADER_UNIFORM_VEC4 ShaderUniformDataType = 3 SHADER_UNIFORM_INT ShaderUniformDataType = 4 SHADER_UNIFORM_IVEC2 ShaderUniformDataType = 5 SHADER_UNIFORM_IVEC3 ShaderUniformDataType = 6 SHADER_UNIFORM_IVEC4 ShaderUniformDataType = 7 SHADER_UNIFORM_UINT ShaderUniformDataType = 8 SHADER_UNIFORM_UIVEC2 ShaderUniformDataType = 9 SHADER_UNIFORM_UIVEC3 ShaderUniformDataType = 10 SHADER_UNIFORM_UIVEC4 ShaderUniformDataType = 11 // Shader uniform type: sampler2d SHADER_UNIFORM_SAMPLER2D ShaderUniformDataType = 12 )
type Sound ¶
type Sound struct {
Stream AudioStream
FrameCount c.Uint
}
Sound
func (Sound) IsSoundPlaying ¶
Check if a sound is currently playing
llgo:link Sound.IsSoundPlaying C.IsSoundPlaying
func (Sound) IsSoundValid ¶
Checks if a sound is valid (data loaded and buffers initialized)
llgo:link Sound.IsSoundValid C.IsSoundValid
func (Sound) LoadSoundAlias ¶
Create a new sound that shares the same sample data as the source sound, does not own the sound data
llgo:link Sound.LoadSoundAlias C.LoadSoundAlias
func (Sound) Play ¶
func (self Sound) Play()
Wave/Sound management functions
llgo:link Sound.Play C.PlaySound
func (Sound) Resume ¶
func (self Sound) Resume()
Resume a paused sound
llgo:link Sound.Resume C.ResumeSound
func (Sound) SetSoundPan ¶
Set pan for a sound (-1.0 left, 0.0 center, 1.0 right)
llgo:link Sound.SetSoundPan C.SetSoundPan
func (Sound) SetSoundPitch ¶
Set pitch for a sound (1.0 is base level)
llgo:link Sound.SetSoundPitch C.SetSoundPitch
func (Sound) SetSoundVolume ¶
Set volume for a sound (1.0 is max level)
llgo:link Sound.SetSoundVolume C.SetSoundVolume
func (Sound) UnloadSoundAlias ¶
func (self Sound) UnloadSoundAlias()
Unload a sound alias (does not deallocate sample data)
llgo:link Sound.UnloadSoundAlias C.UnloadSoundAlias
type Texture2D ¶
type Texture2D = Texture
Texture2D, same as Texture
func GetShapesTexture ¶
func GetShapesTexture() Texture2D
Get texture that is used for shapes drawing
func LoadTexture ¶
Texture loading functions NOTE: These functions require GPU access
func (Texture2D) DrawTexture ¶
Texture drawing functions
llgo:link Texture2D.DrawTexture C.DrawTexture
func (Texture2D) DrawTextureEx ¶
Draw a Texture2D with extended parameters
llgo:link Texture2D.DrawTextureEx C.DrawTextureEx
func (Texture2D) DrawTextureNPatch ¶
func (self Texture2D) DrawTextureNPatch(nPatchInfo NPatchInfo, dest Rectangle, origin Vector2, rotation c.Float, tint Color)
Draws a texture (or part of it) that stretches or shrinks nicely
llgo:link Texture2D.DrawTextureNPatch C.DrawTextureNPatch
func (Texture2D) DrawTexturePro ¶
func (self Texture2D) DrawTexturePro(source Rectangle, dest Rectangle, origin Vector2, rotation c.Float, tint Color)
Draw a part of a texture defined by a rectangle with 'pro' parameters
llgo:link Texture2D.DrawTexturePro C.DrawTexturePro
func (Texture2D) DrawTextureRec ¶
Draw a part of a texture defined by a rectangle
llgo:link Texture2D.DrawTextureRec C.DrawTextureRec
func (Texture2D) DrawTextureV ¶
Draw a Texture2D with position defined as Vector2
llgo:link Texture2D.DrawTextureV C.DrawTextureV
func (*Texture2D) GenTextureMipmaps ¶
func (self *Texture2D) GenTextureMipmaps()
Texture configuration functions
llgo:link (*Texture2D).GenTextureMipmaps C.GenTextureMipmaps
func (Texture2D) IsTextureValid ¶
Check if a texture is valid (loaded in GPU)
llgo:link Texture2D.IsTextureValid C.IsTextureValid
func (Texture2D) LoadImageFromTexture ¶
Load image from GPU texture data
llgo:link Texture2D.LoadImageFromTexture C.LoadImageFromTexture
func (Texture2D) SetShapesTexture ¶
------------------------------------------------------------------------------------ Basic Shapes Drawing Functions (Module: shapes) ------------------------------------------------------------------------------------ Set texture and rectangle to be used on shapes drawing NOTE: It can be useful when using basic shapes and one single font, defining a font char white rectangle would allow drawing everything in a single draw call
llgo:link Texture2D.SetShapesTexture C.SetShapesTexture
func (Texture2D) SetTextureFilter ¶
Set texture scaling filter mode
llgo:link Texture2D.SetTextureFilter C.SetTextureFilter
func (Texture2D) SetTextureWrap ¶
Set texture wrapping mode
llgo:link Texture2D.SetTextureWrap C.SetTextureWrap
func (Texture2D) UnloadTexture ¶
func (self Texture2D) UnloadTexture()
Unload texture from GPU memory (VRAM)
llgo:link Texture2D.UnloadTexture C.UnloadTexture
func (Texture2D) UpdateTexture ¶
Update GPU texture with new data (pixels should be able to fill texture)
llgo:link Texture2D.UpdateTexture C.UpdateTexture
type TextureFilter ¶
Texture parameters: filter mode NOTE 1: Filtering considers mipmaps if available in the texture NOTE 2: Filter is accordingly set for minification and magnification
const ( TEXTURE_FILTER_POINT TextureFilter = 0 TEXTURE_FILTER_BILINEAR TextureFilter = 1 TEXTURE_FILTER_TRILINEAR TextureFilter = 2 TEXTURE_FILTER_ANISOTROPIC_4X TextureFilter = 3 TEXTURE_FILTER_ANISOTROPIC_8X TextureFilter = 4 TEXTURE_FILTER_ANISOTROPIC_16X TextureFilter = 5 )
type TextureWrap ¶
Texture parameters: wrap mode
const ( TEXTURE_WRAP_REPEAT TextureWrap = 0 TEXTURE_WRAP_CLAMP TextureWrap = 1 TEXTURE_WRAP_MIRROR_REPEAT TextureWrap = 2 // Mirrors and clamps to border the texture in tiled mode TEXTURE_WRAP_MIRROR_CLAMP TextureWrap = 3 )
type TraceLogCallback ¶
Callbacks to hook some internal functions WARNING: These callbacks are intended for advanced users
llgo:type C
type TraceLogLevel ¶
Trace log level NOTE: Organized by priority level
const ( LOG_ALL TraceLogLevel = 0 LOG_TRACE TraceLogLevel = 1 LOG_DEBUG TraceLogLevel = 2 LOG_INFO TraceLogLevel = 3 LOG_WARNING TraceLogLevel = 4 LOG_ERROR TraceLogLevel = 5 LOG_FATAL TraceLogLevel = 6 // Disable logging LOG_NONE TraceLogLevel = 7 )
type Transform ¶
type Transform struct {
Translation Vector3
Rotation Quaternion
Scale Vector3
}
Transform, vertex transformation data
type Vector2 ¶
Vector2, 2 components
func GetMonitorPosition ¶
Get specified monitor position
func GetMouseWheelMoveV ¶
func GetMouseWheelMoveV() Vector2
Get mouse wheel movement for both X and Y
func GetTouchPosition ¶
Get touch position XY for a touch point index (relative to screen size)
func (Vector2) CheckCollisionCircleLine ¶
Check if circle collides with a line created betweeen two points [p1] and [p2]
llgo:link Vector2.CheckCollisionCircleLine C.CheckCollisionCircleLine
func (Vector2) CheckCollisionCircleRec ¶
Check collision between circle and rectangle
llgo:link Vector2.CheckCollisionCircleRec C.CheckCollisionCircleRec
func (Vector2) CheckCollisionCircles ¶
Check collision between two circles
llgo:link Vector2.CheckCollisionCircles C.CheckCollisionCircles
func (Vector2) CheckCollisionLines ¶
func (self Vector2) CheckCollisionLines(endPos1 Vector2, startPos2 Vector2, endPos2 Vector2, collisionPoint *Vector2) bool
Check the collision between two lines defined by two points each, returns collision point by reference
llgo:link Vector2.CheckCollisionLines C.CheckCollisionLines
func (Vector2) CheckCollisionPointCircle ¶
Check if point is inside circle
llgo:link Vector2.CheckCollisionPointCircle C.CheckCollisionPointCircle
func (Vector2) CheckCollisionPointLine ¶
Check if point belongs to line created between two points [p1] and [p2] with defined margin in pixels [threshold]
llgo:link Vector2.CheckCollisionPointLine C.CheckCollisionPointLine
func (Vector2) CheckCollisionPointPoly ¶
Check if point is within a polygon described by array of vertices
llgo:link Vector2.CheckCollisionPointPoly C.CheckCollisionPointPoly
func (Vector2) CheckCollisionPointRec ¶
Check if point is inside rectangle
llgo:link Vector2.CheckCollisionPointRec C.CheckCollisionPointRec
func (Vector2) CheckCollisionPointTriangle ¶
Check if point is inside a triangle
llgo:link Vector2.CheckCollisionPointTriangle C.CheckCollisionPointTriangle
func (Vector2) DrawCircleGradient ¶
Draw a gradient-filled circle
llgo:link Vector2.DrawCircleGradient C.DrawCircleGradient
func (Vector2) DrawCircleLinesV ¶
Draw circle outline (Vector version)
llgo:link Vector2.DrawCircleLinesV C.DrawCircleLinesV
func (Vector2) DrawCircleSector ¶
func (self Vector2) DrawCircleSector(radius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, color Color)
Draw a piece of a circle
llgo:link Vector2.DrawCircleSector C.DrawCircleSector
func (Vector2) DrawCircleSectorLines ¶
func (self Vector2) DrawCircleSectorLines(radius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, color Color)
Draw circle sector outline
llgo:link Vector2.DrawCircleSectorLines C.DrawCircleSectorLines
func (Vector2) DrawCircleV ¶
Draw a color-filled circle (Vector version)
llgo:link Vector2.DrawCircleV C.DrawCircleV
func (Vector2) DrawEllipseLinesV ¶
Draw ellipse outline (Vector version)
llgo:link Vector2.DrawEllipseLinesV C.DrawEllipseLinesV
func (Vector2) DrawEllipseV ¶
Draw ellipse (Vector version)
llgo:link Vector2.DrawEllipseV C.DrawEllipseV
func (Vector2) DrawLineBezier ¶
Draw line segment cubic-bezier in-out interpolation
llgo:link Vector2.DrawLineBezier C.DrawLineBezier
func (Vector2) DrawLineDashed ¶
Draw a dashed line
llgo:link Vector2.DrawLineDashed C.DrawLineDashed
func (Vector2) DrawLineEx ¶
Draw a line (using triangles/quads)
llgo:link Vector2.DrawLineEx C.DrawLineEx
func (*Vector2) DrawLineStrip ¶
Draw lines sequence (using gl lines)
llgo:link (*Vector2).DrawLineStrip C.DrawLineStrip
func (Vector2) DrawPixelV ¶
Draw a pixel using geometry (Vector version) [Can be slow, use with care]
llgo:link Vector2.DrawPixelV C.DrawPixelV
func (Vector2) DrawPoly ¶
Draw a regular polygon (Vector version)
llgo:link Vector2.DrawPoly C.DrawPoly
func (Vector2) DrawPolyLines ¶
Draw a polygon outline of n sides
llgo:link Vector2.DrawPolyLines C.DrawPolyLines
func (Vector2) DrawPolyLinesEx ¶
func (self Vector2) DrawPolyLinesEx(sides c.Int, radius c.Float, rotation c.Float, lineThick c.Float, color Color)
Draw a polygon outline of n sides with extended parameters
llgo:link Vector2.DrawPolyLinesEx C.DrawPolyLinesEx
func (Vector2) DrawRectangleV ¶
Draw a color-filled rectangle (Vector version)
llgo:link Vector2.DrawRectangleV C.DrawRectangleV
func (Vector2) DrawRing ¶
func (self Vector2) DrawRing(innerRadius c.Float, outerRadius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, color Color)
Draw ring
llgo:link Vector2.DrawRing C.DrawRing
func (Vector2) DrawRingLines ¶
func (self Vector2) DrawRingLines(innerRadius c.Float, outerRadius c.Float, startAngle c.Float, endAngle c.Float, segments c.Int, color Color)
Draw ring outline
llgo:link Vector2.DrawRingLines C.DrawRingLines
func (*Vector2) DrawSplineBasis ¶
Draw spline: B-Spline, minimum 4 points
llgo:link (*Vector2).DrawSplineBasis C.DrawSplineBasis
func (*Vector2) DrawSplineBezierCubic ¶
Draw spline: Cubic Bezier, minimum 4 points (2 control points): [p1, c2, c3, p4, c5, c6...]
llgo:link (*Vector2).DrawSplineBezierCubic C.DrawSplineBezierCubic
func (*Vector2) DrawSplineBezierQuadratic ¶
Draw spline: Quadratic Bezier, minimum 3 points (1 control point): [p1, c2, p3, c4...]
llgo:link (*Vector2).DrawSplineBezierQuadratic C.DrawSplineBezierQuadratic
func (*Vector2) DrawSplineCatmullRom ¶
Draw spline: Catmull-Rom, minimum 4 points
llgo:link (*Vector2).DrawSplineCatmullRom C.DrawSplineCatmullRom
func (*Vector2) DrawSplineLinear ¶
Splines drawing functions
llgo:link (*Vector2).DrawSplineLinear C.DrawSplineLinear
func (Vector2) DrawSplineSegmentBasis ¶
func (self Vector2) DrawSplineSegmentBasis(p2 Vector2, p3 Vector2, p4 Vector2, thick c.Float, color Color)
Draw spline segment: B-Spline, 4 points
llgo:link Vector2.DrawSplineSegmentBasis C.DrawSplineSegmentBasis
func (Vector2) DrawSplineSegmentBezierCubic ¶
func (self Vector2) DrawSplineSegmentBezierCubic(c2 Vector2, c3 Vector2, p4 Vector2, thick c.Float, color Color)
Draw spline segment: Cubic Bezier, 2 points, 2 control points
llgo:link Vector2.DrawSplineSegmentBezierCubic C.DrawSplineSegmentBezierCubic
func (Vector2) DrawSplineSegmentBezierQuadratic ¶
func (self Vector2) DrawSplineSegmentBezierQuadratic(c2 Vector2, p3 Vector2, thick c.Float, color Color)
Draw spline segment: Quadratic Bezier, 2 points, 1 control point
llgo:link Vector2.DrawSplineSegmentBezierQuadratic C.DrawSplineSegmentBezierQuadratic
func (Vector2) DrawSplineSegmentCatmullRom ¶
func (self Vector2) DrawSplineSegmentCatmullRom(p2 Vector2, p3 Vector2, p4 Vector2, thick c.Float, color Color)
Draw spline segment: Catmull-Rom, 4 points
llgo:link Vector2.DrawSplineSegmentCatmullRom C.DrawSplineSegmentCatmullRom
func (Vector2) DrawSplineSegmentLinear ¶
Draw spline segment: Linear, 2 points
llgo:link Vector2.DrawSplineSegmentLinear C.DrawSplineSegmentLinear
func (Vector2) DrawTriangle ¶
Draw a color-filled triangle (vertex in counter-clockwise order!)
llgo:link Vector2.DrawTriangle C.DrawTriangle
func (*Vector2) DrawTriangleFan ¶
Draw a triangle fan defined by points (first vertex is the center)
llgo:link (*Vector2).DrawTriangleFan C.DrawTriangleFan
func (Vector2) DrawTriangleLines ¶
Draw triangle outline (vertex in counter-clockwise order!)
llgo:link Vector2.DrawTriangleLines C.DrawTriangleLines
func (*Vector2) DrawTriangleStrip ¶
Draw a triangle strip defined by points
llgo:link (*Vector2).DrawTriangleStrip C.DrawTriangleStrip
func (Vector2) ScreenToWorld2D ¶
Get the world space position for a 2d camera screen space position
llgo:link Vector2.ScreenToWorld2D C.GetScreenToWorld2D
func (Vector2) ScreenToWorldRay ¶
Get a ray trace from screen position (i.e mouse)
llgo:link Vector2.ScreenToWorldRay C.GetScreenToWorldRay
func (Vector2) ScreenToWorldRayEx ¶
Get a ray trace from screen position (i.e mouse) in a viewport
llgo:link Vector2.ScreenToWorldRayEx C.GetScreenToWorldRayEx
func (Vector2) SplinePointBasis ¶
Get (evaluate) spline point: B-Spline
llgo:link Vector2.SplinePointBasis C.GetSplinePointBasis
func (Vector2) SplinePointBezierCubic ¶
Get (evaluate) spline point: Cubic Bezier
llgo:link Vector2.SplinePointBezierCubic C.GetSplinePointBezierCubic
func (Vector2) SplinePointBezierQuad ¶
Get (evaluate) spline point: Quadratic Bezier
llgo:link Vector2.SplinePointBezierQuad C.GetSplinePointBezierQuad
func (Vector2) SplinePointCatmullRom ¶
Get (evaluate) spline point: Catmull-Rom
llgo:link Vector2.SplinePointCatmullRom C.GetSplinePointCatmullRom
func (Vector2) SplinePointLinear ¶
Spline segment point evaluation functions, for a given t [0.0f .. 1.0f]
llgo:link Vector2.SplinePointLinear C.GetSplinePointLinear
func (Vector2) WorldToScreen2D ¶
Get the screen space position for a 2d camera world space position
llgo:link Vector2.WorldToScreen2D C.GetWorldToScreen2D
type Vector3 ¶
Vector3, 3 components
func (Vector3) CheckCollisionSpheres ¶
Collision detection functions
llgo:link Vector3.CheckCollisionSpheres C.CheckCollisionSpheres
func (Vector3) DrawCapsule ¶
func (self Vector3) DrawCapsule(endPos Vector3, radius c.Float, slices c.Int, rings c.Int, color Color)
Draw a capsule with the center of its sphere caps at startPos and endPos
llgo:link Vector3.DrawCapsule C.DrawCapsule
func (Vector3) DrawCapsuleWires ¶
func (self Vector3) DrawCapsuleWires(endPos Vector3, radius c.Float, slices c.Int, rings c.Int, color Color)
Draw capsule wireframe with the center of its sphere caps at startPos and endPos
llgo:link Vector3.DrawCapsuleWires C.DrawCapsuleWires
func (Vector3) DrawCircle3D ¶
func (self Vector3) DrawCircle3D(radius c.Float, rotationAxis Vector3, rotationAngle c.Float, color Color)
Draw a circle in 3D world space
llgo:link Vector3.DrawCircle3D C.DrawCircle3D
func (Vector3) DrawCubeWiresV ¶
Draw cube wires (Vector version)
llgo:link Vector3.DrawCubeWiresV C.DrawCubeWiresV
func (Vector3) DrawCylinder ¶
func (self Vector3) DrawCylinder(radiusTop c.Float, radiusBottom c.Float, height c.Float, slices c.Int, color Color)
Draw a cylinder/cone
llgo:link Vector3.DrawCylinder C.DrawCylinder
func (Vector3) DrawCylinderEx ¶
func (self Vector3) DrawCylinderEx(endPos Vector3, startRadius c.Float, endRadius c.Float, sides c.Int, color Color)
Draw a cylinder with base at startPos and top at endPos
llgo:link Vector3.DrawCylinderEx C.DrawCylinderEx
func (Vector3) DrawCylinderWires ¶
func (self Vector3) DrawCylinderWires(radiusTop c.Float, radiusBottom c.Float, height c.Float, slices c.Int, color Color)
Draw a cylinder/cone wires
llgo:link Vector3.DrawCylinderWires C.DrawCylinderWires
func (Vector3) DrawCylinderWiresEx ¶
func (self Vector3) DrawCylinderWiresEx(endPos Vector3, startRadius c.Float, endRadius c.Float, sides c.Int, color Color)
Draw a cylinder wires with base at startPos and top at endPos
llgo:link Vector3.DrawCylinderWiresEx C.DrawCylinderWiresEx
func (Vector3) DrawLine3D ¶
Basic geometric 3D shapes drawing functions
llgo:link Vector3.DrawLine3D C.DrawLine3D
func (Vector3) DrawPoint3D ¶
Draw a point in 3D space, actually a small line
llgo:link Vector3.DrawPoint3D C.DrawPoint3D
func (Vector3) DrawSphereEx ¶
Draw sphere with extended parameters
llgo:link Vector3.DrawSphereEx C.DrawSphereEx
func (Vector3) DrawSphereWires ¶
Draw sphere wires
llgo:link Vector3.DrawSphereWires C.DrawSphereWires
func (Vector3) DrawTriangle3D ¶
Draw a color-filled triangle (vertex in counter-clockwise order!)
llgo:link Vector3.DrawTriangle3D C.DrawTriangle3D
func (*Vector3) DrawTriangleStrip3D ¶
Draw a triangle strip defined by points
llgo:link (*Vector3).DrawTriangleStrip3D C.DrawTriangleStrip3D
func (Vector3) WorldToScreen ¶
Get the screen space position for a 3d world space position
llgo:link Vector3.WorldToScreen C.GetWorldToScreen
type Vector4 ¶
Vector4, 4 components
func (Vector4) ColorFromNormalized ¶
Get Color from normalized values [0..1]
llgo:link Vector4.ColorFromNormalized C.ColorFromNormalized
type VrDeviceInfo ¶
type VrDeviceInfo struct {
HResolution c.Int
VResolution c.Int
HScreenSize c.Float
VScreenSize c.Float
EyeToScreenDistance c.Float
LensSeparationDistance c.Float
InterpupillaryDistance c.Float
LensDistortionValues [4]c.Float
ChromaAbCorrection [4]c.Float
}
VrDeviceInfo, Head-Mounted-Display device parameters
func (VrDeviceInfo) LoadVrStereoConfig ¶
func (self VrDeviceInfo) LoadVrStereoConfig() VrStereoConfig
VR stereo config functions for VR simulator
llgo:link VrDeviceInfo.LoadVrStereoConfig C.LoadVrStereoConfig
type VrStereoConfig ¶
type VrStereoConfig struct {
Projection [2]Matrix
ViewOffset [2]Matrix
LeftLensCenter [2]c.Float
RightLensCenter [2]c.Float
LeftScreenCenter [2]c.Float
RightScreenCenter [2]c.Float
Scale [2]c.Float
ScaleIn [2]c.Float
}
VrStereoConfig, VR stereo rendering configuration for simulator
func (VrStereoConfig) BeginVrStereoMode ¶
func (self VrStereoConfig) BeginVrStereoMode()
Begin stereo rendering (requires VR simulator)
llgo:link VrStereoConfig.BeginVrStereoMode C.BeginVrStereoMode
func (VrStereoConfig) Unload ¶
func (self VrStereoConfig) Unload()
Unload VR stereo config
llgo:link VrStereoConfig.Unload C.UnloadVrStereoConfig
type Wave ¶
type Wave struct {
FrameCount c.Uint
SampleRate c.Uint
SampleSize c.Uint
Channels c.Uint
Data unsafe.Pointer
}
Wave, audio wave data
func LoadWaveFromMemory ¶
Load wave from memory buffer, fileType refers to extension: i.e. '.wav'
func (Wave) Export ¶
Export wave data to file, returns true on success
llgo:link Wave.Export C.ExportWave
func (Wave) ExportWaveAsCode ¶
Export wave sample data to code (.h), returns true on success
llgo:link Wave.ExportWaveAsCode C.ExportWaveAsCode
func (Wave) IsWaveValid ¶
Checks if wave data is valid (data loaded and parameters)
llgo:link Wave.IsWaveValid C.IsWaveValid
func (Wave) LoadSoundFrom ¶
Load sound from wave data
llgo:link Wave.LoadSoundFrom C.LoadSoundFromWave
func (Wave) LoadWaveSamples ¶
Load samples data from wave as a 32bit float data array
llgo:link Wave.LoadWaveSamples C.LoadWaveSamples