mirror of
https://github.com/glfw/glfw.git
synced 2024-11-14 10:34:34 +00:00
Formatted public header, removed per-token docs.
Some tokens are used for more than one purpose, making it difficult to write good documentation on the token itself. These tokens should instead be described in the documentation for each function or callback that uses them.
This commit is contained in:
parent
38aef53b0c
commit
2fca5c5df1
@ -203,7 +203,7 @@ extern "C" {
|
|||||||
|
|
||||||
|
|
||||||
/*************************************************************************
|
/*************************************************************************
|
||||||
* GLFW version
|
* GLFW API tokens
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*! @name GLFW version macros
|
/*! @name GLFW version macros
|
||||||
@ -230,11 +230,6 @@ extern "C" {
|
|||||||
#define GLFW_VERSION_REVISION 0
|
#define GLFW_VERSION_REVISION 0
|
||||||
/*! @} */
|
/*! @} */
|
||||||
|
|
||||||
|
|
||||||
/*************************************************************************
|
|
||||||
* Input handling definitions
|
|
||||||
*************************************************************************/
|
|
||||||
|
|
||||||
/*! @name Key and button actions
|
/*! @name Key and button actions
|
||||||
* @{ */
|
* @{ */
|
||||||
/*! @brief The key or button was released.
|
/*! @brief The key or button was released.
|
||||||
@ -449,234 +444,6 @@ extern "C" {
|
|||||||
#define GLFW_JOYSTICK_LAST GLFW_JOYSTICK_16
|
#define GLFW_JOYSTICK_LAST GLFW_JOYSTICK_16
|
||||||
/*! @} */
|
/*! @} */
|
||||||
|
|
||||||
|
|
||||||
/*************************************************************************
|
|
||||||
* Other definitions
|
|
||||||
*************************************************************************/
|
|
||||||
|
|
||||||
/*! @defgroup paramhints Window parameters and hints
|
|
||||||
* @ingroup window
|
|
||||||
* @{ */
|
|
||||||
|
|
||||||
/*! @brief @c GL_TRUE if the window has focus, or @c GL_FALSE otherwise.
|
|
||||||
* @see glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_FOCUSED 0x00020001
|
|
||||||
/*! @brief @c GL_TRUE if the window is iconified, or @c GL_FALSE otherwise.
|
|
||||||
* @see glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_ICONIFIED 0x00020002
|
|
||||||
/*! @brief @c GL_TRUE if the window has been requested to close, or @c GL_FALSE
|
|
||||||
* otherwise.
|
|
||||||
* @see glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_SHOULD_CLOSE 0x00020003
|
|
||||||
/*! @brief The revision number of the context's API version.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_CONTEXT_REVISION 0x00020004
|
|
||||||
|
|
||||||
/*! @brief The bit depth of the red component of the color buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_RED_BITS 0x00021000
|
|
||||||
/*! @brief The bit depth of the green component of the color buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_GREEN_BITS 0x00021001
|
|
||||||
/*! @brief The bit depth of the blue component of the color buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_BLUE_BITS 0x00021002
|
|
||||||
/*! @brief The bit depth of the alpha component of the color buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_ALPHA_BITS 0x00021003
|
|
||||||
/*! @brief The bit depth of the depth buffer of the default framebuffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_DEPTH_BITS 0x00021004
|
|
||||||
/*! @brief The bit depth of the stencil buffer of the default framebuffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_STENCIL_BITS 0x00021005
|
|
||||||
/*! @brief The bit depth of the red component of the accumulation buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_ACCUM_RED_BITS 0x00021006
|
|
||||||
/*! @brief The bit depth of the red component of the accumulation buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_ACCUM_GREEN_BITS 0x00021007
|
|
||||||
/*! @brief The bit depth of the red component of the accumulation buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_ACCUM_BLUE_BITS 0x00021008
|
|
||||||
/*! @brief The bit depth of the red component of the accumulation buffer.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_ACCUM_ALPHA_BITS 0x00021009
|
|
||||||
/*! @brief The number of auxiliary buffers.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_AUX_BUFFERS 0x0002100A
|
|
||||||
/*! @brief @c GL_TRUE for stereo rendering, or @c GL_FALSE otherwise.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_STEREO 0x0002100B
|
|
||||||
/*! @brief The number of samples used for default framebuffer multisampling, or
|
|
||||||
* zero to disable multisampling.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_SAMPLES 0x0002100C
|
|
||||||
/*! @brief @c GL_TRUE if the framebuffer should be sRGB capable, or @c GL_FALSE
|
|
||||||
* otherwise.
|
|
||||||
* @see glfwWindowHint
|
|
||||||
*/
|
|
||||||
#define GLFW_SRGB_CAPABLE 0x0002100D
|
|
||||||
|
|
||||||
/*! @brief The client API used for the window's context; one of
|
|
||||||
* @ref One of GLFW_OPENGL_API or @ref GLFW_OPENGL_ES_API.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_CLIENT_API 0x00022000
|
|
||||||
/*! @brief The major number of the context's API version.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_CONTEXT_VERSION_MAJOR 0x00022001
|
|
||||||
/*! @brief The minor number of the context's API version.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_CONTEXT_VERSION_MINOR 0x00022002
|
|
||||||
/*! @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_CONTEXT_ROBUSTNESS 0x00022003
|
|
||||||
/*! @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_FORWARD_COMPAT 0x00022004
|
|
||||||
/*! @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_DEBUG_CONTEXT 0x00022005
|
|
||||||
/*! @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_PROFILE 0x00022006
|
|
||||||
/*! @brief @c GL_TRUE if the window is resizable, or @c GL_FALSE otherwise.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_RESIZABLE 0x00022007
|
|
||||||
/*! @brief @c GL_TRUE if the window is visible, or @c GL_FALSE otherwise.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_VISIBLE 0x00022008
|
|
||||||
/*! @brief The x-coordinate, in pixels, of the upper-left corner of the
|
|
||||||
* client area of the window.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_POSITION_X 0x00022009
|
|
||||||
/*! @brief The y-coordinate, in pixels, of the upper-left corner of the
|
|
||||||
* client area of the window.
|
|
||||||
* @see glfwWindowHint glfwGetWindowParam
|
|
||||||
*/
|
|
||||||
#define GLFW_POSITION_Y 0x0002200A
|
|
||||||
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name Client APIs
|
|
||||||
* @{ */
|
|
||||||
/*! @brief The OpenGL API.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_API 0x00000001
|
|
||||||
/*! @brief The OpenGL ES API.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_ES_API 0x00000002
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name Context robustness strategies
|
|
||||||
* @{ */
|
|
||||||
/*! @brief No robustness strategy is used.
|
|
||||||
*
|
|
||||||
* This is the default.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_NO_ROBUSTNESS 0x00000000
|
|
||||||
/*! @brief
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_NO_RESET_NOTIFICATION 0x00000001
|
|
||||||
/*! @brief
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_LOSE_CONTEXT_ON_RESET 0x00000002
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name OpenGL profiles
|
|
||||||
* @{ */
|
|
||||||
/*! @brief No OpenGL profile.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_NO_PROFILE 0x00000000
|
|
||||||
/*! @brief The OpenGL core profile.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_CORE_PROFILE 0x00000001
|
|
||||||
/*! @brief The OpenGL compatibility profile.
|
|
||||||
* @ingroup context
|
|
||||||
*/
|
|
||||||
#define GLFW_OPENGL_COMPAT_PROFILE 0x00000002
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name Input modes
|
|
||||||
* @{ */
|
|
||||||
/*! @brief The behaviour of the cursor.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_CURSOR_MODE 0x00030001
|
|
||||||
/*! @brief Whether the @ref glfwGetKey function uses sticky state.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_STICKY_KEYS 0x00030002
|
|
||||||
/*! @brief Whether the @ref glfwGetMouseButton function uses sticky state.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_STICKY_MOUSE_BUTTONS 0x00030003
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name Cursor modes
|
|
||||||
* @{ */
|
|
||||||
/*! @brief The cursor is visible and behaves normally.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_CURSOR_NORMAL 0x00040001
|
|
||||||
/*! @brief The cursor is hidden when over the client area of the window.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_CURSOR_HIDDEN 0x00040002
|
|
||||||
/*! @brief The cursor is disabled and cursor movement is unbounded.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_CURSOR_CAPTURED 0x00040003
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @name Joystick parameters
|
|
||||||
* @{ */
|
|
||||||
/*! @brief @c GL_TRUE if the joystick is present, or @c GL_FALSE otherwise.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_PRESENT 0x00050001
|
|
||||||
/*! @brief The number of axes on the specified joystick, or zero if the joystick
|
|
||||||
* is not present.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_AXES 0x00050002
|
|
||||||
/*! @brief The number of buttons on the specified joystick, or zero if the
|
|
||||||
* joystick is not present.
|
|
||||||
* @ingroup input
|
|
||||||
*/
|
|
||||||
#define GLFW_BUTTONS 0x00050003
|
|
||||||
/*! @} */
|
|
||||||
|
|
||||||
/*! @defgroup errors Error codes
|
/*! @defgroup errors Error codes
|
||||||
* @ingroup error
|
* @ingroup error
|
||||||
* @{ */
|
* @{ */
|
||||||
@ -715,47 +482,74 @@ extern "C" {
|
|||||||
#define GLFW_FORMAT_UNAVAILABLE 0x00070009
|
#define GLFW_FORMAT_UNAVAILABLE 0x00070009
|
||||||
/*! @} */
|
/*! @} */
|
||||||
|
|
||||||
/*! @brief The number of entries in the gamma ramp.
|
#define GLFW_FOCUSED 0x00020001
|
||||||
* @ingroup gamma
|
#define GLFW_ICONIFIED 0x00020002
|
||||||
*/
|
#define GLFW_SHOULD_CLOSE 0x00020003
|
||||||
|
#define GLFW_RESIZABLE 0x00022007
|
||||||
|
#define GLFW_VISIBLE 0x00022008
|
||||||
|
#define GLFW_POSITION_X 0x00022009
|
||||||
|
#define GLFW_POSITION_Y 0x0002200A
|
||||||
|
|
||||||
|
#define GLFW_CONTEXT_REVISION 0x00020004
|
||||||
|
#define GLFW_RED_BITS 0x00021000
|
||||||
|
#define GLFW_GREEN_BITS 0x00021001
|
||||||
|
#define GLFW_BLUE_BITS 0x00021002
|
||||||
|
#define GLFW_ALPHA_BITS 0x00021003
|
||||||
|
#define GLFW_DEPTH_BITS 0x00021004
|
||||||
|
#define GLFW_STENCIL_BITS 0x00021005
|
||||||
|
#define GLFW_ACCUM_RED_BITS 0x00021006
|
||||||
|
#define GLFW_ACCUM_GREEN_BITS 0x00021007
|
||||||
|
#define GLFW_ACCUM_BLUE_BITS 0x00021008
|
||||||
|
#define GLFW_ACCUM_ALPHA_BITS 0x00021009
|
||||||
|
#define GLFW_AUX_BUFFERS 0x0002100A
|
||||||
|
#define GLFW_STEREO 0x0002100B
|
||||||
|
#define GLFW_SAMPLES 0x0002100C
|
||||||
|
#define GLFW_SRGB_CAPABLE 0x0002100D
|
||||||
|
|
||||||
|
#define GLFW_CLIENT_API 0x00022000
|
||||||
|
#define GLFW_CONTEXT_VERSION_MAJOR 0x00022001
|
||||||
|
#define GLFW_CONTEXT_VERSION_MINOR 0x00022002
|
||||||
|
#define GLFW_CONTEXT_ROBUSTNESS 0x00022003
|
||||||
|
#define GLFW_OPENGL_FORWARD_COMPAT 0x00022004
|
||||||
|
#define GLFW_OPENGL_DEBUG_CONTEXT 0x00022005
|
||||||
|
#define GLFW_OPENGL_PROFILE 0x00022006
|
||||||
|
|
||||||
|
#define GLFW_OPENGL_API 0x00000001
|
||||||
|
#define GLFW_OPENGL_ES_API 0x00000002
|
||||||
|
|
||||||
|
#define GLFW_NO_ROBUSTNESS 0x00000000
|
||||||
|
#define GLFW_NO_RESET_NOTIFICATION 0x00000001
|
||||||
|
#define GLFW_LOSE_CONTEXT_ON_RESET 0x00000002
|
||||||
|
|
||||||
|
#define GLFW_OPENGL_NO_PROFILE 0x00000000
|
||||||
|
#define GLFW_OPENGL_CORE_PROFILE 0x00000001
|
||||||
|
#define GLFW_OPENGL_COMPAT_PROFILE 0x00000002
|
||||||
|
|
||||||
|
#define GLFW_CURSOR_MODE 0x00030001
|
||||||
|
#define GLFW_STICKY_KEYS 0x00030002
|
||||||
|
#define GLFW_STICKY_MOUSE_BUTTONS 0x00030003
|
||||||
|
|
||||||
|
#define GLFW_CURSOR_NORMAL 0x00040001
|
||||||
|
#define GLFW_CURSOR_HIDDEN 0x00040002
|
||||||
|
#define GLFW_CURSOR_CAPTURED 0x00040003
|
||||||
|
|
||||||
|
#define GLFW_PRESENT 0x00050001
|
||||||
|
#define GLFW_AXES 0x00050002
|
||||||
|
#define GLFW_BUTTONS 0x00050003
|
||||||
|
|
||||||
#define GLFW_GAMMA_RAMP_SIZE 256
|
#define GLFW_GAMMA_RAMP_SIZE 256
|
||||||
|
|
||||||
/*! @name Monitor parameters
|
|
||||||
* @{ */
|
|
||||||
/*! @brief The physical width, in mm, of the monitor.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_MONITOR_WIDTH_MM 0x00060001
|
#define GLFW_MONITOR_WIDTH_MM 0x00060001
|
||||||
/*! @brief The physical height, in mm, of the monitor.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_MONITOR_HEIGHT_MM 0x00060002
|
#define GLFW_MONITOR_HEIGHT_MM 0x00060002
|
||||||
/*! @brief The x-coordinate of the upper-left corner of the monitor on the
|
|
||||||
* virtual desktop.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_MONITOR_POS_X 0x00060003
|
#define GLFW_MONITOR_POS_X 0x00060003
|
||||||
/*! @brief The y-coordinate of the upper-left corner of the monitor on the
|
|
||||||
* virtual desktop.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_MONITOR_POS_Y 0x00060004
|
#define GLFW_MONITOR_POS_Y 0x00060004
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/*! @name Monitor events
|
|
||||||
* @{ */
|
|
||||||
/*! @brief The monitor was connected.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_CONNECTED 0x00061000
|
#define GLFW_CONNECTED 0x00061000
|
||||||
/*! @brief The monitor was disconnected.
|
|
||||||
* @ingroup monitor
|
|
||||||
*/
|
|
||||||
#define GLFW_DISCONNECTED 0x00061001
|
#define GLFW_DISCONNECTED 0x00061001
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/*************************************************************************
|
/*************************************************************************
|
||||||
* Typedefs
|
* GLFW API types
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*! @brief Client API function pointer type.
|
/*! @brief Client API function pointer type.
|
||||||
@ -907,7 +701,7 @@ typedef struct
|
|||||||
|
|
||||||
|
|
||||||
/*************************************************************************
|
/*************************************************************************
|
||||||
* Prototypes
|
* GLFW API functions
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*! @brief Initializes the GLFW library.
|
/*! @brief Initializes the GLFW library.
|
||||||
|
Loading…
Reference in New Issue
Block a user