Beispiel #1
0
func main() {
	glut.InitDisplayMode(glut.SINGLE | glut.RGB)
	glut.InitWindowSize(465, 250)
	glut.CreateWindow("GLUT bitmap & stroke font example")
	gl.ClearColor(1.0, 1.0, 1.0, 1.0)
	gl.Color3f(0, 0, 0)
	gl.LineWidth(3.0)
	glut.DisplayFunc(display)
	glut.ReshapeFunc(reshape)
	glut.MainLoop()
}
Beispiel #2
0
func main() {
	glut.CreateWindow("Triangle Demo")
	t.units = list.New()
	e := Entity{[...]float32{1, 0, 0, 1},
		[...]float32{0, 0},
		"test",
		t.units}
	t.units.PushBack(&e)
	t.main_unit = &e
	initWindow()
	glut.MainLoop()
}
Beispiel #3
0
func main() {
	glut.InitDisplayMode(glut.DOUBLE | glut.RGB)

	// FIXME: gamemode causes crash
	//if (argc > 1 && !strcmp(argv[1], "-fullscreen")) {
	//glut.GameModeString("800x600:32@60")
	//glut.EnterGameMode()
	// } else {
	originalWindow = glut.CreateWindow("asteroids")
	//}

	initWindow()

	glut.MainLoop()

}
Beispiel #4
0
func main() {
	glut.CreateWindow("single triangle")
	glut.DisplayFunc(display)
	glut.ReshapeFunc(reshape)
	glut.MainLoop()
}