Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDalai Felinto <dfelinto@gmail.com>2017-02-09 17:57:06 +0300
committerDalai Felinto <dfelinto@gmail.com>2017-02-09 17:57:06 +0300
commitcb490561d3a7db02d612800a1610c79f2e4eccaa (patch)
tree85478b136967ce0897ec2fcfabb79ef4aa86f000 /source/blender/blenloader/intern
parent5bee553b1f38319da9f88ca2d9e7150d6448eaf5 (diff)
Layers: set active object in doversion for all render layers
Diffstat (limited to 'source/blender/blenloader/intern')
-rw-r--r--source/blender/blenloader/intern/versioning_280.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 72859b0b94a..432d8be0a6d 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -69,7 +69,7 @@ void do_versions_after_linking_280(Main *main)
is_visible[i] = (scene->lay & (1 << i));
}
- for (BaseLegacy *base = scene->base.first; base; base = base->next) {
+ for (Base *base = scene->base.first; base; base = base->next) {
lay_used |= base->lay & ((1 << 20) - 1); /* ignore localview */
for (int i = 0; i < 20; i++) {
@@ -108,6 +108,11 @@ void do_versions_after_linking_280(Main *main)
}
}
+ /* for convenience set the same active object in all the layers */
+ if (scene->basact) {
+ sl->basact = BKE_scene_layer_base_find(sl, scene->basact->object);
+ }
+
/* TODO: passes, samples, mask_layesr, exclude, ... */
}
@@ -136,7 +141,7 @@ void do_versions_after_linking_280(Main *main)
}
/* convert selected bases */
- for (BaseLegacy *base = scene->base.first; base; base = base->next) {
+ for (Base *base = scene->base.first; base; base = base->next) {
Base *ob_base = BKE_scene_layer_base_find(sl, base->object);
if ((base->flag & SELECT) != 0) {
if ((ob_base->flag & BASE_SELECTABLED) != 0) {
@@ -158,7 +163,7 @@ void do_versions_after_linking_280(Main *main)
}
/* remove bases once and for all */
- for (BaseLegacy *base = scene->base.first; base; base = base->next) {
+ for (Base *base = scene->base.first; base; base = base->next) {
id_us_min(&base->object->id);
}
BLI_freelistN(&scene->base);