Page MenuHome

Incorrect assignment of layers to compositor nodes in 2.8 when reading 2.79 .blend
Closed, ResolvedPublic


System Information
Operating system: macOS 10.13.6
Graphics card: AMD Radeon R9 M370X 2048 MB

Blender Version
Broken: 2.80 2019-02-13
Worked: 2.79b 2018-03-22

Short description of error
When the attached .blend file (created in 2.79b) is opened in 2.80 2019-02-13
the the compositor Render Layer nodes have wrong scene render layers.
The attached screen shots highlight the issue.

Exact steps for others to reproduce the error
Open attached P00_102c.blend in 2.80
View Compositing Node Editor

Correct setup in 2.79b

Wrong setup when opened in 2.80

Blender file

Event Timeline

Philipp Oeser (lichtwerk) lowered the priority of this task from Needs Triage by Developer to Confirmed, Medium.Feb 14 2019, 9:24 AM

Confirmed, checking...

Looks like this is caused by adding a vanilla "Viewport" viewlayer and making it the first in the list here
(special case in do_version_layers_to_collections() if there are layer overrides...)

/* Make it first in the list. */
BLI_remlink(&scene->view_layers, view_layer);
BLI_addhead(&scene->view_layers, view_layer);

Render Layers node stores an index to viewlayers afaics and by just making a new viewlayer the first here is shifting all others by one...
Not sure why the new vanilla "Viewport" viewlayer needs to be the first in the list?
If that needs to be the case, then Render Layers nodes indices need to be corrected as well, I guess.
But just removing the "push-to-head" for the new vanilla viewlayer also solves this issue: D4352