You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: chapters/checking_for_support.adoc
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,4 +82,4 @@ View the link:https://vulkan.lunarg.com/doc/sdk/latest/windows/via.html[SDK docu
82
82
83
83
A simple way to check for Vulkan support cross platform is to create a simple "`Hello World`" Vulkan application. The `vkCreateInstance` function is used to create a Vulkan Instance and is also the shortest way to write a valid Vulkan application.
84
84
85
-
The Vulkan SDK provides a minimal link:https://vulkan.lunarg.com/doc/view/latest/windows/tutorial/html/01-init_instance.html[vkCreateInstance] example `01-init_instance.cpp` that can be used.
85
+
The Vulkan SDK provides a minimal link:https://docs.vulkan.org/tutorial/latest/03_Drawing_a_triangle/00_Setup/01_Instance.html[vkCreateInstance] example `01-init_instance.cpp` that can be used.
* *Android Baseline 2022* - A baseline profile specifically for Android devices (link:https://vulkan.lunarg.com/doc/sdk/latest/windows/profiles_api_library.html[Documentation], link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/profiles/VP_ANDROID_baseline_2022.json[JSON Definition])
58
-
* *Roadmap 2022* - A forward-looking profile that hardware vendors are encouraged to support in future implementations (link:https://vulkan.lunarg.com/doc/sdk/latest/windows/profiles_api_library.html[Documentation], link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/profiles/VP_KHR_roadmap_2022.json[JSON Definition])
59
+
* *Roadmap 2024* - A forward-looking profile that hardware vendors are
60
+
encouraged to support in future implementations (link:https://vulkan.lunarg.com/doc/sdk/latest/windows/profiles_api_library.html[Documentation],
These profiles are versioned by year to allow for evolution over time while maintaining backward compatibility. You can find sample code demonstrating the use of these profiles in the link:https://github.com/KhronosGroup/Vulkan-Samples/tree/main/samples/tooling/profiles[Vulkan-Samples repository].
61
64
@@ -116,17 +119,30 @@ Profiles use a year-based versioning scheme (e.g., 2022, 2023) to indicate when
116
119
117
120
* Provides clear temporal context for each profile
118
121
* Allows for the creation of new profiles that reflect evolving hardware capabilities
119
-
* Maintains backward compatibility, as older profiles remain valid even as
120
-
new ones are introduced. This is a feature of the design of the profiles,
121
-
yet sometimes, there are rare instances where the older profiles are updated
122
-
due to newly released hardware.
122
+
* Maintains backward compatibility, as older profiles are only updated to fix shortcomings or issues.
123
123
124
124
When a new yearly profile is released, it typically includes all the capabilities of the previous year's profile plus additional features and possibly higher limits, reflecting the advancement of hardware capabilities.
125
125
126
126
== Using Vulkan Profiles
127
127
128
128
There are two main ways to use Vulkan Profiles to initialize a Vulkan application:
129
129
130
+
=== Automatic Feature Enabling
131
+
132
+
One of the key benefits of using the Vulkan Profiles library is that it automatically handles the enabling of all required features, extensions, and properties defined in a profile. This eliminates the need to manually:
133
+
134
+
* Track and enable each required extension
135
+
* Set up feature structures for each feature you need
136
+
* Configure property structures for specific requirements
137
+
138
+
When you call `profile.ConfigureDeviceCreation()`, the library automatically:
139
+
140
+
1. Populates the device creation info with all necessary extensions
141
+
2. Sets up the feature chain with all required features enabled
142
+
3. Configures any required properties
143
+
144
+
This significantly simplifies device initialization and reduces the chance of errors from forgetting to enable specific features or extensions.
145
+
130
146
=== 1. Using the Vulkan Profiles header
131
147
132
148
The simplest way to use Vulkan Profiles is through the Vulkan Profiles header (`vulkan_profiles.hpp`), which is available in the link:https://vulkan.lunarg.com/sdk/home[Vulkan SDK]. This header provides a C++ API that simplifies working with profiles. The header is documented in the link:https://github.com/KhronosGroup/Vulkan-Profiles/tree/main[Vulkan-Profiles library documentation]:
@@ -157,8 +173,7 @@ if (supported) {
157
173
=== 2. Using the Vulkan Profiles, JSON files directly
158
174
159
175
For more advanced use cases, you can work with the JSON profile definitions
160
-
directly. The JSON schema is documented in the link:https://github
Integrating Vulkan Profiles into an existing Vulkan application involves several steps, which are described in the link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/library/README.md#integrating-with-existing-applications[Vulkan-Profiles library documentation]:
370
+
Integrating Vulkan Profiles into an existing Vulkan application involves several steps, which are described in the link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/library/TUTORIAL.md[Vulkan-Profiles library documentation]:
356
371
357
372
1. *Identify Target Profiles*: Determine which profiles best match your application's requirements
358
373
2. *Add Profile Support*: Incorporate the Vulkan Profiles header or JSON handling
@@ -423,7 +438,7 @@ To optimize performance when using profiles:
423
438
424
439
== Troubleshooting and Common Issues
425
440
426
-
When working with Vulkan Profiles, developers might encounter several common issues. The link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/library/README.md#troubleshooting[Vulkan-Profiles library documentation] provides guidance on troubleshooting, and the link:https://github.com/KhronosGroup/Vulkan-ValidationLayers/blob/main/docs/khronos_validation_layer.md[Vulkan Validation Layers documentation] can help identify issues with profile usage:
441
+
When working with Vulkan Profiles, developers might encounter several common issues. The link:https://github.com/KhronosGroup/Vulkan-Profiles/blob/main/library/TUTORIAL.md[Vulkan-Profiles library documentation] provides guidance on troubleshooting, and the link:https://github.com/KhronosGroup/Vulkan-ValidationLayers/blob/main/docs/khronos_validation_layer.md[Vulkan Validation Layers documentation] can help identify issues with profile usage:
427
442
428
443
=== Profile Isn't Supported
429
444
@@ -476,6 +491,7 @@ Using Vulkan Profiles offers several advantages:
476
491
477
492
1. *Simplified Development*
478
493
- Reduces the complexity of checking for individual features and extensions
494
+
- *Automatically enables all required features and extensions* without manual configuration
479
495
2. *Better Compatibility*
480
496
- Ensures your application works consistently across different devices
481
497
3. *Future-Proofing*
@@ -488,6 +504,8 @@ Using Vulkan Profiles offers several advantages:
488
504
- Provides a well-defined baseline that hardware vendors can target
489
505
7. *Easier Porting*
490
506
- Simplifies the process of porting applications between different platforms
507
+
8. *Reduced Boilerplate Code*
508
+
- Eliminates the need to write extensive feature and extension enabling code
0 commit comments