I have been having a look into the vulkan-hpp source code to try to understand how to manage StructureChain
s. I've found this odd looking syntax (line marked with comment) related with the usage of template
keyword as a member type. Moreover, its followed by a function call with no ;
preceding.
template<typename X, typename Y, typename ...Z, typename Dispatch>
VULKAN_HPP_INLINE StructureChain<X, Y, Z...> PhysicalDevice::getFormatProperties2( VULKAN_HPP_NAMESPACE::Format format, Dispatch const &d ) const VULKAN_HPP_NOEXCEPT
{
StructureChain<X, Y, Z...> structureChain;
VULKAN_HPP_NAMESPACE::FormatProperties2& formatProperties = structureChain.template get<VULKAN_HPP_NAMESPACE::FormatProperties2>(); //This line
d.vkGetPhysicalDeviceFormatProperties2( m_physicalDevice, static_cast<VkFormat>( format ), reinterpret_cast<VkFormatProperties2*>( &formatProperties ) );
return structureChain;
}
Can anyone help me to figure out the meaning of this line?