InKryption
05bf1df86b
glfw: Use anyopaque
instead of opaque {}
...
Update other two instances of `opaque {}`
2022-01-12 18:58:49 -07:00
InKryption
c84f8510bd
glfw: Use anyopaque
instead of opaque{}
...
Using an inline `opaque{}` type forces the use of `@typeInfo` to cast to the specific type of the parameter.
2022-01-12 18:58:49 -07:00
iddev5
2d738248e7
glfw: Update function docs in Monitor and vulkan to match glfw 3.3.6
2021-12-23 13:01:45 -07:00
Stephen Gutekanst
8e76a927a5
glfw: correctly @errorSetCast when returning errors from createWindowSurface
...
Fixes an issue where `createWindowSurface` would not compile (found when
updating https://github.com/hexops/mach-glfw-vulkan-example to latest.)
Introduced in hexops/mach#115
cc @InKryption
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-12-06 22:16:06 -07:00
InKryption
1b57fb13fb
glfw: Denormalize errors ( #115 )
...
Closes hexops/mach#96
Co-authored-by: Stephen Gutekanst <stephen@hexops.com>
2021-12-06 21:52:15 -07:00
InKryption
58e2632a4e
glfw: Fix pointer cast
...
The GLFW implementation takes a constant pointer to a `VkAllocationCallbacks` struct; casting it to a mutable pointer equivalent here doesn't break anything, but does prevent passing a valid const pointer, which is often what one should prefer to do.
As well, the `@alignOf` builtin takes the alignment expected of the type directly, so `@alignOf(*T)` returns the alignment of `*T`, not `T`, so that has also been corrected.
2021-11-29 12:52:46 -07:00
InKryption
9ec72fdb2c
glfw: Eliminate Error.InvalidValue
2021-11-26 20:50:38 -07:00
InKryption
e363bb0840
glfw: Change error unions into normal returns, in accordance with the new guarantee to never encounter 'GLFW_NOT_INITIALIZED', and update tests
2021-11-22 12:59:11 -07:00
InKryption
946c059f10
glfw: amend and update various TODOs pertaining to force-init changes
2021-11-22 12:59:11 -07:00
InKryption
5c93c0fe22
glfw: assert initialized in proc address getter functions
2021-11-22 12:59:11 -07:00
InKryption
c7558b61eb
glfw: Revert error denormalization
2021-11-22 12:59:11 -07:00
InKryption
db6b48e9e4
glfw: force init error type work around
2021-11-22 12:59:11 -07:00
InKryption
ea757b077f
glfw: force init in vulkan.zig
2021-11-22 12:59:11 -07:00
Silver
f0dd193695
glfw: remove [*c] pointers from api and return lengthed strings when possible
2021-11-16 07:12:02 -07:00
InKryption
82c5079d1d
glfw: Update tests in all other files to reflect changes made to glfw.init
2021-11-10 11:42:24 -07:00
Stephen Gutekanst
b87ef62856
glfw: improve ABI compatability with zig-vulkan library
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-31 01:00:02 -07:00
Stephen Gutekanst
cc4595eb37
glfw: improve panic message for glfw.getInstanceProcAddress
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-29 17:13:21 -07:00
Stephen Gutekanst
457c9394ab
glfw: make glfw.getInstanceProcAddress conform to GLFW C ABI
...
Having `glfw.getInstanceProcAddress` conform to the GLFW C ABI is important as it is often
likely to be passed into libraries which expect exactly that ABI, e.g. zig-vulkan.
Fixes hexops/mach#49
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-29 16:15:42 -07:00
Stephen Gutekanst
37e3c492e8
glfw: add glfw.createWindowSurface
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-18 20:52:34 -07:00
Stephen Gutekanst
e3107a6bd2
glfw: add glfw.getPhysicalDevicePresentationSupport
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-18 20:52:34 -07:00
Stephen Gutekanst
6cfc46077f
glfw: add glfw.getRequiredInstanceExtensions
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-18 20:52:34 -07:00
Stephen Gutekanst
3182eaa4f7
glfw: update TODOs
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-16 18:39:57 -07:00
Stephen Gutekanst
83d3eed240
glfw: add glfw.vulkanSupported
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-16 18:39:57 -07:00
Stephen Gutekanst
dd7305bd1e
glfw: add glfw.getInstanceProcAddress
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-16 18:39:57 -07:00
Stephen Gutekanst
7ba458d25b
glfw: add TODOs for tracking 100% GLFW API coverage
...
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
2021-10-16 18:39:57 -07:00