Commit Graph

589 Commits

Author SHA1 Message Date
Andreas Süßenbach
d748663707
Undef True/False in case they are defined and introduce some constexpr True/False to replace them. (#1610) 2023-07-03 14:34:21 +02:00
github-actions[bot]
c115fd1ec6
Update Vulkan-Headers to v1.3.256 (#1609)
Co-authored-by: GitHub <noreply@github.com>
2023-07-03 12:07:37 +02:00
Sharadh Rajaraman
6c1996f068
Add C++20 module interface file and tests (#1582)
* feat: exported vk::raii types in vulkan.ixx, with a small test

* feat: *almost* complete vulkan.ixx; missing functions in vulkan_funcs.hpp and constexpr auto defines

* Exported free functions in `vulkan_funcs.hpp` in `vulkan.ixx`

* Completed vulkan.ixx

Exported all types, structs, functions; need to handle anonymous namespace and getDispatchLoaderStatic()

* Moved `vk::anon-namespace::throwResultException` to `vk::detail::throwResultException` to solve linking errors

* Made `vk::getDispatchLoaderStatic` not `static`

`static`in namespace/global scope has to do with internal/external linkage, and not lifetime

* Fixed debug assert fail in `generateCppModuleStructUsings`

* Removed references to `.cppm`

* Formatting and versioning changes

- CMake version handling simplified
- vulkan.ixx includes new structs from new versions
- vulkan.hpp and vulkan_raii.hpp reformatted with clang-format 14

* Removed extraneous includes

- std::optional -> std::string::empty
- std::filesystem was unused

* Fixed constexpr function and value generation
- 'c' prefix removed
- Constants casing fixed
- Types for constants fixed
- Constants assigned to macros
- Ordering of constants and consteval functions fixed

* Moved constexprs to `vulkan.hpp`

- Added corresponding `using` statements to `vulkan.ixx`
- Changed `consteval auto(auto)` functions into templated SFINAE `constexpr` functions

* Formatting, signposting, misc fixes

- Added newlines around macro guards
- Added signposting comments for relevant groups of `using`-statements in `vulkan.ixx`
- Guarded createInstanceUnique with macro guard
- Use m_handles.at("").commands for Funcs

* Changed module file extension to `.cppm`

- It follows the rest of the project convention; `ixx` looks really weird next to `.hpp` and `.cpp`
- CMake transparently handles any extension anyway

* Added `VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE` to `vulkan.cppm`

* Added format traits and extension inspections

- Straightforward, since everything is hard-coded

* Added documentation about Vulkan-Hpp C++ module

- Compiler requirements
- CMake compilation
- Command-line examples

* Added vulkan_hash.hpp

- No need for `using`, since all declarations are template specialisations of existing `std` objects

* Documentation and comment fixes

- Removed extraneous CMake version comments
- Documentation about default dynamic dispatcher with the module
- Comment updates in the source code

* Moved constexpr defines and using statements 

- Moved to after resultUsings in both vulkan.hpp and vulkan.cppm
- Also split up constexprDefinesAndUsings
- Used const_cast for constexprDefines()

* Used std::string instead of std::stringstream

- Some changes also in previous commit
- Also removed overly-clever ranges algorithms

* Simplified protection generation

- Removed `generateNotProtection`
- Added optional `bool` parameter to `generateProtection` for `#if !defined( ... )`

* Simplified Cpp20Modules CMakeLists

- Made C++ standard and libraries into parameters
- Removed FindVulkan call; already done

* `constexpr` generation fixed

- Made all generating functions `const`
- Removed typos and extra comments
- Extracted out filtering functionality into separate functions

* Simplified defines partition generation

- Added `DefinesPartition` struct as a member variable
- Added non-const function to write to the above in `readTypeDefines`
- Removed previous implementation that made many copies

* Added `generateUsingsAndProtection` lambda to RAII name generation

* Moved around `partitionDefines` to make more sense

- called once at the end of the constructor
- edited comments

* Updated headers to 1.3.255

* Removed std::ranges and ranges view adaptors

- CI isn't passing with them

* Fixed constexpr functions for C++11 and C++14

- Removed `enable_if_t` and `is_integral_v` 
- Changed `auto` return type into `uint32_t`

---------

Co-authored-by: Sharadh Rajaraman <r.sharadh@yahoo.com.sg>
2023-06-28 14:10:51 +02:00
Andreas Süßenbach
5d8c550b0d
Mark vk::ResultValue::asTuple() & as deprecated, introduce vk::ResultValue::asTuple() && (#1605) 2023-06-27 11:31:29 +02:00
github-actions[bot]
3d95b910da
Update Vulkan-Headers to v1.3.255 (#1604)
Co-authored-by: GitHub <noreply@github.com>
2023-06-26 14:12:49 +02:00
Andreas Süßenbach
389d1250cd
Add specializations of std::tuple_element and std::tuple_size for vk::StructureChain. (#1602) 2023-06-22 14:02:39 +02:00
Andreas Süßenbach
98d2b53258
Fix some formatting. (#1599) 2023-06-21 13:33:29 +02:00
Andreas Süßenbach
397ffad84a
Fix defines in workflow files to enable compilation of tests and samples in CI. (#1595) 2023-06-20 14:43:35 +02:00
Andreas Süßenbach
9f89f760a6
Update Vulkan-Headers to v1.3.254 (#1596) 2023-06-19 15:02:19 +02:00
GitHub
0ab2f4a18a Update Vulkan-Headers to v1.3.253 2023-06-11 16:53:55 +02:00
GitHub
18bce4a642 Update Vulkan-Headers to v1.3.252 2023-06-03 05:57:43 -07:00
GitHub
9c3fb4f8df Update Vulkan-Headers to v1.3.251 2023-05-30 02:36:42 -07:00
github-actions[bot]
d4d0ac4859
Update Vulkan-Headers to v1.3.250 (#1574)
Co-authored-by: GitHub <noreply@github.com>
2023-05-08 11:07:25 +02:00
Andreas Süßenbach
f618b6bd5d
Cleanup work on enum value handling. (#1573) 2023-05-04 13:35:50 +02:00
github-actions[bot]
4e3e3e026d
Update Vulkan-Headers to v1.3.249 (#1571)
Co-authored-by: GitHub <noreply@github.com>
2023-05-02 13:31:35 +02:00
Andreas Süßenbach
95c622a64f
Extend support of some special type of functions. (#1567) 2023-04-24 18:06:06 +02:00
github-actions[bot]
f06c4aa1d3
Update Vulkan-Headers to v1.3.248 (#1565)
Co-authored-by: GitHub <noreply@github.com>
2023-04-24 11:04:14 +02:00
github-actions[bot]
3bcbb39802
Update Vulkan-Headers to v1.3.247 (#1560)
Co-authored-by: GitHub <noreply@github.com>
2023-04-17 11:55:11 +02:00
Andreas Süßenbach
678295aa75
Update Vulkan-Headers to v1.3.246 (#1551) 2023-04-03 13:29:44 +02:00
Andreas Süßenbach
2175530fd0
Improved tokenizing of extension attribute "depends" (#1546) 2023-03-29 13:33:42 +02:00
Andreas Süßenbach
4420e1f91e
First set of extension inspection helper functions: isDeviceExtension and isInstanceExtension (#1545) 2023-03-28 17:33:11 +02:00
Andreas Süßenbach
9d5220db12
Extend default case in throwResultException to also get the actual message. (#1544) 2023-03-27 12:31:14 +02:00
github-actions[bot]
beb3f6f35e
Update Vulkan-Headers to v1.3.245 (#1540)
Co-authored-by: GitHub <noreply@github.com>
2023-03-27 09:46:47 +02:00
github-actions[bot]
1bd3877dcc
Update Vulkan-Headers to v1.3.244 (#1535)
Co-authored-by: GitHub <noreply@github.com>
2023-03-20 10:03:08 +01:00
github-actions[bot]
2acce33951
Update Vulkan-Headers to v1.3.243 (#1531)
Co-authored-by: GitHub <noreply@github.com>
2023-03-13 10:38:56 +01:00
Andreas Süßenbach
9e66a8886a
Refactor reading procedures (#1521) 2023-03-01 10:17:02 +01:00
github-actions[bot]
c499dd0f79
Update Vulkan-Headers to v1.3.242 (#1520)
Co-authored-by: GitHub <noreply@github.com>
2023-02-27 13:35:15 +01:00
github-actions[bot]
3853394ffa
Update Vulkan-Headers to v1.3.241 (#1516)
Co-authored-by: GitHub <noreply@github.com>
2023-02-21 11:20:28 +01:00
github-actions[bot]
83adc3fa57
Update Vulkan-Headers to v1.3.240 (#1497)
Co-authored-by: GitHub <noreply@github.com>
2023-01-30 09:40:19 +01:00
Andreas Süßenbach
e40e6b641e
Update Vulkan-Headers to v1.3.239 (#1489) 2023-01-23 10:37:51 +01:00
Andreas Süßenbach
68512e6702
Add options for clang-format 15. (#1480) 2023-01-16 17:38:34 +01:00
github-actions[bot]
e4b8afe005
Update Vulkan-Headers to v1.3.238 (#1472)
Co-authored-by: GitHub <noreply@github.com>
2022-12-20 17:48:45 +01:00
Andreas Süßenbach
23a13e4707
Add support of clang_format version 13 and 14. (#1468) 2022-12-12 17:30:35 +01:00
github-actions[bot]
d3728e63a1
Update Vulkan-Headers to v1.3.237 (#1466)
Co-authored-by: GitHub <noreply@github.com>
Co-authored-by: Andreas Süßenbach <asuessenbach@nvidia.com>
2022-12-12 10:13:44 +01:00
GitHub
fb561d8092 Update Vulkan-Headers to v1.3.236 2022-12-06 00:11:19 +00:00
GitHub
aed619647c Update Vulkan-Headers to v1.3.235 2022-11-18 00:12:31 +00:00
asuessenbach
73276f2c26 Remove outdated conditions around two init functions of the DispatchLoaderDynamic. 2022-11-14 12:28:20 +01:00
asuessenbach
196978705e Extent support of functions returning some typed value 2022-11-14 10:06:49 +01:00
GitHub
c873ad307d Update Vulkan-Headers to v1.3.234 2022-11-11 00:12:48 +00:00
Andreas Süßenbach
d6493eae1d
Merge pull request #1438 from asuessenbach/flags
Fix Flags<T>::operator~()
2022-11-07 14:27:38 +01:00
asuessenbach
040686faae Fix Flags<T>::operator~() 2022-11-07 11:28:15 +01:00
GitHub
92c36643f1 Update Vulkan-Headers to v1.3.233 2022-11-07 00:12:52 +00:00
GitHub
dcc1d9562f Update Vulkan-Headers to v1.3.232 2022-10-28 00:12:55 +00:00
GitHub
738e7c1423 Update Vulkan-Headers to v1.3.231 2022-10-14 00:16:32 +00:00
asuessenbach
302389d550 Templatized bitwise operators on FlagBits. 2022-10-10 11:04:27 +02:00
GitHub
3b5961d5ce Update Vulkan-Headers to v1.3.230 2022-09-30 00:20:29 +00:00
GitHub
917ba7cbb0 Update Vulkan-Headers to v1.3.229 2022-09-23 00:12:32 +00:00
GitHub
27b37765e7 Update Vulkan-Headers to v1.3.228 2022-09-16 00:13:32 +00:00
Andreas Süßenbach
984ab4e846
Merge pull request #1407 from asuessenbach/algorithm
Unconditionally include <algorithm> in vulkan.hpp.
2022-09-13 08:29:20 +02:00
asuessenbach
ac1eda539c Unconditionally include <algorithm> in vulkan.hpp. 2022-09-12 17:10:56 +02:00
asuessenbach
34725b3192 Introduce helper class vk::StridedArrayProxy; use it on functions with parameters having the 'stride' attribute. 2022-09-12 16:53:44 +02:00
GitHub
6fd5e6dd72 Update Vulkan-Headers to v1.3.227 2022-09-09 00:11:55 +00:00
GitHub
5c406ec531 Update Vulkan-Headers to v1.3.226 2022-09-02 00:12:10 +00:00
GitHub
33dad92cec Update Vulkan-Headers to v1.3.225 2022-08-24 08:40:49 +02:00
asuessenbach
6e5824e21a Update to Vulkan-Headers v1.3.224 2022-08-08 09:47:30 +02:00
asuessenbach
893d6847bb Refactor top-level function to generate vulkan.hpp 2022-08-01 16:40:15 +02:00
GitHub
e31e673550 Update Vulkan-Headers to v1.3.223 2022-07-29 00:09:57 +00:00
asuessenbach
056abda3e2 Reduce number of included headers 2022-07-27 16:39:37 +02:00
asuessenbach
3aae157e5b Move the vk::to_string functions into a separate header vulkan_to_string.hpp. 2022-07-26 11:19:42 +02:00
asuessenbach
527e52a1bd Introduce VULKAN_HPP_NO_TO_STRING to optionally remove the various vk::to_string functions.
Also extend the samples to hold some local version of the needed to_string functions in case VULKAN_HPP_NO_TO_STRING is defined.
2022-07-25 17:11:30 +02:00
GitHub
3e449ebc53 Update Vulkan-Headers to v1.3.222 2022-07-22 00:12:13 +00:00
GitHub
e6ea601adb Update Vulkan-Headers to v1.3.221 2022-07-15 00:12:11 +00:00
github-actions[bot]
85fba669da
Update Vulkan-Headers to v1.3.220 (#1349)
Co-authored-by: GitHub <noreply@github.com>
2022-07-11 10:35:37 +02:00
GitHub
93f8b6b541 Update Vulkan-Headers to v1.3.219 2022-07-01 00:11:04 +00:00
Andreas Süßenbach
94244d51d5
Merge pull request #1329 from asuessenbach/spaceship
Change used check for using spaceship operator from "impl" to "lib".
2022-06-20 11:28:48 +02:00
asuessenbach
cbb02bf5ab Change used check for using spaceship operator from "impl" to "lib". 2022-06-20 09:32:27 +02:00
GitHub
2b55b3382d Update Vulkan-Headers to v1.3.218 2022-06-17 00:09:45 +00:00
GitHub
1dc2a0eeaf Update Vulkan-Headers to v1.3.217 2022-06-10 00:09:44 +00:00
GitHub
dd45c179bb Update Vulkan-Headers to v1.3.216 2022-06-03 00:09:17 +00:00
GitHub
e777f1d1d2 Update Vulkan-Headers to v1.3.215 2022-05-25 00:11:11 +00:00
GitHub
21e1f09d49 Update Vulkan-Headers to v1.3.214 2022-05-18 00:10:20 +00:00
asuessenbach
66c3c89d8e Combine two types of commands into one generation function 2022-05-17 10:35:57 +02:00
GitHub
21448e0ace Update Vulkan-Headers to v1.3.213 2022-05-11 00:09:28 +00:00
asuessenbach
f9ad86aef8 Remove deprecated implicit-cast operators on vk::ResultValue. 2022-05-03 09:47:58 +02:00
asuessenbach
145c10e945 Combine two types of commands into one generation function 2022-05-02 17:01:38 +02:00
asuessenbach
e5921db439 Combine two types of commands into one generation function 2022-04-26 12:35:15 +02:00
GitHub
0495d69c6d Update Vulkan-Headers to v1.3.212 2022-04-22 00:10:35 +00:00
Andreas Süßenbach
828ac8e246
Merge pull request #1288 from phantom10111/array-proxy-with-raw-arrays
Add ArrayProxy constructors with support for raw array with size
2022-04-19 17:38:31 +02:00
phantom10111
5df998c0d6 Add ArrayProxy constructors with support for raw array with size
There's a little known C language family feature, which makes it
possible to take a pointer or reference to an array with size. Use this
feature to add constructors to ArrayProxy and ArrayProxyNoTemporaries
which can wrap raw arrays and deduce their size automatically.
2022-04-19 11:49:09 +02:00
phantom10111
9e95c0072d Make type conversions implicit for dispatchable handles
Vulkan handles are not typesafe on 32-bit platforms, but only for
non-dispachable handles. Dispatchable handles are opaque struct pointers
on all platforms, and thus typesafe.

This commit makes all conversions for dispatchable handles implicit,
regardless of VULKAN_HPP_TYPESAFE_CONVERSION setting.
2022-04-15 11:24:30 +02:00
asuessenbach
956cda998b Combine two types of commands into one generation function. 2022-04-12 13:56:21 +02:00
asuessenbach
26e2fc42c8 Combine two types of commands into one generation function. 2022-04-07 16:04:26 +02:00
asuessenbach
d50485c5c7 Combine two types of commands into one generation function. 2022-04-07 08:48:55 +02:00
GitHub
da42600e06 Update Vulkan-Headers to v1.3.211 2022-04-06 00:09:05 +00:00
asuessenbach
dd6deccf52 Add missing allocator template argument in createResultValue helper functions working on std::vector<UniqueHandle> types. 2022-04-04 10:00:13 +02:00
asuessenbach
5190cd09ff Update Vulkan-Headers to v1.3.210 2022-03-30 11:52:35 +02:00
asuessenbach
16a44bb94f Re-add accidentally removed version of createResultValue
+ add test project for UniqueHandles.
2022-03-30 09:45:51 +02:00
asuessenbach
a8d47f4694 Combine two types of commands into one generation function. 2022-03-28 17:52:45 +02:00
asuessenbach
439ac7fe26 Update Vulkan-Headers to v1.3.209 2022-03-24 09:51:10 +01:00
asuessenbach
dfffc95731 Update Vulkan-Headers to v1.3.208 2022-03-16 12:19:09 +01:00
asuessenbach
c761497d36 Update Vulkan-Headers to v1.3.207 2022-03-16 09:09:01 +01:00
asuessenbach
611365b986 Updated clang_format options 2022-03-09 12:28:52 +01:00
asuessenbach
4fd8ad4baa Minor cleanup work in command generation. 2022-03-09 10:13:51 +01:00
asuessenbach
ffead3984d Add some support of attribute "altlen" on command parameters. 2022-03-02 09:51:12 +01:00
GitHub
eccc252a98 Update Vulkan-Headers to v1.3.206 2022-03-01 00:09:13 +00:00
asuessenbach
5fe410279a Change ColumnLimit with clang-format from 120 to 160. 2022-02-28 10:11:04 +01:00
GitHub
47520a1025 Update Vulkan-Headers to v1.3.206 2022-02-19 00:07:27 +00:00
asuessenbach
1b12dd8cbb Enclose "free" in parenthesis to prevent interference with MSVC's debug free 2022-02-10 09:49:24 +01:00
Andreas Süßenbach
bc5b7fb5fe
Merge pull request #1194 from KhronosGroup/update-vulkan-headers-pr
Update Vulkan-Headers to v1.3.205
2022-02-07 13:56:40 +01:00
GitHub
1e95dfbb80 Update Vulkan-Headers to v1.3.205 2022-02-06 00:45:04 +00:00