Blender V5.0
BKE_blender_version.h File Reference
#include <stddef.h>

Go to the source code of this file.

Macros

#define BLENDER_VERSION   500
#define BLENDER_VERSION_PATCH   0
#define BLENDER_VERSION_CYCLE   release
#define BLENDER_VERSION_SUFFIX
#define BLENDER_FILE_VERSION   BLENDER_VERSION
#define BLENDER_FILE_SUBVERSION   118
#define BLENDER_FILE_MIN_VERSION   405
#define BLENDER_FILE_MIN_SUBVERSION   85

Functions

const char * BKE_blender_version_string (void)
const char * BKE_blender_version_string_compact (void)
bool BKE_blender_version_is_alpha (void)
bool BKE_blender_version_is_lts (void)
void BKE_blender_version_blendfile_string_from_values (char *str_buff, const size_t str_buff_maxncpy, const short file_version, const short file_subversion)

Macro Definition Documentation

◆ BLENDER_FILE_MIN_SUBVERSION

#define BLENDER_FILE_MIN_SUBVERSION   85

Definition at line 40 of file BKE_blender_version.h.

Referenced by write_global().

◆ BLENDER_FILE_MIN_VERSION

#define BLENDER_FILE_MIN_VERSION   405

Definition at line 39 of file BKE_blender_version.h.

Referenced by write_global().

◆ BLENDER_FILE_SUBVERSION

◆ BLENDER_FILE_VERSION

◆ BLENDER_VERSION

#define BLENDER_VERSION   500

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. Blender major and minor version.

Definition at line 20 of file BKE_blender_version.h.

Referenced by BKE_appdir_folder_id_user_notest(), BKE_appdir_resource_path_id(), blend_file_thumb_from_camera(), blend_file_thumb_from_screenshot(), blender_version_init(), bpy_resource_path(), file_overwrite_detailed_info_show(), get_path_local(), get_path_system(), get_path_user(), make_app_info(), and RNA_def_property_deprecated().

◆ BLENDER_VERSION_CYCLE

#define BLENDER_VERSION_CYCLE   release

Blender release cycle stage: alpha/beta/rc/release.

Definition at line 24 of file BKE_blender_version.h.

Referenced by BKE_blender_version_is_alpha(), blender_version_init(), and make_app_info().

◆ BLENDER_VERSION_PATCH

#define BLENDER_VERSION_PATCH   0

Blender patch version for bug-fix releases.

Definition at line 22 of file BKE_blender_version.h.

Referenced by blender_version_init(), and make_app_info().

◆ BLENDER_VERSION_SUFFIX

#define BLENDER_VERSION_SUFFIX

Blender release type suffix. LTS or blank.

Definition at line 26 of file BKE_blender_version.h.

Referenced by BKE_blender_version_is_lts().

Function Documentation

◆ BKE_blender_version_blendfile_string_from_values()

void BKE_blender_version_blendfile_string_from_values ( char * str_buff,
const size_t str_buff_maxncpy,
const short file_version,
const short file_subversion )

Fill in given string buffer with user-readable formatted file version and subversion (if provided).

Parameters
str_buffa char buffer where the formatted string is written, minimal recommended size is 8, or 16 if subversion is provided.
file_subversionthe file subversion, if given value < 0, it is ignored, and only the file_version is used.

Definition at line 156 of file blender.cc.

References BLI_snprintf_utf8().

Referenced by file_overwrite_detailed_info_show(), is_minversion_older_than_blender(), and ui_template_status_tooltip().

◆ BKE_blender_version_is_alpha()

bool BKE_blender_version_is_alpha ( void )

Returns true when version cycle is alpha, otherwise (beta, rc) returns false.

Definition at line 176 of file blender.cc.

References BLENDER_VERSION_CYCLE, STREQ, and STRINGIFY.

Referenced by BLO_sanitize_experimental_features_userpref_blend().

◆ BKE_blender_version_is_lts()

bool BKE_blender_version_is_lts ( void )

Returns true when version suffix is LTS, otherwise returns false.

Definition at line 182 of file blender.cc.

References BLENDER_VERSION_SUFFIX, STREQ, and STRINGIFY.

Referenced by blender_version_init().

◆ BKE_blender_version_string()

◆ BKE_blender_version_string_compact()

const char * BKE_blender_version_string_compact ( void )

As above but does not show patch version.

Definition at line 151 of file blender.cc.

References blender_version_string_compact.

Referenced by ED_info_statusbar_string_ex().