2014-03-29 18:49:22 -05:00
/**
* @ file
* @ brief Header file that includes the version number of libopenshot
* @ author Jonathan Thomas < jonathan @ openshot . org >
*
2019-06-09 08:31:04 -04:00
* @ ref License
*/
/* LICENSE
2014-03-29 18:49:22 -05:00
*
2019-06-11 06:48:32 -04:00
* Copyright ( c ) 2008 - 2019 OpenShot Studios , LLC
2014-03-29 18:49:22 -05:00
* < http : //www.openshotstudios.com/>. This file is part of
* OpenShot Library ( libopenshot ) , an open - source project dedicated to
* delivering high quality video editing and animation solutions to the
* world . For more information visit < http : //www.openshot.org/>.
*
* OpenShot Library ( libopenshot ) is free software : you can redistribute it
2014-07-11 16:52:14 -05:00
* and / or modify it under the terms of the GNU Lesser General Public License
2014-03-29 18:49:22 -05:00
* as published by the Free Software Foundation , either version 3 of the
* License , or ( at your option ) any later version .
*
* OpenShot Library ( libopenshot ) is distributed in the hope that it will be
* useful , but WITHOUT ANY WARRANTY ; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the
2014-07-11 16:52:14 -05:00
* GNU Lesser General Public License for more details .
2014-03-29 18:49:22 -05:00
*
2014-07-11 16:52:14 -05:00
* You should have received a copy of the GNU Lesser General Public License
2014-03-29 18:49:22 -05:00
* along with OpenShot Library . If not , see < http : //www.gnu.org/licenses/>.
*/
# ifndef OPENSHOT_VERSION_H
# define OPENSHOT_VERSION_H
2019-07-01 12:24:50 -05:00
# define OPENSHOT_VERSION_ALL "@PROJECT_VERSION@" /// A string of the entire version "Major.Minor.Build"
# define OPENSHOT_VERSION_FULL "@PROJECT_VERSION_FULL@" /// A string of the full version identifier, including suffixes (e.g. "0.0.0-dev0")
2014-03-29 18:49:22 -05:00
2019-07-01 12:24:50 -05:00
# define OPENSHOT_VERSION_MAJOR_MINOR "@PROJECT_VERSION_MAJOR@.@PROJECT_VERSION_MINOR@" /// A string of the "Major.Minor" version
# define OPENSHOT_VERSION_MAJOR @PROJECT_VERSION_MAJOR@ /// Major version number is incremented when huge features are added or improved.
# define OPENSHOT_VERSION_MINOR @PROJECT_VERSION_MINOR@ /// Minor version is incremented when smaller (but still very important) improvements are added.
# define OPENSHOT_VERSION_BUILD @PROJECT_VERSION_PATCH@ /// Build number is incremented when minor bug fixes and less important improvements are added.
# define OPENSHOT_VERSION_SO @PROJECT_SO_VERSION@ /// Shared object version number. This increments any time the API and ABI changes (so old apps will no longer link)
2014-03-29 18:49:22 -05:00
# include <sstream>
2016-04-04 23:09:18 -05:00
namespace openshot
2014-03-29 18:49:22 -05:00
{
2016-04-04 23:09:18 -05:00
/// This struct holds version number information. Use the GetVersion() method to access the current version of libopenshot.
struct OpenShotVersion {
2019-09-21 01:43:30 -04:00
static const int Major = OPENSHOT_VERSION_MAJOR ; /// Major version number
static const int Minor = OPENSHOT_VERSION_MINOR ; /// Minor version number
static const int Build = OPENSHOT_VERSION_BUILD ; /// Build number
static const int So = OPENSHOT_VERSION_SO ; /// Shared Object Number (incremented when API or ABI changes)
2014-03-29 18:49:22 -05:00
2016-04-04 23:09:18 -05:00
/// Get a string version of the version (i.e. "Major.Minor.Build")
2019-09-21 01:43:30 -04:00
inline static const std : : string ToString ( ) {
std : : stringstream version_string ;
version_string < < Major < < " . " < < Minor < < " . " < < Build ;
2016-04-04 23:09:18 -05:00
return version_string . str ( ) ;
}
} ;
2019-09-21 01:43:30 -04:00
static const openshot : : OpenShotVersion Version ;
2016-04-04 23:09:18 -05:00
/// Get the current version number of libopenshot (major, minor, and build number)
2019-09-21 01:43:30 -04:00
openshot : : OpenShotVersion GetVersion ( ) ;
2014-03-29 18:49:22 -05:00
}
2019-09-21 01:43:30 -04:00
# endif // OPENSHOT_VERSION_H