func DrawBox(pos, size mgl64.Vec2, borderColor, backgroundColor mgl64.Vec3) { DrawBorderlessBox(pos.Add(mgl64.Vec2{-1, -1}), size.Add(mgl64.Vec2{2, 2}), borderColor) DrawBorderlessBox(pos, size, backgroundColor) }
func (o *OpenGlStream) SetPosWithExpandedPosition(pos mgl64.Vec2, x, y uint32) { o.pos = pos.Add(mgl64.Vec2{float64(x * fontWidth), float64(y * fontHeight)}) o.lineStartX = pos[0] o.advance = x }
func DrawBorderlessBox(pos, size mgl64.Vec2, backgroundColor mgl64.Vec3) { gl.Color3dv(&backgroundColor[0]) gl.Rectd(float64(pos[0]), float64(pos[1]), float64(pos.Add(size)[0]), float64(pos.Add(size)[1])) }