diff options
Diffstat (limited to 'source/blender/blenloader/intern/versioning_260.c')
-rw-r--r-- | source/blender/blenloader/intern/versioning_260.c | 94 |
1 files changed, 47 insertions, 47 deletions
diff --git a/source/blender/blenloader/intern/versioning_260.c b/source/blender/blenloader/intern/versioning_260.c index d8a19bfa59e..a7c5d7b933c 100644 --- a/source/blender/blenloader/intern/versioning_260.c +++ b/source/blender/blenloader/intern/versioning_260.c @@ -700,7 +700,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 260 || (bmain->versionfile == 260 && bmain->subversionfile < 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 260, 1)) { Object *ob; for (ob = bmain->objects.first; ob; ob = ob->id.next) { @@ -721,7 +721,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 260 || (bmain->versionfile == 260 && bmain->subversionfile < 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 260, 2)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_SHADER) { bNode *node; @@ -740,7 +740,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 260 || (bmain->versionfile == 260 && bmain->subversionfile < 4)) { + if (!MAIN_VERSION_ATLEAST(bmain, 260, 4)) { { /* Convert node angles to radians! */ Scene *sce; @@ -830,7 +830,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 260 || (bmain->versionfile == 260 && bmain->subversionfile < 6)) { + if (!MAIN_VERSION_ATLEAST(bmain, 260, 6)) { Scene *sce; MovieClip *clip; @@ -880,7 +880,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 260 || (bmain->versionfile == 260 && bmain->subversionfile < 8)) { + if (!MAIN_VERSION_ATLEAST(bmain, 260, 8)) { Brush *brush; for (brush = bmain->brushes.first; brush; brush = brush->id.next) { @@ -890,7 +890,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 261 || (bmain->versionfile == 261 && bmain->subversionfile < 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 261, 1)) { { /* update use flags for node sockets (was only temporary before) */ Scene *sce; @@ -975,7 +975,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 261 || (bmain->versionfile == 261 && bmain->subversionfile < 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 261, 2)) { { /* convert deprecated sculpt_paint_unified_* fields to * UnifiedPaintSettings */ @@ -991,7 +991,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 261 || (bmain->versionfile == 261 && bmain->subversionfile < 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 261, 3)) { { /* convert extended ascii to utf-8 for text editor */ Text *text; @@ -1068,7 +1068,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 262 || (bmain->versionfile == 262 && bmain->subversionfile < 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 262, 1)) { /* update use flags for node sockets (was only temporary before) */ Scene *sce; bNodeTree *ntree; @@ -1095,7 +1095,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 262 || (bmain->versionfile == 262 && bmain->subversionfile < 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 262, 2)) { /* Set new idname of keyingsets from their now "label-only" name. */ Scene *scene; for (scene = bmain->scenes.first; scene; scene = scene->id.next) { @@ -1108,7 +1108,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 262 || (bmain->versionfile == 262 && bmain->subversionfile < 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 262, 3)) { Object *ob; ModifierData *md; @@ -1122,7 +1122,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 262 || (bmain->versionfile == 262 && bmain->subversionfile < 4)) { + if (!MAIN_VERSION_ATLEAST(bmain, 262, 4)) { /* Read Viscosity presets from older files */ Object *ob; @@ -1152,7 +1152,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 1)) { /* file output node paths are now stored in the file info struct instead socket name */ Scene *sce; bNodeTree *ntree; @@ -1167,7 +1167,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 3)) { Scene *scene; Brush *brush; @@ -1188,7 +1188,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 2)) { bScreen *screen; for (screen = bmain->screens.first; screen; screen = screen->id.next) { @@ -1223,7 +1223,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 4)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 4)) { Camera *cam; Curve *cu; @@ -1242,7 +1242,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 5)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 5)) { { /* file output node paths are now stored in the file info struct instead socket name */ Scene *sce; @@ -1261,7 +1261,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 6)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 6)) { /* update use flags for node sockets (was only temporary before) */ Scene *sce; Material *mat; @@ -1304,7 +1304,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 7)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 7)) { Object *ob; for (ob = bmain->objects.first; ob; ob = ob->id.next) { @@ -1322,7 +1322,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 9)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 9)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_SHADER) { bNode *node; @@ -1340,7 +1340,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 10)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 10)) { { Scene *scene; /* composite redesign */ @@ -1399,7 +1399,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 11)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 11)) { MovieClip *clip; for (clip = bmain->movieclips.first; clip; clip = clip->id.next) { @@ -1414,7 +1414,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 13)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 13)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_COMPOSIT) { bNode *node; @@ -1432,7 +1432,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 14)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 14)) { ParticleSettings *part; FOREACH_NODETREE_BEGIN (bmain, ntree, id) { @@ -1461,7 +1461,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 17)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 17)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_COMPOSIT) { bNode *node; @@ -1482,7 +1482,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 18)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 18)) { Scene *scene; for (scene = bmain->scenes.first; scene; scene = scene->id.next) { @@ -1518,7 +1518,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } /* color management pipeline changes compatibility code */ - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 19)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 19)) { Scene *scene; Image *ima; bool colormanagement_disabled = false; @@ -1556,14 +1556,14 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 20)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 20)) { Key *key; for (key = bmain->shapekeys.first; key; key = key->id.next) { blo_do_versions_key_uidgen(key); } } - if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 21)) { + if (!MAIN_VERSION_ATLEAST(bmain, 263, 21)) { { Mesh *me; for (me = bmain->meshes.first; me; me = me->id.next) { @@ -1589,7 +1589,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 1)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_SHADER) { bNode *node; @@ -1603,7 +1603,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 2)) { MovieClip *clip; for (clip = bmain->movieclips.first; clip; clip = clip->id.next) { @@ -1620,7 +1620,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 3)) { /* smoke branch */ { Object *ob; @@ -1683,7 +1683,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 5)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 5)) { /* set a unwrapping margin and ABF by default */ Scene *scene; @@ -1695,7 +1695,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 6)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 6)) { /* Fix for bug T32982, internal_links list could get corrupted from r51630 onward. * Simply remove bad internal_links lists to avoid NULL pointers. */ @@ -1715,7 +1715,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 7)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 7)) { /* convert tiles size from resolution and number of tiles */ { Scene *scene; @@ -1739,7 +1739,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 264 || (bmain->versionfile == 264 && bmain->subversionfile < 7)) { + if (!MAIN_VERSION_ATLEAST(bmain, 264, 7)) { MovieClip *clip; for (clip = bmain->movieclips.first; clip; clip = clip->id.next) { @@ -1758,7 +1758,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 265 || (bmain->versionfile == 265 && bmain->subversionfile < 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 3)) { bScreen *screen; for (screen = bmain->screens.first; screen; screen = screen->id.next) { ScrArea *area; @@ -1797,7 +1797,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 265 || (bmain->versionfile == 265 && bmain->subversionfile < 5)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 5)) { Scene *scene; Tex *tex; @@ -1858,7 +1858,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } FOREACH_NODETREE_END; } - else if (bmain->versionfile < 266 || (bmain->versionfile == 266 && bmain->subversionfile < 1)) { + else if (!MAIN_VERSION_ATLEAST(bmain, 266, 1)) { /* texture use alpha was removed for 2.66 but added back again for 2.66a, * for compatibility all textures assumed it to be enabled */ Tex *tex; @@ -1870,7 +1870,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (bmain->versionfile < 265 || (bmain->versionfile == 265 && bmain->subversionfile < 7)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 7)) { Curve *cu; for (cu = bmain->curves.first; cu; cu = cu->id.next) { @@ -1905,14 +1905,14 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (MAIN_VERSION_OLDER(bmain, 265, 9)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 9)) { Mesh *me; for (me = bmain->meshes.first; me; me = me->id.next) { BKE_mesh_do_versions_cd_flag_init(me); } } - if (MAIN_VERSION_OLDER(bmain, 265, 10)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 10)) { Brush *br; for (br = bmain->brushes.first; br; br = br->id.next) { if (br->ob_mode & OB_MODE_TEXTURE_PAINT) { @@ -1922,7 +1922,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } /* add storage for compositor translate nodes when not existing */ - if (MAIN_VERSION_OLDER(bmain, 265, 11)) { + if (!MAIN_VERSION_ATLEAST(bmain, 265, 11)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { if (ntree->type == NTREE_COMPOSIT) { bNode *node; @@ -1936,14 +1936,14 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) FOREACH_NODETREE_END; } - if (MAIN_VERSION_OLDER(bmain, 266, 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 266, 2)) { FOREACH_NODETREE_BEGIN (bmain, ntree, id) { do_versions_nodetree_customnodes(ntree, ((ID *)ntree == id)); } FOREACH_NODETREE_END; } - if (MAIN_VERSION_OLDER(bmain, 266, 2)) { + if (!MAIN_VERSION_ATLEAST(bmain, 266, 2)) { bScreen *screen; for (screen = bmain->screens.first; screen; screen = screen->id.next) { ScrArea *area; @@ -1977,7 +1977,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (MAIN_VERSION_OLDER(bmain, 266, 3)) { + if (!MAIN_VERSION_ATLEAST(bmain, 266, 3)) { { /* Fix for a very old issue: * Node names were nominally made unique in r24478 (2.50.8), but the do_versions check @@ -2152,7 +2152,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain) } } - if (MAIN_VERSION_OLDER(bmain, 267, 1)) { + if (!MAIN_VERSION_ATLEAST(bmain, 267, 1)) { Object *ob; for (ob = bmain->objects.first; ob; ob = ob->id.next) { |