mirror of
https://github.com/Kiritow/MiniEngine.git
synced 2024-03-22 13:11:22 +08:00
Add version querying functions
This commit is contained in:
parent
c4b8e3e34e
commit
d4aa4cbbaa
|
@ -2088,7 +2088,7 @@ namespace MiniEngine
|
||||||
}
|
}
|
||||||
|
|
||||||
//static
|
//static
|
||||||
std::tuple<int,int,int> SDLSystem::getCompileVersion()
|
std::tuple<int,int,int> SDLSystem::GetSDLCompileVersion()
|
||||||
{
|
{
|
||||||
SDL_version ver;
|
SDL_version ver;
|
||||||
SDL_VERSION(&ver);
|
SDL_VERSION(&ver);
|
||||||
|
@ -2096,12 +2096,56 @@ namespace MiniEngine
|
||||||
}
|
}
|
||||||
|
|
||||||
//static
|
//static
|
||||||
std::tuple<int,int,int> SDLSystem::getLinkedVersion()
|
std::tuple<int,int,int> SDLSystem::GetSDLLinkedVersion()
|
||||||
{
|
{
|
||||||
SDL_version ver;
|
SDL_version ver;
|
||||||
SDL_GetVersion(&ver);
|
SDL_GetVersion(&ver);
|
||||||
return std::make_tuple(ver.major,ver.minor,ver.patch);
|
return std::make_tuple(ver.major,ver.minor,ver.patch);
|
||||||
}
|
}
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetIMGCompileVersion()
|
||||||
|
{
|
||||||
|
SDL_version ver;
|
||||||
|
SDL_IMAGE_VERSION(&ver);
|
||||||
|
return std::make_tuple(ver.major,ver.minor,ver.patch);
|
||||||
|
}
|
||||||
|
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetIMGLinkedVersion()
|
||||||
|
{
|
||||||
|
const SDL_version* ptr=IMG_Linked_Version();
|
||||||
|
return std::make_tuple();
|
||||||
|
}
|
||||||
|
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetMixCompileVersion()
|
||||||
|
{
|
||||||
|
SDL_version ver;
|
||||||
|
SDL_MIXER_VERSION(&ver);
|
||||||
|
return std::make_tuple(ver.major,ver.minor,ver.patch);
|
||||||
|
}
|
||||||
|
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetMixLinkedVersion()
|
||||||
|
{
|
||||||
|
const SDL_version* ptr=Mix_Linked_Version();
|
||||||
|
return std::make_tuple(ptr->major,ptr->minor,ptr->patch);
|
||||||
|
}
|
||||||
|
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetTTFCompileVersion()
|
||||||
|
{
|
||||||
|
SDL_version ver;
|
||||||
|
SDL_TTF_VERSION(&ver);
|
||||||
|
return std::make_tuple(ver.major,ver.minor,ver.patch);
|
||||||
|
}
|
||||||
|
|
||||||
|
//static
|
||||||
|
std::tuple<int,int,int> SDLSystem::GetTTFLinkedVersion()
|
||||||
|
{
|
||||||
|
const SDL_version* ptr=TTF_Linked_Version();
|
||||||
|
return std::make_tuple(ptr->major,ptr->minor,ptr->patch);
|
||||||
|
}
|
||||||
|
|
||||||
/// Global Executor For class Timer
|
/// Global Executor For class Timer
|
||||||
Uint32 _global_timer_executor(Uint32 interval,void* param)
|
Uint32 _global_timer_executor(Uint32 interval,void* param)
|
||||||
|
|
13
MiniEngine.h
13
MiniEngine.h
|
@ -574,8 +574,17 @@ namespace MiniEngine
|
||||||
|
|
||||||
static bool HasScreenKeyboardSupport();
|
static bool HasScreenKeyboardSupport();
|
||||||
|
|
||||||
static std::tuple<int,int,int> getCompileVersion();
|
static std::tuple<int,int,int> GetSDLCompileVersion();
|
||||||
static std::tuple<int,int,int> getLinkedVersion();
|
static std::tuple<int,int,int> GetSDLLinkedVersion();
|
||||||
|
|
||||||
|
static std::tuple<int,int,int> GetIMGCompileVersion();
|
||||||
|
static std::tuple<int,int,int> GetIMGLinkedVersion();
|
||||||
|
|
||||||
|
static std::tuple<int,int,int> GetMixCompileVersion();
|
||||||
|
static std::tuple<int,int,int> GetMixLinkedVersion();
|
||||||
|
|
||||||
|
static std::tuple<int,int,int> GetTTFCompileVersion();
|
||||||
|
static std::tuple<int,int,int> GetTTFLinkedVersion();
|
||||||
|
|
||||||
class Android
|
class Android
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user