1
0
Fork 0
mirror of https://github.com/gwm17/glfw.git synced 2024-10-08 23:27:25 -04:00
Commit Graph

352 Commits

Author SHA1 Message Date
Camilla Löwy 798d7c6d68 Implement glfwGetJoystickHats
This moves the buttons-as-hats logic to shared code and adds the
GLFW_JOYSTICK_HAT_BUTTONS input mode as a way to disable this legacy
behavior.

Fixes #889.
2017-03-06 03:23:29 +01:00
Camilla Löwy 6d9a58bfef Add glfwInitHint
This allows setting hints that control how the library is initialized,
transforming more compile-time options into run-time ones.
2017-03-01 04:35:41 +01:00
Camilla Löwy 071a049f07 Documentation work
[ci skip]
2017-02-28 22:54:50 +01:00
Camilla Löwy e019f7e7f2 Remove misleading platform API documentation
[ci skip]
2017-02-28 22:54:45 +01:00
Camilla Löwy 53f46d32e2 Make OSMesa backend an almost proper null backend
It still depends on POSIX time and TLS.
2017-02-28 21:57:43 +01:00
Camilla Löwy e9560ef021 Add GLFW_OSMESA_CONTEXT_API
This allows the creation of OpenGL contexts via OSMesa on existing
platforms.  It does not add a compile- or link-time dependency on
OSMesa.

Fixes #281.
2017-02-28 20:38:10 +01:00
Camilla Löwy 77a8f103d8 Add GLFW_COCOA_GRAPHICS_SWICTHING
This provides control over whether the context should participate in
macOS Automatic Graphics Switching.

Closes #377.
Closes #935.
2017-02-10 01:29:29 +01:00
Camilla Löwy 21eabd3938 Documentation work 2017-02-08 06:53:04 +01:00
Camilla Löwy 926d2beddb Move initialized flag into library struct 2017-02-08 06:53:04 +01:00
Liam Middlebrook 72ac5badb0 Add GLFW_CENTER_CURSOR
Adds a hint for controlling whether the cursor is centered over newly
created full screen windows.

Fixes #749.
Closes #842.
2017-02-06 15:16:26 +01:00
Camilla Löwy bfd564f257 Move internals to shared joystick objects
Preparation for gamecontrollerdb support and the gamepad API.
2017-01-30 16:52:49 +01:00
Camilla Löwy 221451b817 Cleanup 2017-01-10 15:46:00 +01:00
Camilla Löwy 48a795c101 Merge single-use function _glfwFreeMonitors
All other uses were elminiated by _glfwInputMonitor.
2017-01-10 15:01:55 +01:00
Camilla Löwy 3edaa5280d Add GLFW_INCLUDE_ES32 2017-01-02 06:06:01 +01:00
Camilla Löwy 04f559e28d Restructure monitor enumeration
This way is both kinder on event-based enumeration and less work to
unwind allocations for when properly implementing GLFW_OUT_OF_MEMORY.
2017-01-02 06:03:02 +01:00
Camilla Löwy 4661315192 Add GLFW_COCOA_FRAME_AUTOSAVE
Fixes #195.
2017-01-01 19:58:34 +01:00
Camilla Löwy 58ceab5f1e Add GLFW_COCOA_RETINA_FRAMEBUFFER
Look, a can of worms!  I wonder what's inside.

This adds the first platform specific window hint, transforming
a compile-time option to a run-time per-window one.
2016-12-08 16:56:05 +01:00
Camilla Löwy 744cee6ec9 Cleanup 2016-12-08 16:56:05 +01:00
Camilla Löwy 9e56099edd Add glfwSetWindowAttrib
This function allows updating the GLFW_DECORATED, GLFW_RESIZABLE,
GLFW_FLOATING and GLFW_AUTO_ICONIFY attributes for existing windows.

Fixes #537.
2016-12-06 15:59:18 +01:00
Camilla Löwy f4d0c83181 Paperwork done 2016-11-30 14:00:41 +01:00
Camilla Berglund fef21361c5 OSMesa: Cleanup
Fixes formatting, semantics and documentation.  Adds
glfwGetOSMesaContext.  Adds support for OSMesa context attributes.
Updates changelog and credits.  Adds license and copyright headers.
Removes superfluous code (the shared code provides many conveniences).
Removes loading of unused OSMesa functions.  Removes empty platform
structs.  Fixes version string format.  Removes build dependency on
the OSMesa header and library (only the library is needed and only at
runtime).

Closes #850.
2016-11-09 01:36:21 +01:00
Jason Daly 368fa9475d Add headless OSMesa backend
Allows creation and drawing to in-memory OpenGL contexts.

This backend does not provide input.

Related to #850.
2016-11-09 01:23:43 +01:00
Camilla Berglund e94d16667b Cocoa: Add basic support for Vulkan via MoltenVK
This adds basic support for MoltenVK, a Vulkan implementation on top of
Metal, on macOS 10.11 and later.  It looks for MoltenVK in the process
via RTLD_DEFAULT symbol lookup if _GLFW_VULKAN_STATIC is disabled.

glfwCreateWindowSurface now creates and sets a CAMetalLayer for the
window content view, which is required for MoltenVK to function.

You must help CMake find MoltenVK for the Vulkan test to be built.

Fixes #870.
2016-11-01 21:39:54 +01:00
Camilla Berglund fef25ea934 Emit all Vulkan init errors from init function 2016-11-01 21:34:26 +01:00
Camilla Berglund efc6b35615 Rename joystick ID variables 2016-10-16 14:07:18 +02:00
Camilla Berglund c156b50e4c Add glfwSetWindowMaximizeCallback
Fixes #778.
2016-09-29 01:24:56 +02:00
Camilla Berglund 54930ddd33 Check only for relevant Vulkan extensions
Related to #858.
2016-09-14 22:59:03 +02:00
Camilla Berglund bb3cb8f233 Cleanup
Clean up code and documentation for glfwGetKeyScancode and add
implementation for Wayland and Mir.

Related to #830.
2016-09-07 16:46:48 +02:00
Michael Stocker e745b0dd47 Add glfwGetKeyScancode
Allows retrieval of platform scancode from GLFW_KEY_*.  Implemented for
Win32, Cocoa and X11.  Stubs for Mir and Wayland.

Closes #830.
2016-09-07 16:38:22 +02:00
Camilla Berglund 5ff7d9505f Simplify Vulkan extension checks
Related to #478.
2016-09-07 16:31:18 +02:00
Camilla Berglund 53fafad915 Start 3.3 2016-08-18 23:55:49 +02:00
Camilla Berglund 1d3240ff9c Fix Vulkan header macro not breaking compilation
Fixes #823.
2016-08-05 01:32:23 +02:00
Camilla Berglund 7c3706763a Cleanup
Cleanup of 8bdb105897.

Add build macro to configuration header and documentation.  Add
corresponding CMake option.  Add change log entry and credit.  Add
loader static library to link dependencies and add detection to
FindVulkan.cmake.
2016-08-05 01:00:08 +02:00
Philip Rideout 8bdb105897 Add _GLFW_VULKAN_STATIC build macro
This allows clients to link GLFW with a staticly-built loader library.
This is useful in hermetic build systems that build the Khronos loader
from source, rather than depending on the LunarG SDK binaries.

Closes #820.
2016-08-04 18:24:41 +02:00
Camilla Berglund 614debd13f Initialize Vulkan API on demand 2016-07-20 15:18:42 +02:00
Camilla Berglund 9a781cef53 Formatting 2016-06-15 01:35:07 +02:00
Camilla Berglund 757eea2779 Update email address 2016-06-01 21:25:20 +02:00
Camilla Berglund 6a8e169001 Update copyright notice year 2016-06-01 21:25:19 +02:00
Camilla Berglund 2d2756cbad Simplify cursor window logic 2016-05-30 22:12:33 +02:00
Camilla Berglund bda031f4ac Cleanup 2016-05-29 15:34:08 +02:00
Camilla Berglund 797ee8d8e3 Move all cursor positioning to platform code
Due to Wayland, shared code cannot rely on cursor positioning being
supported by the underlying platform.

This implicitly fixes #617 as it moves cursor centering into
_glfwPlatformSetCursorMode, thus separating it from the stale value of
_glfw.cursorWindow.

Fixes #617.
2016-05-29 15:33:49 +02:00
Camilla Berglund 0e846883bf Clarify cursor position variable names 2016-05-27 02:39:03 +02:00
Camilla Berglund ef80beab81 Add run-time context creation API selection
Fixes #145.
2016-05-04 17:00:07 +02:00
Camilla Berglund 8a7fa306ce Add glfwSetJoystickCallback 2016-03-31 12:12:09 +02:00
Camilla Berglund f96d865b93 Cleanup 2016-03-28 20:16:53 +02:00
Camilla Berglund 7ab7d8b4b1 Make use of uint32_t where appropriate
This change does not affect the ABI.
2016-03-28 12:34:57 +02:00
Camilla Berglund 5661d03be8 Replace GLFWuint64 with uint64_t
C99 stdint.h is provided by VS 2010 and later.  GLFW has not provided
testing or binaries for VS 2008 for several releases.

For earlier versions of VS there are third-party alternatives:

https://msinttypes.googlecode.com/svn/trunk/stdint.h
http://www.azillionmonkeys.com/qed/pstdint.h

This change does not affect the ABI.
2016-03-28 12:34:44 +02:00
Camilla Berglund 5eb2e83c82 Cleanup 2016-03-28 12:26:08 +02:00
Camilla Berglund 6570d0c4b7 Add glfwSetWindowMonitor
This adds the ability to switch between windowed and full screen modes,
move a full screen window between monitors and update its desired
resolution and refresh rate.

Fixes #43.
2016-03-18 11:13:24 +01:00
Camilla Berglund 99c925efd8 Add tracking of which window 'owns' a monitor 2016-03-16 16:16:29 +01:00