132 lines
7.4 KiB
Plaintext
132 lines
7.4 KiB
Plaintext
#ifndef GLFW_FUNCTION_TABLE_H
|
|
#define GLFW_FUNCTION_TABLE_H
|
|
|
|
#include "../glfw/glfw3.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef struct GLFWFunctionTable {
|
|
int (*glfwInit)(void);
|
|
void (*glfwTerminate)(void);
|
|
void (*glfwInitHint)(int hint, int value);
|
|
void (*glfwGetVersion)(int* major, int* minor, int* rev);
|
|
const char* (*glfwGetVersionString)(void);
|
|
int (*glfwGetError)(const char** description);
|
|
void* (*glfwSetErrorCallback)(void* callback);
|
|
GLFWmonitor** (*glfwGetMonitors)(int* count);
|
|
GLFWmonitor* (*glfwGetPrimaryMonitor)(void);
|
|
void (*glfwGetMonitorPos)(GLFWmonitor* monitor, int* xpos, int* ypos);
|
|
void (*glfwGetMonitorWorkarea)(GLFWmonitor* monitor, int* xpos, int* ypos, int* width, int* height);
|
|
void (*glfwGetMonitorPhysicalSize)(GLFWmonitor* monitor, int* widthMM, int* heightMM);
|
|
void (*glfwGetMonitorContentScale)(GLFWmonitor* monitor, float* xscale, float* yscale);
|
|
const char* (*glfwGetMonitorName)(GLFWmonitor* monitor);
|
|
void glfwSetMonitorUserPointer(GLFWmonitor* monitor, void* pointer);
|
|
void* glfwGetMonitorUserPointer(GLFWmonitor* monitor);
|
|
void* (*glfwSetMonitorCallback)(void* callback);
|
|
const GLFWvidmode* (*glfwGetVideoModes)(GLFWmonitor* monitor, int* count);
|
|
const GLFWvidmode* (*glfwGetVideoMode)(GLFWmonitor* monitor);
|
|
void (*glfwSetGamma)(GLFWmonitor* monitor, float gamma);
|
|
const GLFWgammaramp* (*glfwGetGammaRamp)(GLFWmonitor* monitor);
|
|
void (*glfwSetGammaRamp)(GLFWmonitor* monitor, const GLFWgammaramp* ramp);
|
|
void (*glfwDefaultWindowHints)(void);
|
|
void (*glfwWindowHint)(int hint, int value);
|
|
void (*glfwWindowHintString)(int hint, const char* value);
|
|
GLFWwindow* (*glfwCreateWindow)(int width, int height, const char* title, GLFWmonitor* monitor, GLFWwindow* share);
|
|
void (*glfwDestroyWindow)(GLFWwindow* window);
|
|
int (*glfwWindowShouldClose)(GLFWwindow* window);
|
|
void (*glfwSetWindowShouldClose)(GLFWwindow* window, int value);
|
|
void (*glfwSetWindowTitle)(GLFWwindow* window, const char* title);
|
|
void (*glfwSetWindowIcon)(GLFWwindow* window, int count, const GLFWimage* images);
|
|
void (*glfwGetWindowPos)(GLFWwindow* window, int* xpos, int* ypos);
|
|
void (*glfwSetWindowPos)(GLFWwindow* window, int xpos, int ypos);
|
|
void (*glfwGetWindowSize)(GLFWwindow* window, int* width, int* height);
|
|
void (*glfwSetWindowSizeLimits)(GLFWwindow* window, int minwidth, int minheight, int maxwidth, int maxheight);
|
|
void (*glfwSetWindowAspectRatio)(GLFWwindow* window, int numer, int denom);
|
|
void (*glfwSetWindowSize)(GLFWwindow* window, int width, int height);
|
|
void (*glfwGetFramebufferSize)(GLFWwindow* window, int* width, int* height);
|
|
void (*glfwGetWindowFrameSize)(GLFWwindow* window, int* left, int* top, int* right, int* bottom);
|
|
void (*glfwGetWindowContentScale)(GLFWwindow* window, float* xscale, float* yscale);
|
|
float (*glfwGetWindowOpacity)(GLFWwindow* window);
|
|
void (*glfwSetWindowOpacity)(GLFWwindow* window, float opacity);
|
|
void (*glfwIconifyWindow)(GLFWwindow* window);
|
|
void (*glfwRestoreWindow)(GLFWwindow* window);
|
|
void (*glfwMaximizeWindow)(GLFWwindow* window);
|
|
void (*glfwShowWindow)(GLFWwindow* window);
|
|
void (*glfwHideWindow)(GLFWwindow* window);
|
|
void (*glfwFocusWindow)(GLFWwindow* window);
|
|
void (*glfwRequestWindowAttention)(GLFWwindow* window);
|
|
GLFWmonitor* (*glfwGetWindowMonitor)(GLFWwindow* window);
|
|
void (*glfwSetWindowMonitor)(GLFWwindow* window, GLFWmonitor* monitor, int xpos, int ypos, int width, int height, int refreshRate);
|
|
int (*glfwGetWindowAttrib)(GLFWwindow* window, int attrib);
|
|
void (*glfwSetWindowAttrib)(GLFWwindow* window, int attrib, int value);
|
|
void (*glfwSetWindowUserPointer)(GLFWwindow* window, void* pointer);
|
|
void* (*glfwGetWindowUserPointer)(GLFWwindow* window);
|
|
void* (*glfwSetWindowPosCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowSizeCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowCloseCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowRefreshCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowFocusCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowIconifyCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowMaximizeCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetFramebufferSizeCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetWindowContentScaleCallback)(GLFWwindow* window, void* callback);
|
|
void (*glfwPollEvents)(void);
|
|
void (*glfwWaitEvents)(void);
|
|
void (*glfwWaitEventsTimeout)(double timeout);
|
|
void (*glfwPostEmptyEvent)(void);
|
|
int (*glfwGetInputMode)(GLFWwindow* window, int mode);
|
|
void (*glfwSetInputMode)(GLFWwindow* window, int mode, int value);
|
|
int (*glfwRawMouseMotionSupported)(void);
|
|
const char* (*glfwGetKeyName)(int key, int scancode);
|
|
int (*glfwGetKeyScancode)(int key);
|
|
int (*glfwGetKey)(GLFWwindow* window, int key);
|
|
int (*glfwGetMouseButton)(GLFWwindow* window, int button);
|
|
void (*glfwGetCursorPos)(GLFWwindow* window, double* xpos, double* ypos);
|
|
void (*glfwSetCursorPos)(GLFWwindow* window, double xpos, double ypos);
|
|
GLFWcursor* (*glfwCreateCursor)(const GLFWimage* image, int xhot, int yhot);
|
|
GLFWcursor* (*glfwCreateStandardCursor)(int shape);
|
|
void (*glfwDestroyCursor)(GLFWcursor* cursor);
|
|
void (*glfwSetCursor)(GLFWwindow* window, GLFWcursor* cursor);
|
|
void* (*glfwSetKeyCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetCharCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetCharModsCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetMouseButtonCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetCursorPosCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetCursorEnterCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetScrollCallback)(GLFWwindow* window, void* callback);
|
|
void* (*glfwSetDropCallback)(GLFWwindow* window, void* callback);
|
|
int (*glfwJoystickPresent)(int jid);
|
|
const float* (*glfwGetJoystickAxes)(int jid, int* count);
|
|
const unsigned char* (*glfwGetJoystickButtons)(int jid, int* count);
|
|
const char* (*glfwGetJoystickGUID)(int jid);
|
|
const unsigned char* (*glfwGetJoystickHats)(int jid, int* count);
|
|
const char* (*glfwGetJoystickName)(int jid);
|
|
void* (*glfwGetJoystickUserPointer)(int jid);
|
|
int (*glfwJoystickIsGamepad)(int jid);
|
|
void* (*glfwSetJoystickCallback)(void* callback);
|
|
int (*glfwUpdateGamepadMappings)(const char* str);
|
|
const char* (*glfwGetGamepadName)(int jid);
|
|
int (*glfwGetGamepadState)(int jid, GLFWgamepadstate* state);
|
|
void (*glfwSetClipboardString)(GLFWwindow* window, const char* str);
|
|
const char* (*glfwGetClipboardString)(GLFWwindow* window);
|
|
double (*glfwGetTime)(void);
|
|
void (*glfwSetTime)(double time);
|
|
unsigned long long (*glfwGetTimerValue)(void);
|
|
unsigned long long (*glfwGetTimerFrequency)(void);
|
|
void (*glfwMakeContextCurrent)(GLFWwindow* window);
|
|
GLFWwindow* (*glfwGetCurrentContext)(void);
|
|
void (*glfwSwapBuffers)(GLFWwindow* window);
|
|
void (*glfwSwapInterval)(int interval);
|
|
int (*glfwExtensionSupported)(const char* extension);
|
|
void* (*glfwGetProcAddress)(const char* procname);
|
|
int (*glfwVulkanSupported)(void);
|
|
const char** (*glfwGetRequiredInstanceExtensions)(unsigned int* count);
|
|
} GLFWFunctionTable;
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif |