diff --git a/RAII_Samples/PhysicalDeviceProperties/PhysicalDeviceProperties.cpp b/RAII_Samples/PhysicalDeviceProperties/PhysicalDeviceProperties.cpp index 94e665e..f86cc65 100644 --- a/RAII_Samples/PhysicalDeviceProperties/PhysicalDeviceProperties.cpp +++ b/RAII_Samples/PhysicalDeviceProperties/PhysicalDeviceProperties.cpp @@ -36,7 +36,7 @@ std::string decodeDriverVersion( uint32_t driverVersion, uint32_t vendorID ) { switch ( vendorID ) { - case 4318: + case 0x10DE: return std::to_string( ( driverVersion >> 22 ) & 0x3FF ) + "." + std::to_string( ( driverVersion >> 14 ) & 0xFF ) + "." + std::to_string( ( driverVersion >> 6 ) & 0xFF ) + "." + std::to_string( driverVersion & 0x3F ); case 0x8086: return std::to_string( ( driverVersion >> 14 ) & 0x3FFFF ) + "." + std::to_string( ( driverVersion & 0x3FFF ) ); diff --git a/VulkanHppGenerator.cpp b/VulkanHppGenerator.cpp index 0b974dd..de34d39 100644 --- a/VulkanHppGenerator.cpp +++ b/VulkanHppGenerator.cpp @@ -4710,18 +4710,25 @@ std::string VulkanHppGenerator::generateCommandVoid1Return( } else if ( commandData.params[returnParam].type.type == "void" ) { - if ( vectorParams.size() == 1 ) + switch ( vectorParams.size() ) { - if ( returnParam == vectorParams.begin()->first ) - { - if ( name == stripPluralS( name ) ) + case 0: + return generateCommandSetStandardEnhanced( + definition, + generateCommandStandard( name, commandData, initialSkipCount, definition ), + generateCommandEnhanced( name, commandData, initialSkipCount, definition, vectorParams, { returnParam }, false, false, false, false ) ); + case 1: + if ( returnParam == vectorParams.begin()->first ) { - return generateCommandSetStandardEnhanced( - definition, - generateCommandStandard( name, commandData, initialSkipCount, definition ), - generateCommandEnhanced( name, commandData, initialSkipCount, definition, vectorParams, { returnParam }, true, false, false, false ) ); + if ( name == stripPluralS( name ) ) + { + return generateCommandSetStandardEnhanced( + definition, + generateCommandStandard( name, commandData, initialSkipCount, definition ), + generateCommandEnhanced( name, commandData, initialSkipCount, definition, vectorParams, { returnParam }, true, false, false, false ) ); + } } - } + break; } } else @@ -7057,15 +7064,18 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandVoid( std::mapsecond.params[returnParams[0]].type.type == "void" ) { - if ( vectorParams.size() == 1 ) + switch ( vectorParams.size() ) { - if ( returnParams[0] == vectorParams.begin()->first ) - { - if ( commandIt->first == stripPluralS( commandIt->first ) ) + case 0: str = generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, returnParams, vectorParams, definition, false, false ); break; + case 1: + if ( returnParams[0] == vectorParams.begin()->first ) { - str = generateRAIIHandleCommandVoid1ReturnVoidVectorSingular( commandIt, initialSkipCount, vectorParams, returnParams[0], definition ); + if ( commandIt->first == stripPluralS( commandIt->first ) ) + { + str = generateRAIIHandleCommandVoid1ReturnVoidVectorSingular( commandIt, initialSkipCount, vectorParams, returnParams[0], definition ); + } } - } + break; } } else