Exemplo n.º 1
0
func Text(x, y, z float32, str string) {
	gl.BlendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA)
	gl.Enable(gl.BLEND)

	gl.RasterPos3f(x, y, z)
	for _, ch := range str {
		//glut.BitmapCharacter(glut.BITMAP_9_BY_15, string(ch))
	}

	gl.Disable(gl.BLEND)
}
Exemplo n.º 2
0
func Number(x, y, z, n float32) {
	gl.BlendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA)
	gl.Enable(gl.BLEND)

	s := ""
	fmt.Fprintf(s, "%f", n)
	gl.RasterPos3f(x, y, z)
	for _, ch := range s {
		//glut.BitmapCharacter(glut.BITMAP_9_BY_15, string(ch))
	}

	gl.Disable(gl.BLEND)
}