mirror of
https://github.com/KhronosGroup/Vulkan-Hpp.git
synced 2024-10-14 16:32:17 +00:00
Combine two types of commands into one generation function
This commit is contained in:
parent
0506a95686
commit
3f240ea665
@ -2045,24 +2045,16 @@ size_t VulkanHppGenerator::determineDefaultStartIndex( std::vector<ParamData> co
|
||||
return defaultStartIndex;
|
||||
}
|
||||
|
||||
bool VulkanHppGenerator::determineEnumeration( std::map<size_t, size_t> const & vectorParams,
|
||||
std::vector<size_t> const & returnParams
|
||||
#if !defined( NDEBUG )
|
||||
,
|
||||
std::vector<std::string> const & successCodes
|
||||
#endif
|
||||
) const
|
||||
bool VulkanHppGenerator::determineEnumeration( std::map<size_t, size_t> const & vectorParams, std::vector<size_t> const & returnParams ) const
|
||||
{
|
||||
// a command is considered to be enumerating some data, if for at least one vectorParam both, the data and the counter, are returnParams
|
||||
bool enumerating = std::find_if( vectorParams.begin(),
|
||||
vectorParams.end(),
|
||||
[&returnParams]( std::pair<size_t, size_t> const & vp )
|
||||
{
|
||||
return std::find( returnParams.begin(), returnParams.end(), vp.first ) != returnParams.end() &&
|
||||
std::find( returnParams.begin(), returnParams.end(), vp.second ) != returnParams.end();
|
||||
} ) != vectorParams.end();
|
||||
assert( !enumerating || successCodes.empty() || ( ( successCodes.size() == 2 ) && ( successCodes[1] == "VK_INCOMPLETE" ) ) );
|
||||
return enumerating;
|
||||
return std::find_if( vectorParams.begin(),
|
||||
vectorParams.end(),
|
||||
[&returnParams]( std::pair<size_t, size_t> const & vp )
|
||||
{
|
||||
return std::find( returnParams.begin(), returnParams.end(), vp.first ) != returnParams.end() &&
|
||||
std::find( returnParams.begin(), returnParams.end(), vp.second ) != returnParams.end();
|
||||
} ) != vectorParams.end();
|
||||
}
|
||||
|
||||
size_t VulkanHppGenerator::determineInitialSkipCount( std::string const & command ) const
|
||||
@ -3125,8 +3117,10 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
size_t initialSkipCount,
|
||||
std::set<size_t> const & singularParams,
|
||||
std::set<size_t> const & templatedParams,
|
||||
bool chained ) const
|
||||
bool chained,
|
||||
bool raii ) const
|
||||
{
|
||||
std::string dispatcher = raii ? "getDispatcher()->" : "d.";
|
||||
// if at least one returnParam is a size value of a vector param (and no singular params), we need two calls
|
||||
if ( singularParams.empty() &&
|
||||
( std::find_if( returnParams.begin(),
|
||||
@ -3155,7 +3149,7 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
const std::string callSequenceTemplate = R"(VkResult result;
|
||||
do
|
||||
{
|
||||
result = d.${vkCommand}( ${firstCallArguments} );
|
||||
result = ${dispatcher}${vkCommand}( ${firstCallArguments} );
|
||||
if ( ( result == VK_SUCCESS ) && ${counterName} )
|
||||
{
|
||||
structureChains.resize( ${counterName} );
|
||||
@ -3164,13 +3158,14 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
{
|
||||
${vectorName}[i].pNext = structureChains[i].template get<${vectorElementType}>().pNext;
|
||||
}
|
||||
result = d.${vkCommand}( ${secondCallArguments} );
|
||||
result = ${dispatcher}${vkCommand}( ${secondCallArguments} );
|
||||
}
|
||||
} while ( result == VK_INCOMPLETE );)";
|
||||
|
||||
return replaceWithMap( callSequenceTemplate,
|
||||
{ { "counterName", startLowerCase( stripPrefix( commandData.params[vectorParamIt->second].name, "p" ) ) },
|
||||
{ "counterType", commandData.params[vectorParamIt->second].type.type },
|
||||
{ "dispatcher", dispatcher },
|
||||
{ "firstCallArguments", firstCallArguments },
|
||||
{ "secondCallArguments", secondCallArguments },
|
||||
{ "vectorElementType", vectorElementType },
|
||||
@ -3180,18 +3175,19 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
else
|
||||
{
|
||||
const std::string callSequenceTemplate =
|
||||
R"(d.${vkCommand}( ${firstCallArguments} );
|
||||
R"(${dispatcher}${vkCommand}( ${firstCallArguments} );
|
||||
structureChains.resize( ${counterName} );
|
||||
${vectorName}.resize( ${counterName} );
|
||||
for ( ${counterType} i = 0; i < ${counterName}; i++ )
|
||||
{
|
||||
${vectorName}[i].pNext = structureChains[i].template get<${vectorElementType}>().pNext;
|
||||
}
|
||||
d.${vkCommand}( ${secondCallArguments} );)";
|
||||
${dispatcher}${vkCommand}( ${secondCallArguments} );)";
|
||||
|
||||
return replaceWithMap( callSequenceTemplate,
|
||||
{ { "counterName", startLowerCase( stripPrefix( commandData.params[vectorParamIt->second].name, "p" ) ) },
|
||||
{ "counterType", commandData.params[vectorParamIt->second].type.type },
|
||||
{ "dispatcher", dispatcher },
|
||||
{ "firstCallArguments", firstCallArguments },
|
||||
{ "secondCallArguments", secondCallArguments },
|
||||
{ "vectorElementType", vectorElementType },
|
||||
@ -3217,16 +3213,17 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
std::string const callSequenceTemplate = R"(VkResult result;
|
||||
do
|
||||
{
|
||||
result = d.${vkCommand}( ${firstCallArguments} );
|
||||
result = ${dispatcher}${vkCommand}( ${firstCallArguments} );
|
||||
if ( ( result == VK_SUCCESS ) && ${counterName} )
|
||||
{
|
||||
${resizes}
|
||||
result = d.${vkCommand}( ${secondCallArguments} );
|
||||
result = ${dispatcher}${vkCommand}( ${secondCallArguments} );
|
||||
}
|
||||
} while ( result == VK_INCOMPLETE );)";
|
||||
|
||||
return replaceWithMap( callSequenceTemplate,
|
||||
{ { "counterName", startLowerCase( stripPrefix( commandData.params[vectorParamIt->second].name, "p" ) ) },
|
||||
{ "dispatcher", dispatcher },
|
||||
{ "firstCallArguments", firstCallArguments },
|
||||
{ "secondCallArguments", secondCallArguments },
|
||||
{ "resizes", resizes },
|
||||
@ -3236,12 +3233,13 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
{
|
||||
// no need to enumerate here, just two calls
|
||||
assert( commandData.returnType == "void" );
|
||||
std::string const callSequenceTemplate = R"(d.${vkCommand}( ${firstCallArguments} );
|
||||
std::string const callSequenceTemplate = R"(${dispatcher}${vkCommand}( ${firstCallArguments} );
|
||||
${vectorName}.resize( ${vectorSize} );
|
||||
d.${vkCommand}( ${secondCallArguments} );)";
|
||||
${dispatcher}${vkCommand}( ${secondCallArguments} );)";
|
||||
|
||||
return replaceWithMap( callSequenceTemplate,
|
||||
{ { "firstCallArguments", firstCallArguments },
|
||||
{ { "dispatcher", dispatcher },
|
||||
{ "firstCallArguments", firstCallArguments },
|
||||
{ "secondCallArguments", secondCallArguments },
|
||||
{ "vectorName", vectorName },
|
||||
{ "vectorSize", vectorSize },
|
||||
@ -3250,12 +3248,14 @@ std::string VulkanHppGenerator::generateCallSequence( std::string const &
|
||||
}
|
||||
else
|
||||
{
|
||||
std::string const callSequenceTemplate = R"(${resultAssignment}d.${vkCommand}( ${callArguments} );)";
|
||||
std::string const callSequenceTemplate = R"(${resultAssignment}${dispatcher}${vkCommand}( ${callArguments} );)";
|
||||
|
||||
std::string callArguments = generateCallArgumentsEnhanced( commandData, initialSkipCount, false, singularParams, templatedParams, false );
|
||||
std::string callArguments = generateCallArgumentsEnhanced( commandData, initialSkipCount, false, singularParams, templatedParams, raii );
|
||||
std::string resultAssignment = generateResultAssignment( commandData );
|
||||
|
||||
return replaceWithMap( callSequenceTemplate, { { "callArguments", callArguments }, { "resultAssignment", resultAssignment }, { "vkCommand", name } } );
|
||||
return replaceWithMap(
|
||||
callSequenceTemplate,
|
||||
{ { "callArguments", callArguments }, { "dispatcher", dispatcher }, { "resultAssignment", resultAssignment }, { "vkCommand", name } } );
|
||||
}
|
||||
}
|
||||
|
||||
@ -3425,13 +3425,7 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const &
|
||||
std::set<size_t> singularParams = singular ? determineSingularParams( returnParams[0], vectorParams ) : std::set<size_t>();
|
||||
std::pair<bool, std::map<size_t, std::vector<size_t>>> vectorSizeCheck =
|
||||
needsVectorSizeCheck( commandData.params, vectorParams, returnParams, singularParams );
|
||||
bool enumerating = determineEnumeration( vectorParams,
|
||||
returnParams
|
||||
#if !defined( NDEBUG )
|
||||
,
|
||||
commandData.successCodes
|
||||
#endif
|
||||
);
|
||||
bool enumerating = determineEnumeration( vectorParams, returnParams );
|
||||
|
||||
std::vector<std::string> dataTypes = determineDataTypes( commandData.params, vectorParams, returnParams, templatedParams );
|
||||
std::string dataType = combineDataTypes( vectorParams, returnParams, singular, enumerating, dataTypes );
|
||||
@ -3440,17 +3434,9 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const &
|
||||
std::string chainTemplates = generateChainTemplates( returnParams, chained );
|
||||
auto [allocatorTemplates, uniqueHandleAllocatorTemplates] =
|
||||
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,
|
||||
#if !defined( NDEBUG )
|
||||
vectorParams,
|
||||
singular,
|
||||
#endif
|
||||
unique,
|
||||
chained,
|
||||
dataType );
|
||||
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 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 );
|
||||
@ -3478,7 +3464,7 @@ std::string VulkanHppGenerator::generateCommandEnhanced( std::string const &
|
||||
commandData, initialSkipCount, returnParams, vectorParams, templatedParams, singular, withAllocator, unique, chained, enumerating );
|
||||
std::string dataSizeChecks = generateDataSizeChecks( commandData, returnParams, dataTypes, vectorParams, templatedParams, singular );
|
||||
std::string callSequence =
|
||||
generateCallSequence( name, commandData, returnParams, vectorParams, initialSkipCount, singularParams, templatedParams, chained );
|
||||
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 );
|
||||
@ -6121,32 +6107,56 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandDeclarations( std::pair
|
||||
|
||||
std::string VulkanHppGenerator::generateRAIIHandleCommandEnhanced( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool definition ) const
|
||||
{
|
||||
std::set<size_t> skippedParams = determineSkippedParams( commandIt->second.params, initialSkipCount, vectorParams, {}, false );
|
||||
std::set<size_t> templatedParams = determineVoidPointerParams( commandIt->second.params );
|
||||
std::string argumentTemplates = generateArgumentTemplates( commandIt->second.params, {}, vectorParams, templatedParams, true );
|
||||
std::string argumentList =
|
||||
std::set<size_t> skippedParams = determineSkippedParams( commandIt->second.params, initialSkipCount, vectorParams, {}, false );
|
||||
std::set<size_t> singularParams = false ? determineSingularParams( returnParams[0], vectorParams ) : std::set<size_t>();
|
||||
std::set<size_t> templatedParams = determineVoidPointerParams( commandIt->second.params );
|
||||
|
||||
bool enumerating = determineEnumeration( vectorParams, returnParams );
|
||||
std::vector<std::string> dataTypes = determineDataTypes( commandIt->second.params, vectorParams, returnParams, templatedParams );
|
||||
std::string dataType = combineDataTypes( vectorParams, returnParams, false, enumerating, dataTypes );
|
||||
|
||||
std::string argumentTemplates = generateArgumentTemplates( commandIt->second.params, {}, vectorParams, templatedParams, true );
|
||||
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 nodiscard =
|
||||
generateNoDiscard( !returnParams.empty() || ( ( commandIt->second.returnType != "VkResult" ) && ( commandIt->second.returnType != "void" ) ),
|
||||
1 < commandIt->second.successCodes.size(),
|
||||
1 < commandIt->second.errorCodes.size() );
|
||||
std::pair<bool, std::map<size_t, std::vector<size_t>>> vectorSizeCheck = needsVectorSizeCheck( commandIt->second.params, vectorParams, {}, {} );
|
||||
std::string noexceptString = vectorSizeCheck.first ? "" : "VULKAN_HPP_NOEXCEPT";
|
||||
std::string returnType = generateReturnType( commandIt->second, returnParams, false, false, dataType );
|
||||
|
||||
if ( definition )
|
||||
{
|
||||
std::string const definitionTemplate =
|
||||
R"(
|
||||
${argumentTemplates}
|
||||
VULKAN_HPP_INLINE void ${className}::${commandName}( ${argumentList} ) const ${noexcept}
|
||||
${nodiscard} VULKAN_HPP_INLINE ${returnType} ${className}::${commandName}( ${argumentList} ) const ${noexcept}
|
||||
{
|
||||
${functionPointerCheck}
|
||||
${vectorSizeCheck}
|
||||
getDispatcher()->${vkCommand}( ${callArguments} );
|
||||
${callSequence}
|
||||
${returnStatement}
|
||||
}
|
||||
)";
|
||||
|
||||
std::string callArguments = generateCallArgumentsEnhanced( commandIt->second, initialSkipCount, false, {}, templatedParams, true );
|
||||
std::string callSequence =
|
||||
generateCallSequence( commandIt->first, commandIt->second, returnParams, vectorParams, initialSkipCount, singularParams, templatedParams, false, true );
|
||||
std::string returnVariable = generateReturnVariable( commandIt->second, returnParams, vectorParams, false, false );
|
||||
std::string returnStatement = generateReturnStatement( commandIt->first,
|
||||
commandIt->second,
|
||||
returnVariable,
|
||||
returnType,
|
||||
dataType,
|
||||
initialSkipCount,
|
||||
returnParams.empty() ? INVALID_INDEX : returnParams[0],
|
||||
false,
|
||||
enumerating );
|
||||
std::string vectorSizeCheckString =
|
||||
vectorSizeCheck.first ? generateRAIIHandleVectorSizeCheck( commandIt->first, commandIt->second, initialSkipCount, vectorSizeCheck.second, skippedParams )
|
||||
: "";
|
||||
@ -6154,31 +6164,37 @@ ${vectorSizeCheck}
|
||||
return replaceWithMap( definitionTemplate,
|
||||
{ { "argumentList", argumentList },
|
||||
{ "argumentTemplates", argumentTemplates },
|
||||
{ "callArguments", callArguments },
|
||||
{ "callSequence", callSequence },
|
||||
{ "className", stripPrefix( commandIt->second.params[initialSkipCount - 1].type.type, "Vk" ) },
|
||||
{ "commandName", commandName },
|
||||
{ "functionPointerCheck", generateFunctionPointerCheck( commandIt->first, commandIt->second.referencedIn ) },
|
||||
{ "nodiscard", nodiscard },
|
||||
{ "noexcept", noexceptString },
|
||||
{ "vectorSizeCheck", vectorSizeCheckString },
|
||||
{ "vkCommand", commandIt->first } } );
|
||||
{ "returnStatement", returnStatement },
|
||||
{ "returnType", returnType },
|
||||
{ "vectorSizeCheck", vectorSizeCheckString } } );
|
||||
}
|
||||
else
|
||||
{
|
||||
std::string const declarationTemplate =
|
||||
R"(
|
||||
${argumentTemplates}
|
||||
void ${commandName}( ${argumentList} ) const ${noexcept};
|
||||
${nodiscard} ${returnType} ${commandName}( ${argumentList} ) const ${noexcept};
|
||||
)";
|
||||
|
||||
return replaceWithMap(
|
||||
declarationTemplate,
|
||||
{ { "argumentList", argumentList }, { "argumentTemplates", argumentTemplates }, { "commandName", commandName }, { "noexcept", noexceptString } } );
|
||||
return replaceWithMap( declarationTemplate,
|
||||
{ { "argumentList", argumentList },
|
||||
{ "argumentTemplates", argumentTemplates },
|
||||
{ "commandName", commandName },
|
||||
{ "nodiscard", nodiscard },
|
||||
{ "noexcept", noexceptString },
|
||||
{ "returnType", returnType } } );
|
||||
}
|
||||
}
|
||||
|
||||
std::string VulkanHppGenerator::generateRAIIHandleCommandFactory( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::vector<size_t> returnParams,
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool definition,
|
||||
bool singular ) const
|
||||
@ -7214,7 +7230,7 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandResultSingleSuccessNoEr
|
||||
std::vector<size_t> returnParams = determineReturnParams( commandIt->second.params );
|
||||
if ( returnParams.empty() )
|
||||
{
|
||||
return generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, determineVectorParams( commandIt->second.params ), definition );
|
||||
return generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, returnParams, determineVectorParams( commandIt->second.params ), definition );
|
||||
}
|
||||
return "";
|
||||
}
|
||||
@ -7969,73 +7985,13 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandValue( std::map<std::st
|
||||
}
|
||||
else
|
||||
{
|
||||
return generateRAIIHandleCommandValue0Return0VectorType( commandIt, initialSkipCount, vectorParams, definition );
|
||||
return generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, returnParams, vectorParams, definition );
|
||||
}
|
||||
}
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
std::string VulkanHppGenerator::generateRAIIHandleCommandValue0Return0VectorType( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool definition ) const
|
||||
{
|
||||
std::set<size_t> skippedParams = determineSkippedParams( commandIt->second.params, initialSkipCount, vectorParams, {}, false );
|
||||
std::set<size_t> templatedParams = determineVoidPointerParams( commandIt->second.params );
|
||||
std::string argumentList =
|
||||
generateArgumentListEnhanced( commandIt->second.params, {}, vectorParams, skippedParams, {}, templatedParams, definition, false, false, false );
|
||||
std::string argumentTemplates = generateArgumentTemplates( commandIt->second.params, {}, vectorParams, templatedParams, true );
|
||||
std::string commandName = generateCommandName( commandIt->first, commandIt->second.params, initialSkipCount, m_tags, false, false );
|
||||
std::string returnType = generateNamespacedType( commandIt->second.returnType );
|
||||
|
||||
if ( definition )
|
||||
{
|
||||
std::string const definitionTemplate =
|
||||
R"(
|
||||
${argumentTemplates}
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE ${returnType} ${className}::${commandName}( ${argumentList} ) const VULKAN_HPP_NOEXCEPT
|
||||
{${functionPointerCheck}
|
||||
${vectorSizeCheck}
|
||||
return getDispatcher()->${vkCommand}( ${callArguments} );
|
||||
}
|
||||
)";
|
||||
|
||||
std::string callArguments = generateCallArgumentsEnhanced( commandIt->second, initialSkipCount, false, {}, templatedParams, true );
|
||||
std::pair<bool, std::map<size_t, std::vector<size_t>>> vectorSizeCheck = needsVectorSizeCheck( commandIt->second.params, vectorParams, {}, {} );
|
||||
std::string vectorSizeCheckString =
|
||||
vectorSizeCheck.first ? generateVectorSizeCheck( commandIt->first, commandIt->second, initialSkipCount, vectorSizeCheck.second, skippedParams, true )
|
||||
: "";
|
||||
|
||||
return replaceWithMap( definitionTemplate,
|
||||
{ { "argumentList", argumentList },
|
||||
{ "callArguments", callArguments },
|
||||
{ "argumentTemplates", argumentTemplates },
|
||||
{ "className", stripPrefix( commandIt->second.params[initialSkipCount - 1].type.type, "Vk" ) },
|
||||
{ "commandName", commandName },
|
||||
{ "functionPointerCheck", generateFunctionPointerCheck( commandIt->first, commandIt->second.referencedIn ) },
|
||||
{ "returnType", returnType },
|
||||
{ "vectorSizeCheck", vectorSizeCheckString },
|
||||
{ "vkCommand", commandIt->first } } );
|
||||
}
|
||||
else
|
||||
{
|
||||
std::string const declarationTemplate =
|
||||
R"(
|
||||
${argumentTemplates}
|
||||
VULKAN_HPP_NODISCARD ${returnType} ${commandName}( ${argumentList} ) const VULKAN_HPP_NOEXCEPT;
|
||||
)";
|
||||
|
||||
return replaceWithMap( declarationTemplate,
|
||||
{
|
||||
{ "argumentList", argumentList },
|
||||
{ "argumentTemplates", argumentTemplates },
|
||||
{ "commandName", commandName },
|
||||
{ "returnType", returnType },
|
||||
} );
|
||||
}
|
||||
}
|
||||
|
||||
std::string VulkanHppGenerator::generateRAIIHandleCommandValue0Return0VectorVkType( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
@ -8098,7 +8054,7 @@ std::string VulkanHppGenerator::generateRAIIHandleCommandVoid( std::map<std::str
|
||||
std::map<size_t, size_t> vectorParams = determineVectorParams( commandIt->second.params );
|
||||
switch ( returnParams.size() )
|
||||
{
|
||||
case 0: str = generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, vectorParams, definition ); break;
|
||||
case 0: str = generateRAIIHandleCommandEnhanced( commandIt, initialSkipCount, returnParams, vectorParams, definition ); break;
|
||||
case 1:
|
||||
if ( commandIt->second.params[returnParams[0]].type.postfix == "**" )
|
||||
{
|
||||
@ -9938,15 +9894,8 @@ std::string VulkanHppGenerator::generateReturnStatement( std::string const & com
|
||||
return returnStatement;
|
||||
}
|
||||
|
||||
std::string VulkanHppGenerator::generateReturnType( CommandData const & commandData,
|
||||
std::vector<size_t> const & returnParams,
|
||||
#if !defined( NDEBUG )
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool singular,
|
||||
#endif
|
||||
bool unique,
|
||||
bool chained,
|
||||
std::string const & dataType ) const
|
||||
std::string VulkanHppGenerator::generateReturnType(
|
||||
CommandData const & commandData, std::vector<size_t> const & returnParams, bool unique, bool chained, std::string const & dataType ) const
|
||||
{
|
||||
std::string modifiedDataType = dataType;
|
||||
if ( chained )
|
||||
@ -9977,12 +9926,12 @@ std::string VulkanHppGenerator::generateReturnType( CommandData const &
|
||||
std::string returnType;
|
||||
if ( ( 1 < commandData.successCodes.size() ) && returnParams.empty() )
|
||||
{
|
||||
assert( ( commandData.returnType == "VkResult" ) && !chained && !singular && !unique );
|
||||
assert( ( commandData.returnType == "VkResult" ) && !chained && !unique );
|
||||
returnType = "VULKAN_HPP_NAMESPACE::Result";
|
||||
}
|
||||
else if ( ( commandData.returnType != "VkResult" ) && ( commandData.returnType != "void" ) )
|
||||
{
|
||||
assert( returnParams.empty() && vectorParams.empty() && !chained && !singular && !unique );
|
||||
assert( returnParams.empty() && !chained && !unique );
|
||||
if ( beginsWith( commandData.returnType, "Vk" ) )
|
||||
{
|
||||
returnType = "VULKAN_HPP_NAMESPACE::" + stripPrefix( commandData.returnType, "Vk" );
|
||||
@ -9995,11 +9944,8 @@ std::string VulkanHppGenerator::generateReturnType( CommandData const &
|
||||
else if ( ( commandData.returnType == "void" ) ||
|
||||
( ( commandData.returnType == "VkResult" ) && ( commandData.successCodes.size() == 1 ) && commandData.errorCodes.empty() ) )
|
||||
{
|
||||
assert( !singular && !unique );
|
||||
assert( ( commandData.returnType != "void" ) ||
|
||||
( returnParams.empty() || ( ( returnParams.size() == 1 ) && ( vectorParams.find( returnParams[0] ) == vectorParams.end() ) ) ||
|
||||
( ( returnParams.size() == 2 ) && ( vectorParams.size() == 1 ) && ( returnParams[0] == vectorParams.begin()->second ) &&
|
||||
( returnParams[1] == vectorParams.begin()->first ) ) ) );
|
||||
assert( !unique );
|
||||
assert( ( commandData.returnType != "void" ) || ( returnParams.size() <= 2 ) );
|
||||
assert( ( commandData.returnType != "VkResult" ) || returnParams.empty() );
|
||||
returnType = modifiedDataType;
|
||||
}
|
||||
@ -10009,23 +9955,14 @@ std::string VulkanHppGenerator::generateReturnType( CommandData const &
|
||||
assert( !commandData.successCodes.empty() && ( commandData.successCodes[0] == "VK_SUCCESS" ) );
|
||||
if ( ( 1 < commandData.successCodes.size() ) && ( returnParams.size() == 1 ) )
|
||||
{
|
||||
assert( !commandData.errorCodes.empty() && ( vectorParams.empty() || ( vectorParams.find( returnParams[0] ) != vectorParams.end() ) ) && !chained );
|
||||
assert( !commandData.errorCodes.empty() && !chained );
|
||||
returnType = "ResultValue<" + modifiedDataType + ">";
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(
|
||||
( ( commandData.successCodes.size() == 1 ) || ( ( commandData.successCodes.size() == 2 ) && ( commandData.successCodes[1] == "VK_INCOMPLETE" ) ) ) &&
|
||||
!commandData.errorCodes.empty() &&
|
||||
( returnParams.empty() ||
|
||||
( ( returnParams.size() == 1 ) && ( vectorParams.empty() || ( vectorParams.find( returnParams[0] ) != vectorParams.end() ) ) ) ||
|
||||
( ( returnParams.size() == 2 ) &&
|
||||
( ( ( vectorParams.size() == 1 ) && ( returnParams[0] == vectorParams.begin()->second ) && ( returnParams[1] == vectorParams.begin()->first ) ) ||
|
||||
( ( vectorParams.size() == 2 ) && ( vectorParams.find( returnParams[0] ) != vectorParams.end() ) &&
|
||||
( vectorParams.find( returnParams[1] ) == vectorParams.end() ) ) ) ) ||
|
||||
( ( returnParams.size() == 3 ) && ( vectorParams.size() == 2 ) && ( vectorParams.find( returnParams[1] ) != vectorParams.end() ) &&
|
||||
( vectorParams.find( returnParams[1] )->second == returnParams[0] ) && ( vectorParams.find( returnParams[2] ) != vectorParams.end() ) &&
|
||||
( vectorParams.find( returnParams[2] )->second == returnParams[0] ) ) ) );
|
||||
!commandData.errorCodes.empty() && ( returnParams.size() <= 3 ) );
|
||||
returnType = "typename ResultValueType<" + modifiedDataType + ">::type";
|
||||
}
|
||||
}
|
||||
|
@ -410,15 +410,9 @@ private:
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::set<size_t> const & templatedParams ) const;
|
||||
size_t determineDefaultStartIndex( std::vector<ParamData> const & params, std::set<size_t> const & skippedParams ) const;
|
||||
bool determineEnumeration( std::map<size_t, size_t> const & vectorParams,
|
||||
std::vector<size_t> const & returnParams
|
||||
#if !defined( NDEBUG )
|
||||
,
|
||||
std::vector<std::string> const & successCodes
|
||||
#endif
|
||||
) const;
|
||||
size_t determineInitialSkipCount( std::string const & command ) const;
|
||||
std::vector<size_t> determineReturnParams( std::vector<ParamData> const & params ) const;
|
||||
bool determineEnumeration( std::map<size_t, size_t> const & vectorParams, std::vector<size_t> const & returnParams ) const;
|
||||
size_t determineInitialSkipCount( std::string const & command ) const;
|
||||
std::vector<size_t> determineReturnParams( std::vector<ParamData> const & params ) const;
|
||||
std::vector<std::map<std::string, CommandData>::const_iterator>
|
||||
determineRAIIHandleConstructors( std::string const & handleType, std::map<std::string, CommandData>::const_iterator destructorIt ) const;
|
||||
std::map<std::string, CommandData>::const_iterator determineRAIIHandleDestructor( std::string const & handleType ) const;
|
||||
@ -490,7 +484,8 @@ private:
|
||||
size_t initialSkipCount,
|
||||
std::set<size_t> const & singularParams,
|
||||
std::set<size_t> const & templatedParams,
|
||||
bool chained ) const;
|
||||
bool chained,
|
||||
bool raii ) const;
|
||||
std::string generateChainTemplates( std::vector<size_t> const & returnParams, bool chained ) const;
|
||||
std::string generateCommand( std::string const & name, CommandData const & commandData, size_t initialSkipCount, bool definition ) const;
|
||||
std::string
|
||||
@ -681,11 +676,12 @@ private:
|
||||
std::string generateRAIIHandleCommandDeclarations( std::pair<std::string, HandleData> const & handle, std::set<std::string> const & specialFunctions ) const;
|
||||
std::string generateRAIIHandleCommandEnhanced( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandFactory( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::vector<size_t> returnParams,
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool definition,
|
||||
bool singular ) const;
|
||||
@ -823,45 +819,41 @@ private:
|
||||
std::vector<size_t> const & returnParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandValue( std::map<std::string, CommandData>::const_iterator commandIt, size_t initialSkipCount, bool definition ) const;
|
||||
std::string generateRAIIHandleCommandValue0Return0VectorType( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandValue0Return0VectorVkType( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid( std::map<std::string, CommandData>::const_iterator commandIt, size_t initialSkipCount, bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnChain( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnValue( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnVector( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnVoidVectorSingular( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid2ReturnEnumerateChain( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
std::vector<size_t> const & returnParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid2ReturnEnumerateValue( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
std::vector<size_t> const & returnParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnChain( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnValue( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnVector( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid1ReturnVoidVectorSingular( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
size_t returnParam,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid2ReturnEnumerateChain( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
std::vector<size_t> const & returnParamIndices,
|
||||
bool definition ) const;
|
||||
std::string generateRAIIHandleCommandVoid2ReturnEnumerateValue( std::map<std::string, CommandData>::const_iterator commandIt,
|
||||
size_t initialSkipCount,
|
||||
std::map<size_t, size_t> const & vectorParamIndices,
|
||||
std::vector<size_t> const & returnParamIndices,
|
||||
bool definition ) const;
|
||||
std::pair<std::string, std::string> generateRAIIHandleConstructor( std::pair<std::string, HandleData> const & handle,
|
||||
std::map<std::string, CommandData>::const_iterator constructorIt,
|
||||
std::string const & enter,
|
||||
@ -946,15 +938,8 @@ private:
|
||||
size_t returnParam,
|
||||
bool unique,
|
||||
bool enumerating ) const;
|
||||
std::string generateReturnType( CommandData const & commandData,
|
||||
std::vector<size_t> const & returnParams,
|
||||
#if !defined( NDEBUG )
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
bool singular,
|
||||
#endif
|
||||
bool unique,
|
||||
bool chained,
|
||||
std::string const & dataType ) const;
|
||||
std::string generateReturnType(
|
||||
CommandData const & commandData, std::vector<size_t> const & returnParams, bool unique, bool chained, std::string const & dataType ) const;
|
||||
std::string generateReturnVariable( CommandData const & commandData,
|
||||
std::vector<size_t> const & returnParams,
|
||||
std::map<size_t, size_t> const & vectorParams,
|
||||
|
@ -8520,12 +8520,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*/
|
||||
};
|
||||
};
|
||||
@ -8720,15 +8720,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 )
|
||||
};
|
||||
};
|
||||
|
||||
@ -8961,7 +8961,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*/
|
||||
};
|
||||
};
|
||||
@ -9571,7 +9571,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*/
|
||||
};
|
||||
};
|
||||
@ -9684,13 +9684,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*/
|
||||
};
|
||||
};
|
||||
@ -11361,13 +11361,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 )
|
||||
};
|
||||
};
|
||||
|
||||
@ -11695,7 +11695,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*/
|
||||
};
|
||||
};
|
||||
@ -12093,9 +12093,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 ) |
|
||||
@ -12231,10 +12231,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 ) |
|
||||
@ -12471,14 +12471,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 )
|
||||
};
|
||||
};
|
||||
|
||||
@ -13002,7 +13002,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*/
|
||||
};
|
||||
|
@ -10228,12 +10228,14 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE PFN_vkVoidFunction Instance::getProcAddr( const std::string & name ) const VULKAN_HPP_NOEXCEPT
|
||||
{
|
||||
return getDispatcher()->vkGetInstanceProcAddr( static_cast<VkInstance>( m_instance ), name.c_str() );
|
||||
PFN_vkVoidFunction result = getDispatcher()->vkGetInstanceProcAddr( static_cast<VkInstance>( 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
|
||||
{
|
||||
return getDispatcher()->vkGetDeviceProcAddr( static_cast<VkDevice>( m_device ), name.c_str() );
|
||||
PFN_vkVoidFunction result = getDispatcher()->vkGetDeviceProcAddr( static_cast<VkDevice>( m_device ), name.c_str() );
|
||||
return result;
|
||||
}
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_RAII_NAMESPACE::Device
|
||||
@ -11887,15 +11889,17 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE uint64_t
|
||||
Device::getBufferOpaqueCaptureAddress( const VULKAN_HPP_NAMESPACE::BufferDeviceAddressInfo & info ) const VULKAN_HPP_NOEXCEPT
|
||||
{
|
||||
return getDispatcher()->vkGetBufferOpaqueCaptureAddress( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkBufferDeviceAddressInfo *>( &info ) );
|
||||
uint64_t result =
|
||||
getDispatcher()->vkGetBufferOpaqueCaptureAddress( static_cast<VkDevice>( m_device ), reinterpret_cast<const VkBufferDeviceAddressInfo *>( &info ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE uint64_t
|
||||
Device::getMemoryOpaqueCaptureAddress( const VULKAN_HPP_NAMESPACE::DeviceMemoryOpaqueCaptureAddressInfo & info ) const VULKAN_HPP_NOEXCEPT
|
||||
{
|
||||
return getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddress( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkDeviceMemoryOpaqueCaptureAddressInfo *>( &info ) );
|
||||
uint64_t result = getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddress( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkDeviceMemoryOpaqueCaptureAddressInfo *>( &info ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
//=== VK_VERSION_1_3 ===
|
||||
@ -13150,7 +13154,9 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
{
|
||||
VULKAN_HPP_ASSERT( getDispatcher()->vkGetImageViewHandleNVX && "Function <vkGetImageViewHandleNVX> needs extension <VK_NVX_image_view_handle> enabled!" );
|
||||
|
||||
return getDispatcher()->vkGetImageViewHandleNVX( static_cast<VkDevice>( m_device ), reinterpret_cast<const VkImageViewHandleInfoNVX *>( &info ) );
|
||||
uint32_t result =
|
||||
getDispatcher()->vkGetImageViewHandleNVX( static_cast<VkDevice>( m_device ), reinterpret_cast<const VkImageViewHandleInfoNVX *>( &info ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::ImageViewAddressPropertiesNVX ImageView::getAddressNVX() const
|
||||
@ -16167,8 +16173,9 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
VULKAN_HPP_ASSERT( getDispatcher()->vkGetBufferOpaqueCaptureAddressKHR &&
|
||||
"Function <vkGetBufferOpaqueCaptureAddressKHR> needs extension <VK_KHR_buffer_device_address> enabled!" );
|
||||
|
||||
return getDispatcher()->vkGetBufferOpaqueCaptureAddressKHR( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkBufferDeviceAddressInfo *>( &info ) );
|
||||
uint64_t result =
|
||||
getDispatcher()->vkGetBufferOpaqueCaptureAddressKHR( static_cast<VkDevice>( m_device ), reinterpret_cast<const VkBufferDeviceAddressInfo *>( &info ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE uint64_t
|
||||
@ -16177,8 +16184,9 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
VULKAN_HPP_ASSERT( getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddressKHR &&
|
||||
"Function <vkGetDeviceMemoryOpaqueCaptureAddressKHR> needs extension <VK_KHR_buffer_device_address> enabled!" );
|
||||
|
||||
return getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddressKHR( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkDeviceMemoryOpaqueCaptureAddressInfo *>( &info ) );
|
||||
uint64_t result = getDispatcher()->vkGetDeviceMemoryOpaqueCaptureAddressKHR( static_cast<VkDevice>( m_device ),
|
||||
reinterpret_cast<const VkDeviceMemoryOpaqueCaptureAddressInfo *>( &info ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
//=== VK_EXT_line_rasterization ===
|
||||
@ -16341,7 +16349,9 @@ namespace VULKAN_HPP_NAMESPACE
|
||||
VULKAN_HPP_ASSERT( getDispatcher()->vkGetDeferredOperationMaxConcurrencyKHR &&
|
||||
"Function <vkGetDeferredOperationMaxConcurrencyKHR> needs extension <VK_KHR_deferred_host_operations> enabled!" );
|
||||
|
||||
return getDispatcher()->vkGetDeferredOperationMaxConcurrencyKHR( static_cast<VkDevice>( m_device ), static_cast<VkDeferredOperationKHR>( m_operation ) );
|
||||
uint32_t result =
|
||||
getDispatcher()->vkGetDeferredOperationMaxConcurrencyKHR( static_cast<VkDevice>( m_device ), static_cast<VkDeferredOperationKHR>( m_operation ) );
|
||||
return result;
|
||||
}
|
||||
|
||||
VULKAN_HPP_NODISCARD VULKAN_HPP_INLINE VULKAN_HPP_NAMESPACE::Result DeferredOperationKHR::getResult() const VULKAN_HPP_NOEXCEPT
|
||||
|
@ -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 ),
|
||||
|
Loading…
Reference in New Issue
Block a user