Changeset View
Changeset View
Standalone View
Standalone View
source/blender/depsgraph/intern/builder/deg_builder_rna.cc
| Show First 20 Lines • Show All 288 Lines • ▼ Show 20 Lines | if (prop != nullptr) { | ||||
| } | } | ||||
| else if (strstr(prop_identifier, "data")) { | else if (strstr(prop_identifier, "data")) { | ||||
| /* We access object.data, most likely a geometry. | /* We access object.data, most likely a geometry. | ||||
| * Might be a bone tho. */ | * Might be a bone tho. */ | ||||
| node_identifier.type = NodeType::GEOMETRY; | node_identifier.type = NodeType::GEOMETRY; | ||||
| return node_identifier; | return node_identifier; | ||||
| } | } | ||||
| else if (STREQ(prop_identifier, "hide_viewport") || STREQ(prop_identifier, "hide_render")) { | else if (STREQ(prop_identifier, "hide_viewport") || STREQ(prop_identifier, "hide_render")) { | ||||
| node_identifier.type = NodeType::OBJECT_FROM_LAYER; | node_identifier.type = NodeType::OBJECT_FROM_LAYER; | ||||
| node_identifier.operation_code = OperationCode::OBJECT_FROM_LAYER_EXIT; | |||||
| return node_identifier; | return node_identifier; | ||||
sergey: Two things here.
First, I think we should stick to COMPONENT level communication as much as… | |||||
sybrenAuthorUnsubmitted Done Inline ActionsThis was the cause of Spring loosing her hair. I didn't take into account the source parameter, so it would indeed always relate to the EXIT node. By sticking to component level communication, this is picked up properly automatically. sybren: This was the cause of Spring loosing her hair. I didn't take into account the `source`… | |||||
| } | } | ||||
| else if (STREQ(prop_identifier, "dimensions")) { | else if (STREQ(prop_identifier, "dimensions")) { | ||||
| node_identifier.type = NodeType::PARAMETERS; | node_identifier.type = NodeType::PARAMETERS; | ||||
| node_identifier.operation_code = OperationCode::DIMENSIONS; | node_identifier.operation_code = OperationCode::DIMENSIONS; | ||||
| return node_identifier; | return node_identifier; | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 66 Lines • Show Last 20 Lines | |||||
Two things here.
First, I think we should stick to COMPONENT level communication as much as possible, leave picking up exact operation to the graph. Kind of hides specifics of topology from other areas. Additionally, this allows depsgraph to automatically pick exit operation for source of relation, and will pick up entry operation for destination of relation.
Second, is maybe this is the reason why object is invisible? If there is a driver on hide_viewport this code wires relation to the EXIT, which is too late since then FROM_LAYER function will not have driver evaluated yet.