From b6aea0ffaf48a98ad61b73193c2efa15ccd455f4 Mon Sep 17 00:00:00 2001 From: Petr Kraus Date: Mon, 26 Mar 2018 19:52:13 +0200 Subject: [PATCH] Refine extension dependencies - requires impls to honor resolution in #659 - addresses some confusion in Vulkan-LoaderAndValidationLayers/#2366 - require impls to support dependencies --- appendices/glossary.txt | 2 +- chapters/extensions.txt | 34 ++++++++++++++++++++++------------ 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/appendices/glossary.txt b/appendices/glossary.txt index 01f1e92b..e31e5042 100644 --- a/appendices/glossary.txt +++ b/appendices/glossary.txt @@ -1021,7 +1021,7 @@ Render Pass Instance:: A use of a render pass in a command buffer. Required Extensions:: - Extensions which must: be enabled to use a specific enabled extension + Extensions that must: be enabled alongside extensions dependent on them (see <>). diff --git a/chapters/extensions.txt b/chapters/extensions.txt index 1d137122..03782080 100644 --- a/chapters/extensions.txt +++ b/chapters/extensions.txt @@ -223,6 +223,15 @@ wrapped by the validation layers. See the <> document for additional information. +[NOTE] +.Note +==== +Valid Usage sections for individual commands and structures do not currently +contain which extensions have to be enabled in order to make their use +valid, although it might do so in the future. +It is defined only in the <> section. +==== + [open,refpage='vkEnumerateInstanceExtensionProperties',desc='Returns up to requested number of global extension properties',type='protos'] -- @@ -344,21 +353,22 @@ endif::VK_VERSION_1_1,VK_KHR_get_physical_device_properties2[] == Extension Dependencies Some extensions are dependent on other extensions to function. -To use extensions with dependencies, such _required extensions_ must: also -be enabled through the same API mechanisms when creating an instance with -flink:vkCreateInstance or a device with flink:vkCreateDevice. +To enable extensions with dependencies, such _required extensions_ must: +also be enabled through the same API mechanisms when creating an instance +with flink:vkCreateInstance or a device with flink:vkCreateDevice. Each extension which has such dependencies documents them in the <>. -[NOTE] -.Note -==== -The Specification does not currently include required extensions in Valid -Usage statements for individual commands and structures, although it might -do so in the future. -Nonetheless, applications must: not use any extension functionality if -dependencies of that extension are not enabled. -==== +If an extension is supported (as queried by +flink:vkEnumerateInstanceExtensionProperties or +flink:vkEnumerateDeviceExtensionProperties), then _required extensions_ of +that extension must: also be supported for the same instance or +physical device. + +Any device extension that has an instance extension dependency that is not +enabled by flink:vkCreateInstance is considered to be unsupported, hence it +must: not be returned by flink:vkEnumerateDeviceExtensionProperties for any +slink:VkPhysicalDevice child of the instance. [[extended-functionality-extensions-compatibility]]