mirror of
https://github.com/glfw/glfw.git
synced 2026-08-27 19:55:53 +02:00
Merge branch 'master' into cursor-enter-leave
This commit is contained in:
@@ -136,10 +136,6 @@ extern "C" {
|
||||
|
||||
/* -------------------- END SYSTEM/COMPILER SPECIFIC --------------------- */
|
||||
|
||||
/* Include the declaration of the size_t type used below.
|
||||
*/
|
||||
#include <stddef.h>
|
||||
|
||||
/* Include standard OpenGL headers: GLFW uses GL_FALSE/GL_TRUE, and it is
|
||||
* convenient for the user to only have to include <GL/glfw.h>. This also
|
||||
* solves the problem with Windows <GL/gl.h> and <GL/glu.h> needing some
|
||||
@@ -427,13 +423,14 @@ extern "C" {
|
||||
#define GLFW_OPENGL_COMPAT_PROFILE 0x00000002
|
||||
#define GLFW_OPENGL_ES2_PROFILE 0x00000004
|
||||
|
||||
/* glfwEnable/glfwDisable tokens */
|
||||
/* glfwGetInputMode/glfwSetInputMode tokens */
|
||||
#define GLFW_CURSOR_MODE 0x00030001
|
||||
#define GLFW_STICKY_KEYS 0x00030002
|
||||
#define GLFW_STICKY_MOUSE_BUTTONS 0x00030003
|
||||
#define GLFW_SYSTEM_KEYS 0x00030004
|
||||
#define GLFW_KEY_REPEAT 0x00030005
|
||||
|
||||
/* glfwSetCursorMode tokens */
|
||||
/* GLFW_CURSOR_MODE values */
|
||||
#define GLFW_CURSOR_NORMAL 0x00040001
|
||||
#define GLFW_CURSOR_HIDDEN 0x00040002
|
||||
#define GLFW_CURSOR_CAPTURED 0x00040003
|
||||
@@ -478,8 +475,6 @@ typedef void (* GLFWcursorenterfun)(GLFWwindow,int);
|
||||
typedef void (* GLFWscrollfun)(GLFWwindow,int,int);
|
||||
typedef void (* GLFWkeyfun)(GLFWwindow,int,int);
|
||||
typedef void (* GLFWcharfun)(GLFWwindow,int);
|
||||
typedef void* (* GLFWmallocfun)(size_t);
|
||||
typedef void (* GLFWfreefun)(void*);
|
||||
|
||||
/* The video mode structure used by glfwGetVideoModes */
|
||||
typedef struct
|
||||
@@ -499,19 +494,6 @@ typedef struct
|
||||
unsigned short blue[GLFW_GAMMA_RAMP_SIZE];
|
||||
} GLFWgammaramp;
|
||||
|
||||
/* Custom memory allocator interface */
|
||||
typedef struct
|
||||
{
|
||||
GLFWmallocfun malloc;
|
||||
GLFWfreefun free;
|
||||
} GLFWallocator;
|
||||
|
||||
/* Custom threading model interface */
|
||||
typedef struct
|
||||
{
|
||||
int dummy;
|
||||
} GLFWthreadmodel;
|
||||
|
||||
|
||||
/*************************************************************************
|
||||
* Prototypes
|
||||
@@ -519,7 +501,6 @@ typedef struct
|
||||
|
||||
/* Initialization, termination and version querying */
|
||||
GLFWAPI int glfwInit(void);
|
||||
GLFWAPI int glfwInitWithModels(GLFWthreadmodel* threading, GLFWallocator* allocator);
|
||||
GLFWAPI void glfwTerminate(void);
|
||||
GLFWAPI void glfwGetVersion(int* major, int* minor, int* rev);
|
||||
GLFWAPI const char* glfwGetVersionString(void);
|
||||
@@ -564,11 +545,12 @@ GLFWAPI void glfwPollEvents(void);
|
||||
GLFWAPI void glfwWaitEvents(void);
|
||||
|
||||
/* Input handling */
|
||||
GLFWAPI int glfwGetInputMode(GLFWwindow window, int mode);
|
||||
GLFWAPI void glfwSetInputMode(GLFWwindow window, int mode, int value);
|
||||
GLFWAPI int glfwGetKey(GLFWwindow window, int key);
|
||||
GLFWAPI int glfwGetMouseButton(GLFWwindow window, int button);
|
||||
GLFWAPI void glfwGetMousePos(GLFWwindow window, int* xpos, int* ypos);
|
||||
GLFWAPI void glfwSetMousePos(GLFWwindow window, int xpos, int ypos);
|
||||
GLFWAPI void glfwSetCursorMode(GLFWwindow window, int mode);
|
||||
GLFWAPI void glfwGetScrollOffset(GLFWwindow window, int* xoffset, int* yoffset);
|
||||
GLFWAPI void glfwSetKeyCallback(GLFWkeyfun cbfun);
|
||||
GLFWAPI void glfwSetCharCallback(GLFWcharfun cbfun);
|
||||
@@ -595,10 +577,6 @@ GLFWAPI int glfwExtensionSupported(const char* extension);
|
||||
GLFWAPI void* glfwGetProcAddress(const char* procname);
|
||||
GLFWAPI void glfwCopyContext(GLFWwindow src, GLFWwindow dst, unsigned long mask);
|
||||
|
||||
/* Enable/disable functions */
|
||||
GLFWAPI void glfwEnable(GLFWwindow window, int token);
|
||||
GLFWAPI void glfwDisable(GLFWwindow window, int token);
|
||||
|
||||
|
||||
/*************************************************************************
|
||||
* Global definition cleanup
|
||||
|
||||
Reference in New Issue
Block a user