578 Commits

Author SHA1 Message Date
kbz_8 c54aff0397 Indev (#133) 2025-03-17 11:34:58 +01:00
Kbz-8 49a66e1abc fixing bug 2025-03-17 11:24:43 +01:00
Kbz-8 a2996191d3 yes 2025-03-14 12:41:51 +01:00
kbz_8 30cc6cb0d5 adding bindings (#132) 2025-03-13 17:11:33 +01:00
kbz_8 ad27df221b Merge branch 'master' into indev 2025-03-13 17:06:23 +01:00
Kbz-8 96bb8c94f5 adding bindings 2025-03-13 16:58:10 +01:00
kbz_8 7991b045f3 Indev (#131) 2025-03-13 00:47:48 +01:00
Kbz-8 8c27a1eb20 Merge branch 'indev' of github.com:seekrs/MacroLibX into indev 2025-03-13 00:43:47 +01:00
Kbz-8 0c177eaaa7 removing unnecessary mode in CIs 2025-03-13 00:43:34 +01:00
Kbz-8 ff77f3bf9c adding hidden bindings 2025-03-13 00:40:16 +01:00
Kbz-8 5c1cfdea60 Merge branch 'indev' of github.com:seekrs/MacroLibX into indev 2025-03-13 00:39:22 +01:00
Kbz-8 0a9d423eeb adding hidden bindings 2025-03-13 00:39:01 +01:00
kbz_8 ce291c9c47 Indev (#130) 2025-03-12 23:09:01 +01:00
kbz_8 2dd27f9411 Merge branch 'master' into indev 2025-03-12 23:03:14 +01:00
Kbz-8 91c87e2b7a adding secret bindings 2025-03-12 22:57:29 +01:00
Kbz-8 ac05312375 Merge branch 'indev' of github.com:seekrs/MacroLibX into indev 2025-03-12 21:38:20 +01:00
Kbz-8 d47f71804b yes 2025-03-12 21:37:59 +01:00
kbz_8 970a1b4575 update dependencies (#129)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-03-10 08:49:06 +01:00
Kbz-8 ae9b0beac9 [BOT] update dependencies 2025-03-09 00:34:15 +00:00
kbz_8 b0c8a09697 Indev (#128) 2025-03-08 19:01:54 +01:00
kbz_8 785fb0808e Merge branch 'master' into indev 2025-03-08 18:53:58 +01:00
kbz_8 37bb97b4d1 update dependencies (#124)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-02-24 08:13:09 +01:00
kbz_8 65aa97ceb5 fix(Renderer/Image.cpp): bad moving_y bounds checking (#126) 2025-02-24 08:12:50 +01:00
kbz_8 ba60f93434 Revert "🐛 fix(Renderer/Image.cpp): bad moving_y bounds checking" (#125)
Reverts seekrs/MacroLibX#123
2025-02-24 08:12:05 +01:00
kbz_8 c06a0fb1de Revert "🐛 fix(Renderer/Image.cpp): bad moving_y bounds checking" 2025-02-24 08:11:18 +01:00
kbz_8 cc0e674f3a 🐛 fix(Renderer/Image.cpp): bad moving_y bounds checking (#123)
moved moving_y++ line
2025-02-24 08:11:10 +01:00
Kbz-8 e13ea28ae6 [BOT] update dependencies 2025-02-23 00:40:25 +00:00
Arkturius 312ca527be 🐛 fix(Renderer/Image.cpp): bad moving_y bounds checking 2025-02-22 16:39:09 +01:00
kbz_8 580352f970 update dependencies (#122)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-02-10 08:05:01 +01:00
Kbz-8 278ea3e756 [BOT] update dependencies 2025-02-09 00:39:34 +00:00
kbz_8 cadfce3e7b update dependencies (#121)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-02-02 17:19:08 +01:00
Kbz-8 5c1771a711 [BOT] update dependencies 2025-02-02 00:38:46 +00:00
kbz_8 876be807e2 update dependencies (#120)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-01-26 10:18:23 +01:00
Kbz-8 5c18ceeb16 [BOT] update dependencies 2025-01-26 00:37:34 +00:00
kbz_8 8ff55ee0e7 fixing error message (#119) 2025-01-24 20:30:54 +01:00
Kbz-8 cd9d2dde95 fixing error message 2025-01-24 20:23:28 +01:00
kbz_8 56bbc2204e Fix swapchain surface format selection (#118) 2025-01-22 10:11:02 +01:00
Kbz-8 04294418b7 yes 2025-01-21 21:27:13 +01:00
Kbz-8 eeb563d2c2 fixing msvc compilation issue 2025-01-21 21:24:58 +01:00
Kbz-8 f18fa55b59 fixing swapchain surface format selection 2025-01-21 20:59:57 +01:00
Kbz-8 49dd56ba8f Merge branch 'indev' of github.com:seekrs/MacroLibX into indev 2025-01-21 15:12:30 +01:00
Kbz-8 1934e4a478 adding swapchain format to debug logs 2025-01-21 15:12:09 +01:00
kbz_8 3e5f370281 update dependencies (#117)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-01-19 20:48:42 +01:00
Kbz-8 b156368f9c [BOT] update dependencies 2025-01-19 00:39:17 +00:00
kbz_8 082f9907b0 fixing too recent header (#116) 2025-01-12 21:17:31 +01:00
Kbz-8 430fa0af9e fixing too recent header 2025-01-12 21:13:30 +01:00
kbz_8 99d20ca740 Indev (#115) 2025-01-12 18:39:09 +01:00
Kbz-8 8470080236 fixing deps update 2025-01-12 12:30:43 +01:00
kbz_8 a226e4d746 yes (#114) 2025-01-12 12:28:03 +01:00
kbz_8 f478c44599 update dependencies (#113)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-01-12 12:27:14 +01:00
Kbz-8 be01670919 [BOT] update dependencies 2025-01-12 00:41:23 +00:00
kbz_8 b06150f322 update README.md (#112) 2025-01-11 23:44:59 +01:00
Kbz-8 6cd0aaa42b update README.md 2025-01-11 23:44:37 +01:00
kbz_8 87e2c2002d Update README.md (#111) 2025-01-11 23:26:30 +01:00
kbz_8 52a18af142 Update README.md 2025-01-11 23:26:20 +01:00
kbz_8 f8dc9613d6 release 2.0 (#110) 2025-01-11 23:15:04 +01:00
Kbz-8 07f521d3d5 fixing macOS issue 2025-01-11 23:04:58 +01:00
Kbz-8 d2a8ac46f6 fixing macOS issue 2025-01-11 22:47:26 +01:00
Kbz-8 f73fa1b02d fixing macOS issue 2025-01-11 22:42:40 +01:00
Kbz-8 2030534cf2 fixing macOS issue 2025-01-11 22:28:39 +01:00
Kbz-8 712ac4be64 fixing macOS issue 2025-01-11 22:23:20 +01:00
Kbz-8 809bea2fca fixing macOS issue 2025-01-11 22:21:32 +01:00
Kbz-8 285bcda21f fixing macOS issue 2025-01-11 22:00:42 +01:00
Kbz-8 c9870faaf1 fixing macOS issue 2025-01-11 21:49:30 +01:00
Kbz-8 c6490c979c fixing macOS issue 2025-01-11 21:44:17 +01:00
Kbz-8 427e5aa099 fixing macOS issue 2025-01-11 21:42:50 +01:00
Kbz-8 55f1df2ec7 fixing haeder 2025-01-08 12:37:34 +01:00
Kbz-8 273255ecfe fixing transformations 2025-01-07 19:57:03 +01:00
Kbz-8 f9ef8fc790 fixing possible segmentation fault in Texture::SetLinearRegion 2025-01-07 15:59:26 +01:00
Kbz-8 54b45824b3 fixing things 2025-01-07 01:20:26 +01:00
kbz_8 aa345c7e38 update dependencies (#109)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2025-01-05 12:05:19 +01:00
Kbz-8 9874c1fd5b [BOT] update dependencies 2025-01-05 00:40:54 +00:00
kbz_8 1da9fd767d update dependencies (#107)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-12-29 17:27:48 +01:00
Kbz-8 c6fefe2ffa [BOT] update dependencies 2024-12-29 00:41:02 +00:00
Kbz-8 c60c176a54 wtf is hapenning 2024-12-28 15:42:38 +01:00
Kbz-8 cd906ca117 Merge branch 'indev' of github.com:seekrs/MacroLibX into indev 2024-12-27 23:29:27 +01:00
Kbz-8 f6708058b3 fixing vicious bug in scene code 2024-12-27 23:28:51 +01:00
kbz_8 f07131686f update dependencies (#106)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-12-22 15:42:50 +01:00
Kbz-8 036fa0e7b6 [BOT] update dependencies 2024-12-22 00:40:37 +00:00
Kbz-8 b6edf442a2 re-adding render to texture 2024-12-20 01:19:15 +01:00
Kbz-8 b6660b99d6 fixing documentation in headers 2024-12-17 03:00:12 +01:00
Kbz-8 ffff4722b7 adding multiple hooks supports for events and loop 2024-12-17 02:33:04 +01:00
Kbz-8 8f4dc6e3b5 fixing gcc/msvc error 2024-12-17 01:40:58 +01:00
Kbz-8 6de8d3a4fd fixing gcc/msvc error 2024-12-17 01:03:00 +01:00
Kbz-8 24d9b4b6c9 fixing gcc/msvc error 2024-12-17 00:59:54 +01:00
Kbz-8 905859acba changing endianness getter 2024-12-17 00:42:21 +01:00
Kbz-8 213a8f6a6d implementing endianness check on mlx_color struct 2024-12-17 00:19:13 +01:00
Kbz-8 42e62ac3eb working on endianness with vulkan images 2024-12-17 00:11:21 +01:00
Kbz-8 30328b1732 fixing bug in texture clear 2024-12-16 19:07:16 +01:00
Kbz-8 335c797c12 fixing homebrew path 2024-12-16 17:26:12 +01:00
Kbz-8 d3808cde1a revert 2024-12-16 17:22:34 +01:00
Kbz-8 9183e7c1e8 installing SDL2 framework in macos action 2024-12-16 17:03:53 +01:00
Kbz-8 17ae77d11a update action images 2024-12-16 16:57:23 +01:00
Kbz-8 d379e5a9fe fixing windows compilation issue 2024-12-16 16:39:50 +01:00
Kbz-8 7d407fc6d1 adding gcc13 to CI 2024-12-16 16:39:04 +01:00
Kbz-8 47f6bc73e9 fixing macos compilation issue 2024-12-16 16:17:17 +01:00
Kbz-8 4987a8ca6e implementing last functions, adding put pixel region 2024-12-16 16:13:44 +01:00
Kbz-8 ab4d67d764 finxing memory usages 2024-12-16 01:24:25 +01:00
Kbz-8 11ccc041d2 adding missing function implementation 2024-12-15 03:53:56 +01:00
Kbz-8 323b16f107 reworking application and bridge 2024-12-15 03:35:17 +01:00
Kbz-8 0622684e40 rewritting parts of the API; ci skip 2024-12-14 16:38:44 +01:00
Kbz-8 f5333882c6 working on garbage collection, fixing small issues with font destroy 2024-12-14 01:39:50 +01:00
Kbz-8 5d4d97e05d fixing valgrind issues, injecting garbage collector inside vulkan's funtions 2024-12-13 02:51:52 +01:00
Kbz-8 5a04ad7781 moving experimental features to a new folder 2024-12-04 18:34:53 +01:00
kbz_8 e1add20315 officially push 2.0 to test (#105) 2024-12-04 15:56:59 +01:00
Kbz-8 9bb95be679 fetching deps 2024-12-04 15:56:38 +01:00
Kbz-8 97ea5e3acf trying to fix merge conflicts 2024-12-04 15:55:11 +01:00
Kbz-8 841d140c69 working on subpass dependencies 2024-12-04 15:38:47 +01:00
Kbz-8 fc74873bc6 yes 2024-12-04 15:14:56 +01:00
Kbz-8 37ea1b1cd4 enabling pre compiled header 2024-12-04 15:04:51 +01:00
Kbz-8 1bf92b3b26 adding include check 2024-12-04 14:35:54 +01:00
Kbz-8 cda4faa103 adding compiler version info to makefile header 2024-12-04 14:30:09 +01:00
Kbz-8 5529bbd2e1 adding missing include 2024-12-04 14:19:36 +01:00
Kbz-8 ec2c444051 fixing window resizing 2024-12-04 14:04:44 +01:00
kbz_8 56fec8d1ff update dependencies (#104)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-12-03 14:35:12 +01:00
Kbz-8 e29f5e7edd [BOT] update dependencies 2024-12-01 00:48:21 +00:00
Kbz-8 17fcb85adc working on swapchains 2024-11-26 23:11:03 +01:00
kbz_8 b8966d5907 update dependencies (#103)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-11-24 18:11:21 +01:00
Kbz-8 50edf78e7d [BOT] update dependencies 2024-11-24 00:41:50 +00:00
kbz_8 89b1ae475f yes (#102) 2024-11-22 15:37:01 +01:00
kbz_8 44484798e8 Edit valgrind.supp for libdbus & libnvidia leak (#101)
Added rules in valgrind.supp for libdbus.so & libnvidia leaks
2024-11-22 15:35:43 +01:00
Thomas Arnaud 8cf08d3490 Edit valgrind.supp for libdbus & libnvidia lib 2024-11-22 13:59:35 +01:00
Kbz-8 c85a30e669 working on rtt 2024-11-14 17:38:44 +01:00
Kbz-8 f401b3694a fixing rotation 2024-11-14 11:44:52 +01:00
Kbz-8 f27e5ef043 fixing linux build failure 2024-11-13 12:23:16 +01:00
Kbz-8 35b7408eab adding transformations 2024-11-13 12:17:59 +01:00
Kbz-8 71d1c20a27 adding nesting to debug logs 2024-11-05 12:49:21 +01:00
Kbz-8 8d879fb5bc improving BringToLayer 2024-11-05 11:59:31 +01:00
Kbz-8 d1a5bceb03 fixing bug with image recreation 2024-11-05 11:50:40 +01:00
Kbz-8 5bd66fd362 adding clear color in mlx_clear_window 2024-11-04 21:21:46 +01:00
kbz_8 142ea2d39f update dependencies (#100)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-11-04 17:50:11 +01:00
Kbz-8 21964fc628 [BOT] update dependencies 2024-11-03 00:40:16 +00:00
Kbz-8 af70e2e354 yes 2024-11-03 01:23:52 +01:00
Kbz-8 77f1a2d8f8 added show and hide cursor support, fixing technological debt from original mlx, fixed missaligned comments in mlx.h 2024-10-31 15:16:01 +01:00
Kbz-8 fc404a4d22 updating example 2024-10-31 13:07:07 +01:00
Kbz-8 601c2435f1 fixing texts 2024-10-31 12:54:05 +01:00
Kbz-8 ea950a1901 yes 2024-10-31 12:36:44 +01:00
Kbz-8 524da32c65 yes 2024-10-28 20:19:39 +01:00
Kbz-8 3153941573 yes 2024-10-28 20:17:39 +01:00
kbz_8 51427dce86 Fixing layering issues with text and textures (#99)
![image](https://github.com/user-attachments/assets/804d7dfa-90fd-4d61-b448-61ffa30ed00f)
2024-10-28 20:16:49 +01:00
Namonay 245d556105 Formatting 2024-10-28 20:02:42 +01:00
Namonay df05148d22 Cleaned code 2024-10-28 00:29:11 +01:00
Namonay f7ddf3cccb add: bring textures to draw layer
Adding the Scene::BringToDrawLayer() to fix layering issues after a Scene::ResetScene() call
2024-10-27 23:12:07 +01:00
Kbz-8 77240013a4 fixing segfault at exit 2024-10-27 21:18:22 +01:00
Kbz-8 1721632a75 pushing for vavaas to debug 2024-10-27 20:55:21 +01:00
kbz_8 d3bf2505f6 update dependencies (#98)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-27 11:42:45 +01:00
Kbz-8 c6d6c821a9 [BOT] update dependencies 2024-10-27 00:40:14 +00:00
Kbz-8 d4bd8b62c5 working on texts and fonts 2024-10-27 01:14:07 +02:00
kbz_8 fc6aeab678 feature(platform/window.cpp): put SDL_CreateWindow flags in a define (#97) 2024-10-27 00:42:33 +02:00
kbz_8 53bb936453 fixed code style 2024-10-27 00:34:41 +02:00
killian a7fdb5838d feature(platform/window.cpp): put SDL_CreateWindow flags in a define
Signed-off-by: killian <oss@xtrm.me>
2024-10-27 00:32:22 +02:00
kbz_8 ef61b7943e 2.0 devFixing putpixel and put image overlapping incorrectly after a mlx_clear_window() call (#96)
Fixed m_draw_layer incrementation when TexturePut is called
2024-10-25 23:23:37 +02:00
Namonay 185a2b700c Merge branch 'seekrs:2.0-dev' into 2.0-dev 2024-10-25 23:08:55 +02:00
Kbz-8 da85343e32 yes 2024-10-24 19:13:02 +02:00
Namonay d8a6676063 better naming and removed todo🤓 2024-10-24 05:30:37 +02:00
Namonay 47d0cfb20b this feels wrong 2024-10-24 05:16:37 +02:00
Namonay 92c8014af1 Merge branch '2.0-dev' of github.com:Namonay/MacroLibX into 2.0-dev 2024-10-24 05:15:57 +02:00
Namonay 101b8dac7b this feel so wrong 2024-10-24 05:13:41 +02:00
Kbz-8 cfb41b7b27 yes 2024-10-22 16:25:13 +02:00
Kbz-8 aa26e528c4 fixing compilation issues 2024-10-22 12:09:49 +02:00
Kbz-8 e7cb78557f working on fonts 2024-10-21 23:21:50 +02:00
Kbz-8 05d07e5b72 bozoman solution 2024-10-21 21:58:04 +02:00
Kbz-8 8f757cab08 yes 2024-10-21 19:45:33 +02:00
Kbz-8 c7484b771f fixing put pixel, adding scene change checker 2024-10-21 01:48:01 +02:00
kbz_8 418feba7d3 update dependencies (#95)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-20 02:42:25 +02:00
Kbz-8 0c35f2702e [BOT] update dependencies 2024-10-20 00:40:22 +00:00
kbz_8 226430f01e fixing crash when initializing mlx multiple times (#94) 2024-10-19 10:57:39 +02:00
kbz_8 ae3be69081 Merge branch 'master' into indev 2024-10-19 10:52:55 +02:00
Kbz-8 307270532f fetching deps once a week 2024-10-19 10:51:33 +02:00
Kbz-8 04f9cb1d95 fixing crash when initializing the mlx multiple times 2024-10-19 10:50:50 +02:00
Kbz-8 59455495b6 yes 2024-10-19 10:46:31 +02:00
kbz_8 c45a76a5bf update dependencies (#92)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-19 00:44:08 +02:00
Kbz-8 632117a3a3 yes 2024-10-19 00:43:39 +02:00
Kbz-8 0ea0cde668 fixing inputs bug, fixing missing depth image destruction in scenes 2024-10-17 18:35:33 +02:00
Kbz-8 74dd8a01e2 fixing projection issue 2024-10-17 15:37:39 +02:00
Kbz-8 09561328ed [BOT] update dependencies 2024-10-12 01:21:00 +00:00
kbz_8 baa0ab0a2c update dependencies (#91)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-08 05:29:49 +02:00
Kbz-8 fd56e83c7b [BOT] update dependencies 2024-10-08 01:23:20 +00:00
kbz_8 ea2ee83a3e update dependencies (#90)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-07 06:09:15 +02:00
Kbz-8 5be3c86de4 [BOT] update dependencies 2024-10-07 01:25:31 +00:00
kbz_8 ae02055e18 update dependencies (#89)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-06 07:50:37 +02:00
Kbz-8 74e2d04b7b [BOT] update dependencies 2024-10-06 01:35:52 +00:00
kbz_8 6ad95ca4c4 update dependencies (#88)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-10-06 02:05:35 +02:00
Kbz-8 f08b1f6c8a [BOT] update dependencies 2024-10-05 01:22:08 +00:00
kbz_8 4d640ed70c dumbass (#87) 2024-09-30 03:26:07 +02:00
xtrm 85ada83d57 Update mlx.h 2024-09-30 03:15:44 +02:00
kbz_8 c9ca2187b3 update dependencies (#86)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-09-28 22:03:43 +02:00
Kbz-8 6a0f4fd8dc [BOT] update dependencies 2024-09-27 01:23:16 +00:00
Kbz-8 cf773b586e adding shaders compilation in makefile 2024-09-22 21:39:20 +02:00
Kbz-8 c718915927 fixing release compilation issue 2024-09-21 12:56:21 +02:00
Kbz-8 0b3ca8ec0c adding debug vulkan resources names 2024-09-21 12:18:42 +02:00
Kbz-8 3f065bc77e fixing bugs 2024-09-20 21:43:23 +02:00
Kbz-8 8dd6def84d fixing kvf issues 2024-09-20 17:41:52 +02:00
Kbz-8 4e1ae347a8 removing all singletons 2024-09-20 17:29:42 +02:00
Kbz-8 4ed84d43c1 fixing SDLManager 2024-09-20 17:02:55 +02:00
Kbz-8 48801d1070 fixing vulkan loader, moving vulkan pfns to RenderCore 2024-09-20 16:14:14 +02:00
Kbz-8 e9a8a0cb84 working on vulkan loader 2024-09-16 05:07:02 +02:00
Kbz-8 83432cb356 fixing warnings in kvf 2024-09-15 10:11:08 +02:00
Kbz-8 527a88ebaa fixing compilation issues 2024-09-15 09:03:52 +02:00
Kbz-8 7079e1e42d implementing mouse move and get screen size, removing warnings 2024-09-15 08:56:22 +02:00
Kbz-8 7243c67c3e AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHHHHHHHHHHHHH 2024-09-15 07:56:28 +02:00
Kbz-8 94873df8fe fixing windows build x3 | replacing compile commands by compile flags 2024-09-15 07:52:25 +02:00
Kbz-8 25b605d7d9 fixing windows build x2 2024-09-14 13:20:31 +02:00
Kbz-8 f743fc717f fixing windows build 2024-09-14 13:14:36 +02:00
Kbz-8 8191191fff fixing macos and windows CI ? x3 2024-09-14 13:04:43 +02:00
Kbz-8 9631305e35 fixing macos and windows CI ? 2024-09-14 12:53:29 +02:00
Kbz-8 14b42a7c9e fixing macos and windows CI ? 2024-09-14 12:44:25 +02:00
Kbz-8 f50dd2d946 fixing compilation issues 2024-09-14 09:55:19 +02:00
kbz_8 3dd68f9942 merge indev into master (#84) 2024-09-14 00:45:30 +02:00
Kbz-8 ffe5704673 fixing compilation issues with GCC 2024-09-14 00:05:50 +02:00
kbz_8 20ec13d2b9 resolving merge (#83) 2024-09-13 23:54:58 +02:00
Kbz-8 77bfe4ff11 yes 2024-09-13 23:51:01 +02:00
kbz_8 33d2b98c55 adding support for changing window position (#82)
added window move function
2024-09-12 21:00:40 +02:00
kbz_8 1adce43d9f fixing codestyle in application.inl 2024-09-12 03:32:08 +02:00
Tidian Delage 466050ee7a adding support for changing window position
mlx_set_window_position(void *mlx, void *win, int x, int y)
2024-09-12 01:32:52 +02:00
kbz_8 6bc505de13 update dependencies (#80)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-09-07 05:17:36 +02:00
Kbz-8 d70d748877 [BOT] update dependencies 2024-09-07 01:17:30 +00:00
Kbz-8 6eaf871d45 fixing compilation issues 2024-09-05 00:41:52 +02:00
Kbz-8 0a84ea6a18 fixing compilation issues, working on textures 2024-09-04 02:35:01 +02:00
Kbz-8 1b996af83f starting to fix compilation issues 2024-09-02 13:36:02 +02:00
Kbz-8 b7d554553b adding depth buffer, ci skip 2024-09-02 13:02:32 +02:00
Kbz-8 d5eeef9559 big refactoring ! ci skip 2024-09-02 09:44:42 +02:00
kbz_8 5cda85d16c update dependencies (#79)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-09-02 09:42:20 +02:00
Kbz-8 9318456afb [BOT] update dependencies 2024-08-31 01:18:08 +00:00
kbz_8 40fe100ecc update dependencies (#75)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-08-22 23:13:32 +02:00
Kbz-8 c1bfc0f27d [BOT] update dependencies 2024-08-17 01:12:49 +00:00
kbz_8 5a09ebb179 Add <algorithm> header to fix compilation issue on Arch Linux (#76)
The code was failing to compile on Arch Linux due to missing definitions
from the <algorithm> header. Including this header resolves the issue,
ensuring compatibility across different environments.
2024-08-08 18:10:22 +02:00
bonsthie 8370ae8324 Add <algorithm> header to fix compilation issue on Arch Linux
The code was failing to compile on Arch Linux due to missing definitions from the <algorithm> header. Including this header resolves the issue, ensuring compatibility across different environments.
2024-08-08 17:49:14 +02:00
kbz_8 a4fcbf187b update dependencies (#74)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-07-20 09:58:01 +02:00
Kbz-8 b15aa648e2 [BOT] update dependencies 2024-07-19 15:46:30 +00:00
kbz_8 9a88a8502e update dependencies (#73)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-07-13 03:50:02 +02:00
Kbz-8 34a46d643a [BOT] update dependencies 2024-07-13 01:13:25 +00:00
Kbz-8 7ecee717f8 fixing compoilation issues 2024-07-05 22:15:36 +02:00
kbz_8 359be83f49 update dependencies (#72)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-07-05 12:59:44 +02:00
Kbz-8 8c8c96bf30 [BOT] update dependencies 2024-07-02 01:12:05 +00:00
kbz_8 e30a243452 update dependencies (#71)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-07-01 22:07:45 +02:00
Kbz-8 f8e1cd4a66 [BOT] update dependencies 2024-06-29 01:10:23 +00:00
kbz_8 d5512b72fa update dependencies (#70)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-06-17 19:32:26 +02:00
Kbz-8 86f3d545ee [BOT] update dependencies 2024-06-15 01:10:51 +00:00
kbz_8 9149f42b95 update dependencies (#69)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-06-08 05:01:50 +02:00
Kbz-8 7aea6682f2 [BOT] update dependencies 2024-06-08 01:10:19 +00:00
kbz_8 d0ca0e4ab7 update dependencies (#68)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-06-04 14:44:26 +02:00
Kbz-8 f6dfed48dd [BOT] update dependencies 2024-06-01 01:13:48 +00:00
kbz_8 5a69dff9d7 update dependencies (#67)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-05-29 18:23:43 +02:00
Kbz-8 b7e2164f91 [BOT] update dependencies 2024-05-28 01:08:56 +00:00
Kbz-8 37e9410d12 removing GLFW support 2024-05-25 16:47:28 +02:00
kbz_8 273858ec8f update dependencies (#65)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-05-25 14:58:18 +02:00
Kbz-8 8f088eb76d [BOT] update dependencies 2024-05-23 01:08:01 +00:00
kbz_8 a7433a6570 🐛 fix(vsupp): dl and dbus errors suppressed (#66)
ehehheheheh
2024-05-22 18:53:36 +02:00
Arkturius 3ab445e780 🐛 fix(vsupp): dl and dbus errors suppressed 2024-05-22 18:30:59 +02:00
killian dd554cce2a feature(Makefile): change color when compiling in debug 2024-04-24 15:00:22 +02:00
killian a182b53d7f feature(Makefile): remove bc dependency, allow usage of -j with make re 2024-04-24 14:57:20 +02:00
Kbz-8 a5f85a8a4c fixing segmentation fault on mlx_destroy_image 2024-04-24 13:52:34 +02:00
Kbz-8 edb44070a9 still refactor 2024-04-24 13:47:58 +02:00
Kbz-8 be19b71c55 still working on code refactoring 2024-04-23 22:59:33 +02:00
kbz_8 ae6a86800e Cool Makefile I guess (#64)
yada yada yada
2024-04-23 22:52:09 +02:00
xtrm b85e0444cb 🔨 chore: mauvaisfeedback 2024-04-23 22:46:32 +02:00
Kbz-8 f8a856db1c working on code refactor 2024-04-23 20:59:50 +02:00
xtrm fc33d33508 🔨 chore(actions): change usage of DEBUG=true to the debug rule 2024-04-23 20:42:39 +02:00
xtrm 14698594d8 🐛 fix(Makefile): optimize color usage 2024-04-23 20:38:26 +02:00
xtrm 024f3fefc3 🐛 fix(actions): try and fix logging in GitHub Actions CI 2024-04-23 20:37:17 +02:00
xtrm 33872806a1 🔨 chore(render_core.cpp): revert moving the warning to Makefile 2024-04-23 20:33:11 +02:00
xtrm 3b4a1de9f3 feature(Makefile): pretty makefile, added -rdynamic LDFLAG, moved debug warning, added debug Makefile rule 2024-04-23 20:21:53 +02:00
Kbz-8 5af4c82c1b fixing multiple window issue 2024-04-22 17:35:41 +02:00
kbz_8 e26af9ae1b update dependencies (#62)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-04-22 12:57:49 +02:00
Kbz-8 8c41eefadb [BOT] update dependencies 2024-04-22 01:07:14 +00:00
kbz_8 25d86eccee merge indev to master (#61) 2024-04-21 18:20:21 +02:00
kbz_8 2393261cb0 Merge branch 'master' into indev 2024-04-21 18:15:25 +02:00
kbz_8 d9d165f17e update dependencies (#60)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-04-21 18:14:31 +02:00
Kbz-8 f446c82780 fixing bug with window destruction within mlx_loop 2024-04-21 18:14:14 +02:00
Kbz-8 810417a251 working 2024-04-21 18:10:36 +02:00
Kbz-8 cc507ea4cf [BOT] update dependencies 2024-04-20 01:04:56 +00:00
Kbz-8 0e04356ea7 begenning the refactor 2024-03-27 23:03:54 +01:00
Kbz-8 b5983ac24b renaming MLX_Window to Window 2024-03-27 13:19:28 +01:00
Kbz-8 abc213c808 working glfw support 2024-03-26 00:11:38 +01:00
Kbz-8 86671b8919 fixing pch compilation error 2024-03-25 19:27:48 +01:00
Kbz-8 982e3e6827 fixing pch compilation error 2024-03-25 19:24:37 +01:00
Kbz-8 e2ea602372 fixing pre compiled header usage, improved compilation time 2024-03-25 19:21:14 +01:00
Kbz-8 7f80671be8 adding pre compiled header 2024-03-25 18:58:48 +01:00
Kbz-8 42fc7d9a86 working on fps capper 2024-03-25 17:33:42 +01:00
Kbz-8 60d3df7969 fixing new gcc warning in GPU allocator, fixing #55 2024-03-25 16:18:24 +01:00
Kbz-8 be52578d37 fixing some bad memory usage 2024-03-25 13:57:20 +01:00
kbz_8 57c5ae5415 update dependencies (#59)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-03-24 23:04:44 +01:00
Kbz-8 c6d6e409f1 [BOT] update dependencies 2024-03-23 01:01:59 +00:00
kbz_8 c0dfcd9244 update dependencies (#57)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-03-15 15:42:44 +01:00
Kbz-8 689608b3fe [BOT] update dependencies 2024-03-09 01:00:27 +00:00
kbz_8 04330a10ac The bro did it again (#54) 2024-02-25 09:40:47 +01:00
kbz_8 a456ad15ce Merge branch 'master' into indev 2024-02-25 09:35:31 +01:00
Kbz-8 e621bb53d4 removing debug print 2024-02-25 09:30:30 +01:00
kbz_8 420ba21b4d merge to master (#53) 2024-02-25 09:15:29 +01:00
Kbz-8 f3de55d6e9 fixing issue with text destruction 2024-02-25 09:02:57 +01:00
Kbz-8 bc1e0fbba9 adding std namespace to all libstd provided primitive types 2024-02-25 08:04:44 +01:00
Kbz-8 80c0146ecd removing unecessary SDL window creation in Vulkan Instance creation 2024-02-24 04:47:05 +01:00
Kbz-8 dbe3bb3cb3 fixing weird color bug with mlx_get_image_pixel 2024-02-24 03:58:12 +01:00
kbz_8 83ecc6e498 update dependencies (#50)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-02-18 21:42:23 +01:00
Kbz-8 8b2965f6dd [BOT] update dependencies 2024-02-17 01:02:17 +00:00
kbz_8 6c31d3347a sync (#49) 2024-02-10 03:12:08 +01:00
kbz_8 7f8ec481f1 Bump peter-evans/create-pull-request from 5 to 6 (#48)
Bumps
[peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request)
from 5 to 6.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's
releases</a>.</em></p>
<blockquote>
<h2>Create Pull Request v6.0.0</h2>
<h2>Behaviour changes</h2>
<ul>
<li>The default values for <code>author</code> and
<code>committer</code> have changed. See &quot;What's new&quot; below
for details. If you are overriding the default values you will not be
affected by this change.</li>
<li>On completion, the action now removes the temporary git remote
configuration it adds when using <code>push-to-fork</code>. This should
not affect you unless you were using the temporary configuration for
some other purpose after the action completes.</li>
</ul>
<h2>What's new</h2>
<ul>
<li>Updated runtime to Node.js 20
<ul>
<li>The action now requires a minimum version of <a
href="https://github.com/actions/runner/releases/tag/v2.308.0">v2.308.0</a>
for the Actions runner. Update self-hosted runners to v2.308.0 or later
to ensure compatibility.</li>
</ul>
</li>
<li>The default value for <code>author</code> has been changed to
<code>${{ github.actor }} &lt;${{ github.actor_id }}+${{ github.actor
}}@users.noreply.github.com&gt;</code>. The change adds the <code>${{
github.actor_id }}+</code> prefix to the email address to align with
GitHub's standard format for the author email address.</li>
<li>The default value for <code>committer</code> has been changed to
<code>github-actions[bot]
&lt;41898282+github-actions[bot]@users.noreply.github.com&gt;</code>.
This is to align with the default GitHub Actions bot user account.</li>
<li>Adds input <code>git-token</code>, the <a
href="https://docs.github.com/en/github/authenticating-to-github/creating-a-personal-access-token">Personal
Access Token (PAT)</a> that the action will use for git operations. This
input defaults to the value of <code>token</code>. Use this input if you
would like the action to use a different token for git operations than
the one used for the GitHub API.</li>
<li><code>push-to-fork</code> now supports pushing to sibling
repositories in the same network.</li>
<li>Previously, when using <code>push-to-fork</code>, the action did not
remove temporary git remote configuration it adds during execution. This
has been fixed and the configuration is now removed when the action
completes.</li>
<li>If the pull request body is truncated due to exceeding the maximum
length, the action will now suffix the body with the message
&quot;...<em>[Pull request body truncated]</em>&quot; to indicate that
the body has been truncated.</li>
<li>The action now uses <code>--unshallow</code> only when necessary,
rather than as a default argument of <code>git fetch</code>. This should
improve performance, particularly for large git repositories with
extensive commit history.</li>
<li>The action can now be executed on one GitHub server and create pull
requests on a <em>different</em> GitHub server. Server products include
GitHub hosted (github.com), GitHub Enterprise Server (GHES), and GitHub
Enterprise Cloud (GHEC). For example, the action can be executed on
GitHub hosted and create pull requests on a GHES or GHEC instance.</li>
</ul>
<h2>What's Changed</h2>
<ul>
<li>Update distribution by <a
href="https://github.com/actions-bot"><code>@​actions-bot</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2086">peter-evans/create-pull-request#2086</a></li>
<li>fix crazy-max/ghaction-import-gp parameters by <a
href="https://github.com/fharper"><code>@​fharper</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2177">peter-evans/create-pull-request#2177</a></li>
<li>Update distribution by <a
href="https://github.com/actions-bot"><code>@​actions-bot</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2364">peter-evans/create-pull-request#2364</a></li>
<li>Use checkout v4 by <a
href="https://github.com/okuramasafumi"><code>@​okuramasafumi</code></a>
in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2521">peter-evans/create-pull-request#2521</a></li>
<li>Note about <code>delete-branch</code> by <a
href="https://github.com/dezren39"><code>@​dezren39</code></a> in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2631">peter-evans/create-pull-request#2631</a></li>
<li>98 dependency updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/fharper"><code>@​fharper</code></a> made
their first contribution in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2177">peter-evans/create-pull-request#2177</a></li>
<li><a
href="https://github.com/okuramasafumi"><code>@​okuramasafumi</code></a>
made their first contribution in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2521">peter-evans/create-pull-request#2521</a></li>
<li><a href="https://github.com/dezren39"><code>@​dezren39</code></a>
made their first contribution in <a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2631">peter-evans/create-pull-request#2631</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v5.0.2...v6.0.0">https://github.com/peter-evans/create-pull-request/compare/v5.0.2...v6.0.0</a></p>
<h2>Create Pull Request v5.0.2</h2>
<p>⚙️ Fixes an issue that occurs when using <code>push-to-fork</code>
and both base and head repositories are in the same org/user
account.</p>
<h2>What's Changed</h2>
<ul>
<li>fix: specify head repo by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/2044">peter-evans/create-pull-request#2044</a></li>
<li>20 dependency updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v5.0.1...v5.0.2">https://github.com/peter-evans/create-pull-request/compare/v5.0.1...v5.0.2</a></p>
<h2>Create Pull Request v5.0.1</h2>
<h2>What's Changed</h2>
<ul>
<li>fix: truncate body if exceeds max length by <a
href="https://github.com/peter-evans"><code>@​peter-evans</code></a> in
<a
href="https://redirect.github.com/peter-evans/create-pull-request/pull/1915">peter-evans/create-pull-request#1915</a></li>
<li>12 dependency updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/peter-evans/create-pull-request/compare/v5.0.0...v5.0.1">https://github.com/peter-evans/create-pull-request/compare/v5.0.0...v5.0.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/b1ddad2c994a25fbc81a28b3ec0e368bb2021c50"><code>b1ddad2</code></a>
feat: v6 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2717">#2717</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/bb809027fda03cc267431a7d36a88148eb9f3846"><code>bb80902</code></a>
build(deps-dev): bump <code>@​types/node</code> from 18.19.8 to 18.19.10
(<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2712">#2712</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/e0037d470cdeb1c8133acfba89af08639bb69eb3"><code>e0037d4</code></a>
build(deps): bump peter-evans/create-or-update-comment from 3 to 4 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2702">#2702</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/94b1f99e3a73880074d0e669c3b69d376cc8ceae"><code>94b1f99</code></a>
build(deps): bump peter-evans/find-comment from 2 to 3 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2703">#2703</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/69c27eaf4a14a67b5362a51e681f83d3d5e0f96b"><code>69c27ea</code></a>
build(deps-dev): bump ts-jest from 29.1.1 to 29.1.2 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2685">#2685</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/7ea722a0f6286a45eb3005280d83575a74bc8fef"><code>7ea722a</code></a>
build(deps-dev): bump prettier from 3.2.2 to 3.2.4 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2684">#2684</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/5ee839affd4c87811108724370a2819a40e2e5d3"><code>5ee839a</code></a>
build(deps-dev): bump <code>@​types/node</code> from 18.19.7 to 18.19.8
(<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2683">#2683</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/60fc256c678e6ed78d0d42e09675c9beba09cb94"><code>60fc256</code></a>
build(deps-dev): bump eslint-plugin-prettier from 5.1.2 to 5.1.3 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2660">#2660</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/0c677233614c017442253060c74fd2cb7ff349fc"><code>0c67723</code></a>
build(deps-dev): bump <code>@​types/node</code> from 18.19.5 to 18.19.7
(<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2661">#2661</a>)</li>
<li><a
href="https://github.com/peter-evans/create-pull-request/commit/4e288e851b95bd1362e281a255094fcc47ada675"><code>4e288e8</code></a>
build(deps-dev): bump prettier from 3.1.1 to 3.2.2 (<a
href="https://redirect.github.com/peter-evans/create-pull-request/issues/2659">#2659</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/peter-evans/create-pull-request/compare/v5...v6">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=peter-evans/create-pull-request&package-manager=github_actions&previous-version=5&new-version=6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>
2024-02-05 23:17:30 +01:00
dependabot[bot] 25bb57a973 Bump peter-evans/create-pull-request from 5 to 6
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 5 to 6.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](https://github.com/peter-evans/create-pull-request/compare/v5...v6)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-05 22:10:30 +00:00
kbz_8 39365f52a2 update dependencies (#47)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-02-02 15:21:14 +01:00
Kbz-8 fafc94248d [BOT] update dependencies 2024-02-02 01:03:23 +00:00
kbz_8 edeaff793a adding check to texture pointers (#46) 2024-01-26 12:11:47 +01:00
kbz_8 2d5758419f Merge branch 'master' into indev 2024-01-26 12:07:15 +01:00
kbz_8 ba063dae3b update dependencies (#45)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-01-26 12:01:23 +01:00
Kbz-8 e018cad851 adding check to texture pointers 2024-01-26 11:59:57 +01:00
Kbz-8 9ee8041710 [BOT] update dependencies 2024-01-26 01:04:35 +00:00
kbz_8 1b50e123c5 yes (#43) 2024-01-24 17:54:37 +01:00
kbz_8 77563b8449 Merge branch 'master' into indev 2024-01-24 17:49:53 +01:00
kbz_8 d0923320a3 yes 2024-01-24 17:49:38 +01:00
Kbz-8 d8cab7aa47 adding rule to gitignore 2024-01-20 08:54:28 +01:00
kbz_8 fcf4d3d030 improving descriptor sets and pools management (#41) 2024-01-20 08:53:13 +01:00
Kbz-8 05362905f7 improving descriptor sets and pools management 2024-01-20 08:46:50 +01:00
kbz_8 6866f2240e adding fps capper (#40) 2024-01-18 15:31:37 +01:00
kbz_8 1903104247 Merge branch 'master' into indev 2024-01-18 15:28:20 +01:00
Kbz-8 04db0a7441 adding fps capper 2024-01-18 15:25:13 +01:00
kbz_8 91cbb15b66 fixing texts allocation issues (#39) 2024-01-18 14:23:05 +01:00
kbz_8 eeded8c8bc Merge branch 'master' into indev 2024-01-18 13:59:37 +01:00
Kbz-8 58e687c952 fixing allocation issues with texts 2024-01-18 13:57:41 +01:00
Kbz-8 a0b536483a fixing shit 2024-01-17 07:41:15 +01:00
Kbz-8 de1e8ed563 i dont know chat i did i was high as f*ck 2024-01-17 05:30:38 +01:00
Kbz-8 a832c3ca40 fixing issue with swapchain recreation 2024-01-16 07:19:27 +01:00
kbz_8 575ee21c7a oh the misery (#38)
Fixed a bug and modified the example/main.c to test all mlx functions 

![image](https://github.com/seekrs/MacroLibX/assets/105780726/d9946f1f-4e97-453f-87a6-953ffd0ad52d)
2024-01-12 14:56:14 +01:00
Namonay 071bc4596b upgraded example to test all mlx functions 2024-01-12 04:25:12 +01:00
Namonay 178690cff3 Fixed mlx_mouse_move() not updating mouse position
Removed SDL_FlushEvent(SDL_MOUSEMOTION) preventing Input::update() from catching new mouse position after a mlx_mouse_move() call
2024-01-12 04:24:24 +01:00
kbz_8 1d566f74e3 Preventing some segfaults (#37)
![nerd](https://github.com/seekrs/MacroLibX/assets/105780726/74152e81-029a-4f35-afda-11e6411646bf)
2024-01-12 01:51:51 +01:00
Namonay eaa1b9afd0 Merge branch 'seekrs:indev' into indev 2024-01-12 01:28:25 +01:00
Namonay a2d40ce844 Added protections to THE bridge 2024-01-12 01:27:02 +01:00
Kbz-8 4dcdcde7d5 improving vsupp 2024-01-12 00:49:42 +01:00
kbz_8 8805f91bfd Indev (#36) 2024-01-11 15:53:39 +01:00
kbz_8 b5ca757189 Merge branch 'master' into indev 2024-01-11 15:48:15 +01:00
Kbz-8 c2d27c8434 fixing compilation error 2024-01-11 15:47:45 +01:00
Kbz-8 5f55dd9b9a fixing vsupp missing character 2024-01-11 15:46:11 +01:00
kbz_8 f044b9ab45 merge indev to master (#35) 2024-01-11 05:32:13 +01:00
kbz_8 8c6ad92f37 Merge branch 'master' into indev 2024-01-11 05:27:21 +01:00
Kbz-8 34bdb740c2 new text management, texts and textures are on the same level, new texture rendering management, fixing issues 2024-01-11 05:23:16 +01:00
Kbz-8 c485f039fb fixing color management issue with texts 2024-01-10 20:22:53 +01:00
Kbz-8 3c60e76094 adding xmake profiler option 2024-01-10 18:49:54 +01:00
kbz_8 39650b5c96 adding profiler (#34) 2024-01-10 18:48:52 +01:00
Kbz-8 0f16255240 fixing windows compilation issue 2024-01-10 18:37:14 +01:00
Kbz-8 91661fd206 adding profiler 2024-01-10 18:32:40 +01:00
kbz_8 6648bd427f Indev (#33)
Indev
2024-01-09 01:42:36 +01:00
Namonay aa2d0be63f added back not so much 'unnecesary' include 2024-01-09 01:37:01 +01:00
Namonay 2b557d5be7 removed useless includes 🤓 2024-01-09 01:28:50 +01:00
Namonay 36fae5c7d1 update buid.sh 2024-01-09 01:01:31 +01:00
Namonay 68570910e3 Fixed brief typo 2024-01-09 00:31:39 +01:00
Kbz-8 697a5e7147 fixing norme issue in the example 2024-01-09 00:25:23 +01:00
Kbz-8 31073c116c fixing issue with vulkan queues on multiple GPU computers 2024-01-08 23:50:00 +01:00
Kbz-8 c6a024d911 fixing issue with fonts vulkan descriptor destroyed 2024-01-08 22:18:45 +01:00
kbz_8 66a1b44224 Better vk commands management (#31) 2024-01-07 01:49:40 +01:00
Kbz-8 f5c581d89c figin another MacOS compilation error 2024-01-07 01:45:12 +01:00
Kbz-8 765a04d9b5 fixing compilation issues 2024-01-07 01:40:19 +01:00
Kbz-8 ac054830b9 removing gdb garbage file 2024-01-07 01:35:18 +01:00
Kbz-8 ccbd7561f4 fixing better vk command buffers management 2024-01-07 01:34:02 +01:00
kbz_8 2859725257 update dependencies (#30)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2024-01-06 14:09:23 +01:00
Kbz-8 f18cce29b3 [BOT] update dependencies 2024-01-06 01:06:21 +00:00
Kbz-8 d9a7f337ba working on cmd resources management 2024-01-05 23:13:35 +01:00
Kbz-8 f8e619ad94 fixing 32bit vulkan issue 2024-01-04 12:27:31 +01:00
kbz_8 ea6450b308 yes (#29) 2024-01-03 15:49:18 +01:00
kbz_8 6df9c284b8 Merge branch 'better_vk_commands' into indev 2024-01-03 15:47:31 +01:00
Kbz-8 d6b3f5dcc2 fixing gitignore file 2024-01-03 15:45:24 +01:00
kbz_8 826740906f merge Indev to master (#28) 2024-01-03 15:38:38 +01:00
Kbz-8 2c1f5181bf fixing compilation issue 2024-01-03 15:33:46 +01:00
Kbz-8 e728926521 fixing windows compilation issue 2024-01-03 15:30:35 +01:00
kbz_8 04af533469 Merge branch 'master' into indev 2024-01-03 15:17:17 +01:00
Kbz-8 53048bd82a improving vulkan error messages 2024-01-03 15:15:38 +01:00
Kbz-8 d0a19c5312 adding greetings 2024-01-03 00:30:45 +01:00
Kbz-8 6e284fb9bc fixing the workflows 2024-01-03 00:07:38 +01:00
Kbz-8 ea87c32051 updating license year, fixing fetch dependencies script, adding VMA auto update, removing useless dependency in xmake build 2024-01-03 00:01:30 +01:00
kbz_8 d73ade4a85 Update fetch_dependencies.yml (#27) 2024-01-02 12:04:00 +01:00
kbz_8 67bfc73066 Merge branch 'master' into indev 2024-01-02 11:56:57 +01:00
kbz_8 8b44a3aa6e Update fetch_dependencies.yml 2024-01-02 11:56:10 +01:00
kbz_8 36f9fdd53b merge Indev to master (#26) 2024-01-02 11:46:45 +01:00
kbz_8 9c43069e5f debug fetch_dependencies.yml 2024-01-02 11:28:11 +01:00
Kbz-8 0b6e1717d9 adding note to README 2023-12-31 14:34:52 +01:00
Kbz-8 41f7b4ef4c working automated dependencies updates, polishing the CI 2023-12-31 14:17:24 +01:00
kbz_8 418791930c update dependencies (#25)
Automated changes by
[create-pull-request](https://github.com/peter-evans/create-pull-request)
GitHub action
2023-12-31 13:48:27 +01:00
Kbz-8 0690ecacd8 debugging CI 2023-12-31 13:47:56 +01:00
Kbz-8 36f7efb679 update dependencies 2023-12-31 12:47:00 +00:00
Kbz-8 a52e33e697 debugging CI 2023-12-31 13:46:45 +01:00
Kbz-8 086c5402f5 debugging CI 2023-12-31 13:45:25 +01:00
Kbz-8 dd1bd43360 debugging CI 2023-12-31 13:44:37 +01:00
Kbz-8 d515ca5333 debugging CI 2023-12-31 13:41:09 +01:00
Kbz-8 eeb4695d6c debugging CI 2023-12-31 13:34:11 +01:00
Kbz-8 e94d3fd70f debugging CI 2023-12-31 13:31:22 +01:00
Kbz-8 e76f084625 debugging CI 2023-12-31 13:30:32 +01:00
Kbz-8 6e1fcb381a fixing compilation errors with local vulkan headers 2023-12-31 13:21:40 +01:00
Kbz-8 52c309a288 test automated dependencies updates 2023-12-31 13:12:37 +01:00
kbz_8 9ad28d7cf2 Kbz 8 patch 1 (#23) 2023-12-31 11:57:44 +01:00
kbz_8 5f21f0bcf9 Create dependabot.yml 2023-12-31 11:57:19 +01:00
kbz_8 066eec2cf3 merge Indev to master (#22)
yes
2023-12-31 01:41:39 +01:00
kbz_8 03e21227fa Merge branch 'master' into indev 2023-12-31 01:38:11 +01:00
Kbz-8 6f05728906 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAH x2 2023-12-31 01:30:17 +01:00
Kbz-8 5edc36393a AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAH 2023-12-31 01:27:37 +01:00
Kbz-8 af29fc7b39 I hate SDL_main on windows 2023-12-31 01:24:10 +01:00
Kbz-8 9795988e14 fuck SDL_main on windows 2023-12-31 01:14:17 +01:00
Kbz-8 4087fca980 fixing SDL issue on windows 2023-12-31 01:08:41 +01:00
Kbz-8 f3efb72a21 adding transparency support to pixel put 2023-12-28 16:59:36 +01:00
kbz_8 fc97445875 Update xmake.lua 2023-12-28 01:13:40 +01:00
Kbz-8 5babfde870 fixing issue when creating multiple mlx application with leaks in the first one 2023-12-28 01:06:03 +01:00
kbz_8 04ffce60cd adding frame capture feature (#21) 2023-12-25 16:18:42 +01:00
Kbz-8 9aaa26ddf5 fixing frame capture 2023-12-24 16:07:09 +01:00
Kbz-8 df12d08ad3 working on frame capture 2023-12-23 01:53:54 +01:00
Kbz-8 064f660852 adding possible new feature 2023-12-22 23:21:24 +01:00
Kbz-8 bf6389f9a7 adding CONTRIBUTIN.md 2023-12-22 01:24:55 +01:00
Kbz-8 cae3db0ebf fixing issue with static casts 2023-12-22 00:45:06 +01:00
Kbz-8 79b01a5007 adding error messages when using a corrupted window pointer, dropping SDL init responsability when running in sandbox 2023-12-21 00:28:53 +01:00
kbz_8 91927126f2 merge indev to master (#20) 2023-12-20 17:50:38 +01:00
kbz_8 6fb8932ba9 Merge branch 'master' into indev 2023-12-20 17:38:06 +01:00
Kbz-8 536cf4c420 working on better command buffers management 2023-12-20 16:35:52 +01:00
kbz_8 1b49794be6 Change github links to reflect organisation change (#19) 2023-12-20 01:03:42 +01:00
xtrm 25f73a6967 🐛 fix: change github links to reflect organisation change
Signed-off-by: xtrm <oss@xtrm.me>
2023-12-20 00:58:24 +01:00
kbz_8 b7424e7f92 Merge pull request #18 from 420verfl0w/errors-everywhere
Errors everywhere
2023-12-16 20:32:04 +01:00
Kbz-8 0b4b32b5ac removing GCC error 2023-12-16 20:20:51 +01:00
Kbz-8 1922b409dd adding error checks 2023-12-16 20:17:49 +01:00
Kbz-8 80e938c019 new branch for error management 2023-12-16 18:51:51 +01:00
Kbz-8 68d2c63694 fixing compilation error 2023-12-16 02:14:23 +01:00
Kbz-8 1386fe64cb updating readme 2023-12-16 02:11:54 +01:00
kbz_8 7fd0ccff94 Merge pull request #17 from 420verfl0w/indev
merge dev to master
2023-12-15 21:13:53 +01:00
Kbz-8 b28b144edb fixing issue when destroying an image in the loop hook, begenning single time command buffers manager 2023-12-15 21:08:46 +01:00
Kbz-8 8e33b2fa30 updating README 2023-12-15 18:08:22 +01:00
kbz_8 cebadef063 Merge pull request #16 from 420verfl0w/multiple-fonts
merge Multiple fonts in dev
2023-12-14 20:12:44 +01:00
kbz_8 57b27adf1a Merge branch 'indev' into multiple-fonts 2023-12-14 19:21:12 +01:00
Kbz-8 d08a97f55c adding multiple font support 2023-12-14 19:13:41 +01:00
kbz_8 c7ad6650d9 Merge pull request #15 from 420verfl0w/indev
removing buggy texture hash system
2023-12-14 14:44:10 +01:00
Kbz-8 ac91253f51 removing buggy texture hash system 2023-12-14 14:39:00 +01:00
kbz_8 3d939675e4 Merge pull request #14 from 420verfl0w/indev
merge dev to master
2023-12-14 13:56:28 +01:00
Kbz-8 11b1bd147d fixing issues with texture rendering 2023-12-14 13:51:17 +01:00
Kbz-8 c013237219 yes 2023-12-14 00:08:38 +01:00
kbz_8 8039638885 removed garbage file 2023-12-13 16:06:43 +01:00
Kbz-8 d56b224d42 working on font system 2023-12-13 00:33:34 +01:00
kbz_8 6ccf2a10d7 Merge pull request #13 from 420verfl0w/indev
Indev
2023-12-12 18:49:48 +01:00
kbz_8 cfd1aab9e3 Merge pull request #12 from 420verfl0w/macos-debug
Macos debug
2023-12-12 18:21:36 +01:00
Kbz-8 c5752f773e fixing CI 2023-12-12 18:12:41 +01:00
Kbz-8 f398126e08 fixing CI 2023-12-12 18:07:58 +01:00
Kbz-8 6c0d8829a5 macos debug 2023-12-12 18:04:27 +01:00
Kbz-8 cf3f16d832 macos debug 2023-12-12 17:58:49 +01:00
Kbz-8 b60ae54e34 macos debug 2023-12-12 17:47:10 +01:00
Kbz-8 7786b07eb8 adding message when vk res init fails 2023-12-12 15:53:57 +01:00
Kbz-8 90b1dac0f5 adding message when instance init fails 2023-12-12 15:46:47 +01:00
Kbz-8 3c52fd05f3 fixing run file and lib name on macos 2023-12-12 13:27:19 +01:00
Kbz-8 843d7f0fe2 removing unused files 2023-12-12 13:08:34 +01:00
Kbz-8 ea2014819d fxing macos libraries location issue 2023-12-12 13:08:00 +01:00
kbz_8 e458ef6401 Merge pull request #11 from 420verfl0w/indev
merge dev to master
2023-12-11 23:53:56 +01:00
kbz_8 0494ff14da Merge pull request #10 from 420verfl0w/indev
Indev
2023-12-11 20:41:15 +01:00
Kbz-8 c2c2dece61 fixing DLL API import error 2023-12-11 20:36:21 +01:00
Kbz-8 401e6d13f3 moving profile to API scope 2023-12-11 20:28:58 +01:00
kbz_8 2e5346a0ff Merge pull request #8 from 420verfl0w/vsupp-debug
Vsupp debug
2023-12-11 19:36:32 +01:00
kbz_8 ce5157a299 Merge pull request #7 from 420verfl0w/malloc-custom
improving custom malloc, removing unused code in input system
2023-12-11 19:35:38 +01:00
Kbz-8 b5ce2347f6 improving custom malloc, removing unused code in input system 2023-12-11 19:30:37 +01:00
Kbz-8 9e0a0df5ca removing error 2023-12-11 13:53:40 +01:00
Kbz-8 8f6f50c37f fixing vsupp issue, cleaning it 2023-12-11 13:40:05 +01:00
Kbz-8 c36de40f4a fixing warning issue with clang 2023-12-10 23:15:59 +01:00
Kbz-8 52ca0c0d1b suppress warnings 2023-12-10 23:12:22 +01:00
kbz_8 651a05c4bc Merge pull request #6 from 420verfl0w/indev
merge Indev to master
2023-12-09 23:41:55 +01:00
Kbz-8 1cfb8745e2 updating readmes 2023-12-09 23:33:02 +01:00
Kbz-8 b3f3a01ee6 updating readmes 2023-12-09 23:18:28 +01:00
kbz_8 4acd240737 Merge pull request #5 from 420verfl0w/indev
merge Indev to master
2023-12-09 18:13:55 +01:00
Kbz-8 b79b8da031 improving vsupp file 2023-12-09 18:02:30 +01:00
Kbz-8 bc7ef4484f improving vsupp file 2023-12-09 16:23:38 +01:00
Kbz-8 9db5515fb5 adding vsupp file 2023-12-09 15:46:32 +01:00
kbz_8 387a1f5632 Merge pull request #4 from 420verfl0w/windows-support
Merge windows support into dev
2023-12-09 13:40:45 +01:00
Kbz-8 0babc2235f Merge branch 'windows-support' of github.com:420verfl0w/MacroLibX into windows-support 2023-12-09 13:25:30 +01:00
Kbz-8 1a9a6ec6f8 adding build readme for xmake, fixing windows workflow 2023-12-09 13:24:40 +01:00
kbz_8 d59d9f285a removing exe file 2023-12-08 23:34:19 +01:00
kbz_8 d16af1c4a8 fixing windows dll issues 2023-12-08 23:33:26 +01:00
Kbz-8 5dcc2045d6 adding symbols to dll on windows 2023-12-08 19:13:25 +01:00
Kbz-8 19ce912afe adding symbols to dll on windows 2023-12-08 18:56:33 +01:00
Kbz-8 890e301b78 fixing cross compilation issue 2023-12-08 18:09:08 +01:00
Kbz-8 218a97e4ec debugging windows CI 2023-12-08 16:37:42 +01:00
Kbz-8 74e5e35f5a debugging windows CI 2023-12-08 15:57:45 +01:00
Kbz-8 e6298b1dc3 fixing syntax error in windows workflow 2023-12-08 14:48:28 +01:00
Kbz-8 df860a5a64 removing garbage files 2023-12-08 14:12:41 +01:00
Kbz-8 b22064035a adding xmake support and windows workflow 2023-12-08 14:11:48 +01:00
kbz_8 197c71021b Merge pull request #3 from 420verfl0w/indev
Merge from dev to master
2023-12-08 13:00:24 +01:00
Kbz-8 d5fa70d7ab fixing issue in 42 header 2023-12-08 12:56:59 +01:00
Kbz-8 fd8e98f1ce adding mouse wheel support 2023-12-08 12:24:20 +01:00
Kbz-8 0e10e5f8e1 removing garbage files 2023-12-07 23:20:25 +01:00
Kbz-8 689c9b3ed4 fixing memory leaks, begenning xmake support to build on windows 2023-12-07 23:19:56 +01:00
Kbz-8 ecd43dedc5 fixing weird X in logo 2023-11-25 14:26:05 +01:00
kbz_8 dea507ec0e Update README.md 2023-11-25 13:13:57 +01:00
Kbz-8 39501f2940 update logo size 2023-11-25 12:48:16 +01:00
Kbz-8 372f818da4 working on readme 2023-11-25 12:47:07 +01:00
Kbz-8 1651f9ba97 working on readme 2023-11-25 12:31:09 +01:00
Kbz-8 c7e09f1d8c adding logo 2023-11-25 12:23:57 +01:00
Kbz-8 82529d6dc9 update readme 2023-11-25 10:44:51 +01:00
Kbz-8 4e30bd02bf adding screenshot te readme 2023-11-25 10:44:24 +01:00
Kbz-8 f8c2abb20b adding screenshot te readme 2023-11-25 10:44:00 +01:00
Kbz-8 880ac98ca9 adding screenshot te readme 2023-11-25 10:43:05 +01:00
Kbz-8 49c211cebc transparency management added 2023-11-25 10:31:06 +01:00
Kbz-8 38768c85c9 improving font management 2023-11-24 19:34:15 +01:00
Kbz-8 c7433ec419 removing gdb history 2023-11-23 14:37:58 +01:00
Kbz-8 d6b6dd955c new feature, font loading 2023-11-23 14:37:42 +01:00
kbz_8 c125dde951 Update README.md 2023-11-21 07:14:32 +01:00
kbz_8 9934b34bba Update README.md 2023-11-21 07:14:08 +01:00
kbz_8 3e3f20513f moving to MIT license 2023-11-21 07:13:15 +01:00
Kbz-8 c93d7854d0 fixing compilation error 2023-11-20 07:29:36 +01:00
Kbz-8 9fdb514541 fixing spaces in indentaions 2023-11-20 07:28:03 +01:00
kbz_8 35f5f41258 fixed error message for image file loading 2023-11-18 17:57:06 +01:00
Kbz-8 f6201014aa cleaning renderpass, framebuffers and swapchain code, setting all vulkan resources to NULL after destroy 2023-11-18 17:25:30 +01:00
Kbz-8 c583f1abc8 fixing GCC warning 2023-11-16 14:07:02 +01:00
Kbz-8 f7cf64cbb9 removing a trash file 2023-11-16 14:05:16 +01:00
Kbz-8 b882771a18 removing all memory dump strings informations in release mode 2023-11-16 14:04:51 +01:00
Kbz-8 39aa8009a4 fixing memory management issue, VMA uses custom asserts 2023-11-14 12:46:51 +01:00
Kbz-8 5dce6a2c8e updating readme, improving buffer transfer to GPU 2023-11-14 07:46:06 +01:00
Kbz-8 52929e215c fixing macos warning 2023-11-14 07:22:38 +01:00
Kbz-8 ad60a17da9 fixing rendering issues 2023-11-14 07:07:43 +01:00
kbz_8 d29cd56044 removing vim command in code 2023-11-11 03:32:43 +01:00
Kbz-8 d6795f97ef fixing physical device pick issues 2023-11-11 03:30:29 +01:00
Kbz-8 2fa7e2d4a9 fixing GCC CI 2023-11-10 09:21:58 +01:00
Kbz-8 85c43dabf4 fixing compilation issues, adding profile 2023-11-10 09:19:47 +01:00
Kbz-8 e6ed390e84 working on buffers 2023-11-09 22:17:25 +01:00
Kbz-8 6cd3422337 deleting clangd garbage 2023-11-09 09:07:30 +01:00
Kbz-8 c0f539b57f adding debug messages to renderer, working on VMA implementation 2023-11-09 09:07:03 +01:00
kbz_8 497879a0bc Merge pull request #1 from 27network/feature/better-readme
Improve project's README.
2023-10-30 14:13:09 +01:00
kbz_8 5b43b47f90 Update README.md 2023-10-30 14:10:48 +01:00
xtrm ab4ebc34d5 Change the names of the workflows to look better in the README
Signed-off-by: xtrm <oss@xtrm.me>
2023-10-30 01:28:00 +01:00
killian 587e71b940 Rework README.md and add better formatting and form 2023-10-30 01:26:35 +01:00
Kbz-8 11073a2cbc debugging CI 2023-10-20 03:33:31 +02:00
Kbz-8 c1898fb8dd debugging CI 2023-10-19 23:48:00 +02:00
Kbz-8 453ee0850b debugging CI 2023-10-19 23:44:52 +02:00
Kbz-8 3dd055b406 debugging CI 2023-10-19 23:31:36 +02:00
Kbz-8 08cbbfa836 debugging CI 2023-10-19 22:58:07 +02:00
Kbz-8 ce7e3ac88d debugging CI 2023-10-19 21:38:11 +02:00
Kbz-8 cc810368aa debugging CI 2023-10-19 21:37:08 +02:00
Kbz-8 ec757ab292 debugging CI 2023-10-19 21:23:53 +02:00
Kbz-8 fc9fa1a980 debugging CI 2023-10-19 21:21:52 +02:00
Kbz-8 469716e72b debugging CI 2023-10-19 21:21:33 +02:00
Kbz-8 254f80b442 debugging CI 2023-10-19 21:20:18 +02:00
Kbz-8 4d19598ac2 debugging CI 2023-10-19 21:17:31 +02:00
Kbz-8 774f7c41b0 debugging CI 2023-10-19 21:08:10 +02:00
Kbz-8 4f8dbc794c debugging CI 2023-10-19 20:44:40 +02:00
Kbz-8 281bf2dcd2 CI 2023-10-19 20:35:17 +02:00
Kbz-8 a7ac7b2318 adding SDL initialisation and quit, improving inputs code readability 2023-08-28 10:53:22 +02:00
kbz_8 3b0442df7e Update mlx.h 2023-08-10 08:52:46 +02:00
kbz_8 6e92a3c32b Update Makefile 2023-08-10 08:46:31 +02:00
Kbz-8 aadfb7449c adding image optimizations control over make call 2023-08-09 13:51:50 +02:00
Kbz-8 c1f3e49975 adding image optimizations control over make call 2023-08-09 13:50:33 +02:00
kbz_8 e39dc7ee7e fixing get pixel image issue 2023-08-02 12:52:38 +02:00
kbz_8 a6b72fbc6f fixing performance issues 2023-08-02 12:51:04 +02:00
kbz_8 5847172049 fixing performance issues 2023-08-02 12:50:50 +02:00
Kbz-8 e98bd490b2 yes 2023-06-06 16:35:08 +02:00
kbz_8 31e08416e0 reworking texture modifiers 2023-04-25 22:14:01 +02:00
kbz_8 4edd619841 adding multiple mapping support on textures 2023-04-23 22:11:44 +02:00
kbz_8 77f707ca7a removing texture library 2023-04-21 22:17:55 +02:00
kbz_8 5f1298f9ce adding documentation to mlx.h 2023-04-19 12:36:59 +02:00
kbz_8 b71c0eafb8 fixing color bug 2023-04-19 11:51:13 +02:00
Kbz-8 39c7857ccc working on colors issue 2023-04-14 12:29:17 +02:00
Kbz-8 ff6fb56042 working input API 2023-04-12 21:53:14 +02:00
Kbz-8 0c79a0d01c fixing performance issue in text pipeline, working on event system 2023-04-12 15:15:25 +02:00
Kbz-8 34cc9d63da fixing color issues with texts 2023-04-11 23:42:27 +02:00
Kbz-8 3863bd3378 working text pipeline 2023-04-11 19:21:11 +02:00
Kbz-8 026f83ca81 working text pipeline 2023-04-11 13:21:11 +02:00
kbz_8 77d71adc1f almost fixing text rendering 2023-04-08 20:45:06 +02:00
kbz_8 b4b3bbda54 working on text render pipeline 2023-04-08 04:09:25 +02:00
Kbz-8 5f16a98d08 adding texture atlas class 2023-04-07 17:27:23 +02:00
kbz_8 f6c6b5e018 adding stb_truetype 2023-04-07 13:47:22 +02:00
Kbz-8 8ae152e67a working on text put pipeline 2023-04-06 17:26:19 +02:00
Kbz-8 66022c08fb removing xpm support bc frick xpm 2023-04-06 15:30:01 +02:00
kbz_8 0466c40242 working on xpm support 2023-04-06 12:56:36 +02:00
kbz_8 83e6ebb430 working on xpm support 2023-04-05 01:11:49 +02:00
Kbz-8 f4bf7ea6b7 working on xpm implementation 2023-04-04 15:41:45 +02:00
kbz_8 d360c8fb6a working on event system 2023-04-04 12:40:47 +02:00
kbz_8 e444856964 adding manual image manipulation 2023-04-03 00:01:13 +02:00
kbz_8 7a5e280322 adding graphics support class, refactoring the code 2023-04-02 17:37:38 +02:00
kbz_8 534bea942c adding clear window 2023-04-01 17:51:29 +02:00
kbz_8 3a93881392 working textures 2023-04-01 15:48:28 +02:00
kbz_8 e9c3fb8046 working pixel put pipeline 2023-04-01 13:03:21 +02:00
kbz_8 90c1aaad4b adding pixel put pipeline 2023-03-31 22:16:21 +02:00
Kbz-8 0aae9015a9 yes 2023-03-08 02:25:25 +01:00
Kbz-8 b170354e7f adding vulkan images, start using images for put_pixel 2023-01-25 21:46:58 +01:00
Kbz-8 659f6cc14e doing some stuff 2023-01-24 20:06:00 +01:00
Kbz-8 72d6802230 adding uniform buffers and projection matrix management in vertex shader 2023-01-24 17:27:55 +01:00
Kbz-8 4c1043ee17 adding descriptors support to renderer 2023-01-23 19:27:37 +01:00
Kbz-8 54fc452aa2 rendering 2022-12-19 17:16:50 +01:00
Kbz-8 f1e0499564 almost first rendering, fixing renderer issues 2022-12-19 00:59:45 +01:00
Kbz-8 4a67aab716 fixing compatibility, workign on renderer 2022-12-18 04:04:10 +01:00
Kbz-8 f52c4e51c9 working on window manager 2022-10-05 20:37:04 +02:00
Kbz-8 5df9b4d39f adding imputs system 2022-10-05 17:08:36 +02:00
98 changed files with 92490 additions and 162723 deletions
-1
View File
@@ -7,6 +7,5 @@ version: 2
updates:
- package-ecosystem: "github-actions" # See documentation for possible values
directory: "/" # Location of package manifests
target-branch: "indev"
schedule:
interval: "weekly"
+4 -9
View File
@@ -1,7 +1,6 @@
name: Fetch Dependencies
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * 0' # Runs weekly
@@ -11,24 +10,20 @@ jobs:
steps:
- name: Checkout Repository
uses: actions/checkout@v6
uses: actions/checkout@v4
- name: Run Fetch Dependencies Script
run: cd scripts && bash ./fetch_dependencies.sh
- name: Create Pull Request
uses: peter-evans/create-pull-request@v8
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.REPO_SCOPED_TOKEN }}
delete-branch: true
title: update dependencies
commit-message: "[BOT] update dependencies"
committer: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
author: kbJeff-8 <kbJeff-8@users.noreply.github.com>
committer: GitHub <noreply@github.com>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
signoff: false
base: indev
assignees: Kbz-8
reviewers: Kbz-8
branch: auto_deps_updates
labels: |
automated
+1 -1
View File
@@ -9,7 +9,7 @@ jobs:
issues: write
pull-requests: write
steps:
- uses: actions/first-interaction@v2
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: |
+1 -3
View File
@@ -1,8 +1,6 @@
name: Linux (clang)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
@@ -23,7 +21,7 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v6
uses: actions/checkout@v4
- name: Install system dependencies
run: |
+1 -3
View File
@@ -1,8 +1,6 @@
name: Linux (gcc)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
@@ -23,7 +21,7 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v6
uses: actions/checkout@v4
- name: Install system dependencies
run: |
-43
View File
@@ -1,43 +0,0 @@
name: Linux (meson)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-24.04]
arch: [x86_64]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get -y install mesa-common-dev clang libsdl2-2.0-0 libsdl2-dev build-essential libvulkan-dev
- name: Python
uses: actions/setup-python@v6
with:
python-version: '3.11'
- name: Install Meson with pip
run: sudo pip3 install meson
- name: Build with meson
run: |
meson build --prefix=$PWD/ --bindir='' --libdir=''
ninja install -C build
-42
View File
@@ -1,42 +0,0 @@
name: macOS (meson)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [macOS-latest]
arch: [x86_64, arm]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install system dependencies
run: |
brew install SDL2
- name: Python
uses: actions/setup-python@v6
with:
python-version: '3.11'
- name: Install Meson with pip
run: sudo pip3 install meson
- name: Build with meson
run: |
meson build --prefix=$PWD/ --bindir='' --libdir=''
ninja install -C build
@@ -1,8 +1,6 @@
name: macOS
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
@@ -16,14 +14,14 @@ jobs:
fail-fast: false
matrix:
os: [macOS-latest]
arch: [x86_64, arm]
arch: [x86_64]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
uses: actions/checkout@v4
# Install system dependencies
- name: Install Dependancies
-80
View File
@@ -1,80 +0,0 @@
name: Unit tests
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-24.04]
arch: [x86_64]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- uses: NcStudios/VulkanCI@v1.2
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get -y install mesa-common-dev clang libsdl2-2.0-0 libsdl2-dev build-essential libvulkan-dev
# Build the lib
- name: Build MacroLibX
run: make -j DEBUG=true
# Force xmake to a specific folder (for cache)
- name: Set xmake env
run: echo "XMAKE_GLOBALDIR=${{ runner.workspace }}/xmake-global" >> $GITHUB_ENV
# Install xmake
- name: Setup xmake
if: ${{ matrix.confs.plat != 'mingw' }}
uses: xmake-io/github-action-setup-xmake@v1
with:
xmake-version: latest
actions-cache-folder: .xmake-cache-W${{ steps.cache_key.outputs.key }}
# Update xmake repository (in order to have the file that will be cached)
- name: Update xmake repository
run: xmake repo --update
# Fetch xmake dephash
- name: Retrieve dependencies hash
id: dep_hash
run: echo "hash=$(xmake l utils.ci.packageskey)" >> $GITHUB_OUTPUT
- name: Install unit tester
run: git clone https://github.com/seekrs/MacroUnitTest.git ../MacroUnitTest
# Setup compilation mode and install project dependencies
- name: Configure xmake and install dependencies
run: |
cd ../MacroUnitTest
xmake config --toolchain=clang --ccache=n --yes
# Save dependencies
- name: Save cached xmake dependencies
if: ${{ !steps.restore-depcache.outputs.cache-hit }}
uses: actions/cache/save@v5
with:
path: ${{ env.XMAKE_GLOBALDIR }}/.xmake/packages
key: ${{ steps.restore-depcache.outputs.cache-primary-key }}
- name: Build and run unit tester
run: |
cd ../MacroUnitTest
xmake run MacroUnitTest --headless --path="${{ runner.workspace }}/MacroLibX/libmlx.so"
+2 -4
View File
@@ -1,8 +1,6 @@
name: Windows (xmake)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
@@ -16,7 +14,7 @@ jobs:
fail-fast: false
matrix:
os: [windows-latest]
arch: [x64, x86]
arch: [x64]
mode: [release]
runs-on: ${{ matrix.os }}
@@ -28,7 +26,7 @@ jobs:
run: echo "key=$(date +'%W')" >> $GITHUB_OUTPUT
- name: Checkout repository
uses: actions/checkout@v6
uses: actions/checkout@v4
# Force xmake to a specific folder (for cache)
- name: Set xmake env
-109
View File
@@ -1,109 +0,0 @@
name : Windows (Meson)
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
VisualStudio:
if: "!contains(github.event.head_commit.message, 'ci skip')"
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
platform: ['x64', 'x86']
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
# Install a 32-bit Python so building related stuff work.
- name: Setup x86 Python
if: matrix.platform == 'x86'
uses: actions/setup-python@v6
with:
architecture: 'x86'
python-version: '3.12'
- name: Install Meson & Ninja
run: |
python -m pip install meson ninja
- uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{matrix.platform}}
- name: Compile mlx
run: |
meson setup builddir
meson compile -C builddir
VisualStudio-clang-cl:
if: "!contains(github.event.head_commit.message, 'ci skip')"
runs-on: windows-latest
strategy:
fail-fast: false
env:
CC: clang-cl
CXX: clang-cl
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Install Meson & Ninja
run: |
python -m pip install meson ninja
- uses: ilammy/msvc-dev-cmd@v1
- name: Compile mlx
run: |
meson setup builddir
meson compile -C builddir
MSYS2:
if: "!contains(github.event.head_commit.message, 'ci skip')"
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
platform: ['UCRT64', 'CLANG64']
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: msys2/setup-msys2@v2
with:
msystem: ${{matrix.platform}}
install: >-
bison
dos2unix
flex
git
pacboy: >-
cc:p
cmake:p
ninja:p
pkgconf:p
python-certifi:p
python-pip:p
# Make sure Python is updated to >=3.11 (fix https://github.com/msys2/MINGW-packages/issues/17415).
update: true
- name: Install Meson
shell: msys2 {0}
run: |
python -m pip install meson
- name: Compile mlx
shell: msys2 {0}
run: |
meson setup builddir
meson compile -C builddir
-2
View File
@@ -23,5 +23,3 @@
objs/
build/
example/Test
subprojects/*/
subprojects/.wraplock
+1 -1
View File
@@ -1,5 +1,5 @@
MIT License
Copyright (c) 2022-2026 kbz_8
Copyright (c) 2022-2024 kbz_8
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
+10 -6
View File
@@ -4,6 +4,8 @@ MAKE = make --no-print-directory
OS ?= $(shell uname -s)
DEBUG ?= false
TOOLCHAIN ?= clang
IMAGES_OPTIMIZED ?= true
FORCE_INTEGRATED_GPU ?= false
GRAPHICS_MEMORY_DUMP ?= false
PROFILER ?= false
FORCE_WAYLAND ?= false
@@ -36,9 +38,6 @@ GCH = runtime/Includes/PreCompiled.h.gch
CCH = runtime/Includes/PreCompiled.h.pch
PCH =
# Personal path, should be overriden with env var
UNIT_TESTS_PATH = ../UnitTester/build/Bin/linux_x86_64/MacroUnitTest
NZSLC ?= nzslc
ifeq ($(TOOLCHAIN), gcc)
@@ -63,6 +62,14 @@ else
CXXFLAGS += -O3
endif
ifeq ($(FORCE_INTEGRATED_GPU), true)
_ENABLEDFLAGS += FORCE_INTEGRATED_GPU
endif
ifeq ($(IMAGES_OPTIMIZED), true)
_ENABLEDFLAGS += IMAGE_OPTIMIZED
endif
ifeq ($(GRAPHICS_MEMORY_DUMP), true)
_ENABLEDFLAGS += GRAPHICS_MEMORY_DUMP
endif
@@ -154,9 +161,6 @@ clean-shaders:
shaders: clean-shaders $(SPVS)
tests: debug
@$(UNIT_TESTS_PATH) --headless --path="./$(NAME)"
clean:
@$(RM) $(OBJ_DIR)
@printf "Cleaned $(_BOLD)$(OBJ_DIR)$(_RESET)\n"
+7 -4
View File
@@ -3,14 +3,11 @@
<div align="center">
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/linux_clang.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/linux_clang.yml/badge.svg"></a>
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/linux_gcc.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/linux_gcc.yml/badge.svg"></a>
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/macos.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/macos.yml/badge.svg"></a>
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/macos_x86.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/macos_x86.yml/badge.svg"></a>
</div>
<div align="center">
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/windows.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/windows.yml/badge.svg"></a>
</div>
<div align="center">
<a href="https://github.com/seekrs/MacroLibX/actions/workflows/tests.yml"><img src="https://github.com/seekrs/MacroLibX/actions/workflows/tests.yml/badge.svg"></a>
</div>
</div>
###### MacroLibX, a rewrite of 42 School's MiniLibX using SDL2 and Vulkan.
@@ -103,6 +100,12 @@ MacroLibX has a strong safety support, mainly by checking every pointer that you
### 🛠️ Set the toolchain
If you want to use `GCC` to build the mlx you can use `make TOOLCHAIN=gcc`
### ⚠️⚠️⚠️ 🖼️ Image optimisations ⚠️⚠️⚠️
If you run into glitches when writing or reading pixels from images you can turn off images optimisations by using `make IMAGES_OPTIMIZED=false`.
### 🖥️ Force the integrated GPU (not recommended)
You can force the mlx to use your integrated GPU by using `make FORCE_INTEGRATED_GPU=true`. Note that there are a lot of chances that your application crashes by using that.
### 💽 Dump the graphics memory
The mlx can dump it's graphics memory use to json files every two seconds by enabling this option `make GRAPHICS_MEMORY_DUMP=true`.
+7 -1
View File
@@ -16,11 +16,17 @@ MacroLibX has a strong safety support, mainly by checking every pointer that you
### 🛠️ Set the toolchain
To change the compilation toolchain you can use `xmake config --toolchain=[gcc|clang|...]`
### ⚠️⚠️⚠️ 🖼️ Image optimisations ⚠️⚠️⚠️
If you run into glitches when writing or reading pixels from images you can turn off images optimisations by using `xmake config --images_optimized=n`.
### 🖥️ Force the integrated GPU (not recommended)
You can force the mlx to use your integrated GPU using `xmake config --force_integrated_gpu=y`. Note that there are a lot of chances that your application crashes by using that.
### 💽 Dump the graphics memory
The mlx can dump it's graphics memory use to json files every two seconds by enabling this option `xmake config --graphics_memory_dump=y`.
### 🪛 A possible build configuration
As a configuration example here's how the command can look like `xmake config --mode=debug --toolchain=clang --graphics_memory_dump=y`
As a configuration example here's how the command can look like `xmake config --mode=debug --toolchain=clang --graphics_memory_dump=y --images_optimized=n`
## 🚧 Build the lib
+1
View File
@@ -7,5 +7,6 @@
-DMLX_BUILD
-DSDL_MAIN_HANDLED
-DDEBUG
-DIMAGE_OPTIMIZED
-D_REENTRANT
-isystem/usr/include/SDL2
+2 -7
View File
@@ -44,16 +44,11 @@ void update(void* param)
mlx_set_font(mlx->mlx, "default");
mlx_string_put(mlx->mlx, mlx->win, 20, 50, (mlx_color){ .rgba = 0xFFFFFFFF }, "that's a text");
int win_width;
int win_height;
mlx_get_window_size(mlx->mlx, mlx->win, &win_width, &win_height);
uint32_t color = 0;
for(int j = 0; j < win_height; j++)
for(int j = 0; j < 400; j++)
{
mlx_pixel_put(mlx->mlx, mlx->win, j, j, (mlx_color){ .rgba = 0x0000FFFF + (color << 24) });
mlx_pixel_put(mlx->mlx, mlx->win, win_width - j, j, (mlx_color){ .rgba = 0x0000FFFF });
mlx_pixel_put(mlx->mlx, mlx->win, 399 - j, j, (mlx_color){ .rgba = 0x0000FFFF });
color += (color < 255);
}
+20 -2
View File
@@ -6,7 +6,7 @@
/* By: maldavid <contact@kbz8.me> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/10/04 16:56:35 by maldavid #+# #+# */
/* Updated: 2025/10/22 16:59:21 by maldavid ### ########.fr */
/* Updated: 2025/03/12 22:26:32 by maldavid ### ########.fr */
/* */
/* ************************************************************************** */
@@ -338,7 +338,7 @@ MLX_API mlx_image mlx_new_image(mlx_context mlx, int width, int height);
* @param mlx Internal MLX application
* @param filename Path to the png file
* @param width Get the width of the image
* @param height Get the height of the image
* @param heigth Get the height of the image
*
* @return (mlx_image) An opaque handler to the internal image or MLX_NULL_HANDLE (0x0) in case of error
*/
@@ -361,6 +361,14 @@ MLX_API void mlx_destroy_image(mlx_context mlx, mlx_image image);
* @param y Y coordinate in the image
*
* @return (int) Return the pixel data
*
* /!\ If you run into glitches when writing or reading pixels from images /!\
* You need to add IMAGES_OPTIMIZED=false to your make mlx command
* ```
* ~ git clone https://github.com/seekrs/MacroLibX.git
* ~ cd MacroLibX
* ~ make IMAGES_OPTIMIZED=false
* ```
*/
MLX_API mlx_color mlx_get_image_pixel(mlx_context mlx, mlx_image image, int x, int y);
@@ -372,6 +380,14 @@ MLX_API mlx_color mlx_get_image_pixel(mlx_context mlx, mlx_image image, int x, i
* @param x X coordinate in the image
* @param y Y coordinate in the image
* @param color Color of the pixel to set
*
* /!\ If you run into glitches when writing or reading pixels from images /!\
* You need to add IMAGES_OPTIMIZED=false to your make mlx command
* ```
* ~ git clone https://github.com/seekrs/MacroLibX.git
* ~ cd MacroLibX
* ~ make IMAGES_OPTIMIZED=false
* ```
*/
MLX_API void mlx_set_image_pixel(mlx_context mlx, mlx_image image, int x, int y, mlx_color color);
@@ -407,6 +423,7 @@ MLX_API void mlx_string_put(mlx_context mlx, mlx_window win, int x, int y, mlx_c
* @brief Loads a font to be used by `mlx_string_put`
*
* @param mlx Internal MLX application
* @param win Internal window
* @param filepath Filepath to the font or "default" to reset to the embedded font
*/
MLX_API void mlx_set_font(mlx_context mlx, char* filepath);
@@ -415,6 +432,7 @@ MLX_API void mlx_set_font(mlx_context mlx, char* filepath);
* @brief Loads a font to be used by `mlx_string_put` and scales it
*
* @param mlx Internal MLX application
* @param win Internal window
* @param filepath Filepath to the font or "default" to reset to the embedded font
* @param scale Scale to apply to the font
*/
+17 -1
View File
@@ -6,7 +6,7 @@
/* By: maldavid <contact@kbz8.me> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/12/14 16:17:10 by maldavid #+# #+# */
/* Updated: 2025/10/22 16:59:38 by maldavid ### ########.fr */
/* Updated: 2025/03/12 22:03:45 by maldavid ### ########.fr */
/* */
/* ************************************************************************** */
@@ -122,6 +122,14 @@ MLX_API void mlx_pixel_put_region(mlx_context mlx, mlx_window win, int x, int y,
*
* Note: it is responsability of the user to make sure the size of `dst` is
* big enough for the given region.
*
* /!\ If you run into glitches when writing or reading pixels from images /!\
* You need to add IMAGES_OPTIMIZED=false to your make mlx command
* ```
* ~ git clone https://github.com/seekrs/MacroLibX.git
* ~ cd MacroLibX
* ~ make IMAGES_OPTIMIZED=false
* ```
*/
MLX_API void mlx_get_image_region(mlx_context mlx, mlx_image image, int x, int y, int w, int h, mlx_color* dst);
@@ -138,6 +146,14 @@ MLX_API void mlx_get_image_region(mlx_context mlx, mlx_image image, int x, int y
*
* Note: it is responsability of the user to make sure the size of `pixels` is
* big enough for the given region.
*
* /!\ If you run into glitches when writing or reading pixels from images /!\
* You need to add IMAGES_OPTIMIZED=false to your make mlx command
* ```
* ~ git clone https://github.com/seekrs/MacroLibX.git
* ~ cd MacroLibX
* ~ make IMAGES_OPTIMIZED=false
* ```
*/
MLX_API void mlx_set_image_region(mlx_context mlx, mlx_image image, int x, int y, int w, int h, mlx_color* pixels);
+2 -2
View File
@@ -6,7 +6,7 @@
/* By: maldavid <kbz_8.dev@akel-engine.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/11/10 08:49:17 by maldavid #+# #+# */
/* Updated: 2025/10/22 13:38:43 by maldavid ### ########.fr */
/* Updated: 2025/03/12 22:01:07 by maldavid ### ########.fr */
/* */
/* ************************************************************************** */
@@ -206,7 +206,7 @@
typedef void (*mlx_function)(void);
#define MLX_VERSION MLX_MAKE_VERSION(2, 2, 4)
#define MLX_VERSION MLX_MAKE_VERSION(2, 0, 0)
#define MLX_TARGET_VULKAN_API_VERSION MLX_MAKE_VERSION(1, 0, 0)
// Checking common assumptions
-107
View File
@@ -1,107 +0,0 @@
project('MacroLibX',
['c', 'cpp'],
version : '2.2.4',
license : 'MIT',
meson_version : '>= 1.9.0',
default_options : ['warning_level=2', 'optimization=3', 'cpp_std=c++20'])
add_project_arguments('-Wno-error=', language : 'c')
add_project_arguments('-fPIC', language : 'c')
add_project_arguments('-DSDL_MAIN_HANDLED', language : 'c')
if get_option('graphics_memory_dump')
add_project_arguments('-DGRAPHICS_MEMORY_DUMP', language : 'c')
endif
if get_option('profiler')
add_project_arguments('-DPROFILER_ENABLED', language : 'c')
endif
if get_option('force_wayland')
add_project_arguments('-DFORCE_WAYLAND', language : 'c')
endif
if get_option('disable_all_safeties')
add_project_arguments('-DDISABLE_ALL_SAFETIES', language : 'c')
endif
includes_directories = [
include_directories('includes'),
include_directories('runtime/Includes'),
include_directories('runtime/Sources'),
include_directories('third_party'),
]
sources = [
files(
'runtime/Sources/Core/Application.cpp',
'runtime/Sources/Core/Bridge.cpp',
'runtime/Sources/Core/EventBus.cpp',
'runtime/Sources/Core/EventListener.cpp',
'runtime/Sources/Core/Fps.cpp',
'runtime/Sources/Core/Graphics.cpp',
'runtime/Sources/Core/Logs.cpp',
'runtime/Sources/Core/Memory.cpp',
'runtime/Sources/Core/Profiler.cpp',
'runtime/Sources/Core/SDLManager.cpp',
'runtime/Sources/Core/UUID.cpp',
'runtime/Sources/Graphics/Font.cpp',
'runtime/Sources/Graphics/Mesh.cpp',
'runtime/Sources/Graphics/PutPixelManager.cpp',
'runtime/Sources/Graphics/Scene.cpp',
'runtime/Sources/Graphics/Sprite.cpp',
'runtime/Sources/Graphics/Text.cpp',
'runtime/Sources/Platform/Inputs.cpp',
'runtime/Sources/Platform/Window.cpp',
'runtime/Sources/Renderer/Pipelines/Graphics.cpp',
'runtime/Sources/Renderer/Pipelines/Shader.cpp',
'runtime/Sources/Renderer/RenderPasses/2DPass.cpp',
'runtime/Sources/Renderer/RenderPasses/FinalPass.cpp',
'runtime/Sources/Renderer/RenderPasses/Passes.cpp',
'runtime/Sources/Renderer/Vulkan/VulkanLoader.cpp',
'runtime/Sources/Renderer/Buffer.cpp',
'runtime/Sources/Renderer/Descriptor.cpp',
'runtime/Sources/Renderer/Image.cpp',
'runtime/Sources/Renderer/Memory.cpp',
'runtime/Sources/Renderer/RenderCore.cpp',
'runtime/Sources/Renderer/Renderer.cpp',
'runtime/Sources/Renderer/SceneRenderer.cpp',
'runtime/Sources/Renderer/Swapchain.cpp'
)
]
mlx_headers = [
'includes/mlx.h',
'includes/mlx_extended.h',
'includes/mlx_profile.h'
]
install_headers(mlx_headers)
deps = [
dependency('sdl2'),
]
libmlx = library('mlx',
sources,
include_directories : includes_directories,
dependencies : deps,
install : true)
libmlx_dep = declare_dependency(
include_directories: includes_directories,
dependencies : deps,
link_with : libmlx)
meson.override_dependency('mlx', libmlx_dep)
# PKG CONFIG GENERATION
pkg_mod = import('pkgconfig')
pkg_mod.generate(
libmlx,
name : 'mlx',
description : 'MacroLibX Library',
version : meson.project_version(),
subdirs : ['.'],
)
-23
View File
@@ -1,23 +0,0 @@
option('graphics_memory_dump',
type : 'boolean',
value : false,
description : 'Enable graphics memory dump for debugging purposes.'
)
option('profiler',
type : 'boolean',
value : false,
description : 'Enable profiler for performance analysis.'
)
option('force_wayland',
type : 'boolean',
value : false,
description : 'Force the application to use Wayland display server.'
)
option('disable_all_safeties',
type : 'boolean',
value : false,
description : 'Disable all safety checks in the application.'
)
+3 -1
View File
@@ -7,7 +7,9 @@ namespace mlx
{
public:
UUID();
inline operator std::uint64_t() const noexcept { return m_uuid; }
UUID(std::uint64_t uuid);
inline operator std::uint64_t() const { return m_uuid; }
private:
std::uint64_t m_uuid;
+1 -1
View File
@@ -38,7 +38,7 @@ namespace mlx
inline void UpdateDescriptorSet(std::shared_ptr<DescriptorSet> set)
{
p_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool(set->GetShaderLayout(), set->GetShaderType()).RequestDescriptorSet(set->GetShaderLayout(), set->GetShaderType());
p_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool().RequestDescriptorSet(set->GetShaderLayout(), set->GetShaderType());
}
virtual void Bind(std::size_t frame_index, VkCommandBuffer cmd) = 0;
+1 -2
View File
@@ -8,7 +8,7 @@ namespace mlx
class PutPixelManager
{
public:
PutPixelManager(NonOwningPtr<class Renderer> renderer);
PutPixelManager(NonOwningPtr<class Renderer> renderer) : p_renderer(renderer) {}
// Returns a valid pointer when a new texture has been created
NonOwningPtr<Texture> DrawPixel(int x, int y, std::uint64_t draw_layer, mlx_color color);
@@ -20,7 +20,6 @@ namespace mlx
private:
NonOwningPtr<Texture> GetLayer(std::uint64_t draw_layer, bool& is_newlayer);
std::unique_ptr<Texture> NewTexture();
private:
std::unordered_map<std::uint64_t, NonOwningPtr<Texture>> m_placements;
+2 -15
View File
@@ -17,21 +17,8 @@
#include <vulkan/vulkan.h>
#if __has_include(<SDL2/SDL.h>)
#include <SDL2/SDL.h>
#elif __has_include(<SDL.h>)
#include <SDL.h>
#else
#error Failed to find SDL2 headers
#endif
#if __has_include(<SDL2/SDL_vulkan.h>)
#include <SDL2/SDL_vulkan.h>
#elif __has_include(<SDL_vulkan.h>)
#include <SDL_vulkan.h>
#else
#error Failed to find SDL2 Vulkan headers
#endif
#include <SDL2/SDL.h>
#include <SDL2/SDL_vulkan.h>
#include <functional>
#include <memory>
+4 -3
View File
@@ -26,9 +26,9 @@ namespace mlx
std::shared_ptr<class DescriptorSet> RequestDescriptorSet(const ShaderSetLayout& layout, ShaderType shader_type);
void ReturnDescriptorSet(std::shared_ptr<class DescriptorSet> set);
bool CanAllocate(const ShaderSetLayout& layout, ShaderType shader_type) const;
[[nodiscard]] inline VkDescriptorPool Get() const noexcept { return m_pool; }
[[nodiscard]] MLX_FORCEINLINE std::size_t GetNumberOfSetsAllocated() const noexcept { return m_allocation_count; }
~DescriptorPool() = default;
@@ -36,6 +36,7 @@ namespace mlx
std::vector<std::shared_ptr<class DescriptorSet>> m_free_sets;
std::vector<std::shared_ptr<class DescriptorSet>> m_used_sets;
VkDescriptorPool m_pool;
std::size_t m_allocation_count = 0;
};
class DescriptorPoolManager
@@ -43,13 +44,13 @@ namespace mlx
public:
DescriptorPoolManager() = default;
DescriptorPool& GetAvailablePool(const ShaderSetLayout& layout, ShaderType shader_type);
DescriptorPool& GetAvailablePool();
void Destroy();
~DescriptorPoolManager() = default;
private:
std::vector<std::unique_ptr<DescriptorPool>> m_pools;
std::vector<DescriptorPool> m_pools;
};
class DescriptorSet : public std::enable_shared_from_this<DescriptorSet>
-6
View File
@@ -89,13 +89,7 @@ namespace mlx
mlx_color GetPixel(int x, int y) noexcept;
void GetRegion(int x, int y, int w, int h, mlx_color* dst) noexcept;
void Clear(VkCommandBuffer cmd, Vec4f color) override;
void CopyTo(Texture& other);
void Resize(std::uint32_t width, std::uint32_t height);
void Swap(Texture& texture) noexcept;
// If a valid cmd buffer is passed, this function takes ownership and makes it invalid after
void SyncCPUBuffer(VkCommandBuffer cmd = VK_NULL_HANDLE);
void Update(VkCommandBuffer cmd);
~Texture() override { Destroy(); }
+1 -1
View File
@@ -38,8 +38,8 @@ namespace mlx
private:
Swapchain m_swapchain;
std::vector<VkSemaphore> m_render_finished_semaphores;
std::array<VkSemaphore, MAX_FRAMES_IN_FLIGHT> m_image_available_semaphores;
std::array<VkSemaphore, MAX_FRAMES_IN_FLIGHT> m_render_finished_semaphores;
std::array<VkCommandBuffer, MAX_FRAMES_IN_FLIGHT> m_cmd_buffers;
std::array<VkFence, MAX_FRAMES_IN_FLIGHT> m_cmd_fences;
NonOwningPtr<Window> p_window;
+7 -50
View File
@@ -238,15 +238,6 @@ extern "C"
mlx::Error("Image loader: not a valid file format '%'", filename);
return nullptr;
}
{
std::ifstream stream(file, std::ios::binary);
if(!stream.is_open())
{
mlx::Error("Image loader: failed to open file '%'", filename);
return nullptr;
}
}
return mlx->app->NewStbTexture(filename, width, height);
}
@@ -313,29 +304,12 @@ extern "C"
mlx::Error("Font loader: filepath is NULL");
return;
}
std::filesystem::path file(filepath);
if (std::strcmp(filepath, "default") != 0 && !std::filesystem::exists(file))
if(std::strcmp(filepath, "default") != 0 && file.extension() != ".ttf" && file.extension() != ".tte")
{
mlx::Error("TTF loader: unable to find file '%'", filepath);
mlx::Error("TTF loader: not a truetype font file '%'", filepath);
return;
}
if(std::strcmp(filepath, "default") != 0)
{
if(file.extension() != ".ttf" && file.extension() != ".tte")
{
mlx::Error("TTF loader: not a truetype font file '%'", filepath);
return;
}
std::ifstream stream(file, std::ios::binary);
if(!stream.is_open())
{
mlx::Error("TTF loader: failed to open font file '%'", filepath);
return;
}
}
if(std::strcmp(filepath, "default") == 0)
mlx->app->LoadFont(file, 6.f);
else
@@ -350,29 +324,12 @@ extern "C"
mlx::Error("Font loader: filepath is NULL");
return;
}
std::filesystem::path file(filepath);
if (std::strcmp(filepath, "default") != 0 && !std::filesystem::exists(file))
if(std::strcmp(filepath, "default") != 0 && file.extension() != ".ttf" && file.extension() != ".tte")
{
mlx::Error("TTF loader: unable to find file '%'", filepath);
mlx::Error("TTF loader: not a truetype font file '%'", filepath);
return;
}
if(std::strcmp(filepath, "default") != 0)
{
if(file.extension() != ".ttf" && file.extension() != ".tte")
{
mlx::Error("TTF loader: not a truetype font file '%'", filepath);
return;
}
std::ifstream stream(file, std::ios::binary);
if(!stream.is_open())
{
mlx::Error("TTF loader: failed to open font file '%'", filepath);
return;
}
}
mlx->app->LoadFont(file, scale);
}
@@ -522,7 +479,7 @@ extern "C"
MLX_CHECK_APPLICATION_POINTER(mlx);
mlx::NonOwningPtr<mlx::GraphicsSupport> gs = mlx->app->GetGraphicsSupport(win);
if(!gs)
return VK_NULL_HANDLE;
return nullptr;
return gs->GetRenderer().GetSwapchain().GetSurface();
}
@@ -531,7 +488,7 @@ extern "C"
MLX_CHECK_APPLICATION_POINTER(mlx);
mlx::NonOwningPtr<mlx::GraphicsSupport> gs = mlx->app->GetGraphicsSupport(win);
if(!gs || index > gs->GetRenderer().GetSwapchain().GetImagesCount())
return VK_NULL_HANDLE;
return nullptr;
return gs->GetRenderer().GetSwapchain().GetSwapchainImages()[index].Get();
}
@@ -549,7 +506,7 @@ extern "C"
MLX_CHECK_APPLICATION_POINTER(mlx);
mlx::NonOwningPtr<mlx::GraphicsSupport> gs = mlx->app->GetGraphicsSupport(win);
if(!gs || index > gs->GetRenderer().GetSwapchain().GetImagesCount())
return VK_NULL_HANDLE;
return nullptr;
return gs->GetRenderer().GetSwapchain().GetSwapchainImages()[index].GetImageView();
}
+4 -4
View File
@@ -21,7 +21,7 @@ namespace mlx
void* MemManager::AlignedMalloc(std::size_t alignment, std::size_t size)
{
#ifdef MLX_PLAT_WINDOWS
#ifdef MLX_COMPILER_MSVC
void* ptr = _aligned_malloc(size, alignment);
#else
if(alignment < sizeof(void*))
@@ -66,7 +66,7 @@ namespace mlx
{
auto it = std::find_if(s_blocks.begin(), s_blocks.end(), [=](const Descriptor& rhs){ return ptr == rhs.ptr; });
#ifdef MLX_PLAT_WINDOWS
#ifdef MLX_COMPILER_MSVC
void* ptr2 = _aligned_realloc(ptr, size, alignment);
if(it != s_blocks.end())
s_blocks.erase(it);
@@ -90,7 +90,7 @@ namespace mlx
auto it = std::find_if(s_blocks.begin(), s_blocks.end(), [=](const Descriptor& rhs){ return ptr == rhs.ptr; });
if(it == s_blocks.end())
return;
#ifdef MLX_PLAT_WINDOWS
#ifdef MLX_COMPILER_MSVC
if(it->aligned)
_aligned_free(it->ptr);
else
@@ -105,7 +105,7 @@ namespace mlx
{
for(const Descriptor& desc : s_blocks)
{
#ifdef MLX_PLAT_WINDOWS
#ifdef MLX_COMPILER_MSVC
if(desc.aligned)
_aligned_free(desc.ptr);
else
+2 -2
View File
@@ -22,10 +22,10 @@ namespace mlx
MLX_PROFILE_FUNCTION();
s_instance = this;
m_drop_sdl_responsability = SDL_WasInit(SDL_INIT_VIDEO) || std::getenv("MLX_HEADLESS_MODE") != nullptr;
m_drop_sdl_responsability = SDL_WasInit(SDL_INIT_VIDEO);
if(m_drop_sdl_responsability) // is case the mlx is running in a sandbox like MacroUnitTester where SDL is already init
return;
//SDL_SetMemoryFunctions(MemManager::Get().Malloc, MemManager::Get().Calloc, MemManager::Get().Realloc, MemManager::Get().Free);
SDL_SetMemoryFunctions(MemManager::Get().Malloc, MemManager::Get().Calloc, MemManager::Get().Realloc, MemManager::Get().Free);
#ifdef FORCE_WAYLAND
SDL_SetHint(SDL_HINT_VIDEODRIVER, "wayland,x11");
+2 -9
View File
@@ -7,14 +7,7 @@ namespace mlx
static std::random_device random_device;
static std::mt19937_64 engine(random_device());
static std::uniform_int_distribution<std::uint64_t> uniform_distribution;
static std::unordered_set<std::uint64_t> registry;
UUID::UUID()
{
do
{
m_uuid = uniform_distribution(engine);
} while(registry.contains(m_uuid));
registry.emplace(m_uuid);
}
UUID::UUID() : m_uuid(uniform_distribution(engine)) {}
UUID::UUID(std::uint64_t uuid) : m_uuid(uuid) {}
}
+14 -41
View File
@@ -6,29 +6,6 @@
namespace mlx
{
PutPixelManager::PutPixelManager(NonOwningPtr<class Renderer> renderer) : p_renderer(renderer)
{
MLX_PROFILE_FUNCTION();
std::function<void(const EventBase&)> functor = [this](const EventBase& event)
{
// Suboptimal for multi-windows applications
if(event.What() == Event::ResizeEventCode)
{
VkExtent2D extent{ .width = 0, .height = 0 };
if(p_renderer->GetWindow())
extent = kvfGetSwapchainImagesSize(p_renderer->GetSwapchain().Get());
else if(p_renderer->GetRenderTarget())
extent = VkExtent2D{ .width = p_renderer->GetRenderTarget()->GetWidth(), .height = p_renderer->GetRenderTarget()->GetHeight() };
else
FatalError("a renderer was created without window nor render target attached (wtf!?)");
for(auto& texture : m_textures)
texture->Resize(extent.width, extent.height);
}
};
EventBus::RegisterListener({ functor, "mlx_put_pixel_manager_" + std::to_string(reinterpret_cast<std::uintptr_t>(this)) });
}
NonOwningPtr<Texture> PutPixelManager::DrawPixel(int x, int y, std::uint64_t draw_layer, mlx_color color)
{
MLX_PROFILE_FUNCTION();
@@ -76,8 +53,21 @@ namespace mlx
is_newlayer = true;
if(m_current_texture_index >= m_textures.size())
m_textures.push_back(NewTexture());
{
VkExtent2D extent{ .width = 0, .height = 0 };
if(p_renderer->GetWindow())
extent = kvfGetSwapchainImagesSize(p_renderer->GetSwapchain().Get());
else if(p_renderer->GetRenderTarget())
extent = VkExtent2D{ .width = p_renderer->GetRenderTarget()->GetWidth(), .height = p_renderer->GetRenderTarget()->GetHeight() };
else
FatalError("a renderer was created without window nor render target attached (wtf)");
#ifdef DEBUG
m_textures.push_back(std::make_unique<Texture>(CPUBuffer{}, extent.width, extent.height, VK_FORMAT_R8G8B8A8_SRGB, false, "mlx_put_pixel_layer_" + std::to_string(m_current_texture_index)));
#else
m_textures.push_back(std::make_unique<Texture>(CPUBuffer{}, extent.width, extent.height, VK_FORMAT_R8G8B8A8_SRGB, false, std::string_view{}));
#endif
}
try
{
m_placements[draw_layer] = m_textures.at(m_current_texture_index).get();
@@ -93,23 +83,6 @@ namespace mlx
}
}
std::unique_ptr<Texture> PutPixelManager::NewTexture()
{
VkExtent2D extent{ .width = 0, .height = 0 };
if(p_renderer->GetWindow())
extent = kvfGetSwapchainImagesSize(p_renderer->GetSwapchain().Get());
else if(p_renderer->GetRenderTarget())
extent = VkExtent2D{ .width = p_renderer->GetRenderTarget()->GetWidth(), .height = p_renderer->GetRenderTarget()->GetHeight() };
else
FatalError("a renderer was created without window nor render target attached (wtf!?)");
#ifdef DEBUG
return std::make_unique<Texture>(CPUBuffer{}, extent.width, extent.height, VK_FORMAT_R8G8B8A8_SRGB, false, "mlx_put_pixel_layer_" + std::to_string(m_current_texture_index));
#else
return std::make_unique<Texture>(CPUBuffer{}, extent.width, extent.height, VK_FORMAT_R8G8B8A8_SRGB, false, std::string_view{});
#endif
}
void PutPixelManager::ResetRenderData()
{
m_placements.clear();
+1 -1
View File
@@ -81,7 +81,7 @@ namespace mlx
VkCommandBuffer cmd = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
kvfBeginCommandBuffer(cmd, VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT);
kvfCopyBufferToBuffer(cmd, m_buffer, buffer.Get(), m_size, 0, 0);
kvfCopyBufferToBuffer(cmd, m_buffer, buffer.Get(), m_size);
kvfEndCommandBuffer(cmd);
VkFence fence = kvfCreateFence(RenderCore::Get().GetDevice());
kvfSubmitSingleTimeCommandBuffer(RenderCore::Get().GetDevice(), cmd, KVF_GRAPHICS_QUEUE, fence);
+17 -23
View File
@@ -9,7 +9,7 @@
namespace mlx
{
constexpr std::size_t MAX_SETS_PER_POOL = 1024;
constexpr std::size_t MAX_SETS_PER_POOL = MAX_FRAMES_IN_FLIGHT * 1024;
void TransitionImageToCorrectLayout(Image& image, VkCommandBuffer cmd)
{
@@ -26,19 +26,19 @@ namespace mlx
{
MLX_PROFILE_FUNCTION();
VkDescriptorPoolSize pool_sizes[] = {
{ VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, MAX_FRAMES_IN_FLIGHT * MAX_SETS_PER_POOL },
{ VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, MAX_FRAMES_IN_FLIGHT * MAX_SETS_PER_POOL },
{ VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, MAX_FRAMES_IN_FLIGHT * MAX_SETS_PER_POOL }
{ VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, MAX_SETS_PER_POOL },
{ VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, MAX_SETS_PER_POOL },
{ VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, MAX_SETS_PER_POOL }
};
VkDescriptorPoolCreateInfo pool_info{};
pool_info.sType = VK_STRUCTURE_TYPE_DESCRIPTOR_POOL_CREATE_INFO;
pool_info.poolSizeCount = sizeof(pool_sizes) / sizeof(pool_sizes[0]);
pool_info.pPoolSizes = pool_sizes;
pool_info.maxSets = MAX_FRAMES_IN_FLIGHT * MAX_SETS_PER_POOL;
pool_info.maxSets = MAX_SETS_PER_POOL;
pool_info.flags = 0;
kvfCheckVk(RenderCore::Get().vkCreateDescriptorPool(RenderCore::Get().GetDevice(), &pool_info, nullptr, &m_pool));
DebugLog("Vulkan: created new descriptor pool");
m_allocation_count = 0;
}
void DescriptorPool::Destroy() noexcept
@@ -52,6 +52,7 @@ namespace mlx
kvfDestroyDescriptorSetLayout(RenderCore::Get().GetDevice(), set->m_set_layout);
RenderCore::Get().vkDestroyDescriptorPool(RenderCore::Get().GetDevice(), m_pool, nullptr);
m_pool = VK_NULL_HANDLE;
m_allocation_count = 0;
m_free_sets.clear();
m_used_sets.clear();
}
@@ -102,6 +103,7 @@ namespace mlx
alloc_info.pSetLayouts = &vulkan_layout;
VkDescriptorSet vulkan_set;
kvfCheckVk(RenderCore::Get().vkAllocateDescriptorSets(RenderCore::Get().GetDevice(), &alloc_info, &vulkan_set));
m_allocation_count++;
vulkan_sets[i] = vulkan_set;
}
@@ -112,8 +114,11 @@ namespace mlx
void DescriptorPool::ReturnDescriptorSet(std::shared_ptr<DescriptorSet> set)
{
//std::size_t i = 0;
auto it = std::find_if(m_used_sets.begin(), m_used_sets.end(), [&](const std::shared_ptr<DescriptorSet>& rhs_set)
{
//i++;
//std::cout << m_used_sets.size() << " " << i << std::endl;
return set == rhs_set;
});
if(it == m_used_sets.end())
@@ -122,34 +127,23 @@ namespace mlx
m_free_sets.push_back(set);
}
bool DescriptorPool::CanAllocate(const ShaderSetLayout& layout, ShaderType shader_type) const
{
auto it = std::find_if(m_free_sets.begin(), m_free_sets.end(), [&](std::shared_ptr<DescriptorSet> set)
{
return shader_type == set->GetShaderType() && layout == set->GetShaderLayout();
});
if(it != m_free_sets.end())
return true;
return m_used_sets.size() + m_free_sets.size() < MAX_SETS_PER_POOL;
}
DescriptorPool& DescriptorPoolManager::GetAvailablePool(const ShaderSetLayout& layout, ShaderType shader_type)
DescriptorPool& DescriptorPoolManager::GetAvailablePool()
{
MLX_PROFILE_FUNCTION();
for(auto& pool : m_pools)
{
if(pool->CanAllocate(layout, shader_type))
return *pool;
if(pool.GetNumberOfSetsAllocated() < MAX_SETS_PER_POOL)
return pool;
}
m_pools.emplace_back(std::make_unique<DescriptorPool>())->Init();
return *m_pools.back();
m_pools.emplace_back().Init();
return m_pools.back();
}
void DescriptorPoolManager::Destroy()
{
MLX_PROFILE_FUNCTION();
for(auto& pool : m_pools)
pool->Destroy();
pool.Destroy();
m_pools.clear();
}
+14 -115
View File
@@ -22,9 +22,15 @@
#include <stb_image.h>
#endif
#ifdef IMAGE_OPTIMIZED
#define TILING VK_IMAGE_TILING_OPTIMAL
#else
#define TILING VK_IMAGE_TILING_LINEAR
#endif
namespace mlx
{
MLX_FORCEINLINE mlx_color ReverseColor(mlx_color color)
mlx_color ReverseColor(mlx_color color)
{
mlx_color reversed_color;
reversed_color.r = color.a;
@@ -180,7 +186,7 @@ namespace mlx
void Texture::Init(CPUBuffer pixels, std::uint32_t width, std::uint32_t height, VkFormat format, bool is_multisampled, [[maybe_unused]] std::string_view debug_name)
{
MLX_PROFILE_FUNCTION();
Image::Init(ImageType::Color, width, height, format, VK_IMAGE_TILING_OPTIMAL, VK_IMAGE_USAGE_TRANSFER_DST_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT | VK_IMAGE_USAGE_SAMPLED_BIT | VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT, is_multisampled, std::move(debug_name));
Image::Init(ImageType::Color, width, height, format, TILING, VK_IMAGE_USAGE_TRANSFER_DST_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT | VK_IMAGE_USAGE_SAMPLED_BIT | VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT, is_multisampled, std::move(debug_name));
Image::CreateImageView(VK_IMAGE_VIEW_TYPE_2D, VK_IMAGE_ASPECT_COLOR_BIT);
Image::CreateSampler();
if(pixels)
@@ -212,7 +218,7 @@ namespace mlx
void Texture::SetPixel(int x, int y, mlx_color color) noexcept
{
MLX_PROFILE_FUNCTION();
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) >= m_width || static_cast<std::uint32_t>(y) >= m_height)
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) > m_width || static_cast<std::uint32_t>(y) > m_height)
return;
if(!m_staging_buffer.has_value())
OpenCPUBuffer();
@@ -226,7 +232,7 @@ namespace mlx
void Texture::SetRegion(int x, int y, int w, int h, mlx_color* pixels) noexcept
{
MLX_PROFILE_FUNCTION();
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) >= m_width || static_cast<std::uint32_t>(y) >= m_height)
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) > m_width || static_cast<std::uint32_t>(y) > m_height)
return;
if(w < 0 || h < 0)
return;
@@ -252,7 +258,7 @@ namespace mlx
void Texture::SetLinearRegion(int x, int y, std::size_t len, mlx_color* pixels) noexcept
{
MLX_PROFILE_FUNCTION();
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) >= m_width || static_cast<std::uint32_t>(y) >= m_height)
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) > m_width || static_cast<std::uint32_t>(y) > m_height)
return;
if(!m_staging_buffer.has_value())
OpenCPUBuffer();
@@ -276,7 +282,7 @@ namespace mlx
mlx_color Texture::GetPixel(int x, int y) noexcept
{
MLX_PROFILE_FUNCTION();
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) >= m_width || static_cast<std::uint32_t>(y) >= m_height)
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) > m_width || static_cast<std::uint32_t>(y) > m_height)
return { .rgba = 0x00000000 };
if(!m_staging_buffer.has_value())
OpenCPUBuffer();
@@ -289,7 +295,7 @@ namespace mlx
void Texture::GetRegion(int x, int y, int w, int h, mlx_color* dst) noexcept
{
MLX_PROFILE_FUNCTION();
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) >= m_width || static_cast<std::uint32_t>(y) >= m_height)
if(x < 0 || y < 0 || static_cast<std::uint32_t>(x) > m_width || static_cast<std::uint32_t>(y) > m_height)
return;
if(!m_staging_buffer.has_value())
OpenCPUBuffer();
@@ -362,16 +368,8 @@ namespace mlx
m_staging_buffer->Init(BufferType::Staging, size, VK_BUFFER_USAGE_TRANSFER_SRC_BIT | VK_BUFFER_USAGE_TRANSFER_DST_BIT, {}, {});
#endif
SyncCPUBuffer();
}
void Texture::SyncCPUBuffer(VkCommandBuffer cmd)
{
if(!m_staging_buffer.has_value())
return;
VkImageLayout old_layout = m_layout;
if(cmd == VK_NULL_HANDLE)
cmd = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
VkCommandBuffer cmd = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
kvfBeginCommandBuffer(cmd, VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT);
TransitionLayout(VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, cmd);
kvfCopyImageToBuffer(cmd, m_staging_buffer->Get(), m_image, m_staging_buffer->GetOffset(), VK_IMAGE_ASPECT_COLOR_BIT, { m_width, m_height, 1 });
@@ -383,105 +381,6 @@ namespace mlx
kvfDestroyCommandBuffer(RenderCore::Get().GetDevice(), cmd);
}
void Texture::CopyTo(Texture& other)
{
VkImageLayout old_layout = m_layout;
VkImageLayout other_old_layout = other.GetLayout();
VkImageSubresourceLayers subresource{};
subresource.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT;
subresource.mipLevel = 0;
subresource.layerCount = 1;
subresource.baseArrayLayer = 0;
VkExtent3D extent{};
extent.width = m_width;
extent.height = m_height;
extent.depth = 1;
VkOffset3D offset{};
offset.x = 0;
offset.y = 0;
offset.z = 0;
VkImageCopy region{};
region.srcSubresource = subresource;
region.dstSubresource = subresource;
region.extent = extent;
region.srcOffset = offset;
region.dstOffset = offset;
VkCommandBuffer cmd = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
kvfBeginCommandBuffer(cmd, VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT);
TransitionLayout(VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, cmd);
other.TransitionLayout(VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, cmd);
kvfCopyImageToImage(cmd, m_image, m_layout, other.Get(), other.GetLayout(), 1, &region);
TransitionLayout(old_layout, cmd);
other.TransitionLayout(other_old_layout, cmd);
kvfEndCommandBuffer(cmd);
SyncCPUBuffer(cmd);
}
void Texture::Resize(std::uint32_t width, std::uint32_t height)
{
#ifdef DEBUG
Texture new_texture = Texture(CPUBuffer{}, width, height, m_format, m_is_multisampled, m_debug_name);
#else
Texture new_texture = Texture(CPUBuffer{}, width, height, m_format, m_is_multisampled, std::string_view{});
#endif
if(m_staging_buffer.has_value())
{
new_texture.OpenCPUBuffer();
new_texture.m_staging_buffer->CopyFrom(*m_staging_buffer);
}
// Suboptimal operations, should bake all of them in a single command buffer
new_texture.Clear(VK_NULL_HANDLE, Vec4f{ 0.f });
CopyTo(new_texture);
Swap(new_texture);
#ifdef DEBUG
DebugLog("Texture: resized '%'", m_debug_name);
#endif
}
void Texture::Swap(Texture& texture) noexcept
{
MLX_PROFILE_FUNCTION();
#ifdef DEBUG
std::swap(m_debug_name, texture.m_debug_name);
#endif
std::swap(m_allocation, texture.m_allocation);
std::swap(m_image, texture.m_image);
std::swap(m_image_view, texture.m_image_view);
std::swap(m_sampler, texture.m_sampler);
std::swap(m_format, texture.m_format);
std::swap(m_tiling, texture.m_tiling);
std::swap(m_layout, texture.m_layout);
std::swap(m_type, texture.m_type);
std::swap(m_width, texture.m_width);
std::swap(m_height, texture.m_height);
std::swap(m_is_multisampled, texture.m_is_multisampled);
if(m_staging_buffer.has_value() && texture.m_staging_buffer.has_value())
m_staging_buffer->Swap(*texture.m_staging_buffer);
else if(m_staging_buffer.has_value())
m_staging_buffer.reset();
else if(texture.m_staging_buffer.has_value())
texture.m_staging_buffer.reset();
m_has_been_modified = true;
texture.m_has_been_modified = true;
}
Texture* StbTextureLoad(const std::filesystem::path& file, int* w, int* h)
{
using namespace std::literals;
+17 -35
View File
@@ -55,17 +55,17 @@ namespace mlx
std::cout << std::endl;
}
void* VKAPI_PTR VulkanAllocationFunction(void*, std::size_t size, std::size_t alignment, VkSystemAllocationScope)
void* VulkanAllocationFunction(void*, std::size_t size, std::size_t alignment, VkSystemAllocationScope)
{
return MemManager::AlignedMalloc(alignment, size);
}
void* VKAPI_PTR VulkanReallocationFunction(void*, void* ptr, std::size_t size, std::size_t alignment, VkSystemAllocationScope)
void* VulkanReallocationFunction(void*, void* ptr, std::size_t size, std::size_t alignment, VkSystemAllocationScope)
{
return MemManager::AlignedRealloc(ptr, alignment, size);
}
void VKAPI_PTR VulkanFreeFunction(void*, void* ptr)
void VulkanFreeFunction(void*, void* ptr)
{
MemManager::Free(ptr);
}
@@ -87,24 +87,15 @@ namespace mlx
kvfSetValidationErrorCallback(&ValidationErrorCallback);
kvfSetValidationWarningCallback(&WarningCallback);
std::vector<const char*> instance_extensions;
VkSurfaceKHR surface = VK_NULL_HANDLE;
std::unique_ptr<Window> window;
bool is_headless = std::getenv("MLX_HEADLESS_MODE") != nullptr;
if(!is_headless)
{
mlx_window_create_info info{};
info.title = "";
info.width = 1;
info.height = 1;
window = std::make_unique<Window>(&info, true);
instance_extensions = window->GetRequiredVulkanInstanceExtentions();
#ifdef MLX_PLAT_MACOS
instance_extensions.push_back(VK_KHR_PORTABILITY_ENUMERATION_EXTENSION_NAME);
#endif
}
mlx_window_create_info info{};
info.title = "";
info.width = 1;
info.height = 1;
Window window(&info, true);
std::vector<const char*> instance_extensions = window.GetRequiredVulkanInstanceExtentions();
#ifdef MLX_PLAT_MACOS
instance_extensions.push_back(VK_KHR_PORTABILITY_ENUMERATION_EXTENSION_NAME);
#endif
m_instance = kvfCreateInstance(instance_extensions.data(), instance_extensions.size());
DebugLog("Vulkan: instance created");
@@ -112,34 +103,25 @@ namespace mlx
loader->LoadInstance(m_instance);
LoadKVFInstanceVulkanFunctionPointers();
if(!is_headless)
{
surface = window->CreateVulkanSurface(m_instance);
m_physical_device = kvfPickGoodDefaultPhysicalDevice(m_instance, surface);
}
else
m_physical_device = kvfPickGoodPhysicalDevice(m_instance, VK_NULL_HANDLE, nullptr, 0);
VkSurfaceKHR surface = window.CreateVulkanSurface(m_instance);
Verify(m_physical_device != VK_NULL_HANDLE, "Could not find a suitable physical device");
m_physical_device = kvfPickGoodDefaultPhysicalDevice(m_instance, surface);
// just for style
VkPhysicalDeviceProperties props;
vkGetPhysicalDeviceProperties(m_physical_device, &props);
DebugLog("Vulkan: physical device picked '%'", props.deviceName);
std::vector<const char*> device_extensions;
if(!is_headless)
device_extensions.push_back(VK_KHR_SWAPCHAIN_EXTENSION_NAME);
const char* device_extensions[] = { VK_KHR_SWAPCHAIN_EXTENSION_NAME };
VkPhysicalDeviceFeatures features{};
vkGetPhysicalDeviceFeatures(m_physical_device, &features);
m_device = kvfCreateDevice(m_physical_device, device_extensions.data(), device_extensions.size(), &features);
m_device = kvfCreateDevice(m_physical_device, device_extensions, sizeof(device_extensions) / sizeof(device_extensions[0]), &features);
DebugLog("Vulkan: logical device created");
loader->LoadDevice(m_device);
LoadKVFDeviceVulkanFunctionPointers();
if(surface != VK_NULL_HANDLE)
vkDestroySurfaceKHR(m_instance, surface, nullptr);
vkDestroySurfaceKHR(m_instance, surface, nullptr);
VkAllocationCallbacks callbacks;
callbacks.pUserData = nullptr;
@@ -52,8 +52,8 @@ namespace mlx
};
EventBus::RegisterListener({ functor, "mlx_2d_render_pass_" + std::to_string(reinterpret_cast<std::uintptr_t>(this)) });
p_viewer_data_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool(p_vertex_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Vertex).RequestDescriptorSet(p_vertex_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Vertex);
p_texture_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment).RequestDescriptorSet(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment);
p_viewer_data_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool().RequestDescriptorSet(p_vertex_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Vertex);
p_texture_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool().RequestDescriptorSet(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment);
p_viewer_data_buffer = std::make_shared<UniformBuffer>();
p_viewer_data_buffer->Init(sizeof(ViewerData), "mlx_2d_pass_viewer_data");
@@ -38,7 +38,7 @@ namespace mlx
};
EventBus::RegisterListener({ functor, "mlx_final_pass_" + std::to_string(reinterpret_cast<std::uintptr_t>(this)) });
p_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment).RequestDescriptorSet(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment);
p_set = RenderCore::Get().GetDescriptorPoolManager().GetAvailablePool().RequestDescriptorSet(p_fragment_shader->GetShaderLayout().set_layouts[0].second, ShaderType::Fragment);
}
void FinalPass::Pass([[maybe_unused]] Scene& scene, Renderer& renderer, Texture& render_target, NonOwningPtr<class Texture> final_target)
+18 -36
View File
@@ -20,42 +20,29 @@ namespace mlx
MLX_PROFILE_FUNCTION();
p_window = window;
m_swapchain.Init(p_window);
Init(NonOwningPtr<Texture>{ nullptr });
for(std::size_t i = 0; i < MAX_FRAMES_IN_FLIGHT; i++)
{
m_image_available_semaphores[i] = kvfCreateSemaphore(RenderCore::Get().GetDevice());
DebugLog("Vulkan: image available semaphore created");
m_render_finished_semaphores[i] = kvfCreateSemaphore(RenderCore::Get().GetDevice());
DebugLog("Vulkan: render finished semaphore created");
m_cmd_buffers[i] = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
DebugLog("Vulkan: command buffer created");
m_cmd_fences[i] = kvfCreateFence(RenderCore::Get().GetDevice());
DebugLog("Vulkan: fence created");
}
}
void Renderer::Init(NonOwningPtr<Texture> render_target)
{
MLX_PROFILE_FUNCTION();
std::function<void(const EventBase&)> functor = [this](const EventBase& event)
{
if(event.What() == Event::ResizeEventCode)
{
for(std::size_t i = 0; i < m_render_finished_semaphores.size(); i++)
{
kvfDestroySemaphore(RenderCore::Get().GetDevice(), m_render_finished_semaphores[i]);
DebugLog("Vulkan: render finished semaphore destroyed");
}
m_render_finished_semaphores.clear();
for(std::size_t i = 0; i < (p_window ? m_swapchain.GetImagesCount() : 1); i++)
{
m_render_finished_semaphores.push_back(kvfCreateSemaphore(RenderCore::Get().GetDevice()));
DebugLog("Vulkan: render finished semaphore created");
}
}
};
EventBus::RegisterListener({ functor, "mlx_renderer_" + std::to_string(reinterpret_cast<std::uintptr_t>(this)) });
if(render_target)
p_render_target = render_target;
for(std::size_t i = 0; i < (p_window ? m_swapchain.GetImagesCount() : 1); i++)
{
m_render_finished_semaphores.push_back(kvfCreateSemaphore(RenderCore::Get().GetDevice()));
DebugLog("Vulkan: render finished semaphore created");
}
p_render_target = render_target;
for(std::size_t i = 0; i < MAX_FRAMES_IN_FLIGHT; i++)
{
m_image_available_semaphores[i] = kvfCreateSemaphore(RenderCore::Get().GetDevice());
DebugLog("Vulkan: image available semaphore created");
m_render_finished_semaphores[i] = kvfCreateSemaphore(RenderCore::Get().GetDevice());
DebugLog("Vulkan: render finished semaphore created");
m_cmd_buffers[i] = kvfCreateCommandBuffer(RenderCore::Get().GetDevice());
DebugLog("Vulkan: command buffer created");
m_cmd_fences[i] = kvfCreateFence(RenderCore::Get().GetDevice());
@@ -79,15 +66,14 @@ namespace mlx
void Renderer::EndFrame()
{
MLX_PROFILE_FUNCTION();
std::size_t render_finished_index = (p_window ? m_swapchain.GetImageIndex() : 0);
VkPipelineStageFlags wait_stages[] = { VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT };
kvfEndCommandBuffer(m_cmd_buffers[m_current_frame_index]);
if(p_window)
kvfSubmitCommandBuffer(RenderCore::Get().GetDevice(), m_cmd_buffers[m_current_frame_index], KVF_GRAPHICS_QUEUE, m_render_finished_semaphores[render_finished_index], m_image_available_semaphores[m_current_frame_index], m_cmd_fences[m_current_frame_index], wait_stages);
kvfSubmitCommandBuffer(RenderCore::Get().GetDevice(), m_cmd_buffers[m_current_frame_index], KVF_GRAPHICS_QUEUE, m_render_finished_semaphores[m_current_frame_index], m_image_available_semaphores[m_current_frame_index], m_cmd_fences[m_current_frame_index], wait_stages);
else
kvfSubmitCommandBuffer(RenderCore::Get().GetDevice(), m_cmd_buffers[m_current_frame_index], KVF_GRAPHICS_QUEUE, VK_NULL_HANDLE, VK_NULL_HANDLE, m_cmd_fences[m_current_frame_index], wait_stages);
if(p_window)
m_swapchain.Present(m_render_finished_semaphores[render_finished_index]);
m_swapchain.Present(m_render_finished_semaphores[m_current_frame_index]);
m_current_frame_index = (m_current_frame_index + 1) % MAX_FRAMES_IN_FLIGHT;
}
@@ -95,16 +81,12 @@ namespace mlx
{
MLX_PROFILE_FUNCTION();
RenderCore::Get().WaitDeviceIdle();
for(std::size_t i = 0; i < m_render_finished_semaphores.size(); i++)
{
kvfDestroySemaphore(RenderCore::Get().GetDevice(), m_render_finished_semaphores[i]);
DebugLog("Vulkan: render finished semaphore destroyed");
}
m_render_finished_semaphores.clear();
for(std::size_t i = 0; i < MAX_FRAMES_IN_FLIGHT; i++)
{
kvfDestroySemaphore(RenderCore::Get().GetDevice(), m_image_available_semaphores[i]);
DebugLog("Vulkan: image available semaphore destroyed");
kvfDestroySemaphore(RenderCore::Get().GetDevice(), m_render_finished_semaphores[i]);
DebugLog("Vulkan: render finished semaphore destroyed");
kvfDestroyCommandBuffer(RenderCore::Get().GetDevice(), m_cmd_buffers[i]);
DebugLog("Vulkan: command buffer destroyed");
kvfDestroyFence(RenderCore::Get().GetDevice(), m_cmd_fences[i]);
@@ -28,10 +28,6 @@ namespace mlx
{
static inline PFN_vkVoidFunction vkGetInstanceProcAddrStub(Handle context, const char* name)
{
bool is_headless = std::getenv("MLX_HEADLESS_MODE") != nullptr;
if(is_headless && std::string_view(name).find("KHR") != std::string_view::npos)
return nullptr;
PFN_vkVoidFunction function = RenderCore::Get().vkGetInstanceProcAddr(static_cast<VkInstance>(context), name);
if(!function)
FatalError("Vulkan Loader: could not load '%'", name);
@@ -41,10 +37,6 @@ namespace mlx
static inline PFN_vkVoidFunction vkGetDeviceProcAddrStub(Handle context, const char* name)
{
bool is_headless = std::getenv("MLX_HEADLESS_MODE") != nullptr;
if(is_headless && std::string_view(name).find("KHR") != std::string_view::npos)
return nullptr;
PFN_vkVoidFunction function = RenderCore::Get().vkGetDeviceProcAddr(static_cast<VkDevice>(context), name);
if(!function)
FatalError("Vulkan Loader: could not load '%'", name);
+1 -1
View File
@@ -21,6 +21,6 @@ rm vulkan-headers.zip
# Update KVF
rm -f ../third_party/kvf.h
git clone https://git.kbz8.me/kbz_8/KVF.git ../third_party/KVF/
git clone https://github.com/Kbz-8/KVF.git ../third_party/KVF/
mv ../third_party/KVF/kvf.h ../third_party/kvf.h
rm -rf ../third_party/KVF
-15
View File
@@ -1,15 +0,0 @@
[wrap-file]
directory = SDL2-2.32.8
source_url = https://github.com/libsdl-org/SDL/releases/download/release-2.32.8/SDL2-2.32.8.tar.gz
source_filename = SDL2-2.32.8.tar.gz
source_hash = 0ca83e9c9b31e18288c7ec811108e58bac1f1bb5ec6577ad386830eac51c787e
patch_filename = sdl2_2.32.8-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/sdl2_2.32.8-1/get_patch
patch_hash = 5df17ea39ca418826db20e96bd821fa52b5718dac64b6225119fb6588c2744f0
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/sdl2_2.32.8-1/SDL2-2.32.8.tar.gz
wrapdb_version = 2.32.8-1
[provide]
sdl2 = sdl2_dep
sdl2main = sdl2main_dep
sdl2_test = sdl2_test_dep
+13 -49
View File
@@ -1,7 +1,7 @@
/***
* MIT License
*
* Copyright (c) 2023-2025 kbz_8
* Copyright (c) 2023-2024 kbz_8
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -51,7 +51,7 @@
#ifndef KBZ_8_VULKAN_FRAMEWORK_H
#define KBZ_8_VULKAN_FRAMEWORK_H
#if defined(KVF_IMPL_VK_NO_PROTOTYPES) && !defined(VK_NO_PROTOTYPES)
#ifdef KVF_IMPL_VK_NO_PROTOTYPES
#define VK_NO_PROTOTYPES
#endif
@@ -104,7 +104,6 @@ void kvfSetValidationWarningCallback(KvfErrorCallback callback);
void kvfAddLayer(const char* layer);
VkInstance kvfCreateInstance(const char** extensions_enabled, uint32_t extensions_count);
VkInstance kvfCreateInstanceNext(const char** extensions_enabled, uint32_t extensions_count, void* p_next);
void kvfDestroyInstance(VkInstance instance);
// If surfaces given to theses functions are VK_NULL_HANDLE no present queues will be searched and thus kvfQueuePresentKHR will not work
@@ -152,8 +151,6 @@ void kvfDestroySemaphore(VkDevice device, VkSemaphore semaphore);
VkImage kvfCreateImage(VkDevice device, uint32_t width, uint32_t height, VkFormat format, VkImageTiling tiling, VkImageUsageFlags usage, KvfImageType type);
void kvfCopyImageToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkImage src, size_t buffer_offset, VkImageAspectFlagBits aspect, VkExtent3D extent);
void kvfCopyImageToImage(VkCommandBuffer cmd, VkImage src, VkImageLayout src_layout, VkImage dst, VkImageLayout dst_layout, uint32_t count, const VkImageCopy* regions);
void kvfDestroyImage(VkDevice device, VkImage image);
VkImageView kvfCreateImageView(VkDevice device, VkImage image, VkFormat format, VkImageViewType type, VkImageAspectFlags aspect, int layer_count);
void kvfDestroyImageView(VkDevice device, VkImageView image_view);
@@ -162,7 +159,7 @@ VkSampler kvfCreateSampler(VkDevice device, VkFilter filters, VkSamplerAddressMo
void kvfDestroySampler(VkDevice device, VkSampler sampler);
VkBuffer kvfCreateBuffer(VkDevice device, VkBufferUsageFlags usage, VkDeviceSize size);
void kvfCopyBufferToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkBuffer src, size_t size, size_t src_offset, size_t dst_offset);
void kvfCopyBufferToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkBuffer src, size_t size);
void kvfCopyBufferToImage(VkCommandBuffer cmd, VkImage dst, VkBuffer src, size_t buffer_offset, VkImageAspectFlagBits aspect, VkExtent3D extent);
void kvfDestroyBuffer(VkDevice device, VkBuffer buffer);
@@ -238,7 +235,6 @@ VkPipeline kvfCreateGraphicsPipeline(VkDevice device, VkPipelineCache cache, VkP
void kvfDestroyPipeline(VkDevice device, VkPipeline pipeline);
void kvfCheckVk(VkResult result);
int32_t kvfFindMemoryType(VkPhysicalDevice physical_device, uint32_t type_filter, VkMemoryPropertyFlags properties);
#ifdef KVF_IMPL_VK_NO_PROTOTYPES
#ifdef KVF_DEFINE_VULKAN_FUNCTION_PROTOTYPE
@@ -378,12 +374,12 @@ int32_t kvfFindMemoryType(VkPhysicalDevice physical_device, uint32_t type_filter
#ifdef KVF_DESCRIPTOR_POOL_CAPACITY
#undef KVF_DESCRIPTOR_POOL_CAPACITY
#endif
#define KVF_DESCRIPTOR_POOL_CAPACITY 1024
#define KVF_DESCRIPTOR_POOL_CAPACITY 512
#ifdef KVF_COMMAND_POOL_CAPACITY
#undef KVF_COMMAND_POOL_CAPACITY
#endif
#define KVF_COMMAND_POOL_CAPACITY 1024
#define KVF_COMMAND_POOL_CAPACITY 512
typedef struct
{
@@ -523,19 +519,6 @@ void kvfCheckVk(VkResult result)
__kvfCheckVk(result);
}
int32_t kvfFindMemoryType(VkPhysicalDevice physical_device, uint32_t type_filter, VkMemoryPropertyFlags properties)
{
VkPhysicalDeviceMemoryProperties mem_properties;
KVF_GET_INSTANCE_FUNCTION(vkGetPhysicalDeviceMemoryProperties)(physical_device, &mem_properties);
for(int32_t i = 0; i < (int32_t)mem_properties.memoryTypeCount; i++)
{
if((type_filter & (1 << i)) && (mem_properties.memoryTypes[i].propertyFlags & properties) == properties)
return i;
}
return -1;
}
void __kvfAddDeviceToArray(VkPhysicalDevice device, int32_t graphics_queue, int32_t present_queue, int32_t compute_queue)
{
KVF_ASSERT(device != VK_NULL_HANDLE);
@@ -577,7 +560,6 @@ void __kvfCompleteDevice(VkPhysicalDevice physical, VkDevice device)
kvf_device->device = device;
kvf_device->cmd_pool = pool;
kvf_device->callbacks = NULL;
kvf_device->sets_pools = NULL;
kvf_device->sets_pools_size = 0;
kvf_device->cmd_buffers_size = 0;
@@ -1168,7 +1150,7 @@ const char* kvfVerbaliseVkResult(VkResult result)
case VK_ERROR_OUT_OF_DATE_KHR: return "A surface has changed in such a way that it is no longer compatible with the swapchain";
case VK_ERROR_INCOMPATIBLE_DISPLAY_KHR: return "The display used by a swapchain does not use the same presentable image layout";
case VK_ERROR_NATIVE_WINDOW_IN_USE_KHR: return "The requested window is already connected to a VkSurfaceKHR, or to some other non-Vulkan API";
case VK_ERROR_VALIDATION_FAILED_EXT: return "A command failed because invalid usage was detected by the implementation or a validation layer.";
case VK_ERROR_VALIDATION_FAILED_EXT: return "A validation layer found an error";
default: return "Unknown Vulkan error";
}
@@ -1312,11 +1294,6 @@ void kvfAddLayer(const char* layer)
}
VkInstance kvfCreateInstance(const char** extensions_enabled, uint32_t extensions_count)
{
return kvfCreateInstanceNext(extensions_enabled, extensions_count, NULL);
}
VkInstance kvfCreateInstanceNext(const char** extensions_enabled, uint32_t extensions_count, void* p_next)
{
VkInstance instance = VK_NULL_HANDLE;
@@ -1327,7 +1304,7 @@ VkInstance kvfCreateInstanceNext(const char** extensions_enabled, uint32_t exten
create_info.ppEnabledExtensionNames = extensions_enabled;
create_info.enabledLayerCount = 0;
create_info.ppEnabledLayerNames = NULL;
create_info.pNext = p_next;
create_info.pNext = NULL;
#if defined(VK_USE_PLATFORM_MACOS_MVK) || defined(VK_USE_PLATFORM_METAL_EXT)
create_info.flags = VK_INSTANCE_CREATE_ENUMERATE_PORTABILITY_BIT_KHR;
#else
@@ -1346,8 +1323,6 @@ VkInstance kvfCreateInstanceNext(const char** extensions_enabled, uint32_t exten
memcpy(new_extension_set, extensions_enabled, sizeof(char*) * extensions_count);
new_extension_set[extensions_count] = VK_EXT_DEBUG_UTILS_EXTENSION_NAME;
debug_create_info.pNext = p_next;
create_info.enabledExtensionCount = extensions_count + 1;
create_info.ppEnabledExtensionNames = new_extension_set;
create_info.enabledLayerCount = __kvf_extra_layers_count;
@@ -1499,6 +1474,9 @@ int32_t __kvfScorePhysicalDevice(VkPhysicalDevice device, VkSurfaceKHR surface,
if(device_props.deviceType == VK_PHYSICAL_DEVICE_TYPE_DISCRETE_GPU)
score += 1000;
if(!device_features.geometryShader)
return -1;
score += device_props.limits.maxImageDimension2D;
score += device_props.limits.maxBoundDescriptorSets;
@@ -2149,18 +2127,6 @@ void kvfCopyImageToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkImage src, size_t
KVF_GET_DEVICE_FUNCTION(vkCmdCopyImageToBuffer)(cmd, src, VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, dst, 1, &region);
}
void kvfCopyImageToImage(VkCommandBuffer cmd, VkImage src, VkImageLayout src_layout, VkImage dst, VkImageLayout dst_layout, uint32_t count, const VkImageCopy* regions)
{
KVF_ASSERT(cmd != VK_NULL_HANDLE);
KVF_ASSERT(dst != VK_NULL_HANDLE);
KVF_ASSERT(src != VK_NULL_HANDLE);
#ifdef KVF_IMPL_VK_NO_PROTOTYPES
__KvfDevice* kvf_device = __kvfGetKvfDeviceFromVkCommandBuffer(cmd);
KVF_ASSERT(kvf_device != NULL && "could not find VkDevice in registered devices");
#endif
KVF_GET_DEVICE_FUNCTION(vkCmdCopyImage)(cmd, src, src_layout, dst, dst_layout, count, regions);
}
void kvfDestroyImage(VkDevice device, VkImage image)
{
if(image == VK_NULL_HANDLE)
@@ -2311,7 +2277,7 @@ VkBuffer kvfCreateBuffer(VkDevice device, VkBufferUsageFlags usage, VkDeviceSize
return buffer;
}
void kvfCopyBufferToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkBuffer src, size_t size, size_t src_offset, size_t dst_offset)
void kvfCopyBufferToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkBuffer src, size_t size)
{
KVF_ASSERT(cmd != VK_NULL_HANDLE);
KVF_ASSERT(dst != VK_NULL_HANDLE);
@@ -2322,8 +2288,6 @@ void kvfCopyBufferToBuffer(VkCommandBuffer cmd, VkBuffer dst, VkBuffer src, size
#endif
VkBufferCopy copy_region = {};
copy_region.size = size;
copy_region.srcOffset = src_offset;
copy_region.dstOffset = dst_offset;
KVF_GET_DEVICE_FUNCTION(vkCmdCopyBuffer)(cmd, src, dst, 1, &copy_region);
}
@@ -2352,7 +2316,7 @@ void kvfCopyBufferToImage(VkCommandBuffer cmd, VkImage dst, VkBuffer src, size_t
void kvfDestroyBuffer(VkDevice device, VkBuffer buffer)
{
if(buffer == VK_NULL_HANDLE)
if(buffer != VK_NULL_HANDLE)
return;
KVF_ASSERT(device != VK_NULL_HANDLE);
__KvfDevice* kvf_device = __kvfGetKvfDeviceFromVkDevice(device);
@@ -2579,7 +2543,7 @@ VkAttachmentDescription kvfBuildAttachmentDescription(KvfImageType type, VkForma
__KvfSwapchain* kvf_swapchain = __kvfGetKvfSwapchainFromVkSwapchainKHR(swapchain);
KVF_ASSERT(kvf_swapchain != NULL);
KVF_ASSERT(kvf_swapchain->images_count != 0);
return kvfBuildAttachmentDescription(KVF_IMAGE_COLOR, kvf_swapchain->images_format, VK_IMAGE_LAYOUT_PRESENT_SRC_KHR, VK_IMAGE_LAYOUT_PRESENT_SRC_KHR, clear, VK_SAMPLE_COUNT_1_BIT);
return kvfBuildAttachmentDescription(KVF_IMAGE_COLOR, kvf_swapchain->images_format, VK_IMAGE_LAYOUT_UNDEFINED,VK_IMAGE_LAYOUT_PRESENT_SRC_KHR, clear, VK_SAMPLE_COUNT_1_BIT);
}
#endif
+23 -23
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_AV1STD_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -22,27 +22,27 @@ extern "C" {
// vulkan_video_codec_av1std is a preprocessor guard. Do not pass it to API calls.
#define vulkan_video_codec_av1std 1
#include "vulkan_video_codecs_common.h"
#define STD_VIDEO_AV1_NUM_REF_FRAMES 8U
#define STD_VIDEO_AV1_REFS_PER_FRAME 7U
#define STD_VIDEO_AV1_TOTAL_REFS_PER_FRAME 8U
#define STD_VIDEO_AV1_MAX_TILE_COLS 64U
#define STD_VIDEO_AV1_MAX_TILE_ROWS 64U
#define STD_VIDEO_AV1_MAX_SEGMENTS 8U
#define STD_VIDEO_AV1_SEG_LVL_MAX 8U
#define STD_VIDEO_AV1_PRIMARY_REF_NONE 7U
#define STD_VIDEO_AV1_SELECT_INTEGER_MV 2U
#define STD_VIDEO_AV1_SELECT_SCREEN_CONTENT_TOOLS 2U
#define STD_VIDEO_AV1_SKIP_MODE_FRAMES 2U
#define STD_VIDEO_AV1_MAX_LOOP_FILTER_STRENGTHS 4U
#define STD_VIDEO_AV1_LOOP_FILTER_ADJUSTMENTS 2U
#define STD_VIDEO_AV1_MAX_CDEF_FILTER_STRENGTHS 8U
#define STD_VIDEO_AV1_MAX_NUM_PLANES 3U
#define STD_VIDEO_AV1_GLOBAL_MOTION_PARAMS 6U
#define STD_VIDEO_AV1_MAX_NUM_Y_POINTS 14U
#define STD_VIDEO_AV1_MAX_NUM_CB_POINTS 10U
#define STD_VIDEO_AV1_MAX_NUM_CR_POINTS 10U
#define STD_VIDEO_AV1_MAX_NUM_POS_LUMA 24U
#define STD_VIDEO_AV1_MAX_NUM_POS_CHROMA 25U
#define STD_VIDEO_AV1_NUM_REF_FRAMES 8
#define STD_VIDEO_AV1_REFS_PER_FRAME 7
#define STD_VIDEO_AV1_TOTAL_REFS_PER_FRAME 8
#define STD_VIDEO_AV1_MAX_TILE_COLS 64
#define STD_VIDEO_AV1_MAX_TILE_ROWS 64
#define STD_VIDEO_AV1_MAX_SEGMENTS 8
#define STD_VIDEO_AV1_SEG_LVL_MAX 8
#define STD_VIDEO_AV1_PRIMARY_REF_NONE 7
#define STD_VIDEO_AV1_SELECT_INTEGER_MV 2
#define STD_VIDEO_AV1_SELECT_SCREEN_CONTENT_TOOLS 2
#define STD_VIDEO_AV1_SKIP_MODE_FRAMES 2
#define STD_VIDEO_AV1_MAX_LOOP_FILTER_STRENGTHS 4
#define STD_VIDEO_AV1_LOOP_FILTER_ADJUSTMENTS 2
#define STD_VIDEO_AV1_MAX_CDEF_FILTER_STRENGTHS 8
#define STD_VIDEO_AV1_MAX_NUM_PLANES 3
#define STD_VIDEO_AV1_GLOBAL_MOTION_PARAMS 6
#define STD_VIDEO_AV1_MAX_NUM_Y_POINTS 14
#define STD_VIDEO_AV1_MAX_NUM_CB_POINTS 10
#define STD_VIDEO_AV1_MAX_NUM_CR_POINTS 10
#define STD_VIDEO_AV1_MAX_NUM_POS_LUMA 24
#define STD_VIDEO_AV1_MAX_NUM_POS_CHROMA 25
typedef enum StdVideoAV1Profile {
STD_VIDEO_AV1_PROFILE_MAIN = 0,
@@ -144,7 +144,7 @@ typedef enum StdVideoAV1ColorPrimaries {
STD_VIDEO_AV1_COLOR_PRIMARIES_SMPTE_432 = 12,
STD_VIDEO_AV1_COLOR_PRIMARIES_EBU_3213 = 22,
STD_VIDEO_AV1_COLOR_PRIMARIES_INVALID = 0x7FFFFFFF,
// STD_VIDEO_AV1_COLOR_PRIMARIES_BT_UNSPECIFIED is a legacy alias
// STD_VIDEO_AV1_COLOR_PRIMARIES_BT_UNSPECIFIED is a deprecated alias
STD_VIDEO_AV1_COLOR_PRIMARIES_BT_UNSPECIFIED = STD_VIDEO_AV1_COLOR_PRIMARIES_UNSPECIFIED,
STD_VIDEO_AV1_COLOR_PRIMARIES_MAX_ENUM = 0x7FFFFFFF
} StdVideoAV1ColorPrimaries;
+1 -1
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_AV1STD_DECODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
+1 -1
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_AV1STD_ENCODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
+9 -9
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H264STD_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -22,14 +22,14 @@ extern "C" {
// vulkan_video_codec_h264std is a preprocessor guard. Do not pass it to API calls.
#define vulkan_video_codec_h264std 1
#include "vulkan_video_codecs_common.h"
#define STD_VIDEO_H264_CPB_CNT_LIST_SIZE 32U
#define STD_VIDEO_H264_SCALING_LIST_4X4_NUM_LISTS 6U
#define STD_VIDEO_H264_SCALING_LIST_4X4_NUM_ELEMENTS 16U
#define STD_VIDEO_H264_SCALING_LIST_8X8_NUM_LISTS 6U
#define STD_VIDEO_H264_SCALING_LIST_8X8_NUM_ELEMENTS 64U
#define STD_VIDEO_H264_MAX_NUM_LIST_REF 32U
#define STD_VIDEO_H264_MAX_CHROMA_PLANES 2U
#define STD_VIDEO_H264_NO_REFERENCE_PICTURE 0xFFU
#define STD_VIDEO_H264_CPB_CNT_LIST_SIZE 32
#define STD_VIDEO_H264_SCALING_LIST_4X4_NUM_LISTS 6
#define STD_VIDEO_H264_SCALING_LIST_4X4_NUM_ELEMENTS 16
#define STD_VIDEO_H264_SCALING_LIST_8X8_NUM_LISTS 6
#define STD_VIDEO_H264_SCALING_LIST_8X8_NUM_ELEMENTS 64
#define STD_VIDEO_H264_MAX_NUM_LIST_REF 32
#define STD_VIDEO_H264_MAX_CHROMA_PLANES 2
#define STD_VIDEO_H264_NO_REFERENCE_PICTURE 0xFF
typedef enum StdVideoH264ChromaFormatIdc {
STD_VIDEO_H264_CHROMA_FORMAT_IDC_MONOCHROME = 0,
+2 -2
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H264STD_DECODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -27,7 +27,7 @@ extern "C" {
#define VK_STD_VULKAN_VIDEO_CODEC_H264_DECODE_SPEC_VERSION VK_STD_VULKAN_VIDEO_CODEC_H264_DECODE_API_VERSION_1_0_0
#define VK_STD_VULKAN_VIDEO_CODEC_H264_DECODE_EXTENSION_NAME "VK_STD_vulkan_video_codec_h264_decode"
#define STD_VIDEO_DECODE_H264_FIELD_ORDER_COUNT_LIST_SIZE 2U
#define STD_VIDEO_DECODE_H264_FIELD_ORDER_COUNT_LIST_SIZE 2
typedef enum StdVideoDecodeH264FieldOrderCount {
STD_VIDEO_DECODE_H264_FIELD_ORDER_COUNT_TOP = 0,
+1 -1
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H264STD_ENCODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
+24 -24
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H265STD_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -22,29 +22,29 @@ extern "C" {
// vulkan_video_codec_h265std is a preprocessor guard. Do not pass it to API calls.
#define vulkan_video_codec_h265std 1
#include "vulkan_video_codecs_common.h"
#define STD_VIDEO_H265_CPB_CNT_LIST_SIZE 32U
#define STD_VIDEO_H265_SUBLAYERS_LIST_SIZE 7U
#define STD_VIDEO_H265_SCALING_LIST_4X4_NUM_LISTS 6U
#define STD_VIDEO_H265_SCALING_LIST_4X4_NUM_ELEMENTS 16U
#define STD_VIDEO_H265_SCALING_LIST_8X8_NUM_LISTS 6U
#define STD_VIDEO_H265_SCALING_LIST_8X8_NUM_ELEMENTS 64U
#define STD_VIDEO_H265_SCALING_LIST_16X16_NUM_LISTS 6U
#define STD_VIDEO_H265_SCALING_LIST_16X16_NUM_ELEMENTS 64U
#define STD_VIDEO_H265_SCALING_LIST_32X32_NUM_LISTS 2U
#define STD_VIDEO_H265_SCALING_LIST_32X32_NUM_ELEMENTS 64U
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_LIST_SIZE 6U
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_TILE_COLS_LIST_SIZE 19U
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_TILE_ROWS_LIST_SIZE 21U
#define STD_VIDEO_H265_PREDICTOR_PALETTE_COMPONENTS_LIST_SIZE 3U
#define STD_VIDEO_H265_PREDICTOR_PALETTE_COMP_ENTRIES_LIST_SIZE 128U
#define STD_VIDEO_H265_MAX_NUM_LIST_REF 15U
#define STD_VIDEO_H265_MAX_CHROMA_PLANES 2U
#define STD_VIDEO_H265_MAX_SHORT_TERM_REF_PIC_SETS 64U
#define STD_VIDEO_H265_MAX_DPB_SIZE 16U
#define STD_VIDEO_H265_MAX_LONG_TERM_REF_PICS_SPS 32U
#define STD_VIDEO_H265_MAX_LONG_TERM_PICS 16U
#define STD_VIDEO_H265_MAX_DELTA_POC 48U
#define STD_VIDEO_H265_NO_REFERENCE_PICTURE 0xFFU
#define STD_VIDEO_H265_CPB_CNT_LIST_SIZE 32
#define STD_VIDEO_H265_SUBLAYERS_LIST_SIZE 7
#define STD_VIDEO_H265_SCALING_LIST_4X4_NUM_LISTS 6
#define STD_VIDEO_H265_SCALING_LIST_4X4_NUM_ELEMENTS 16
#define STD_VIDEO_H265_SCALING_LIST_8X8_NUM_LISTS 6
#define STD_VIDEO_H265_SCALING_LIST_8X8_NUM_ELEMENTS 64
#define STD_VIDEO_H265_SCALING_LIST_16X16_NUM_LISTS 6
#define STD_VIDEO_H265_SCALING_LIST_16X16_NUM_ELEMENTS 64
#define STD_VIDEO_H265_SCALING_LIST_32X32_NUM_LISTS 2
#define STD_VIDEO_H265_SCALING_LIST_32X32_NUM_ELEMENTS 64
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_LIST_SIZE 6
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_TILE_COLS_LIST_SIZE 19
#define STD_VIDEO_H265_CHROMA_QP_OFFSET_TILE_ROWS_LIST_SIZE 21
#define STD_VIDEO_H265_PREDICTOR_PALETTE_COMPONENTS_LIST_SIZE 3
#define STD_VIDEO_H265_PREDICTOR_PALETTE_COMP_ENTRIES_LIST_SIZE 128
#define STD_VIDEO_H265_MAX_NUM_LIST_REF 15
#define STD_VIDEO_H265_MAX_CHROMA_PLANES 2
#define STD_VIDEO_H265_MAX_SHORT_TERM_REF_PIC_SETS 64
#define STD_VIDEO_H265_MAX_DPB_SIZE 16
#define STD_VIDEO_H265_MAX_LONG_TERM_REF_PICS_SPS 32
#define STD_VIDEO_H265_MAX_LONG_TERM_PICS 16
#define STD_VIDEO_H265_MAX_DELTA_POC 48
#define STD_VIDEO_H265_NO_REFERENCE_PICTURE 0xFF
typedef enum StdVideoH265ChromaFormatIdc {
STD_VIDEO_H265_CHROMA_FORMAT_IDC_MONOCHROME = 0,
+2 -2
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H265STD_DECODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -27,7 +27,7 @@ extern "C" {
#define VK_STD_VULKAN_VIDEO_CODEC_H265_DECODE_SPEC_VERSION VK_STD_VULKAN_VIDEO_CODEC_H265_DECODE_API_VERSION_1_0_0
#define VK_STD_VULKAN_VIDEO_CODEC_H265_DECODE_EXTENSION_NAME "VK_STD_vulkan_video_codec_h265_decode"
#define STD_VIDEO_DECODE_H265_REF_PIC_SET_LIST_SIZE 8U
#define STD_VIDEO_DECODE_H265_REF_PIC_SET_LIST_SIZE 8
typedef struct StdVideoDecodeH265PictureInfoFlags {
uint32_t IrapPicFlag : 1;
uint32_t IdrPicFlag : 1;
+1 -1
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODEC_H265STD_ENCODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
-151
View File
@@ -1,151 +0,0 @@
#ifndef VULKAN_VIDEO_CODEC_VP9STD_H_
#define VULKAN_VIDEO_CODEC_VP9STD_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
/*
** This header is generated from the Khronos Vulkan XML API Registry.
**
*/
#ifdef __cplusplus
extern "C" {
#endif
// vulkan_video_codec_vp9std is a preprocessor guard. Do not pass it to API calls.
#define vulkan_video_codec_vp9std 1
#include "vulkan_video_codecs_common.h"
#define STD_VIDEO_VP9_NUM_REF_FRAMES 8U
#define STD_VIDEO_VP9_REFS_PER_FRAME 3U
#define STD_VIDEO_VP9_MAX_REF_FRAMES 4U
#define STD_VIDEO_VP9_LOOP_FILTER_ADJUSTMENTS 2U
#define STD_VIDEO_VP9_MAX_SEGMENTS 8U
#define STD_VIDEO_VP9_SEG_LVL_MAX 4U
#define STD_VIDEO_VP9_MAX_SEGMENTATION_TREE_PROBS 7U
#define STD_VIDEO_VP9_MAX_SEGMENTATION_PRED_PROB 3U
typedef enum StdVideoVP9Profile {
STD_VIDEO_VP9_PROFILE_0 = 0,
STD_VIDEO_VP9_PROFILE_1 = 1,
STD_VIDEO_VP9_PROFILE_2 = 2,
STD_VIDEO_VP9_PROFILE_3 = 3,
STD_VIDEO_VP9_PROFILE_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_PROFILE_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9Profile;
typedef enum StdVideoVP9Level {
STD_VIDEO_VP9_LEVEL_1_0 = 0,
STD_VIDEO_VP9_LEVEL_1_1 = 1,
STD_VIDEO_VP9_LEVEL_2_0 = 2,
STD_VIDEO_VP9_LEVEL_2_1 = 3,
STD_VIDEO_VP9_LEVEL_3_0 = 4,
STD_VIDEO_VP9_LEVEL_3_1 = 5,
STD_VIDEO_VP9_LEVEL_4_0 = 6,
STD_VIDEO_VP9_LEVEL_4_1 = 7,
STD_VIDEO_VP9_LEVEL_5_0 = 8,
STD_VIDEO_VP9_LEVEL_5_1 = 9,
STD_VIDEO_VP9_LEVEL_5_2 = 10,
STD_VIDEO_VP9_LEVEL_6_0 = 11,
STD_VIDEO_VP9_LEVEL_6_1 = 12,
STD_VIDEO_VP9_LEVEL_6_2 = 13,
STD_VIDEO_VP9_LEVEL_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_LEVEL_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9Level;
typedef enum StdVideoVP9FrameType {
STD_VIDEO_VP9_FRAME_TYPE_KEY = 0,
STD_VIDEO_VP9_FRAME_TYPE_NON_KEY = 1,
STD_VIDEO_VP9_FRAME_TYPE_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_FRAME_TYPE_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9FrameType;
typedef enum StdVideoVP9ReferenceName {
STD_VIDEO_VP9_REFERENCE_NAME_INTRA_FRAME = 0,
STD_VIDEO_VP9_REFERENCE_NAME_LAST_FRAME = 1,
STD_VIDEO_VP9_REFERENCE_NAME_GOLDEN_FRAME = 2,
STD_VIDEO_VP9_REFERENCE_NAME_ALTREF_FRAME = 3,
STD_VIDEO_VP9_REFERENCE_NAME_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_REFERENCE_NAME_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9ReferenceName;
typedef enum StdVideoVP9InterpolationFilter {
STD_VIDEO_VP9_INTERPOLATION_FILTER_EIGHTTAP = 0,
STD_VIDEO_VP9_INTERPOLATION_FILTER_EIGHTTAP_SMOOTH = 1,
STD_VIDEO_VP9_INTERPOLATION_FILTER_EIGHTTAP_SHARP = 2,
STD_VIDEO_VP9_INTERPOLATION_FILTER_BILINEAR = 3,
STD_VIDEO_VP9_INTERPOLATION_FILTER_SWITCHABLE = 4,
STD_VIDEO_VP9_INTERPOLATION_FILTER_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_INTERPOLATION_FILTER_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9InterpolationFilter;
typedef enum StdVideoVP9ColorSpace {
STD_VIDEO_VP9_COLOR_SPACE_UNKNOWN = 0,
STD_VIDEO_VP9_COLOR_SPACE_BT_601 = 1,
STD_VIDEO_VP9_COLOR_SPACE_BT_709 = 2,
STD_VIDEO_VP9_COLOR_SPACE_SMPTE_170 = 3,
STD_VIDEO_VP9_COLOR_SPACE_SMPTE_240 = 4,
STD_VIDEO_VP9_COLOR_SPACE_BT_2020 = 5,
STD_VIDEO_VP9_COLOR_SPACE_RESERVED = 6,
STD_VIDEO_VP9_COLOR_SPACE_RGB = 7,
STD_VIDEO_VP9_COLOR_SPACE_INVALID = 0x7FFFFFFF,
STD_VIDEO_VP9_COLOR_SPACE_MAX_ENUM = 0x7FFFFFFF
} StdVideoVP9ColorSpace;
typedef struct StdVideoVP9ColorConfigFlags {
uint32_t color_range : 1;
uint32_t reserved : 31;
} StdVideoVP9ColorConfigFlags;
typedef struct StdVideoVP9ColorConfig {
StdVideoVP9ColorConfigFlags flags;
uint8_t BitDepth;
uint8_t subsampling_x;
uint8_t subsampling_y;
uint8_t reserved1;
StdVideoVP9ColorSpace color_space;
} StdVideoVP9ColorConfig;
typedef struct StdVideoVP9LoopFilterFlags {
uint32_t loop_filter_delta_enabled : 1;
uint32_t loop_filter_delta_update : 1;
uint32_t reserved : 30;
} StdVideoVP9LoopFilterFlags;
typedef struct StdVideoVP9LoopFilter {
StdVideoVP9LoopFilterFlags flags;
uint8_t loop_filter_level;
uint8_t loop_filter_sharpness;
uint8_t update_ref_delta;
int8_t loop_filter_ref_deltas[STD_VIDEO_VP9_MAX_REF_FRAMES];
uint8_t update_mode_delta;
int8_t loop_filter_mode_deltas[STD_VIDEO_VP9_LOOP_FILTER_ADJUSTMENTS];
} StdVideoVP9LoopFilter;
typedef struct StdVideoVP9SegmentationFlags {
uint32_t segmentation_update_map : 1;
uint32_t segmentation_temporal_update : 1;
uint32_t segmentation_update_data : 1;
uint32_t segmentation_abs_or_delta_update : 1;
uint32_t reserved : 28;
} StdVideoVP9SegmentationFlags;
typedef struct StdVideoVP9Segmentation {
StdVideoVP9SegmentationFlags flags;
uint8_t segmentation_tree_probs[STD_VIDEO_VP9_MAX_SEGMENTATION_TREE_PROBS];
uint8_t segmentation_pred_prob[STD_VIDEO_VP9_MAX_SEGMENTATION_PRED_PROB];
uint8_t FeatureEnabled[STD_VIDEO_VP9_MAX_SEGMENTS];
int16_t FeatureData[STD_VIDEO_VP9_MAX_SEGMENTS][STD_VIDEO_VP9_SEG_LVL_MAX];
} StdVideoVP9Segmentation;
#ifdef __cplusplus
}
#endif
#endif
-68
View File
@@ -1,68 +0,0 @@
#ifndef VULKAN_VIDEO_CODEC_VP9STD_DECODE_H_
#define VULKAN_VIDEO_CODEC_VP9STD_DECODE_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
/*
** This header is generated from the Khronos Vulkan XML API Registry.
**
*/
#ifdef __cplusplus
extern "C" {
#endif
// vulkan_video_codec_vp9std_decode is a preprocessor guard. Do not pass it to API calls.
#define vulkan_video_codec_vp9std_decode 1
#include "vulkan_video_codec_vp9std.h"
#define VK_STD_VULKAN_VIDEO_CODEC_VP9_DECODE_API_VERSION_1_0_0 VK_MAKE_VIDEO_STD_VERSION(1, 0, 0)
#define VK_STD_VULKAN_VIDEO_CODEC_VP9_DECODE_SPEC_VERSION VK_STD_VULKAN_VIDEO_CODEC_VP9_DECODE_API_VERSION_1_0_0
#define VK_STD_VULKAN_VIDEO_CODEC_VP9_DECODE_EXTENSION_NAME "VK_STD_vulkan_video_codec_vp9_decode"
typedef struct StdVideoDecodeVP9PictureInfoFlags {
uint32_t error_resilient_mode : 1;
uint32_t intra_only : 1;
uint32_t allow_high_precision_mv : 1;
uint32_t refresh_frame_context : 1;
uint32_t frame_parallel_decoding_mode : 1;
uint32_t segmentation_enabled : 1;
uint32_t show_frame : 1;
uint32_t UsePrevFrameMvs : 1;
uint32_t reserved : 24;
} StdVideoDecodeVP9PictureInfoFlags;
typedef struct StdVideoDecodeVP9PictureInfo {
StdVideoDecodeVP9PictureInfoFlags flags;
StdVideoVP9Profile profile;
StdVideoVP9FrameType frame_type;
uint8_t frame_context_idx;
uint8_t reset_frame_context;
uint8_t refresh_frame_flags;
uint8_t ref_frame_sign_bias_mask;
StdVideoVP9InterpolationFilter interpolation_filter;
uint8_t base_q_idx;
int8_t delta_q_y_dc;
int8_t delta_q_uv_dc;
int8_t delta_q_uv_ac;
uint8_t tile_cols_log2;
uint8_t tile_rows_log2;
uint16_t reserved1[3];
const StdVideoVP9ColorConfig* pColorConfig;
const StdVideoVP9LoopFilter* pLoopFilter;
const StdVideoVP9Segmentation* pSegmentation;
} StdVideoDecodeVP9PictureInfo;
#ifdef __cplusplus
}
#endif
#endif
+1 -1
View File
@@ -2,7 +2,7 @@
#define VULKAN_VIDEO_CODECS_COMMON_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
+349 -768
View File
File diff suppressed because it is too large Load Diff
+1 -2
View File
@@ -44,9 +44,8 @@
typedef VkResult(VKAPI_PTR *PFN_vkNegotiateLoaderICDInterfaceVersion)(uint32_t *pVersion);
// This is defined in vk_layer.h which will be found by the loader, but if an ICD is building against this
// file directly, it won't be found.
#ifndef IS_DEFINED_PFN_GetPhysicalDeviceProcAddr
#ifndef PFN_GetPhysicalDeviceProcAddr
typedef PFN_vkVoidFunction(VKAPI_PTR *PFN_GetPhysicalDeviceProcAddr)(VkInstance instance, const char *pName);
#define IS_DEFINED_PFN_GetPhysicalDeviceProcAddr
#endif
// Typedefs for loader/ICD interface
-3
View File
@@ -27,10 +27,7 @@
#define VK_CURRENT_CHAIN_VERSION 1
// Typedef for use in the interfaces below
#ifndef IS_DEFINED_PFN_GetPhysicalDeviceProcAddr
typedef PFN_vkVoidFunction (VKAPI_PTR *PFN_GetPhysicalDeviceProcAddr)(VkInstance instance, const char* pName);
#define IS_DEFINED_PFN_GetPhysicalDeviceProcAddr
#endif
// Version negotiation values
typedef enum VkNegotiateLayerStructType {
+1 -1
View File
@@ -2,7 +2,7 @@
// File: vk_platform.h
//
/*
** Copyright 2014-2026 The Khronos Group Inc.
** Copyright 2014-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
+8228 -980
View File
File diff suppressed because it is too large Load Diff
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -96,8 +96,4 @@
#include "vulkan_beta.h"
#endif
#ifdef VK_USE_PLATFORM_OHOS
#include "vulkan_ohos.h"
#endif
#endif // VULKAN_H_
+4389 -8297
View File
File diff suppressed because it is too large Load Diff
+1 -7
View File
@@ -2,7 +2,7 @@
#define VULKAN_ANDROID_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -35,14 +35,12 @@ typedef struct VkAndroidSurfaceCreateInfoKHR {
typedef VkResult (VKAPI_PTR *PFN_vkCreateAndroidSurfaceKHR)(VkInstance instance, const VkAndroidSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateAndroidSurfaceKHR(
VkInstance instance,
const VkAndroidSurfaceCreateInfoKHR* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
// VK_ANDROID_external_memory_android_hardware_buffer is a preprocessor guard. Do not pass it to API calls.
@@ -111,20 +109,16 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetAndroidHardwareBufferPropertiesANDROID)(Vk
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryAndroidHardwareBufferANDROID)(VkDevice device, const VkMemoryGetAndroidHardwareBufferInfoANDROID* pInfo, struct AHardwareBuffer** pBuffer);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetAndroidHardwareBufferPropertiesANDROID(
VkDevice device,
const struct AHardwareBuffer* buffer,
VkAndroidHardwareBufferPropertiesANDROID* pProperties);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryAndroidHardwareBufferANDROID(
VkDevice device,
const VkMemoryGetAndroidHardwareBufferInfoANDROID* pInfo,
struct AHardwareBuffer** pBuffer);
#endif
#endif
// VK_ANDROID_external_format_resolve is a preprocessor guard. Do not pass it to API calls.
+2 -151
View File
@@ -2,7 +2,7 @@
#define VULKAN_BETA_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -120,7 +120,7 @@ typedef struct VkPipelineShaderStageNodeCreateInfoAMDX {
uint32_t index;
} VkPipelineShaderStageNodeCreateInfoAMDX;
typedef VkResult (VKAPI_PTR *PFN_vkCreateExecutionGraphPipelinesAMDX)(VkDevice device, VkPipelineCache pipelineCache, uint32_t createInfoCount, const VkExecutionGraphPipelineCreateInfoAMDX* pCreateInfos, const VkAllocationCallbacks* pAllocator, VkPipeline* pPipelines);
typedef VkResult (VKAPI_PTR *PFN_vkCreateExecutionGraphPipelinesAMDX)(VkDevice device, VkPipelineCache pipelineCache, uint32_t createInfoCount, const VkExecutionGraphPipelineCreateInfoAMDX* pCreateInfos, const VkAllocationCallbacks* pAllocator, VkPipeline* pPipelines);
typedef VkResult (VKAPI_PTR *PFN_vkGetExecutionGraphPipelineScratchSizeAMDX)(VkDevice device, VkPipeline executionGraph, VkExecutionGraphPipelineScratchSizeAMDX* pSizeInfo);
typedef VkResult (VKAPI_PTR *PFN_vkGetExecutionGraphPipelineNodeIndexAMDX)(VkDevice device, VkPipeline executionGraph, const VkPipelineShaderStageNodeCreateInfoAMDX* pNodeInfo, uint32_t* pNodeIndex);
typedef void (VKAPI_PTR *PFN_vkCmdInitializeGraphScratchMemoryAMDX)(VkCommandBuffer commandBuffer, VkPipeline executionGraph, VkDeviceAddress scratch, VkDeviceSize scratchSize);
@@ -129,7 +129,6 @@ typedef void (VKAPI_PTR *PFN_vkCmdDispatchGraphIndirectAMDX)(VkCommandBuffer
typedef void (VKAPI_PTR *PFN_vkCmdDispatchGraphIndirectCountAMDX)(VkCommandBuffer commandBuffer, VkDeviceAddress scratch, VkDeviceSize scratchSize, VkDeviceAddress countInfo);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateExecutionGraphPipelinesAMDX(
VkDevice device,
VkPipelineCache pipelineCache,
@@ -137,159 +136,42 @@ VKAPI_ATTR VkResult VKAPI_CALL vkCreateExecutionGraphPipelinesAMDX(
const VkExecutionGraphPipelineCreateInfoAMDX* pCreateInfos,
const VkAllocationCallbacks* pAllocator,
VkPipeline* pPipelines);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetExecutionGraphPipelineScratchSizeAMDX(
VkDevice device,
VkPipeline executionGraph,
VkExecutionGraphPipelineScratchSizeAMDX* pSizeInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetExecutionGraphPipelineNodeIndexAMDX(
VkDevice device,
VkPipeline executionGraph,
const VkPipelineShaderStageNodeCreateInfoAMDX* pNodeInfo,
uint32_t* pNodeIndex);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkCmdInitializeGraphScratchMemoryAMDX(
VkCommandBuffer commandBuffer,
VkPipeline executionGraph,
VkDeviceAddress scratch,
VkDeviceSize scratchSize);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkCmdDispatchGraphAMDX(
VkCommandBuffer commandBuffer,
VkDeviceAddress scratch,
VkDeviceSize scratchSize,
const VkDispatchGraphCountInfoAMDX* pCountInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkCmdDispatchGraphIndirectAMDX(
VkCommandBuffer commandBuffer,
VkDeviceAddress scratch,
VkDeviceSize scratchSize,
const VkDispatchGraphCountInfoAMDX* pCountInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkCmdDispatchGraphIndirectCountAMDX(
VkCommandBuffer commandBuffer,
VkDeviceAddress scratch,
VkDeviceSize scratchSize,
VkDeviceAddress countInfo);
#endif
#endif
// VK_NV_cuda_kernel_launch is a preprocessor guard. Do not pass it to API calls.
#define VK_NV_cuda_kernel_launch 1
VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkCudaModuleNV)
VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkCudaFunctionNV)
#define VK_NV_CUDA_KERNEL_LAUNCH_SPEC_VERSION 2
#define VK_NV_CUDA_KERNEL_LAUNCH_EXTENSION_NAME "VK_NV_cuda_kernel_launch"
typedef struct VkCudaModuleCreateInfoNV {
VkStructureType sType;
const void* pNext;
size_t dataSize;
const void* pData;
} VkCudaModuleCreateInfoNV;
typedef struct VkCudaFunctionCreateInfoNV {
VkStructureType sType;
const void* pNext;
VkCudaModuleNV module;
const char* pName;
} VkCudaFunctionCreateInfoNV;
typedef struct VkCudaLaunchInfoNV {
VkStructureType sType;
const void* pNext;
VkCudaFunctionNV function;
uint32_t gridDimX;
uint32_t gridDimY;
uint32_t gridDimZ;
uint32_t blockDimX;
uint32_t blockDimY;
uint32_t blockDimZ;
uint32_t sharedMemBytes;
size_t paramCount;
const void* const * pParams;
size_t extraCount;
const void* const * pExtras;
} VkCudaLaunchInfoNV;
typedef struct VkPhysicalDeviceCudaKernelLaunchFeaturesNV {
VkStructureType sType;
void* pNext;
VkBool32 cudaKernelLaunchFeatures;
} VkPhysicalDeviceCudaKernelLaunchFeaturesNV;
typedef struct VkPhysicalDeviceCudaKernelLaunchPropertiesNV {
VkStructureType sType;
void* pNext;
uint32_t computeCapabilityMinor;
uint32_t computeCapabilityMajor;
} VkPhysicalDeviceCudaKernelLaunchPropertiesNV;
typedef VkResult (VKAPI_PTR *PFN_vkCreateCudaModuleNV)(VkDevice device, const VkCudaModuleCreateInfoNV* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkCudaModuleNV* pModule);
typedef VkResult (VKAPI_PTR *PFN_vkGetCudaModuleCacheNV)(VkDevice device, VkCudaModuleNV module, size_t* pCacheSize, void* pCacheData);
typedef VkResult (VKAPI_PTR *PFN_vkCreateCudaFunctionNV)(VkDevice device, const VkCudaFunctionCreateInfoNV* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkCudaFunctionNV* pFunction);
typedef void (VKAPI_PTR *PFN_vkDestroyCudaModuleNV)(VkDevice device, VkCudaModuleNV module, const VkAllocationCallbacks* pAllocator);
typedef void (VKAPI_PTR *PFN_vkDestroyCudaFunctionNV)(VkDevice device, VkCudaFunctionNV function, const VkAllocationCallbacks* pAllocator);
typedef void (VKAPI_PTR *PFN_vkCmdCudaLaunchKernelNV)(VkCommandBuffer commandBuffer, const VkCudaLaunchInfoNV* pLaunchInfo);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateCudaModuleNV(
VkDevice device,
const VkCudaModuleCreateInfoNV* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkCudaModuleNV* pModule);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetCudaModuleCacheNV(
VkDevice device,
VkCudaModuleNV module,
size_t* pCacheSize,
void* pCacheData);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateCudaFunctionNV(
VkDevice device,
const VkCudaFunctionCreateInfoNV* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkCudaFunctionNV* pFunction);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkDestroyCudaModuleNV(
VkDevice device,
VkCudaModuleNV module,
const VkAllocationCallbacks* pAllocator);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkDestroyCudaFunctionNV(
VkDevice device,
VkCudaFunctionNV function,
const VkAllocationCallbacks* pAllocator);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkCmdCudaLaunchKernelNV(
VkCommandBuffer commandBuffer,
const VkCudaLaunchInfoNV* pLaunchInfo);
#endif
#endif
// VK_NV_displacement_micromap is a preprocessor guard. Do not pass it to API calls.
@@ -337,37 +219,6 @@ typedef struct VkAccelerationStructureTrianglesDisplacementMicromapNV {
} VkAccelerationStructureTrianglesDisplacementMicromapNV;
// VK_AMDX_dense_geometry_format is a preprocessor guard. Do not pass it to API calls.
#define VK_AMDX_dense_geometry_format 1
#define VK_AMDX_DENSE_GEOMETRY_FORMAT_SPEC_VERSION 1
#define VK_AMDX_DENSE_GEOMETRY_FORMAT_EXTENSION_NAME "VK_AMDX_dense_geometry_format"
#define VK_COMPRESSED_TRIANGLE_FORMAT_DGF1_BYTE_ALIGNMENT_AMDX 128U
#define VK_COMPRESSED_TRIANGLE_FORMAT_DGF1_BYTE_STRIDE_AMDX 128U
typedef enum VkCompressedTriangleFormatAMDX {
VK_COMPRESSED_TRIANGLE_FORMAT_DGF1_AMDX = 0,
VK_COMPRESSED_TRIANGLE_FORMAT_MAX_ENUM_AMDX = 0x7FFFFFFF
} VkCompressedTriangleFormatAMDX;
typedef struct VkPhysicalDeviceDenseGeometryFormatFeaturesAMDX {
VkStructureType sType;
void* pNext;
VkBool32 denseGeometryFormat;
} VkPhysicalDeviceDenseGeometryFormatFeaturesAMDX;
typedef struct VkAccelerationStructureDenseGeometryFormatTrianglesDataAMDX {
VkStructureType sType;
const void* pNext;
VkDeviceOrHostAddressConstKHR compressedData;
VkDeviceSize dataSize;
uint32_t numTriangles;
uint32_t numVertices;
uint32_t maxPrimitiveIndex;
uint32_t maxGeometryIndex;
VkCompressedTriangleFormatAMDX format;
} VkAccelerationStructureDenseGeometryFormatTrianglesDataAMDX;
#ifdef __cplusplus
}
#endif
+2456 -5882
View File
File diff suppressed because it is too large Load Diff
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_DIRECTFB_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,21 +36,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateDirectFBSurfaceEXT)(VkInstance instance
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceDirectFBPresentationSupportEXT)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, IDirectFB* dfb);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateDirectFBSurfaceEXT(
VkInstance instance,
const VkDirectFBSurfaceCreateInfoEXT* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceDirectFBPresentationSupportEXT(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex,
IDirectFB* dfb);
#endif
#endif
#ifdef __cplusplus
}
+1791 -3016
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+4444 -7430
View File
File diff suppressed because it is too large Load Diff
+1 -21
View File
@@ -2,7 +2,7 @@
#define VULKAN_FUCHSIA_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -34,14 +34,12 @@ typedef struct VkImagePipeSurfaceCreateInfoFUCHSIA {
typedef VkResult (VKAPI_PTR *PFN_vkCreateImagePipeSurfaceFUCHSIA)(VkInstance instance, const VkImagePipeSurfaceCreateInfoFUCHSIA* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateImagePipeSurfaceFUCHSIA(
VkInstance instance,
const VkImagePipeSurfaceCreateInfoFUCHSIA* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
// VK_FUCHSIA_external_memory is a preprocessor guard. Do not pass it to API calls.
@@ -72,21 +70,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryZirconHandleFUCHSIA)(VkDevice device
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryZirconHandlePropertiesFUCHSIA)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, zx_handle_t zirconHandle, VkMemoryZirconHandlePropertiesFUCHSIA* pMemoryZirconHandleProperties);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryZirconHandleFUCHSIA(
VkDevice device,
const VkMemoryGetZirconHandleInfoFUCHSIA* pGetZirconHandleInfo,
zx_handle_t* pZirconHandle);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryZirconHandlePropertiesFUCHSIA(
VkDevice device,
VkExternalMemoryHandleTypeFlagBits handleType,
zx_handle_t zirconHandle,
VkMemoryZirconHandlePropertiesFUCHSIA* pMemoryZirconHandleProperties);
#endif
#endif
// VK_FUCHSIA_external_semaphore is a preprocessor guard. Do not pass it to API calls.
@@ -113,19 +107,15 @@ typedef VkResult (VKAPI_PTR *PFN_vkImportSemaphoreZirconHandleFUCHSIA)(VkDevice
typedef VkResult (VKAPI_PTR *PFN_vkGetSemaphoreZirconHandleFUCHSIA)(VkDevice device, const VkSemaphoreGetZirconHandleInfoFUCHSIA* pGetZirconHandleInfo, zx_handle_t* pZirconHandle);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkImportSemaphoreZirconHandleFUCHSIA(
VkDevice device,
const VkImportSemaphoreZirconHandleInfoFUCHSIA* pImportSemaphoreZirconHandleInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetSemaphoreZirconHandleFUCHSIA(
VkDevice device,
const VkSemaphoreGetZirconHandleInfoFUCHSIA* pGetZirconHandleInfo,
zx_handle_t* pZirconHandle);
#endif
#endif
// VK_FUCHSIA_buffer_collection is a preprocessor guard. Do not pass it to API calls.
@@ -238,42 +228,32 @@ typedef void (VKAPI_PTR *PFN_vkDestroyBufferCollectionFUCHSIA)(VkDevice device,
typedef VkResult (VKAPI_PTR *PFN_vkGetBufferCollectionPropertiesFUCHSIA)(VkDevice device, VkBufferCollectionFUCHSIA collection, VkBufferCollectionPropertiesFUCHSIA* pProperties);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateBufferCollectionFUCHSIA(
VkDevice device,
const VkBufferCollectionCreateInfoFUCHSIA* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkBufferCollectionFUCHSIA* pCollection);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkSetBufferCollectionImageConstraintsFUCHSIA(
VkDevice device,
VkBufferCollectionFUCHSIA collection,
const VkImageConstraintsInfoFUCHSIA* pImageConstraintsInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkSetBufferCollectionBufferConstraintsFUCHSIA(
VkDevice device,
VkBufferCollectionFUCHSIA collection,
const VkBufferConstraintsInfoFUCHSIA* pBufferConstraintsInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkDestroyBufferCollectionFUCHSIA(
VkDevice device,
VkBufferCollectionFUCHSIA collection,
const VkAllocationCallbacks* pAllocator);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetBufferCollectionPropertiesFUCHSIA(
VkDevice device,
VkBufferCollectionFUCHSIA collection,
VkBufferCollectionPropertiesFUCHSIA* pProperties);
#endif
#endif
#ifdef __cplusplus
}
+13845 -14283
View File
File diff suppressed because it is too large Load Diff
+1 -3
View File
@@ -2,7 +2,7 @@
#define VULKAN_GGP_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -34,14 +34,12 @@ typedef struct VkStreamDescriptorSurfaceCreateInfoGGP {
typedef VkResult (VKAPI_PTR *PFN_vkCreateStreamDescriptorSurfaceGGP)(VkInstance instance, const VkStreamDescriptorSurfaceCreateInfoGGP* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateStreamDescriptorSurfaceGGP(
VkInstance instance,
const VkStreamDescriptorSurfaceCreateInfoGGP* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
// VK_GGP_frame_token is a preprocessor guard. Do not pass it to API calls.
+8542 -10765
View File
File diff suppressed because it is too large Load Diff
+255 -2966
View File
File diff suppressed because it is too large Load Diff
+41 -63
View File
@@ -1,4 +1,4 @@
// Copyright 2015-2026 The Khronos Group Inc.
// Copyright 2015-2025 The Khronos Group Inc.
//
// SPDX-License-Identifier: Apache-2.0 OR MIT
//
@@ -35,18 +35,6 @@
# include <ciso646>
#endif
#define VULKAN_HPP_STRINGIFY2( text ) #text
#define VULKAN_HPP_STRINGIFY( text ) VULKAN_HPP_STRINGIFY2( text )
#define VULKAN_HPP_NAMESPACE_STRING VULKAN_HPP_STRINGIFY( VULKAN_HPP_NAMESPACE )
#if defined( __clang__ ) || defined( __GNUC__ ) || defined( __GNUG__ )
# define VULKAN_HPP_COMPILE_WARNING( text ) _Pragma( VULKAN_HPP_STRINGIFY( GCC warning text ) )
#elif defined( _MSC_VER )
# define VULKAN_HPP_COMPILE_WARNING( text ) _Pragma( VULKAN_HPP_STRINGIFY( message( __FILE__ "(" VULKAN_HPP_STRINGIFY( __LINE__ ) "): warning: " text ) ) )
#else
# define VULKAN_HPP_COMPILE_WARNING( text )
#endif
#if defined( VULKAN_HPP_DISABLE_ENHANCED_MODE )
# if !defined( VULKAN_HPP_NO_SMART_HANDLE )
# define VULKAN_HPP_NO_SMART_HANDLE
@@ -87,43 +75,20 @@
# define VULKAN_HPP_ENABLE_DYNAMIC_LOADER_TOOL 1
#endif
#if VULKAN_HPP_ENABLE_DYNAMIC_LOADER_TOOL == 1
# if defined( __unix__ ) || defined( __APPLE__ ) || defined( __QNX__ ) || defined( __Fuchsia__ ) && !defined( VULKAN_HPP_CXX_MODULE )
# include <dlfcn.h>
# elif defined( _WIN32 ) && !defined( VULKAN_HPP_NO_WIN32_PROTOTYPES )
using HINSTANCE = struct HINSTANCE__ *;
# if defined( _WIN64 )
# include <cstdint>
using FARPROC = int64_t( __stdcall * )();
# else
using FARPROC = int( __stdcall * )();
# endif
extern "C" __declspec( dllimport ) HINSTANCE __stdcall LoadLibraryA( char const * lpLibFileName );
extern "C" __declspec( dllimport ) int __stdcall FreeLibrary( HINSTANCE hLibModule );
extern "C" __declspec( dllimport ) FARPROC __stdcall GetProcAddress( HINSTANCE hModule, char const * lpProcName );
# endif
#endif
#if !defined( __has_include )
# define __has_include( x ) false
#endif
#if defined( __cpp_lib_three_way_comparison ) && ( 201907 <= __cpp_lib_three_way_comparison ) && __has_include( <compare> ) && !defined( VULKAN_HPP_NO_SPACESHIP_OPERATOR )
#if ( 201907 <= __cpp_lib_three_way_comparison ) && __has_include( <compare> ) && !defined( VULKAN_HPP_NO_SPACESHIP_OPERATOR )
# define VULKAN_HPP_HAS_SPACESHIP_OPERATOR
#endif
#if defined( __cpp_lib_span ) && ( 201803 <= __cpp_lib_span )
#if ( 201803 <= __cpp_lib_span )
# define VULKAN_HPP_SUPPORT_SPAN
#endif
#if defined( VULKAN_HPP_CXX_MODULE )
# define VULKAN_HPP_EXPORT export
#else
# define VULKAN_HPP_EXPORT
#endif
#if defined( VULKAN_HPP_CXX_MODULE ) && !( defined( __cpp_modules ) && defined( __cpp_lib_modules ) )
VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ named modules and the standard library module." )
#if defined( __cpp_lib_modules ) && !defined( VULKAN_HPP_STD_MODULE ) && defined( VULKAN_HPP_ENABLE_STD_MODULE )
# define VULKAN_HPP_STD_MODULE std.compat
#endif
#ifndef VK_USE_64_BIT_PTR_DEFINES
@@ -193,11 +158,6 @@ VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ name
# else
# define VULKAN_HPP_CONSTEXPR_14
# endif
# if 201603 <= __cpp_constexpr
# define VULKAN_HPP_CONSTEXPR_17 constexpr
# else
# define VULKAN_HPP_CONSTEXPR_17
# endif
# if ( 201907 <= __cpp_constexpr ) && ( !defined( __GNUC__ ) || ( 110400 < GCC_VERSION ) )
# define VULKAN_HPP_CONSTEXPR_20 constexpr
# else
@@ -260,6 +220,10 @@ VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ name
# define VULKAN_HPP_NAMESPACE vk
#endif
#define VULKAN_HPP_STRINGIFY2( text ) #text
#define VULKAN_HPP_STRINGIFY( text ) VULKAN_HPP_STRINGIFY2( text )
#define VULKAN_HPP_NAMESPACE_STRING VULKAN_HPP_STRINGIFY( VULKAN_HPP_NAMESPACE )
#if !defined( VULKAN_HPP_DISPATCH_LOADER_DYNAMIC )
# if defined( VK_NO_PROTOTYPES )
# define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC 1
@@ -291,20 +255,19 @@ VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ name
# endif
#endif
#if !defined( VULKAN_HPP_DISPATCH_LOADER_DYNAMIC_TYPE )
# define VULKAN_HPP_DISPATCH_LOADER_DYNAMIC_TYPE VULKAN_HPP_NAMESPACE::detail::DispatchLoaderDynamic
#endif
#if !defined( VULKAN_HPP_DISPATCH_LOADER_STATIC_TYPE )
# define VULKAN_HPP_DISPATCH_LOADER_STATIC_TYPE VULKAN_HPP_NAMESPACE::detail::DispatchLoaderStatic
#endif
namespace VULKAN_HPP_NAMESPACE
{
namespace detail
{
class DispatchLoaderDynamic;
#if !defined( VULKAN_HPP_DEFAULT_DISPATCHER_TYPE )
#if !defined( VULKAN_HPP_DEFAULT_DISPATCHER )
# if VULKAN_HPP_DISPATCH_LOADER_DYNAMIC == 1
# define VULKAN_HPP_DEFAULT_DISPATCHER_TYPE VULKAN_HPP_DISPATCH_LOADER_DYNAMIC_TYPE
# else
# define VULKAN_HPP_DEFAULT_DISPATCHER_TYPE VULKAN_HPP_DISPATCH_LOADER_STATIC_TYPE
extern VULKAN_HPP_STORAGE_API DispatchLoaderDynamic defaultDispatchLoaderDynamic;
# endif
#endif
} // namespace detail
} // namespace VULKAN_HPP_NAMESPACE
#if !defined( VULKAN_HPP_DEFAULT_DISPATCHER )
# if VULKAN_HPP_DISPATCH_LOADER_DYNAMIC == 1
@@ -321,18 +284,27 @@ VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ name
# define VULKAN_HPP_DEFAULT_DISPATCHER ::VULKAN_HPP_NAMESPACE::detail::getDispatchLoaderStatic()
# define VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE
# endif
#else
# define VULKAN_HPP_DEFAULT_DISPATCHER_HANDLED
#endif
#if !defined( VULKAN_HPP_DEFAULT_DISPATCHER_TYPE )
# if VULKAN_HPP_DISPATCH_LOADER_DYNAMIC == 1
# define VULKAN_HPP_DEFAULT_DISPATCHER_TYPE ::VULKAN_HPP_NAMESPACE::detail::DispatchLoaderDynamic
# else
# define VULKAN_HPP_DEFAULT_DISPATCHER_TYPE ::VULKAN_HPP_NAMESPACE::detail::DispatchLoaderStatic
# endif
#endif
#if defined( VULKAN_HPP_NO_DEFAULT_DISPATCHER )
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment )
# define VULKAN_HPP_DEFAULT_ARGUMENT_ASSIGNMENT
# define VULKAN_HPP_DEFAULT_ARGUMENT_NULLPTR_ASSIGNMENT
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT
#else
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment ) = assignment
# define VULKAN_HPP_DEFAULT_ARGUMENT_ASSIGNMENT = {}
# define VULKAN_HPP_DEFAULT_ARGUMENT_NULLPTR_ASSIGNMENT = nullptr
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT = VULKAN_HPP_DEFAULT_DISPATCHER
#endif
#define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT VULKAN_HPP_DEFAULT_ASSIGNMENT( VULKAN_HPP_DEFAULT_DISPATCHER )
#if !defined( VULKAN_HPP_EXPECTED ) && ( 23 <= VULKAN_HPP_CPP_VERSION ) && defined( __cpp_lib_expected ) && defined( VULKAN_HPP_USE_STD_EXPECTED )
#if !defined( VULKAN_HPP_EXPECTED ) && ( 23 <= VULKAN_HPP_CPP_VERSION ) && defined( __cpp_lib_expected )
# if !( defined( VULKAN_HPP_ENABLE_STD_MODULE ) && defined( VULKAN_HPP_STD_MODULE ) )
# include <expected>
# endif
@@ -341,8 +313,14 @@ VULKAN_HPP_COMPILE_WARNING( "This is a non-conforming implementation of C++ name
#endif
#if !defined( VULKAN_HPP_RAII_NAMESPACE )
# define VULKAN_HPP_RAII_NAMESPACE raii
# define VULKAN_HPP_RAII_NAMESPACE_STRING VULKAN_HPP_STRINGIFY( VULKAN_HPP_NAMESPACE::VULKAN_HPP_RAII_NAMESPACE )
# define VULKAN_HPP_RAII_NAMESPACE raii
#endif
#if defined( VULKAN_HPP_NO_EXCEPTIONS ) && defined( VULKAN_HPP_EXPECTED )
# define VULKAN_HPP_RAII_NO_EXCEPTIONS
# define VULKAN_HPP_RAII_CREATE_NOEXCEPT noexcept
#else
# define VULKAN_HPP_RAII_CREATE_NOEXCEPT
#endif
#endif
+1 -3
View File
@@ -2,7 +2,7 @@
#define VULKAN_IOS_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -34,14 +34,12 @@ typedef struct VkIOSSurfaceCreateInfoMVK {
typedef VkResult (VKAPI_PTR *PFN_vkCreateIOSSurfaceMVK)(VkInstance instance, const VkIOSSurfaceCreateInfoMVK* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateIOSSurfaceMVK(
VkInstance instance,
const VkIOSSurfaceCreateInfoMVK* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
#ifdef __cplusplus
}
+1 -3
View File
@@ -2,7 +2,7 @@
#define VULKAN_MACOS_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -34,14 +34,12 @@ typedef struct VkMacOSSurfaceCreateInfoMVK {
typedef VkResult (VKAPI_PTR *PFN_vkCreateMacOSSurfaceMVK)(VkInstance instance, const VkMacOSSurfaceCreateInfoMVK* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateMacOSSurfaceMVK(
VkInstance instance,
const VkMacOSSurfaceCreateInfoMVK* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
#ifdef __cplusplus
}
+1 -9
View File
@@ -2,7 +2,7 @@
#define VULKAN_METAL_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -40,14 +40,12 @@ typedef struct VkMetalSurfaceCreateInfoEXT {
typedef VkResult (VKAPI_PTR *PFN_vkCreateMetalSurfaceEXT)(VkInstance instance, const VkMetalSurfaceCreateInfoEXT* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateMetalSurfaceEXT(
VkInstance instance,
const VkMetalSurfaceCreateInfoEXT* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
// VK_EXT_metal_objects is a preprocessor guard. Do not pass it to API calls.
@@ -185,12 +183,10 @@ typedef struct VkImportMetalSharedEventInfoEXT {
typedef void (VKAPI_PTR *PFN_vkExportMetalObjectsEXT)(VkDevice device, VkExportMetalObjectsInfoEXT* pMetalObjectsInfo);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR void VKAPI_CALL vkExportMetalObjectsEXT(
VkDevice device,
VkExportMetalObjectsInfoEXT* pMetalObjectsInfo);
#endif
#endif
// VK_EXT_external_memory_metal is a preprocessor guard. Do not pass it to API calls.
@@ -221,21 +217,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryMetalHandleEXT)(VkDevice device, con
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryMetalHandlePropertiesEXT)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, const void* pHandle, VkMemoryMetalHandlePropertiesEXT* pMemoryMetalHandleProperties);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryMetalHandleEXT(
VkDevice device,
const VkMemoryGetMetalHandleInfoEXT* pGetMetalHandleInfo,
void** pHandle);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryMetalHandlePropertiesEXT(
VkDevice device,
VkExternalMemoryHandleTypeFlagBits handleType,
const void* pHandle,
VkMemoryMetalHandlePropertiesEXT* pMemoryMetalHandleProperties);
#endif
#endif
#ifdef __cplusplus
}
-120
View File
@@ -1,120 +0,0 @@
#ifndef VULKAN_OHOS_H_
#define VULKAN_OHOS_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
/*
** This header is generated from the Khronos Vulkan XML API Registry.
**
*/
#ifdef __cplusplus
extern "C" {
#endif
// VK_OHOS_external_memory is a preprocessor guard. Do not pass it to API calls.
#define VK_OHOS_external_memory 1
struct OH_NativeBuffer;
#define VK_OHOS_EXTERNAL_MEMORY_SPEC_VERSION 1
#define VK_OHOS_EXTERNAL_MEMORY_EXTENSION_NAME "VK_OHOS_external_memory"
typedef struct VkNativeBufferUsageOHOS {
VkStructureType sType;
void* pNext;
uint64_t OHOSNativeBufferUsage;
} VkNativeBufferUsageOHOS;
typedef struct VkNativeBufferPropertiesOHOS {
VkStructureType sType;
void* pNext;
VkDeviceSize allocationSize;
uint32_t memoryTypeBits;
} VkNativeBufferPropertiesOHOS;
typedef struct VkNativeBufferFormatPropertiesOHOS {
VkStructureType sType;
void* pNext;
VkFormat format;
uint64_t externalFormat;
VkFormatFeatureFlags formatFeatures;
VkComponentMapping samplerYcbcrConversionComponents;
VkSamplerYcbcrModelConversion suggestedYcbcrModel;
VkSamplerYcbcrRange suggestedYcbcrRange;
VkChromaLocation suggestedXChromaOffset;
VkChromaLocation suggestedYChromaOffset;
} VkNativeBufferFormatPropertiesOHOS;
typedef struct VkImportNativeBufferInfoOHOS {
VkStructureType sType;
const void* pNext;
struct OH_NativeBuffer* buffer;
} VkImportNativeBufferInfoOHOS;
typedef struct VkMemoryGetNativeBufferInfoOHOS {
VkStructureType sType;
const void* pNext;
VkDeviceMemory memory;
} VkMemoryGetNativeBufferInfoOHOS;
typedef struct VkExternalFormatOHOS {
VkStructureType sType;
void* pNext;
uint64_t externalFormat;
} VkExternalFormatOHOS;
typedef VkResult (VKAPI_PTR *PFN_vkGetNativeBufferPropertiesOHOS)(VkDevice device, const struct OH_NativeBuffer* buffer, VkNativeBufferPropertiesOHOS* pProperties);
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryNativeBufferOHOS)(VkDevice device, const VkMemoryGetNativeBufferInfoOHOS* pInfo, struct OH_NativeBuffer** pBuffer);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetNativeBufferPropertiesOHOS(
VkDevice device,
const struct OH_NativeBuffer* buffer,
VkNativeBufferPropertiesOHOS* pProperties);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryNativeBufferOHOS(
VkDevice device,
const VkMemoryGetNativeBufferInfoOHOS* pInfo,
struct OH_NativeBuffer** pBuffer);
#endif
#endif
// VK_OHOS_surface is a preprocessor guard. Do not pass it to API calls.
#define VK_OHOS_surface 1
typedef struct NativeWindow OHNativeWindow;
#define VK_OHOS_SURFACE_SPEC_VERSION 1
#define VK_OHOS_SURFACE_EXTENSION_NAME "VK_OHOS_surface"
typedef VkFlags VkSurfaceCreateFlagsOHOS;
typedef struct VkSurfaceCreateInfoOHOS {
VkStructureType sType;
const void* pNext;
VkSurfaceCreateFlagsOHOS flags;
OHNativeWindow* window;
} VkSurfaceCreateInfoOHOS;
typedef VkResult (VKAPI_PTR *PFN_vkCreateSurfaceOHOS)(VkInstance instance, const VkSurfaceCreateInfoOHOS* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateSurfaceOHOS(
VkInstance instance,
const VkSurfaceCreateInfoOHOS* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
#ifdef __cplusplus
}
#endif
#endif
+9261 -10524
View File
File diff suppressed because it is too large Load Diff
+1 -7
View File
@@ -2,7 +2,7 @@
#define VULKAN_SCREEN_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,21 +36,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateScreenSurfaceQNX)(VkInstance instance,
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceScreenPresentationSupportQNX)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, struct _screen_window* window);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateScreenSurfaceQNX(
VkInstance instance,
const VkScreenSurfaceCreateInfoQNX* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceScreenPresentationSupportQNX(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex,
struct _screen_window* window);
#endif
#endif
// VK_QNX_external_memory_screen_buffer is a preprocessor guard. Do not pass it to API calls.
@@ -99,13 +95,11 @@ typedef struct VkPhysicalDeviceExternalMemoryScreenBufferFeaturesQNX {
typedef VkResult (VKAPI_PTR *PFN_vkGetScreenBufferPropertiesQNX)(VkDevice device, const struct _screen_buffer* buffer, VkScreenBufferPropertiesQNX* pProperties);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetScreenBufferPropertiesQNX(
VkDevice device,
const struct _screen_buffer* buffer,
VkScreenBufferPropertiesQNX* pProperties);
#endif
#endif
#ifdef __cplusplus
}
+139 -171
View File
@@ -1,4 +1,4 @@
// Copyright 2015-2026 The Khronos Group Inc.
// Copyright 2015-2025 The Khronos Group Inc.
//
// SPDX-License-Identifier: Apache-2.0 OR MIT
//
@@ -8,14 +8,16 @@
#ifndef VULKAN_SHARED_HPP
#define VULKAN_SHARED_HPP
#if !defined( VULKAN_HPP_CXX_MODULE )
#include <vulkan/vulkan.hpp>
#if !( defined( VULKAN_HPP_ENABLE_STD_MODULE ) && defined( VULKAN_HPP_STD_MODULE ) )
# include <atomic> // std::atomic_size_t
# include <vulkan/vulkan.hpp>
#endif
VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
namespace VULKAN_HPP_NAMESPACE
{
#if !defined( VULKAN_HPP_NO_SMART_HANDLE )
template <typename HandleType>
class SharedHandleTraits;
@@ -83,7 +85,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
template <typename DestructorType, typename Deleter>
struct SharedHeader
{
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT
: parent( std::move( parent ) )
, deleter( std::move( deleter ) )
{
@@ -96,7 +98,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
template <typename Deleter>
struct SharedHeader<NoDestructor, Deleter>
{
SharedHeader( Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
SharedHeader( Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
Deleter deleter;
};
@@ -112,8 +114,8 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
{
}
ReferenceCounter( ReferenceCounter const & ) = delete;
ReferenceCounter & operator=( ReferenceCounter const & ) = delete;
ReferenceCounter( const ReferenceCounter & ) = delete;
ReferenceCounter & operator=( const ReferenceCounter & ) = delete;
public:
size_t addRef() VULKAN_HPP_NOEXCEPT
@@ -130,7 +132,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
public:
std::atomic_size_t m_ref_cnt{ 1 };
HeaderType m_header;
HeaderType m_header{};
};
//=====================================================================================================================
@@ -147,7 +149,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
{
}
SharedHandleBase( SharedHandleBase const & o ) VULKAN_HPP_NOEXCEPT
SharedHandleBase( const SharedHandleBase & o ) VULKAN_HPP_NOEXCEPT
{
o.addRef();
m_handle = o.m_handle;
@@ -162,7 +164,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
o.m_control = nullptr;
}
SharedHandleBase & operator=( SharedHandleBase const & o ) VULKAN_HPP_NOEXCEPT
SharedHandleBase & operator=( const SharedHandleBase & o ) VULKAN_HPP_NOEXCEPT
{
SharedHandleBase( o ).swap( *this );
return *this;
@@ -234,25 +236,25 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
}
template <typename T = HandleType>
typename std::enable_if<HasDestructor<T>::value, SharedHandle<DestructorTypeOf<HandleType>> const &>::type getDestructorType() const VULKAN_HPP_NOEXCEPT
typename std::enable_if<HasDestructor<T>::value, const SharedHandle<DestructorTypeOf<HandleType>> &>::type getDestructorType() const VULKAN_HPP_NOEXCEPT
{
return getHeader().parent;
}
protected:
template <typename T = HandleType>
static typename std::enable_if<!HasDestructor<T>::value, void>::type internalDestroy( HeaderType const & control, HandleType handle ) VULKAN_HPP_NOEXCEPT
static typename std::enable_if<!HasDestructor<T>::value, void>::type internalDestroy( const HeaderType & control, HandleType handle ) VULKAN_HPP_NOEXCEPT
{
control.deleter.destroy( handle );
}
template <typename T = HandleType>
static typename std::enable_if<HasDestructor<T>::value, void>::type internalDestroy( HeaderType const & control, HandleType handle ) VULKAN_HPP_NOEXCEPT
static typename std::enable_if<HasDestructor<T>::value, void>::type internalDestroy( const HeaderType & control, HandleType handle ) VULKAN_HPP_NOEXCEPT
{
control.deleter.destroy( control.parent.get(), handle );
}
HeaderType const & getHeader() const VULKAN_HPP_NOEXCEPT
const HeaderType & getHeader() const VULKAN_HPP_NOEXCEPT
{
return m_control->m_header;
}
@@ -281,9 +283,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
SharedHandle() = default;
template <typename T = HandleType, typename = typename std::enable_if<HasDestructor<T>::value && !HasPoolType<T>::value>::type>
explicit SharedHandle( HandleType handle,
SharedHandle<DestructorTypeOf<HandleType>> parent,
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
explicit SharedHandle( HandleType handle, SharedHandle<DestructorTypeOf<HandleType>> parent, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ) )
{
}
@@ -294,14 +294,13 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
explicit SharedHandle( HandleType handle,
SharedHandle<DestructorTypeOf<HandleType>> parent,
SharedHandle<typename GetPoolType<HandleType>::type> pool,
Dispatcher const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), DeleterType{ std::move( pool ), dispatch } )
{
}
template <typename T = HandleType, typename = typename std::enable_if<!HasDestructor<T>::value>::type>
explicit SharedHandle( HandleType handle, DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( deleter ) )
explicit SharedHandle( HandleType handle, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT : BaseType( handle, std::move( deleter ) )
{
}
@@ -311,6 +310,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
namespace detail
{
// Silence the function cast warnings.
# if defined( __GNUC__ ) && !defined( __clang__ ) && !defined( __INTEL_COMPILER )
# pragma GCC diagnostic push
@@ -320,22 +320,24 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
# pragma clang diagnostic ignored "-Wcast-function-type"
# endif
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType>
class ObjectDestroyShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType =
typename std::conditional<HasDestructor<HandleType>::value,
void ( DestructorType::* )( HandleType, AllocationCallbacks const *, Dispatcher const & ) const,
void ( HandleType::* )( AllocationCallbacks const *, Dispatcher const & ) const>::type;
void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const,
void ( HandleType::* )( const AllocationCallbacks *, const Dispatcher & ) const>::type;
using SelectorType = typename std::conditional<HasDestructor<HandleType>::value, DestructorType, HandleType>::type;
ObjectDestroyShared( Optional<AllocationCallbacks const> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatcher const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &SelectorType::destroy ) ) )
template <typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectDestroyShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ARGUMENT_NULLPTR_ASSIGNMENT,
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &SelectorType::destroy ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@@ -357,22 +359,24 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType m_destroy = nullptr;
Dispatcher const * m_dispatch = nullptr;
Optional<AllocationCallbacks const> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType>
class ObjectFreeShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, AllocationCallbacks const *, Dispatcher const & ) const;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const;
ObjectFreeShared( Optional<AllocationCallbacks const> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatcher const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectFreeShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ARGUMENT_NULLPTR_ASSIGNMENT,
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@@ -386,21 +390,24 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType m_destroy = nullptr;
Dispatcher const * m_dispatch = nullptr;
Optional<AllocationCallbacks const> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType>
class ObjectReleaseShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, Dispatcher const & ) const;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const Dispatcher & ) const;
ObjectReleaseShared( Dispatcher const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::release ) ) ), m_dispatch( &dispatch )
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectReleaseShared( const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::release ) ) )
, m_dispatch( &dispatch )
{
}
@@ -412,11 +419,11 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType m_destroy = nullptr;
Dispatcher const * m_dispatch = nullptr;
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
};
template <typename HandleType, typename PoolType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType, typename PoolType>
class PoolFreeShared
{
public:
@@ -424,14 +431,17 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using PoolTypeExport = PoolType;
template <class Dispatcher>
using ReturnType = decltype( std::declval<DestructorType>().free( PoolType(), 0u, nullptr, Dispatcher() ) );
using DestroyFunctionPointerType = ReturnType ( DestructorType::* )( PoolType, uint32_t, HandleType const *, Dispatcher const & ) const;
template <class Dispatcher>
using DestroyFunctionPointerType = ReturnType<Dispatcher> ( DestructorType::* )( PoolType, uint32_t, const HandleType *, const Dispatcher & ) const;
PoolFreeShared() = default;
PoolFreeShared( SharedHandle<PoolType> pool, Dispatcher const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
PoolFreeShared( SharedHandle<PoolType> pool, const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_pool( std::move( pool ) )
{
@@ -445,9 +455,9 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType m_destroy = nullptr;
Dispatcher const * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
};
# if defined( __GNUC__ ) && !defined( __clang__ ) && !defined( __INTEL_COMPILER )
@@ -455,6 +465,7 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
# elif defined( __clang__ ) && ( __clang_major__ >= 13 ) && !defined( __INTEL_COMPILER )
# pragma clang diagnostic pop
# endif
} // namespace detail
//======================
@@ -512,6 +523,16 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedSemaphore = SharedHandle<Semaphore>;
template <>
class SharedHandleTraits<Event>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<Event>;
};
using SharedEvent = SharedHandle<Event>;
template <>
class SharedHandleTraits<QueryPool>
{
@@ -532,6 +553,16 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedBuffer = SharedHandle<Buffer>;
template <>
class SharedHandleTraits<BufferView>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<BufferView>;
};
using SharedBufferView = SharedHandle<BufferView>;
template <>
class SharedHandleTraits<Image>
{
@@ -552,46 +583,6 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedImageView = SharedHandle<ImageView>;
template <>
class SharedHandleTraits<CommandPool>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<CommandPool>;
};
using SharedCommandPool = SharedHandle<CommandPool>;
template <>
class SharedHandleTraits<CommandBuffer>
{
public:
using DestructorType = Device;
using deleter = detail::PoolFreeShared<CommandBuffer, CommandPool>;
};
using SharedCommandBuffer = SharedHandle<CommandBuffer>;
template <>
class SharedHandleTraits<Event>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<Event>;
};
using SharedEvent = SharedHandle<Event>;
template <>
class SharedHandleTraits<BufferView>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<BufferView>;
};
using SharedBufferView = SharedHandle<BufferView>;
template <>
class SharedHandleTraits<ShaderModule>
{
@@ -692,18 +683,27 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedRenderPass = SharedHandle<RenderPass>;
//=== VK_VERSION_1_1 ===
template <>
class SharedHandleTraits<DescriptorUpdateTemplate>
class SharedHandleTraits<CommandPool>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<DescriptorUpdateTemplate>;
using deleter = detail::ObjectDestroyShared<CommandPool>;
};
using SharedDescriptorUpdateTemplate = SharedHandle<DescriptorUpdateTemplate>;
using SharedDescriptorUpdateTemplateKHR = SharedHandle<DescriptorUpdateTemplate>;
using SharedCommandPool = SharedHandle<CommandPool>;
template <>
class SharedHandleTraits<CommandBuffer>
{
public:
using DestructorType = Device;
using deleter = detail::PoolFreeShared<CommandBuffer, CommandPool>;
};
using SharedCommandBuffer = SharedHandle<CommandBuffer>;
//=== VK_VERSION_1_1 ===
template <>
class SharedHandleTraits<SamplerYcbcrConversion>
{
@@ -715,6 +715,17 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedSamplerYcbcrConversion = SharedHandle<SamplerYcbcrConversion>;
using SharedSamplerYcbcrConversionKHR = SharedHandle<SamplerYcbcrConversion>;
template <>
class SharedHandleTraits<DescriptorUpdateTemplate>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<DescriptorUpdateTemplate>;
};
using SharedDescriptorUpdateTemplate = SharedHandle<DescriptorUpdateTemplate>;
using SharedDescriptorUpdateTemplateKHR = SharedHandle<DescriptorUpdateTemplate>;
//=== VK_VERSION_1_3 ===
template <>
class SharedHandleTraits<PrivateDataSlot>
@@ -824,17 +835,6 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedDebugUtilsMessengerEXT = SharedHandle<DebugUtilsMessengerEXT>;
//=== VK_EXT_descriptor_heap ===
template <>
class SharedHandleTraits<TensorARM>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<TensorARM>;
};
using SharedTensorARM = SharedHandle<TensorARM>;
//=== VK_KHR_acceleration_structure ===
template <>
class SharedHandleTraits<AccelerationStructureKHR>
@@ -948,17 +948,6 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedMicromapEXT = SharedHandle<MicromapEXT>;
//=== VK_ARM_tensors ===
template <>
class SharedHandleTraits<TensorViewARM>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<TensorViewARM>;
};
using SharedTensorViewARM = SharedHandle<TensorViewARM>;
//=== VK_NV_optical_flow ===
template <>
class SharedHandleTraits<OpticalFlowSessionNV>
@@ -992,28 +981,6 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedPipelineBinaryKHR = SharedHandle<PipelineBinaryKHR>;
//=== VK_ARM_data_graph ===
template <>
class SharedHandleTraits<DataGraphPipelineSessionARM>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<DataGraphPipelineSessionARM>;
};
using SharedDataGraphPipelineSessionARM = SharedHandle<DataGraphPipelineSessionARM>;
//=== VK_NV_external_compute_queue ===
template <>
class SharedHandleTraits<ExternalComputeQueueNV>
{
public:
using DestructorType = Device;
using deleter = detail::ObjectDestroyShared<ExternalComputeQueueNV>;
};
using SharedExternalComputeQueueNV = SharedHandle<ExternalComputeQueueNV>;
//=== VK_EXT_device_generated_commands ===
template <>
class SharedHandleTraits<IndirectCommandsLayoutEXT>
@@ -1035,19 +1002,20 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
using SharedIndirectExecutionSetEXT = SharedHandle<IndirectExecutionSetEXT>;
// a number of SharedHandle specializations
enum class SwapchainOwns
{
no,
yes,
};
struct ImageHeader : SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>
struct ImageHeader : SharedHeader<DestructorTypeOf<VULKAN_HPP_NAMESPACE::Image>, typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::Image>::deleter>
{
ImageHeader( SharedHandle<DestructorTypeOf<Image>> parent,
typename SharedHandleTraits<Image>::deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<Image>::deleter() ),
SwapchainOwns swapchainOwned = SwapchainOwns::no ) VULKAN_HPP_NOEXCEPT
: SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>( std::move( parent ), std::move( deleter ) )
ImageHeader(
SharedHandle<DestructorTypeOf<VULKAN_HPP_NAMESPACE::Image>> parent,
typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::Image>::deleter deleter = typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::Image>::deleter(),
SwapchainOwns swapchainOwned = SwapchainOwns::no ) VULKAN_HPP_NOEXCEPT
: SharedHeader<DestructorTypeOf<VULKAN_HPP_NAMESPACE::Image>, typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::Image>::deleter>( std::move( parent ),
std::move( deleter ) )
, swapchainOwned( swapchainOwned )
{
}
@@ -1056,25 +1024,25 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
};
template <>
class SharedHandle<Image> : public SharedHandleBase<Image, ImageHeader>
class SharedHandle<VULKAN_HPP_NAMESPACE::Image> : public SharedHandleBase<VULKAN_HPP_NAMESPACE::Image, ImageHeader>
{
using BaseType = SharedHandleBase<Image, ImageHeader>;
using DeleterType = typename SharedHandleTraits<Image>::deleter;
using BaseType = SharedHandleBase<VULKAN_HPP_NAMESPACE::Image, ImageHeader>;
using DeleterType = typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::Image>::deleter;
friend BaseType;
public:
SharedHandle() = default;
explicit SharedHandle( Image handle,
SharedHandle<DestructorTypeOf<Image>> parent,
SwapchainOwns swapchain_owned VULKAN_HPP_DEFAULT_ASSIGNMENT( SwapchainOwns::no ),
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
explicit SharedHandle( VULKAN_HPP_NAMESPACE::Image handle,
SharedHandle<DestructorTypeOf<VULKAN_HPP_NAMESPACE::Image>> parent,
SwapchainOwns swapchain_owned = SwapchainOwns::no,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ), swapchain_owned )
{
}
protected:
static void internalDestroy( ImageHeader const & control, Image handle ) VULKAN_HPP_NOEXCEPT
static void internalDestroy( const ImageHeader & control, VULKAN_HPP_NAMESPACE::Image handle ) VULKAN_HPP_NOEXCEPT
{
if ( control.swapchainOwned == SwapchainOwns::no )
{
@@ -1085,41 +1053,41 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
struct SwapchainHeader
{
SwapchainHeader( SharedHandle<SurfaceKHR> surface,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
typename SharedHandleTraits<SwapchainKHR>::deleter deleter
VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<SwapchainKHR>::deleter() ) ) VULKAN_HPP_NOEXCEPT
SwapchainHeader( SharedHandle<VULKAN_HPP_NAMESPACE::SurfaceKHR> surface,
SharedHandle<DestructorTypeOf<VULKAN_HPP_NAMESPACE::SwapchainKHR>> parent,
typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::SwapchainKHR>::deleter deleter =
typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::SwapchainKHR>::deleter() ) VULKAN_HPP_NOEXCEPT
: surface( std::move( surface ) )
, parent( std::move( parent ) )
, deleter( std::move( deleter ) )
{
}
SharedHandle<SurfaceKHR> surface;
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent;
typename SharedHandleTraits<SwapchainKHR>::deleter deleter;
SharedHandle<VULKAN_HPP_NAMESPACE::SurfaceKHR> surface{};
SharedHandle<DestructorTypeOf<VULKAN_HPP_NAMESPACE::SwapchainKHR>> parent{};
typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::SwapchainKHR>::deleter deleter{};
};
template <>
class SharedHandle<SwapchainKHR> : public SharedHandleBase<SwapchainKHR, SwapchainHeader>
class SharedHandle<VULKAN_HPP_NAMESPACE::SwapchainKHR> : public SharedHandleBase<VULKAN_HPP_NAMESPACE::SwapchainKHR, SwapchainHeader>
{
using BaseType = SharedHandleBase<SwapchainKHR, SwapchainHeader>;
using DeleterType = typename SharedHandleTraits<SwapchainKHR>::deleter;
using BaseType = SharedHandleBase<VULKAN_HPP_NAMESPACE::SwapchainKHR, SwapchainHeader>;
using DeleterType = typename SharedHandleTraits<VULKAN_HPP_NAMESPACE::SwapchainKHR>::deleter;
friend BaseType;
public:
SharedHandle() = default;
explicit SharedHandle( SwapchainKHR handle,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
SharedHandle<SurfaceKHR> surface,
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
explicit SharedHandle( VULKAN_HPP_NAMESPACE::SwapchainKHR handle,
SharedHandle<DestructorTypeOf<VULKAN_HPP_NAMESPACE::SwapchainKHR>> parent,
SharedHandle<VULKAN_HPP_NAMESPACE::SurfaceKHR> surface,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( surface ), std::move( parent ), std::move( deleter ) )
{
}
public:
SharedHandle<SurfaceKHR> const & getSurface() const VULKAN_HPP_NOEXCEPT
const SharedHandle<VULKAN_HPP_NAMESPACE::SurfaceKHR> & getSurface() const VULKAN_HPP_NOEXCEPT
{
return getHeader().surface;
}
@@ -1134,13 +1102,13 @@ VULKAN_HPP_EXPORT namespace VULKAN_HPP_NAMESPACE
public:
using SharedHandleBase<HandleType, DestructorType>::SharedHandleBase;
DestructorType const & getDestructorType() const VULKAN_HPP_NOEXCEPT
const DestructorType & getDestructorType() const VULKAN_HPP_NOEXCEPT
{
return SharedHandleBase<HandleType, DestructorType>::getHeader();
}
protected:
static void internalDestroy( DestructorType const &, HandleType ) VULKAN_HPP_NOEXCEPT {}
static void internalDestroy( const DestructorType &, HandleType ) VULKAN_HPP_NOEXCEPT {}
};
//=== VK_VERSION_1_0 ===
File diff suppressed because it is too large Load Diff
+31395 -82688
View File
File diff suppressed because it is too large Load Diff
+4475 -5582
View File
File diff suppressed because it is too large Load Diff
+1 -3
View File
@@ -2,7 +2,7 @@
#define VULKAN_VI_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -34,14 +34,12 @@ typedef struct VkViSurfaceCreateInfoNN {
typedef VkResult (VKAPI_PTR *PFN_vkCreateViSurfaceNN)(VkInstance instance, const VkViSurfaceCreateInfoNN* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateViSurfaceNN(
VkInstance instance,
const VkViSurfaceCreateInfoNN* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#endif
#ifdef __cplusplus
}
-72
View File
@@ -1,72 +0,0 @@
// Copyright 2021-2026 The Khronos Group Inc.
// SPDX-License-Identifier: Apache-2.0 OR MIT
//
// This header is generated from the Khronos Vulkan XML API Registry.
module;
#define VULKAN_HPP_CXX_MODULE 1
#if __has_include( <vk_video/vulkan_video_codecs_common.h> )
# include <vk_video/vulkan_video_codecs_common.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h264std.h> )
# include <vk_video/vulkan_video_codec_h264std.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h264std_decode.h> )
# include <vk_video/vulkan_video_codec_h264std_decode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h264std_encode.h> )
# include <vk_video/vulkan_video_codec_h264std_encode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h265std.h> )
# include <vk_video/vulkan_video_codec_h265std.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h265std_decode.h> )
# include <vk_video/vulkan_video_codec_h265std_decode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_h265std_encode.h> )
# include <vk_video/vulkan_video_codec_h265std_encode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_vp9std.h> )
# include <vk_video/vulkan_video_codec_vp9std.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_vp9std_decode.h> )
# include <vk_video/vulkan_video_codec_vp9std_decode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_av1std.h> )
# include <vk_video/vulkan_video_codec_av1std.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_av1std_decode.h> )
# include <vk_video/vulkan_video_codec_av1std_decode.h>
#endif
#if __has_include( <vk_video/vulkan_video_codec_av1std_encode.h> )
# include <vk_video/vulkan_video_codec_av1std_encode.h>
#endif
// clang-format off
#include <vulkan/vulkan_hpp_macros.hpp>
// clang-format on
export module vulkan_video;
import vulkan;
#if defined( _MSC_VER )
# pragma warning( push )
# pragma warning( disable : 5244 )
#elif defined( __clang__ )
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Winclude-angled-in-module-purview"
#elif defined( __GNUC__ )
#endif
#include <vulkan/vulkan_video.hpp>
#if defined( _MSC_VER )
# pragma warning( pop )
#elif defined( __clang__ )
# pragma clang diagnostic pop
#elif defined( __GNUC__ )
#endif
+747 -1755
View File
File diff suppressed because it is too large Load Diff
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_WAYLAND_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,21 +36,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateWaylandSurfaceKHR)(VkInstance instance,
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceWaylandPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, struct wl_display* display);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateWaylandSurfaceKHR(
VkInstance instance,
const VkWaylandSurfaceCreateInfoKHR* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceWaylandPresentationSupportKHR(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex,
struct wl_display* display);
#endif
#endif
#ifdef __cplusplus
}
+1 -31
View File
@@ -2,7 +2,7 @@
#define VULKAN_WIN32_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,20 +36,16 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateWin32SurfaceKHR)(VkInstance instance, c
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceWin32PresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateWin32SurfaceKHR(
VkInstance instance,
const VkWin32SurfaceCreateInfoKHR* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceWin32PresentationSupportKHR(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex);
#endif
#endif
// VK_KHR_external_memory_win32 is a preprocessor guard. Do not pass it to API calls.
@@ -89,21 +85,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandleKHR)(VkDevice device, con
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandlePropertiesKHR)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, HANDLE handle, VkMemoryWin32HandlePropertiesKHR* pMemoryWin32HandleProperties);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryWin32HandleKHR(
VkDevice device,
const VkMemoryGetWin32HandleInfoKHR* pGetWin32HandleInfo,
HANDLE* pHandle);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryWin32HandlePropertiesKHR(
VkDevice device,
VkExternalMemoryHandleTypeFlagBits handleType,
HANDLE handle,
VkMemoryWin32HandlePropertiesKHR* pMemoryWin32HandleProperties);
#endif
#endif
// VK_KHR_win32_keyed_mutex is a preprocessor guard. Do not pass it to API calls.
@@ -166,19 +158,15 @@ typedef VkResult (VKAPI_PTR *PFN_vkImportSemaphoreWin32HandleKHR)(VkDevice devic
typedef VkResult (VKAPI_PTR *PFN_vkGetSemaphoreWin32HandleKHR)(VkDevice device, const VkSemaphoreGetWin32HandleInfoKHR* pGetWin32HandleInfo, HANDLE* pHandle);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkImportSemaphoreWin32HandleKHR(
VkDevice device,
const VkImportSemaphoreWin32HandleInfoKHR* pImportSemaphoreWin32HandleInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetSemaphoreWin32HandleKHR(
VkDevice device,
const VkSemaphoreGetWin32HandleInfoKHR* pGetWin32HandleInfo,
HANDLE* pHandle);
#endif
#endif
// VK_KHR_external_fence_win32 is a preprocessor guard. Do not pass it to API calls.
@@ -214,19 +202,15 @@ typedef VkResult (VKAPI_PTR *PFN_vkImportFenceWin32HandleKHR)(VkDevice device, c
typedef VkResult (VKAPI_PTR *PFN_vkGetFenceWin32HandleKHR)(VkDevice device, const VkFenceGetWin32HandleInfoKHR* pGetWin32HandleInfo, HANDLE* pHandle);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkImportFenceWin32HandleKHR(
VkDevice device,
const VkImportFenceWin32HandleInfoKHR* pImportFenceWin32HandleInfo);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetFenceWin32HandleKHR(
VkDevice device,
const VkFenceGetWin32HandleInfoKHR* pGetWin32HandleInfo,
HANDLE* pHandle);
#endif
#endif
// VK_NV_external_memory_win32 is a preprocessor guard. Do not pass it to API calls.
@@ -250,14 +234,12 @@ typedef struct VkExportMemoryWin32HandleInfoNV {
typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandleNV)(VkDevice device, VkDeviceMemory memory, VkExternalMemoryHandleTypeFlagsNV handleType, HANDLE* pHandle);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryWin32HandleNV(
VkDevice device,
VkDeviceMemory memory,
VkExternalMemoryHandleTypeFlagsNV handleType,
HANDLE* pHandle);
#endif
#endif
// VK_NV_win32_keyed_mutex is a preprocessor guard. Do not pass it to API calls.
@@ -314,33 +296,25 @@ typedef VkResult (VKAPI_PTR *PFN_vkReleaseFullScreenExclusiveModeEXT)(VkDevice d
typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceGroupSurfacePresentModes2EXT)(VkDevice device, const VkPhysicalDeviceSurfaceInfo2KHR* pSurfaceInfo, VkDeviceGroupPresentModeFlagsKHR* pModes);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetPhysicalDeviceSurfacePresentModes2EXT(
VkPhysicalDevice physicalDevice,
const VkPhysicalDeviceSurfaceInfo2KHR* pSurfaceInfo,
uint32_t* pPresentModeCount,
VkPresentModeKHR* pPresentModes);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkAcquireFullScreenExclusiveModeEXT(
VkDevice device,
VkSwapchainKHR swapchain);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkReleaseFullScreenExclusiveModeEXT(
VkDevice device,
VkSwapchainKHR swapchain);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetDeviceGroupSurfacePresentModes2EXT(
VkDevice device,
const VkPhysicalDeviceSurfaceInfo2KHR* pSurfaceInfo,
VkDeviceGroupPresentModeFlagsKHR* pModes);
#endif
#endif
// VK_NV_acquire_winrt_display is a preprocessor guard. Do not pass it to API calls.
@@ -351,19 +325,15 @@ typedef VkResult (VKAPI_PTR *PFN_vkAcquireWinrtDisplayNV)(VkPhysicalDevice physi
typedef VkResult (VKAPI_PTR *PFN_vkGetWinrtDisplayNV)(VkPhysicalDevice physicalDevice, uint32_t deviceRelativeId, VkDisplayKHR* pDisplay);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkAcquireWinrtDisplayNV(
VkPhysicalDevice physicalDevice,
VkDisplayKHR display);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetWinrtDisplayNV(
VkPhysicalDevice physicalDevice,
uint32_t deviceRelativeId,
VkDisplayKHR* pDisplay);
#endif
#endif
#ifdef __cplusplus
}
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_XCB_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,22 +36,18 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateXcbSurfaceKHR)(VkInstance instance, con
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceXcbPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, xcb_connection_t* connection, xcb_visualid_t visual_id);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateXcbSurfaceKHR(
VkInstance instance,
const VkXcbSurfaceCreateInfoKHR* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceXcbPresentationSupportKHR(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex,
xcb_connection_t* connection,
xcb_visualid_t visual_id);
#endif
#endif
#ifdef __cplusplus
}
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_XLIB_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -36,22 +36,18 @@ typedef VkResult (VKAPI_PTR *PFN_vkCreateXlibSurfaceKHR)(VkInstance instance, co
typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceXlibPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, Display* dpy, VisualID visualID);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkCreateXlibSurfaceKHR(
VkInstance instance,
const VkXlibSurfaceCreateInfoKHR* pCreateInfo,
const VkAllocationCallbacks* pAllocator,
VkSurfaceKHR* pSurface);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkBool32 VKAPI_CALL vkGetPhysicalDeviceXlibPresentationSupportKHR(
VkPhysicalDevice physicalDevice,
uint32_t queueFamilyIndex,
Display* dpy,
VisualID visualID);
#endif
#endif
#ifdef __cplusplus
}
+1 -5
View File
@@ -2,7 +2,7 @@
#define VULKAN_XLIB_XRANDR_H_ 1
/*
** Copyright 2015-2026 The Khronos Group Inc.
** Copyright 2015-2025 The Khronos Group Inc.
**
** SPDX-License-Identifier: Apache-2.0
*/
@@ -27,21 +27,17 @@ typedef VkResult (VKAPI_PTR *PFN_vkAcquireXlibDisplayEXT)(VkPhysicalDevice physi
typedef VkResult (VKAPI_PTR *PFN_vkGetRandROutputDisplayEXT)(VkPhysicalDevice physicalDevice, Display* dpy, RROutput rrOutput, VkDisplayKHR* pDisplay);
#ifndef VK_NO_PROTOTYPES
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkAcquireXlibDisplayEXT(
VkPhysicalDevice physicalDevice,
Display* dpy,
VkDisplayKHR display);
#endif
#ifndef VK_ONLY_EXPORTED_PROTOTYPES
VKAPI_ATTR VkResult VKAPI_CALL vkGetRandROutputDisplayEXT(
VkPhysicalDevice physicalDevice,
Display* dpy,
RROutput rrOutput,
VkDisplayKHR* pDisplay);
#endif
#endif
#ifdef __cplusplus
}
-63
View File
@@ -158,66 +158,3 @@
obj:*libdbus-1.so*
...
}
{
vulkan_lvp_leaks
Memcheck:Leak
fun:*
...
obj:*libvulkan_lvp.so*
...
}
{
vulkan_intel_leaks
Memcheck:Leak
fun:*
...
obj:*libvulkan_intel.so*
...
}
{
vulkan_base_leaks
Memcheck:Leak
fun:*
...
obj:*libvulkan.so*
...
}
{
vulkan_mesa_leaks
Memcheck:Leak
fun:*
...
obj:*libVkLayer_MESA_device_select.so*
...
}
{
vulkan_read_errors
Memcheck:Addr1
...
obj:*libvulkan*
...
}
{
vulkan_read_errors_intel
Memcheck:Addr1
...
obj:*libvulkan_intel.so*
...
}
{
nvidia_thread_read_errors
Memcheck:Addr1
...
obj:*libnvidia-glcore.so*
...
fun:start_thread
...
}
{
nvidia_specific_thread_error
Memcheck:Addr1
obj:*libnvidia-glcore.so.550.120*
obj:*libnvidia-glcore.so.550.120*
fun:start_thread
fun:clone
}
+16 -3
View File
@@ -1,6 +1,6 @@
-- Global settings
add_requires("libsdl2", { configs = { sdlmain = false } })
add_requires("libsdl", { configs = { sdlmain = false } })
add_rules("mode.debug", "mode.release", "mode.releasedbg")
set_languages("cxx20", "c11")
@@ -11,6 +11,17 @@ set_targetdir("./")
set_optimize("fastest")
-- Options
option("images_optimized")
set_default(true)
add_defines("IMAGE_OPTIMIZED")
option_end()
option("force_integrated_gpu")
set_default(false)
add_defines("FORCE_INTEGRATED_GPU")
option_end()
option("graphics_memory_dump")
set_default(false)
add_defines("GRAPHICS_MEMORY_DUMP")
@@ -37,6 +48,8 @@ target("mlx")
set_default(true)
set_license("MIT")
set_kind("shared")
add_options("images_optimized")
add_options("force_integrated_gpu")
add_options("graphics_memory_dump")
add_options("profiler")
add_options("force_wayland")
@@ -50,7 +63,7 @@ target("mlx")
add_files("runtime/Sources/**.cpp")
add_packages("libsdl2")
add_packages("libsdl")
if is_mode("debug") then
add_defines("DEBUG")
@@ -85,5 +98,5 @@ target("Test")
add_defines("SDL_MAIN_HANDLED")
add_packages("libsdl2")
add_packages("libsdl")
target_end()