mirror of
https://github.com/bkaradzic/bimg.git
synced 2026-02-17 20:52:38 +01:00
texturec: Added version info.
This commit is contained in:
1
tools/bin/darwin/.gitignore
vendored
Normal file
1
tools/bin/darwin/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
*
|
||||
1
tools/bin/linux/.gitignore
vendored
Normal file
1
tools/bin/linux/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
*
|
||||
1
tools/bin/windows/.gitignore
vendored
Normal file
1
tools/bin/windows/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
*
|
||||
@@ -384,6 +384,14 @@ bimg::ImageContainer* convert(bx::AllocatorI* _allocator, const void* _inputData
|
||||
return output;
|
||||
}
|
||||
|
||||
#define BIMG_TEXTUREC_VERSION_MAJOR 1
|
||||
#define BIMG_TEXTUREC_VERSION_MINOR 0
|
||||
|
||||
#define BIMG_TEXTUREC_VERSION_STR \
|
||||
BX_STRINGIZE(BIMG_TEXTUREC_VERSION_MAJOR) \
|
||||
"." BX_STRINGIZE(BIMG_TEXTUREC_VERSION_MINOR) \
|
||||
"." BX_STRINGIZE(BIMG_API_VERSION)
|
||||
|
||||
void help(const char* _error = NULL)
|
||||
{
|
||||
if (NULL != _error)
|
||||
@@ -392,7 +400,7 @@ void help(const char* _error = NULL)
|
||||
}
|
||||
|
||||
fprintf(stderr
|
||||
, "texturec, bgfx texture compiler tool\n"
|
||||
, "texturec, bgfx texture compiler tool, version " BIMG_TEXTUREC_VERSION_STR "\n"
|
||||
"Copyright 2011-2017 Branimir Karadzic. All rights reserved.\n"
|
||||
"License: https://github.com/bkaradzic/bgfx#license-bsd-2-clause\n\n"
|
||||
);
|
||||
@@ -430,6 +438,12 @@ int main(int _argc, const char* _argv[])
|
||||
{
|
||||
bx::CommandLine cmdLine(_argc, _argv);
|
||||
|
||||
if (cmdLine.hasArg('v', "version") )
|
||||
{
|
||||
fprintf(stderr, "texturec, bgfx texture compiler tool, version " BIMG_TEXTUREC_VERSION_STR "\n");
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
if (cmdLine.hasArg('h', "help") )
|
||||
{
|
||||
help();
|
||||
|
||||
Reference in New Issue
Block a user