2023-05-31 16:19:06 +02:00
|
|
|
/* SPDX-FileCopyrightText: 2023 Blender Foundation
|
|
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later */
|
2016-04-24 22:42:41 +10:00
|
|
|
#pragma once
|
|
|
|
|
|
2023-07-23 20:29:29 +02:00
|
|
|
#include "BLI_utildefines.h"
|
|
|
|
|
|
2020-05-08 18:16:39 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
|
extern "C" {
|
|
|
|
|
#endif
|
|
|
|
|
|
2019-02-18 08:08:12 +11:00
|
|
|
/** \file
|
|
|
|
|
* \ingroup bke
|
2016-04-24 22:42:41 +10:00
|
|
|
*/
|
|
|
|
|
|
2019-04-14 10:48:42 +02:00
|
|
|
/**
|
|
|
|
|
* The lines below use regex from scripts to extract their values,
|
|
|
|
|
* Keep this in mind when modifying this file and keep this comment above the defines.
|
|
|
|
|
*
|
|
|
|
|
* \note Use #STRINGIFY() rather than defining with quotes.
|
|
|
|
|
*/
|
2016-04-24 22:42:41 +10:00
|
|
|
|
2023-07-31 10:15:30 +10:00
|
|
|
/** Blender major and minor version. */
|
2023-05-17 12:39:01 +02:00
|
|
|
#define BLENDER_VERSION 400
|
2023-07-31 10:15:30 +10:00
|
|
|
/** Blender patch version for bug-fix releases. */
|
2023-03-13 08:38:04 +01:00
|
|
|
#define BLENDER_VERSION_PATCH 0
|
Blender: change bugfix release versioning from a/b/c to .1/.2/.3
The file subversion is no longer used in the Python API or user interface,
and is now internal to Blender.
User interface, Python API and file I/O metadata now use more consistent
formatting for version numbers. Official releases use "2.83.0", "2.83.1",
and releases under development use "2.90.0 Alpha", "2.90.0 Beta".
Some Python add-ons may need to lower the Blender version in bl_info to
(2, 83, 0) or (2, 90, 0) if they used a subversion number higher than 0.
https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Python_API#Compatibility
This change is in preparation of LTS releases, and also brings us more
in line with semantic versioning.
Fixes T76058.
Differential Revision: https://developer.blender.org/D7748
2020-05-25 10:49:04 +02:00
|
|
|
/** Blender release cycle stage: alpha/beta/rc/release. */
|
2023-05-17 13:05:32 +02:00
|
|
|
#define BLENDER_VERSION_CYCLE alpha
|
2023-02-15 12:47:47 +01:00
|
|
|
|
Blender: change bugfix release versioning from a/b/c to .1/.2/.3
The file subversion is no longer used in the Python API or user interface,
and is now internal to Blender.
User interface, Python API and file I/O metadata now use more consistent
formatting for version numbers. Official releases use "2.83.0", "2.83.1",
and releases under development use "2.90.0 Alpha", "2.90.0 Beta".
Some Python add-ons may need to lower the Blender version in bl_info to
(2, 83, 0) or (2, 90, 0) if they used a subversion number higher than 0.
https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Python_API#Compatibility
This change is in preparation of LTS releases, and also brings us more
in line with semantic versioning.
Fixes T76058.
Differential Revision: https://developer.blender.org/D7748
2020-05-25 10:49:04 +02:00
|
|
|
/* Blender file format version. */
|
|
|
|
|
#define BLENDER_FILE_VERSION BLENDER_VERSION
|
2023-08-03 17:07:22 +02:00
|
|
|
#define BLENDER_FILE_SUBVERSION 14
|
Blender: change bugfix release versioning from a/b/c to .1/.2/.3
The file subversion is no longer used in the Python API or user interface,
and is now internal to Blender.
User interface, Python API and file I/O metadata now use more consistent
formatting for version numbers. Official releases use "2.83.0", "2.83.1",
and releases under development use "2.90.0 Alpha", "2.90.0 Beta".
Some Python add-ons may need to lower the Blender version in bl_info to
(2, 83, 0) or (2, 90, 0) if they used a subversion number higher than 0.
https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Python_API#Compatibility
This change is in preparation of LTS releases, and also brings us more
in line with semantic versioning.
Fixes T76058.
Differential Revision: https://developer.blender.org/D7748
2020-05-25 10:49:04 +02:00
|
|
|
|
|
|
|
|
/* Minimum Blender version that supports reading file written with the current
|
2023-07-24 11:21:20 +02:00
|
|
|
* version. Older Blender versions will test this and cancel loading the file, showing a warning to
|
|
|
|
|
* the user.
|
|
|
|
|
*
|
|
|
|
|
* See https://wiki.blender.org/wiki/Process/Compatibility_Handling for details. */
|
|
|
|
|
#define BLENDER_FILE_MIN_VERSION 306
|
|
|
|
|
#define BLENDER_FILE_MIN_SUBVERSION 11
|
Blender: change bugfix release versioning from a/b/c to .1/.2/.3
The file subversion is no longer used in the Python API or user interface,
and is now internal to Blender.
User interface, Python API and file I/O metadata now use more consistent
formatting for version numbers. Official releases use "2.83.0", "2.83.1",
and releases under development use "2.90.0 Alpha", "2.90.0 Beta".
Some Python add-ons may need to lower the Blender version in bl_info to
(2, 83, 0) or (2, 90, 0) if they used a subversion number higher than 0.
https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Python_API#Compatibility
This change is in preparation of LTS releases, and also brings us more
in line with semantic versioning.
Fixes T76058.
Differential Revision: https://developer.blender.org/D7748
2020-05-25 10:49:04 +02:00
|
|
|
|
|
|
|
|
/** User readable version string. */
|
|
|
|
|
const char *BKE_blender_version_string(void);
|
2016-04-24 22:42:41 +10:00
|
|
|
|
2023-07-31 10:15:30 +10:00
|
|
|
/** Returns true when version cycle is alpha, otherwise (beta, rc) returns false. */
|
2020-08-17 19:50:35 +02:00
|
|
|
bool BKE_blender_version_is_alpha(void);
|
|
|
|
|
|
2023-07-31 10:15:30 +10:00
|
|
|
/**
|
|
|
|
|
* Fill in given string buffer with user-readable formatted file version and subversion (if
|
2023-07-23 20:29:29 +02:00
|
|
|
* provided).
|
|
|
|
|
*
|
2023-07-31 10:15:30 +10:00
|
|
|
* \param str_buff a char buffer where the formatted string is written, minimal recommended size is
|
2023-07-23 20:29:29 +02:00
|
|
|
* 8, or 16 if subversion is provided.
|
|
|
|
|
*
|
|
|
|
|
* \param file_subversion the file subversion, if given value < 0, it is ignored, and only the
|
2023-07-31 10:15:30 +10:00
|
|
|
* `file_version` is used.
|
|
|
|
|
*/
|
2023-07-23 20:29:29 +02:00
|
|
|
void BKE_blender_version_blendfile_string_from_values(char *str_buff,
|
|
|
|
|
const size_t str_buff_len,
|
|
|
|
|
const short file_version,
|
|
|
|
|
const short file_subversion);
|
|
|
|
|
|
2020-05-08 18:16:39 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
|
}
|
|
|
|
|
#endif
|