Merge pull request #1008 from asuessenbach/protect

Add support of attribute "protect" for enum values, third part
This commit is contained in:
Andreas Süßenbach 2021-06-30 17:01:02 +02:00 committed by GitHub
commit a90db8ad9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 56 additions and 81 deletions

View File

@ -957,7 +957,7 @@ void VulkanHppGenerator::appendDispatchLoaderDynamicCommand( std::string &
CommandData const & commandData ) CommandData const & commandData )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( commandData.referencedIn ); std::tie( enter, leave ) = generateProtection( commandData.referencedIn, std::string() );
std::string command = " PFN_" + commandName + " " + commandName + " = 0;\n"; std::string command = " PFN_" + commandName + " " + commandName + " = 0;\n";
if ( !enter.empty() ) if ( !enter.empty() )
{ {
@ -1023,16 +1023,7 @@ void VulkanHppGenerator::appendEnum( std::string & str, std::pair<std::string, E
for ( auto const & value : enumData.second.values ) for ( auto const & value : enumData.second.values )
{ {
std::string enter, leave; std::string enter, leave;
if ( !value.extension.empty() ) std::tie( enter, leave ) = generateProtection( value.extension, value.protect );
{
assert( value.protect.empty() );
std::tie( enter, leave ) = generateProtection( value.extension );
}
else if ( !value.protect.empty() )
{
enter = "#if defined( " + value.protect + " )\n";
leave = "#endif /*" + value.protect + "*/\n";
}
if ( previousEnter != enter ) if ( previousEnter != enter )
{ {
enumList += previousLeave + enter; enumList += previousLeave + enter;
@ -1077,7 +1068,7 @@ void VulkanHppGenerator::appendEnum( std::string & str, std::pair<std::string, E
[&aliasIt]( EnumValueData const & evd ) { return aliasIt->second.name == evd.name; } ); [&aliasIt]( EnumValueData const & evd ) { return aliasIt->second.name == evd.name; } );
} }
assert( enumIt != enumData.second.values.end() ); assert( enumIt != enumData.second.values.end() );
assert( enumIt->extension.empty() || generateProtection( enumIt->extension ).first.empty() ); assert( enumIt->extension.empty() || generateProtection( enumIt->extension, enumIt->protect ).first.empty() );
#endif #endif
enumList += " " + aliasName + " = " + alias.first + ",\n"; enumList += " " + aliasName + " = " + alias.first + ",\n";
@ -1249,16 +1240,7 @@ void VulkanHppGenerator::appendEnumToString( std::string &
for ( auto const & value : enumData.second.values ) for ( auto const & value : enumData.second.values )
{ {
std::string enter, leave; std::string enter, leave;
if ( !value.extension.empty() ) std::tie( enter, leave ) = generateProtection( value.extension, value.protect );
{
assert( value.protect.empty() );
std::tie( enter, leave ) = generateProtection( value.extension );
}
else if ( !value.protect.empty() )
{
enter = "#if defined( " + value.protect + " )\n";
leave = "#endif /*" + value.protect + "*/\n";
}
if ( previousEnter != enter ) if ( previousEnter != enter )
{ {
str += previousLeave + enter; str += previousLeave + enter;
@ -1628,7 +1610,7 @@ void VulkanHppGenerator::appendHandle( std::string & str, std::pair<std::string,
if ( !commandNames.empty() ) if ( !commandNames.empty() )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( extIt.second->first ); std::tie( enter, leave ) = generateProtection( extIt.second->first, std::string() );
commands += "\n" + enter + " //=== " + extIt.second->first + " ===\n"; commands += "\n" + enter + " //=== " + extIt.second->first + " ===\n";
for ( auto const & command : commandNames ) for ( auto const & command : commandNames )
{ {
@ -1855,7 +1837,7 @@ void VulkanHppGenerator::appendHandlesCommandDefinitions( std::string & str ) co
if ( !extIt.second->second.commands.empty() ) if ( !extIt.second->second.commands.empty() )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( extIt.second->first ); std::tie( enter, leave ) = generateProtection( extIt.second->first, std::string() );
str += "\n" + enter + " //=== " + extIt.second->first + " ===\n"; str += "\n" + enter + " //=== " + extIt.second->first + " ===\n";
for ( auto const & command : extIt.second->second.commands ) for ( auto const & command : extIt.second->second.commands )
{ {
@ -1937,7 +1919,7 @@ void VulkanHppGenerator::appendRAIICommands( std::string & str, std::set<std::st
if ( !commands.empty() ) if ( !commands.empty() )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( extIt.second->first ); std::tie( enter, leave ) = generateProtection( extIt.second->first, std::string() );
str += "\n" + enter + " //=== " + extIt.second->first + " ===\n"; str += "\n" + enter + " //=== " + extIt.second->first + " ===\n";
for ( auto const & command : commands ) for ( auto const & command : commands )
{ {
@ -1957,7 +1939,7 @@ void VulkanHppGenerator::appendRAIIDispatchers( std::string & str ) const
for ( auto const & command : m_commands ) for ( auto const & command : m_commands )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( command.second.referencedIn ); std::tie( enter, leave ) = generateProtection( command.second.referencedIn, std::string() );
if ( command.second.handle.empty() ) if ( command.second.handle.empty() )
{ {
@ -2105,7 +2087,7 @@ ${leave})";
if ( beginsWith( value.name, "VK_ERROR" ) ) if ( beginsWith( value.name, "VK_ERROR" ) )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( value.extension ); std::tie( enter, leave ) = generateProtection( value.extension, value.protect );
std::string valueName = generateEnumValueName( enumIt->first, value.name, false, m_tags ); std::string valueName = generateEnumValueName( enumIt->first, value.name, false, m_tags );
str += replaceWithMap( templateString, str += replaceWithMap( templateString,
{ { "className", stripPrefix( valueName, "eError" ) + "Error" }, { { "className", stripPrefix( valueName, "eError" ) + "Error" },
@ -5862,7 +5844,8 @@ std::pair<std::string, std::string>
// check for additional enter/leave guards for the constructors // check for additional enter/leave guards for the constructors
std::string constructorEnter, constructorLeave; std::string constructorEnter, constructorLeave;
std::tie( constructorEnter, constructorLeave ) = generateProtection( constructorIt->second.referencedIn ); std::tie( constructorEnter, constructorLeave ) =
generateProtection( constructorIt->second.referencedIn, std::string() );
if ( constructorEnter == enter ) if ( constructorEnter == enter )
{ {
constructorEnter.clear(); constructorEnter.clear();
@ -6048,7 +6031,7 @@ std::pair<std::string, std::string>
std::string const & enter ) const std::string const & enter ) const
{ {
std::string destructorEnter, destructorLeave; std::string destructorEnter, destructorLeave;
std::tie( destructorEnter, destructorLeave ) = generateProtection( destructorIt->second.referencedIn ); std::tie( destructorEnter, destructorLeave ) = generateProtection( destructorIt->second.referencedIn, std::string() );
bool doProtect = !destructorEnter.empty() && ( destructorEnter != enter ); bool doProtect = !destructorEnter.empty() && ( destructorEnter != enter );
if ( !doProtect ) if ( !doProtect )
{ {
@ -6467,7 +6450,7 @@ std::pair<std::string, std::string> VulkanHppGenerator::constructRAIIHandleMembe
std::string commandName = generateCommandName( std::string commandName = generateCommandName(
commandIt->first, initialSkipCount ? commandIt->second.params[initialSkipCount - 1].type.type : "", m_tags ); commandIt->first, initialSkipCount ? commandIt->second.params[initialSkipCount - 1].type.type : "", m_tags );
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( commandIt->second.referencedIn ); std::tie( enter, leave ) = generateProtection( commandIt->second.referencedIn, std::string() );
std::string callArguments = constructCallArgumentsEnhanced( std::string callArguments = constructCallArgumentsEnhanced(
commandIt->second.params, initialSkipCount, false, {}, nonConstPointerParamIndices, true ); commandIt->second.params, initialSkipCount, false, {}, nonConstPointerParamIndices, true );
std::string firstReturnName = std::string firstReturnName =
@ -7451,7 +7434,7 @@ std::pair<std::string, std::string> VulkanHppGenerator::constructRAIIHandleMembe
std::string commandName = std::string commandName =
generateCommandName( commandIt->first, commandIt->second.params[initialSkipCount - 1].type.type, m_tags ); generateCommandName( commandIt->first, commandIt->second.params[initialSkipCount - 1].type.type, m_tags );
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( commandIt->second.referencedIn ); std::tie( enter, leave ) = generateProtection( commandIt->second.referencedIn, std::string() );
std::string returnType = stripPostfix( commandIt->second.params[nonConstPointerParamIndices[0]].type.compose(), "*" ); std::string returnType = stripPostfix( commandIt->second.params[nonConstPointerParamIndices[0]].type.compose(), "*" );
std::pair<bool, std::map<size_t, std::vector<size_t>>> vectorSizeCheck = needsVectorSizeCheck( vectorParamIndices ); std::pair<bool, std::map<size_t, std::vector<size_t>>> vectorSizeCheck = needsVectorSizeCheck( vectorParamIndices );
std::string noexceptString = vectorSizeCheck.first ? "VULKAN_HPP_NOEXCEPT_WHEN_NO_EXCEPTIONS" : "VULKAN_HPP_NOEXCEPT"; std::string noexceptString = vectorSizeCheck.first ? "VULKAN_HPP_NOEXCEPT_WHEN_NO_EXCEPTIONS" : "VULKAN_HPP_NOEXCEPT";
@ -7846,7 +7829,7 @@ std::string VulkanHppGenerator::constructRAIIHandleMemberFunctionDeclarations(
std::string enter, leave; std::string enter, leave;
if ( extIt.second->first != m_types.find( handle.first )->second.referencedIn ) if ( extIt.second->first != m_types.find( handle.first )->second.referencedIn )
{ {
std::tie( enter, leave ) = generateProtection( extIt.second->first ); std::tie( enter, leave ) = generateProtection( extIt.second->first, std::string() );
} }
functionDeclarations += "\n" + enter + " //=== " + extIt.second->first + " ===\n"; functionDeclarations += "\n" + enter + " //=== " + extIt.second->first + " ===\n";
for ( auto const & command : firstLevelCommands ) for ( auto const & command : firstLevelCommands )
@ -9366,7 +9349,7 @@ void VulkanHppGenerator::appendThrowExceptions( std::string & str ) const
if ( beginsWith( value.name, "VK_ERROR" ) ) if ( beginsWith( value.name, "VK_ERROR" ) )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( value.extension ); std::tie( enter, leave ) = generateProtection( value.extension, value.protect );
std::string valueName = generateEnumValueName( enumIt->first, value.name, false, m_tags ); std::string valueName = generateEnumValueName( enumIt->first, value.name, false, m_tags );
str += enter + " case Result::" + valueName + ": throw " + stripPrefix( valueName, "eError" ) + str += enter + " case Result::" + valueName + ": throw " + stripPrefix( valueName, "eError" ) +
"Error( message );\n" + leave; "Error( message );\n" + leave;
@ -10664,7 +10647,7 @@ std::string VulkanHppGenerator::generateDispatchLoaderStatic()
std::string referencedIn = commandIt->second.referencedIn; std::string referencedIn = commandIt->second.referencedIn;
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( referencedIn ); std::tie( enter, leave ) = generateProtection( referencedIn, std::string() );
str += "\n" + enter + " //=== " + extIt.second->first + " ===\n"; str += "\n" + enter + " //=== " + extIt.second->first + " ===\n";
for ( auto const & commandName : extIt.second->second.commands ) for ( auto const & commandName : extIt.second->second.commands )
{ {
@ -10740,14 +10723,14 @@ std::string VulkanHppGenerator::generateBitmask( std::map<std::string, BitmaskDa
for ( auto const & value : bitmaskBits->second.values ) for ( auto const & value : bitmaskBits->second.values )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( value.extension ); std::tie( enter, leave ) = generateProtection( value.extension, value.protect );
std::string valueName = generateEnumValueName( bitmaskBits->first, value.name, true, m_tags ); std::string valueName = generateEnumValueName( bitmaskBits->first, value.name, true, m_tags );
allFlags += ( ( previousEnter != enter ) ? ( "\n" + previousLeave + enter ) : "\n" ) + " " + allFlags += ( ( previousEnter != enter ) ? ( "\n" + previousLeave + enter ) : "\n" ) + " " +
( encounteredFlag ? "| " : " " ) + bitmaskIt->second.type + "( " + strippedEnumName + ( encounteredFlag ? "| " : " " ) + bitmaskIt->second.type + "( " + strippedEnumName +
"::" + valueName + " )"; "::" + valueName + " )";
encounteredFlag = true; encounteredFlag = true;
previousEnter = enter; previousEnter = enter;
previousLeave = leave; previousLeave = leave;
} }
if ( !previousLeave.empty() ) if ( !previousLeave.empty() )
{ {
@ -10819,17 +10802,30 @@ std::string VulkanHppGenerator::generateBitmask( std::map<std::string, BitmaskDa
str += str +=
" if ( !value ) return \"{}\";\n\n" " if ( !value ) return \"{}\";\n\n"
" std::string result;\n"; " std::string result;\n";
std::string previousEnter, previousLeave;
for ( auto const & evd : bitmaskBits->second.values ) for ( auto const & evd : bitmaskBits->second.values )
{ {
if ( evd.singleBit ) if ( evd.singleBit )
{ {
std::string enter, leave; std::string enter, leave;
std::tie( enter, leave ) = generateProtection( evd.extension ); std::tie( enter, leave ) = generateProtection( evd.extension, evd.protect );
std::string valueName = generateEnumValueName( bitmaskBits->first, evd.name, true, m_tags ); std::string valueName = generateEnumValueName( bitmaskBits->first, evd.name, true, m_tags );
str += enter + " if ( value & " + strippedEnumName + "::" + valueName + " ) result += \"" + if ( previousEnter != enter )
valueName.substr( 1 ) + " | \";\n" + leave; {
str += previousLeave + enter;
}
str += " if ( value & " + strippedEnumName + "::" + valueName + " ) result += \"" + valueName.substr( 1 ) +
" | \";\n";
previousEnter = enter;
previousLeave = leave;
} }
} }
if ( !previousLeave.empty() )
{
assert( endsWith( previousLeave, "\n" ) );
previousLeave.resize( previousLeave.size() - strlen( "\n" ) );
str += previousLeave + "\n";
}
str += " return \"{ \" + result.substr(0, result.size() - 3) + \" }\";\n"; str += " return \"{ \" + result.substr(0, result.size() - 3) + \" }\";\n";
} }
@ -12001,23 +11997,32 @@ std::string VulkanHppGenerator::generateLenInitializer(
return initializer; return initializer;
} }
std::pair<std::string, std::string> VulkanHppGenerator::generateProtection( std::string const & referencedIn ) const std::pair<std::string, std::string> VulkanHppGenerator::generateProtection( std::string const & referencedIn,
std::string const & protect ) const
{ {
if ( !referencedIn.empty() && m_features.find( referencedIn ) == m_features.end() ) if ( !referencedIn.empty() )
{ {
auto extensionIt = m_extensions.find( referencedIn ); assert( protect.empty() );
assert( extensionIt != m_extensions.end() ); if ( m_features.find( referencedIn ) == m_features.end() )
if ( !extensionIt->second.platform.empty() )
{ {
auto platformIt = m_platforms.find( extensionIt->second.platform ); auto extensionIt = m_extensions.find( referencedIn );
assert( platformIt != m_platforms.end() ); assert( extensionIt != m_extensions.end() );
std::string const & protect = platformIt->second.protect; if ( !extensionIt->second.platform.empty() )
if ( !protect.empty() )
{ {
return std::make_pair( "#if defined( " + protect + " )\n", "#endif /*" + protect + "*/\n" ); auto platformIt = m_platforms.find( extensionIt->second.platform );
assert( platformIt != m_platforms.end() );
if ( !platformIt->second.protect.empty() )
{
return std::make_pair( "#if defined( " + platformIt->second.protect + " )\n",
"#endif /*" + platformIt->second.protect + "*/\n" );
}
} }
} }
} }
else if ( !protect.empty() )
{
return std::make_pair( "#if defined( " + protect + " )\n", "#endif /*" + protect + "*/\n" );
}
return std::make_pair( "", "" ); return std::make_pair( "", "" );
} }
@ -12032,7 +12037,7 @@ std::pair<std::string, std::string> VulkanHppGenerator::generateProtection( std:
{ {
auto typeIt = m_types.find( type ); auto typeIt = m_types.find( type );
assert( typeIt != m_types.end() ); assert( typeIt != m_types.end() );
return generateProtection( typeIt->second.referencedIn ); return generateProtection( typeIt->second.referencedIn, std::string() );
} }
} }

View File

@ -1065,7 +1065,7 @@ private:
std::map<std::vector<MemberData>::const_iterator, std::map<std::vector<MemberData>::const_iterator,
std::vector<std::vector<MemberData>::const_iterator>>::const_iterator litit, std::vector<std::vector<MemberData>::const_iterator>>::const_iterator litit,
bool mutualExclusiveLens ) const; bool mutualExclusiveLens ) const;
std::pair<std::string, std::string> generateProtection( std::string const & referencedIn ) const; std::pair<std::string, std::string> generateProtection( std::string const & referencedIn, std::string const & protect ) const;
std::pair<std::string, std::string> generateProtection( std::string const & type, bool isAliased ) const; std::pair<std::string, std::string> generateProtection( std::string const & type, bool isAliased ) const;
std::string generateSizeCheck( std::vector<std::vector<MemberData>::const_iterator> const & arrayIts, std::string generateSizeCheck( std::vector<std::vector<MemberData>::const_iterator> const & arrayIts,
std::string const & structName, std::string const & structName,

View File

@ -8014,8 +8014,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & FormatFeatureFlagBits::eVideoDecodeOutputKHR ) if ( value & FormatFeatureFlagBits::eVideoDecodeOutputKHR )
result += "VideoDecodeOutputKHR | "; result += "VideoDecodeOutputKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & FormatFeatureFlagBits::eVideoDecodeDpbKHR ) if ( value & FormatFeatureFlagBits::eVideoDecodeDpbKHR )
result += "VideoDecodeDpbKHR | "; result += "VideoDecodeDpbKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -8028,8 +8026,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & FormatFeatureFlagBits::eVideoEncodeInputKHR ) if ( value & FormatFeatureFlagBits::eVideoEncodeInputKHR )
result += "VideoEncodeInputKHR | "; result += "VideoEncodeInputKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & FormatFeatureFlagBits::eVideoEncodeDpbKHR ) if ( value & FormatFeatureFlagBits::eVideoEncodeDpbKHR )
result += "VideoEncodeDpbKHR | "; result += "VideoEncodeDpbKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -8191,12 +8187,8 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoDecodeDstKHR ) if ( value & ImageUsageFlagBits::eVideoDecodeDstKHR )
result += "VideoDecodeDstKHR | "; result += "VideoDecodeDstKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoDecodeSrcKHR ) if ( value & ImageUsageFlagBits::eVideoDecodeSrcKHR )
result += "VideoDecodeSrcKHR | "; result += "VideoDecodeSrcKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoDecodeDpbKHR ) if ( value & ImageUsageFlagBits::eVideoDecodeDpbKHR )
result += "VideoDecodeDpbKHR | "; result += "VideoDecodeDpbKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -8207,12 +8199,8 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoEncodeDstKHR ) if ( value & ImageUsageFlagBits::eVideoEncodeDstKHR )
result += "VideoEncodeDstKHR | "; result += "VideoEncodeDstKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoEncodeSrcKHR ) if ( value & ImageUsageFlagBits::eVideoEncodeSrcKHR )
result += "VideoEncodeSrcKHR | "; result += "VideoEncodeSrcKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & ImageUsageFlagBits::eVideoEncodeDpbKHR ) if ( value & ImageUsageFlagBits::eVideoEncodeDpbKHR )
result += "VideoEncodeDpbKHR | "; result += "VideoEncodeDpbKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -8395,8 +8383,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & QueueFlagBits::eVideoDecodeKHR ) if ( value & QueueFlagBits::eVideoDecodeKHR )
result += "VideoDecodeKHR | "; result += "VideoDecodeKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & QueueFlagBits::eVideoEncodeKHR ) if ( value & QueueFlagBits::eVideoEncodeKHR )
result += "VideoEncodeKHR | "; result += "VideoEncodeKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -9176,8 +9162,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & BufferUsageFlagBits::eVideoDecodeSrcKHR ) if ( value & BufferUsageFlagBits::eVideoDecodeSrcKHR )
result += "VideoDecodeSrcKHR | "; result += "VideoDecodeSrcKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & BufferUsageFlagBits::eVideoDecodeDstKHR ) if ( value & BufferUsageFlagBits::eVideoDecodeDstKHR )
result += "VideoDecodeDstKHR | "; result += "VideoDecodeDstKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -9196,8 +9180,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & BufferUsageFlagBits::eVideoEncodeDstKHR ) if ( value & BufferUsageFlagBits::eVideoEncodeDstKHR )
result += "VideoEncodeDstKHR | "; result += "VideoEncodeDstKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & BufferUsageFlagBits::eVideoEncodeSrcKHR ) if ( value & BufferUsageFlagBits::eVideoEncodeSrcKHR )
result += "VideoEncodeSrcKHR | "; result += "VideoEncodeSrcKHR | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -11810,12 +11792,8 @@ namespace VULKAN_HPP_NAMESPACE
# if defined( VK_ENABLE_BETA_EXTENSIONS ) # if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & VideoCodecOperationFlagBitsKHR::eEncodeH264EXT ) if ( value & VideoCodecOperationFlagBitsKHR::eEncodeH264EXT )
result += "EncodeH264EXT | "; result += "EncodeH264EXT | ";
# endif /*VK_ENABLE_BETA_EXTENSIONS*/
# if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & VideoCodecOperationFlagBitsKHR::eDecodeH264EXT ) if ( value & VideoCodecOperationFlagBitsKHR::eDecodeH264EXT )
result += "DecodeH264EXT | "; result += "DecodeH264EXT | ";
# endif /*VK_ENABLE_BETA_EXTENSIONS*/
# if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & VideoCodecOperationFlagBitsKHR::eDecodeH265EXT ) if ( value & VideoCodecOperationFlagBitsKHR::eDecodeH265EXT )
result += "DecodeH265EXT | "; result += "DecodeH265EXT | ";
# endif /*VK_ENABLE_BETA_EXTENSIONS*/ # endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -13830,8 +13808,6 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & PipelineStageFlagBits2KHR::eVideoDecode ) if ( value & PipelineStageFlagBits2KHR::eVideoDecode )
result += "VideoDecode | "; result += "VideoDecode | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & PipelineStageFlagBits2KHR::eVideoEncode ) if ( value & PipelineStageFlagBits2KHR::eVideoEncode )
result += "VideoEncode | "; result += "VideoEncode | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/
@ -13967,16 +13943,10 @@ namespace VULKAN_HPP_NAMESPACE
#if defined( VK_ENABLE_BETA_EXTENSIONS ) #if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & AccessFlagBits2KHR::eVideoDecodeRead ) if ( value & AccessFlagBits2KHR::eVideoDecodeRead )
result += "VideoDecodeRead | "; result += "VideoDecodeRead | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & AccessFlagBits2KHR::eVideoDecodeWrite ) if ( value & AccessFlagBits2KHR::eVideoDecodeWrite )
result += "VideoDecodeWrite | "; result += "VideoDecodeWrite | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & AccessFlagBits2KHR::eVideoEncodeRead ) if ( value & AccessFlagBits2KHR::eVideoEncodeRead )
result += "VideoEncodeRead | "; result += "VideoEncodeRead | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/
#if defined( VK_ENABLE_BETA_EXTENSIONS )
if ( value & AccessFlagBits2KHR::eVideoEncodeWrite ) if ( value & AccessFlagBits2KHR::eVideoEncodeWrite )
result += "VideoEncodeWrite | "; result += "VideoEncodeWrite | ";
#endif /*VK_ENABLE_BETA_EXTENSIONS*/ #endif /*VK_ENABLE_BETA_EXTENSIONS*/