Skip to content

Instantly share code, notes, and snippets.

View jrenner's full-sized avatar

Jon Renner jrenner

  • Minneapolis, Minnesota, USA
View GitHub Profile
@allj
allj / triangle.nim
Last active April 23, 2017 19:53
A colorful triangle in nim OpenGL.
import os
import opengl
import glfw/wrapper as glfw
template `&`[T](v: var T): ptr[T] = addr(v)
template `*`[T](v: ptr[T]): T = v[]
template `*`[T](v: ref[T]): T = v[]