Compare commits

...

10 Commits

Author SHA1 Message Date
Sharadh Rajaraman 86cebc2473 Building section 2025-11-23 21:06:36 +00:00
Sharadh Rajaraman c2a3479a3b Introduction and installation 2025-11-23 20:55:17 +00:00
Sharadh Rajaraman 9104ffcacc Adhere to some markdownlint recommendations
- `-` instead of `*`
- Spaces around lists
2025-11-14 00:29:09 +00:00
Sharadh Rajaraman b67b5d3074 Initial readme rework
- Remove HTML hyperlinks; markdown generates automatically
- Use backticks \` to demarcate config macros
- Remove `VULKAN_HPP_NO_STD_MODULE` option
2025-11-14 00:29:09 +00:00
Andreas Süßenbach 8e79f71c15
Extend enum value alias handling. (#2361)
Set Version Tag / set-version-tag (push) Has been cancelled Details
2025-11-13 14:09:34 +01:00
Andreas Süßenbach 9747e68285
Restrict template argument Dispatch to only take evaluate the newly introduced type trait isDispatchLoader with value == true. (#2360)
Set Version Tag / set-version-tag (push) Has been cancelled Details
2025-11-12 18:21:31 +01:00
Jan Kuhlmann 7c480ca5aa
C++Module: Fix GCC error and replace `std.compat` with `std` (#2353)
* iunclude vulkan.h before the import

* replace std.compat with std
2025-11-12 13:49:10 +01:00
Andreas Süßenbach 5cd5bcf6de
Extent function call tests with Fence commands (#2359) 2025-11-12 13:42:37 +01:00
Nikita Gubarkov c75dcdc0bb
Export vk::raii::isVulkanRAIIHandleType (#2357)
Set Version Tag / set-version-tag (push) Waiting to run Details
2025-11-12 10:12:14 +01:00
Andreas Süßenbach 15f4b3024f
Fix default values of function arguments when VULKAN_HPP_NO_DEFAULT_DISPATCHER is defined. (#2356) 2025-11-12 10:08:57 +01:00
22 changed files with 5909 additions and 5014 deletions

674
README.md

File diff suppressed because it is too large Load Diff

View File

@ -28,6 +28,8 @@ using namespace std::literals;
namespace
{
template <typename T>
bool containsByName( std::vector<T> const & values, std::string const & name );
std::vector<std::pair<std::string, size_t>> filterNumbers( std::vector<std::string> const & names );
template <typename T>
typename std::vector<T>::const_iterator findByName( std::vector<T> const & values, std::string const & name );
@ -1552,40 +1554,8 @@ std::set<size_t> VulkanHppGenerator::determineVoidPointerParams( std::vector<Par
return voidPointerParams;
}
void VulkanHppGenerator::distributeEnumExtends()
{
for ( auto const & extendedEnum : m_enumExtends )
{
assert( !extendedEnum.second.empty() );
auto typeIt = m_types.find( extendedEnum.first );
checkForError( typeIt != m_types.end(),
extendedEnum.second.front().xmlLine,
"enum value <" + extendedEnum.second.front().name + "> extends unknown type <" + extendedEnum.first + ">" );
checkForError( typeIt->second.category == TypeCategory::Enum,
extendedEnum.second.front().xmlLine,
"enum value <" + extendedEnum.second.front().name + "> extends non-enum type <" + extendedEnum.first + ">" );
const auto enumIt = m_enums.find( extendedEnum.first );
assert( enumIt != m_enums.end() );
for ( auto const & eed : extendedEnum.second )
{
for ( auto const & requiredBy : eed.requiredBy )
{
typeIt->second.requiredBy.insert( requiredBy );
}
checkForError( enumIt->second.addEnumAlias( eed.xmlLine, eed.name, eed.alias, eed.protect, ( eed.api.empty() || ( eed.api == m_api ) ) && eed.supported ),
eed.xmlLine,
"enum value alias <" + eed.name + "> already listed with different properties" );
}
}
m_enumExtends.clear();
}
void VulkanHppGenerator::distributeEnumValueAliases()
{
assert( m_enumExtends.empty() );
for ( auto & e : m_enums )
{
for ( auto & a : e.second.valueAliases )
@ -1710,7 +1680,7 @@ void VulkanHppGenerator::extendSpecialCommands( std::string const & name, bool d
cmd.insert(
pos,
R"( // wrapper function for command vkSetDebugUtilsObjectNameEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkSetDebugUtilsObjectNameEXT.html
template <typename HandleType, typename Dispatch>
template <typename HandleType, typename Dispatch, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type>
VULKAN_HPP_NODISCARD_WHEN_NO_EXCEPTIONS VULKAN_HPP_INLINE typename ResultValueType<void>::type
Device::setDebugUtilsObjectNameEXT( HandleType const & handle, std::string const & name, Dispatch const & d ) const
{
@ -1728,7 +1698,7 @@ void VulkanHppGenerator::extendSpecialCommands( std::string const & name, bool d
{
cmd.insert( pos, R"( // wrapper function for command vkSetDebugUtilsObjectNameEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkSetDebugUtilsObjectNameEXT.html
template <typename HandleType, typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType, typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type = true>
VULKAN_HPP_NODISCARD_WHEN_NO_EXCEPTIONS typename ResultValueType<void>::type
setDebugUtilsObjectNameEXT( HandleType const & handle, std::string const & name, Dispatch const & d VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) const;
)" );
@ -1781,7 +1751,7 @@ void VulkanHppGenerator::extendSpecialCommands( std::string const & name, bool d
cmd.insert(
pos,
R"( // wrapper function for command vkSetDebugUtilsObjectTagEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkSetDebugUtilsObjectTagEXT.html
template <typename HandleType, typename TagType, typename Dispatch>
template <typename HandleType, typename TagType, typename Dispatch, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type>
VULKAN_HPP_NODISCARD_WHEN_NO_EXCEPTIONS VULKAN_HPP_INLINE typename ResultValueType<void>::type
Device::setDebugUtilsObjectTagEXT( HandleType const & handle, uint64_t name, TagType const & tag, Dispatch const & d ) const
{
@ -1801,7 +1771,7 @@ void VulkanHppGenerator::extendSpecialCommands( std::string const & name, bool d
{
cmd.insert( pos, R"( // wrapper function for command vkSetDebugUtilsObjectTagEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkSetDebugUtilsObjectTagEXT.html
template <typename HandleType, typename TagType, typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename HandleType, typename TagType, typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type = true>
VULKAN_HPP_NODISCARD_WHEN_NO_EXCEPTIONS typename ResultValueType<void>::type setDebugUtilsObjectTagEXT(
HandleType const & handle, uint64_t name, TagType const & tag, Dispatch const & d VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) const;
)" );
@ -2076,7 +2046,8 @@ std::string VulkanHppGenerator::generateArgumentListEnhanced( std::vector<ParamD
}
else if ( params[i].optional )
{
arguments.push_back( "Optional<" + stripPostfix( composedType, " *" ) + "> " + name + ( ( definition || withAllocators ) ? "" : " = nullptr" ) );
arguments.push_back( "Optional<" + stripPostfix( composedType, " *" ) + "> " + name +
( ( definition || withAllocators ) ? "" : " VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr )" ) );
hasDefaultAssignment = true;
}
else
@ -2094,7 +2065,8 @@ std::string VulkanHppGenerator::generateArgumentListEnhanced( std::vector<ParamD
assert( params[i].type.type == "char" );
if ( params[i].optional )
{
arguments.push_back( "Optional<const std::string> " + name + ( ( definition || withAllocators ) ? "" : " = nullptr" ) );
arguments.push_back( "Optional<const std::string> " + name +
( ( definition || withAllocators ) ? "" : " VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr )" ) );
hasDefaultAssignment = true;
}
else
@ -2115,7 +2087,7 @@ std::string VulkanHppGenerator::generateArgumentListEnhanced( std::vector<ParamD
if ( params[i].optional && !definition )
{
assert( params[i].strideParam.first.empty() );
arguments.back() += " = nullptr";
arguments.back() += " VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr )";
hasDefaultAssignment = true;
}
}
@ -2142,7 +2114,7 @@ std::string VulkanHppGenerator::generateArgumentListEnhanced( std::vector<ParamD
std::string paramName = ( definition && ( params[i].name == "objectType" ) ) ? "objectType_" : params[i].name;
arguments.push_back( composedType + " " + paramName + generateCArraySizes( params[i].arraySizes ) );
}
arguments.back() += std::string( !definition && ( defaultStartIndex <= i ) && !hasDefaultAssignment ? " = {}" : "" );
arguments.back() += std::string( !definition && ( defaultStartIndex <= i ) && !hasDefaultAssignment ? " VULKAN_HPP_DEFAULT_ASSIGNMENT( {} )" : "" );
}
}
if ( withAllocators )
@ -3201,10 +3173,10 @@ std::string VulkanHppGenerator::generateCommandDefinitions( std::string const &
pos = destroyCommandString.find( commandIt->second.params[1].name,
pos + 1 ); // get the argument to destroy in the advanced version
assert( pos != std::string::npos );
pos = destroyCommandString.find( " = {}", pos );
pos = destroyCommandString.find( " VULKAN_HPP_DEFAULT_ASSIGNMENT( {} )", pos );
if ( pos != std::string::npos )
{
destroyCommandString.erase( pos, strlen( " = {}" ) );
destroyCommandString.erase( pos, strlen( " VULKAN_HPP_DEFAULT_ASSIGNMENT( {} )" ) );
}
str += "\n" + destroyCommandString;
}
@ -3293,7 +3265,7 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const &
std::string const functionTemplate =
R"( // wrapper function for command ${vkCommandName}, see https://registry.khronos.org/vulkan/specs/latest/man/html/${vkCommandName}.html
template <${argumentTemplates}${allocatorTemplates}typename Dispatch${uniqueHandleAllocatorTemplates}${typenameCheck}>
template <${argumentTemplates}${allocatorTemplates}typename Dispatch${uniqueHandleAllocatorTemplates}${typenameCheck}, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type>
${nodiscard}VULKAN_HPP_INLINE ${decoratedReturnType} ${className}${classSeparator}${commandName}( ${argumentList} )${const}${noexcept}
{
VULKAN_HPP_ASSERT( d.getVkHeaderVersion() == VK_HEADER_VERSION );
@ -3336,7 +3308,7 @@ ${vectorSizeCheck}
{
std::string const functionTemplate =
R"( // wrapper function for command ${vkCommandName}, see https://registry.khronos.org/vulkan/specs/latest/man/html/${vkCommandName}.html
template <${argumentTemplates}${allocatorTemplates}typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE${uniqueHandleAllocatorTemplates}${typenameCheck}>
template <${argumentTemplates}${allocatorTemplates}typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE${uniqueHandleAllocatorTemplates}${typenameCheck}, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type = true>
${nodiscard}${decoratedReturnType} ${commandName}( ${argumentList} )${const}${noexcept};)";
return replaceWithMap( functionTemplate,
@ -4487,7 +4459,7 @@ std::string
std::string const functionTemplate =
R"( // wrapper function for command ${vkCommandName}, see https://registry.khronos.org/vulkan/specs/latest/man/html/${vkCommandName}.html
template <typename Dispatch>
template <typename Dispatch, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type>
${nodiscard}VULKAN_HPP_INLINE ${returnType} ${className}${classSeparator}${commandName}( ${argumentList} )${const} VULKAN_HPP_NOEXCEPT
{
VULKAN_HPP_ASSERT( d.getVkHeaderVersion() == VK_HEADER_VERSION );
@ -4509,7 +4481,7 @@ std::string
{
std::string const functionTemplate =
R"( // wrapper function for command ${vkCommandName}, see https://registry.khronos.org/vulkan/specs/latest/man/html/${vkCommandName}.html
template <typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
template <typename Dispatch = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE, typename std::enable_if<detail::isDispatchLoader<Dispatch>::value, bool>::type = true>
${nodiscard}${returnType} ${commandName}( ${argumentList} VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )${const} VULKAN_HPP_NOEXCEPT;)";
return replaceWithMap( functionTemplate,
@ -5509,6 +5481,7 @@ std::string VulkanHppGenerator::generateCppModuleUsings() const
#endif /*VK_NO_PROTOTYPES*/
using VULKAN_HPP_NAMESPACE::detail::createResultValueType;
using VULKAN_HPP_NAMESPACE::detail::resultCheck;
using VULKAN_HPP_NAMESAPCE::detail::isDispatchLoader;
}
#if !defined( VULKAN_HPP_DISABLE_ENHANCED_MODE )
namespace VULKAN_HPP_RAII_NAMESPACE
@ -5701,6 +5674,7 @@ std::string VulkanHppGenerator::generateCppModuleRaiiUsings() const
//======================
using VULKAN_HPP_RAII_NAMESPACE::Context;
using VULKAN_HPP_RAII_NAMESPACE::isVulkanRAIIHandleType;
namespace detail
{
using VULKAN_HPP_RAII_NAMESPACE::detail::ContextDispatcher;
@ -6798,7 +6772,14 @@ ${deviceCommandAssignments}
static DynamicLoader dl;
init(instance, device, dl);
}
};)";
};
template <>
struct isDispatchLoader<DispatchLoaderDynamic>
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = true;
};
)";
std::string commandMembers, deviceCommandAssignments, initialCommandAssignments, instanceCommandAssignments;
std::set<std::string> listedCommands; // some commands are listed with more than one extension!
@ -6901,6 +6882,12 @@ std::string VulkanHppGenerator::generateDispatchLoaderStatic() const
${commands}
};
template <>
struct isDispatchLoader<DispatchLoaderStatic>
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = true;
};
inline DispatchLoaderStatic & getDispatchLoaderStatic()
{
static DispatchLoaderStatic dls;
@ -6964,10 +6951,10 @@ std::string VulkanHppGenerator::generateDestroyCommand( std::string const & name
pos = destroyCommandString.find( localCommandData.params[1].name,
pos + 1 ); // get the argument to destroy in the advanced version
assert( pos != std::string::npos );
pos = destroyCommandString.find( " = {}", pos );
pos = destroyCommandString.find( " VULKAN_HPP_DEFAULT_ASSIGNMENT( {} )", pos );
if ( pos != std::string::npos )
{
destroyCommandString.erase( pos, strlen( " = {}" ) );
destroyCommandString.erase( pos, strlen( " VULKAN_HPP_DEFAULT_ASSIGNMENT( {} )" ) );
}
return "\n" + destroyCommandString;
}
@ -15352,7 +15339,6 @@ void VulkanHppGenerator::readRegistry( tinyxml2::XMLElement const * element )
// for all api but vulkanbase, we merge the internal features into the normal ones
mergeInternalFeatures();
}
distributeEnumExtends();
distributeEnumValueAliases();
distributeStructAliases();
distributeRequirements();
@ -15471,19 +15457,15 @@ void VulkanHppGenerator::readRequireEnum(
protect = getProtectFromPlatform( platform );
}
auto extendIt = m_enumExtends.insert( { extends, {} } ).first;
auto eedIt = std::ranges::find_if( extendIt->second, [&name]( auto const & eed ) { return eed.name == name; } );
if ( eedIt == extendIt->second.end() )
{
extendIt->second.push_back( { alias, api, name, protect, { requiredBy }, supported, line } );
}
else
{
checkForError( ( eedIt->alias == alias ) && ( eedIt->api == api ) && ( eedIt->protect == protect ) && ( eedIt->supported == supported ),
line,
"extending enum <" + extends + "> with already listed value <" + name + "> but different properties" );
eedIt->requiredBy.insert( requiredBy );
}
auto typeIt = m_types.find( extends );
checkForError( typeIt != m_types.end(), line, "enum value <" + name + "> extends unknown type <" + extends + ">" );
checkForError( typeIt->second.category == TypeCategory::Enum, line, "enum value <" + name + "> extends non-enum type <" + extends + ">" );
typeIt->second.requiredBy.insert( requiredBy );
auto enumIt = findByNameOrAlias( m_enums, extends );
assert( enumIt != m_enums.end() );
checkForError( enumIt->second.addEnumAlias( line, name, alias, protect, supported ),
line,
"enum value alias <" + name + "> already listed with different properties" );
}
}
else
@ -15742,7 +15724,9 @@ void VulkanHppGenerator::readSPIRVCapabilityEnable( tinyxml2::XMLElement const *
const auto enumIt = m_enums.find( bitmaskIt->second.require );
checkForError(
enumIt != m_enums.end(), line, "member <" + member + "> specified for SPIR-V capability requires an unknown enum <" + bitmaskIt->second.require + ">" );
checkForError( containsName( enumIt->second.values, value ), line, "unknown attribute value <" + value + "> specified for SPIR-V capability" );
checkForError( containsByName( enumIt->second.values, value ) || containsByName( enumIt->second.valueAliases, value ),
line,
"unknown attribute value <" + value + "> specified for SPIR-V capability" );
}
}
else if ( attributes.contains( "struct" ) )
@ -17418,6 +17402,10 @@ bool VulkanHppGenerator::EnumData::addEnumAlias( int line, std::string const & n
{
valueAliases.push_back( { alias, name, protect, supported, line } );
}
else
{
ok = ( ( aliasIt->alias == alias ) && ( aliasIt->protect == protect ) && ( aliasIt->supported == supported ) );
}
return ok;
}
@ -17449,6 +17437,12 @@ bool VulkanHppGenerator::EnumData::addEnumValue(
namespace
{
template <typename T>
bool containsByName( std::vector<T> const & values, std::string const & name )
{
return std::ranges::any_of( values, [&name]( T const & value ) { return value.name == name; } );
}
std::vector<std::pair<std::string, size_t>> filterNumbers( std::vector<std::string> const & names )
{
std::vector<std::pair<std::string, size_t>> filteredNames;

View File

@ -600,7 +600,6 @@ private:
std::string determineSubStruct( std::pair<std::string, StructData> const & structure ) const;
std::map<size_t, VectorParamData> determineVectorParams( std::vector<ParamData> const & params ) const;
std::set<size_t> determineVoidPointerParams( std::vector<ParamData> const & params ) const;
void distributeEnumExtends();
void distributeEnumValueAliases();
void distributeRequirements();
void distributeRequirements( std::vector<RequireData> const & requireData, std::string const & requiredBy );
@ -1266,27 +1265,26 @@ private:
MemberData const & vectorMemberByStructure( std::string const & structureType ) const;
private:
std::string m_api;
std::map<std::string, BaseTypeData> m_baseTypes;
std::map<std::string, BitmaskData> m_bitmasks;
std::set<std::string> m_commandQueues;
std::map<std::string, CommandData> m_commands;
std::map<std::string, ConstantData> m_constants;
std::map<std::string, DefineData> m_defines;
DefinesPartition m_definesPartition; // partition defined macros into mutually-exclusive sets of callees, callers, and values
std::map<std::string, std::vector<EnumExtendData>> m_enumExtends;
std::map<std::string, EnumData> m_enums;
std::vector<ExtensionData> m_extensions;
std::map<std::string, ExternalTypeData> m_externalTypes;
std::vector<FeatureData> m_features;
std::map<std::string, FormatData> m_formats;
std::map<std::string, FuncPointerData> m_funcPointers;
std::map<std::string, HandleData> m_handles;
std::map<std::string, IncludeData> m_includes;
std::map<std::string, PlatformData> m_platforms;
std::set<std::string> m_RAIISpecialFunctions;
std::map<std::string, SpirVCapabilityData> m_spirVCapabilities;
std::map<std::string, StructData> m_structs;
std::string m_api;
std::map<std::string, BaseTypeData> m_baseTypes;
std::map<std::string, BitmaskData> m_bitmasks;
std::set<std::string> m_commandQueues;
std::map<std::string, CommandData> m_commands;
std::map<std::string, ConstantData> m_constants;
std::map<std::string, DefineData> m_defines;
DefinesPartition m_definesPartition; // partition defined macros into mutually-exclusive sets of callees, callers, and values
std::map<std::string, EnumData> m_enums;
std::vector<ExtensionData> m_extensions;
std::map<std::string, ExternalTypeData> m_externalTypes;
std::vector<FeatureData> m_features;
std::map<std::string, FormatData> m_formats;
std::map<std::string, FuncPointerData> m_funcPointers;
std::map<std::string, HandleData> m_handles;
std::map<std::string, IncludeData> m_includes;
std::map<std::string, PlatformData> m_platforms;
std::set<std::string> m_RAIISpecialFunctions;
std::map<std::string, SpirVCapabilityData> m_spirVCapabilities;
std::map<std::string, StructData> m_structs;
std::vector<std::pair<std::string, NameLine>> m_structsAliases; // temporary storage for aliases, as they might be listed before the actual struct is listed
std::map<std::string, NameLine> m_syncAccesses;
std::map<std::string, NameLine> m_syncStages;

View File

@ -24,7 +24,7 @@ module;
#include <vulkan/${api}_shared.hpp>
export module ${api}_hpp;
export import std.compat;
export import std;
export namespace VULKAN_HPP_NAMESPACE
{

View File

@ -20,3 +20,10 @@
bool m_valid = true;
#endif
};
template <typename Type>
struct isDispatchLoader
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = false;
};

View File

@ -305,10 +305,11 @@ namespace VULKAN_HPP_NAMESPACE
#endif
#if defined( VULKAN_HPP_NO_DEFAULT_DISPATCHER )
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment )
#else
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT = VULKAN_HPP_DEFAULT_DISPATCHER
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment ) = assignment
#endif
#define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT VULKAN_HPP_DEFAULT_ASSIGNMENT( VULKAN_HPP_DEFAULT_DISPATCHER )
#if !defined( VULKAN_HPP_RAII_NAMESPACE )
# define VULKAN_HPP_RAII_NAMESPACE raii

View File

@ -5,7 +5,7 @@ public:
ObjectDestroy() = default;
ObjectDestroy( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
: m_owner( owner )
, m_allocationCallbacks( allocationCallbacks )

View File

@ -5,7 +5,7 @@
ObjectFree() = default;
ObjectFree( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
: m_owner( owner )
, m_allocationCallbacks( allocationCallbacks )

View File

@ -79,7 +79,7 @@ namespace VULKAN_HPP_NAMESPACE
template <typename DestructorType, typename Deleter>
struct SharedHeader
{
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT
: parent( std::move( parent ) )
, deleter( std::move( deleter ) )
{
@ -92,7 +92,7 @@ namespace VULKAN_HPP_NAMESPACE
template <typename Deleter>
struct SharedHeader<NoDestructor, Deleter>
{
SharedHeader( Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
SharedHeader( Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
Deleter deleter;
};
@ -277,7 +277,9 @@ namespace VULKAN_HPP_NAMESPACE
SharedHandle() = default;
template <typename T = HandleType, typename = typename std::enable_if<HasDestructor<T>::value && !HasPoolType<T>::value>::type>
explicit SharedHandle( HandleType handle, SharedHandle<DestructorTypeOf<HandleType>> parent, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
explicit SharedHandle( HandleType handle,
SharedHandle<DestructorTypeOf<HandleType>> parent,
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ) )
{
}
@ -294,7 +296,9 @@ namespace VULKAN_HPP_NAMESPACE
}
template <typename T = HandleType, typename = typename std::enable_if<!HasDestructor<T>::value>::type>
explicit SharedHandle( HandleType handle, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT : BaseType( handle, std::move( deleter ) )
explicit SharedHandle( HandleType handle,
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( deleter ) )
{
}
@ -313,13 +317,12 @@ namespace VULKAN_HPP_NAMESPACE
# pragma clang diagnostic ignored "-Wcast-function-type"
# endif
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectDestroyShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType =
typename std::conditional<HasDestructor<HandleType>::value,
void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const,
@ -327,10 +330,9 @@ namespace VULKAN_HPP_NAMESPACE
using SelectorType = typename std::conditional<HasDestructor<HandleType>::value, DestructorType, HandleType>::type;
template <typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectDestroyShared( Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
ObjectDestroyShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &SelectorType::destroy ) ) )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &SelectorType::destroy ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@ -352,24 +354,22 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectFreeShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectFreeShared( Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
ObjectFreeShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@ -383,23 +383,21 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectReleaseShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const Dispatcher & ) const;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectReleaseShared( const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::release ) ) )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::release ) ) )
, m_dispatch( &dispatch )
{
}
@ -412,11 +410,11 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
};
template <typename HandleType, typename PoolType>
template <typename HandleType, typename PoolType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class PoolFreeShared
{
public:
@ -424,17 +422,14 @@ namespace VULKAN_HPP_NAMESPACE
using PoolTypeExport = PoolType;
template <class Dispatcher>
using ReturnType = decltype( std::declval<DestructorType>().free( PoolType(), 0u, nullptr, Dispatcher() ) );
template <class Dispatcher>
using DestroyFunctionPointerType = ReturnType<Dispatcher> ( DestructorType::* )( PoolType, uint32_t, const HandleType *, const Dispatcher & ) const;
using DestroyFunctionPointerType = ReturnType( DestructorType::* )( PoolType, uint32_t, const HandleType *, const Dispatcher & ) const;
PoolFreeShared() = default;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
PoolFreeShared( SharedHandle<PoolType> pool, const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_pool( std::move( pool ) )
{
@ -448,9 +443,9 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
};
# if defined( __GNUC__ ) && !defined( __clang__ ) && !defined( __INTEL_COMPILER )
@ -472,7 +467,8 @@ namespace VULKAN_HPP_NAMESPACE
struct ImageHeader : SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>
{
ImageHeader( SharedHandle<DestructorTypeOf<Image>> parent,
typename SharedHandleTraits<Image>::deleter deleter = typename SharedHandleTraits<Image>::deleter(),
typename SharedHandleTraits<Image>::deleter deleter
VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<Image>::deleter() ),
SwapchainOwns swapchainOwned = SwapchainOwns::no ) VULKAN_HPP_NOEXCEPT
: SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>( std::move( parent ), std::move( deleter ) )
, swapchainOwned( swapchainOwned )
@ -494,8 +490,8 @@ namespace VULKAN_HPP_NAMESPACE
explicit SharedHandle( Image handle,
SharedHandle<DestructorTypeOf<Image>> parent,
SwapchainOwns swapchain_owned = SwapchainOwns::no,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
SwapchainOwns swapchain_owned VULKAN_HPP_DEFAULT_ASSIGNMENT( SwapchainOwns::no ),
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ), swapchain_owned )
{
}
@ -514,7 +510,8 @@ namespace VULKAN_HPP_NAMESPACE
{
SwapchainHeader( SharedHandle<SurfaceKHR> surface,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
typename SharedHandleTraits<SwapchainKHR>::deleter deleter = typename SharedHandleTraits<SwapchainKHR>::deleter() ) VULKAN_HPP_NOEXCEPT
typename SharedHandleTraits<SwapchainKHR>::deleter deleter
VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<SwapchainKHR>::deleter() ) ) VULKAN_HPP_NOEXCEPT
: surface( std::move( surface ) )
, parent( std::move( parent ) )
, deleter( std::move( deleter ) )
@ -539,7 +536,7 @@ namespace VULKAN_HPP_NAMESPACE
explicit SharedHandle( SwapchainKHR handle,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
SharedHandle<SurfaceKHR> surface,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( surface ), std::move( parent ), std::move( deleter ) )
{
}

View File

@ -1,3 +1,4 @@
#include <vulkan/${vulkan_h}>
#if !defined( VULKAN_HPP_CXX_MODULE )
// clang-format off
# include <vulkan/vulkan_hpp_macros.hpp>
@ -27,9 +28,8 @@
#else
# include <cassert>
# include <cstring>
import std.compat;
import std;
#endif
#include <vulkan/${vulkan_h}>
#if VULKAN_HPP_ENABLE_DYNAMIC_LOADER_TOOL == 1
# if defined( __unix__ ) || defined( __APPLE__ ) || defined( __QNX__ ) || defined( __Fuchsia__ )

View File

@ -41,6 +41,7 @@ add_subdirectory( FunctionCallsRAII )
add_subdirectory( Handles )
add_subdirectory( HandlesMoveExchange )
add_subdirectory( Hash )
add_subdirectory( NoDefaultDispatcher )
add_subdirectory( NoExceptions )
if( ( CMAKE_CXX_STANDARD GREATER_EQUAL 23 ) AND NOT ( ( CMAKE_CXX_COMPILER_ID STREQUAL "Clang" ) AND ( CMAKE_CXX_COMPILER_VERSION VERSION_LESS 15.0 ) ) )
# This test is for C++23 only... but clang++13 and clang++14 seem to have a problem with it

View File

@ -504,6 +504,66 @@ int main( int /*argc*/, char ** /*argv*/ )
queue.bindSparse( bindSparseInfo, fence );
}
// Fence commands
{
vk::Device device;
vk::FenceCreateInfo fenceCreateInfo;
vk::AllocationCallbacks allocationCallbacks;
vk::Fence fence;
vk::Result result = device.createFence( &fenceCreateInfo, &allocationCallbacks, &fence );
}
{
vk::Device device;
vk::FenceCreateInfo fenceCreateInfo;
vk::Fence fence = device.createFence( fenceCreateInfo );
}
{
vk::Device device;
vk::Fence fence;
vk::AllocationCallbacks allocationCallbacks;
device.destroyFence( fence, &allocationCallbacks );
}
{
vk::Device device;
vk::Fence fence;
device.destroyFence( fence );
}
{
vk::Device device;
uint32_t fenceCount = 1;
vk::Fence fence;
vk::Result result = device.resetFences( fenceCount, &fence );
}
{
vk::Device device;
vk::Fence fence;
device.resetFences( fence );
}
{
vk::Device device;
vk::Fence fence;
vk::Result result = device.getFenceStatus( fence );
}
{
vk::Device device;
uint32_t fenceCount = 1;
vk::Fence fence;
vk::Bool32 waitAll = vk::True;
uint64_t timeout = 1000000000;
vk::Result result = device.waitForFences( fenceCount, &fence, waitAll, timeout );
}
{
vk::Device device;
vk::Fence fence;
vk::Bool32 waitAll = vk::True;
uint64_t timeout = 1000000000;
vk::Result result = device.waitForFences( fence, waitAll, timeout );
}
#if 0
{
vk::PhysicalDevice physicalDevice;

View File

@ -106,6 +106,11 @@ int main( int /*argc*/, char ** /*argv*/ )
vk::DeviceCreateInfo deviceCreateInfo;
vk::raii::Device device = physicalDevice.createDevice( deviceCreateInfo );
}
{
vk::raii::PhysicalDevice physicalDevice = nullptr;
vk::DeviceCreateInfo deviceCreateInfo;
vk::raii::Device device( physicalDevice, deviceCreateInfo );
}
// Extension discovery commands
{
@ -136,6 +141,12 @@ int main( int /*argc*/, char ** /*argv*/ )
uint32_t queueIndex = 0;
vk::raii::Queue queue = device.getQueue( queueFamilyIndex, queueIndex );
}
{
vk::raii::Device device = nullptr;
uint32_t queueFamilyIndex = 0;
uint32_t queueIndex = 0;
vk::raii::Queue queue( device, queueFamilyIndex, queueIndex );
}
{
vk::raii::Queue queue = nullptr;
@ -160,6 +171,11 @@ int main( int /*argc*/, char ** /*argv*/ )
vk::MemoryAllocateInfo memoryAllocateInfo;
vk::raii::DeviceMemory deviceMemory = device.allocateMemory( memoryAllocateInfo );
}
{
vk::raii::Device device = nullptr;
vk::MemoryAllocateInfo memoryAllocateInfo;
vk::raii::DeviceMemory deviceMemory( device, memoryAllocateInfo );
}
{
vk::raii::DeviceMemory deviceMemory = nullptr;
@ -240,5 +256,36 @@ int main( int /*argc*/, char ** /*argv*/ )
queue.bindSparse( bindSparseInfo, fence );
}
// Fence commands
{
vk::raii::Device device = nullptr;
vk::FenceCreateInfo fenceCreateInfo;
vk::raii::Fence fence = device.createFence( fenceCreateInfo );
}
{
vk::raii::Device device = nullptr;
vk::FenceCreateInfo fenceCreateInfo;
vk::raii::Fence fence( device, fenceCreateInfo );
}
{
vk::raii::Device device = nullptr;
vk::Fence fence;
device.resetFences( fence );
}
{
vk::raii::Fence fence = nullptr;
vk::Result result = fence.getStatus();
}
{
vk::raii::Device device = nullptr;
vk::Fence fence;
vk::Bool32 waitAll = vk::True;
uint64_t timeout = 1000000000;
vk::Result result = device.waitForFences( fence, waitAll, timeout );
}
return 0;
}

View File

@ -0,0 +1,21 @@
# Copyright(c) 2018, NVIDIA CORPORATION. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
vulkan_hpp__setup_test( NAME NoDefaultDispatcher )
if( VULKAN_HPP_ENABLE_CPP20_MODULES )
# gcc versions <= 15.x fail to ignore -Winit-list-lifetime when importing vulkan_hpp
if ( NOT (CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS "16") )
vulkan_hpp__setup_test( NAME NoDefaultDispatcher CXX_MODULE )
endif()
endif()

View File

@ -0,0 +1,31 @@
// Copyright(c) 2018, NVIDIA CORPORATION. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// VulkanHpp Samples : NoDefaultDispatcher
// Compile test with VULKAN_HPP_NO_DEFAULT_DISPATCHER defined
#define VULKAN_HPP_NO_DEFAULT_DISPATCHER
#ifdef VULKAN_HPP_USE_CXX_MODULE
import vulkan_hpp;
#else
# include <vulkan/vulkan.hpp>
# include <vulkan/vulkan_raii.hpp>
# include <vulkan/vulkan_shared.hpp>
#endif
int main( int /*argc*/, char ** /*argv*/ )
{
return 0;
}

View File

@ -29,7 +29,7 @@ VULKAN_HPP_COMPILE_WARNING( VULKAN_HPP_CXX_MODULE_EXPERIMENTAL_WARNING )
#include <vulkan/vulkan_shared.hpp>
export module vulkan_hpp;
export import std.compat;
export import std;
export namespace VULKAN_HPP_NAMESPACE
{
@ -52,6 +52,7 @@ export namespace VULKAN_HPP_NAMESPACE
using VULKAN_HPP_NAMESPACE::detail::DispatchLoaderStatic;
using VULKAN_HPP_NAMESPACE::detail::getDispatchLoaderStatic;
#endif /*VK_NO_PROTOTYPES*/
using VULKAN_HPP_NAMESAPCE::detail::isDispatchLoader;
using VULKAN_HPP_NAMESPACE::detail::createResultValueType;
using VULKAN_HPP_NAMESPACE::detail::resultCheck;
} // namespace detail
@ -5737,6 +5738,7 @@ export namespace VULKAN_HPP_NAMESPACE
//======================
using VULKAN_HPP_RAII_NAMESPACE::Context;
using VULKAN_HPP_RAII_NAMESPACE::isVulkanRAIIHandleType;
namespace detail
{

View File

@ -8,6 +8,7 @@
#ifndef VULKAN_HPP
#define VULKAN_HPP
#include <vulkan/vulkan.h>
#if !defined( VULKAN_HPP_CXX_MODULE )
// clang-format off
# include <vulkan/vulkan_hpp_macros.hpp>
@ -37,9 +38,8 @@
#else
# include <cassert>
# include <cstring>
import std.compat;
import std;
#endif
#include <vulkan/vulkan.h>
#if VULKAN_HPP_ENABLE_DYNAMIC_LOADER_TOOL == 1
# if defined( __unix__ ) || defined( __APPLE__ ) || defined( __QNX__ ) || defined( __Fuchsia__ )
@ -150,7 +150,7 @@ namespace VULKAN_HPP_NAMESPACE
private:
VULKAN_HPP_CONSTEXPR_14 void copy( char const * data, size_t len ) VULKAN_HPP_NOEXCEPT
{
size_t n = (std::min)( N - 1, len );
size_t n = ( std::min )( N - 1, len );
for ( size_t i = 0; i < n; ++i )
{
( *this )[i] = data[i];
@ -1023,6 +1023,12 @@ namespace VULKAN_HPP_NAMESPACE
#endif
};
template <typename Type>
struct isDispatchLoader
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = false;
};
#if !defined( VK_NO_PROTOTYPES ) || ( defined( VULKAN_HPP_DISPATCH_LOADER_DYNAMIC ) && ( VULKAN_HPP_DISPATCH_LOADER_DYNAMIC == 0 ) )
class DispatchLoaderStatic : public DispatchLoaderBase
{
@ -6600,6 +6606,12 @@ namespace VULKAN_HPP_NAMESPACE
}
};
template <>
struct isDispatchLoader<DispatchLoaderStatic>
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = true;
};
inline DispatchLoaderStatic & getDispatchLoaderStatic()
{
static DispatchLoaderStatic dls;
@ -6631,9 +6643,9 @@ namespace VULKAN_HPP_NAMESPACE
public:
ObjectDestroy() = default;
ObjectDestroy( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
ObjectDestroy( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
: m_owner( owner )
, m_allocationCallbacks( allocationCallbacks )
, m_dispatch( &dispatch )
@ -6713,9 +6725,9 @@ namespace VULKAN_HPP_NAMESPACE
public:
ObjectFree() = default;
ObjectFree( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
ObjectFree( OwnerType owner,
Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
Dispatch const & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT ) VULKAN_HPP_NOEXCEPT
: m_owner( owner )
, m_allocationCallbacks( allocationCallbacks )
, m_dispatch( &dispatch )
@ -24151,6 +24163,13 @@ namespace VULKAN_HPP_NAMESPACE
init( instance, device, dl );
}
};
template <>
struct isDispatchLoader<DispatchLoaderDynamic>
{
static VULKAN_HPP_CONST_OR_CONSTEXPR bool value = true;
};
} // namespace detail
} // namespace VULKAN_HPP_NAMESPACE
#endif

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -315,10 +315,11 @@ namespace VULKAN_HPP_NAMESPACE
#endif
#if defined( VULKAN_HPP_NO_DEFAULT_DISPATCHER )
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment )
#else
# define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT = VULKAN_HPP_DEFAULT_DISPATCHER
# define VULKAN_HPP_DEFAULT_ASSIGNMENT( assignment ) = assignment
#endif
#define VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT VULKAN_HPP_DEFAULT_ASSIGNMENT( VULKAN_HPP_DEFAULT_DISPATCHER )
#if !defined( VULKAN_HPP_RAII_NAMESPACE )
# define VULKAN_HPP_RAII_NAMESPACE raii

View File

@ -3174,7 +3174,7 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkEnumerateInstanceExtensionProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkEnumerateInstanceExtensionProperties.html
VULKAN_HPP_NODISCARD typename ResultValueType<std::vector<ExtensionProperties>>::type
enumerateInstanceExtensionProperties( Optional<const std::string> layerName = nullptr ) const;
enumerateInstanceExtensionProperties( Optional<const std::string> layerName VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkEnumerateInstanceLayerProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkEnumerateInstanceLayerProperties.html
@ -3599,8 +3599,8 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetPhysicalDeviceImageFormatProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPhysicalDeviceImageFormatProperties.html
VULKAN_HPP_NODISCARD typename ResultValueType<ImageFormatProperties>::type
getImageFormatProperties( Format format, ImageType type, ImageTiling tiling, ImageUsageFlags usage, ImageCreateFlags flags = {} ) const;
VULKAN_HPP_NODISCARD typename ResultValueType<ImageFormatProperties>::type getImageFormatProperties(
Format format, ImageType type, ImageTiling tiling, ImageUsageFlags usage, ImageCreateFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkGetPhysicalDeviceProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPhysicalDeviceProperties.html
@ -3622,7 +3622,7 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkEnumerateDeviceExtensionProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkEnumerateDeviceExtensionProperties.html
VULKAN_HPP_NODISCARD typename ResultValueType<std::vector<ExtensionProperties>>::type
enumerateDeviceExtensionProperties( Optional<const std::string> layerName = nullptr ) const;
enumerateDeviceExtensionProperties( Optional<const std::string> layerName VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkEnumerateDeviceLayerProperties, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkEnumerateDeviceLayerProperties.html
@ -3736,12 +3736,12 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetPhysicalDeviceSurfaceFormatsKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPhysicalDeviceSurfaceFormatsKHR.html
VULKAN_HPP_NODISCARD typename ResultValueType<std::vector<SurfaceFormatKHR>>::type
getSurfaceFormatsKHR( VULKAN_HPP_NAMESPACE::SurfaceKHR surface = {} ) const;
getSurfaceFormatsKHR( VULKAN_HPP_NAMESPACE::SurfaceKHR surface VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkGetPhysicalDeviceSurfacePresentModesKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPhysicalDeviceSurfacePresentModesKHR.html
VULKAN_HPP_NODISCARD typename ResultValueType<std::vector<PresentModeKHR>>::type
getSurfacePresentModesKHR( VULKAN_HPP_NAMESPACE::SurfaceKHR surface = {} ) const;
getSurfacePresentModesKHR( VULKAN_HPP_NAMESPACE::SurfaceKHR surface VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_KHR_swapchain ===
@ -3829,12 +3829,12 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetPhysicalDeviceExternalImageFormatPropertiesNV, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPhysicalDeviceExternalImageFormatPropertiesNV.html
VULKAN_HPP_NODISCARD typename ResultValueType<ExternalImageFormatPropertiesNV>::type
getExternalImageFormatPropertiesNV( Format format,
ImageType type,
ImageTiling tiling,
ImageUsageFlags usage,
ImageCreateFlags flags = {},
ExternalMemoryHandleTypeFlagsNV externalHandleType = {} ) const;
getExternalImageFormatPropertiesNV( Format format,
ImageType type,
ImageTiling tiling,
ImageUsageFlags usage,
ImageCreateFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
ExternalMemoryHandleTypeFlagsNV externalHandleType VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_KHR_get_physical_device_properties2 ===
@ -4730,8 +4730,9 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkDestroyDescriptorUpdateTemplateKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkDestroyDescriptorUpdateTemplateKHR.html
void destroyDescriptorUpdateTemplateKHR( VULKAN_HPP_NAMESPACE::DescriptorUpdateTemplate descriptorUpdateTemplate = {},
Optional<const AllocationCallbacks> allocator = nullptr ) const VULKAN_HPP_NOEXCEPT;
void
destroyDescriptorUpdateTemplateKHR( VULKAN_HPP_NAMESPACE::DescriptorUpdateTemplate descriptorUpdateTemplate VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
Optional<const AllocationCallbacks> allocator VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_EXT_display_control ===
@ -4935,9 +4936,9 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetAccelerationStructureBuildSizesKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetAccelerationStructureBuildSizesKHR.html
VULKAN_HPP_NODISCARD AccelerationStructureBuildSizesInfoKHR
getAccelerationStructureBuildSizesKHR( AccelerationStructureBuildTypeKHR buildType,
const AccelerationStructureBuildGeometryInfoKHR & buildInfo,
ArrayProxy<const uint32_t> const & maxPrimitiveCounts = nullptr ) const;
getAccelerationStructureBuildSizesKHR( AccelerationStructureBuildTypeKHR buildType,
const AccelerationStructureBuildGeometryInfoKHR & buildInfo,
ArrayProxy<const uint32_t> const & maxPrimitiveCounts VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
//=== VK_KHR_ray_tracing_pipeline ===
@ -4967,8 +4968,8 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkDestroySamplerYcbcrConversionKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkDestroySamplerYcbcrConversionKHR.html
void destroySamplerYcbcrConversionKHR( VULKAN_HPP_NAMESPACE::SamplerYcbcrConversion ycbcrConversion = {},
Optional<const AllocationCallbacks> allocator = nullptr ) const VULKAN_HPP_NOEXCEPT;
void destroySamplerYcbcrConversionKHR( VULKAN_HPP_NAMESPACE::SamplerYcbcrConversion ycbcrConversion VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
Optional<const AllocationCallbacks> allocator VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_KHR_bind_memory2 ===
@ -5190,8 +5191,8 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkDestroyPrivateDataSlotEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkDestroyPrivateDataSlotEXT.html
void destroyPrivateDataSlotEXT( VULKAN_HPP_NAMESPACE::PrivateDataSlot privateDataSlot = {},
Optional<const AllocationCallbacks> allocator = nullptr ) const VULKAN_HPP_NOEXCEPT;
void destroyPrivateDataSlotEXT( VULKAN_HPP_NAMESPACE::PrivateDataSlot privateDataSlot VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
Optional<const AllocationCallbacks> allocator VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkSetPrivateDataEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkSetPrivateDataEXT.html
typename ResultValueType<void>::type
@ -5546,7 +5547,7 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetPipelineKeyKHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPipelineKeyKHR.html
VULKAN_HPP_NODISCARD typename ResultValueType<PipelineBinaryKeyKHR>::type
getPipelineKeyKHR( Optional<const PipelineCreateInfoKHR> pipelineCreateInfo = nullptr ) const;
getPipelineKeyKHR( Optional<const PipelineCreateInfoKHR> pipelineCreateInfo VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkGetPipelineBinaryDataKHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetPipelineBinaryDataKHR.html
VULKAN_HPP_NODISCARD typename ResultValueType<std::pair<PipelineBinaryKeyKHR, std::vector<uint8_t>>>::type
@ -5554,8 +5555,9 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkReleaseCapturedPipelineDataKHR, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkReleaseCapturedPipelineDataKHR.html
typename ResultValueType<void>::type releaseCapturedPipelineDataKHR( const ReleaseCapturedPipelineDataInfoKHR & info,
Optional<const AllocationCallbacks> allocator = nullptr ) const;
typename ResultValueType<void>::type
releaseCapturedPipelineDataKHR( const ReleaseCapturedPipelineDataInfoKHR & info,
Optional<const AllocationCallbacks> allocator VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
//=== VK_QCOM_tile_properties ===
@ -6547,17 +6549,17 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_VERSION_1_0 ===
// wrapper function for command vkResetCommandPool, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkResetCommandPool.html
typename ResultValueType<void>::type reset( CommandPoolResetFlags flags = {} ) const;
typename ResultValueType<void>::type reset( CommandPoolResetFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_VERSION_1_1 ===
// wrapper function for command vkTrimCommandPool, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkTrimCommandPool.html
void trim( CommandPoolTrimFlags flags = {} ) const VULKAN_HPP_NOEXCEPT;
void trim( CommandPoolTrimFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_KHR_maintenance1 ===
// wrapper function for command vkTrimCommandPoolKHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkTrimCommandPoolKHR.html
void trimKHR( CommandPoolTrimFlags flags = {} ) const VULKAN_HPP_NOEXCEPT;
void trimKHR( CommandPoolTrimFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
private:
VULKAN_HPP_NAMESPACE::Device m_device = {};
@ -6684,7 +6686,7 @@ namespace VULKAN_HPP_NAMESPACE
typename ResultValueType<void>::type end() const;
// wrapper function for command vkResetCommandBuffer, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkResetCommandBuffer.html
typename ResultValueType<void>::type reset( CommandBufferResetFlags flags = {} ) const;
typename ResultValueType<void>::type reset( CommandBufferResetFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkCmdCopyBuffer, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdCopyBuffer.html
void copyBuffer( VULKAN_HPP_NAMESPACE::Buffer srcBuffer,
@ -6726,7 +6728,9 @@ namespace VULKAN_HPP_NAMESPACE
ArrayProxy<const ImageMemoryBarrier> const & imageMemoryBarriers ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdBeginQuery, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdBeginQuery.html
void beginQuery( VULKAN_HPP_NAMESPACE::QueryPool queryPool, uint32_t query, QueryControlFlags flags = {} ) const VULKAN_HPP_NOEXCEPT;
void beginQuery( VULKAN_HPP_NAMESPACE::QueryPool queryPool,
uint32_t query,
QueryControlFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdEndQuery, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdEndQuery.html
void endQuery( VULKAN_HPP_NAMESPACE::QueryPool queryPool, uint32_t query ) const VULKAN_HPP_NOEXCEPT;
@ -6744,7 +6748,7 @@ namespace VULKAN_HPP_NAMESPACE
VULKAN_HPP_NAMESPACE::Buffer dstBuffer,
DeviceSize dstOffset,
DeviceSize stride,
QueryResultFlags flags = {} ) const VULKAN_HPP_NOEXCEPT;
QueryResultFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdExecuteCommands, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdExecuteCommands.html
void executeCommands( ArrayProxy<const VULKAN_HPP_NAMESPACE::CommandBuffer> const & commandBuffers ) const VULKAN_HPP_NOEXCEPT;
@ -6772,10 +6776,10 @@ namespace VULKAN_HPP_NAMESPACE
void dispatchIndirect( VULKAN_HPP_NAMESPACE::Buffer buffer, DeviceSize offset ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdSetEvent, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetEvent.html
void setEvent( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags stageMask = {} ) const VULKAN_HPP_NOEXCEPT;
void setEvent( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags stageMask VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdResetEvent, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdResetEvent.html
void resetEvent( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags stageMask = {} ) const VULKAN_HPP_NOEXCEPT;
void resetEvent( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags stageMask VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdWaitEvents, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdWaitEvents.html
void waitEvents( ArrayProxy<const VULKAN_HPP_NAMESPACE::Event> const & events,
@ -6935,7 +6939,7 @@ namespace VULKAN_HPP_NAMESPACE
void setEvent2( VULKAN_HPP_NAMESPACE::Event event, const DependencyInfo & dependencyInfo ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdResetEvent2, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdResetEvent2.html
void resetEvent2( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags2 stageMask = {} ) const VULKAN_HPP_NOEXCEPT;
void resetEvent2( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags2 stageMask VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdWaitEvents2, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdWaitEvents2.html
void waitEvents2( ArrayProxy<const VULKAN_HPP_NAMESPACE::Event> const & events, ArrayProxy<const DependencyInfo> const & dependencyInfos ) const;
@ -6953,7 +6957,7 @@ namespace VULKAN_HPP_NAMESPACE
void endRendering() const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdSetCullMode, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetCullMode.html
void setCullMode( CullModeFlags cullMode = {} ) const VULKAN_HPP_NOEXCEPT;
void setCullMode( CullModeFlags cullMode VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdSetFrontFace, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetFrontFace.html
void setFrontFace( FrontFace frontFace ) const VULKAN_HPP_NOEXCEPT;
@ -6971,8 +6975,8 @@ namespace VULKAN_HPP_NAMESPACE
void bindVertexBuffers2( uint32_t firstBinding,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & buffers,
ArrayProxy<const DeviceSize> const & offsets,
ArrayProxy<const DeviceSize> const & sizes = nullptr,
ArrayProxy<const DeviceSize> const & strides = nullptr ) const;
ArrayProxy<const DeviceSize> const & sizes VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
ArrayProxy<const DeviceSize> const & strides VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdSetDepthTestEnable, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetDepthTestEnable.html
void setDepthTestEnable( Bool32 depthTestEnable ) const VULKAN_HPP_NOEXCEPT;
@ -7081,19 +7085,19 @@ namespace VULKAN_HPP_NAMESPACE
void bindTransformFeedbackBuffersEXT( uint32_t firstBinding,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & buffers,
ArrayProxy<const DeviceSize> const & offsets,
ArrayProxy<const DeviceSize> const & sizes = nullptr ) const;
ArrayProxy<const DeviceSize> const & sizes VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdBeginTransformFeedbackEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdBeginTransformFeedbackEXT.html
void beginTransformFeedbackEXT( uint32_t firstCounterBuffer,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & counterBuffers,
ArrayProxy<const DeviceSize> const & counterBufferOffsets = nullptr ) const;
void beginTransformFeedbackEXT( uint32_t firstCounterBuffer,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & counterBuffers,
ArrayProxy<const DeviceSize> const & counterBufferOffsets VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdEndTransformFeedbackEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdEndTransformFeedbackEXT.html
void endTransformFeedbackEXT( uint32_t firstCounterBuffer,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & counterBuffers,
ArrayProxy<const DeviceSize> const & counterBufferOffsets = nullptr ) const;
void endTransformFeedbackEXT( uint32_t firstCounterBuffer,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & counterBuffers,
ArrayProxy<const DeviceSize> const & counterBufferOffsets VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdBeginQueryIndexedEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdBeginQueryIndexedEXT.html
void beginQueryIndexedEXT( VULKAN_HPP_NAMESPACE::QueryPool queryPool, uint32_t query, QueryControlFlags flags, uint32_t index ) const VULKAN_HPP_NOEXCEPT;
@ -7463,7 +7467,7 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_EXT_extended_dynamic_state ===
// wrapper function for command vkCmdSetCullModeEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetCullModeEXT.html
void setCullModeEXT( CullModeFlags cullMode = {} ) const VULKAN_HPP_NOEXCEPT;
void setCullModeEXT( CullModeFlags cullMode VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdSetFrontFaceEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetFrontFaceEXT.html
void setFrontFaceEXT( FrontFace frontFace ) const VULKAN_HPP_NOEXCEPT;
@ -7484,8 +7488,8 @@ namespace VULKAN_HPP_NAMESPACE
void bindVertexBuffers2EXT( uint32_t firstBinding,
ArrayProxy<const VULKAN_HPP_NAMESPACE::Buffer> const & buffers,
ArrayProxy<const DeviceSize> const & offsets,
ArrayProxy<const DeviceSize> const & sizes = nullptr,
ArrayProxy<const DeviceSize> const & strides = nullptr ) const;
ArrayProxy<const DeviceSize> const & sizes VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
ArrayProxy<const DeviceSize> const & strides VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdSetDepthTestEnableEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetDepthTestEnableEXT.html
void setDepthTestEnableEXT( Bool32 depthTestEnable ) const VULKAN_HPP_NOEXCEPT;
@ -7561,7 +7565,7 @@ namespace VULKAN_HPP_NAMESPACE
void setEvent2KHR( VULKAN_HPP_NAMESPACE::Event event, const DependencyInfo & dependencyInfo ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdResetEvent2KHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdResetEvent2KHR.html
void resetEvent2KHR( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags2 stageMask = {} ) const VULKAN_HPP_NOEXCEPT;
void resetEvent2KHR( VULKAN_HPP_NAMESPACE::Event event, PipelineStageFlags2 stageMask VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdWaitEvents2KHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdWaitEvents2KHR.html
void waitEvents2KHR( ArrayProxy<const VULKAN_HPP_NAMESPACE::Event> const & events, ArrayProxy<const DependencyInfo> const & dependencyInfos ) const;
@ -7694,7 +7698,7 @@ namespace VULKAN_HPP_NAMESPACE
void drawMultiIndexedEXT( StridedArrayProxy<const MultiDrawIndexedInfoEXT> const & indexInfo,
uint32_t instanceCount,
uint32_t firstInstance,
Optional<const int32_t> vertexOffset = nullptr ) const VULKAN_HPP_NOEXCEPT;
Optional<const int32_t> vertexOffset VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_EXT_opacity_micromap ===
@ -7772,7 +7776,7 @@ namespace VULKAN_HPP_NAMESPACE
void setRasterizationSamplesEXT( SampleCountFlagBits rasterizationSamples ) const VULKAN_HPP_NOEXCEPT;
// wrapper function for command vkCmdSetSampleMaskEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetSampleMaskEXT.html
void setSampleMaskEXT( SampleCountFlagBits samples, ArrayProxy<const SampleMask> const & sampleMask = nullptr ) const;
void setSampleMaskEXT( SampleCountFlagBits samples, ArrayProxy<const SampleMask> const & sampleMask VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const;
// wrapper function for command vkCmdSetAlphaToCoverageEnableEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetAlphaToCoverageEnableEXT.html
@ -7899,7 +7903,8 @@ namespace VULKAN_HPP_NAMESPACE
void bindShadersEXT( ArrayProxy<const ShaderStageFlagBits> const & stages, ArrayProxy<const VULKAN_HPP_NAMESPACE::ShaderEXT> const & shaders ) const;
// wrapper function for command vkCmdSetDepthClampRangeEXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetDepthClampRangeEXT.html
void setDepthClampRangeEXT( DepthClampModeEXT depthClampMode, Optional<const DepthClampRangeEXT> depthClampRange = nullptr ) const VULKAN_HPP_NOEXCEPT;
void setDepthClampRangeEXT( DepthClampModeEXT depthClampMode,
Optional<const DepthClampRangeEXT> depthClampRange VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_NV_cooperative_vector ===
@ -7910,14 +7915,14 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_ARM_data_graph ===
// wrapper function for command vkCmdDispatchDataGraphARM, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdDispatchDataGraphARM.html
void dispatchDataGraphARM( VULKAN_HPP_NAMESPACE::DataGraphPipelineSessionARM session,
Optional<const DataGraphPipelineDispatchInfoARM> info = nullptr ) const VULKAN_HPP_NOEXCEPT;
void dispatchDataGraphARM( VULKAN_HPP_NAMESPACE::DataGraphPipelineSessionARM session,
Optional<const DataGraphPipelineDispatchInfoARM> info VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_EXT_attachment_feedback_loop_dynamic_state ===
// wrapper function for command vkCmdSetAttachmentFeedbackLoopEnableEXT, see
// https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdSetAttachmentFeedbackLoopEnableEXT.html
void setAttachmentFeedbackLoopEnableEXT( ImageAspectFlags aspectMask = {} ) const VULKAN_HPP_NOEXCEPT;
void setAttachmentFeedbackLoopEnableEXT( ImageAspectFlags aspectMask VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_KHR_line_rasterization ===
@ -7952,7 +7957,7 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_QCOM_tile_memory_heap ===
// wrapper function for command vkCmdBindTileMemoryQCOM, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdBindTileMemoryQCOM.html
void bindTileMemoryQCOM( Optional<const TileMemoryBindInfoQCOM> tileMemoryBindInfo = nullptr ) const VULKAN_HPP_NOEXCEPT;
void bindTileMemoryQCOM( Optional<const TileMemoryBindInfoQCOM> tileMemoryBindInfo VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_KHR_copy_memory_indirect ===
@ -8002,12 +8007,12 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_EXT_fragment_density_map_offset ===
// wrapper function for command vkCmdEndRendering2EXT, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdEndRendering2EXT.html
void endRendering2EXT( Optional<const RenderingEndInfoKHR> renderingEndInfo = nullptr ) const VULKAN_HPP_NOEXCEPT;
void endRendering2EXT( Optional<const RenderingEndInfoKHR> renderingEndInfo VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
//=== VK_KHR_maintenance10 ===
// wrapper function for command vkCmdEndRendering2KHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkCmdEndRendering2KHR.html
void endRendering2KHR( Optional<const RenderingEndInfoKHR> renderingEndInfo = nullptr ) const VULKAN_HPP_NOEXCEPT;
void endRendering2KHR( Optional<const RenderingEndInfoKHR> renderingEndInfo VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ) ) const VULKAN_HPP_NOEXCEPT;
private:
VULKAN_HPP_NAMESPACE::Device m_device = {};
@ -9208,7 +9213,7 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_VERSION_1_0 ===
// wrapper function for command vkResetDescriptorPool, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkResetDescriptorPool.html
typename ResultValueType<void>::type reset( DescriptorPoolResetFlags flags = {} ) const;
typename ResultValueType<void>::type reset( DescriptorPoolResetFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
private:
VULKAN_HPP_NAMESPACE::Device m_device = {};
@ -9770,7 +9775,8 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_VERSION_1_0 ===
// wrapper function for command vkMapMemory, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkMapMemory.html
VULKAN_HPP_NODISCARD typename ResultValueType<void *>::type mapMemory( DeviceSize offset, DeviceSize size, MemoryMapFlags flags = {} ) const;
VULKAN_HPP_NODISCARD typename ResultValueType<void *>::type
mapMemory( DeviceSize offset, DeviceSize size, MemoryMapFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkUnmapMemory, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkUnmapMemory.html
void unmapMemory() const VULKAN_HPP_NOEXCEPT;
@ -10829,8 +10835,9 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_OHOS_native_buffer ===
// wrapper function for command vkAcquireImageOHOS, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkAcquireImageOHOS.html
typename ResultValueType<void>::type
acquireOHOS( int32_t nativeFenceFd, VULKAN_HPP_NAMESPACE::Semaphore semaphore = {}, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
typename ResultValueType<void>::type acquireOHOS( int32_t nativeFenceFd,
VULKAN_HPP_NAMESPACE::Semaphore semaphore VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
# endif /*VK_USE_PLATFORM_OHOS*/
protected:
@ -12775,12 +12782,13 @@ namespace VULKAN_HPP_NAMESPACE
// wrapper function for command vkGetQueryPoolResults, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetQueryPoolResults.html
template <typename DataType>
VULKAN_HPP_NODISCARD ResultValue<std::vector<DataType>>
getResults( uint32_t firstQuery, uint32_t queryCount, size_t dataSize, DeviceSize stride, QueryResultFlags flags = {} ) const;
VULKAN_HPP_NODISCARD ResultValue<std::vector<DataType>> getResults(
uint32_t firstQuery, uint32_t queryCount, size_t dataSize, DeviceSize stride, QueryResultFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkGetQueryPoolResults, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkGetQueryPoolResults.html
template <typename DataType>
VULKAN_HPP_NODISCARD ResultValue<DataType> getResult( uint32_t firstQuery, uint32_t queryCount, DeviceSize stride, QueryResultFlags flags = {} ) const;
VULKAN_HPP_NODISCARD ResultValue<DataType>
getResult( uint32_t firstQuery, uint32_t queryCount, DeviceSize stride, QueryResultFlags flags VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_VERSION_1_2 ===
@ -12908,18 +12916,21 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_VERSION_1_0 ===
// wrapper function for command vkQueueSubmit, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkQueueSubmit.html
typename ResultValueType<void>::type submit( ArrayProxy<const SubmitInfo> const & submits, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
typename ResultValueType<void>::type submit( ArrayProxy<const SubmitInfo> const & submits,
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
// wrapper function for command vkQueueWaitIdle, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkQueueWaitIdle.html
typename ResultValueType<void>::type waitIdle() const;
// wrapper function for command vkQueueBindSparse, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkQueueBindSparse.html
typename ResultValueType<void>::type bindSparse( ArrayProxy<const BindSparseInfo> const & bindInfo, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
typename ResultValueType<void>::type bindSparse( ArrayProxy<const BindSparseInfo> const & bindInfo,
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_VERSION_1_3 ===
// wrapper function for command vkQueueSubmit2, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkQueueSubmit2.html
typename ResultValueType<void>::type submit2( ArrayProxy<const SubmitInfo2> const & submits, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
typename ResultValueType<void>::type submit2( ArrayProxy<const SubmitInfo2> const & submits,
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_KHR_swapchain ===
@ -12958,7 +12969,8 @@ namespace VULKAN_HPP_NAMESPACE
//=== VK_KHR_synchronization2 ===
// wrapper function for command vkQueueSubmit2KHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkQueueSubmit2KHR.html
typename ResultValueType<void>::type submit2KHR( ArrayProxy<const SubmitInfo2> const & submits, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
typename ResultValueType<void>::type submit2KHR( ArrayProxy<const SubmitInfo2> const & submits,
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_NV_low_latency2 ===
@ -14196,8 +14208,9 @@ namespace VULKAN_HPP_NAMESPACE
VULKAN_HPP_NODISCARD typename ResultValueType<std::vector<VULKAN_HPP_NAMESPACE::Image>>::type getImages() const;
// wrapper function for command vkAcquireNextImageKHR, see https://registry.khronos.org/vulkan/specs/latest/man/html/vkAcquireNextImageKHR.html
VULKAN_HPP_NODISCARD ResultValue<uint32_t>
acquireNextImage( uint64_t timeout, VULKAN_HPP_NAMESPACE::Semaphore semaphore = {}, VULKAN_HPP_NAMESPACE::Fence fence = {} ) const;
VULKAN_HPP_NODISCARD ResultValue<uint32_t> acquireNextImage( uint64_t timeout,
VULKAN_HPP_NAMESPACE::Semaphore semaphore VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ),
VULKAN_HPP_NAMESPACE::Fence fence VULKAN_HPP_DEFAULT_ASSIGNMENT( {} ) ) const;
//=== VK_EXT_display_control ===

View File

@ -84,7 +84,7 @@ namespace VULKAN_HPP_NAMESPACE
template <typename DestructorType, typename Deleter>
struct SharedHeader
{
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT
SharedHeader( SharedHandle<DestructorType> parent, Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT
: parent( std::move( parent ) )
, deleter( std::move( deleter ) )
{
@ -97,7 +97,7 @@ namespace VULKAN_HPP_NAMESPACE
template <typename Deleter>
struct SharedHeader<NoDestructor, Deleter>
{
SharedHeader( Deleter deleter = Deleter() ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
SharedHeader( Deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( Deleter() ) ) VULKAN_HPP_NOEXCEPT : deleter( std::move( deleter ) ) {}
Deleter deleter;
};
@ -282,7 +282,9 @@ namespace VULKAN_HPP_NAMESPACE
SharedHandle() = default;
template <typename T = HandleType, typename = typename std::enable_if<HasDestructor<T>::value && !HasPoolType<T>::value>::type>
explicit SharedHandle( HandleType handle, SharedHandle<DestructorTypeOf<HandleType>> parent, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
explicit SharedHandle( HandleType handle,
SharedHandle<DestructorTypeOf<HandleType>> parent,
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ) )
{
}
@ -299,7 +301,8 @@ namespace VULKAN_HPP_NAMESPACE
}
template <typename T = HandleType, typename = typename std::enable_if<!HasDestructor<T>::value>::type>
explicit SharedHandle( HandleType handle, DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT : BaseType( handle, std::move( deleter ) )
explicit SharedHandle( HandleType handle, DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( deleter ) )
{
}
@ -318,13 +321,12 @@ namespace VULKAN_HPP_NAMESPACE
# pragma clang diagnostic ignored "-Wcast-function-type"
# endif
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectDestroyShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType =
typename std::conditional<HasDestructor<HandleType>::value,
void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const,
@ -332,10 +334,9 @@ namespace VULKAN_HPP_NAMESPACE
using SelectorType = typename std::conditional<HasDestructor<HandleType>::value, DestructorType, HandleType>::type;
template <typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectDestroyShared( Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &SelectorType::destroy ) ) )
ObjectDestroyShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &SelectorType::destroy ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@ -357,24 +358,22 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectFreeShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const AllocationCallbacks *, const Dispatcher & ) const;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectFreeShared( Optional<const AllocationCallbacks> allocationCallbacks = nullptr,
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
ObjectFreeShared( Optional<const AllocationCallbacks> allocationCallbacks VULKAN_HPP_DEFAULT_ASSIGNMENT( nullptr ),
const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_allocationCallbacks( allocationCallbacks )
{
@ -388,24 +387,21 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
Optional<const AllocationCallbacks> m_allocationCallbacks = nullptr;
};
template <typename HandleType>
template <typename HandleType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class ObjectReleaseShared
{
public:
using DestructorType = typename SharedHandleTraits<HandleType>::DestructorType;
template <class Dispatcher>
using DestroyFunctionPointerType = void ( DestructorType::* )( HandleType, const Dispatcher & ) const;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
ObjectReleaseShared( const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::release ) ) )
, m_dispatch( &dispatch )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::release ) ) ), m_dispatch( &dispatch )
{
}
@ -417,11 +413,11 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
};
template <typename HandleType, typename PoolType>
template <typename HandleType, typename PoolType, typename Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
class PoolFreeShared
{
public:
@ -429,17 +425,14 @@ namespace VULKAN_HPP_NAMESPACE
using PoolTypeExport = PoolType;
template <class Dispatcher>
using ReturnType = decltype( std::declval<DestructorType>().free( PoolType(), 0u, nullptr, Dispatcher() ) );
template <class Dispatcher>
using DestroyFunctionPointerType = ReturnType<Dispatcher> ( DestructorType::* )( PoolType, uint32_t, const HandleType *, const Dispatcher & ) const;
using DestroyFunctionPointerType = ReturnType ( DestructorType::* )( PoolType, uint32_t, const HandleType *, const Dispatcher & ) const;
PoolFreeShared() = default;
template <class Dispatcher = VULKAN_HPP_DEFAULT_DISPATCHER_TYPE>
PoolFreeShared( SharedHandle<PoolType> pool, const Dispatcher & dispatch VULKAN_HPP_DEFAULT_DISPATCHER_ASSIGNMENT )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType<Dispatcher>>( &DestructorType::free ) ) )
: m_destroy( reinterpret_cast<decltype( m_destroy )>( static_cast<DestroyFunctionPointerType>( &DestructorType::free ) ) )
, m_dispatch( &dispatch )
, m_pool( std::move( pool ) )
{
@ -453,9 +446,9 @@ namespace VULKAN_HPP_NAMESPACE
}
private:
DestroyFunctionPointerType<detail::DispatchLoaderBase> m_destroy = nullptr;
const detail::DispatchLoaderBase * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
DestroyFunctionPointerType m_destroy = nullptr;
const Dispatcher * m_dispatch = nullptr;
SharedHandle<PoolType> m_pool{};
};
# if defined( __GNUC__ ) && !defined( __clang__ ) && !defined( __INTEL_COMPILER )
@ -1051,9 +1044,9 @@ namespace VULKAN_HPP_NAMESPACE
struct ImageHeader : SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>
{
ImageHeader( SharedHandle<DestructorTypeOf<Image>> parent,
typename SharedHandleTraits<Image>::deleter deleter = typename SharedHandleTraits<Image>::deleter(),
SwapchainOwns swapchainOwned = SwapchainOwns::no ) VULKAN_HPP_NOEXCEPT
ImageHeader( SharedHandle<DestructorTypeOf<Image>> parent,
typename SharedHandleTraits<Image>::deleter deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<Image>::deleter() ),
SwapchainOwns swapchainOwned = SwapchainOwns::no ) VULKAN_HPP_NOEXCEPT
: SharedHeader<DestructorTypeOf<Image>, typename SharedHandleTraits<Image>::deleter>( std::move( parent ), std::move( deleter ) )
, swapchainOwned( swapchainOwned )
{
@ -1074,8 +1067,8 @@ namespace VULKAN_HPP_NAMESPACE
explicit SharedHandle( Image handle,
SharedHandle<DestructorTypeOf<Image>> parent,
SwapchainOwns swapchain_owned = SwapchainOwns::no,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
SwapchainOwns swapchain_owned VULKAN_HPP_DEFAULT_ASSIGNMENT( SwapchainOwns::no ),
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( parent ), std::move( deleter ), swapchain_owned )
{
}
@ -1092,9 +1085,10 @@ namespace VULKAN_HPP_NAMESPACE
struct SwapchainHeader
{
SwapchainHeader( SharedHandle<SurfaceKHR> surface,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
typename SharedHandleTraits<SwapchainKHR>::deleter deleter = typename SharedHandleTraits<SwapchainKHR>::deleter() ) VULKAN_HPP_NOEXCEPT
SwapchainHeader( SharedHandle<SurfaceKHR> surface,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
typename SharedHandleTraits<SwapchainKHR>::deleter deleter
VULKAN_HPP_DEFAULT_ASSIGNMENT( typename SharedHandleTraits<SwapchainKHR>::deleter() ) ) VULKAN_HPP_NOEXCEPT
: surface( std::move( surface ) )
, parent( std::move( parent ) )
, deleter( std::move( deleter ) )
@ -1119,7 +1113,7 @@ namespace VULKAN_HPP_NAMESPACE
explicit SharedHandle( SwapchainKHR handle,
SharedHandle<DestructorTypeOf<SwapchainKHR>> parent,
SharedHandle<SurfaceKHR> surface,
DeleterType deleter = DeleterType() ) VULKAN_HPP_NOEXCEPT
DeleterType deleter VULKAN_HPP_DEFAULT_ASSIGNMENT( DeleterType() ) ) VULKAN_HPP_NOEXCEPT
: BaseType( handle, std::move( surface ), std::move( parent ), std::move( deleter ) )
{
}