Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/object/object_modifier.c
| Show First 20 Lines • Show All 652 Lines • ▼ Show 20 Lines | else if (ELEM(ob->type, OB_CURVE, OB_SURF)) { | ||||
| vertexCos = BKE_curve_nurbs_vertexCos_get(&cu->nurb, &numVerts); | vertexCos = BKE_curve_nurbs_vertexCos_get(&cu->nurb, &numVerts); | ||||
| modifier_deformVerts_DM_deprecated(md, &mectx, NULL, vertexCos, numVerts); | modifier_deformVerts_DM_deprecated(md, &mectx, NULL, vertexCos, numVerts); | ||||
| BK_curve_nurbs_vertexCos_apply(&cu->nurb, vertexCos); | BK_curve_nurbs_vertexCos_apply(&cu->nurb, vertexCos); | ||||
| MEM_freeN(vertexCos); | MEM_freeN(vertexCos); | ||||
| DEG_id_tag_update(&ob->id, OB_RECALC_DATA); | DEG_id_tag_update(&ob->id, OB_RECALC_DATA); | ||||
| } | } | ||||
| else if (ob->type == OB_GPENCIL) { | |||||
| if (ELEM(NULL, ob, ob->data)) { | |||||
| return 0; | |||||
| } | |||||
| else if (mti->gp_bakeModifier == NULL) { | |||||
| BKE_report(reports, RPT_ERROR, "Not implemented"); | |||||
| return 0; | |||||
| } | |||||
| mti->gp_bakeModifier(bmain, depsgraph, md, ob); | |||||
| DEG_id_tag_update(&ob->id, OB_RECALC_DATA); | |||||
| } | |||||
| else { | else { | ||||
| BKE_report(reports, RPT_ERROR, "Cannot apply modifier for this object type"); | BKE_report(reports, RPT_ERROR, "Cannot apply modifier for this object type"); | ||||
| return 0; | return 0; | ||||
| } | } | ||||
| /* lattice modifier can be applied to particle system too */ | /* lattice modifier can be applied to particle system too */ | ||||
| if (ob->particlesystem.first) { | if (ob->particlesystem.first) { | ||||
| ▲ Show 20 Lines • Show All 1,780 Lines • Show Last 20 Lines | |||||