Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/intern/object.cc
| Show First 20 Lines • Show All 992 Lines • ▼ Show 20 Lines | |||||
| CLOG_ERROR(&LOG, | CLOG_ERROR(&LOG, | ||||
| "Evaluated mesh is needed to solve parenting, " | "Evaluated mesh is needed to solve parenting, " | ||||
| "object position can be wrong now"); | "object position can be wrong now"); | ||||
| } | } | ||||
| } | } | ||||
| else if (ELEM(par->type, OB_CURVES_LEGACY, OB_SURF)) { | else if (ELEM(par->type, OB_CURVES_LEGACY, OB_SURF)) { | ||||
| ListBase *nurb; | ListBase *nurb; | ||||
| /* Unless there's some weird depsgraph failure the cache should exist. */ | /* Unless there's some weird depsgraph failure the cache should exist, however | ||||
| BLI_assert(par->runtime.curve_cache != nullptr); | * dependency cycles can also cause the curve cache to be empty as well. */ | ||||
sergey: Not sure the statement about weird depsgraph failure brings much information/ I'd rephrase this… | |||||
| if (par->runtime.curve_cache->deformed_nurbs.first != nullptr) { | if (par->runtime.curve_cache && par->runtime.curve_cache->deformed_nurbs.first != nullptr) { | ||||
| nurb = &par->runtime.curve_cache->deformed_nurbs; | nurb = &par->runtime.curve_cache->deformed_nurbs; | ||||
| } | } | ||||
| else { | else { | ||||
| Curve *cu = (Curve *)par->data; | Curve *cu = (Curve *)par->data; | ||||
| nurb = BKE_curve_nurbs_get(cu); | nurb = BKE_curve_nurbs_get(cu); | ||||
| } | } | ||||
| BKE_nurbList_index_get_co(nurb, nr, vec); | BKE_nurbList_index_get_co(nurb, nr, vec); | ||||
| ▲ Show 20 Lines • Show All 992 Lines • Show Last 20 Lines | |||||
Not sure the statement about weird depsgraph failure brings much information/ I'd rephrase this comment to state facts. Something in-between of lines: