From 9a9a714da301f2158b6f0de5f6f2a490fc7ab3b1 Mon Sep 17 00:00:00 2001 From: Bobby Dilley Date: Mon, 2 Jan 2023 23:14:20 +0000 Subject: [PATCH] make afterburner work --- src/lindbergh/graphics.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/src/lindbergh/graphics.c b/src/lindbergh/graphics.c index c5cef5a..d8bb015 100644 --- a/src/lindbergh/graphics.c +++ b/src/lindbergh/graphics.c @@ -242,3 +242,33 @@ Bool XF86VidModeSwitchToMode(Display *display, int screen, XF86VidModeModeInfo * { return 0; } + +typedef unsigned int uint; + +int glXSwapIntervalSGI(int interval) { + return 0; +} + +int glXGetVideoSyncSGI(uint *count) { + static unsigned int frameCount = 0; + //TODO: Framecount should depend on current system time + *count = (frameCount++)/2; // NOTE: Keeps the same frame for 2 calls + return 0; +} + +int glXGetRefreshRateSGI(unsigned int * rate) { //TODO: need an actual prototype + *rate = 60; //TODO: what does this function return? + return 0; +} + +void glGenFencesNV(int n, uint *fences) { + static unsigned int curf = 1; + while(n--) { + *fences++ = curf++; + } + return; +} + +void glDeleteFencesNV(int a, const uint *b) { + return; +} \ No newline at end of file