Go bindings for raylib, a simple and easy-to-use library to enjoy videogames programming.
Find a file
2017-02-11 20:32:56 +02:00
easings Golint 2017-02-01 01:50:51 +01:00
examples Update C sources, add new functions 2017-02-10 11:28:19 +01:00
physics Initial commit 2017-01-27 09:35:30 +01:00
raygui Improve GUI on Android, add OpenAsset function 2017-02-02 02:05:14 +01:00
raylib Fix compiling on Windows with MSYS2 2017-02-11 20:32:56 +02:00
raymath Some typos 2017-01-29 01:35:01 +01:00
.travis.yml Fix travis 2017-02-01 16:14:13 +01:00
LICENSE Initial commit 2017-01-27 09:35:30 +01:00
Makefile Travis add X libraries 2017-01-31 20:51:01 +01:00
README.md Update README.md 2017-02-01 01:55:34 +01:00

raylib-go Build Status GoDoc Go Report Card

Golang bindings for raylib, a simple and easy-to-use library to learn videogames programming.

screenshot

Requirements

  • GLFW3 (desktop platform only, not needed on Android and RPi)
  • OpenAL Soft (on OS X system framework is used)

GLFW version 3.2 is required.

Ubuntu
apt-get install libglfw3-dev libopenal-dev libxi-dev libxinerama-dev libxcursor-dev libxxf86vm-dev

On older Ubuntu releases you will need to compile GLFW, instructions are in travis file.

Fedora
dnf install glfw-devel openal-soft-devel mesa-libGL-devel libXi-devel
OS X
brew install glfw3
Windows (MSYS2)
pacman -S mingw-w64-x86_64-openal mingw-w64-x86_64-glfw mingw-w64-x86_64-gcc mingw-w64-x86_64-go git 
Android

Android example.

Installation

go get -v github.com/gen2brain/raylib-go/raylib

Example

package main

import "github.com/gen2brain/raylib-go/raylib"

func main() {
	raylib.InitWindow(800, 450, "raylib [core] example - basic window")

	raylib.SetTargetFPS(60)

	for !raylib.WindowShouldClose() {
		raylib.BeginDrawing()

		raylib.ClearBackground(raylib.RayWhite)

		raylib.DrawText("Congrats! You created your first window!", 190, 200, 20, raylib.LightGray)

		raylib.EndDrawing()
	}

	raylib.CloseWindow()
}

Check more examples organized by raylib modules.

License

raylib-go is licensed under an unmodified zlib/libpng license. View LICENSE.