Entropie git · main
Entropie festival game; first steps
C 88.5% Markdown 9.1% GLSL 2.3%git clone https://git.christianimmanuel.de/games/Entropie.gitwget https://git.christianimmanuel.de/games/Entropie/archive/Entropie.tar.gzentropie/src/core/gl.c raw
#include "core/gl.h"
#include <SDL3/SDL.h>
#define GL_DEFINE_FN(type, name) type name = NULL;
GL_FUNCTION_LIST(GL_DEFINE_FN)
#undef GL_DEFINE_FN
bool Gl_load(void) {
bool ok = true;
#define GL_LOAD_FN(type, name) \
name = (type)SDL_GL_GetProcAddress(#name); \
if (!name) { \
SDL_Log("OpenGL function missing: %s", #name); \
ok = false; \
}
GL_FUNCTION_LIST(GL_LOAD_FN)
#undef GL_LOAD_FN
return ok;
}