From e8cbffbd2548d26915f7a52bbff1204d7407fd09 Mon Sep 17 00:00:00 2001 From: Jon Leech Date: Sat, 25 Mar 2017 01:46:58 -0700 Subject: [PATCH] Change log for March 24, 2017 Vulkan 1.0.45 spec update: * Bump API patch number and header version number to 45 for this update. Github Issues: * Defined the lifetime of the memory pointed to by slink:VkDisplayPropertiesKHR::pname:displayName to be equal to that of its associated display handle (public issue 460). * Correct several cases where the sparse memory feature name pname:residencyNonResidentStrict was written as pname:sparseResidencyNonResidentStrict (public issue 475). Internal Issues: * Fix ptext:pNext member of slink:VkPhysicalDeviceGroupPropertiesKHX to be a non-const pointer. Properties structures return values, so the chain should be non-const. * Clarify definition of memory aliasing to consistently use the terms "linear" and "non-linear" when referring to resources, and define what those terms mean. * Modified XML schema and implicit validity scripts to generate language for all ptext:pNext values in a ptext:pNext chain instead of just the top level struct, and made `noautovalidity` functional for ptext:sType and ptext:pNext (internal issue 535). * Add more detail for BT2020 and scRGB color spaces in `VK_EXT_swapchain_colorspace` extension (internal issue 632). * Add naming rules for Extension Structure Names (structures added to the ptext:pNext chain of a base structure) to the style guide (internal issue 706). * Define the glossary term "ptext:pNext chain", and use it consistently in the spec (internal issue 744). New Extensions: --- ChangeLog.txt | 35 +++ doc/specs/vulkan/Makefile | 2 +- doc/specs/vulkan/README.adoc | 13 + .../VK_EXT_swapchain_colorspace.txt | 119 ++------- ...VK_KHR_get_physical_device_properties2.txt | 14 +- doc/specs/vulkan/appendices/glossary.txt | 11 + .../vulkan/chapters/VK_EXT_debug_report.txt | 39 ++- .../display_control.txt | 4 +- .../VK_EXT_display_control/fence_events.txt | 8 +- .../surface_capabilities.txt | 3 +- .../chapters/VK_EXT_validation_flags.txt | 3 +- .../PresentTimeInfo.txt | 2 +- .../chapters/VK_KHR_display/display.txt | 2 + .../vulkan/chapters/VK_KHR_surface/wsi.txt | 226 ++++++++++++++++-- .../vertexpostproc.txt | 8 +- doc/specs/vulkan/chapters/cmdbuffers.txt | 25 +- doc/specs/vulkan/chapters/descriptorsets.txt | 17 +- doc/specs/vulkan/chapters/devsandqueues.txt | 2 +- doc/specs/vulkan/chapters/features.txt | 62 +++-- doc/specs/vulkan/chapters/fragops.txt | 7 +- doc/specs/vulkan/chapters/fundamentals.txt | 6 +- doc/specs/vulkan/chapters/fxvertex.txt | 3 +- doc/specs/vulkan/chapters/initialization.txt | 2 +- doc/specs/vulkan/chapters/memory.txt | 40 +++- doc/specs/vulkan/chapters/pipelines.txt | 5 +- doc/specs/vulkan/chapters/primsrast.txt | 12 +- doc/specs/vulkan/chapters/queries.txt | 12 +- doc/specs/vulkan/chapters/renderpass.txt | 30 ++- doc/specs/vulkan/chapters/resources.txt | 78 +++--- doc/specs/vulkan/chapters/samplers.txt | 27 ++- doc/specs/vulkan/chapters/sparsemem.txt | 23 +- doc/specs/vulkan/chapters/synchronization.txt | 16 +- doc/specs/vulkan/chapters/textures.txt | 19 +- doc/specs/vulkan/chapters/vertexpostproc.txt | 28 +-- doc/specs/vulkan/config/extDependency.py | 3 +- doc/specs/vulkan/config/extDependency.sh | 3 +- doc/specs/vulkan/registry.txt | 11 +- doc/specs/vulkan/style/extensions.txt | 4 + doc/specs/vulkan/style/naming.txt | 43 ++++ doc/specs/vulkan/style/writing.txt | 4 + doc/specs/vulkan/styleguide.txt | 2 + src/spec/validitygenerator.py | 46 ++-- src/spec/vk.xml | 92 +++---- src/vulkan/vulkan.h | 25 +- 44 files changed, 746 insertions(+), 390 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 63b2b6f0..86867b2f 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -8,6 +8,41 @@ public issues. ----------------------------------------------------- +Change log for March 24, 2017 Vulkan 1.0.45 spec update: + + * Bump API patch number and header version number to 45 for this update. + +Github Issues: + + * Defined the lifetime of the memory pointed to by + slink:VkDisplayPropertiesKHR::pname:displayName to be equal to that of + its associated display handle (public issue 460). + * Correct several cases where the sparse memory feature name + pname:residencyNonResidentStrict was written as + pname:sparseResidencyNonResidentStrict (public issue 475). + +Internal Issues: + + * Fix ptext:pNext member of slink:VkPhysicalDeviceGroupPropertiesKHX to be + a non-const pointer. Properties structures return values, so the chain + should be non-const. + * Clarify definition of memory aliasing to consistently use the terms + "linear" and "non-linear" when referring to resources, and define what + those terms mean. + * Modified XML schema and implicit validity scripts to generate language + for all ptext:pNext values in a ptext:pNext chain instead of just the + top level struct, and made `noautovalidity` functional for ptext:sType + and ptext:pNext (internal issue 535). + * Add more detail for BT2020 and scRGB color spaces in + `VK_EXT_swapchain_colorspace` extension (internal issue 632). + * Add naming rules for Extension Structure Names (structures added to the + ptext:pNext chain of a base structure) to the style guide (internal + issue 706). + * Define the glossary term "ptext:pNext chain", and use it consistently in + the spec (internal issue 744). + +----------------------------------------------------- + Change log for March 17, 2017 Vulkan 1.0.44 spec update: * Bump API patch number and header version number to 44 for this update. diff --git a/doc/specs/vulkan/Makefile b/doc/specs/vulkan/Makefile index b488df7d..8fbda610 100644 --- a/doc/specs/vulkan/Makefile +++ b/doc/specs/vulkan/Makefile @@ -86,7 +86,7 @@ VERBOSE = # $(EXTENSIONS)) # ADOCOPTS options for asciidoc->HTML5 output NOTEOPTS = -a editing-notes -a implementation-guide -SPECREVISION = 1.0.44 +SPECREVISION = 1.0.45 # Spell out RFC2822 format as not all date commands support -R SPECDATE = $(shell echo `date -u "+%a, %d %b %Y %T %z"`) diff --git a/doc/specs/vulkan/README.adoc b/doc/specs/vulkan/README.adoc index efa00c2a..7bf41151 100644 --- a/doc/specs/vulkan/README.adoc +++ b/doc/specs/vulkan/README.adoc @@ -731,6 +731,8 @@ gem install --pre asciidoctor-pdf [[ruby-enum-downgrade]] ==== Ruby Gem Versioning Errors +*ruby-enum* + As of 2017-03-06, there appears to be a problem with the ruby-enum version 0.7.1 gem which breaks the PDF build. Make sure you are using ruby-enum 0.7.0, as follows: @@ -743,9 +745,20 @@ https://github.com/gjtorikian/mathematical/issues/69 for a report of this problem. +*prawn* + +As of 2017-03-20, there are incompatibilities between asciidoctor-pdf and +certain versions of prawn and prawn-templates affecting the PDF build. Make +sure to update to prawn 2.2.1 and prawn-templates 0.0.5. See + +https://github.com/KhronosGroup/Vulkan-Docs/issues/476 + + [[history]] == Revision History + * 2017-03-20 - Add description of prawn versioning problem and how to fix + it. * 2017-03-06 - Add description of ruby-enum versioning problem and how to fix it. * 2017-02-13 - Move some comments here from ../../../README.md. Tweak diff --git a/doc/specs/vulkan/appendices/VK_EXT_swapchain_colorspace.txt b/doc/specs/vulkan/appendices/VK_EXT_swapchain_colorspace.txt index 4090e829..01245b12 100644 --- a/doc/specs/vulkan/appendices/VK_EXT_swapchain_colorspace.txt +++ b/doc/specs/vulkan/appendices/VK_EXT_swapchain_colorspace.txt @@ -8,7 +8,7 @@ *Registered Extension Number*:: 105 *Last Modified Date*:: - 2017-01-13 + 2017-03-15 *Revision*:: 1 *IP Status*:: @@ -21,107 +21,13 @@ *Contacts*:: - Courtney Goeltzenleuchter, Google -This extension defines enums for elink:VkColorSpaceKHR that correspond to -the following color spaces:: - -[[VK_EXT_swapchain_colorspace-table]] -.Color Spaces and Attributes -[options="header"] -|==== -| Name | Red Primary | Green Primary | Blue Primary | White-point | OETF -| DCI-P3 | 0.680, 0.320 | 0.265, 0.690 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | Gamma 2.6 -| Display-P3 | 0.680, 0.320 | 0.265, 0.690 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | sRGB -| BT709 | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | SMPTE 170M -| sRGB | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | sRGB -| scRGB | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | scRGB -| BT2020 | 0.708, 0.292 | 0.170, 0.797 | 0.131, 0.046 | 0.3127, 0.3290 (D65) | SMPTE 170M -| AdobeRGB | 0.640, 0.330 | 0.210, 0.710 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | Gamma 2.2 -|==== - -For Opto-Electrical Transfer Function (OETF), unless otherwise specified, -the values of [eq]#L# and [eq]#E# are defined as: - -[eq]#L# - luminance of image [eq]#0 {leq} L {leq} 1# for conventional -colorimetry - -[eq]#E# - corresponding electrical signal (value stored in memory) - -=== sRGB OETF - -[latexmath] -+++++++++++++++++++ -\begin{aligned} -E & = - \begin{cases} - 1.055 \times L^{1 \over 2.4} - 0.055 & \text{for}\ 0.0031308 \leq L \leq 1 \\ - 12.92 \times L & \text{for}\ 0 \leq L < 0.0031308 - \end{cases} -\end{aligned} -+++++++++++++++++++ - -=== scRGB OETF - -[latexmath] -+++++++++++++++++++ -\begin{aligned} -E & = - \begin{cases} - 1.055 \times L^{1 \over 2.4} - 0.055 & \text{for}\ 0.0031308 \leq L \leq 7.5913 \\ - 12.92 \times L & \text{for}\ 0 \leq L < 0.0031308 \\ - -E \times -L & \text{for}\ L < 0 - \end{cases} -\end{aligned} -+++++++++++++++++++ - -[eq]#L# - luminance of image is within [eq]#[-0.6038, 7.5913]#. - -[eq]#E# can be negative and/or > 1. -That is how scRGB specifies colors outside the standard sRGB gamut. - -=== SMPTE 170M OETF - -[latexmath] -+++++++++++++++++++ -\begin{aligned} -E & = - \begin{cases} - 1.099 \times L^0.45 - 0.099 & \text{for}\ 0.018 \leq L \leq 1 \\ - 4.5 \times L & \text{for}\ 0 \leq L < 0.018 - \end{cases} -\end{aligned} -+++++++++++++++++++ - -=== Display Gamma 2.2 OETF - -latexmath:[$E = L^{1 \over 2.2}$] - -=== Display Gamma 2.6 OETF - -latexmath:[$E = L^{1 \over 2.6}$] - -An implementation supporting this extension indicates support for these -color spaces via slink:VkSurfaceFormatKHR structures returned from -flink:vkGetPhysicalDeviceSurfaceFormatsKHR. - -Specifying the supported surface color space when calling -flink:vkCreateSwapchainKHR will create a swapchain using that color space. - -Vulkan requires that all implementations support the sRGB OETF and EOTF when -using an SRGB pixel format. -Other transfer functions, such as SMPTE 170M, must: not be performed by the -implementation, but can: be performed by the application shader. - === New Enum Constants * Extending elink:VkColorSpaceKHR: - ** ename:VK_COLOR_SPACE_DISPLAY_P3_LINEAR_EXT - supports the Display-P3 - color space and applies a linear OETF. ** ename:VK_COLOR_SPACE_DISPLAY_P3_NONLINEAR_EXT - supports the Display-P3 - color space and applies the sRGB OETF. - ** ename:VK_COLOR_SPACE_SCRGB_LINEAR_EXT - supports the scRGB color space - and applies a linear OETF. - ** ename:VK_COLOR_SPACE_SCRGB_NONLINEAR_EXT - supports the scRGB color - space and applies the scRGB OETF. + color space and applies an sRGB-like OETF. + ** ename:VK_COLOR_SPACE_EXTENDED_SRGB_LINEAR_EXT - supports the extended + sRGB color space and applies a linear OETF. ** ename:VK_COLOR_SPACE_DCI_P3_LINEAR_EXT - supports the DCI-P3 color space and applies a linear OETF. ** ename:VK_COLOR_SPACE_DCI_P3_NONLINEAR_EXT - supports the DCI-P3 color @@ -132,12 +38,19 @@ implementation, but can: be performed by the application shader. space and applies the SMPTE 170M OETF. ** ename:VK_COLOR_SPACE_BT2020_LINEAR_EXT - supports the BT2020 color space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_BT2020_NONLINEAR_EXT - supports the BT2020 color - space and applies the SMPTE 170M OETF. + ** ename:VK_COLOR_SPACE_HDR10_ST2084_EXT - supports HDR10 (BT2020 color + space and applies the SMPTE ST2084 Perceptual Quantizer (PQ) OETF). + ** ename:VK_COLOR_SPACE_DOLBYVISION_EXT - supports Dolby Vision (BT2020 + color space, proprietary encoding, and applies the SMPTE ST2084 OETF). + ** ename:VK_COLOR_SPACE_HDR10_HLG_EXT - supports HDR10 (BT2020 color space + and applies the Hybrid Log Gamma (HLG) OETF). ** ename:VK_COLOR_SPACE_ADOBERGB_LINEAR_EXT - supports the AdobeRGB color space and applies a linear OETF. ** ename:VK_COLOR_SPACE_ADOBERGB_NONLINEAR_EXT - supports the AdobeRGB color space and applies the Gamma 2.2 OETF. + ** ename:VK_COLOR_SPACE_PASS_THROUGH_EXT - color components used "as is". + Intended to allow application to supply data for color spaces not + described here. === Issues @@ -157,8 +70,14 @@ function for a colorspace? *RESOLVED*: Extension indicates that implementation must: not do the OETF encoding if it is not sRGB. That responsibility falls to the application shaders. +Any other native OETF / EOTF functions supported by an implementation can be +described by separate extension. === Version History * Revision 1, 2016-12-27 (Courtney Goeltzenleuchter) - Initial version + + * Revision 2, 2017-01-19 (Courtney Goeltzenleuchter) + - Add pass through and multiple options for BT2020. + - Clean up some issues with equations not displaying properly. diff --git a/doc/specs/vulkan/appendices/VK_KHR_get_physical_device_properties2.txt b/doc/specs/vulkan/appendices/VK_KHR_get_physical_device_properties2.txt index 740996e6..79b3d49d 100644 --- a/doc/specs/vulkan/appendices/VK_KHR_get_physical_device_properties2.txt +++ b/doc/specs/vulkan/appendices/VK_KHR_get_physical_device_properties2.txt @@ -29,14 +29,16 @@ This extension provides new entry points to query device features, device properties, and format properties in a way that can be easily extended by other extensions, without introducing any further entry points. -The Vulkan 1.0 feature/limit/formatproperty structures do not include an -sType/pNext, this extension wraps them in new structures with sType/pNext so -an application can query a chain of feature/limit/formatproperty structures -by constructing the chain and letting the implementation fill them in. +The Vulkan 1.0 feature/limit/formatproperty structures do not include +ptext:sType/ptext:pNext members. +This extension wraps them in new structures with ptext:sType/ptext:pNext +members, so an application can query a chain of feature/limit/formatproperty +structures by constructing the chain and letting the implementation fill +them in. A new command is added for each ftext:vkGetPhysicalDevice* command in core Vulkan 1.0. -The new feature structure (and a chain of extensions) can also be passed in -to device creation to enable features. +The new feature structure (and a chain of extension structures) can also be +passed in to device creation to enable features. This extension also allows applications to use the physical-device components of device extensions before flink:vkCreateDevice is called. diff --git a/doc/specs/vulkan/appendices/glossary.txt b/doc/specs/vulkan/appendices/glossary.txt index e3f5f75b..50b8cfa7 100644 --- a/doc/specs/vulkan/appendices/glossary.txt +++ b/doc/specs/vulkan/appendices/glossary.txt @@ -606,6 +606,13 @@ Invocation Group:: execute the same control flow path in order for control flow to be considered dynamically uniform. +[[glossary-linear-resource]] +Linear Resource:: + A resource is _linear_ if it is a slink:VkBuffer, or a slink:VkImage + created with ename:VK_IMAGE_TILING_LINEAR. + A resource is _non-linear_ if it is a slink:VkImage created with + ename:VK_IMAGE_TILING_OPTIMAL. + Local Workgroup:: A collection of compute shader invocations invoked by a single dispatch command, which share shared memory and can synchronize with each other. @@ -742,6 +749,10 @@ Pipeline Stage:: A logically independent execution unit that performs some of the operations defined by an action command. +pname:pNext Chain:: + A set of structures <> + through their ptext:pNext members. + Point Sampling (Rasterization):: A rule that determines whether a fragment sample location is covered by a polygon primitive by testing whether the sample location is in the diff --git a/doc/specs/vulkan/chapters/VK_EXT_debug_report.txt b/doc/specs/vulkan/chapters/VK_EXT_debug_report.txt index 60622a1c..2a9a5ed3 100644 --- a/doc/specs/vulkan/chapters/VK_EXT_debug_report.txt +++ b/doc/specs/vulkan/chapters/VK_EXT_debug_report.txt @@ -61,27 +61,26 @@ include::../api/structs/VkDebugReportCallbackCreateInfoEXT.txt[] // refBegin VkDebugReportFlagBitsEXT Bitmask specifying events which cause a debug report callback include::../api/enums/VkDebugReportFlagBitsEXT.txt[] - * ename:VK_DEBUG_REPORT_ERROR_BIT_EXT indicates an error that may cause - undefined results, including an application crash. - * ename:VK_DEBUG_REPORT_WARNING_BIT_EXT indicates use of Vulkan that may - expose an app bug. - Such cases may not be immediately harmful, such as a fragment shader - outputting to a location with no attachment. - Other cases may point to behavior that is almost certainly bad when - unintended such as using an image whose memory has not been filled. - In general if you see a warning but you know that the behavior is - intended/desired, then simply ignore the warning. - * ename:VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT indicates a - potentially non-optimal use of Vulkan. - E.g. using flink:vkCmdClearColorImage when a RenderPass load_op would - have worked. - * ename:VK_DEBUG_REPORT_INFORMATION_BIT_EXT indicates an informational - message such as resource details that may be handy when debugging an - application. - * ename:VK_DEBUG_REPORT_DEBUG_BIT_EXT indicates diagnostic information - from the loader and layers. + ** ename:VK_DEBUG_REPORT_ERROR_BIT_EXT indicates an error that may cause + undefined results, including an application crash. + ** ename:VK_DEBUG_REPORT_WARNING_BIT_EXT indicates use of Vulkan that may + expose an app bug. + Such cases may not be immediately harmful, such as a fragment shader + outputting to a location with no attachment. + Other cases may point to behavior that is almost certainly bad when + unintended such as using an image whose memory has not been filled. + In general if you see a warning but you know that the behavior is + intended/desired, then simply ignore the warning. + ** ename:VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT indicates a + potentially non-optimal use of Vulkan. + E.g. using flink:vkCmdClearColorImage when a RenderPass load_op would + have worked. + ** ename:VK_DEBUG_REPORT_INFORMATION_BIT_EXT indicates an informational + message such as resource details that may be handy when debugging an + application. + ** ename:VK_DEBUG_REPORT_DEBUG_BIT_EXT indicates diagnostic information + from the loader and layers. -- -+ * pname:pfnCallback is the application callback function to call. * pname:pUserData is user data to be passed to the callback. diff --git a/doc/specs/vulkan/chapters/VK_EXT_display_control/display_control.txt b/doc/specs/vulkan/chapters/VK_EXT_display_control/display_control.txt index d7e26108..05305a7f 100644 --- a/doc/specs/vulkan/chapters/VK_EXT_display_control/display_control.txt +++ b/doc/specs/vulkan/chapters/VK_EXT_display_control/display_control.txt @@ -27,8 +27,7 @@ include::../../api/structs/VkDisplayPowerInfoEXT.txt[] -- // refBegin VkDisplayPowerStateEXT Possible power states for a VkDisplay include::../../api/enums/VkDisplayPowerStateEXT.txt[] --- -+ + ** ename:VK_DISPLAY_POWER_STATE_OFF_EXT means the display is powered down. ** ename:VK_DISPLAY_POWER_STATE_SUSPEND_EXT means the display is in a low power mode, but may: be able to transition back to @@ -36,5 +35,6 @@ include::../../api/enums/VkDisplayPowerStateEXT.txt[] ename:VK_DISPLAY_POWER_STATE_OFF_EXT. This state may: be the same as ename:VK_DISPLAY_POWER_STATE_OFF_EXT. ** ename:VK_DISPLAY_POWER_STATE_ON_EXT is powered on. +-- include::../../validity/structs/VkDisplayPowerInfoEXT.txt[] diff --git a/doc/specs/vulkan/chapters/VK_EXT_display_control/fence_events.txt b/doc/specs/vulkan/chapters/VK_EXT_display_control/fence_events.txt index 24417e05..1374c1be 100644 --- a/doc/specs/vulkan/chapters/VK_EXT_display_control/fence_events.txt +++ b/doc/specs/vulkan/chapters/VK_EXT_display_control/fence_events.txt @@ -36,12 +36,12 @@ include::../../api/structs/VkDeviceEventInfoEXT.txt[] -- // refBegin VkDeviceEventTypeEXT Events that can occur on a device object include::../../api/enums/VkDeviceEventTypeEXT.txt[] --- -+ + ** ename:VK_DEVICE_EVENT_TYPE_DISPLAY_HOTPLUG_EXT occurs when a display is plugged into or unplugged from the specified device. Applications can: use this notification to determine when they need to re-enumerate the available displays on a device. +-- include::../../validity/structs/VkDeviceEventInfoEXT.txt[] @@ -78,10 +78,10 @@ include::../../api/structs/VkDisplayEventInfoEXT.txt[] -- // refBegin VkDisplayEventTypeEXT Events that can occur on a display object include::../../api/enums/VkDisplayEventTypeEXT.txt[] --- -+ + ** ename:VK_DISPLAY_EVENT_TYPE_FIRST_PIXEL_OUT_EXT occurs when the first pixel of the next display refresh cycle leaves the display engine for the display. +-- include::../../validity/structs/VkDisplayEventInfoEXT.txt[] diff --git a/doc/specs/vulkan/chapters/VK_EXT_display_surface_counter/surface_capabilities.txt b/doc/specs/vulkan/chapters/VK_EXT_display_surface_counter/surface_capabilities.txt index 14ea613f..effa5910 100644 --- a/doc/specs/vulkan/chapters/VK_EXT_display_surface_counter/surface_capabilities.txt +++ b/doc/specs/vulkan/chapters/VK_EXT_display_surface_counter/surface_capabilities.txt @@ -15,7 +15,8 @@ include::../../api/protos/vkGetPhysicalDeviceSurfaceCapabilities2EXT.txt[] fname:vkGetPhysicalDeviceSurfaceCapabilities2EXT behaves similarly to flink:vkGetPhysicalDeviceSurfaceCapabilitiesKHR, with the ability to return -extended information via chained output structures. +extended information by adding extension structures to its pname:pNext +chain. include::../../validity/protos/vkGetPhysicalDeviceSurfaceCapabilities2EXT.txt[] diff --git a/doc/specs/vulkan/chapters/VK_EXT_validation_flags.txt b/doc/specs/vulkan/chapters/VK_EXT_validation_flags.txt index 6c1fbefa..5b75b561 100644 --- a/doc/specs/vulkan/chapters/VK_EXT_validation_flags.txt +++ b/doc/specs/vulkan/chapters/VK_EXT_validation_flags.txt @@ -17,7 +17,8 @@ include::../api/structs/VkValidationFlagsEXT.txt[] -- // refBegin VkValidationCheckEXT Specify validation checks to disable include::../api/enums/VkValidationCheckEXT.txt[] --- + ** ename:VK_VALIDATION_CHECK_ALL_EXT disables all validation checks. +-- include::../validity/structs/VkValidationFlagsEXT.txt[] diff --git a/doc/specs/vulkan/chapters/VK_GOOGLE_display_timing/PresentTimeInfo.txt b/doc/specs/vulkan/chapters/VK_GOOGLE_display_timing/PresentTimeInfo.txt index 0df3f6e7..b82e825f 100644 --- a/doc/specs/vulkan/chapters/VK_GOOGLE_display_timing/PresentTimeInfo.txt +++ b/doc/specs/vulkan/chapters/VK_GOOGLE_display_timing/PresentTimeInfo.txt @@ -32,7 +32,7 @@ include::../../api/structs/VkPresentTimesInfoGOOGLE.txt[] **** * pname:swapchainCount must: be the same value as sname:VkPresentInfoKHR::pname:swapchainCount, where - sname:VkPresentInfoKHR is in the pNext-chain of this + sname:VkPresentInfoKHR is in the pname:pNext chain of this sname:VkPresentTimesInfoGOOGLE structure. **** diff --git a/doc/specs/vulkan/chapters/VK_KHR_display/display.txt b/doc/specs/vulkan/chapters/VK_KHR_display/display.txt index f7c7a0cf..4bccfd56 100644 --- a/doc/specs/vulkan/chapters/VK_KHR_display/display.txt +++ b/doc/specs/vulkan/chapters/VK_KHR_display/display.txt @@ -67,6 +67,8 @@ include::../../api/structs/VkDisplayPropertiesKHR.txt[] the name of the display. Generally, this will be the name provided by the display's EDID. It can: be `NULL` if no suitable name is available. + If not `NULL`, the memory it points to must: remain accessible as long + as pname:display is valid. * pname:physicalDimensions describes the physical width and height of the visible portion of the display, in millimeters. * pname:physicalResolution describes the physical, native, or preferred diff --git a/doc/specs/vulkan/chapters/VK_KHR_surface/wsi.txt b/doc/specs/vulkan/chapters/VK_KHR_surface/wsi.txt index 5c6921ed..be3eccc7 100644 --- a/doc/specs/vulkan/chapters/VK_KHR_surface/wsi.txt +++ b/doc/specs/vulkan/chapters/VK_KHR_surface/wsi.txt @@ -455,34 +455,228 @@ The ename:VkColorSpaceKHR is defined as follows: include::../../api/enums/VkColorSpaceKHR.txt[] +ifndef::VK_EXT_swapchain_colorspace[] * ename:VK_COLOR_SPACE_SRGB_NONLINEAR_KHR: The presentation engine supports the sRGB color space. +endif::VK_EXT_swapchain_colorspace[] ifdef::VK_EXT_swapchain_colorspace[] - ** ename:VK_COLOR_SPACE_SCRGB_LINEAR_EXT - supports the scRGB color space + * ename:VK_COLOR_SPACE_SRGB_NONLINEAR_KHR: The presentation engine + supports the sRGB color space. + * ename:VK_COLOR_SPACE_DISPLAY_P3_NONLINEAR_EXT - supports the Display-P3 + color space and applies an sRGB-like OETF (defined below). + * ename:VK_COLOR_SPACE_EXTENDED_SRGB_LINEAR_EXT - supports the extended + sRGB color space and applies a linear OETF. + * ename:VK_COLOR_SPACE_DCI_P3_LINEAR_EXT - supports the DCI-P3 color space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_SCRGB_NONLINEAR_EXT - supports the scRGB color - space and applies the scRGB OETF. - ** ename:VK_COLOR_SPACE_DCI_P3_LINEAR_EXT - supports the DCI-P3 color - space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_DCI_P3_NONLINEAR_EXT - supports the DCI-P3 color + * ename:VK_COLOR_SPACE_DCI_P3_NONLINEAR_EXT - supports the DCI-P3 color space and applies the Gamma 2.6 OETF. - ** ename:VK_COLOR_SPACE_BT709_LINEAR_EXT - supports the BT709 color space + * ename:VK_COLOR_SPACE_BT709_LINEAR_EXT - supports the BT709 color space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_BT709_NONLINEAR_EXT - supports the BT709 color + * ename:VK_COLOR_SPACE_BT709_NONLINEAR_EXT - supports the BT709 color space and applies the SMPTE 170M OETF. - ** ename:VK_COLOR_SPACE_BT2020_LINEAR_EXT - supports the BT2020 color + * ename:VK_COLOR_SPACE_BT2020_LINEAR_EXT - supports the BT2020 color space + and applies a linear OETF. + * ename:VK_COLOR_SPACE_HDR10_ST2084_EXT - supports HDR10 (BT2020 color) + space and applies the SMPTE ST2084 Perceptual Quantizer (PQ) OETF. + * ename:VK_COLOR_SPACE_DOLBYVISION_EXT - supports Dolby Vision (BT2020 + color space), proprietary encoding, and applies the SMPTE ST2084 OETF. + * ename:VK_COLOR_SPACE_HDR10_HLG_EXT - supports HDR10 (BT2020 color space) + and applies the Hybrid Log Gamma (HLG) OETF. + * ename:VK_COLOR_SPACE_ADOBERGB_LINEAR_EXT - supports the AdobeRGB color space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_BT2020_NONLINEAR_EXT - supports the BT2020 color - space and applies the SMPTE 170M OETF. - ** ename:VK_COLOR_SPACE_ADOBERGB_LINEAR_EXT - supports the AdobeRGB color - space and applies a linear OETF. - ** ename:VK_COLOR_SPACE_ADOBERGB_NONLINEAR_EXT - supports the AdobeRGB + * ename:VK_COLOR_SPACE_ADOBERGB_NONLINEAR_EXT - supports the AdobeRGB color space and applies the Gamma 2.2 OETF. + * ename:VK_COLOR_SPACE_PASS_THROUGH_EXT - color components used "as is". + Intended to allow application to supply data for color spaces not + described here. + The color components of Non-linear color space swap chain images have had the appropriate transfer function applied. Vulkan requires that all implementations support the sRGB OETF and EOTF transfer functions when using an SRGB pixel format. +Other transfer functions, such as SMPTE 170M or SMPTE2084, must: not be +performed by the implementation, but can: be performed by the application +shader. +This extension defines enums for elink:VkColorSpaceKHR that correspond to +the following color spaces:: + +[[VK_EXT_swapchain_colorspace-table]] +.Color Spaces and Attributes +[options="header"] +|==== +| Name | Red Primary | Green Primary | Blue Primary | White-point | OETF +| DCI-P3 | 0.680, 0.320 | 0.265, 0.690 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | Gamma 2.6 +| Display-P3 | 0.680, 0.320 | 0.265, 0.690 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | Display-P3 +| BT709 | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | SMPTE 170M +| sRGB | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | sRGB +| extended sRGB | 0.640, 0.330 | 0.300, 0.600 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | extended sRGB +| HDR10_ST2084 | 0.708, 0.292 | 0.170, 0.797 | 0.131, 0.046 | 0.3127, 0.3290 (D65) | ST2084 +| DOLBYVISION | 0.708, 0.292 | 0.170, 0.797 | 0.131, 0.046 | 0.3127, 0.3290 (D65) | ST2084 +| HDR10_HLG | 0.708, 0.292 | 0.170, 0.797 | 0.131, 0.046 | 0.3127, 0.3290 (D65) | HLG +| AdobeRGB | 0.640, 0.330 | 0.210, 0.710 | 0.150, 0.060 | 0.3127, 0.3290 (D65) | AdobeRGB +|==== + +For Opto-Electrical Transfer Function (OETF), unless otherwise specified, +the values of [eq]#L# and [eq]#E# are defined as: + +[eq]#L# - linear luminance of image latexmath:[0 \leq L \leq 1] for +conventional colorimetry + +[eq]#E# - corresponding electrical signal (value stored in memory) + + +=== sRGB OETF + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + 1.055 \times L^{1 \over 2.4} - 0.055 & \text{for}\ 0.0031308 \leq L \leq 1 \\ + 12.92 \times L & \text{for}\ 0 \leq L < 0.0031308 + \end{cases} +\end{aligned} ++++++++++++++++++++ + + +=== Display-P3 EOTF + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + (a \times L + b)^{2.4} & \text{for}\ 0.039 \leq L \leq 1 \\ + b \times L & \text{for}\ 0 \leq L < 0.039 + \end{cases} +\end{aligned} ++++++++++++++++++++ + +latexmath:[a = 0.948] + +latexmath:[b = 0.052] + +latexmath:[c = 0.077] + + + +=== Display-P3 OETF + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + 1.055 \times L^{1 \over 2.4} - 0.055 & \text{for}\ 0.0030186 \leq L \leq 1 \\ + 12.92 \times L & \text{for}\ 0 \leq L < 0.0030186 + \end{cases} +\end{aligned} ++++++++++++++++++++ + +[NOTE] +.Note +==== +For most uses, the sRGB OETF is equivalent. +==== + + +=== Extended sRGB OETF + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + 1.055 \times L^{1 \over 2.4} - 0.055 & \text{for}\ 0.0031308 \leq L \leq 7.5913 \\ + 12.92 \times L & \text{for}\ 0 \leq L < 0.0031308 \\ + -f(-L) & \text{for}\ L < 0 + \end{cases} +\end{aligned} ++++++++++++++++++++ + +[eq]#L# - luminance of image is within [eq]#[-0.6038, 7.5913]#. + +[eq]#E# can be negative and/or > 1. +That is how extended sRGB specifies colors outside the standard sRGB gamut. +This means extended sRGB needs a floating point pixel format to cover the +intended color range. + + +=== SMPTE 170M OETF + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + \alpha \times L^{0.45} - (1 - \alpha) & \text{for}\ \beta \leq L \leq 1 \\ + 4.5 \times L & \text{for}\ 0 \leq L < \beta + \end{cases} +\end{aligned} ++++++++++++++++++++ + +latexmath:[\alpha = 1.099 \text{ and } \beta = 0.018 \text{ for 10-bits and +less per sample system (the values given in Rec. 709)}] + +latexmath:[\alpha = 1.0993 \text{ and } \beta = 0.0181 \text{ for 12-bits +per sample system}] + + +=== SMPTE ST2084 OETF (Inverse-EOTF) + +[latexmath] ++++++++++++++++++++ +\[ +E = (\frac{c_1 + c_2 \times L^{m_1}}{1 + c_3 \times L^{m_1}})^{m_2} +\] ++++++++++++++++++++ + + where: + +latexmath:[m_1 = 2610 / 4096 \times \frac{1}{4} = 0.1593017578125] + +latexmath:[m_2 = 2523 / 4096 \times 128 = 78.84375] + +latexmath:[c_1 = 3424 / 4096 = 0.8359375 = c3 - c2 + 1] + +latexmath:[c_2 = 2413 / 4096 \times 32 = 18.8515625] + +latexmath:[c_3 = 2392 / 4096 \times 32 = 18.6875] + + + +=== Hybrid Log Gamma (HLG) + +[latexmath] ++++++++++++++++++++ +\begin{aligned} +E & = + \begin{cases} + r \sqrt{L} & \text{for}\ 0 \leq L \leq 1 \\ + a \times \ln(L - b) + c & \text{for}\ 1 < L + \end{cases} +\end{aligned} ++++++++++++++++++++ + +latexmath:[L \text{ - is the signal normalized by the reference white +level}] + +latexmath:[r \text{ - is the reference white level and has a signal value of +0.5}] + +latexmath:[a = 0.17883277 \text{ and } b = 0.28466892 \text{, and } c = +0.55991073] + + +=== AdobeRGB OETF + +latexmath:[E = L^\frac{1}{2.19921875}] + + +=== Gamma 2.6 OETF + +latexmath:[E = L^\frac{1}{2.6}] + +An implementation supporting this extension indicates support for these +color spaces via slink:VkSurfaceFormatKHR structures returned from +flink:vkGetPhysicalDeviceSurfaceFormatsKHR. + +Specifying the supported surface color space when calling +flink:vkCreateSwapchainKHR will create a swapchain using that color space. + +Vulkan requires that all implementations support the sRGB Opto-Electrical +Transfer Function (OETF) and Electro-optical transfer function (EOTF) when +using an SRGB pixel format. Other transfer functions, such as SMPTE 170M, must: not be performed by the implementation, but can: be performed by the application shader. endif::VK_EXT_swapchain_colorspace[] @@ -611,6 +805,7 @@ equivalent to the behavior of {wgl|glX}SwapBuffers with a swap interval of ifdef::VK_KHR_swapchain[] ifdef::VK_KHX_device_group[] + == Device Group Queries // refBegin vkGetDeviceGroupPresentCapabilitiesKHX Query present capabilities from other physical devices @@ -651,7 +846,7 @@ include::../../api/structs/VkDeviceGroupPresentCapabilitiesKHX.txt[] -- // refBegin VkDeviceGroupPresentModeFlagBitsKHX Bitmask specifying supported device group present modes include::../../api/enums/VkDeviceGroupPresentModeFlagBitsKHX.txt[] --- + ** if pname:modes contains ename:VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHX, any physical device with a presentation engine can: present its own swapchain images. @@ -666,6 +861,7 @@ include::../../api/enums/VkDeviceGroupPresentModeFlagBitsKHX.txt[] ename:VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHX, multiple physical devices with a presentation engine can: each present their own swapchain images. +-- pname:modes always has ename:VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHX set. diff --git a/doc/specs/vulkan/chapters/VK_NV_clip_space_w_scaling/vertexpostproc.txt b/doc/specs/vulkan/chapters/VK_NV_clip_space_w_scaling/vertexpostproc.txt index 7a17faa7..19604c8b 100644 --- a/doc/specs/vulkan/chapters/VK_NV_clip_space_w_scaling/vertexpostproc.txt +++ b/doc/specs/vulkan/chapters/VK_NV_clip_space_w_scaling/vertexpostproc.txt @@ -48,10 +48,10 @@ include::../../api/structs/VkPipelineViewportWScalingStateCreateInfoNV.txt[] include::../../validity/structs/VkPipelineViewportWScalingStateCreateInfoNV.txt[] -The sname:VkPipelineViewportWScalingStateCreateInfoNV state is set by -chaining an instance of this structino to the pname:pNext of an instance of -the sname:VkPipelineViewportStateCreateInfo structure and setting the -graphics pipeline state with flink:vkCreateGraphicsPipelines. +The sname:VkPipelineViewportWScalingStateCreateInfoNV state is set by adding +an instance of this structure to the pname:pNext chain of an instance of the +sname:VkPipelineViewportStateCreateInfo structure and setting the graphics +pipeline state with flink:vkCreateGraphicsPipelines. // refBegin vkCmdSetViewportWScalingNV Set the viewport W scaling on a command buffer diff --git a/doc/specs/vulkan/chapters/cmdbuffers.txt b/doc/specs/vulkan/chapters/cmdbuffers.txt index e3c32d69..0eb996df 100644 --- a/doc/specs/vulkan/chapters/cmdbuffers.txt +++ b/doc/specs/vulkan/chapters/cmdbuffers.txt @@ -173,8 +173,7 @@ include::../api/structs/VkCommandPoolCreateInfo.txt[] -- // refBegin VkCommandPoolCreateFlagBits Bitmask specifying usage behavior for a command pool include::../api/enums/VkCommandPoolCreateFlagBits.txt[] --- -+ + ** ename:VK_COMMAND_POOL_CREATE_TRANSIENT_BIT indicates that command buffers allocated from the pool will be short-lived, meaning that they will be reset or freed in a relatively short timeframe. @@ -187,6 +186,7 @@ include::../api/enums/VkCommandPoolCreateFlagBits.txt[] flink:vkBeginCommandBuffer. If this flag is not set on a pool, then fname:vkResetCommandBuffer must: not be called for any command buffer allocated from that pool. +-- * pname:queueFamilyIndex designates a queue family as described in section <>. All command buffers allocated from this command pool must: be submitted @@ -274,11 +274,11 @@ include::../api/protos/vkResetCommandPool.txt[] -- // refBegin VkCommandPoolResetFlagBits Bitmask controlling behavior of a command pool reset include::../api/enums/VkCommandPoolResetFlagBits.txt[] --- -+ + If pname:flags includes ename:VK_COMMAND_POOL_RESET_RELEASE_RESOURCES_BIT, resetting a command pool recycles all of the resources from the command pool back to the system. +-- Resetting a command pool recycles all of the resources from all of the command buffers allocated from the command pool back to the command pool. @@ -381,7 +381,6 @@ include::../api/structs/VkCommandBufferAllocateInfo.txt[] // refBegin VkCommandBufferLevel Structure specifying a command buffer level include::../api/enums/VkCommandBufferLevel.txt[] -- -+ * pname:commandBufferCount is the number of command buffers to allocate from the pool. @@ -408,8 +407,7 @@ include::../api/protos/vkResetCommandBuffer.txt[] -- // refBegin VkCommandBufferResetFlagBits Bitmask controlling behavior of a command buffer reset include::../api/enums/VkCommandBufferResetFlagBits.txt[] --- -+ + If pname:flags includes ename:VK_COMMAND_BUFFER_RESET_RELEASE_RESOURCES_BIT, then most or all memory resources currently owned by the command buffer should: be returned to the parent command pool. @@ -417,6 +415,7 @@ If this flag is not set, then the command buffer may: hold onto memory resources and reuse them when recording commands. pname:commandBuffer is moved to the <>. +-- Any primary command buffer that is in the <> and has pname:commandBuffer recorded into @@ -512,8 +511,7 @@ include::../api/structs/VkCommandBufferBeginInfo.txt[] -- // refBegin VkCommandBufferUsageFlagBits Bitmask specifying usage behavior for command buffer include::../api/enums/VkCommandBufferUsageFlagBits.txt[] --- -+ + ** ename:VK_COMMAND_BUFFER_USAGE_ONE_TIME_SUBMIT_BIT indicates that each recording of the command buffer will only be submitted once, and the command buffer will be reset and recorded again between each @@ -525,6 +523,7 @@ include::../api/enums/VkCommandBufferUsageFlagBits.txt[] ** Setting ename:VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT allows the command buffer to be resubmitted to a queue while it is in the _pending state_, and recorded into multiple primary command buffers. +-- * pname:pInheritanceInfo is a pointer to a sname:VkCommandBufferInheritanceInfo structure, which is used if pname:commandBuffer is a secondary command buffer. @@ -903,14 +902,14 @@ pname:pWaitSemaphoreValues or pname:pSignalSemaphoreValues entry is ignored. .Valid Usage **** - * pname:waitSemaphoreValuesCount must: be the same value as sname:VkSubmitInfo::pname:waitSemaphoreCount, where sname:SubmitInfo is - in the pNext-chain of this sname:VkD3D12FenceSubmitInfoKHX structure. - + in the pname:pNext chain of this sname:VkD3D12FenceSubmitInfoKHX + structure. * pname:signalSemaphoreValuesCount must: be the same value as sname:VkSubmitInfo::pname:signalSemaphoreCount, where sname:SubmitInfo - is in the pNext-chain of this sname:VkD3D12FenceSubmitInfoKHX structure. + is in the pname:pNext chain of this sname:VkD3D12FenceSubmitInfoKHX + structure. **** include::../validity/structs/VkD3D12FenceSubmitInfoKHX.txt[] diff --git a/doc/specs/vulkan/chapters/descriptorsets.txt b/doc/specs/vulkan/chapters/descriptorsets.txt index 1d81d239..893a9a0d 100644 --- a/doc/specs/vulkan/chapters/descriptorsets.txt +++ b/doc/specs/vulkan/chapters/descriptorsets.txt @@ -613,6 +613,14 @@ include::../api/structs/VkDescriptorSetLayoutCreateInfo.txt[] // refBegin VkDescriptorSetLayoutCreateFlagBits Bitmask specifying descriptor set layout properties include::../api/enums/VkDescriptorSetLayoutCreateFlagBits.txt[] +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) This section looks odd unless `VK_KHR_push_descriptor` is enabled, +since no bits are defined for the type. +==== +endif::editing-notes[] ifdef::VK_KHR_push_descriptor[] If pname:flags contains ename:VK_DESCRIPTOR_SET_LAYOUT_CREATE_PUSH_DESCRIPTOR_BIT_KHR, then @@ -1272,8 +1280,7 @@ include::../api/structs/VkDescriptorPoolCreateInfo.txt[] -- // refBegin VkDescriptorPoolCreateFlagBits Bitmask specifying certain supported operations on a descriptor pool include::../api/enums/VkDescriptorPoolCreateFlagBits.txt[] --- -+ + If pname:flags includes ename:VK_DESCRIPTOR_POOL_CREATE_FREE_DESCRIPTOR_SET_BIT, then descriptor sets can: return their individual allocations to the pool, i.e. all of @@ -1282,7 +1289,7 @@ fname:vkResetDescriptorPool are allowed. Otherwise, descriptor sets allocated from the pool must: not be individually freed back to the pool, i.e. only fname:vkAllocateDescriptorSets and fname:vkResetDescriptorPool are allowed. -+ +-- * pname:maxSets is the maximum number of descriptor sets that can: be allocated from the pool. * pname:poolSizeCount is the number of elements in pname:pPoolSizes. @@ -1793,12 +1800,12 @@ This means that ename:VK_WHOLE_SIZE is not typically useful in the common case where uniform buffer descriptors are suballocated from a buffer that is much larger than pname:maxUniformBufferRange. ==== --- -+ + For ename:VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC and ename:VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC descriptor types, pname:offset is the base offset from which the dynamic offset is applied and pname:range is the static size used for all dynamic offsets. +-- .Valid Usage **** diff --git a/doc/specs/vulkan/chapters/devsandqueues.txt b/doc/specs/vulkan/chapters/devsandqueues.txt index 82308300..2e7f24cf 100644 --- a/doc/specs/vulkan/chapters/devsandqueues.txt +++ b/doc/specs/vulkan/chapters/devsandqueues.txt @@ -415,7 +415,7 @@ include::../api/protos/vkGetPhysicalDeviceQueueFamilyProperties2KHR.txt[] fname:vkGetPhysicalDeviceQueueFamilyProperties2KHR behaves similarly to flink:vkGetPhysicalDeviceQueueFamilyProperties, with the ability to return -extended information via chained output structures. +extended information in a pname:pNext chain of output structures. include::../validity/protos/vkGetPhysicalDeviceQueueFamilyProperties2KHR.txt[] diff --git a/doc/specs/vulkan/chapters/features.txt b/doc/specs/vulkan/chapters/features.txt index 4a734a74..7075fdc9 100644 --- a/doc/specs/vulkan/chapters/features.txt +++ b/doc/specs/vulkan/chapters/features.txt @@ -24,9 +24,10 @@ slink:VkPhysicalDeviceFeatures and slink:VkPhysicalDeviceLimits), as well as extensible structures (sname:VkPhysicalDeviceFeatures2KHR and sname:VkPhysicalDeviceProperties2KHR) which were added in code:VK_KHR_get_physical_device_properties2. -It is expected that when new features or limits are added in a future Vulkan -version or extensions, each extension should introduce one new feature -structure and/or limit structure (as needed) which can: be chained from the +When new features or limits are added in future Vulkan version or +extensions, each extension should: introduce one new feature structure +and/or limit structure (as needed). +These structures can: be added to the pname:pNext chain of the sname:VkPhysicalDeviceFeatures2KHR and sname:VkPhysicalDeviceProperties2KHR structures, respectively. ==== @@ -175,7 +176,6 @@ considered out of bounds even if the members at the end are not statically used. ==== -- -+ *** If any buffer access in a given SPIR-V block is determined to be out of bounds, then any other access of the same type (load, store, or atomic) in the same SPIR-V block that accesses an address less than 16 @@ -377,11 +377,10 @@ used. * ename:VK_FORMAT_EAC_R11_SNORM_BLOCK * ename:VK_FORMAT_EAC_R11G11_UNORM_BLOCK * ename:VK_FORMAT_EAC_R11G11_SNORM_BLOCK --- -+ + flink:vkGetPhysicalDeviceFormatProperties is used to check for the supported properties of individual formats. -+ +-- * [[features-features-textureCompressionASTC_LDR]] pname:textureCompressionASTC_LDR indicates whether the ASTC LDR compressed texture formats are supported. @@ -417,11 +416,10 @@ properties of individual formats. * ename:VK_FORMAT_ASTC_12x10_SRGB_BLOCK * ename:VK_FORMAT_ASTC_12x12_UNORM_BLOCK * ename:VK_FORMAT_ASTC_12x12_SRGB_BLOCK --- -+ + flink:vkGetPhysicalDeviceFormatProperties is used to check for the supported properties of individual formats. -+ +-- * [[features-features-textureCompressionBC]] pname:textureCompressionBC indicates whether the BC compressed texture formats are supported. If this feature is not enabled, the following formats must: not be used @@ -444,11 +442,10 @@ properties of individual formats. * ename:VK_FORMAT_BC6H_SFLOAT_BLOCK * ename:VK_FORMAT_BC7_UNORM_BLOCK * ename:VK_FORMAT_BC7_SRGB_BLOCK --- -+ + flink:vkGetPhysicalDeviceFormatProperties is used to check for the supported properties of individual formats. -+ +-- * [[features-features-occlusionQueryPrecise]] pname:occlusionQueryPrecise indicates whether occlusion queries returning actual sample counts are supported. @@ -1195,7 +1192,6 @@ just an example and the amount of contribution should: be covered by different equations in the spec). ==== -- -+ * [[features-limits-maxDrawIndexedIndexValue]] pname:maxDrawIndexedIndexValue is the maximum index value that can: be used for indexed draw calls when using 32-bit indices. @@ -1487,13 +1483,13 @@ endif::VK_EXT_discard_rectangles[] -- // refBegin VkSampleCountFlagBits Bitmask specifying sample counts supported for an image used for storage operations include::../api/enums/VkSampleCountFlagBits.txt[] --- -+ + The sample count limits defined above represent the minimum supported sample counts for each image type. Individual images may: support additional sample counts, which are queried using flink:vkGetPhysicalDeviceImageFormatProperties as described in <>. +-- include::../validity/structs/VkPhysicalDeviceLimits.txt[] @@ -3431,18 +3427,16 @@ flink:vkGetPhysicalDeviceFormatProperties::pname:format: ename:VK_FORMAT_FEATURE_BLIT_SRC_BIT. + If the format being queried is a depth/stencil format, this bit only - indicates that the depth aspect (not the stencil aspect) of an image of - this format supports linear filtering, and that linear filtering of the - depth aspect is supported whether depth compare is enabled in the - sampler or not. - If this bit is not present, linear filtering with depth compare disabled - is unsupported and linear filtering with depth compare enabled is - supported, but may: compute the filtered value in an - implementation-dependent manner which differs from the normal rules of - linear filtering. - The resulting value must: be in the range [eq]#[0,1]# and should: be - proportional to, or a weighted average of, the number of comparison - passes or failures. +indicates that the depth aspect (not the stencil aspect) of an image of this +format supports linear filtering, and that linear filtering of the depth +aspect is supported whether depth compare is enabled in the sampler or not. +If this bit is not present, linear filtering with depth compare disabled is +unsupported and linear filtering with depth compare enabled is supported, +but may: compute the filtered value in an implementation-dependent manner +which differs from the normal rules of linear filtering. +The resulting value must: be in the range [eq]#[0,1]# and should: be +proportional to, or a weighted average of, the number of comparison passes +or failures. ifdef::VK_KHR_maintenance1[] ename:VK_FORMAT_FEATURE_TRANSFER_SRC_BIT_KHR:: @@ -3516,7 +3510,7 @@ include::../api/protos/vkGetPhysicalDeviceFormatProperties2KHR.txt[] fname:vkGetPhysicalDeviceFormatProperties2KHR behaves similarly to flink:vkGetPhysicalDeviceFormatProperties, with the ability to return -extended information via chained output structures. +extended information in a pname:pNext chain of output structures. include::../validity/protos/vkGetPhysicalDeviceFormatProperties2KHR.txt[] @@ -4169,7 +4163,7 @@ include::../api/protos/vkGetPhysicalDeviceImageFormatProperties2KHR.txt[] fname:vkGetPhysicalDeviceImageFormatProperties2KHR behaves similarly to flink:vkGetPhysicalDeviceImageFormatProperties, with the ability to return -extended information via chained output structures. +extended information in a pname:pNext chain of output structures. If the loader implementation emulates fname:vkGetPhysicalDeviceImageFormatProperties2KHR on a device that does not @@ -4246,8 +4240,7 @@ include::../api/structs/VkPhysicalDeviceExternalImageFormatInfoKHX.txt[] -- // refBegin VkExternalMemoryHandleTypeFlagBitsKHX - Bitmask of valid external memory handle types include::../api/enums/VkExternalMemoryHandleTypeFlagBitsKHX.txt[] --- -+ + ** ename:VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD_BIT_KHX is a POSIX file descriptor handle that has only limited valid usage outside of Vulkan and other compatible APIs. @@ -4291,6 +4284,7 @@ include::../api/enums/VkExternalMemoryHandleTypeFlagBitsKHX.txt[] handle returned by sname:ID3D12Device::fname:CreateSharedHandle referring to a Direct3D 12 committed resource. It owns a reference to the memory used by the Direct3D resource. +-- If pname:handleType is 0, flink:vkGetPhysicalDeviceImageFormatProperties2KHR will behave as if slink:VkPhysicalDeviceExternalImageFormatInfoKHX was not @@ -4583,8 +4577,7 @@ include::../api/structs/VkPhysicalDeviceExternalSemaphoreInfoKHX.txt[] -- // refBegin VkExternalSemaphoreHandleTypeFlagBitsKHX - Bitmask of valid external semaphore handle types include::../api/enums/VkExternalSemaphoreHandleTypeFlagBitsKHX.txt[] --- -+ + ** ename:VK_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_FD_BIT_KHX is a POSIX file descriptor handle that has only limited valid usage outside of Vulkan and other compatible APIs. @@ -4624,6 +4617,7 @@ include::../api/enums/VkExternalSemaphoreHandleTypeFlagBitsKHX.txt[] Implementations which support importing this handle type must: accept any type of fence FD supported by the native system they are running on. +-- [NOTE] .Note diff --git a/doc/specs/vulkan/chapters/fragops.txt b/doc/specs/vulkan/chapters/fragops.txt index 6ded6013..7b59234d 100644 --- a/doc/specs/vulkan/chapters/fragops.txt +++ b/doc/specs/vulkan/chapters/fragops.txt @@ -74,8 +74,8 @@ include::../api/structs/VkPipelineDiscardRectangleStateCreateInfoEXT.txt[] include::../validity/structs/VkPipelineDiscardRectangleStateCreateInfoEXT.txt[] The sname:VkPipelineDiscardRectangleStateCreateInfoEXT state is set by -chaining an instance of this structure to the pname:pNext of an instance of -the sname:VkGraphicsPipelineCreateInfo structure and setting the graphics +adding an instance of this structure to the pname:pNext chain of an instance +of the sname:VkGraphicsPipelineCreateInfo structure and setting the graphics pipeline state with flink:vkCreateGraphicsPipelines. If the bound pipeline state object was not created with the @@ -562,7 +562,7 @@ include::../api/protos/vkCmdSetStencilCompareMask.txt[] -- // refBegin VkStencilFaceFlagBits Bitmask specifying sets of stencil state for which to update the compare mask include::../api/enums/VkStencilFaceFlagBits.txt[] --- + ** ename:VK_STENCIL_FACE_FRONT_BIT indicates that only the front set of stencil state is updated. ** ename:VK_STENCIL_FACE_BACK_BIT indicates that only the back set of @@ -570,6 +570,7 @@ include::../api/enums/VkStencilFaceFlagBits.txt[] ** ename:VK_STENCIL_FRONT_AND_BACK is the combination of ename:VK_STENCIL_FACE_FRONT_BIT and ename:VK_STENCIL_FACE_BACK_BIT and indicates that both sets of stencil state are updated. +-- * pname:compareMask is the new value to use as the stencil compare mask. .Valid Usage diff --git a/doc/specs/vulkan/chapters/fundamentals.txt b/doc/specs/vulkan/chapters/fundamentals.txt index 5fbb12ef..f7ab03b9 100644 --- a/doc/specs/vulkan/chapters/fundamentals.txt +++ b/doc/specs/vulkan/chapters/fundamentals.txt @@ -788,12 +788,14 @@ valid structure defined by an extension, containing ptext:sType and ptext:pNext members as described in the <> document in the section "`Extension Interactions`". +The set of structures connected by ptext:pNext pointers is referred to as a +_pname:pNext chain_. If that extension is supported by the implementation, then it must: be enabled. Any component of the implementation (the loader, any enabled layers, and drivers) must: skip over, without processing (other than reading the -pname:sType and pname:pNext members) any chained structures with pname:sType -values not defined by extensions supported by that component. +pname:sType and pname:pNext members) any structures in the chain with +pname:sType values not defined by extensions supported by that component. Extension structures are not described in the base Vulkan specification, but either in layered specifications incorporating those extensions, or in diff --git a/doc/specs/vulkan/chapters/fxvertex.txt b/doc/specs/vulkan/chapters/fxvertex.txt index e520c8ee..520ed99c 100644 --- a/doc/specs/vulkan/chapters/fxvertex.txt +++ b/doc/specs/vulkan/chapters/fxvertex.txt @@ -327,11 +327,12 @@ include::../api/structs/VkVertexInputBindingDescription.txt[] -- // refBegin VkVertexInputRate Specify rate at which vertex attributes are pulled from buffers include::../api/enums/VkVertexInputRate.txt[] --- + ** ename:VK_VERTEX_INPUT_RATE_VERTEX indicates that vertex attribute addressing is a function of the vertex index. ** ename:VK_VERTEX_INPUT_RATE_INSTANCE indicates that vertex attribute addressing is a function of the instance index. +-- .Valid Usage **** diff --git a/doc/specs/vulkan/chapters/initialization.txt b/doc/specs/vulkan/chapters/initialization.txt index a9d1d0ef..6732cc49 100644 --- a/doc/specs/vulkan/chapters/initialization.txt +++ b/doc/specs/vulkan/chapters/initialization.txt @@ -136,7 +136,7 @@ Behavior is undefined if an extension physical-device command is called on a physical device that does not support the extension. Device extensions may: define structures that can: be added to the -pNext-chain of physical-device commands. +ptext:pNext chain of physical-device commands. Behavior is undefined if such an extension structure is passed to a physical device command for a physical device that does not support the extension. diff --git a/doc/specs/vulkan/chapters/memory.txt b/doc/specs/vulkan/chapters/memory.txt index 4c895361..8759e0fa 100644 --- a/doc/specs/vulkan/chapters/memory.txt +++ b/doc/specs/vulkan/chapters/memory.txt @@ -584,7 +584,7 @@ include::../api/protos/vkGetPhysicalDeviceMemoryProperties2KHR.txt[] fname:vkGetPhysicalDeviceMemoryProperties2KHR behaves similarly to flink:vkGetPhysicalDeviceMemoryProperties, with the ability to return -extended information via chained output structures. +extended information in a pname:pNext chain of output structures. include::../validity/protos/vkGetPhysicalDeviceMemoryProperties2KHR.txt[] @@ -617,7 +617,7 @@ include::../api/structs/VkMemoryHeap.txt[] -- // refBegin VkMemoryHeapFlagBits Bitmask specifying attribute flags for a heap include::../api/enums/VkMemoryHeapFlagBits.txt[] --- + ** if pname:flags contains ename:VK_MEMORY_HEAP_DEVICE_LOCAL_BIT, it means the heap corresponds to device local memory. Device local memory may: have different performance characteristics @@ -630,6 +630,7 @@ ifdef::VK_KHX_device_group_creation[] By default, an allocation from such a heap will be replicated to each physical device's instance of the heap. endif::VK_KHX_device_group_creation[] +-- include::../validity/structs/VkMemoryHeap.txt[] @@ -648,7 +649,7 @@ include::../api/structs/VkMemoryType.txt[] -- // refBegin VkMemoryPropertyFlagBits Bitmask specifying properties for a memory type include::../api/enums/VkMemoryPropertyFlagBits.txt[] --- + ** if pname:propertyFlags has the ename:VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT bit set, memory allocated with this type is the most efficient for device access. @@ -676,6 +677,7 @@ include::../api/enums/VkMemoryPropertyFlagBits.txt[] Additionally, the object's backing memory may: be provided by the implementation lazily as specified in <>. +-- include::../validity/structs/VkMemoryType.txt[] @@ -759,7 +761,7 @@ include::../api/structs/VkMemoryAllocateInfo.txt[] will come from. ifdef::VK_KHX_external_memory_win32,VK_KHX_external_memory_fd[] -If the pname:pNext extension chain contains an instance of +If the pname:pNext chain contains an instance of ifdef::VK_KHX_external_memory_win32[] slink:VkImportMemoryWin32HandleInfoKHX with a non-zero value for sname:VkImportMemoryWin32HandleInfoKHX::pname:handleType, @@ -812,7 +814,7 @@ endif::VK_KHX_external_memory_win32,VK_KHX_external_memory_fd[] and the calling command's sname:VkDevice * pname:allocationSize must: be greater than `0` ifdef::VK_KHX_external_memory+VK_NV_dedicated_allocation[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of sname:VkExportMemoryAllocateInfoKHX, and any of the handle types specified in sname:VkExportMemoryAllocateInfoKHX::pname:handleTypes require a dedicated allocation, as reported by @@ -820,19 +822,19 @@ ifdef::VK_KHX_external_memory+VK_NV_dedicated_allocation[] sname:VkExternalImageFormatPropertiesKHX::pname:externalMemoryProperties::pname:externalMemoryFeatures or sname:VkExternalBufferPropertiesKHX::pname:externalMemoryProperties::pname:externalMemoryFeatures, - the pname:pNext extension chain must: contain an instance of + the pname:pNext chain must: contain an instance of sname:VkDedicatedAllocationMemoryAllocateInfoNV with either its pname:image or pname:buffer field set to a value other than ename:VK_NULL_HANDLE. endif::VK_KHX_external_memory+VK_NV_dedicated_allocation[] ifdef::VK_KHX_external_memory+VK_NV_external_memory[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of slink:VkExportMemoryAllocateInfoKHX, it must: not contain an instance of slink:VkExportMemoryAllocateInfoNV or slink:VkExportMemoryWin32HandleInfoNV. endif::VK_KHX_external_memory+VK_NV_external_memory[] ifdef::VK_KHX_external_memory_win32+VK_NV_external_memory_win32[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of slink:VkImportMemoryWin32HandleInfoKHX, it must: not contain an instance of slink:VkImportMemoryWin32HandleInfoNV. endif::VK_KHX_external_memory_win32+VK_NV_external_memory_win32[] @@ -842,6 +844,19 @@ ifdef::VK_KHX_external_memory_win32,VK_KHX_external_memory_fd[] pname:allocationSize and pname:memoryTypeIndex must: match those specified when the memory object being imported was created. endif::VK_KHX_external_memory_win32,VK_KHX_external_memory_fd[] +**** + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +Split Valid Usage block into two parts to work around asciidoctor-pdf +problem (internal issue 683). +==== +endif::editing-notes[] + +.Valid Usage +**** ifdef::VK_KHX_external_memory+VK_KHX_device_group[] * If the parameters define an import operation and the external handle specified was created by the Vulkan API, the device mask specified by @@ -865,7 +880,7 @@ ifdef::VK_KHX_external_memory_win32[] pname:allocationSize must: match the size reported in the memory requirements of the pname:image or pname:buffer member of the instance of sname:VkDedicatedAllocationMemoryAllocateInfoNV included in the - pname:pNext extension chain. + pname:pNext chain. * If the parameters define an import operation and the external handle type is ename:VK_EXTERNAL_MEMORY_HANDLE_TYPE_D3D12_HEAP_BIT_KHX, pname:allocationSize must: match the size specified when creating the @@ -1290,10 +1305,10 @@ include::../api/structs/VkMemoryAllocateFlagsInfoKHX.txt[] -- // refBegin VkMemoryAllocateFlagBitsKHX Bitmask specifying flags for a device memory allocation include::../api/enums/VkMemoryAllocateFlagBitsKHX.txt[] --- + ** if pname:flags contains ename:VK_MEMORY_ALLOCATE_DEVICE_MASK_BIT_KHX, memory will be allocated for the devices in pname:deviceMask. -+ +-- * pname:deviceMask is a mask of physical devices in the logical device, indicating that memory must: be allocated on each device in the mask, if ename:VK_MEMORY_ALLOCATE_DEVICE_MASK_BIT_KHX is set. @@ -1675,7 +1690,7 @@ include::../api/protos/vkGetDeviceGroupPeerMemoryFeaturesKHX.txt[] -- // refBegin VkPeerMemoryFeatureFlagBitsKHX Bitmask specifying supported peer memory features include::../api/enums/VkPeerMemoryFeatureFlagBitsKHX.txt[] --- + ** if pname:pPeerMemoryFeatures contains ename:VK_PEER_MEMORY_FEATURE_COPY_SRC_BIT_KHX, the memory can: be accessed as the source of a ftext:vkCmdCopy* command. @@ -1689,6 +1704,7 @@ include::../api/enums/VkPeerMemoryFeatureFlagBitsKHX.txt[] ename:VK_PEER_MEMORY_FEATURE_GENERIC_DST_BIT_KHX, the memory can: be written as any other memory access type. Shader atomics are considered to be writes. +-- ename:VK_PEER_MEMORY_FEATURE_COPY_DST_BIT_KHX must: be supported for all heaps. diff --git a/doc/specs/vulkan/chapters/pipelines.txt b/doc/specs/vulkan/chapters/pipelines.txt index ee540b35..6038e99c 100644 --- a/doc/specs/vulkan/chapters/pipelines.txt +++ b/doc/specs/vulkan/chapters/pipelines.txt @@ -1314,14 +1314,13 @@ include::../api/protos/vkCmdBindPipeline.txt[] -- // refBegin VkPipelineBindPoint Specify the bind point of a pipeline object to a command buffer include::../api/enums/VkPipelineBindPoint.txt[] --- -+ + specifying whether pname:pipeline will be bound as a compute (ename:VK_PIPELINE_BIND_POINT_COMPUTE) or graphics (ename:VK_PIPELINE_BIND_POINT_GRAPHICS) pipeline. There are separate bind points for each of graphics and compute, so binding one does not disturb the other. -+ +-- * pname:pipeline is the pipeline to be bound. Once bound, a pipeline binding affects subsequent graphics or compute diff --git a/doc/specs/vulkan/chapters/primsrast.txt b/doc/specs/vulkan/chapters/primsrast.txt index f0dfca6e..b7987aa2 100644 --- a/doc/specs/vulkan/chapters/primsrast.txt +++ b/doc/specs/vulkan/chapters/primsrast.txt @@ -70,10 +70,10 @@ include::../api/structs/VkPipelineRasterizationStateCreateInfo.txt[] * pname:lineWidth is the width of rasterized line segments. ifdef::VK_AMD_rasterization_order[] -The application can: also chain a +The application can: also add a sname:VkPipelineRasterizationStateRasterizationOrderAMD structure to the -sname:VkPipelineRasterizationStateCreateInfo structure through its -pname:pNext member. +pname:pNext chain of a sname:VkPipelineRasterizationStateCreateInfo +structure. This structure enables selecting the rasterization order to use when rendering with the corresponding graphics pipeline as described in <>. @@ -199,9 +199,9 @@ include::../api/enums/VkRasterizationOrderAMD.txt[] <>. The rasterization order to use for a graphics pipeline is specified by -chaining a sname:VkPipelineRasterizationStateRasterizationOrderAMD structure -through the pname:pNext member to -slink:VkPipelineRasterizationStateCreateInfo. +adding a sname:VkPipelineRasterizationStateRasterizationOrderAMD structure +to the pname:pNext chain of a slink:VkPipelineRasterizationStateCreateInfo +structure. The sname:VkPipelineRasterizationStateRasterizationOrderAMD structure is defined as: diff --git a/doc/specs/vulkan/chapters/queries.txt b/doc/specs/vulkan/chapters/queries.txt index ef44dc55..0a874851 100644 --- a/doc/specs/vulkan/chapters/queries.txt +++ b/doc/specs/vulkan/chapters/queries.txt @@ -65,6 +65,14 @@ include::../api/structs/VkQueryPoolCreateInfo.txt[] -- // refBegin VkQueryType Specify the type of queries managed by a query pool include::../api/enums/VkQueryType.txt[] + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of the enums here. +==== +endif::editing-notes[] -- * pname:queryCount is the number of queries managed by the pool. * pname:pipelineStatistics is a bitmask indicating which counters will be @@ -398,8 +406,7 @@ include::../api/protos/vkGetQueryPoolResults.txt[] -- // refBegin VkQueryResultFlagBits Bitmask specifying how and when query results are returned include::../api/enums/VkQueryResultFlagBits.txt[] --- -+ + ** ename:VK_QUERY_RESULT_64_BIT indicates the results will be written as an array of 64-bit unsigned integer values. If this bit is not set, the results will be written as an array of @@ -410,6 +417,7 @@ include::../api/enums/VkQueryResultFlagBits.txt[] availability status accompanies the results. ** ename:VK_QUERY_RESULT_PARTIAL_BIT indicates that returning partial results is acceptable. +-- If no bits are set in pname:flags, and all requested queries are in the available state, results are written as an array of 32-bit unsigned integer diff --git a/doc/specs/vulkan/chapters/renderpass.txt b/doc/specs/vulkan/chapters/renderpass.txt index 3da01778..2f47a74c 100644 --- a/doc/specs/vulkan/chapters/renderpass.txt +++ b/doc/specs/vulkan/chapters/renderpass.txt @@ -356,6 +356,14 @@ include::../api/structs/VkAttachmentDescription.txt[] -- // refBegin VkAttachmentDescriptionFlagBits Bitmask specifying additional properties of an attachment include::../api/enums/VkAttachmentDescriptionFlagBits.txt[] + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of the enums here. +==== +endif::editing-notes[] -- * pname:format is a elink:VkFormat value specifying the format of the image that will be used for the attachment. @@ -368,7 +376,7 @@ include::../api/enums/VkAttachmentDescriptionFlagBits.txt[] -- // refBegin VkAttachmentLoadOp Specify how contents of an attachment are treated at the beginning of a subpass include::../api/enums/VkAttachmentLoadOp.txt[] --- + ** ename:VK_ATTACHMENT_LOAD_OP_LOAD means the previous contents of the image within the render area will be preserved. For attachments with a depth/stencil format, this uses the access type @@ -389,6 +397,7 @@ include::../api/enums/VkAttachmentLoadOp.txt[] ename:VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT. For attachments with a color format, this uses the access type ename:VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT. +-- * pname:storeOp specifies how the contents of color and depth components of the attachment are treated at the end of the subpass where it is last used: @@ -396,7 +405,7 @@ include::../api/enums/VkAttachmentLoadOp.txt[] -- // refBegin VkAttachmentStoreOp Specify how contents of an attachment are treated at the end of a subpass include::../api/enums/VkAttachmentStoreOp.txt[] --- + ** ename:VK_ATTACHMENT_STORE_OP_STORE means the contents generated during the render pass and within the render area are written to memory. For attachments with a depth/stencil format, this uses the access type @@ -410,6 +419,7 @@ include::../api/enums/VkAttachmentStoreOp.txt[] ename:VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT. For attachments with a color format, this uses the access type ename:VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT. +-- * pname:stencilLoadOp specifies how the contents of stencil components of the attachment are treated at the beginning of the subpass where it is first used, and must: be one of the same values allowed for pname:loadOp @@ -578,9 +588,16 @@ include::../api/structs/VkSubpassDescription.txt[] -- // refBegin VkSubpassDescriptionFlagBits Bitmask specifying usage of a subpass include::../api/enums/VkSubpassDescriptionFlagBits.txt[] --- + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) This section looks odd unless `VK_NVX_multiview_per_view_attributes` +is enabled, since no bits are defined for the type. +==== +endif::editing-notes[] ifdef::VK_NVX_multiview_per_view_attributes[] -+ ** ename:VK_SUBPASS_DESCRIPTION_PER_VIEW_ATTRIBUTES_BIT_NVX indicates that shaders compiled for this subpass write the attributes for all views in a single invocation of each vertex processing stage. @@ -592,6 +609,7 @@ ifdef::VK_NVX_multiview_per_view_attributes[] only differ in value in the x component. Per-view viewport mask can: also be used. endif::VK_NVX_multiview_per_view_attributes[] +-- * pname:pipelineBindPoint is a elink:VkPipelineBindPoint value specifying whether this is a compute or graphics subpass. Currently, only graphics subpasses are supported. @@ -1285,8 +1303,7 @@ include::../api/protos/vkCmdBeginRenderPass.txt[] -- // refBegin VkSubpassContents Specify how commands in the first subpass of a render pass are provided include::../api/enums/VkSubpassContents.txt[] --- -+ + If pname:contents is ename:VK_SUBPASS_CONTENTS_INLINE, the contents of the subpass will be recorded inline in the primary command buffer, and secondary command buffers must: not be executed within the subpass. @@ -1295,6 +1312,7 @@ the contents are recorded in secondary command buffers that will be called from the primary command buffer, and fname:vkCmdExecuteCommands is the only valid command on the command buffer until fname:vkCmdNextSubpass or fname:vkCmdEndRenderPass. +-- After beginning a render pass instance, the command buffer is ready to record the commands for the first subpass of that render pass. diff --git a/doc/specs/vulkan/chapters/resources.txt b/doc/specs/vulkan/chapters/resources.txt index b981f2b6..beea86dd 100644 --- a/doc/specs/vulkan/chapters/resources.txt +++ b/doc/specs/vulkan/chapters/resources.txt @@ -176,12 +176,12 @@ ifdef::VK_KHX_external_memory+VK_NV_dedicated_allocation[] dedicated allocation, as reported by flink:vkGetPhysicalDeviceExternalBufferPropertiesKHX in sname:VkExternalBufferPropertiesKHX::pname:externalMemoryProperties::pname:externalMemoryFeatures, - the pname:pNext extension chain must: contain an instance of + the pname:pNext chain must: contain an instance of sname:VkDedicatedAllocationBufferCreateInfoNV with its pname:dedicatedAllocation field set to ename:VK_TRUE. endif::VK_KHX_external_memory+VK_NV_dedicated_allocation[] ifdef::VK_KHX_external_memory[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext extension contains an instance of slink:VkExternalMemoryBufferCreateInfoKHX, its pname:handleTypes member must: only contain bits that are also in slink:VkExternalBufferPropertiesKHX::pname:externalMemoryProperties.pname:compatibleHandleTypes, @@ -765,23 +765,23 @@ endif::VK_KHR_maintenance1[] ename:VK_IMAGE_CREATE_SPARSE_ALIASED_BIT, it must: also contain ename:VK_IMAGE_CREATE_SPARSE_BINDING_BIT ifdef::VK_NV_external_memory+VK_KHX_external_memory[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of slink:VkExternalMemoryImageCreateInfoNV, it must: not contain an instance of slink:VkExternalMemoryImageCreateInfoKHX. endif::VK_NV_external_memory+VK_KHX_external_memory[] ifdef::VK_KHX_external_memory+VK_NV_dedicated_allocation[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of sname:VkExternalMemoryImageCreateInfoKHX, and any of the handle types specified in sname:VkExternalMemoryImageCreateInfoKHX::pname:handleTypes require a dedicated allocation, as reported by flink:vkGetPhysicalDeviceImageFormatProperties2KHR in sname:VkExternalImageFormatPropertiesKHX::pname:externalMemoryProperties::pname:externalMemoryFeatures, - the pname:pNext extension chain must: contain an instance of + the pname:pNext chain must: contain an instance of sname:VkDedicatedAllocationImageCreateInfoNV with its pname:dedicatedAllocation field set to ename:VK_TRUE. endif::VK_KHX_external_memory+VK_NV_dedicated_allocation[] ifdef::VK_KHX_external_memory[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of slink:VkExternalMemoryImageCreateInfoKHX, its pname:handleTypes member must: only contain bits that are also in slink:VkExternalImageFormatPropertiesKHX::pname:externalMemoryProperties::pname:compatibleHandleTypes, @@ -789,12 +789,11 @@ ifdef::VK_KHX_external_memory[] pname:format, pname:type, pname:tiling, pname:usage, and pname:flags equal to those in this structure, and with an instance of slink:VkPhysicalDeviceExternalImageFormatInfoKHX in the pname:pNext - structure chain, with a pname:handleType equal to any one of the handle - types specified in - slink:VkExternalMemoryImageCreateInfoKHX::pname:handleTypes + chain, with a pname:handleType equal to any one of the handle types + specified in slink:VkExternalMemoryImageCreateInfoKHX::pname:handleTypes endif::VK_KHX_external_memory[] ifdef::VK_NV_external_memory+VK_NV_external_memory_capabilities[] - * If the pname:pNext extension chain contains an instance of + * If the pname:pNext chain contains an instance of slink:VkExternalMemoryImageCreateInfoNV, its pname:handleTypes member must: only contain bits that are also in slink:VkExternalImageFormatPropertiesNV::pname:externalMemoryProperties::pname:compatibleHandleTypes, @@ -2439,14 +2438,10 @@ endif::VK_KHX_device_group[] [[resources-bufferimagegranularity,Buffer-Image Granularity]] .Buffer-Image Granularity There is an implementation-dependent limit, pname:bufferImageGranularity, -which specifies a page-like granularity at which buffer, linear image and -optimal image resources must: be placed in adjacent memory locations to -avoid aliasing. +which specifies a page-like granularity at which linear and non-linear +resources must: be placed in adjacent memory locations to avoid aliasing. Two resources which do not satisfy this granularity requirement are said to <>. -Linear image resource are images created with ename:VK_IMAGE_TILING_LINEAR -and optimal image resources are those created with -ename:VK_IMAGE_TILING_OPTIMAL. pname:bufferImageGranularity is specified in bytes, and must: be a power of two. Implementations which do not require such an additional granularity may: @@ -2455,16 +2450,14 @@ report a value of one. [NOTE] .Note ==== -pname:bufferImageGranularity is really a granularity between "linear" -resources, including buffers and images with linear tiling, vs. -"optimal" resources, i.e. images with optimal tiling. -It would have been better named "linearOptimalGranularity". +Despite its name, pname:bufferImageGranularity is really a granularity +between "linear" and "non-linear" resources. ==== Given resourceA at the lower memory offset and resourceB at the higher -memory offset in the same sname:VkDeviceMemory object, where one of the -resources is a buffer or a linear image and the other is an optimal image, -and the following: +memory offset in the same sname:VkDeviceMemory object, where one resource +linear and the other is non-linear (as defined in the +<>), and the following: [source,c] --------------------------------------------------- @@ -2486,10 +2479,9 @@ resource (B) must: be on separate "`pages`" of size pname:bufferImageGranularity. pname:bufferImageGranularity may: be different than the physical page size of the memory heap. -This restriction is only needed when a buffer or a linear image is at -adjacent memory location with an optimal image and both will be used -simultaneously. -Adjacent buffers' or adjacent images' memory ranges can: be closer than +This restriction is only needed when a linear resource and a non-linear +resource are adjacent in memory and will be used simultaneously. +The memory ranges of adjacent resources can: be closer than pname:bufferImageGranularity, provided they meet the pname:alignment requirement for the objects in question. @@ -2607,8 +2599,8 @@ endif::VK_KHX_external_memory[] == Memory Aliasing A range of a sname:VkDeviceMemory allocation is _aliased_ if it is bound to -multiple resources simultaneously, via flink:vkBindImageMemory, -flink:vkBindBufferMemory, +multiple resources simultaneously, as described below, via +flink:vkBindImageMemory, flink:vkBindBufferMemory, ifndef::VK_KHX_external_memory[] or via <>. endif::VK_KHX_external_memory[] @@ -2617,24 +2609,20 @@ via <>, or by binding the memory to resources in multiple Vulkan instances or external APIs using external memory handle export and import mechanisms. endif::VK_KHX_external_memory[] -A memory range aliased between two images or two buffers is defined to be -the intersection of the memory ranges bound to the two resources. -A memory range aliased between two resources where one is a buffer or a -linear image, and the other is an optimal image, is defined to be the -intersection of the memory ranges bound to the two resources, where each -range is first padded to be aligned to the pname:bufferImageGranularity. + +Consider two resources, resource~A~ and resource~B~, bound respectively to +memory range~A~ and range~B~. +Let paddedRange~A~ and paddedRange~B~ be, respectively, range~A~ and +range~B~ aligned to pname:bufferImageGranularity. +If the resources are both linear or both non-linear (as defined in the +<>), then the resources _alias_ the +memory in the intersection of range~A~ and range~B~. +If one resource is linear and the other is non-linear, then the resources +_alias_ the memory in the intersection of paddedRange~A~ and paddedRange~B~. + Applications can: alias memory, but use of multiple aliases is subject to several constraints. -ifdef::editing-notes[] -[NOTE] -.editing-note -================== -(Jon) Can simplify the conditional structure by rearranging the conditional -clause to precede end of sentence. -================== -endif::editing-notes[] - [NOTE] .Note ==== @@ -2662,7 +2650,7 @@ That is, the host has a well-defined addressing scheme to interpret the contents, and thus the layout of the data in memory can: be consistently interpreted across aliases if each of those aliases is a host-accessible subresource. -Opaque images and linear image subresources in other layouts are not +Non-linear images, and linear image subresources in other layouts, are not host-accessible. If two aliases are both host-accessible, then they interpret the contents of diff --git a/doc/specs/vulkan/chapters/samplers.txt b/doc/specs/vulkan/chapters/samplers.txt index 24467865..e4ac0f93 100644 --- a/doc/specs/vulkan/chapters/samplers.txt +++ b/doc/specs/vulkan/chapters/samplers.txt @@ -48,8 +48,15 @@ include::../api/structs/VkSamplerCreateInfo.txt[] -- // refBegin VkFilter Specify filters used for texture lookups include::../api/enums/VkFilter.txt[] + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of the enums here. +==== +endif::editing-notes[] -- -+ * pname:minFilter is the minification filter to apply to lookups, and is of type elink:VkFilter. * pname:mipmapMode is the mipmap filter to apply to lookups as described @@ -59,8 +66,15 @@ include::../api/enums/VkFilter.txt[] -- // refBegin VkSamplerMipmapMode Specify mipmap mode used for texture lookups include::../api/enums/VkSamplerMipmapMode.txt[] + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of the enums here. +==== +endif::editing-notes[] -- -+ * pname:addressModeU is the addressing mode for outside [0..1] range for U coordinate. See elink:VkSamplerAddressMode. @@ -99,8 +113,15 @@ include::../api/enums/VkSamplerMipmapMode.txt[] -- // refBegin VkBorderColor Specify border color used for texture lookups include::../api/enums/VkBorderColor.txt[] + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of the enums here. +==== +endif::editing-notes[] -- -+ * [[samplers-unnormalizedCoordinates]] pname:unnormalizedCoordinates controls whether to use unnormalized or normalized texel coordinates to address texels of the image. diff --git a/doc/specs/vulkan/chapters/sparsemem.txt b/doc/specs/vulkan/chapters/sparsemem.txt index 5501e196..ccd61b84 100644 --- a/doc/specs/vulkan/chapters/sparsemem.txt +++ b/doc/specs/vulkan/chapters/sparsemem.txt @@ -74,6 +74,15 @@ slink:VkPhysicalDeviceFeatures. advertised on a finer grain via the following features: + -- +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Something wrong with markup here - "`Sparse residency support`" +doesn't show up in the bullet point. +==== +endif::editing-notes[] + *** <>: Support for creating sname:VkBuffer objects with the ename:VK_BUFFER_CREATE_SPARSE_RESIDENCY_BIT. @@ -538,7 +547,7 @@ Hardware that supports access to unbound pages without causing a fault may: support pname:residencyNonResidentStrict. Not faulting on access to unbound pages is not enough to support -pname:sparseResidencyNonResidentStrict. +pname:residencyNonResidentStrict. An implementation must: also guarantee that reads after writes to unbound regions of the resource always return data for the read as if the memory contains zeros. @@ -547,7 +556,7 @@ be possible. Hardware that does not fault, but does not guarantee correct read values will not require dummy pages, but also must: not support -pname:sparseResidencyNonResidentStrict. +pname:residencyNonResidentStrict. Hardware that cannot: access unbound pages without causing a fault will require the implementation to bind the entire device virtual address range @@ -789,7 +798,7 @@ include::../api/structs/VkSparseImageFormatProperties.txt[] -- // refBegin VkSparseImageFormatFlagBits Bitmask specifying additional information about a sparse image resource include::../api/enums/VkSparseImageFormatFlagBits.txt[] --- + ** If ename:VK_SPARSE_IMAGE_FORMAT_SINGLE_MIPTAIL_BIT is set, the image uses a single mip tail region for all array layers. ** If ename:VK_SPARSE_IMAGE_FORMAT_ALIGNED_MIP_SIZE_BIT is set, the first @@ -800,6 +809,7 @@ include::../api/enums/VkSparseImageFormatFlagBits.txt[] image uses non-standard sparse image block dimensions, and the pname:imageGranularity values do not match the standard sparse image block dimensions for the given pixel format. +-- include::../validity/structs/VkSparseImageFormatProperties.txt[] @@ -889,7 +899,8 @@ include::../api/protos/vkGetPhysicalDeviceSparseImageFormatProperties2KHR.txt[] fname:vkGetPhysicalDeviceSparseImageFormatProperties2KHR behaves identically to flink:vkGetPhysicalDeviceSparseImageFormatProperties, with the ability to -return extended information via chained output structures. +return extended information by adding extension structures to its +pname:pNext chain. include::../validity/protos/vkGetPhysicalDeviceSparseImageFormatProperties2KHR.txt[] @@ -1206,10 +1217,10 @@ include::../api/structs/VkSparseMemoryBind.txt[] -- // refBegin VkSparseMemoryBindFlagBits Bitmask specifying usage of a sparse memory binding operation include::../api/enums/VkSparseMemoryBindFlagBits.txt[] --- -+ + ** ename:VK_SPARSE_MEMORY_BIND_METADATA_BIT indicates that the memory being bound is only for the metadata aspect. +-- The _binding range_ [eq]#[pname:resourceOffset, pname:resourceOffset {plus} pname:size)# has different constraints based on pname:flags. diff --git a/doc/specs/vulkan/chapters/synchronization.txt b/doc/specs/vulkan/chapters/synchronization.txt index 54533a45..0439180b 100644 --- a/doc/specs/vulkan/chapters/synchronization.txt +++ b/doc/specs/vulkan/chapters/synchronization.txt @@ -924,11 +924,11 @@ include::../api/structs/VkFenceCreateInfo.txt[] -- // refBegin VkFenceCreateFlagBits Bitmask specifying initial state and behavior of a fence include::../api/enums/VkFenceCreateFlagBits.txt[] --- -+ + If pname:flags contains ename:VK_FENCE_CREATE_SIGNALED_BIT then the fence object is created in the signaled state; otherwise it is created in the unsignaled state. +-- include::../validity/structs/VkFenceCreateInfo.txt[] @@ -2143,10 +2143,18 @@ include::../api/protos/vkCmdPipelineBarrier.txt[] -- // refBegin VkDependencyFlagBits Bitmask specifying how execution and memory dependencies are formed include::../api/enums/VkDependencyFlagBits.txt[] --- + +ifdef::editing-notes[] +[NOTE] +.editing-note +==== +(Jon) Missing a description of some of the enums here. +==== +endif::editing-notes[] + ** ename:VK_DEPENDENCY_BY_REGION_BIT signifies that dependencies will be <>. - +-- * pname:memoryBarrierCount is the length of the pname:pMemoryBarriers array. * pname:pMemoryBarriers is a pointer to an array of slink:VkMemoryBarrier diff --git a/doc/specs/vulkan/chapters/textures.txt b/doc/specs/vulkan/chapters/textures.txt index 6ab79ea7..d9481f57 100644 --- a/doc/specs/vulkan/chapters/textures.txt +++ b/doc/specs/vulkan/chapters/textures.txt @@ -616,13 +616,14 @@ defined if pname:robustBufferAccess is enabled. ================== endif::editing-notes[] -If the sname:VkPhysicalDeviceSparseProperties property -pname:residencyNonResidentStrict is true, a sparse unbound texel is replaced -with 0 or 0.0 values for integer and floating-point components of the image -format, respectively. +If the +slink:VkPhysicalDeviceSparseProperties::pname:residencyNonResidentStrict +property is ename:VK_TRUE, a sparse unbound texel is replaced with 0 or 0.0 +values for integer and floating-point components of the image format, +respectively. -If pname:residencyNonResidentStrict is false, the read must: be safe, but -the value of the sparse unbound texel is undefined. +If pname:residencyNonResidentStrict is ename:VK_FALSE, the read must: be +safe, but the value of the sparse unbound texel is undefined. [[textures-depth-compare-operation]] @@ -795,9 +796,9 @@ no effect. If the texel attempts to write to an unbound region of a sparse image, the texel is a sparse unbound texel. -In such a case, if the sname:VkPhysicalDeviceSparseProperties property -pname:residencyNonResidentStrict is ename:VK_TRUE, the sparse unbound texel -write has no effect. +In such a case, if the +slink:VkPhysicalDeviceSparseProperties::pname:residencyNonResidentStrict +property is ename:VK_TRUE, the sparse unbound texel write has no effect. If pname:residencyNonResidentStrict is ename:VK_FALSE, the effect of the write is undefined but must: be safe. In addition, the write may: have a side effect that is visible to other diff --git a/doc/specs/vulkan/chapters/vertexpostproc.txt b/doc/specs/vulkan/chapters/vertexpostproc.txt index c15a343a..d86c424e 100644 --- a/doc/specs/vulkan/chapters/vertexpostproc.txt +++ b/doc/specs/vulkan/chapters/vertexpostproc.txt @@ -65,10 +65,10 @@ include::../api/structs/VkPipelineViewportSwizzleStateCreateInfoNV.txt[] include::../validity/structs/VkPipelineViewportSwizzleStateCreateInfoNV.txt[] -The sname:VkPipelineViewportSwizzleStateCreateInfoNV state is set by -chaining an instance of this structure to the pname:pNext of an instance of -the sname:VkPipelineViewportStateCreateInfo structure and setting the -graphics pipeline state with flink:vkCreateGraphicsPipelines. +The sname:VkPipelineViewportSwizzleStateCreateInfoNV state is set by adding +an instance of this structure to the pname:pNext chain of an instance of the +sname:VkPipelineViewportStateCreateInfo structure and setting the graphics +pipeline state with flink:vkCreateGraphicsPipelines. Each viewport specified from 0 to pname:viewportCount - 1 has its x,y,z,w swizzle state set to the corresponding pname:x, pname:y, pname:z and pname:w @@ -378,18 +378,18 @@ then the vertex's normalized device coordinates are [latexmath] ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ \left( - \begin{array}{c} - x_d \\ - y_d \\ - z_d - \end{array} + \begin{array}{c} + x_d \\ + y_d \\ + z_d + \end{array} \right) = \left( - \begin{array}{c} - \frac{x_c}{w_c} \\ - \frac{y_c}{w_c} \\ - \frac{z_c}{w_c} - \end{array} + \begin{array}{c} + \frac{x_c}{w_c} \\ + \frac{y_c}{w_c} \\ + \frac{z_c}{w_c} + \end{array} \right) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ diff --git a/doc/specs/vulkan/config/extDependency.py b/doc/specs/vulkan/config/extDependency.py index 08bbec5d..f65aa839 100644 --- a/doc/specs/vulkan/config/extDependency.py +++ b/doc/specs/vulkan/config/extDependency.py @@ -9,6 +9,7 @@ extensions['VK_EXT_direct_mode_display'] = [ 'VK_KHR_display', 'VK_KHR_surface' extensions['VK_EXT_discard_rectangles'] = [ 'VK_KHR_get_physical_device_properties2' ] extensions['VK_EXT_display_control'] = [ 'VK_EXT_display_surface_counter', 'VK_KHR_display', 'VK_KHR_surface', 'VK_KHR_swapchain' ] extensions['VK_EXT_display_surface_counter'] = [ 'VK_KHR_display', 'VK_KHR_surface' ] +extensions['VK_EXT_swapchain_colorspace'] = [ 'VK_KHR_surface' ] extensions['VK_GOOGLE_display_timing'] = [ 'VK_KHR_surface', 'VK_KHR_swapchain' ] extensions['VK_KHR_android_surface'] = [ 'VK_KHR_surface' ] extensions['VK_KHR_display'] = [ 'VK_KHR_surface' ] @@ -39,6 +40,6 @@ extensions['VK_NV_external_memory_win32'] = [ 'VK_NV_external_memory', 'VK_NV_ex extensions['VK_NV_win32_keyed_mutex'] = [ 'VK_NV_external_memory', 'VK_NV_external_memory_capabilities', 'VK_NV_external_memory_win32' ] # Define lists of all / KHR / KHX extensions -allExts = [ 'VK_AMD_draw_indirect_count', 'VK_AMD_gcn_shader', 'VK_AMD_gpu_shader_half_float', 'VK_AMD_negative_viewport_height', 'VK_AMD_rasterization_order', 'VK_AMD_shader_ballot', 'VK_AMD_shader_explicit_vertex_parameter', 'VK_AMD_shader_trinary_minmax', 'VK_EXT_acquire_xlib_display', 'VK_EXT_debug_marker', 'VK_EXT_debug_report', 'VK_EXT_direct_mode_display', 'VK_EXT_discard_rectangles', 'VK_EXT_display_control', 'VK_EXT_display_surface_counter', 'VK_EXT_hdr_metadata', 'VK_EXT_shader_subgroup_ballot', 'VK_EXT_shader_subgroup_vote', 'VK_EXT_validation_flags', 'VK_GOOGLE_display_timing', 'VK_IMG_filter_cubic', 'VK_IMG_format_pvrtc', 'VK_KHR_android_surface', 'VK_KHR_descriptor_update_template', 'VK_KHR_display', 'VK_KHR_display_swapchain', 'VK_KHR_get_physical_device_properties2', 'VK_KHR_maintenance1', 'VK_KHR_mir_surface', 'VK_KHR_push_descriptor', 'VK_KHR_sampler_mirror_clamp_to_edge', 'VK_KHR_shader_draw_parameters', 'VK_KHR_surface', 'VK_KHR_swapchain', 'VK_KHR_wayland_surface', 'VK_KHR_win32_surface', 'VK_KHR_xcb_surface', 'VK_KHR_xlib_surface', 'VK_KHX_device_group', 'VK_KHX_device_group_creation', 'VK_KHX_external_memory', 'VK_KHX_external_memory_capabilities', 'VK_KHX_external_memory_fd', 'VK_KHX_external_memory_win32', 'VK_KHX_external_semaphore', 'VK_KHX_external_semaphore_capabilities', 'VK_KHX_external_semaphore_fd', 'VK_KHX_external_semaphore_win32', 'VK_KHX_multiview', 'VK_KHX_win32_keyed_mutex', 'VK_MVK_ios_surface', 'VK_MVK_macos_surface', 'VK_NN_vi_surface', 'VK_NVX_device_generated_commands', 'VK_NVX_multiview_per_view_attributes', 'VK_NV_clip_space_w_scaling', 'VK_NV_dedicated_allocation', 'VK_NV_external_memory', 'VK_NV_external_memory_capabilities', 'VK_NV_external_memory_win32', 'VK_NV_geometry_shader_passthrough', 'VK_NV_glsl_shader', 'VK_NV_sample_mask_override_coverage', 'VK_NV_viewport_array2', 'VK_NV_viewport_swizzle', 'VK_NV_win32_keyed_mutex' ] +allExts = [ 'VK_AMD_draw_indirect_count', 'VK_AMD_gcn_shader', 'VK_AMD_gpu_shader_half_float', 'VK_AMD_negative_viewport_height', 'VK_AMD_rasterization_order', 'VK_AMD_shader_ballot', 'VK_AMD_shader_explicit_vertex_parameter', 'VK_AMD_shader_trinary_minmax', 'VK_EXT_acquire_xlib_display', 'VK_EXT_debug_marker', 'VK_EXT_debug_report', 'VK_EXT_direct_mode_display', 'VK_EXT_discard_rectangles', 'VK_EXT_display_control', 'VK_EXT_display_surface_counter', 'VK_EXT_hdr_metadata', 'VK_EXT_shader_subgroup_ballot', 'VK_EXT_shader_subgroup_vote', 'VK_EXT_swapchain_colorspace', 'VK_EXT_validation_flags', 'VK_GOOGLE_display_timing', 'VK_IMG_filter_cubic', 'VK_IMG_format_pvrtc', 'VK_KHR_android_surface', 'VK_KHR_descriptor_update_template', 'VK_KHR_display', 'VK_KHR_display_swapchain', 'VK_KHR_get_physical_device_properties2', 'VK_KHR_maintenance1', 'VK_KHR_mir_surface', 'VK_KHR_push_descriptor', 'VK_KHR_sampler_mirror_clamp_to_edge', 'VK_KHR_shader_draw_parameters', 'VK_KHR_surface', 'VK_KHR_swapchain', 'VK_KHR_wayland_surface', 'VK_KHR_win32_surface', 'VK_KHR_xcb_surface', 'VK_KHR_xlib_surface', 'VK_KHX_device_group', 'VK_KHX_device_group_creation', 'VK_KHX_external_memory', 'VK_KHX_external_memory_capabilities', 'VK_KHX_external_memory_fd', 'VK_KHX_external_memory_win32', 'VK_KHX_external_semaphore', 'VK_KHX_external_semaphore_capabilities', 'VK_KHX_external_semaphore_fd', 'VK_KHX_external_semaphore_win32', 'VK_KHX_multiview', 'VK_KHX_win32_keyed_mutex', 'VK_MVK_ios_surface', 'VK_MVK_macos_surface', 'VK_NN_vi_surface', 'VK_NVX_device_generated_commands', 'VK_NVX_multiview_per_view_attributes', 'VK_NV_clip_space_w_scaling', 'VK_NV_dedicated_allocation', 'VK_NV_external_memory', 'VK_NV_external_memory_capabilities', 'VK_NV_external_memory_win32', 'VK_NV_geometry_shader_passthrough', 'VK_NV_glsl_shader', 'VK_NV_sample_mask_override_coverage', 'VK_NV_viewport_array2', 'VK_NV_viewport_swizzle', 'VK_NV_win32_keyed_mutex' ] khrExts = [ 'VK_KHR_android_surface', 'VK_KHR_descriptor_update_template', 'VK_KHR_display', 'VK_KHR_display_swapchain', 'VK_KHR_get_physical_device_properties2', 'VK_KHR_maintenance1', 'VK_KHR_mir_surface', 'VK_KHR_push_descriptor', 'VK_KHR_sampler_mirror_clamp_to_edge', 'VK_KHR_shader_draw_parameters', 'VK_KHR_surface', 'VK_KHR_swapchain', 'VK_KHR_wayland_surface', 'VK_KHR_win32_surface', 'VK_KHR_xcb_surface', 'VK_KHR_xlib_surface' ] khxExts = [ 'VK_KHX_device_group', 'VK_KHX_device_group_creation', 'VK_KHX_external_memory', 'VK_KHX_external_memory_capabilities', 'VK_KHX_external_memory_fd', 'VK_KHX_external_memory_win32', 'VK_KHX_external_semaphore', 'VK_KHX_external_semaphore_capabilities', 'VK_KHX_external_semaphore_fd', 'VK_KHX_external_semaphore_win32', 'VK_KHX_multiview', 'VK_KHX_win32_keyed_mutex' ] diff --git a/doc/specs/vulkan/config/extDependency.sh b/doc/specs/vulkan/config/extDependency.sh index a4f50968..7574310c 100644 --- a/doc/specs/vulkan/config/extDependency.sh +++ b/doc/specs/vulkan/config/extDependency.sh @@ -9,6 +9,7 @@ extensions[VK_EXT_direct_mode_display]="VK_KHR_display VK_KHR_surface" extensions[VK_EXT_discard_rectangles]="VK_KHR_get_physical_device_properties2" extensions[VK_EXT_display_control]="VK_EXT_display_surface_counter VK_KHR_display VK_KHR_surface VK_KHR_swapchain" extensions[VK_EXT_display_surface_counter]="VK_KHR_display VK_KHR_surface" +extensions[VK_EXT_swapchain_colorspace]="VK_KHR_surface" extensions[VK_GOOGLE_display_timing]="VK_KHR_surface VK_KHR_swapchain" extensions[VK_KHR_android_surface]="VK_KHR_surface" extensions[VK_KHR_display]="VK_KHR_surface" @@ -39,6 +40,6 @@ extensions[VK_NV_external_memory_win32]="VK_NV_external_memory VK_NV_external_me extensions[VK_NV_win32_keyed_mutex]="VK_NV_external_memory VK_NV_external_memory_capabilities VK_NV_external_memory_win32" # Define lists of all / KHR / KHX extensions -allExts="VK_AMD_draw_indirect_count VK_AMD_gcn_shader VK_AMD_gpu_shader_half_float VK_AMD_negative_viewport_height VK_AMD_rasterization_order VK_AMD_shader_ballot VK_AMD_shader_explicit_vertex_parameter VK_AMD_shader_trinary_minmax VK_EXT_acquire_xlib_display VK_EXT_debug_marker VK_EXT_debug_report VK_EXT_direct_mode_display VK_EXT_discard_rectangles VK_EXT_display_control VK_EXT_display_surface_counter VK_EXT_hdr_metadata VK_EXT_shader_subgroup_ballot VK_EXT_shader_subgroup_vote VK_EXT_validation_flags VK_GOOGLE_display_timing VK_IMG_filter_cubic VK_IMG_format_pvrtc VK_KHR_android_surface VK_KHR_descriptor_update_template VK_KHR_display VK_KHR_display_swapchain VK_KHR_get_physical_device_properties2 VK_KHR_maintenance1 VK_KHR_mir_surface VK_KHR_push_descriptor VK_KHR_sampler_mirror_clamp_to_edge VK_KHR_shader_draw_parameters VK_KHR_surface VK_KHR_swapchain VK_KHR_wayland_surface VK_KHR_win32_surface VK_KHR_xcb_surface VK_KHR_xlib_surface VK_KHX_device_group VK_KHX_device_group_creation VK_KHX_external_memory VK_KHX_external_memory_capabilities VK_KHX_external_memory_fd VK_KHX_external_memory_win32 VK_KHX_external_semaphore VK_KHX_external_semaphore_capabilities VK_KHX_external_semaphore_fd VK_KHX_external_semaphore_win32 VK_KHX_multiview VK_KHX_win32_keyed_mutex VK_MVK_ios_surface VK_MVK_macos_surface VK_NN_vi_surface VK_NVX_device_generated_commands VK_NVX_multiview_per_view_attributes VK_NV_clip_space_w_scaling VK_NV_dedicated_allocation VK_NV_external_memory VK_NV_external_memory_capabilities VK_NV_external_memory_win32 VK_NV_geometry_shader_passthrough VK_NV_glsl_shader VK_NV_sample_mask_override_coverage VK_NV_viewport_array2 VK_NV_viewport_swizzle VK_NV_win32_keyed_mutex" +allExts="VK_AMD_draw_indirect_count VK_AMD_gcn_shader VK_AMD_gpu_shader_half_float VK_AMD_negative_viewport_height VK_AMD_rasterization_order VK_AMD_shader_ballot VK_AMD_shader_explicit_vertex_parameter VK_AMD_shader_trinary_minmax VK_EXT_acquire_xlib_display VK_EXT_debug_marker VK_EXT_debug_report VK_EXT_direct_mode_display VK_EXT_discard_rectangles VK_EXT_display_control VK_EXT_display_surface_counter VK_EXT_hdr_metadata VK_EXT_shader_subgroup_ballot VK_EXT_shader_subgroup_vote VK_EXT_swapchain_colorspace VK_EXT_validation_flags VK_GOOGLE_display_timing VK_IMG_filter_cubic VK_IMG_format_pvrtc VK_KHR_android_surface VK_KHR_descriptor_update_template VK_KHR_display VK_KHR_display_swapchain VK_KHR_get_physical_device_properties2 VK_KHR_maintenance1 VK_KHR_mir_surface VK_KHR_push_descriptor VK_KHR_sampler_mirror_clamp_to_edge VK_KHR_shader_draw_parameters VK_KHR_surface VK_KHR_swapchain VK_KHR_wayland_surface VK_KHR_win32_surface VK_KHR_xcb_surface VK_KHR_xlib_surface VK_KHX_device_group VK_KHX_device_group_creation VK_KHX_external_memory VK_KHX_external_memory_capabilities VK_KHX_external_memory_fd VK_KHX_external_memory_win32 VK_KHX_external_semaphore VK_KHX_external_semaphore_capabilities VK_KHX_external_semaphore_fd VK_KHX_external_semaphore_win32 VK_KHX_multiview VK_KHX_win32_keyed_mutex VK_MVK_ios_surface VK_MVK_macos_surface VK_NN_vi_surface VK_NVX_device_generated_commands VK_NVX_multiview_per_view_attributes VK_NV_clip_space_w_scaling VK_NV_dedicated_allocation VK_NV_external_memory VK_NV_external_memory_capabilities VK_NV_external_memory_win32 VK_NV_geometry_shader_passthrough VK_NV_glsl_shader VK_NV_sample_mask_override_coverage VK_NV_viewport_array2 VK_NV_viewport_swizzle VK_NV_win32_keyed_mutex" khrExts="VK_KHR_android_surface VK_KHR_descriptor_update_template VK_KHR_display VK_KHR_display_swapchain VK_KHR_get_physical_device_properties2 VK_KHR_maintenance1 VK_KHR_mir_surface VK_KHR_push_descriptor VK_KHR_sampler_mirror_clamp_to_edge VK_KHR_shader_draw_parameters VK_KHR_surface VK_KHR_swapchain VK_KHR_wayland_surface VK_KHR_win32_surface VK_KHR_xcb_surface VK_KHR_xlib_surface" khxExts="VK_KHX_device_group VK_KHX_device_group_creation VK_KHX_external_memory VK_KHX_external_memory_capabilities VK_KHX_external_memory_fd VK_KHX_external_memory_win32 VK_KHX_external_semaphore VK_KHX_external_semaphore_capabilities VK_KHX_external_semaphore_fd VK_KHX_external_semaphore_win32 VK_KHX_multiview VK_KHX_win32_keyed_mutex" diff --git a/doc/specs/vulkan/registry.txt b/doc/specs/vulkan/registry.txt index 0b7a4271..d67b20c8 100644 --- a/doc/specs/vulkan/registry.txt +++ b/doc/specs/vulkan/registry.txt @@ -355,8 +355,15 @@ member. ==== Attributes of tag:member tags * attr:validextensionstructs - only valid on the `pNext` member of a - struct. This is a comma-separated list of structures that may be - accepted by `pNext` instead of `NULL` + struct. + This is a comma-separated list of structures that may be accepted by + `pNext` instead of `NULL`. + This should usually only be put on the top-level structure that is + extended, for all possible chained structures - the chained structures + themselves should be tagged with attr:noautovalidity. + This will generate a validity statement on the top level structure + that validates the entire chain in one go, rather than each chained + structure repeating the list of valid structs. * attr:values - only valid on the `sType` member of a struct. This is a comma-separated list of enumerant values that are valid for the structure type; usually there is only a single value. diff --git a/doc/specs/vulkan/style/extensions.txt b/doc/specs/vulkan/style/extensions.txt index 50036a91..f586c7b2 100644 --- a/doc/specs/vulkan/style/extensions.txt +++ b/doc/specs/vulkan/style/extensions.txt @@ -789,3 +789,7 @@ If an extension needs a specific ordering of its extension structure with respect to other extensions in a chain to provide deterministic results, it must define the required ordering and expected behavior as part of its specification. + +Validation of such extended structure chains is automatically generated from +the registry, as described in the description of attr:validextensionstructs +in link:registry.html[the registry document]. diff --git a/doc/specs/vulkan/style/naming.txt b/doc/specs/vulkan/style/naming.txt index 53bf2578..c25b4c5f 100644 --- a/doc/specs/vulkan/style/naming.txt +++ b/doc/specs/vulkan/style/naming.txt @@ -110,6 +110,49 @@ typedef union VkClearColorValue { ---- +[[naming-extension-structures]] +=== Extension Structure Names + +Structures which extend other structures through the pname:pNext chain +should reflect the name of the base structure they extend. +Currently there are two examples of such naming schemes. + +New structures which add extended object creation parameters to a base +structure should use this naming scheme: + +.Extended Object Information Structures +[width="60%",options="header"] +|==== +| Base Structure Name | Extension Structure Name +| `Vk__Object__CreateInfo` + | `Vk__ObjectName__CreateInfo__Author__` +|==== + +`_Object_` is the name of the object being created. +`_Name_` is a short name for the extension or the new information added by +that extension. +`_Author_` is the author ID of the extension. + +New structures which extend API queries, such as the +`vkGetPhysicalDeviceFeatures2KHR` and `vkGetPhysicalDeviceProperties2KHR` +commands defined by the `VK_KHR_get_physical_device_properties2` extension, +should use this naming scheme: + +.Extended Query Structures +[width="60%",options="header"] +|==== +| Base Structure Name | Extension Structure Name +| `vkGetPhysicalDeviceFeatures2KHR` + | `VkPhysicalDevice__Name__Features__Author__` +| `vkGetPhysicalDeviceProperties2KHR` + | `VkPhysicalDevice__Name__Properties__Author__` +|==== + +`_Name_` is a short name for the extension, or for the new feature or +property being queried, such as `Multiview` or `DiscardRectangle`. +`_Author_` is the author ID of the extension. + + == Enumerant Names Enumerants include an underscore `_` as a delimiter between words, with diff --git a/doc/specs/vulkan/style/writing.txt b/doc/specs/vulkan/style/writing.txt index e7695f71..aea401ee 100644 --- a/doc/specs/vulkan/style/writing.txt +++ b/doc/specs/vulkan/style/writing.txt @@ -134,6 +134,10 @@ of a structure as a "`color space`" value. miptail | "`mipmap *term*`" may be used in time 3+h| Exceptions | mipmap | mip map | Exception for historical reasons +| pname:pNext chain + | pname:pNext-chain + + pname:pNext extension chain + | | swapchain | swap chain | Exception due to heavy use in WSI extensions | happen-before + happen-after | happen before + diff --git a/doc/specs/vulkan/styleguide.txt b/doc/specs/vulkan/styleguide.txt index 38cbd215..c907638d 100644 --- a/doc/specs/vulkan/styleguide.txt +++ b/doc/specs/vulkan/styleguide.txt @@ -153,6 +153,8 @@ include::style/writing.txt[] = Revision History +* 2017-03-19 - Add naming rule for <>. * 2017-02-11 - Finish transitioning to asciidoctor markup. * 2016-09-28 - Add asciidoc math markup guidelines. * 2016-09-16 - Make style guide markup more consistent with its own diff --git a/src/spec/validitygenerator.py b/src/spec/validitygenerator.py index 9a0750f7..4aaa76ed 100644 --- a/src/spec/validitygenerator.py +++ b/src/spec/validitygenerator.py @@ -667,12 +667,10 @@ class ValidityOutputGenerator(OutputGenerator): paramname = param.find('name') paramtype = param.find('type') - asciidoc += self.makeParameterName(paramname.text) - validextensionstructs = param.attrib.get('validextensionstructs') - asciidoc += ' must: be `NULL`' + extensionstructs = [] + if validextensionstructs is not None: - extensionstructs = [] # Check each structure name and skip it if not required by the # generator. This allows tagging extension structs in the XML # that are only included in validity when needed for the spec @@ -686,12 +684,23 @@ class ValidityOutputGenerator(OutputGenerator): extensionstructs.append('slink:' + struct) else: self.logMsg('diag', 'makeStructureExtensionPointer: struct', struct, 'IS NOT required') - if len(extensionstructs) > 0: - asciidoc += ', or a pointer to a valid instance of ' - if len(extensionstructs) == 1: - asciidoc += extensionstructs[0] - else: - asciidoc += (', ').join(extensionstructs[:-1]) + ', or ' + extensionstructs[-1] + + if len(extensionstructs) == 0: + asciidoc += self.makeParameterName(paramname.text) + asciidoc += ' must: be `NULL`' + elif len(extensionstructs) == 1: + asciidoc += self.makeParameterName(paramname.text) + asciidoc += ' must: be `NULL` or a pointer to a valid instance of ' + asciidoc += extensionstructs[0] + else: + asciidoc += 'Each ' + asciidoc += self.makeParameterName(paramname.text) + asciidoc += ' member of any structure (including this one) in the pname:pNext chain must: be either `NULL` or a pointer to a valid instance of ' + + if len(extensionstructs) == 2: + asciidoc += extensionstructs[0] + ' or ' + extensionstructs[1] + else: + asciidoc += (', ').join(extensionstructs[:-1]) + ', or ' + extensionstructs[-1] asciidoc += '\n' @@ -713,14 +722,15 @@ class ValidityOutputGenerator(OutputGenerator): # Get the type's category typecategory = self.getTypeCategory(paramtype.text) - - # Generate language to independently validate a parameter - if paramtype.text == 'VkStructureType' and paramname.text == 'sType': - asciidoc += self.makeStructureType(blockname, param) - elif paramtype.text == 'void' and paramname.text == 'pNext': - asciidoc += self.makeStructureExtensionPointer(param) - else: - asciidoc += self.createValidationLineForParameter(param, params, typecategory) + + if param.attrib.get('noautovalidity') is None: + # Generate language to independently validate a parameter + if paramtype.text == 'VkStructureType' and paramname.text == 'sType': + asciidoc += self.makeStructureType(blockname, param) + elif paramtype.text == 'void' and paramname.text == 'pNext': + asciidoc += self.makeStructureExtensionPointer(param) + else: + asciidoc += self.createValidationLineForParameter(param, params, typecategory) # Ensure that any parenting is properly validated, and list that a handle was found if typecategory == 'handle': diff --git a/src/spec/vk.xml b/src/spec/vk.xml index 50cacce3..27fecc78 100644 --- a/src/spec/vk.xml +++ b/src/spec/vk.xml @@ -112,7 +112,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. // Vulkan 1.0 version number #define VK_API_VERSION_1_0 VK_MAKE_VERSION(1, 0, 0) // Version of this file -#define VK_HEADER_VERSION 44 +#define VK_HEADER_VERSION 45 #define VK_DEFINE_HANDLE(object) typedef struct object##_T* object; @@ -1474,7 +1474,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkRect2D srcRect VkRect2D dstRect VkBool32 persistent @@ -1587,7 +1587,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkRasterizationOrderAMD rasterizationOrder @@ -1614,17 +1614,17 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkBool32 dedicatedAllocation VkStructureType sType - const void* pNext + const void* pNext VkBool32 dedicatedAllocation VkStructureType sType - const void* pNext + const void* pNext VkImage image VkBuffer buffer @@ -1658,7 +1658,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t acquireCount const VkDeviceMemory* pAcquireSyncs const uint64_t* pAcquireKeys @@ -1768,7 +1768,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkShaderStageFlags stageFlags - VkStructureType sType + VkStructureType sType void* pNext VkPhysicalDeviceFeatures features @@ -1832,7 +1832,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkExternalMemoryHandleTypeFlagBitsKHX handleType @@ -1906,7 +1906,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t acquireCount const VkDeviceMemory* pAcquireSyncs const uint64_t* pAcquireKeys @@ -1948,7 +1948,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t waitSemaphoreValuesCount const uint64_t* pWaitSemaphoreValues uint32_t signalSemaphoreValuesCount @@ -1963,7 +1963,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - void* pNext + void* pNext VkBool32 multiview VkBool32 multiviewGeometryShader VkBool32 multiviewTessellationShader @@ -2021,14 +2021,14 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + void* pNext uint32_t physicalDeviceCount VkPhysicalDevice physicalDevices[VK_MAX_DEVICE_GROUP_SIZE_KHX] VkBool32 subsetAllocation VkStructureType sType - const void* pNext + const void* pNext VkMemoryAllocateFlagsKHX flags uint32_t deviceMask @@ -2054,19 +2054,19 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t deviceMask uint32_t deviceRenderAreaCount const VkRect2D* pDeviceRenderAreas VkStructureType sType - const void* pNext + const void* pNext uint32_t deviceMask VkStructureType sType - const void* pNext + const void* pNext uint32_t waitSemaphoreCount const uint32_t* pWaitSemaphoreDeviceIndices uint32_t commandBufferCount @@ -2076,7 +2076,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t resourceDeviceIndex uint32_t memoryDeviceIndex @@ -2088,12 +2088,12 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkSwapchainKHR swapchain VkStructureType sType - const void* pNext + const void* pNext VkSwapchainKHR swapchain uint32_t imageIndex @@ -2108,20 +2108,20 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t swapchainCount const uint32_t* pDeviceMasks VkDeviceGroupPresentModeFlagBitsKHX mode VkStructureType sType - const void* pNext + const void* pNext uint32_t physicalDeviceCount const VkPhysicalDevice* pPhysicalDevices VkStructureType sType - const void* pNext + const void* pNext VkDeviceGroupPresentModeFlagsKHX modes @@ -2176,7 +2176,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext uint32_t swapchainCount const VkPresentTimeGOOGLE* pTimes @@ -2202,7 +2202,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. VkStructureType sType - const void* pNext + const void* pNext VkBool32 viewportWScalingEnable uint32_t viewportCount const VkViewportWScalingNV* pViewportWScalings @@ -5152,7 +5152,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. - + @@ -5591,7 +5591,7 @@ maintained in the master branch of the Khronos Vulkan GitHub project. - + @@ -5678,6 +5678,9 @@ maintained in the master branch of the Khronos Vulkan GitHub project. + + + @@ -6038,22 +6041,23 @@ maintained in the master branch of the Khronos Vulkan GitHub project. - + - + - - - - - - - - - - + + + + + + + + + + + @@ -6206,10 +6210,10 @@ maintained in the master branch of the Khronos Vulkan GitHub project. - + - + @@ -6224,5 +6228,11 @@ maintained in the master branch of the Khronos Vulkan GitHub project. + + + + + + diff --git a/src/vulkan/vulkan.h b/src/vulkan/vulkan.h index 1ac55dfe..a2358611 100644 --- a/src/vulkan/vulkan.h +++ b/src/vulkan/vulkan.h @@ -43,7 +43,7 @@ extern "C" { #define VK_VERSION_MINOR(version) (((uint32_t)(version) >> 12) & 0x3ff) #define VK_VERSION_PATCH(version) ((uint32_t)(version) & 0xfff) // Version of this file -#define VK_HEADER_VERSION 44 +#define VK_HEADER_VERSION 45 #define VK_NULL_HANDLE 0 @@ -261,6 +261,9 @@ typedef enum VkStructureType { VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_EXTERNAL_BUFFER_INFO_KHX = 1000071002, VK_STRUCTURE_TYPE_EXTERNAL_BUFFER_PROPERTIES_KHX = 1000071003, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ID_PROPERTIES_KHX = 1000071004, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROPERTIES_2_KHX = 1000071005, + VK_STRUCTURE_TYPE_IMAGE_FORMAT_PROPERTIES_2_KHX = 1000071006, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_FORMAT_INFO_2_KHX = 1000071007, VK_STRUCTURE_TYPE_EXTERNAL_MEMORY_BUFFER_CREATE_INFO_KHX = 1000072000, VK_STRUCTURE_TYPE_EXTERNAL_MEMORY_IMAGE_CREATE_INFO_KHX = 1000072001, VK_STRUCTURE_TYPE_EXPORT_MEMORY_ALLOCATE_INFO_KHX = 1000072002, @@ -3295,6 +3298,19 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkSurfaceKHR) typedef enum VkColorSpaceKHR { VK_COLOR_SPACE_SRGB_NONLINEAR_KHR = 0, + VK_COLOR_SPACE_DISPLAY_P3_NONLINEAR_EXT = 1000104001, + VK_COLOR_SPACE_EXTENDED_SRGB_LINEAR_EXT = 1000104002, + VK_COLOR_SPACE_DCI_P3_LINEAR_EXT = 1000104003, + VK_COLOR_SPACE_DCI_P3_NONLINEAR_EXT = 1000104004, + VK_COLOR_SPACE_BT709_LINEAR_EXT = 1000104005, + VK_COLOR_SPACE_BT709_NONLINEAR_EXT = 1000104006, + VK_COLOR_SPACE_BT2020_LINEAR_EXT = 1000104007, + VK_COLOR_SPACE_HDR10_ST2084_EXT = 1000104008, + VK_COLOR_SPACE_DOLBYVISION_EXT = 1000104009, + VK_COLOR_SPACE_HDR10_HLG_EXT = 1000104010, + VK_COLOR_SPACE_ADOBERGB_LINEAR_EXT = 1000104011, + VK_COLOR_SPACE_ADOBERGB_NONLINEAR_EXT = 1000104012, + VK_COLOR_SPACE_PASS_THROUGH_EXT = 1000104013, VK_COLOR_SPACE_BEGIN_RANGE_KHR = VK_COLOR_SPACE_SRGB_NONLINEAR_KHR, VK_COLOR_SPACE_END_RANGE_KHR = VK_COLOR_SPACE_SRGB_NONLINEAR_KHR, VK_COLOR_SPACE_RANGE_SIZE_KHR = (VK_COLOR_SPACE_SRGB_NONLINEAR_KHR - VK_COLOR_SPACE_SRGB_NONLINEAR_KHR + 1), @@ -4758,7 +4774,7 @@ VKAPI_ATTR VkResult VKAPI_CALL vkCreateViSurfaceNN( typedef struct VkPhysicalDeviceGroupPropertiesKHX { VkStructureType sType; - const void* pNext; + void* pNext; uint32_t physicalDeviceCount; VkPhysicalDevice physicalDevices[VK_MAX_DEVICE_GROUP_SIZE_KHX]; VkBool32 subsetAllocation; @@ -5684,6 +5700,11 @@ VKAPI_ATTR void VKAPI_CALL vkCmdSetDiscardRectangleEXT( const VkRect2D* pDiscardRectangles); #endif +#define VK_EXT_swapchain_colorspace 1 +#define VK_EXT_SWAPCHAIN_COLOR_SPACE_SPEC_VERSION 2 +#define VK_EXT_SWAPCHAIN_COLOR_SPACE_EXTENSION_NAME "VK_EXT_swapchain_colorspace" + + #define VK_EXT_hdr_metadata 1 #define VK_EXT_HDR_METADATA_SPEC_VERSION 1 #define VK_EXT_HDR_METADATA_EXTENSION_NAME "VK_EXT_hdr_metadata"