[stale since 2013] lib for creating OpenGL apps of the cross-platform and modern sort (ie. Core profile 3.3+, shader-based, no display lists etc)
Go
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
cmd
core
util
README.md

README.md

go-opengl

Go packages for working with OpenGL. While more or less adequate for general use, they're being developed in conjunction with go:ngine and thus tend to be slightly tweaked, optimized or designed around go:ngine's needs and usage patterns.

core:

A (very) GoGL-like OpenGL binding used by go:ngine.

  • includes strictly only GL core profile functionality from version 3.3 onwards (up until 4.3) -- note, this does not mean that a core profile context is required, although it is probably advisable on any current-gen GPU with recent drivers
  • no compatibility-profile-only functionality or any that was deprecated or removed at some (any) point
  • Init() and "stolen-from-GoGL" utility functions moved to a Util struct: so every exported (non-method) function is a direct CGO binding function. (Just minor cosmetics really.)
  • added to Util: ErrorFlags() method
  • embeds the following GL extensions right inside the same binding package:

util:

Based on the above core GL binding package, provides higher-level utility constructs and a few sane lean minimalist wrappers (without going full-on "OO"-overboard).

cmd:

  • opengl-minimal-app: a "minimal" program using OpenGL core profile to draw a triangle and a quad, to test the above core GL binding package with GLFW
  • gogl-minimal-app: same but with the GoGL (gl43) binding
  • gen-opengl-bindings: used to generate the above core GL binding package