Home

Awesome

Beef OpenGL Header Generator

A Generator for OpenGL headers for the Beef Programming language, Version 1.6.0

Features:

Compiling:

Windows:

In cmd, run: gradlew.bat jar

Unix and Unix-like:

In your shell, run: ./gradlew jar

In both cases, the jar will be in build/libs/

Running:

For a list of available options, run java -jar Beef-OpenGL-Header-Generator-{version}.jar --help Options are Unix-style with the support of chaining multiple short options together

Using the Header:

Initializing:

Using is as easy as simply first creating an openGL context and then calling OpenGL.Init() with a function resolving function pointers from System.StringView, e.g.

with SDL

static void* SdlGetProcAddress(StringView string) {
    return SDL.SDL_GL_GetProcAddress(string.ToScopeCStr!());
}

SDL.GL_CreateContext(window);
GL.Init(=> SdlGetProcAddress);

with glfw-beef

Glfw.MakeContextCurrent(window);
OpenGL.Init(=> Glfw.GetProcAddress);

Things to note