MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Hpp / generateStructs

Method generateStructs

generator/VulkanHppGenerator.cpp:11085–11106  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11083}
11084
11085std::string VulkanHppGenerator::generateStructs() const
11086{
11087 std::string const structsTemplate = R"(
11088 //===============
11089 //=== STRUCTS ===
11090 //===============
11091
11092${structs}
11093)";
11094
11095 // Note reordering structs or handles by features and extensions is not possible!
11096 std::set<std::string> listedStructs;
11097 std::string structs;
11098 for ( auto const & structure : m_structs )
11099 {
11100 if ( !listedStructs.contains( structure.first ) && isTypeUsed( structure.first ) )
11101 {
11102 structs += generateStruct( structure, listedStructs );
11103 }
11104 }
11105 return replaceWithMap( structsTemplate, { { "structs", structs } } );
11106}
11107
11108std::string VulkanHppGenerator::generateStructure( std::pair<std::string, StructData> const & structure ) const
11109{

Callers

nothing calls this directly

Calls 1

replaceWithMapFunction · 0.85

Tested by

no test coverage detected