Merge pull request #55 from asuessenbach/version104

Fix issue #54, Updates to support vulkan version 1.0.4
This commit is contained in:
Markus Tavenrath 2016-02-29 12:21:31 +01:00
commit 6958b89c3b
2 changed files with 10 additions and 6 deletions

View File

@ -603,6 +603,7 @@ std::map<size_t, size_t> getVectorParameters(CommandData const& commandData)
}
assert( (lenParameters[i] != ~0)
|| (commandData.arguments[i].len == "dataSize/4")
|| (commandData.arguments[i].len == "latexmath:[$dataSize \\over 4$]")
|| (commandData.arguments[i].len == "null-terminated")
|| (commandData.arguments[i].len == "pAllocateInfo->descriptorSetCount")
|| (commandData.arguments[i].len == "pAllocateInfo->commandBufferCount"));
@ -944,7 +945,8 @@ void readExtensionRequire(tinyxml2::XMLElement * element, std::string const& pro
if (child->Attribute("extends"))
{
assert(enums.find(getEnumName(child->Attribute("extends"))) != enums.end());
enums[getEnumName(child->Attribute("extends"))].addEnum(child->Attribute("name"), tag);
assert(!!child->Attribute("offset") ^ !!child->Attribute("value")); // either offset or value has to be defined; no both of them!
enums[getEnumName(child->Attribute("extends"))].addEnum(child->Attribute("name"), child->Attribute("offset") ? tag : "" );
}
}
else
@ -1467,7 +1469,8 @@ void writeCall(std::ofstream & ofs, std::string const& name, size_t templateInde
{
countIndices.insert(std::make_pair(it->second, it->first));
}
if ((vectorParameters.size() == 1) && (commandData.arguments[vectorParameters.begin()->first].len == "dataSize/4"))
if ((vectorParameters.size() == 1)
&& ((commandData.arguments[vectorParameters.begin()->first].len == "dataSize/4") || (commandData.arguments[vectorParameters.begin()->first].len == "latexmath:[$dataSize \\over 4$]")))
{
assert(commandData.arguments[3].name == "dataSize");
countIndices.insert(std::make_pair(3, vectorParameters.begin()->first));
@ -1601,7 +1604,8 @@ void writeFunctionHeader(std::ofstream & ofs, std::string const& indentation, st
{
skippedArguments.insert(it->second);
}
if ((vectorParameters.size() == 1) && (commandData.arguments[vectorParameters.begin()->first].len == "dataSize/4"))
if ((vectorParameters.size() == 1)
&& ((commandData.arguments[vectorParameters.begin()->first].len == "dataSize/4") || (commandData.arguments[vectorParameters.begin()->first].len == "latexmath:[$dataSize \\over 4$]")))
{
assert(commandData.arguments[3].name == "dataSize");
skippedArguments.insert(3);

View File

@ -37,7 +37,7 @@
# include <vector>
#endif /*VKCPP_ENHANCED_MODE*/
static_assert( VK_MAKE_VERSION(1, 0, 3) == VK_API_VERSION, "Wrong VK_API_VERSION!" );
static_assert( VK_MAKE_VERSION(1, 0, 4) == VK_API_VERSION, "Wrong VK_API_VERSION!" );
// 32-bit vulkan is not typesafe for handles, so don't allow copy constructors on this platform by default.
// To enable this feature on 32-bit platforms please define VK_CPP_TYPESAFE_CONVERSION
@ -6174,7 +6174,7 @@ namespace vk
eMirSurfaceCreateInfoKHR = VK_STRUCTURE_TYPE_MIR_SURFACE_CREATE_INFO_KHR,
eAndroidSurfaceCreateInfoKHR = VK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR,
eWin32SurfaceCreateInfoKHR = VK_STRUCTURE_TYPE_WIN32_SURFACE_CREATE_INFO_KHR,
eDebugReportCreateInfoEXT = VK_STRUCTURE_TYPE_DEBUG_REPORT_CREATE_INFO_EXT
eDebugReportCallbackCreateInfoEXT = VK_STRUCTURE_TYPE_DEBUG_REPORT_CALLBACK_CREATE_INFO_EXT
};
class ApplicationInfo
@ -23790,7 +23790,7 @@ namespace vk
case StructureType::eMirSurfaceCreateInfoKHR: return "MirSurfaceCreateInfoKHR";
case StructureType::eAndroidSurfaceCreateInfoKHR: return "AndroidSurfaceCreateInfoKHR";
case StructureType::eWin32SurfaceCreateInfoKHR: return "Win32SurfaceCreateInfoKHR";
case StructureType::eDebugReportCreateInfoEXT: return "DebugReportCreateInfoEXT";
case StructureType::eDebugReportCallbackCreateInfoEXT: return "DebugReportCallbackCreateInfoEXT";
default: return "unknown";
}
}