From 5c571c1b9acef3baf306e11d20993a0abf12010b Mon Sep 17 00:00:00 2001 From: asuessenbach Date: Wed, 25 May 2022 20:21:21 +0200 Subject: [PATCH] Combine two types of commands into one generation function --- VulkanHppGenerator.cpp | 107 ++------ VulkanHppGenerator.hpp | 9 +- vulkan/vulkan_enums.hpp | 52 ++-- vulkan/vulkan_raii.hpp | 565 +++++++++++++++----------------------- vulkan/vulkan_structs.hpp | 18 +- 5 files changed, 293 insertions(+), 458 deletions(-) diff --git a/VulkanHppGenerator.cpp b/VulkanHppGenerator.cpp index c3c7b2e..d2a2456 100644 --- a/VulkanHppGenerator.cpp +++ b/VulkanHppGenerator.cpp @@ -3436,7 +3436,7 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const & generateAllocatorTemplates( returnParams, dataTypes, vectorParams, definition, singular, unique, chained ); std::string typenameCheck = generateTypenameCheck( returnParams, vectorParams, definition, dataTypes, singular, withAllocator, unique, chained ); std::string nodiscard = generateNoDiscard( !returnParams.empty(), 1 < commandData.successCodes.size(), 1 < commandData.errorCodes.size() ); - std::string returnType = generateReturnType( commandData, returnParams, unique, chained, dataType ); + std::string returnType = generateReturnType( commandData, returnParams, unique, chained, false, dataType ); std::string className = initialSkipCount ? stripPrefix( commandData.params[initialSkipCount - 1].type.type, "Vk" ) : ""; std::string classSeparator = commandData.handle.empty() ? "" : "::"; std::string commandName = generateCommandName( name, commandData.params, initialSkipCount, m_tags, singular, unique ); @@ -3466,8 +3466,16 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const & std::string callSequence = generateCallSequence( name, commandData, returnParams, vectorParams, initialSkipCount, singularParams, templatedParams, chained, false ); std::string resultCheck = generateResultCheck( commandData, className, classSeparator, commandName, enumerating ); - std::string returnStatement = generateReturnStatement( - name, commandData, returnVariable, returnType, dataType, initialSkipCount, returnParams.empty() ? INVALID_INDEX : returnParams[0], unique, enumerating ); + std::string returnStatement = generateReturnStatement( name, + commandData, + returnVariable, + returnType, + dataType, + initialSkipCount, + returnParams.empty() ? INVALID_INDEX : returnParams[0], + unique, + enumerating, + false ); std::string const functionTemplate = R"( template <${argumentTemplates}${chainTemplates}${allocatorTemplates}typename Dispatch${uniqueHandleAllocatorTemplates}${typenameCheck}> @@ -6126,10 +6134,11 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandEnhanced( std::mapsecond.returnType != "VkResult" ) && ( commandIt->second.returnType != "void" ) ), 1 < commandIt->second.successCodes.size(), - 1 < commandIt->second.errorCodes.size() ); - std::pair>> vectorSizeCheck = needsVectorSizeCheck( commandIt->second.params, vectorParams, returnParams, {} ); - std::string noexceptString = vectorSizeCheck.first ? "" : "VULKAN_HPP_NOEXCEPT"; - std::string returnType = generateReturnType( commandIt->second, returnParams, false, false, dataType ); + false ); + std::pair>> vectorSizeCheck = + needsVectorSizeCheck( commandIt->second.params, vectorParams, returnParams, singularParams ); + std::string noexceptString = ( vectorSizeCheck.first || !commandIt->second.errorCodes.empty() ) ? "" : " VULKAN_HPP_NOEXCEPT"; + std::string returnType = generateReturnType( commandIt->second, returnParams, false, false, true, dataType ); if ( definition ) { @@ -6142,15 +6151,18 @@ ${functionPointerCheck} ${vectorSizeCheck} ${dataDeclarations} ${callSequence} + ${resultCheck} ${returnStatement} } )"; std::string callSequence = generateCallSequence( commandIt->first, commandIt->second, returnParams, vectorParams, initialSkipCount, singularParams, templatedParams, false, true ); + std::string className = stripPrefix( commandIt->second.params[initialSkipCount - 1].type.type, "Vk" ); std::string returnVariable = generateReturnVariable( commandIt->second, returnParams, vectorParams, false, false ); std::string dataDeclarations = generateDataDeclarations( commandIt->second, returnParams, vectorParams, templatedParams, false, false, false, false, dataTypes, dataType, returnType, returnVariable ); + std::string resultCheck = generateResultCheck( commandIt->second, className, "::", commandName, enumerating ); std::string returnStatement = generateReturnStatement( commandIt->first, commandIt->second, returnVariable, @@ -6159,7 +6171,8 @@ ${vectorSizeCheck} initialSkipCount, returnParams.empty() ? INVALID_INDEX : returnParams[0], false, - enumerating ); + enumerating, + true ); std::string vectorSizeCheckString = vectorSizeCheck.first ? generateRAIIHandleVectorSizeCheck( commandIt->first, commandIt->second, initialSkipCount, vectorSizeCheck.second, skippedParams ) : ""; @@ -6168,12 +6181,13 @@ ${vectorSizeCheck} { { "argumentList", argumentList }, { "argumentTemplates", argumentTemplates }, { "callSequence", callSequence }, - { "className", stripPrefix( commandIt->second.params[initialSkipCount - 1].type.type, "Vk" ) }, + { "className", className }, { "commandName", commandName }, { "dataDeclarations", dataDeclarations }, { "functionPointerCheck", generateFunctionPointerCheck( commandIt->first, commandIt->second.referencedIn ) }, { "nodiscard", nodiscard }, { "noexcept", noexceptString }, + { "resultCheck", resultCheck }, { "returnStatement", returnStatement }, { "returnType", returnType }, { "vectorSizeCheck", vectorSizeCheckString } } ); @@ -7196,8 +7210,7 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandResultSingleSuccessWith switch ( returnParams.size() ) { case 0: - return generateRAIIHandleCommandResultSingleSuccessWithErrors0Return( - commandIt, initialSkipCount, determineVectorParams( commandIt->second.params ), definition ); + return generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, returnParams, determineVectorParams( commandIt->second.params ), definition ); break; case 1: return generateRAIIHandleCommandResultSingleSuccessWithErrors1Return( commandIt, initialSkipCount, definition, returnParams[0] ); break; case 2: return generateRAIIHandleCommandResultSingleSuccessWithErrors2Return( commandIt, initialSkipCount, definition, returnParams ); break; @@ -7205,69 +7218,6 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandResultSingleSuccessWith return ""; } -std::string VulkanHppGenerator::generateRAIIHandleCommandResultSingleSuccessWithErrors0Return( std::map::const_iterator commandIt, - size_t initialSkipCount, - std::map const & vectorParams, - bool definition ) const -{ - std::set skippedParams = determineSkippedParams( commandIt->second.params, initialSkipCount, vectorParams, {}, false ); - std::set templatedParams = determineVoidPointerParams( commandIt->second.params ); - assert( areDisjoint( skippedParams, templatedParams ) ); - std::string argumentList = - generateArgumentListEnhanced( commandIt->second.params, {}, vectorParams, skippedParams, {}, templatedParams, definition, false, false, false ); - std::string commandName = generateCommandName( commandIt->first, commandIt->second.params, initialSkipCount, m_tags, false, false ); - std::string argumentTemplates = generateArgumentTemplates( commandIt->second.params, {}, vectorParams, templatedParams, true ); - - if ( definition ) - { - std::string const definitionTemplate = - R"( - ${argumentTemplates} - VULKAN_HPP_INLINE void ${className}::${commandName}( ${argumentList} ) const - {${functionPointerCheck} -${vectorSizeCheck} - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->${vkCommand}( ${callArguments} ) ); - if ( ${failureCheck} ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING"::${className}::${commandName}" ); - } - } -)"; - - std::string callArguments = generateCallArgumentsEnhanced( commandIt->second, initialSkipCount, false, {}, templatedParams, true ); - std::pair>> vectorSizeCheck = needsVectorSizeCheck( commandIt->second.params, vectorParams, {}, {} ); - std::string vectorSizeCheckString = - vectorSizeCheck.first ? generateRAIIHandleVectorSizeCheck( commandIt->first, commandIt->second, initialSkipCount, vectorSizeCheck.second, skippedParams ) - : ""; - - return replaceWithMap( definitionTemplate, - { { "argumentList", argumentList }, - { "argumentTemplates", argumentTemplates }, - { "callArguments", callArguments }, - { "className", stripPrefix( commandIt->second.params[initialSkipCount - 1].type.type, "Vk" ) }, - { "commandName", commandName }, - { "failureCheck", generateFailureCheck( commandIt->second.successCodes ) }, - { "functionPointerCheck", generateFunctionPointerCheck( commandIt->first, commandIt->second.referencedIn ) }, - { "vectorSizeCheck", vectorSizeCheckString }, - { "vkCommand", commandIt->first } } ); - } - else - { - std::string const declarationTemplate = - R"( - ${argumentTemplates} - void ${commandName}( ${argumentList} ) const; -)"; - - return replaceWithMap( declarationTemplate, - { - { "argumentList", argumentList }, - { "argumentTemplates", argumentTemplates }, - { "commandName", commandName }, - } ); - } -} - std::string VulkanHppGenerator::generateRAIIHandleCommandResultSingleSuccessWithErrors1ReturnChain( std::map::const_iterator commandIt, size_t initialSkipCount, @@ -9661,7 +9611,8 @@ std::string VulkanHppGenerator::generateReturnStatement( std::string const & com size_t initialSkipCount, size_t returnParam, bool unique, - bool enumerating ) const + bool enumerating, + bool raii ) const { std::string returnStatement; if ( beginsWith( commandData.returnType, "Vk" ) ) @@ -9669,7 +9620,7 @@ std::string VulkanHppGenerator::generateReturnStatement( std::string const & com if ( ( commandData.successCodes.size() == 1 ) || enumerating ) { assert( commandData.successCodes[0] == "VK_SUCCESS" ); - if ( !commandData.errorCodes.empty() ) + if ( !commandData.errorCodes.empty() && !raii ) { if ( returnVariable.empty() ) { @@ -9746,7 +9697,7 @@ std::string VulkanHppGenerator::generateReturnStatement( std::string const & com } std::string VulkanHppGenerator::generateReturnType( - CommandData const & commandData, std::vector const & returnParams, bool unique, bool chained, std::string const & dataType ) const + CommandData const & commandData, std::vector const & returnParams, bool unique, bool chained, bool raii, std::string const & dataType ) const { std::string modifiedDataType = dataType; if ( chained ) @@ -9793,7 +9744,7 @@ std::string VulkanHppGenerator::generateReturnType( } } else if ( ( commandData.returnType == "void" ) || - ( ( commandData.returnType == "VkResult" ) && ( commandData.successCodes.size() == 1 ) && commandData.errorCodes.empty() ) ) + ( ( commandData.returnType == "VkResult" ) && ( commandData.successCodes.size() == 1 ) && ( commandData.errorCodes.empty() || raii ) ) ) { assert( !unique ); assert( ( commandData.returnType != "void" ) || ( returnParams.size() <= 2 ) ); diff --git a/VulkanHppGenerator.hpp b/VulkanHppGenerator.hpp index d13f1ca..d6fc0f3 100644 --- a/VulkanHppGenerator.hpp +++ b/VulkanHppGenerator.hpp @@ -762,10 +762,6 @@ private: std::string generateRAIIHandleCommandResultSingleSuccessWithErrors( std::map::const_iterator commandIt, size_t initialSkipCount, bool definition ) const; - std::string generateRAIIHandleCommandResultSingleSuccessWithErrors0Return( std::map::const_iterator commandIt, - size_t initialSkipCount, - std::map const & vectorParamIndices, - bool definition ) const; std::string generateRAIIHandleCommandResultSingleSuccessWithErrors1ReturnChain( std::map::const_iterator commandIt, size_t initialSkipCount, std::map const & vectorParamIndices, @@ -924,9 +920,10 @@ private: size_t initialSkipCount, size_t returnParam, bool unique, - bool enumerating ) const; + bool enumerating, + bool raii ) const; std::string generateReturnType( - CommandData const & commandData, std::vector const & returnParams, bool unique, bool chained, std::string const & dataType ) const; + CommandData const & commandData, std::vector const & returnParams, bool unique, bool chained, bool raii, std::string const & dataType ) const; std::string generateReturnVariable( CommandData const & commandData, std::vector const & returnParams, std::map const & vectorParams, diff --git a/vulkan/vulkan_enums.hpp b/vulkan/vulkan_enums.hpp index 0fa4d0f..f58124f 100644 --- a/vulkan/vulkan_enums.hpp +++ b/vulkan/vulkan_enums.hpp @@ -8523,12 +8523,12 @@ namespace VULKAN_HPP_NAMESPACE VkFlags( FormatFeatureFlagBits::eDisjoint ) | VkFlags( FormatFeatureFlagBits::eCositedChromaSamples ) | VkFlags( FormatFeatureFlagBits::eSampledImageFilterMinmax ) | VkFlags( FormatFeatureFlagBits::eSampledImageFilterCubicIMG ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( FormatFeatureFlagBits::eVideoDecodeOutputKHR ) | VkFlags( FormatFeatureFlagBits::eVideoDecodeDpbKHR ) + | VkFlags( FormatFeatureFlagBits::eVideoDecodeOutputKHR ) | VkFlags( FormatFeatureFlagBits::eVideoDecodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags( FormatFeatureFlagBits::eAccelerationStructureVertexBufferKHR ) | VkFlags( FormatFeatureFlagBits::eFragmentDensityMapEXT ) | + | VkFlags( FormatFeatureFlagBits::eAccelerationStructureVertexBufferKHR ) | VkFlags( FormatFeatureFlagBits::eFragmentDensityMapEXT ) | VkFlags( FormatFeatureFlagBits::eFragmentShadingRateAttachmentKHR ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( FormatFeatureFlagBits::eVideoEncodeInputKHR ) | VkFlags( FormatFeatureFlagBits::eVideoEncodeDpbKHR ) + | VkFlags( FormatFeatureFlagBits::eVideoEncodeInputKHR ) | VkFlags( FormatFeatureFlagBits::eVideoEncodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ }; }; @@ -8723,15 +8723,15 @@ namespace VULKAN_HPP_NAMESPACE VkFlags( ImageUsageFlagBits::eDepthStencilAttachment ) | VkFlags( ImageUsageFlagBits::eTransientAttachment ) | VkFlags( ImageUsageFlagBits::eInputAttachment ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( ImageUsageFlagBits::eVideoDecodeDstKHR ) | VkFlags( ImageUsageFlagBits::eVideoDecodeSrcKHR ) | + | VkFlags( ImageUsageFlagBits::eVideoDecodeDstKHR ) | VkFlags( ImageUsageFlagBits::eVideoDecodeSrcKHR ) | VkFlags( ImageUsageFlagBits::eVideoDecodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags( ImageUsageFlagBits::eFragmentDensityMapEXT ) | VkFlags( ImageUsageFlagBits::eFragmentShadingRateAttachmentKHR ) + | VkFlags( ImageUsageFlagBits::eFragmentDensityMapEXT ) | VkFlags( ImageUsageFlagBits::eFragmentShadingRateAttachmentKHR ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( ImageUsageFlagBits::eVideoEncodeDstKHR ) | VkFlags( ImageUsageFlagBits::eVideoEncodeSrcKHR ) | + | VkFlags( ImageUsageFlagBits::eVideoEncodeDstKHR ) | VkFlags( ImageUsageFlagBits::eVideoEncodeSrcKHR ) | VkFlags( ImageUsageFlagBits::eVideoEncodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags( ImageUsageFlagBits::eInvocationMaskHUAWEI ) + | VkFlags( ImageUsageFlagBits::eInvocationMaskHUAWEI ) }; }; @@ -8964,7 +8964,7 @@ namespace VULKAN_HPP_NAMESPACE allFlags = VkFlags( QueueFlagBits::eGraphics ) | VkFlags( QueueFlagBits::eCompute ) | VkFlags( QueueFlagBits::eTransfer ) | VkFlags( QueueFlagBits::eSparseBinding ) | VkFlags( QueueFlagBits::eProtected ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( QueueFlagBits::eVideoDecodeKHR ) | VkFlags( QueueFlagBits::eVideoEncodeKHR ) + | VkFlags( QueueFlagBits::eVideoDecodeKHR ) | VkFlags( QueueFlagBits::eVideoEncodeKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ }; }; @@ -9574,7 +9574,7 @@ namespace VULKAN_HPP_NAMESPACE allFlags = VkFlags( QueryResultFlagBits::e64 ) | VkFlags( QueryResultFlagBits::eWait ) | VkFlags( QueryResultFlagBits::eWithAvailability ) | VkFlags( QueryResultFlagBits::ePartial ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( QueryResultFlagBits::eWithStatusKHR ) + | VkFlags( QueryResultFlagBits::eWithStatusKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ }; }; @@ -9687,13 +9687,13 @@ namespace VULKAN_HPP_NAMESPACE VkFlags( BufferUsageFlagBits::eIndexBuffer ) | VkFlags( BufferUsageFlagBits::eVertexBuffer ) | VkFlags( BufferUsageFlagBits::eIndirectBuffer ) | VkFlags( BufferUsageFlagBits::eShaderDeviceAddress ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( BufferUsageFlagBits::eVideoDecodeSrcKHR ) | VkFlags( BufferUsageFlagBits::eVideoDecodeDstKHR ) + | VkFlags( BufferUsageFlagBits::eVideoDecodeSrcKHR ) | VkFlags( BufferUsageFlagBits::eVideoDecodeDstKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags( BufferUsageFlagBits::eTransformFeedbackBufferEXT ) | VkFlags( BufferUsageFlagBits::eTransformFeedbackCounterBufferEXT ) | + | VkFlags( BufferUsageFlagBits::eTransformFeedbackBufferEXT ) | VkFlags( BufferUsageFlagBits::eTransformFeedbackCounterBufferEXT ) | VkFlags( BufferUsageFlagBits::eConditionalRenderingEXT ) | VkFlags( BufferUsageFlagBits::eAccelerationStructureBuildInputReadOnlyKHR ) | VkFlags( BufferUsageFlagBits::eAccelerationStructureStorageKHR ) | VkFlags( BufferUsageFlagBits::eShaderBindingTableKHR ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( BufferUsageFlagBits::eVideoEncodeDstKHR ) | VkFlags( BufferUsageFlagBits::eVideoEncodeSrcKHR ) + | VkFlags( BufferUsageFlagBits::eVideoEncodeDstKHR ) | VkFlags( BufferUsageFlagBits::eVideoEncodeSrcKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ }; }; @@ -11364,13 +11364,13 @@ namespace VULKAN_HPP_NAMESPACE VkFlags( ExternalMemoryHandleTypeFlagBits::eD3D11TextureKmt ) | VkFlags( ExternalMemoryHandleTypeFlagBits::eD3D12Heap ) | VkFlags( ExternalMemoryHandleTypeFlagBits::eD3D12Resource ) | VkFlags( ExternalMemoryHandleTypeFlagBits::eDmaBufEXT ) #if defined( VK_USE_PLATFORM_ANDROID_KHR ) - | VkFlags( ExternalMemoryHandleTypeFlagBits::eAndroidHardwareBufferANDROID ) + | VkFlags( ExternalMemoryHandleTypeFlagBits::eAndroidHardwareBufferANDROID ) #endif /*VK_USE_PLATFORM_ANDROID_KHR*/ - | VkFlags( ExternalMemoryHandleTypeFlagBits::eHostAllocationEXT ) | VkFlags( ExternalMemoryHandleTypeFlagBits::eHostMappedForeignMemoryEXT ) + | VkFlags( ExternalMemoryHandleTypeFlagBits::eHostAllocationEXT ) | VkFlags( ExternalMemoryHandleTypeFlagBits::eHostMappedForeignMemoryEXT ) #if defined( VK_USE_PLATFORM_FUCHSIA ) - | VkFlags( ExternalMemoryHandleTypeFlagBits::eZirconVmoFUCHSIA ) + | VkFlags( ExternalMemoryHandleTypeFlagBits::eZirconVmoFUCHSIA ) #endif /*VK_USE_PLATFORM_FUCHSIA*/ - | VkFlags( ExternalMemoryHandleTypeFlagBits::eRdmaAddressNV ) + | VkFlags( ExternalMemoryHandleTypeFlagBits::eRdmaAddressNV ) }; }; @@ -11698,7 +11698,7 @@ namespace VULKAN_HPP_NAMESPACE VkFlags( ExternalSemaphoreHandleTypeFlagBits::eOpaqueWin32Kmt ) | VkFlags( ExternalSemaphoreHandleTypeFlagBits::eD3D12Fence ) | VkFlags( ExternalSemaphoreHandleTypeFlagBits::eSyncFd ) #if defined( VK_USE_PLATFORM_FUCHSIA ) - | VkFlags( ExternalSemaphoreHandleTypeFlagBits::eZirconEventFUCHSIA ) + | VkFlags( ExternalSemaphoreHandleTypeFlagBits::eZirconEventFUCHSIA ) #endif /*VK_USE_PLATFORM_FUCHSIA*/ }; }; @@ -12096,9 +12096,9 @@ namespace VULKAN_HPP_NAMESPACE VkFlags64( PipelineStageFlagBits2::eClear ) | VkFlags64( PipelineStageFlagBits2::eIndexInput ) | VkFlags64( PipelineStageFlagBits2::eVertexAttributeInput ) | VkFlags64( PipelineStageFlagBits2::ePreRasterizationShaders ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags64( PipelineStageFlagBits2::eVideoDecodeKHR ) | VkFlags64( PipelineStageFlagBits2::eVideoEncodeKHR ) + | VkFlags64( PipelineStageFlagBits2::eVideoDecodeKHR ) | VkFlags64( PipelineStageFlagBits2::eVideoEncodeKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags64( PipelineStageFlagBits2::eTransformFeedbackEXT ) | VkFlags64( PipelineStageFlagBits2::eConditionalRenderingEXT ) | + | VkFlags64( PipelineStageFlagBits2::eTransformFeedbackEXT ) | VkFlags64( PipelineStageFlagBits2::eConditionalRenderingEXT ) | VkFlags64( PipelineStageFlagBits2::eCommandPreprocessNV ) | VkFlags64( PipelineStageFlagBits2::eFragmentShadingRateAttachmentKHR ) | VkFlags64( PipelineStageFlagBits2::eAccelerationStructureBuildKHR ) | VkFlags64( PipelineStageFlagBits2::eRayTracingShaderKHR ) | VkFlags64( PipelineStageFlagBits2::eFragmentDensityProcessEXT ) | VkFlags64( PipelineStageFlagBits2::eTaskShaderNV ) | @@ -12234,10 +12234,10 @@ namespace VULKAN_HPP_NAMESPACE VkFlags64( AccessFlagBits2::eShaderSampledRead ) | VkFlags64( AccessFlagBits2::eShaderStorageRead ) | VkFlags64( AccessFlagBits2::eShaderStorageWrite ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags64( AccessFlagBits2::eVideoDecodeReadKHR ) | VkFlags64( AccessFlagBits2::eVideoDecodeWriteKHR ) | + | VkFlags64( AccessFlagBits2::eVideoDecodeReadKHR ) | VkFlags64( AccessFlagBits2::eVideoDecodeWriteKHR ) | VkFlags64( AccessFlagBits2::eVideoEncodeReadKHR ) | VkFlags64( AccessFlagBits2::eVideoEncodeWriteKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags64( AccessFlagBits2::eTransformFeedbackWriteEXT ) | VkFlags64( AccessFlagBits2::eTransformFeedbackCounterReadEXT ) | + | VkFlags64( AccessFlagBits2::eTransformFeedbackWriteEXT ) | VkFlags64( AccessFlagBits2::eTransformFeedbackCounterReadEXT ) | VkFlags64( AccessFlagBits2::eTransformFeedbackCounterWriteEXT ) | VkFlags64( AccessFlagBits2::eConditionalRenderingReadEXT ) | VkFlags64( AccessFlagBits2::eCommandPreprocessReadNV ) | VkFlags64( AccessFlagBits2::eCommandPreprocessWriteNV ) | VkFlags64( AccessFlagBits2::eFragmentShadingRateAttachmentReadKHR ) | VkFlags64( AccessFlagBits2::eAccelerationStructureReadKHR ) | @@ -12474,14 +12474,14 @@ namespace VULKAN_HPP_NAMESPACE VkFlags64( FormatFeatureFlagBits2::eStorageReadWithoutFormat ) | VkFlags64( FormatFeatureFlagBits2::eStorageWriteWithoutFormat ) | VkFlags64( FormatFeatureFlagBits2::eSampledImageDepthComparison ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags64( FormatFeatureFlagBits2::eVideoDecodeOutputKHR ) | VkFlags64( FormatFeatureFlagBits2::eVideoDecodeDpbKHR ) + | VkFlags64( FormatFeatureFlagBits2::eVideoDecodeOutputKHR ) | VkFlags64( FormatFeatureFlagBits2::eVideoDecodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags64( FormatFeatureFlagBits2::eAccelerationStructureVertexBufferKHR ) | VkFlags64( FormatFeatureFlagBits2::eFragmentDensityMapEXT ) | + | VkFlags64( FormatFeatureFlagBits2::eAccelerationStructureVertexBufferKHR ) | VkFlags64( FormatFeatureFlagBits2::eFragmentDensityMapEXT ) | VkFlags64( FormatFeatureFlagBits2::eFragmentShadingRateAttachmentKHR ) #if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags64( FormatFeatureFlagBits2::eVideoEncodeInputKHR ) | VkFlags64( FormatFeatureFlagBits2::eVideoEncodeDpbKHR ) + | VkFlags64( FormatFeatureFlagBits2::eVideoEncodeInputKHR ) | VkFlags64( FormatFeatureFlagBits2::eVideoEncodeDpbKHR ) #endif /*VK_ENABLE_BETA_EXTENSIONS*/ - | VkFlags64( FormatFeatureFlagBits2::eLinearColorAttachmentNV ) + | VkFlags64( FormatFeatureFlagBits2::eLinearColorAttachmentNV ) }; }; @@ -13005,7 +13005,7 @@ namespace VULKAN_HPP_NAMESPACE { allFlags = VkFlags( VideoCodecOperationFlagBitsKHR::eInvalid ) # if defined( VK_ENABLE_BETA_EXTENSIONS ) - | VkFlags( VideoCodecOperationFlagBitsKHR::eEncodeH264EXT ) | VkFlags( VideoCodecOperationFlagBitsKHR::eEncodeH265EXT ) | + | VkFlags( VideoCodecOperationFlagBitsKHR::eEncodeH264EXT ) | VkFlags( VideoCodecOperationFlagBitsKHR::eEncodeH265EXT ) | VkFlags( VideoCodecOperationFlagBitsKHR::eDecodeH264EXT ) | VkFlags( VideoCodecOperationFlagBitsKHR::eDecodeH265EXT ) # endif /*VK_ENABLE_BETA_EXTENSIONS*/ }; diff --git a/vulkan/vulkan_raii.hpp b/vulkan/vulkan_raii.hpp index 91119e9..00f8fd0 100644 --- a/vulkan/vulkan_raii.hpp +++ b/vulkan/vulkan_raii.hpp @@ -10162,6 +10162,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceFeatures features; getDispatcher()->vkGetPhysicalDeviceFeatures( static_cast( m_physicalDevice ), reinterpret_cast( &features ) ); + return features; } @@ -10171,6 +10172,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::FormatProperties formatProperties; getDispatcher()->vkGetPhysicalDeviceFormatProperties( static_cast( m_physicalDevice ), static_cast( format ), reinterpret_cast( &formatProperties ) ); + return formatProperties; } @@ -10202,6 +10204,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceProperties properties; getDispatcher()->vkGetPhysicalDeviceProperties( static_cast( m_physicalDevice ), reinterpret_cast( &properties ) ); + return properties; } @@ -10223,18 +10226,21 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceMemoryProperties memoryProperties; getDispatcher()->vkGetPhysicalDeviceMemoryProperties( static_cast( m_physicalDevice ), reinterpret_cast( &memoryProperties ) ); + return memoryProperties; } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE PFN_vkVoidFunction Instance::getProcAddr( const std::string & name ) const VULKAN_HPP_NOEXCEPT { PFN_vkVoidFunction result = getDispatcher()->vkGetInstanceProcAddr( static_cast( m_instance ), name.c_str() ); + return result; } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE PFN_vkVoidFunction Device::getProcAddr( const std::string & name ) const VULKAN_HPP_NOEXCEPT { PFN_vkVoidFunction result = getDispatcher()->vkGetDeviceProcAddr( static_cast( m_device ), name.c_str() ); + return result; } @@ -10380,30 +10386,21 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Queue::submit( ArrayProxy const & submits, VULKAN_HPP_NAMESPACE::Fence fence ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueSubmit( - static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::submit" ); - } + VkResult result = getDispatcher()->vkQueueSubmit( + static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::submit" ); } VULKAN_HPP_INLINE void Queue::waitIdle() const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueWaitIdle( static_cast( m_queue ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::waitIdle" ); - } + VkResult result = getDispatcher()->vkQueueWaitIdle( static_cast( m_queue ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::waitIdle" ); } VULKAN_HPP_INLINE void Device::waitIdle() const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkDeviceWaitIdle( static_cast( m_device ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::waitIdle" ); - } + VkResult result = getDispatcher()->vkDeviceWaitIdle( static_cast( m_device ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::waitIdle" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::DeviceMemory @@ -10438,22 +10435,16 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Device::flushMappedMemoryRanges( ArrayProxy const & memoryRanges ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkFlushMappedMemoryRanges( - static_cast( m_device ), memoryRanges.size(), reinterpret_cast( memoryRanges.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::flushMappedMemoryRanges" ); - } + VkResult result = getDispatcher()->vkFlushMappedMemoryRanges( + static_cast( m_device ), memoryRanges.size(), reinterpret_cast( memoryRanges.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::flushMappedMemoryRanges" ); } VULKAN_HPP_INLINE void Device::invalidateMappedMemoryRanges( ArrayProxy const & memoryRanges ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkInvalidateMappedMemoryRanges( - static_cast( m_device ), memoryRanges.size(), reinterpret_cast( memoryRanges.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::invalidateMappedMemoryRanges" ); - } + VkResult result = getDispatcher()->vkInvalidateMappedMemoryRanges( + static_cast( m_device ), memoryRanges.size(), reinterpret_cast( memoryRanges.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::invalidateMappedMemoryRanges" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::DeviceSize DeviceMemory::getCommitment() const VULKAN_HPP_NOEXCEPT @@ -10461,33 +10452,24 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::DeviceSize committedMemoryInBytes; getDispatcher()->vkGetDeviceMemoryCommitment( static_cast( m_device ), static_cast( m_memory ), reinterpret_cast( &committedMemoryInBytes ) ); + return committedMemoryInBytes; } VULKAN_HPP_INLINE void Buffer::bindMemory( VULKAN_HPP_NAMESPACE::DeviceMemory memory, VULKAN_HPP_NAMESPACE::DeviceSize memoryOffset ) const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkBindBufferMemory( static_cast( m_device ), - static_cast( m_buffer ), - static_cast( memory ), - static_cast( memoryOffset ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Buffer::bindMemory" ); - } + VkResult result = getDispatcher()->vkBindBufferMemory( static_cast( m_device ), + static_cast( m_buffer ), + static_cast( memory ), + static_cast( memoryOffset ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Buffer::bindMemory" ); } VULKAN_HPP_INLINE void Image::bindMemory( VULKAN_HPP_NAMESPACE::DeviceMemory memory, VULKAN_HPP_NAMESPACE::DeviceSize memoryOffset ) const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkBindImageMemory( static_cast( m_device ), - static_cast( m_image ), - static_cast( memory ), - static_cast( memoryOffset ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Image::bindMemory" ); - } + VkResult result = getDispatcher()->vkBindImageMemory( + static_cast( m_device ), static_cast( m_image ), static_cast( memory ), static_cast( memoryOffset ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Image::bindMemory" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::MemoryRequirements Buffer::getMemoryRequirements() const VULKAN_HPP_NOEXCEPT @@ -10495,6 +10477,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::MemoryRequirements memoryRequirements; getDispatcher()->vkGetBufferMemoryRequirements( static_cast( m_device ), static_cast( m_buffer ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -10503,6 +10486,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::MemoryRequirements memoryRequirements; getDispatcher()->vkGetImageMemoryRequirements( static_cast( m_device ), static_cast( m_image ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -10552,12 +10536,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Queue::bindSparse( ArrayProxy const & bindInfo, VULKAN_HPP_NAMESPACE::Fence fence ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueBindSparse( - static_cast( m_queue ), bindInfo.size(), reinterpret_cast( bindInfo.data() ), static_cast( fence ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::bindSparse" ); - } + VkResult result = getDispatcher()->vkQueueBindSparse( + static_cast( m_queue ), bindInfo.size(), reinterpret_cast( bindInfo.data() ), static_cast( fence ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::bindSparse" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::Fence @@ -10569,12 +10550,8 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Device::resetFences( ArrayProxy const & fences ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkResetFences( static_cast( m_device ), fences.size(), reinterpret_cast( fences.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::resetFences" ); - } + VkResult result = getDispatcher()->vkResetFences( static_cast( m_device ), fences.size(), reinterpret_cast( fences.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::resetFences" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::Result Fence::getStatus() const @@ -10627,22 +10604,14 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Event::set() const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkSetEvent( static_cast( m_device ), static_cast( m_event ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Event::set" ); - } + VkResult result = getDispatcher()->vkSetEvent( static_cast( m_device ), static_cast( m_event ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Event::set" ); } VULKAN_HPP_INLINE void Event::reset() const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkResetEvent( static_cast( m_device ), static_cast( m_event ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Event::reset" ); - } + VkResult result = getDispatcher()->vkResetEvent( static_cast( m_device ), static_cast( m_event ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Event::reset" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::QueryPool @@ -10724,6 +10693,7 @@ namespace VULKAN_HPP_NAMESPACE static_cast( m_image ), reinterpret_cast( &subresource ), reinterpret_cast( &layout ) ); + return layout; } @@ -10781,15 +10751,11 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void PipelineCache::merge( ArrayProxy const & srcCaches ) const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkMergePipelineCaches( static_cast( m_device ), - static_cast( m_pipelineCache ), - srcCaches.size(), - reinterpret_cast( srcCaches.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::PipelineCache::merge" ); - } + VkResult result = getDispatcher()->vkMergePipelineCaches( static_cast( m_device ), + static_cast( m_pipelineCache ), + srcCaches.size(), + reinterpret_cast( srcCaches.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::PipelineCache::merge" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE std::vector Device::createGraphicsPipelines( @@ -10894,6 +10860,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::Extent2D granularity; getDispatcher()->vkGetRenderAreaGranularity( static_cast( m_device ), static_cast( m_renderPass ), reinterpret_cast( &granularity ) ); + return granularity; } @@ -10906,12 +10873,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void CommandPool::reset( VULKAN_HPP_NAMESPACE::CommandPoolResetFlags flags ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkResetCommandPool( - static_cast( m_device ), static_cast( m_commandPool ), static_cast( flags ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandPool::reset" ); - } + VkResult result = getDispatcher()->vkResetCommandPool( + static_cast( m_device ), static_cast( m_commandPool ), static_cast( flags ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandPool::reset" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE std::vector @@ -10922,32 +10886,22 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void CommandBuffer::begin( const VULKAN_HPP_NAMESPACE::CommandBufferBeginInfo & beginInfo ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBeginCommandBuffer( - static_cast( m_commandBuffer ), reinterpret_cast( &beginInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::begin" ); - } + VkResult result = getDispatcher()->vkBeginCommandBuffer( static_cast( m_commandBuffer ), + reinterpret_cast( &beginInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::begin" ); } VULKAN_HPP_INLINE void CommandBuffer::end() const { - VULKAN_HPP_NAMESPACE::Result result = - static_cast( getDispatcher()->vkEndCommandBuffer( static_cast( m_commandBuffer ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::end" ); - } + VkResult result = getDispatcher()->vkEndCommandBuffer( static_cast( m_commandBuffer ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::end" ); } VULKAN_HPP_INLINE void CommandBuffer::reset( VULKAN_HPP_NAMESPACE::CommandBufferResetFlags flags ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkResetCommandBuffer( static_cast( m_commandBuffer ), static_cast( flags ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::reset" ); - } + VkResult result = + getDispatcher()->vkResetCommandBuffer( static_cast( m_commandBuffer ), static_cast( flags ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::reset" ); } VULKAN_HPP_INLINE void CommandBuffer::bindPipeline( VULKAN_HPP_NAMESPACE::PipelineBindPoint pipelineBindPoint, @@ -11392,22 +11346,16 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Device::bindBufferMemory2( ArrayProxy const & bindInfos ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBindBufferMemory2( - static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::bindBufferMemory2" ); - } + VkResult result = getDispatcher()->vkBindBufferMemory2( + static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::bindBufferMemory2" ); } VULKAN_HPP_INLINE void Device::bindImageMemory2( ArrayProxy const & bindInfos ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBindImageMemory2( - static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::bindImageMemory2" ); - } + VkResult result = getDispatcher()->vkBindImageMemory2( + static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::bindImageMemory2" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::PeerMemoryFeatureFlags @@ -11419,6 +11367,7 @@ namespace VULKAN_HPP_NAMESPACE localDeviceIndex, remoteDeviceIndex, reinterpret_cast( &peerMemoryFeatures ) ); + return peerMemoryFeatures; } @@ -11478,6 +11427,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetImageMemoryRequirements2( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -11500,6 +11450,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetBufferMemoryRequirements2( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -11535,6 +11486,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceFeatures2 features; getDispatcher()->vkGetPhysicalDeviceFeatures2( static_cast( m_physicalDevice ), reinterpret_cast( &features ) ); + return features; } @@ -11553,6 +11505,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceProperties2 properties; getDispatcher()->vkGetPhysicalDeviceProperties2( static_cast( m_physicalDevice ), reinterpret_cast( &properties ) ); + return properties; } @@ -11572,6 +11525,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::FormatProperties2 formatProperties; getDispatcher()->vkGetPhysicalDeviceFormatProperties2( static_cast( m_physicalDevice ), static_cast( format ), reinterpret_cast( &formatProperties ) ); + return formatProperties; } @@ -11659,6 +11613,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceMemoryProperties2 memoryProperties; getDispatcher()->vkGetPhysicalDeviceMemoryProperties2( static_cast( m_physicalDevice ), reinterpret_cast( &memoryProperties ) ); + return memoryProperties; } @@ -11732,6 +11687,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetPhysicalDeviceExternalBufferProperties( static_cast( m_physicalDevice ), reinterpret_cast( &externalBufferInfo ), reinterpret_cast( &externalBufferProperties ) ); + return externalBufferProperties; } @@ -11742,6 +11698,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetPhysicalDeviceExternalFenceProperties( static_cast( m_physicalDevice ), reinterpret_cast( &externalFenceInfo ), reinterpret_cast( &externalFenceProperties ) ); + return externalFenceProperties; } @@ -11753,6 +11710,7 @@ namespace VULKAN_HPP_NAMESPACE static_cast( m_physicalDevice ), reinterpret_cast( &externalSemaphoreInfo ), reinterpret_cast( &externalSemaphoreProperties ) ); + return externalSemaphoreProperties; } @@ -11763,6 +11721,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDescriptorSetLayoutSupport( static_cast( m_device ), reinterpret_cast( &createInfo ), reinterpret_cast( &support ) ); + return support; } @@ -11871,12 +11830,8 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Device::signalSemaphore( const VULKAN_HPP_NAMESPACE::SemaphoreSignalInfo & signalInfo ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkSignalSemaphore( static_cast( m_device ), reinterpret_cast( &signalInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::signalSemaphore" ); - } + VkResult result = getDispatcher()->vkSignalSemaphore( static_cast( m_device ), reinterpret_cast( &signalInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::signalSemaphore" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::DeviceAddress @@ -11884,6 +11839,7 @@ namespace VULKAN_HPP_NAMESPACE { VkDeviceAddress result = getDispatcher()->vkGetBufferDeviceAddress( static_cast( m_device ), reinterpret_cast( &info ) ); + return static_cast( result ); } @@ -11892,6 +11848,7 @@ namespace VULKAN_HPP_NAMESPACE { uint64_t result = getDispatcher()->vkGetBufferOpaqueCaptureAddress( static_cast( m_device ), reinterpret_cast( &info ) ); + return result; } @@ -11900,6 +11857,7 @@ namespace VULKAN_HPP_NAMESPACE { uint64_t result = getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddress( static_cast( m_device ), reinterpret_cast( &info ) ); + return result; } @@ -11948,12 +11906,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PrivateDataSlot privateDataSlot, uint64_t data ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkSetPrivateData( - static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), data ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::setPrivateData" ); - } + VkResult result = getDispatcher()->vkSetPrivateData( + static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), data ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::setPrivateData" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE uint64_t Device::getPrivateData( VULKAN_HPP_NAMESPACE::ObjectType objectType_, @@ -11963,6 +11918,7 @@ namespace VULKAN_HPP_NAMESPACE uint64_t data; getDispatcher()->vkGetPrivateData( static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), &data ); + return data; } @@ -12009,12 +11965,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_INLINE void Queue::submit2( ArrayProxy const & submits, VULKAN_HPP_NAMESPACE::Fence fence ) const { - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueSubmit2( - static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::submit2" ); - } + VkResult result = getDispatcher()->vkQueueSubmit2( + static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::submit2" ); } VULKAN_HPP_INLINE void CommandBuffer::copyBuffer2( const VULKAN_HPP_NAMESPACE::CopyBufferInfo2 & copyBufferInfo ) const VULKAN_HPP_NOEXCEPT @@ -12178,6 +12131,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDeviceBufferMemoryRequirements( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -12200,6 +12154,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDeviceImageMemoryRequirements( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -12672,6 +12627,7 @@ namespace VULKAN_HPP_NAMESPACE VkBool32 result = getDispatcher()->vkGetPhysicalDeviceXlibPresentationSupportKHR( static_cast( m_physicalDevice ), queueFamilyIndex, &dpy, visualID ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_XLIB_KHR*/ @@ -12694,6 +12650,7 @@ namespace VULKAN_HPP_NAMESPACE VkBool32 result = getDispatcher()->vkGetPhysicalDeviceXcbPresentationSupportKHR( static_cast( m_physicalDevice ), queueFamilyIndex, &connection, visual_id ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_XCB_KHR*/ @@ -12716,6 +12673,7 @@ namespace VULKAN_HPP_NAMESPACE VkBool32 result = getDispatcher()->vkGetPhysicalDeviceWaylandPresentationSupportKHR( static_cast( m_physicalDevice ), queueFamilyIndex, &display ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_WAYLAND_KHR*/ @@ -12748,6 +12706,7 @@ namespace VULKAN_HPP_NAMESPACE "Function needs extension enabled!" ); VkBool32 result = getDispatcher()->vkGetPhysicalDeviceWin32PresentationSupportKHR( static_cast( m_physicalDevice ), queueFamilyIndex ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_WIN32_KHR*/ @@ -12788,12 +12747,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkDebugMarkerSetObjectTagEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkDebugMarkerSetObjectTagEXT( - static_cast( m_device ), reinterpret_cast( &tagInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::debugMarkerSetObjectTagEXT" ); - } + VkResult result = + getDispatcher()->vkDebugMarkerSetObjectTagEXT( static_cast( m_device ), reinterpret_cast( &tagInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::debugMarkerSetObjectTagEXT" ); } VULKAN_HPP_INLINE void Device::debugMarkerSetObjectNameEXT( const VULKAN_HPP_NAMESPACE::DebugMarkerObjectNameInfoEXT & nameInfo ) const @@ -12801,12 +12757,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkDebugMarkerSetObjectNameEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkDebugMarkerSetObjectNameEXT( - static_cast( m_device ), reinterpret_cast( &nameInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::debugMarkerSetObjectNameEXT" ); - } + VkResult result = getDispatcher()->vkDebugMarkerSetObjectNameEXT( static_cast( m_device ), + reinterpret_cast( &nameInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::debugMarkerSetObjectNameEXT" ); } VULKAN_HPP_INLINE void CommandBuffer::debugMarkerBeginEXT( const VULKAN_HPP_NAMESPACE::DebugMarkerMarkerInfoEXT & markerInfo ) const VULKAN_HPP_NOEXCEPT @@ -12956,15 +12909,11 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkBindVideoSessionMemoryKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkBindVideoSessionMemoryKHR( static_cast( m_device ), - static_cast( m_videoSession ), - videoSessionBindMemories.size(), - reinterpret_cast( videoSessionBindMemories.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::VideoSessionKHR::bindMemory" ); - } + VkResult result = getDispatcher()->vkBindVideoSessionMemoryKHR( static_cast( m_device ), + static_cast( m_videoSession ), + videoSessionBindMemories.size(), + reinterpret_cast( videoSessionBindMemories.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::VideoSessionKHR::bindMemory" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::VideoSessionParametersKHR @@ -12979,14 +12928,10 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkUpdateVideoSessionParametersKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkUpdateVideoSessionParametersKHR( static_cast( m_device ), - static_cast( m_videoSessionParameters ), - reinterpret_cast( &updateInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::VideoSessionParametersKHR::update" ); - } + VkResult result = getDispatcher()->vkUpdateVideoSessionParametersKHR( static_cast( m_device ), + static_cast( m_videoSessionParameters ), + reinterpret_cast( &updateInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::VideoSessionParametersKHR::update" ); } VULKAN_HPP_INLINE void CommandBuffer::beginVideoCodingKHR( const VULKAN_HPP_NAMESPACE::VideoBeginCodingInfoKHR & beginInfo ) const VULKAN_HPP_NOEXCEPT @@ -13160,6 +13105,7 @@ namespace VULKAN_HPP_NAMESPACE uint32_t result = getDispatcher()->vkGetImageViewHandleNVX( static_cast( m_device ), reinterpret_cast( &info ) ); + return result; } @@ -13344,6 +13290,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceFeatures2 features; getDispatcher()->vkGetPhysicalDeviceFeatures2KHR( static_cast( m_physicalDevice ), reinterpret_cast( &features ) ); + return features; } @@ -13367,6 +13314,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceProperties2 properties; getDispatcher()->vkGetPhysicalDeviceProperties2KHR( static_cast( m_physicalDevice ), reinterpret_cast( &properties ) ); + return properties; } @@ -13391,6 +13339,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::FormatProperties2 formatProperties; getDispatcher()->vkGetPhysicalDeviceFormatProperties2KHR( static_cast( m_physicalDevice ), static_cast( format ), reinterpret_cast( &formatProperties ) ); + return formatProperties; } @@ -13489,6 +13438,7 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_NAMESPACE::PhysicalDeviceMemoryProperties2 memoryProperties; getDispatcher()->vkGetPhysicalDeviceMemoryProperties2KHR( static_cast( m_physicalDevice ), reinterpret_cast( &memoryProperties ) ); + return memoryProperties; } @@ -13538,6 +13488,7 @@ namespace VULKAN_HPP_NAMESPACE localDeviceIndex, remoteDeviceIndex, reinterpret_cast( &peerMemoryFeatures ) ); + return peerMemoryFeatures; } @@ -13631,6 +13582,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetPhysicalDeviceExternalBufferPropertiesKHR( static_cast( m_physicalDevice ), reinterpret_cast( &externalBufferInfo ), reinterpret_cast( &externalBufferProperties ) ); + return externalBufferProperties; } @@ -13717,6 +13669,7 @@ namespace VULKAN_HPP_NAMESPACE static_cast( m_physicalDevice ), reinterpret_cast( &externalSemaphoreInfo ), reinterpret_cast( &externalSemaphoreProperties ) ); + return externalSemaphoreProperties; } @@ -13729,12 +13682,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkImportSemaphoreWin32HandleKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkImportSemaphoreWin32HandleKHR( - static_cast( m_device ), reinterpret_cast( &importSemaphoreWin32HandleInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreWin32HandleKHR" ); - } + VkResult result = getDispatcher()->vkImportSemaphoreWin32HandleKHR( + static_cast( m_device ), reinterpret_cast( &importSemaphoreWin32HandleInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreWin32HandleKHR" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE HANDLE @@ -13760,12 +13710,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkImportSemaphoreFdKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkImportSemaphoreFdKHR( - static_cast( m_device ), reinterpret_cast( &importSemaphoreFdInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreFdKHR" ); - } + VkResult result = getDispatcher()->vkImportSemaphoreFdKHR( static_cast( m_device ), + reinterpret_cast( &importSemaphoreFdInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreFdKHR" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE int Device::getSemaphoreFdKHR( const VULKAN_HPP_NAMESPACE::SemaphoreGetFdInfoKHR & getFdInfo ) const @@ -13894,12 +13841,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkAcquireXlibDisplayEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkAcquireXlibDisplayEXT( static_cast( m_physicalDevice ), &dpy, static_cast( display ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::PhysicalDevice::acquireXlibDisplayEXT" ); - } + VkResult result = + getDispatcher()->vkAcquireXlibDisplayEXT( static_cast( m_physicalDevice ), &dpy, static_cast( display ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::PhysicalDevice::acquireXlibDisplayEXT" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::DisplayKHR PhysicalDevice::getRandROutputDisplayEXT( Display & dpy, @@ -13935,12 +13879,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkDisplayPowerControlEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkDisplayPowerControlEXT( - static_cast( m_device ), static_cast( display ), reinterpret_cast( &displayPowerInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::displayPowerControlEXT" ); - } + VkResult result = getDispatcher()->vkDisplayPowerControlEXT( + static_cast( m_device ), static_cast( display ), reinterpret_cast( &displayPowerInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::displayPowerControlEXT" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::Fence @@ -14122,6 +14063,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetPhysicalDeviceExternalFencePropertiesKHR( static_cast( m_physicalDevice ), reinterpret_cast( &externalFenceInfo ), reinterpret_cast( &externalFenceProperties ) ); + return externalFenceProperties; } @@ -14133,12 +14075,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkImportFenceWin32HandleKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkImportFenceWin32HandleKHR( - static_cast( m_device ), reinterpret_cast( &importFenceWin32HandleInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::importFenceWin32HandleKHR" ); - } + VkResult result = getDispatcher()->vkImportFenceWin32HandleKHR( + static_cast( m_device ), reinterpret_cast( &importFenceWin32HandleInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::importFenceWin32HandleKHR" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE HANDLE @@ -14163,12 +14102,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkImportFenceFdKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkImportFenceFdKHR( static_cast( m_device ), reinterpret_cast( &importFenceFdInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::importFenceFdKHR" ); - } + VkResult result = + getDispatcher()->vkImportFenceFdKHR( static_cast( m_device ), reinterpret_cast( &importFenceFdInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::importFenceFdKHR" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE int Device::getFenceFdKHR( const VULKAN_HPP_NAMESPACE::FenceGetFdInfoKHR & getFdInfo ) const @@ -14236,6 +14172,7 @@ namespace VULKAN_HPP_NAMESPACE static_cast( m_physicalDevice ), reinterpret_cast( &performanceQueryCreateInfo ), &numPasses ); + return numPasses; } @@ -14244,12 +14181,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkAcquireProfilingLockKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkAcquireProfilingLockKHR( static_cast( m_device ), reinterpret_cast( &info ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::acquireProfilingLockKHR" ); - } + VkResult result = + getDispatcher()->vkAcquireProfilingLockKHR( static_cast( m_device ), reinterpret_cast( &info ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::acquireProfilingLockKHR" ); } VULKAN_HPP_INLINE void Device::releaseProfilingLockKHR() const VULKAN_HPP_NOEXCEPT @@ -14534,12 +14468,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkSetDebugUtilsObjectNameEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkSetDebugUtilsObjectNameEXT( - static_cast( m_device ), reinterpret_cast( &nameInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::setDebugUtilsObjectNameEXT" ); - } + VkResult result = getDispatcher()->vkSetDebugUtilsObjectNameEXT( static_cast( m_device ), + reinterpret_cast( &nameInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::setDebugUtilsObjectNameEXT" ); } VULKAN_HPP_INLINE void Device::setDebugUtilsObjectTagEXT( const VULKAN_HPP_NAMESPACE::DebugUtilsObjectTagInfoEXT & tagInfo ) const @@ -14547,12 +14478,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkSetDebugUtilsObjectTagEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkSetDebugUtilsObjectTagEXT( static_cast( m_device ), reinterpret_cast( &tagInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::setDebugUtilsObjectTagEXT" ); - } + VkResult result = + getDispatcher()->vkSetDebugUtilsObjectTagEXT( static_cast( m_device ), reinterpret_cast( &tagInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::setDebugUtilsObjectTagEXT" ); } VULKAN_HPP_INLINE void Queue::beginDebugUtilsLabelEXT( const VULKAN_HPP_NAMESPACE::DebugUtilsLabelEXT & labelInfo ) const VULKAN_HPP_NOEXCEPT @@ -14697,6 +14625,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetPhysicalDeviceMultisamplePropertiesEXT( static_cast( m_physicalDevice ), static_cast( samples ), reinterpret_cast( &multisampleProperties ) ); + return multisampleProperties; } @@ -14712,6 +14641,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetImageMemoryRequirements2KHR( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -14739,6 +14669,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetBufferMemoryRequirements2KHR( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -14999,6 +14930,7 @@ namespace VULKAN_HPP_NAMESPACE VkDeviceAddress result = getDispatcher()->vkGetAccelerationStructureDeviceAddressKHR( static_cast( m_device ), reinterpret_cast( &info ) ); + return static_cast( result ); } @@ -15029,6 +14961,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDeviceAccelerationStructureCompatibilityKHR( static_cast( m_device ), reinterpret_cast( &versionInfo ), reinterpret_cast( &compatibility ) ); + return compatibility; } @@ -15050,6 +14983,7 @@ namespace VULKAN_HPP_NAMESPACE reinterpret_cast( &buildInfo ), maxPrimitiveCounts.data(), reinterpret_cast( &sizeInfo ) ); + return sizeInfo; } @@ -15081,24 +15015,18 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkBindBufferMemory2KHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBindBufferMemory2KHR( - static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::bindBufferMemory2KHR" ); - } + VkResult result = getDispatcher()->vkBindBufferMemory2KHR( + static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::bindBufferMemory2KHR" ); } VULKAN_HPP_INLINE void Device::bindImageMemory2KHR( ArrayProxy const & bindInfos ) const { VULKAN_HPP_ASSERT( getDispatcher()->vkBindImageMemory2KHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBindImageMemory2KHR( - static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::bindImageMemory2KHR" ); - } + VkResult result = getDispatcher()->vkBindImageMemory2KHR( + static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::bindImageMemory2KHR" ); } //=== VK_EXT_image_drm_format_modifier === @@ -15131,15 +15059,11 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkMergeValidationCachesEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkMergeValidationCachesEXT( static_cast( m_device ), - static_cast( m_validationCache ), - srcCaches.size(), - reinterpret_cast( srcCaches.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::ValidationCacheEXT::merge" ); - } + VkResult result = getDispatcher()->vkMergeValidationCachesEXT( static_cast( m_device ), + static_cast( m_validationCache ), + srcCaches.size(), + reinterpret_cast( srcCaches.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::ValidationCacheEXT::merge" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE std::vector ValidationCacheEXT::getData() const @@ -15231,6 +15155,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetAccelerationStructureMemoryRequirementsNV( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -15254,12 +15179,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkBindAccelerationStructureMemoryNV && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkBindAccelerationStructureMemoryNV( - static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::bindAccelerationStructureMemoryNV" ); - } + VkResult result = getDispatcher()->vkBindAccelerationStructureMemoryNV( + static_cast( m_device ), bindInfos.size(), reinterpret_cast( bindInfos.data() ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::bindAccelerationStructureMemoryNV" ); } VULKAN_HPP_INLINE void CommandBuffer::buildAccelerationStructureNV( const VULKAN_HPP_NAMESPACE::AccelerationStructureInfoNV & info, @@ -15442,12 +15364,8 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkCompileDeferredNV && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkCompileDeferredNV( static_cast( m_device ), static_cast( m_pipeline ), shader ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Pipeline::compileDeferredNV" ); - } + VkResult result = getDispatcher()->vkCompileDeferredNV( static_cast( m_device ), static_cast( m_pipeline ), shader ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Pipeline::compileDeferredNV" ); } //=== VK_KHR_maintenance3 === @@ -15462,6 +15380,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDescriptorSetLayoutSupportKHR( static_cast( m_device ), reinterpret_cast( &createInfo ), reinterpret_cast( &support ) ); + return support; } @@ -15741,12 +15660,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkSignalSemaphoreKHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkSignalSemaphoreKHR( static_cast( m_device ), reinterpret_cast( &signalInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::signalSemaphoreKHR" ); - } + VkResult result = + getDispatcher()->vkSignalSemaphoreKHR( static_cast( m_device ), reinterpret_cast( &signalInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::signalSemaphoreKHR" ); } //=== VK_INTEL_performance_query === @@ -15756,12 +15672,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkInitializePerformanceApiINTEL && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkInitializePerformanceApiINTEL( - static_cast( m_device ), reinterpret_cast( &initializeInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::initializePerformanceApiINTEL" ); - } + VkResult result = getDispatcher()->vkInitializePerformanceApiINTEL( static_cast( m_device ), + reinterpret_cast( &initializeInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::initializePerformanceApiINTEL" ); } VULKAN_HPP_INLINE void Device::uninitializePerformanceApiINTEL() const VULKAN_HPP_NOEXCEPT @@ -15777,12 +15690,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkCmdSetPerformanceMarkerINTEL && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkCmdSetPerformanceMarkerINTEL( - static_cast( m_commandBuffer ), reinterpret_cast( &markerInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceMarkerINTEL" ); - } + VkResult result = getDispatcher()->vkCmdSetPerformanceMarkerINTEL( static_cast( m_commandBuffer ), + reinterpret_cast( &markerInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceMarkerINTEL" ); } VULKAN_HPP_INLINE void CommandBuffer::setPerformanceStreamMarkerINTEL( const VULKAN_HPP_NAMESPACE::PerformanceStreamMarkerInfoINTEL & markerInfo ) const @@ -15790,12 +15700,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkCmdSetPerformanceStreamMarkerINTEL && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkCmdSetPerformanceStreamMarkerINTEL( - static_cast( m_commandBuffer ), reinterpret_cast( &markerInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceStreamMarkerINTEL" ); - } + VkResult result = getDispatcher()->vkCmdSetPerformanceStreamMarkerINTEL( static_cast( m_commandBuffer ), + reinterpret_cast( &markerInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceStreamMarkerINTEL" ); } VULKAN_HPP_INLINE void CommandBuffer::setPerformanceOverrideINTEL( const VULKAN_HPP_NAMESPACE::PerformanceOverrideInfoINTEL & overrideInfo ) const @@ -15803,12 +15710,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkCmdSetPerformanceOverrideINTEL && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkCmdSetPerformanceOverrideINTEL( - static_cast( m_commandBuffer ), reinterpret_cast( &overrideInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceOverrideINTEL" ); - } + VkResult result = getDispatcher()->vkCmdSetPerformanceOverrideINTEL( static_cast( m_commandBuffer ), + reinterpret_cast( &overrideInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::CommandBuffer::setPerformanceOverrideINTEL" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::PerformanceConfigurationINTEL @@ -15822,12 +15726,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkQueueSetPerformanceConfigurationINTEL && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueSetPerformanceConfigurationINTEL( - static_cast( m_queue ), static_cast( configuration ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::setPerformanceConfigurationINTEL" ); - } + VkResult result = getDispatcher()->vkQueueSetPerformanceConfigurationINTEL( static_cast( m_queue ), + static_cast( configuration ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::setPerformanceConfigurationINTEL" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::PerformanceValueINTEL @@ -15937,6 +15838,7 @@ namespace VULKAN_HPP_NAMESPACE VkDeviceAddress result = getDispatcher()->vkGetBufferDeviceAddressEXT( static_cast( m_device ), reinterpret_cast( &info ) ); + return static_cast( result ); } @@ -16114,12 +16016,8 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkAcquireFullScreenExclusiveModeEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkAcquireFullScreenExclusiveModeEXT( static_cast( m_device ), static_cast( m_swapchain ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::SwapchainKHR::acquireFullScreenExclusiveModeEXT" ); - } + VkResult result = getDispatcher()->vkAcquireFullScreenExclusiveModeEXT( static_cast( m_device ), static_cast( m_swapchain ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::SwapchainKHR::acquireFullScreenExclusiveModeEXT" ); } VULKAN_HPP_INLINE void SwapchainKHR::releaseFullScreenExclusiveModeEXT() const @@ -16127,12 +16025,8 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkReleaseFullScreenExclusiveModeEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkReleaseFullScreenExclusiveModeEXT( static_cast( m_device ), static_cast( m_swapchain ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::SwapchainKHR::releaseFullScreenExclusiveModeEXT" ); - } + VkResult result = getDispatcher()->vkReleaseFullScreenExclusiveModeEXT( static_cast( m_device ), static_cast( m_swapchain ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::SwapchainKHR::releaseFullScreenExclusiveModeEXT" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::DeviceGroupPresentModeFlagsKHR @@ -16172,6 +16066,7 @@ namespace VULKAN_HPP_NAMESPACE VkDeviceAddress result = getDispatcher()->vkGetBufferDeviceAddressKHR( static_cast( m_device ), reinterpret_cast( &info ) ); + return static_cast( result ); } @@ -16183,6 +16078,7 @@ namespace VULKAN_HPP_NAMESPACE uint64_t result = getDispatcher()->vkGetBufferOpaqueCaptureAddressKHR( static_cast( m_device ), reinterpret_cast( &info ) ); + return result; } @@ -16194,6 +16090,7 @@ namespace VULKAN_HPP_NAMESPACE uint64_t result = getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddressKHR( static_cast( m_device ), reinterpret_cast( &info ) ); + return result; } @@ -16359,6 +16256,7 @@ namespace VULKAN_HPP_NAMESPACE uint32_t result = getDispatcher()->vkGetDeferredOperationMaxConcurrencyKHR( static_cast( m_device ), static_cast( m_operation ) ); + return result; } @@ -16369,6 +16267,7 @@ namespace VULKAN_HPP_NAMESPACE VkResult result = getDispatcher()->vkGetDeferredOperationResultKHR( static_cast( m_device ), static_cast( m_operation ) ); + return static_cast( result ); } @@ -16515,6 +16414,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetGeneratedCommandsMemoryRequirementsNV( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -16580,12 +16480,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkAcquireDrmDisplayEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkAcquireDrmDisplayEXT( static_cast( m_physicalDevice ), drmFd, static_cast( display ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::PhysicalDevice::acquireDrmDisplayEXT" ); - } + VkResult result = + getDispatcher()->vkAcquireDrmDisplayEXT( static_cast( m_physicalDevice ), drmFd, static_cast( display ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::PhysicalDevice::acquireDrmDisplayEXT" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::DisplayKHR PhysicalDevice::getDrmDisplayEXT( int32_t drmFd, uint32_t connectorId ) const @@ -16621,12 +16518,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkSetPrivateDataEXT && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkSetPrivateDataEXT( - static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), data ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::setPrivateDataEXT" ); - } + VkResult result = getDispatcher()->vkSetPrivateDataEXT( + static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), data ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::setPrivateDataEXT" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE uint64_t Device::getPrivateDataEXT( VULKAN_HPP_NAMESPACE::ObjectType objectType_, @@ -16638,6 +16532,7 @@ namespace VULKAN_HPP_NAMESPACE uint64_t data; getDispatcher()->vkGetPrivateDataEXT( static_cast( m_device ), static_cast( objectType_ ), objectHandle, static_cast( privateDataSlot ), &data ); + return data; } @@ -16710,12 +16605,9 @@ namespace VULKAN_HPP_NAMESPACE { VULKAN_HPP_ASSERT( getDispatcher()->vkQueueSubmit2KHR && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkQueueSubmit2KHR( - static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Queue::submit2KHR" ); - } + VkResult result = getDispatcher()->vkQueueSubmit2KHR( + static_cast( m_queue ), submits.size(), reinterpret_cast( submits.data() ), static_cast( fence ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Queue::submit2KHR" ); } VULKAN_HPP_INLINE void CommandBuffer::writeBufferMarker2AMD( VULKAN_HPP_NAMESPACE::PipelineStageFlags2 stage, @@ -16824,6 +16716,7 @@ namespace VULKAN_HPP_NAMESPACE static_cast( m_image ), reinterpret_cast( &subresource ), reinterpret_cast( &layout ) ); + return layout; } @@ -16850,12 +16743,8 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkAcquireWinrtDisplayNV && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( - getDispatcher()->vkAcquireWinrtDisplayNV( static_cast( m_physicalDevice ), static_cast( m_display ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::DisplayKHR::acquireWinrtNV" ); - } + VkResult result = getDispatcher()->vkAcquireWinrtDisplayNV( static_cast( m_physicalDevice ), static_cast( m_display ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::DisplayKHR::acquireWinrtNV" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::DisplayKHR PhysicalDevice::getWinrtDisplayNV( uint32_t deviceRelativeId ) const @@ -16882,6 +16771,7 @@ namespace VULKAN_HPP_NAMESPACE VkBool32 result = getDispatcher()->vkGetPhysicalDeviceDirectFBPresentationSupportEXT( static_cast( m_physicalDevice ), queueFamilyIndex, &dfb ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_DIRECTFB_EXT*/ @@ -17027,6 +16917,7 @@ namespace VULKAN_HPP_NAMESPACE VkDeviceSize result = getDispatcher()->vkGetRayTracingShaderGroupStackSizeKHR( static_cast( m_device ), static_cast( m_pipeline ), group, static_cast( groupShader ) ); + return static_cast( result ); } @@ -17100,12 +16991,9 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkImportSemaphoreZirconHandleFUCHSIA && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( getDispatcher()->vkImportSemaphoreZirconHandleFUCHSIA( - static_cast( m_device ), reinterpret_cast( &importSemaphoreZirconHandleInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreZirconHandleFUCHSIA" ); - } + VkResult result = getDispatcher()->vkImportSemaphoreZirconHandleFUCHSIA( + static_cast( m_device ), reinterpret_cast( &importSemaphoreZirconHandleInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::Device::importSemaphoreZirconHandleFUCHSIA" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE zx_handle_t @@ -17139,14 +17027,11 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkSetBufferCollectionImageConstraintsFUCHSIA && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( + VkResult result = getDispatcher()->vkSetBufferCollectionImageConstraintsFUCHSIA( static_cast( m_device ), static_cast( m_collection ), - reinterpret_cast( &imageConstraintsInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::BufferCollectionFUCHSIA::setImageConstraints" ); - } + reinterpret_cast( &imageConstraintsInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::BufferCollectionFUCHSIA::setImageConstraints" ); } VULKAN_HPP_INLINE void @@ -17155,14 +17040,11 @@ namespace VULKAN_HPP_NAMESPACE VULKAN_HPP_ASSERT( getDispatcher()->vkSetBufferCollectionBufferConstraintsFUCHSIA && "Function needs extension enabled!" ); - VULKAN_HPP_NAMESPACE::Result result = static_cast( + VkResult result = getDispatcher()->vkSetBufferCollectionBufferConstraintsFUCHSIA( static_cast( m_device ), static_cast( m_collection ), - reinterpret_cast( &bufferConstraintsInfo ) ) ); - if ( result != VULKAN_HPP_NAMESPACE::Result::eSuccess ) - { - throwResultException( result, VULKAN_HPP_NAMESPACE_STRING "::BufferCollectionFUCHSIA::setBufferConstraints" ); - } + reinterpret_cast( &bufferConstraintsInfo ) ); + resultCheck( static_cast( result ), VULKAN_HPP_NAMESPACE_STRING "::BufferCollectionFUCHSIA::setBufferConstraints" ); } VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::BufferCollectionPropertiesFUCHSIA BufferCollectionFUCHSIA::getProperties() const @@ -17332,6 +17214,7 @@ namespace VULKAN_HPP_NAMESPACE VkBool32 result = getDispatcher()->vkGetPhysicalDeviceScreenPresentationSupportQNX( static_cast( m_physicalDevice ), queueFamilyIndex, &window ); + return static_cast( result ); } # endif /*VK_USE_PLATFORM_SCREEN_QNX*/ @@ -17414,6 +17297,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDeviceBufferMemoryRequirementsKHR( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -17441,6 +17325,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDeviceImageMemoryRequirementsKHR( static_cast( m_device ), reinterpret_cast( &info ), reinterpret_cast( &memoryRequirements ) ); + return memoryRequirements; } @@ -17487,6 +17372,7 @@ namespace VULKAN_HPP_NAMESPACE getDispatcher()->vkGetDescriptorSetLayoutHostMappingInfoVALVE( static_cast( m_device ), reinterpret_cast( &bindingReference ), reinterpret_cast( &hostMapping ) ); + return hostMapping; } @@ -17497,6 +17383,7 @@ namespace VULKAN_HPP_NAMESPACE void * pData; getDispatcher()->vkGetDescriptorSetHostMappingVALVE( static_cast( m_device ), static_cast( m_descriptorSet ), &pData ); + return pData; } diff --git a/vulkan/vulkan_structs.hpp b/vulkan/vulkan_structs.hpp index 974f0f3..09f3305 100644 --- a/vulkan/vulkan_structs.hpp +++ b/vulkan/vulkan_structs.hpp @@ -2611,10 +2611,10 @@ namespace VULKAN_HPP_NAMESPACE public: VULKAN_HPP_NAMESPACE::TransformMatrixKHR transform = {}; - uint32_t instanceCustomIndex : 24; - uint32_t mask : 8; + uint32_t instanceCustomIndex : 24; + uint32_t mask : 8; uint32_t instanceShaderBindingTableRecordOffset : 24; - VkGeometryInstanceFlagsKHR flags : 8; + VkGeometryInstanceFlagsKHR flags : 8; uint64_t accelerationStructureReference = {}; }; VULKAN_HPP_STATIC_ASSERT( sizeof( VULKAN_HPP_NAMESPACE::AccelerationStructureInstanceKHR ) == sizeof( VkAccelerationStructureInstanceKHR ), @@ -2763,10 +2763,10 @@ namespace VULKAN_HPP_NAMESPACE public: VULKAN_HPP_NAMESPACE::TransformMatrixKHR transformT0 = {}; VULKAN_HPP_NAMESPACE::TransformMatrixKHR transformT1 = {}; - uint32_t instanceCustomIndex : 24; - uint32_t mask : 8; + uint32_t instanceCustomIndex : 24; + uint32_t mask : 8; uint32_t instanceShaderBindingTableRecordOffset : 24; - VkGeometryInstanceFlagsKHR flags : 8; + VkGeometryInstanceFlagsKHR flags : 8; uint64_t accelerationStructureReference = {}; }; VULKAN_HPP_STATIC_ASSERT( sizeof( VULKAN_HPP_NAMESPACE::AccelerationStructureMatrixMotionInstanceNV ) == @@ -3380,10 +3380,10 @@ namespace VULKAN_HPP_NAMESPACE public: VULKAN_HPP_NAMESPACE::SRTDataNV transformT0 = {}; VULKAN_HPP_NAMESPACE::SRTDataNV transformT1 = {}; - uint32_t instanceCustomIndex : 24; - uint32_t mask : 8; + uint32_t instanceCustomIndex : 24; + uint32_t mask : 8; uint32_t instanceShaderBindingTableRecordOffset : 24; - VkGeometryInstanceFlagsKHR flags : 8; + VkGeometryInstanceFlagsKHR flags : 8; uint64_t accelerationStructureReference = {}; }; VULKAN_HPP_STATIC_ASSERT( sizeof( VULKAN_HPP_NAMESPACE::AccelerationStructureSRTMotionInstanceNV ) == sizeof( VkAccelerationStructureSRTMotionInstanceNV ),