30 lines
729 B
C++
30 lines
729 B
C++
#pragma once
|
|
#include <string>
|
|
#include <spdlog/fmt/fmt.h> //TODO replace with external fmt
|
|
|
|
namespace openVulkanoCpp
|
|
{
|
|
inline const char* ENGINE_NAME = "openVulkanoCpp";
|
|
|
|
struct EngineVersion
|
|
{
|
|
int major, minor, patch;
|
|
int intVersion;
|
|
std::string stringVersion;
|
|
|
|
EngineVersion(int major, int minor, int patch, int build = 0) : major(major), minor(minor), patch(patch)
|
|
{
|
|
intVersion = ((major) << 24) | ((minor) << 16) | (patch);
|
|
std::string_view buildConfig;
|
|
#ifdef _DEBUG
|
|
buildConfig = "MSVC_DEBUG";
|
|
#elif DEBUG
|
|
buildConfig = "DEBUG";
|
|
#endif
|
|
stringVersion = fmt::format("v{0}.{1}.{2}.{3}{4}", major, minor, patch, build, buildConfig);
|
|
}
|
|
};
|
|
|
|
inline const EngineVersion ENGINE_VERSION(0, 0, 1);
|
|
}
|